contentEdit.js
1.16 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
var $ = require('jquery'),
common = require('../common/common');
var ENUM={};
// common.util.__ajax({
// url:'EnumListRest/getEnumList',
// async:false
// },function(res){
// ENUM=res.data;
// });
$("#panel-body").html(common.util.__template2($("#tempalte1").html(),{}));
new common.dropDown({el:"#authorId",ajax:"guangGetAuthorList"});
new common.dropDown({el:"#maxSortId",ajax:"guangGetSort",params:function(){
return {pid:0};
}});
new common.dropDown({el:"#minSortId",ajax:"guangGetSort",params:function(){
return {pid:$("#maxSortId").val()};
}});
var g=new common.gird({
el:"grid",
columns:[
{display:"选择","type":"checkbox"},
{display:"标签名",name:"tagName"}
]
});
$(document).on("click","#addUrl",function(){
common.dialog.confirm("添加链接",common.util.__template2($("#template2").html(),{}),function(){
});
});
$(document).on("click","#TagsSelectBtn",function(){
common.dialog.confirm("选择标签","<div id='gird'></div>",function(){
});
g.init('/guang/tags/getList');
});
var e=new common.edit("#panel-body",{});
e.init();
$(document).on("click","#submit",function(){
e.submit($("#panel-body").attr("action"),function(){
});
});