...
|
...
|
@@ -148,7 +148,8 @@ var operationEdit={ |
|
|
this.promotionId=config.promotionId
|
|
|
}
|
|
|
_e.init();
|
|
|
this.bindEvent();
|
|
|
this.bindSaveEvent();
|
|
|
this.bindChangeEvent();
|
|
|
},
|
|
|
template:function(_htmlObj,_data){
|
|
|
if(_data&_data.param_list){
|
...
|
...
|
@@ -173,11 +174,7 @@ var operationEdit={ |
|
|
_htmlObj.last().append(_html);
|
|
|
}
|
|
|
}
|
|
|
},
|
|
|
bindEvent:function(){
|
|
|
$(document).on('click','#save',function(){return this.save()});
|
|
|
$(document).on('change','#promotionType',function(){return this.selectOne()});
|
|
|
},
|
|
|
},
|
|
|
selectOne:function(){
|
|
|
var firstGroup=$("#tab_body>.row").find(".form-group:eq(0)");
|
|
|
firstGroup.nextAll().remove();
|
...
|
...
|
@@ -218,6 +215,12 @@ var operationEdit={ |
|
|
}
|
|
|
this.template(firstGroup,_selectObj);
|
|
|
},
|
|
|
bindSaveEvent:function(){
|
|
|
$(document).on('click','#save',function(){return this.save()});
|
|
|
},
|
|
|
bindChangeEvent:function(){
|
|
|
$(document).on('change','#promotionType',function(){return this.selectOne()});
|
|
|
},
|
|
|
save:function(){
|
|
|
var e=this.edit;
|
|
|
e.submit(this.action, function (option) {
|
...
|
...
|
|