|
@@ -64,29 +64,29 @@ webpackJsonp([71],[ |
|
@@ -64,29 +64,29 @@ webpackJsonp([71],[ |
64
|
el: "#basicTab",
|
64
|
el: "#basicTab",
|
65
|
click: function () {
|
65
|
click: function () {
|
66
|
columnname = $(this).find('a').attr('columnname');
|
66
|
columnname = $(this).find('a').attr('columnname');
|
|
|
67
|
+ g.options.columns[5].hidden = true;
|
67
|
g.options.columns[6].hidden = true;
|
68
|
g.options.columns[6].hidden = true;
|
68
|
- g.options.columns[7].hidden = true;
|
|
|
69
|
switch (columnname) {
|
69
|
switch (columnname) {
|
70
|
case "1":
|
70
|
case "1":
|
71
|
{
|
71
|
{
|
72
|
- g.options.columns[8].hidden = true;
|
72
|
+ g.options.columns[7].hidden = true;
|
73
|
}
|
73
|
}
|
74
|
break;
|
74
|
break;
|
75
|
case "2":
|
75
|
case "2":
|
76
|
{
|
76
|
{
|
77
|
- g.options.columns[6].hidden = false;
|
|
|
78
|
- g.options.columns[8].hidden = true;
|
77
|
+ g.options.columns[5].hidden = false;
|
|
|
78
|
+ g.options.columns[7].hidden = true;
|
79
|
}
|
79
|
}
|
80
|
break;
|
80
|
break;
|
81
|
case "3":
|
81
|
case "3":
|
82
|
{
|
82
|
{
|
83
|
- g.options.columns[7].hidden = false;
|
|
|
84
|
- g.options.columns[8].hidden = true;
|
83
|
+ g.options.columns[6].hidden = false;
|
|
|
84
|
+ g.options.columns[7].hidden = true;
|
85
|
}
|
85
|
}
|
86
|
break;
|
86
|
break;
|
87
|
case "all":
|
87
|
case "all":
|
88
|
{
|
88
|
{
|
89
|
- g.options.columns[8].hidden = false;
|
89
|
+ g.options.columns[7].hidden = false;
|
90
|
}
|
90
|
}
|
91
|
break;
|
91
|
break;
|
92
|
}
|
92
|
}
|
|
@@ -147,7 +147,6 @@ webpackJsonp([71],[ |
|
@@ -147,7 +147,6 @@ webpackJsonp([71],[ |
147
|
}
|
147
|
}
|
148
|
},
|
148
|
},
|
149
|
{display: "优惠券说明", name: "explains"},
|
149
|
{display: "优惠券说明", name: "explains"},
|
150
|
- {display: "申请人", name: "proposer"},
|
|
|
151
|
{
|
150
|
{
|
152
|
display: "驳回理由", hidden: true, name: "rejectReason", render: function (item) {
|
151
|
display: "驳回理由", hidden: true, name: "rejectReason", render: function (item) {
|
153
|
return "<p style='color: red'>" + item.rejectReason + "</p>"
|
152
|
return "<p style='color: red'>" + item.rejectReason + "</p>"
|
|
@@ -240,6 +239,9 @@ webpackJsonp([71],[ |
|
@@ -240,6 +239,9 @@ webpackJsonp([71],[ |
240
|
for (var i = 0; i < array.length; i++) {
|
239
|
for (var i = 0; i < array.length; i++) {
|
241
|
btns.push(buttons[array[i]])
|
240
|
btns.push(buttons[array[i]])
|
242
|
}
|
241
|
}
|
|
|
242
|
+
|
|
|
243
|
+ // 增加查看操作记录按钮
|
|
|
244
|
+ btns.push('<a class="btn btn-primary btn-xs operation-records" data-coupon-id="' + id + '">操作记录</a>');
|
243
|
return btns;
|
245
|
return btns;
|
244
|
}
|
246
|
}
|
245
|
};
|
247
|
};
|
|
@@ -362,7 +364,45 @@ webpackJsonp([71],[ |
|
@@ -362,7 +364,45 @@ webpackJsonp([71],[ |
362
|
Bll.toastInfo(item1, '优惠券详情');
|
364
|
Bll.toastInfo(item1, '优惠券详情');
|
363
|
});
|
365
|
});
|
364
|
|
366
|
|
|
|
367
|
+ // 查看操作记录
|
|
|
368
|
+ $(document).on('click', '.operation-records', function() {
|
|
|
369
|
+ var couponId = $(this).data('coupon-id');
|
|
|
370
|
+ var option = {
|
|
|
371
|
+ title:'操作记录详情',
|
|
|
372
|
+ content:"<div class='historyDetail'>加载操作记录...</div>",
|
|
|
373
|
+ width:'70%',
|
|
|
374
|
+ button:[{value:"关闭", css:"btn-primary"}]
|
|
|
375
|
+ };
|
|
|
376
|
+ new common.dialog(option);
|
|
|
377
|
+
|
|
|
378
|
+ getOperationRecords(couponId);
|
|
|
379
|
+ });
|
|
|
380
|
+
|
|
|
381
|
+ function getOperationRecords(couponId) {
|
|
|
382
|
+ common.util.__ajax({
|
|
|
383
|
+ url: '/coupon/getOperationRecords',
|
|
|
384
|
+ data: {
|
|
|
385
|
+ couponsId: couponId
|
|
|
386
|
+ }
|
|
|
387
|
+ }, function(resp) {
|
|
|
388
|
+ if(resp.code == 200) {
|
|
|
389
|
+ var data = resp.data;
|
|
|
390
|
+ covertOperationRecord(data)
|
|
|
391
|
+ $('.historyDetail').html(common.util.__template2($('#operation-record-template').html(), {list: data}));
|
|
|
392
|
+ }
|
|
|
393
|
+ }, true);
|
|
|
394
|
+ }
|
365
|
|
395
|
|
|
|
396
|
+ // 转化操作类型,操作时间
|
|
|
397
|
+ function covertOperationRecord(data) {
|
|
|
398
|
+ var TYPE = {0: "新增", 1: "修改", 2: "作废"}
|
|
|
399
|
+ if(data && data.length > 0) {
|
|
|
400
|
+ $.each(data, function(index, item) {
|
|
|
401
|
+ item.operationType = TYPE[item.operationType];
|
|
|
402
|
+ item.createTime = Bll.getTime(item.createTime);
|
|
|
403
|
+ })
|
|
|
404
|
+ }
|
|
|
405
|
+ }
|
366
|
|
406
|
|
367
|
|
407
|
|
368
|
/***/ }
|
408
|
/***/ }
|