public void UpdateProductRingInfo(ProductRingDayInfo entity, EventHandler <RestClientEventArgs <object> > callback) { entity.EditUser = CPApplication.Current.LoginUser.UserSysNo; entity.EditDate = DateTime.Now; string relativeUrl = "InventoryService/Inventory/UpdateProductRingDayInfo"; restClient.Update(relativeUrl, entity, callback); }
private void btnSave_Click(object sender, RoutedEventArgs e) { if (!ValidationManager.Validate(this.LayoutRoot)) { return; } if (string.IsNullOrEmpty(_vm.BrandSysNo)) { CurrentWindow.Alert("错误", "请选择一个品牌!", MessageType.Error); return; } if (string.IsNullOrEmpty(_vm.C3SysNo)) { CurrentWindow.Alert("错误", "请选择一个3级类别!", MessageType.Error); return; } CurrentWindow.Confirm("提示", "确定要进行保存操作吗?", (obj, args) => { if (args.DialogResult == DialogResultType.OK) { ProductRingDayInfo entity = EntityConverter <AdventProductsInfoVM, ProductRingDayInfo> .Convert(_vm); if (isAddAction) { _facade.InsertProductRingInfo(entity, (obj2, args2) => { if (args2.FaultsHandle()) { return; } CurrentWindow.Alert("提示", "创建成功!", MessageType.Information, (obj3, args3) => { this.Dialog.ResultArgs.DialogResult = DialogResultType.OK; this.Dialog.Close(true); }); }); } else { _facade.UpdateProductRingInfo(entity, (obj2, args2) => { if (args2.FaultsHandle()) { return; } CurrentWindow.Alert("提示", "保存成功!", MessageType.Information, (obj3, args3) => { this.Dialog.ResultArgs.DialogResult = DialogResultType.OK; this.Dialog.Close(true); }); }); } } }); }
public void AddProductRingInfo(ProductRingDayInfo entity) { ObjectFactory <BatchManagementProcessor> .Instance.AddProductRingInfo(entity); }
public void AddProductRingInfo(ProductRingDayInfo entity) { ObjectFactory <IBatchManagementDA> .Instance.InsertProductRingInfo(entity); }
public void UpdateProductRingInfo(ProductRingDayInfo entity) { ObjectFactory <IBatchManagementDA> .Instance.UpdateProductRingInfo(entity); }
public ProductRingDayInfo AddProductRingDayInfo(ProductRingDayInfo entity) { ObjectFactory <BatchManagementAppService> .Instance.AddProductRingInfo(entity); return(entity); }