private void SetReferenceID() { if (!AuthMgr.HasFunctionAbsolute(AuthKeyConst.Invoice_PayItemQuery_SetReferenceID_AllPath)) { this.AlertInformationDialog(ResCommon.Message_NoAuthorize); return; } var flag = ValidationManager.Validate(this.BaseInfo); if (!flag) { return; } payItemFacade.BatchSetReferenceID(new List <PayItemVM>() { payItemVM }, (msg) => CloseDialog(DialogResultType.OK)); }
/// <summary> /// 批量设置凭证号 /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void btnBatchSetReferenceID_Click(object sender, RoutedEventArgs e) { var selectedPayItemList = GetSelectedPayItemList(); if (selectedPayItemList.Count <= 0) { Window.Alert(ResCommon.Message_AtLeastChooseOneRecord); return; } new UCReferenceIDSetter().ShowDialog(ResPayItemQuery.Message_BatchSetReferenceIDDlgTitle, (obj, args) => { if (args.DialogResult == DialogResultType.OK) { selectedPayItemList.ForEach(w => w.ReferenceID = args.Data.ToString()); facade.BatchSetReferenceID(selectedPayItemList, msg => { Window.Alert(msg, () => this.dgPayItemQueryResult.Bind()); }); } }); }