Showing
5 changed files
with
69 additions
and
94 deletions
@@ -47,7 +47,10 @@ webpackJsonp([18],[ | @@ -47,7 +47,10 @@ webpackJsonp([18],[ | ||
47 | display: "LOGO", | 47 | display: "LOGO", |
48 | name: "brandIco", | 48 | name: "brandIco", |
49 | render: function(item) { | 49 | render: function(item) { |
50 | - return '<img src="' + item.brandIco + '" width="100" height="100"/>' | 50 | + if (item.brandIco) { |
51 | + return '<img src="' + item.brandIco + '" width="100" height="100"/>'; | ||
52 | + } | ||
53 | + return ''; | ||
51 | } | 54 | } |
52 | }, { | 55 | }, { |
53 | display: '品牌名称', | 56 | display: '品牌名称', |
@@ -48,13 +48,19 @@ webpackJsonp([21],[ | @@ -48,13 +48,19 @@ webpackJsonp([21],[ | ||
48 | display:"品牌Logo", | 48 | display:"品牌Logo", |
49 | name:"brandIco", | 49 | name:"brandIco", |
50 | render: function(item) { | 50 | render: function(item) { |
51 | - return '<img src="' + item.brandIco + '" width="100" height="100" id="logo-' + item.__index + '" class="logo-image" />' | 51 | + if (item.brandIco) { |
52 | + return '<img src="' + item.brandIco + '" width="100" height="100" id="logo-' + item.__index + '" class="logo-image" />'; | ||
53 | + } | ||
54 | + return '<div id="logo-' + item.__index + '"/>'; | ||
52 | } | 55 | } |
53 | }, { | 56 | }, { |
54 | display:"线下店品牌Logo", | 57 | display:"线下店品牌Logo", |
55 | name:"offlineBrandIco", | 58 | name:"offlineBrandIco", |
56 | render: function(item) { | 59 | render: function(item) { |
57 | - return '<img src="' + item.offlineBrandIco + '" width="100" height="100" id="offline-logo-' + item.__index + '"/>' | 60 | + if (item.offlineBrandIco) { |
61 | + return '<img src="' + item.offlineBrandIco + '" width="100" height="100" id="offline-logo-' + item.__index + '"/>'; | ||
62 | + } | ||
63 | + return '<div id="offline-logo-' + item.__index + '"/>'; | ||
58 | } | 64 | } |
59 | },{ | 65 | },{ |
60 | display: '品牌名称', | 66 | display: '品牌名称', |
@@ -14,31 +14,24 @@ webpackJsonp([120],[ | @@ -14,31 +14,24 @@ webpackJsonp([120],[ | ||
14 | var g = new common.grid({ | 14 | var g = new common.grid({ |
15 | el: '#payment-list', | 15 | el: '#payment-list', |
16 | columns: [ | 16 | columns: [ |
17 | - {display: "ID", name: "id"}, | ||
18 | - {display: '支付方式名称', render:function(item){ | ||
19 | - if(item.id=='4'){ | ||
20 | - return "Apple Pay(北京银联)"; | ||
21 | - }else if(item.id=='5'){ | ||
22 | - return "银联支付(北京银联)"; | ||
23 | - }else if(item.id=='24'){ | ||
24 | - return "Apple Pay(江苏银联)"; | ||
25 | - }else if(item.id=='26'){ | ||
26 | - return "银联支付(江苏银联)"; | ||
27 | - }else{ | ||
28 | - return item.payName; | ||
29 | - } | ||
30 | - }}, | ||
31 | - {display: '推荐到确认订单页', render: function (item) { | ||
32 | - var rop = ENUM.recommendOrderPage[item.recommendOrderPage]; | ||
33 | - return item.recommendOrderPage == 1 ? rop+"("+item.recommendWords+")" : rop; | ||
34 | - }}, | ||
35 | - {display: '前端显示', render: function (item) { | ||
36 | - var rop = ENUM.displayFirstSight[item.displayFirstSight]; | ||
37 | - return item.displayFirstSight == 1 ? rop+"("+item.displayFirstSight+")" : rop; | 17 | + {display: '支付名称', render:function(item){ |
18 | + return item.payName; | ||
19 | + //if(item.id=='4'){ | ||
20 | + // return "Apple Pay(北京银联)"; | ||
21 | + //}else if(item.id=='5'){ | ||
22 | + // return "银联支付(北京银联)"; | ||
23 | + //}else if(item.id=='24'){ | ||
24 | + // return "Apple Pay(江苏银联)"; | ||
25 | + //}else if(item.id=='26'){ | ||
26 | + // return "银联支付(江苏银联)"; | ||
27 | + //}else{ | ||
28 | + // return item.payName; | ||
29 | + //} | ||
38 | }}, | 30 | }}, |
39 | - {display: "前端排序", name: "sortNumber"}, | ||
40 | - {display: "推荐语1", name: "recommendText1"}, | ||
41 | - {display: "推荐语2", name: "recommendText2"}, | 31 | + {display: "前端显示排序", name: "sortNumber"}, |
32 | + {display: "推荐语", name: "recommendText1"}, | ||
33 | + {display:"未开通文案",name:"noOpenText"}, | ||
34 | + //{display: "推荐语2", name: "recommendText2"}, | ||
42 | {display: '操作', render: function (item) { | 35 | {display: '操作', render: function (item) { |
43 | var HtmArr = []; | 36 | var HtmArr = []; |
44 | HtmArr.push('<a href="javascript:" class="btn btn-info btn-xs edit-btn" data-index="'+item.__index+'">编辑</a>'); | 37 | HtmArr.push('<a href="javascript:" class="btn btn-info btn-xs edit-btn" data-index="'+item.__index+'">编辑</a>'); |
@@ -63,8 +56,6 @@ webpackJsonp([120],[ | @@ -63,8 +56,6 @@ webpackJsonp([120],[ | ||
63 | $(document).on("click", ".edit-btn", function () { | 56 | $(document).on("click", ".edit-btn", function () { |
64 | var _index = $(this).data("index"); | 57 | var _index = $(this).data("index"); |
65 | var data = g.rows[_index]; | 58 | var data = g.rows[_index]; |
66 | - var recommendOrderPage_old = data.recommendOrderPage; | ||
67 | - var displayFirstSight_old = data.displayFirstSight; | ||
68 | 59 | ||
69 | var d = new common.dialog({ | 60 | var d = new common.dialog({ |
70 | title: "支付方式编辑", | 61 | title: "支付方式编辑", |
@@ -78,40 +69,7 @@ webpackJsonp([120],[ | @@ -78,40 +69,7 @@ webpackJsonp([120],[ | ||
78 | newData[item.name] = item.value; | 69 | newData[item.name] = item.value; |
79 | }); | 70 | }); |
80 | if(checkPaymentData(newData, data)){ | 71 | if(checkPaymentData(newData, data)){ |
81 | - //更变了推荐到确认订单页情况下,需要二次确认 | ||
82 | - if(recommendOrderPage_old != newData.recommendOrderPage){ | ||
83 | - new common.dialog({ | ||
84 | - title: "温馨提示", | ||
85 | - width: "360px", | ||
86 | - content:newData.recommendOrderPage == 1 ? "你确认将这个支付方式<font color='#5cb85c'>推荐</font>到确认订单页面么?" : "你确认<font color='#ff0000'>取消</font>将这个支付方式推荐到确认订单页面么?", | ||
87 | - zIndex: 52, | ||
88 | - button:[ | ||
89 | - {value: "确认", css:"btn-primary", callback: function () { | ||
90 | - savePaymentData(newData); | ||
91 | - d.close(); | ||
92 | - }}, | ||
93 | - {value: "取消", css:"btn-default"} | ||
94 | - ] | ||
95 | - }); | ||
96 | - return false; | ||
97 | - } else if(displayFirstSight_old != newData.displayFirstSight){ | ||
98 | - new common.dialog({ | ||
99 | - title: "温馨提示", | ||
100 | - width: "360px", | ||
101 | - content:newData.displayFirstSight == 1 ? "你确认将这个支付方式<font color='#5cb85c'>首次显示</font>吗?" : "你确认<font color='#ff0000'>取消</font>将这个支付方式首次显示吗?", | ||
102 | - zIndex: 52, | ||
103 | - button:[ | ||
104 | - {value: "确认", css:"btn-primary", callback: function () { | ||
105 | - savePaymentData(newData); | ||
106 | - d.close(); | ||
107 | - }}, | ||
108 | - {value: "取消", css:"btn-default"} | ||
109 | - ] | ||
110 | - }); | ||
111 | - return false; | ||
112 | - } else{ | ||
113 | savePaymentData(newData); | 72 | savePaymentData(newData); |
114 | - } | ||
115 | }else{ | 73 | }else{ |
116 | return false; | 74 | return false; |
117 | } | 75 | } |
@@ -27,8 +27,8 @@ module.exports= { | @@ -27,8 +27,8 @@ module.exports= { | ||
27 | {name:"recommendWords", type:"String"}, | 27 | {name:"recommendWords", type:"String"}, |
28 | {name:"sortNumber", type:"Number", default:0}, | 28 | {name:"sortNumber", type:"Number", default:0}, |
29 | {name:"recommendText1", type:"String"}, | 29 | {name:"recommendText1", type:"String"}, |
30 | - {name:"recommendText2", type:"String"}, | ||
31 | - {name:"displayFirstSight", type:"String", default:0} | 30 | + {name:"displayFirstSight", type:"String", default:0}, |
31 | + {name:"noOpenText", type:"String"}, | ||
32 | ] | 32 | ] |
33 | }, | 33 | }, |
34 | 34 | ||
@@ -42,8 +42,8 @@ module.exports= { | @@ -42,8 +42,8 @@ module.exports= { | ||
42 | {name:"recommendWords", type:"String"}, | 42 | {name:"recommendWords", type:"String"}, |
43 | {name:"sortNumber", type:"Number", default:0}, | 43 | {name:"sortNumber", type:"Number", default:0}, |
44 | {name:"recommendText1", type:"String"}, | 44 | {name:"recommendText1", type:"String"}, |
45 | - {name:"recommendText2", type:"String"}, | ||
46 | - {name:"displayFirstSight", type:"String", default:0} | 45 | + {name:"displayFirstSight", type:"String", default:0}, |
46 | + {name:"noOpenText", type:"String"}, | ||
47 | ] | 47 | ] |
48 | }, | 48 | }, |
49 | 49 |
@@ -20,33 +20,32 @@ | @@ -20,33 +20,32 @@ | ||
20 | <label class="col-sm-3 control-label" style="text-align: center">支付方式:</label> | 20 | <label class="col-sm-3 control-label" style="text-align: center">支付方式:</label> |
21 | <div class="col-sm-5" style="padding-top: 10px">[[payName]]</div> | 21 | <div class="col-sm-5" style="padding-top: 10px">[[payName]]</div> |
22 | </div> | 22 | </div> |
23 | + <!--<div class="form-group">--> | ||
24 | + <!--<label class="col-sm-3 control-label" style="text-align: center">推荐到确认订单页:</label>--> | ||
25 | + <!--<div class="col-sm-5" style="padding-top: 3px">--> | ||
26 | + <!--<label class="radio-inline"><input name="recommendOrderPage" type="radio" value=1>是</label>--> | ||
27 | + <!-- --> | ||
28 | + <!--<label class="radio-inline"><input name="recommendOrderPage" type="radio" value=0>否</label>--> | ||
29 | + <!--</div>--> | ||
30 | + <!--<input id="recommendOrderPage" type="hidden" value="[[recommendOrderPage]]" for="radio">--> | ||
31 | + <!--</div>--> | ||
23 | 32 | ||
24 | - <div class="form-group"> | ||
25 | - <label class="col-sm-3 control-label" style="text-align: center">推荐到确认订单页:</label> | ||
26 | - <div class="col-sm-5" style="padding-top: 3px"> | ||
27 | - <label class="radio-inline"><input name="recommendOrderPage" type="radio" value=1>是</label> | ||
28 | - | ||
29 | - <label class="radio-inline"><input name="recommendOrderPage" type="radio" value=0>否</label> | ||
30 | - </div> | ||
31 | - <input id="recommendOrderPage" type="hidden" value="[[recommendOrderPage]]" for="radio"> | ||
32 | - </div> | ||
33 | - | ||
34 | - <div class="form-group"> | ||
35 | - <label for="recommendWords" class="col-sm-3 control-label" style="text-align: center">推荐文案:</label> | ||
36 | - <div class="col-sm-5"> | ||
37 | - <input type="text" id="recommendWords" name="recommendWords" value="[[recommendWords]]" class="form-control" /> | ||
38 | - </div> | ||
39 | - </div> | 33 | + <!--<div class="form-group">--> |
34 | + <!--<label for="recommendWords" class="col-sm-3 control-label" style="text-align: center">推荐文案:</label>--> | ||
35 | + <!--<div class="col-sm-5">--> | ||
36 | + <!--<input type="text" id="recommendWords" name="recommendWords" value="[[recommendWords]]" class="form-control" />--> | ||
37 | + <!--</div>--> | ||
38 | + <!--</div>--> | ||
40 | 39 | ||
41 | - <div class="form-group"> | ||
42 | - <label class="col-sm-3 control-label" style="text-align: center">首页显示:</label> | ||
43 | - <div class="col-sm-5" style="padding-top: 3px"> | ||
44 | - <label class="radio-inline"><input name="displayFirstSight" type="radio" value=1>是</label> | ||
45 | - | ||
46 | - <label class="radio-inline"><input name="displayFirstSight" type="radio" value=0>否</label> | ||
47 | - </div> | ||
48 | - <input id="displayFirstSight" type="hidden" value="[[displayFirstSight]]" for="radio"> | ||
49 | - </div> | 40 | + <!--<div class="form-group">--> |
41 | + <!--<label class="col-sm-3 control-label" style="text-align: center">首页显示:</label>--> | ||
42 | + <!--<div class="col-sm-5" style="padding-top: 3px">--> | ||
43 | + <!--<label class="radio-inline"><input name="displayFirstSight" type="radio" value=1>是</label>--> | ||
44 | + <!-- --> | ||
45 | + <!--<label class="radio-inline"><input name="displayFirstSight" type="radio" value=0>否</label>--> | ||
46 | + <!--</div>--> | ||
47 | + <!--<input id="displayFirstSight" type="hidden" value="[[displayFirstSight]]" for="radio">--> | ||
48 | + <!--</div>--> | ||
50 | 49 | ||
51 | <div class="form-group"> | 50 | <div class="form-group"> |
52 | <label for="sortNumber" class="col-sm-3 control-label" style="text-align: center">前端排序:</label> | 51 | <label for="sortNumber" class="col-sm-3 control-label" style="text-align: center">前端排序:</label> |
@@ -57,13 +56,21 @@ | @@ -57,13 +56,21 @@ | ||
57 | </div> | 56 | </div> |
58 | 57 | ||
59 | <div class="form-group"> | 58 | <div class="form-group"> |
60 | - <label for="recommendText1" class="col-sm-3 control-label" style="text-align: center">推荐语1:</label> | 59 | + <label for="recommendText1" class="col-sm-3 control-label" style="text-align: center">推荐语:</label> |
61 | <div class="col-sm-5"> | 60 | <div class="col-sm-5"> |
62 | - <input type="text" id="recommendText1" name="recommendText1" value="[[recommendText1]]" class="form-control" maxlength="20" /> | 61 | + <input type="te将这个支付方式推荐到确认订单页面么xt" id="recommendText1" name="recommendText1" value="[[recommendText1]]" class="form-control" maxlength="20" /> |
63 | </div> | 62 | </div> |
64 | <div class="col-sm-4"><label style="color: #999"> * 建议10个字以内,不超过20个字</label></div> | 63 | <div class="col-sm-4"><label style="color: #999"> * 建议10个字以内,不超过20个字</label></div> |
65 | </div> | 64 | </div> |
66 | - | 65 | + [[if payName=='Android Pay'||payName=="Apple Pay"]] |
66 | + <div class="form-group"> | ||
67 | + <label class="col-sm-3 control-label" style="text-align: center">未开通文案:</label> | ||
68 | + <div class="col-sm-5"> | ||
69 | + <input type="text" id="noOpenText" name="noOpenText" value="[[noOpenText]]" class="form-control" maxlength="20" /> | ||
70 | + </div> | ||
71 | + </div> | ||
72 | + [[/if]] | ||
73 | + <!-- | ||
67 | <div class="form-group"> | 74 | <div class="form-group"> |
68 | <label for="recommendText2" class="col-sm-3 control-label" style="text-align: center">推荐语2:</label> | 75 | <label for="recommendText2" class="col-sm-3 control-label" style="text-align: center">推荐语2:</label> |
69 | <div class="col-sm-5"> | 76 | <div class="col-sm-5"> |
@@ -71,6 +78,7 @@ | @@ -71,6 +78,7 @@ | ||
71 | </div> | 78 | </div> |
72 | <div class="col-sm-4"><label style="color: #999"> * 建议10个字以内,不超过20个字</label></div> | 79 | <div class="col-sm-4"><label style="color: #999"> * 建议10个字以内,不超过20个字</label></div> |
73 | </div> | 80 | </div> |
81 | + --> | ||
74 | </form> | 82 | </form> |
75 | </script> | 83 | </script> |
76 | 84 |
-
Please register or login to post a comment