ProjectEqAreaView.js
1.98 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
let action = null;
layui.config({
base: "/js/",
version: 111
}).use(['system'], function () {
var form = layui.form,
$ = layui.jquery,
system = layui.system,
sysU = new system.u(),
areaName = 'configure',
tableName = 'BaseProject';
action = {
}
var app = {
data: {
cols: null,
tableIns: null,
tableElem: "mainList",
selectOption: {
//返回的数据 用于后续操作
selectData: {
}
}
},
methods: {
initTable: function () {
let options = {
elem: "#" + app.data.tableElem,
url: `/${areaName}/${tableName}/Load`,
cols: sysU.columnRecord(app.data.tableElem, app.data.cols),
toolbar: '#toolbarTable',
}
app.data.tableIns = sysU.initTable(options);
},
initFrom: function () {
//sysU.initSelect(app.data.selectOption);
debugger
var imgInfo = "暂未设计车间设备区域布局图",
projectName = "".GetUrlParam("projectName"),
imgSrcKey = "".GetUrlParam("projectCode"),
eqAreaImgList = sysU.arrFilterByProperty("DictType", "eq_area_img"),
dic = eqAreaImgList.filter(item => item["DictLabel"] == imgSrcKey);
if (dic.length == 1) {
$("#eq_area_img").attr("src", dic[0].DictValue);
imgInfo = "车间设备区域布局图";
}
$("#projectNameEle").text(`${projectName}${imgInfo}`).show();
},
},
registerEvent: function () {
},
init: function () {
app.registerEvent();
app.methods.initFrom();
}
};
app.init();
});