懒羊羊
2023-11-14 8286c62256f23bc2367a6729c0f46f84215e380b
提交 | 用户 | 时间
8286c6 1 /**
2  * 添加或者修改页面
3  */
4 var EquipmentMaintainContentConfInfoDlg = {
5     data: {
6         id: "",
7         maintainContentCode: "",
8         maintainContentName: "",
9         maintainContentType: "",
10         maintainContent: "",
11         state: "",
12         spareField1: "",
13         spareField2: "",
14         remarks: "",
15         createUser: "",
16         updateUser: "",
17         createTime: "",
18         updateTime: ""
19     }
20 };
21
22 layui.use(['form', 'admin', 'ax','laydate','upload','formSelects'], function () {
23     var $ = layui.jquery;
24     var $ax = layui.ax;
25     var form = layui.form;
26     var admin = layui.admin;
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     form.on('submit(btnSubmit)', function (data) {
55         var ajax = new $ax(Feng.ctxPath + "/equipmentMaintainContentConf/addItem", function (data) {
56             Feng.success("添加成功!");
57             window.location.href = Feng.ctxPath + '/equipmentMaintainContentConf'
58         }, function (data) {
59             Feng.error("添加失败!" + data.responseJSON.message)
60         });
61         ajax.set(data.field);
62         ajax.start();
63
64         return false;
65     });
66
67     $('#cancel').click(function(){
68         window.location.href = Feng.ctxPath + '/equipmentMaintainContentConf'
69     });
70
71
72 });