private void btnAudit_Click(object sender, RoutedEventArgs e) { if (!AuthMgr.HasFunctionPoint(AuthKeyConst.Invoice_PriceChange_Audit)) { //Window.Alert("不能进行审核操作,你没有审核权限!"); Window.Alert(ResPriceChangeQuery.Msg_NoAuditAuthority); return; } UCPriceChangeSetter uc = new UCPriceChangeSetter(); uc.IsBatchModel = true; IDialog dialog = Window.ShowDialog(ResPriceChangeQuery.Msg_AudtiMemo, uc, (obj1, args1) => { if (args1.DialogResult == DialogResultType.OK) { string auditMemo = Convert.ToString(args1.Data); var SysList = from item in this.resultCollection where item.IsChecked == true select item.SysNo.Value; if (SysList.Count() > 0) { Dictionary <int, string> dic = new Dictionary <int, string>(); foreach (var item in SysList) { dic.Add(item, auditMemo); } facade.BatchAuditPriceChange(dic, (msg) => { Window.Alert(ResPriceChangeQuery.Msg_Tips, msg, Newegg.Oversea.Silverlight.Controls.Components.MessageType.Information, (obj, args) => { this.resultgd.Bind(); }); }); } else { //Window.Alert("请至少选择一条记录!"); Window.Alert(ResPriceChangeQuery.Msg_SelectRecord); } } }); uc.DialogHanlder = dialog; }
private void btnAudit_Click(object sender, RoutedEventArgs e) { if (!AuthMgr.HasFunctionPoint(AuthKeyConst.Invoice_PriceChange_Audit)) { //Window.Alert("不能进行审核操作,你没有审核权限!"); Window.Alert(ResPriceChangeMaintain.Msg_NoAuditAuthority); return; } UCPriceChangeSetter uc = new UCPriceChangeSetter(this.vm); uc.IsAuditModel = true; IDialog dialog = Window.ShowDialog(null, uc, (obj1, args1) => { if (args1.DialogResult == DialogResultType.OK) { this.vm.AudtiMemo = Convert.ToString(args1.Data); if (!string.IsNullOrEmpty(this.vm.AudtiMemo)) { Dictionary <int, string> dic = new Dictionary <int, string>(); dic.Add(this.vm.SysNo.Value, this.vm.AudtiMemo); facade.BatchAuditPriceChange(dic, (msg) => { Window.Alert(ResPriceChangeMaintain.Msg_Tips, msg, Newegg.Oversea.Silverlight.Controls.Components.MessageType.Information, (obj, args) => { Window.Refresh(); }); }); } else { //Window.Alert("请输入审核备注信息!"); Window.Alert(ResPriceChangeMaintain.Msg_NeedEnterMemoInfo); } } }); uc.DialogHanlder = dialog; }