...
|
...
|
@@ -39,10 +39,26 @@ var operationEdit={ |
|
|
}
|
|
|
]
|
|
|
},
|
|
|
EveryCashreduce:{
|
|
|
enName:'EveryCashreduce',
|
|
|
LoopCashReduce:{
|
|
|
enName:'LoopCashReduce',
|
|
|
cnName : '每满减',
|
|
|
param_list : []
|
|
|
param_list : [
|
|
|
{
|
|
|
name:'maxLoopNumber' ,
|
|
|
display_name : '循环上限',
|
|
|
type : 'text',
|
|
|
default_value : '10000',
|
|
|
post_label: '倍',
|
|
|
required: true
|
|
|
},
|
|
|
{
|
|
|
name:'reduce' ,
|
|
|
display_name : '满减',
|
|
|
type : 'text',
|
|
|
default_value : '',
|
|
|
required: true
|
|
|
}
|
|
|
]
|
|
|
},
|
|
|
Gift:{
|
|
|
enName:'Gift',
|
...
|
...
|
@@ -193,7 +209,10 @@ var operationEdit={ |
|
|
for(var _index in _data.param_list){
|
|
|
_param=_data.param_list[_index];
|
|
|
var _html=_htmlObj.clone();
|
|
|
_html.children("label").html(_param.display_name);
|
|
|
var $label = _html.children("label").html(_param.display_name);
|
|
|
if(_param.required) {
|
|
|
$label.append($("<span class=\" red \" style=\"padding-left: 5px\">*</span>"));
|
|
|
}
|
|
|
var _input;
|
|
|
switch(_param.type){
|
|
|
case "text":
|
...
|
...
|
@@ -216,7 +235,11 @@ var operationEdit={ |
|
|
}
|
|
|
_input.attr("id",_param.name);
|
|
|
_input.attr("name",_param.name);
|
|
|
_html.children("div").html(_input);
|
|
|
var $inputParent = _html.children("div").html(_input);
|
|
|
if(_param.post_label) {
|
|
|
$inputParent.css({'display': 'flex', 'align-items': 'center'});
|
|
|
$inputParent.append($('<span>倍</span>').css('padding-left', '10px'))
|
|
|
}
|
|
|
if(_param.remark){
|
|
|
var _remark=$("<label class=\"control-label red\"></label>");
|
|
|
_remark.html(_param.remark);
|
...
|
...
|
@@ -263,13 +286,14 @@ var operationEdit={ |
|
|
break;
|
|
|
case this.config.SpecifiedAmount.enName:
|
|
|
_selectObj=this.config.SpecifiedAmount;
|
|
|
case this.config.EveryCashreduce.enName:
|
|
|
this.everyCashreduce()
|
|
|
break;
|
|
|
case this.config.LoopCashReduce.enName:
|
|
|
_selectObj=this.config.LoopCashReduce
|
|
|
break;
|
|
|
}
|
|
|
this.template(firstGroup,_selectObj);
|
|
|
},
|
|
|
everyCashreduce: function() {},
|
|
|
LoopCashReduce: function() {},
|
|
|
bindEvent:function(){
|
|
|
var _g=this;
|
|
|
$('#save_operation').off();
|
...
|
...
|
|