| | |
| | | <Context/> |
| | | <Model> |
| | | <DataType name="dtMain"> |
| | | <ClientEvent name="onDataChange">if(arg.property =="depotId"){
 |
| | | autoByDepot(arg.newValue);
 |
| | | }
</ClientEvent> |
| | | <Property name="creationType">com.fzzy.igds.data.InoutData</Property> |
| | | <PropertyDef name="id"> |
| | | <Property></Property> |
| | |
| | | view.get("#dsMain").set("parameter",TYPE).flushAsync();
 |
| | | };
 |
| | | flush();
 |
| | | 
 |
| | | //根据仓库自动回填粮食品种,登记,产地新
 |
| | | autoByDepot = function(depotId){
 |
| | | view.get("#ajaxGetDepot").set("parameter",depotId).execute(function(result){
 |
| | | if(result){
 |
| | | var data = view.get("#dsMain.data:#");
 |
| | | data.set("foodVariety",result.foodVariety);
 |
| | | }
 |
| | | });
 |
| | | };
 |
| | | 
 |
| | | /**
 |
| | | * 数据保存提交
 |
| | |
| | | <Property name="async">true</Property> |
| | | <Property name="confirmMessage">确定要删除么?</Property> |
| | | </AjaxAction> |
| | | <AjaxAction id="ajaxGetDepot"> |
| | | <Property name="service">depotPR#getDepot</Property> |
| | | </AjaxAction> |
| | | </View> |
| | | </ViewConfig> |