| | |
| | | |
| | | }, |
| | | _initEvent:function(){ |
| | | vc.on('edit@@TemplateCode@@','openEdit@@TemplateCode@@Model',function(_params){ |
| | | vc.on('edit@@TemplateCode@@','openEdit@@TemplateCode@@Modal',function(_params){ |
| | | vc.component.refreshEdit@@TemplateCode@@Info(); |
| | | $('#edit@@TemplateCode@@Model').modal('show'); |
| | | vc.component.edit@@TemplateCode@@Info = _params; |
| | | vc.copyObject(_params, vc.component.edit@@TemplateCode@@Info ); |
| | | vc.component.edit@@TemplateCode@@Info.communityId = vc.getCurrentCommunity().communityId; |
| | | }); |
| | | }, |
| | |
| | | }, |
| | | edit@@TemplateCode@@:function(){ |
| | | if(!vc.component.edit@@TemplateCode@@Validate()){ |
| | | vc.message(vc.validate.errInfo); |
| | | vc.toast(vc.validate.errInfo); |
| | | return ; |
| | | } |
| | | |
| | | vc.http.post( |
| | | 'edit@@TemplateCode@@', |
| | | 'update', |
| | | vc.http.apiPost( |
| | | '@@templateCode@@.update@@TemplateCode@@', |
| | | JSON.stringify(vc.component.edit@@TemplateCode@@Info), |
| | | { |
| | | emulateJSON:true |