public ConsGridViewModel(string str) { serviceCons = XapServiceMgr.find <ICiOrdQryService>(); psndocCrudService = XapServiceMgr.find <IPsndocCrudService>(); consAggService = XapServiceMgr.find <ICiorappconsultCrudService>(); //this.consDoService = XapServiceMgr.find<ICiorappconsultMDOCrudService>(); saveService = XapServiceMgr.find <ICiOrdMaintainService>(); OrdConsDTO[] cons = serviceCons.GetConsList(UserManager.getInstance().CurrentDept.Id_dep, str); consList = new XapDataList <OrdConsDTO>(serviceCons, setValue(cons)); }
public ConsItemViewModel(String id_ent) { QryService = XapServiceMgr.find <ICiOrdQryService>(); consAggService = XapServiceMgr.find <ICiorappconsultCrudService>(); saveService = XapServiceMgr.find <ICiOrdMaintainService>(); this.rptService = XapServiceMgr.find <IConsrptCrudService>(); OrdApConsDO[] ordappcons = QryService.getTreeOrdApConsDO(id_ent); //consItems = new XapDataList<OrdApConsDO>(); XapDataList <OrdApConsDO> list = new XapDataList <OrdApConsDO>(); ordappcons.ToList().ForEach(p => { list.Add(p); }); //consItems= apvm.GetApConsItem(); KeyNodeDataAdapterFactory <OrdApConsDO> moduleAdapter = new KeyNodeDataAdapterFactory <OrdApConsDO>("Id_apcons"); moduleAdapter.CustomCaptionFunc = (dataobj => dataobj.Name_constp + "(" + dataobj.Dt_plan.Value.ToString("yy-MM-dd HH:mm") + ")"); this.TreeModel = new TreeKeyModel <OrdApConsDO>(moduleAdapter); this.TreeModel.Loader = new OTreeKeyLoader(); this.TreeModel.AddRange(list); }
public ConsCardViewModel() { service = XapServiceMgr.find <ICiOrdQryService>(); consAggService = XapServiceMgr.find <ICiorappconsultCrudService>(); this.consDoService = XapServiceMgr.find <ICiorappconsultMDOCrudService>(); }