|
|
@@ -38,11 +38,10 @@ $('#Keys').on('keypress',function(e){
|
|
38
|
38
|
getBM($("#clbmtree"));
|
|
39
|
39
|
|
|
40
|
40
|
function getBM(obj) {
|
|
41
|
|
- $.getJSON(huayi.config.callcenter_url + '/IndexCategory/GetList', {
|
|
42
|
|
- pageSize:20,
|
|
|
41
|
+ $.getJSON(huayi.config.callcenter_url + '/IndexCategory/GetSelectList', {
|
|
43
|
42
|
"token": $.cookie("token")
|
|
44
|
43
|
}, function(result) {
|
|
45
|
|
- if(result.total > 0) {
|
|
|
44
|
+ if(result.rows.length > 0) {
|
|
46
|
45
|
$.fn.zTree.init(obj, setting, result.rows);
|
|
47
|
46
|
}
|
|
48
|
47
|
})
|
|
|
@@ -230,7 +229,7 @@ function GetIndexCategory(Left_Cids) {
|
|
230
|
229
|
success: function(data) {
|
|
231
|
230
|
$("#Left_CategoryName").val(data.data.F_CategoryName);
|
|
232
|
231
|
$("#Left_Sort").val(data.data.F_Sort);
|
|
233
|
|
- $("#Left_ParentId").val('顶级分类');
|
|
|
232
|
+ $("#Left_ParentId").val(data.data.F_ParentId);
|
|
234
|
233
|
}
|
|
235
|
234
|
});
|
|
236
|
235
|
}
|
|
|
@@ -238,7 +237,7 @@ function GetIndexCategory(Left_Cids) {
|
|
238
|
237
|
function Select() {
|
|
239
|
238
|
$.ajax({
|
|
240
|
239
|
type: "get",
|
|
241
|
|
- url: huayi.config.callcenter_url + "IndexCategory/GetList",
|
|
|
240
|
+ url: huayi.config.callcenter_url + "IndexCategory/GetSelectList",
|
|
242
|
241
|
// url:'//117.158.196.116:8878/IndexCategory/GetList',
|
|
243
|
242
|
dataType: 'json',
|
|
244
|
243
|
async: true,
|
|
|
@@ -247,11 +246,9 @@ function Select() {
|
|
247
|
246
|
},
|
|
248
|
247
|
success: function(data) {
|
|
249
|
248
|
var conent = data.rows;
|
|
|
249
|
+ $('<option value="0">顶级分类</option>').appendTo($("#Left_ParentId"))
|
|
250
|
250
|
for(var i = 0; i < conent.length; i++) {
|
|
251
|
|
- if(conent[i].F_ParentId == 0) {
|
|
252
|
|
-// $('<option value="' + conent[i].F_ParentId + '">' + conent[i].F_CategoryName + '</option>').appendTo($("#Left_ParentId"))
|
|
253
|
|
- $('<option value="顶级分类" selected>顶级分类</option>').appendTo($("#Left_ParentId"))
|
|
254
|
|
- }
|
|
|
251
|
+ $('<option value="' + conent[i].F_ParentId + '">' + conent[i].F_CategoryName + '</option>').appendTo($("#Left_ParentId"))
|
|
255
|
252
|
}
|
|
256
|
253
|
}
|
|
257
|
254
|
});
|