/// <summary> /// 删除 /// </summary> /// <param name="sender"></param> /// <param name="e"></param> void ButtonDelete_Click(object sender, RoutedEventArgs e) { if (dgModelCode.SelectedItems.Count > 1) { ComfirmWindow.ConfirmationBox("提示信息", "只能选择一条需要删除的记录!", "确定"); return; } if (dgModelCode.SelectedItems.Count == 1) { string Result = ""; ComfirmWindow com = new ComfirmWindow(); com.OnSelectionBoxClosed += (obj, result) => { pBar.Start(); FLOW_MODELDEFINE_T define = (dgModelCode.SelectedItem as FLOW_MODELDEFINE_T); ObservableCollection<string> delete = new ObservableCollection<string>(); delete.Add(define.MODELCODE); client.DeleteModelDefineAsync(delete); }; com.SelectionBox("删除确定", "你确定删除选中的记录吗?", ComfirmWindow.titlename, Result); } else { ComfirmWindow.ConfirmationBox("提示信息", "请先选择一条需要删除的记录!", "确定"); } }
private void MeetingCancelBtn_Click(object sender, RoutedEventArgs e) { string MeetingInfoID = ""; //V_MeetingInfo MeetingInfoT = new V_MeetingInfo(); //if (DaGr.ItemsSource != null) //{ // foreach (object obj in DaGr.ItemsSource) // { // if (DaGr.Columns[0].GetCellContent(obj) != null) // { // CheckBox cb1 = DaGr.Columns[0].GetCellContent(obj).FindName("myChkBox") as CheckBox; //cb为 // if (cb1.IsChecked == true) // { // MeetingInfoT = cb1.Tag as V_MeetingInfo; // break; // } // } // } //} if (Meetinginfo != null) { string Result = ""; SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow com = new SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow(); com.OnSelectionBoxClosed += (obj, result) => { try { //tmpInfoT = MeetingInfoT.meetinginfo; //tmpInfoT.CHECKSTATE = "3"; //MeetingClient.MeetingInfoUpdateAsync(tmpInfoT); CancelMeetingForm form = new CancelMeetingForm(FormTypes.New, Meetinginfo); EntityBrowser browser = new EntityBrowser(form); browser.MinHeight = 570; browser.MinWidth = 580; browser.ReloadDataEvent += new EntityBrowser.refreshGridView(browser_ReloadDataEvent); browser.Show <string>(DialogMode.Default, Common.ParentLayoutRoot, "", (result1) => { }, true); } catch (Exception ex) { Utility.ShowCustomMessage(MessageTypes.Message, Utility.GetResourceStr("ERROR"), ex.ToString()); return; //com.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow.titlename, Result); } }; com.SelectionBox(Utility.GetResourceStr("CANCELMEETINGCONFIRM"), Utility.GetResourceStr("CANCELMEETINGALTER"), SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow.titlename, Result); } else { //MessageBox.Show("请您选择需要删除的数据!"); Utility.ShowCustomMessage(MessageTypes.Message, Utility.GetResourceStr("WARNING"), Utility.GetResourceStr("SELECTWARNING", "CANCELMEETINGCONFIRM")); } }
private void ConfirmBtn_Click(object sender, RoutedEventArgs e) { T_OA_ORDERMEAL InfoT = new T_OA_ORDERMEAL(); if (DaGr.ItemsSource != null) { foreach (object obj in DaGr.ItemsSource) { if (DaGr.Columns[0].GetCellContent(obj) != null) { CheckBox cb1 = DaGr.Columns[0].GetCellContent(obj).FindName("myChkBox") as CheckBox; //cb为 if (cb1.IsChecked == true) { InfoT = cb1.Tag as T_OA_ORDERMEAL; break; } } } } if (!string.IsNullOrEmpty(InfoT.ORDERMEALID)) { string Result = ""; SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow com = new SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow(); com.OnSelectionBoxClosed += (obj, strresult) => { if (InfoT != null) { try { AddOrderMealRemark AddWin = new AddOrderMealRemark(Action.Add, InfoT); //MeetingRoomAppForm AddWin = new MeetingRoomAppForm(Action.Add, MeetingRoomAppT, null); EntityBrowser browser = new EntityBrowser(AddWin); browser.MinHeight = 300; browser.MinWidth = 300; AddWin.ReloadDataEvent += new AddOrderMealRemark.refreshGridView(AddWin_ReloadDataEvent); browser.Show <string>(DialogMode.Default, Common.ParentLayoutRoot, "", (result) => { }); } catch (Exception ex) { //com.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow.titlename, Result); } } }; com.SelectionBox(Utility.GetResourceStr("ORDEREDMEAL"), Utility.GetResourceStr("ORDERMEALCONFIRM"), SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow.titlename, Result); } else { //MessageBox.Show("请您选择需要删除的数据!"); Utility.ShowCustomMessage(MessageTypes.Message, Utility.GetResourceStr("WARNING"), Utility.GetResourceStr("SELECTWARNING", "CANCELORDERMEAL")); } }
private void ChangeMeetingBtn_Click(object sender, RoutedEventArgs e) { string MeetingInfoID = ""; //V_MeetingInfo MeetingInfoT = new V_MeetingInfo(); //if (DaGr.ItemsSource != null) //{ // foreach (object obj in DaGr.ItemsSource) // { // if (DaGr.Columns[0].GetCellContent(obj) != null) // { // CheckBox cb1 = DaGr.Columns[0].GetCellContent(obj).FindName("myChkBox") as CheckBox; //cb为 // if (cb1.IsChecked == true) // { // MeetingInfoT = cb1.Tag as V_MeetingInfo; // break; // } // } // } //} if (Meetinginfo != null) { string Result = ""; SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow com = new SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow(); com.OnSelectionBoxClosed += (obj, result) => { try { ChangeMeetingTimeForm form = new ChangeMeetingTimeForm(FormTypes.New, Meetinginfo); EntityBrowser browser = new EntityBrowser(form); browser.MinHeight = 400; browser.MinWidth = 500; browser.ReloadDataEvent += new EntityBrowser.refreshGridView(browser_ReloadDataEvent); browser.Show <string>(DialogMode.Default, Common.ParentLayoutRoot, "", (result1) => { }, true); } catch (Exception ex) { throw(ex); //com.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow.titlename, Result); } }; com.SelectionBox(Utility.GetResourceStr("CHANGECONFIRM"), Utility.GetResourceStr("CHANGEALTER"), SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow.titlename, Result); } else { //MessageBox.Show("请您选择需要删除的数据!"); //Utility.ShowCustomMessage(MessageTypes.Message, Utility.GetResourceStr("WARNING"), Utility.GetResourceStr("SELECTWARNING", "DELETE")); ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "EDIT"), Utility.GetResourceStr("CONFIRMBUTTON")); } }
private void CancelOrderBtn_Click(object sender, RoutedEventArgs e) { string MeetingInfoID = ""; T_OA_ORDERMEAL InfoT = new T_OA_ORDERMEAL(); if (DaGr.ItemsSource != null) { foreach (object obj in DaGr.ItemsSource) { if (DaGr.Columns[0].GetCellContent(obj) != null) { CheckBox cb1 = DaGr.Columns[0].GetCellContent(obj).FindName("myChkBox") as CheckBox; //cb为 if (cb1.IsChecked == true) { InfoT = cb1.Tag as T_OA_ORDERMEAL; break; } } } } if (!string.IsNullOrEmpty(InfoT.ORDERMEALID)) { string Result = ""; SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow com = new SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow(); com.OnSelectionBoxClosed += (obj, result) => { if (InfoT != null) { try { tmpOrderInfoT = InfoT; tmpOrderInfoT.ORDERMEALFLAG = "0"; tmpOrderInfoT.UPDATEDATE = System.DateTime.Now; tmpOrderInfoT.UPDATEUSERID = "1"; OrderMealClient.OrderMealInfoUpdateCompleted += new EventHandler <OrderMealInfoUpdateCompletedEventArgs>(OrderMealClient_OrderMealInfoUpdateCompleted); OrderMealClient.OrderMealInfoUpdateAsync(tmpOrderInfoT); } catch (Exception ex) { //com.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow.titlename, Result); } } }; com.SelectionBox(Utility.GetResourceStr("CANCELORDERMEAL"), Utility.GetResourceStr("CANCELORDERMEAL"), SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow.titlename, Result); } else { //MessageBox.Show("请您选择需要删除的数据!"); Utility.ShowCustomMessage(MessageTypes.Message, Utility.GetResourceStr("WARNING"), Utility.GetResourceStr("SELECTWARNING", "CANCELORDERMEAL")); } }
//删除 private void btnDelete_Click(object sender, RoutedEventArgs e) { string OrderMealID = ""; T_OA_ORDERMEAL OrderMealInfoT = new T_OA_ORDERMEAL(); if (DaGr.ItemsSource != null) { foreach (object obj in DaGr.ItemsSource) { if (DaGr.Columns[0].GetCellContent(obj) != null) { CheckBox cb1 = DaGr.Columns[0].GetCellContent(obj).FindName("myChkBox") as CheckBox; //cb为 if (cb1.IsChecked == true) { OrderMealInfoT = cb1.Tag as T_OA_ORDERMEAL; //OrderMealID += OrderMealInfoT.ORDERMEALID + ","; OrderMealID = OrderMealInfoT.ORDERMEALID; DelInfosList.Add(OrderMealID); //MeetingInfoID += cb1.Tag.ToString() + ","; } } } } if (DelInfosList.Count() > 0) { string Result = ""; SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow com = new SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow(); com.OnSelectionBoxClosed += (obj, result) => { if (DelInfosList != null) { try { OrderMealClient.OrderMealInfoDelAsync(DelInfosList); } catch (Exception ex) { //com.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow.titlename, Result); } } }; com.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow.titlename, Result); } else { Utility.ShowCustomMessage(MessageTypes.Message, Utility.GetResourceStr("WARNING"), Utility.GetResourceStr("SELECTWARNING", "DELETE")); } }
void btnDelete_Click(object sender, RoutedEventArgs e) { string Result = ""; if (Perm != null) { ComfirmWindow com = new ComfirmWindow(); com.OnSelectionBoxClosed += (obj, result) => { ServiceClient.EntityMenuCustomPermDeleteAsync(Perm.ENTITYMENUCUSTOMPERMID); }; com.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), ComfirmWindow.titlename, Result); } else { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTDATAALERT"), Utility.GetResourceStr("CONFIRMBUTTON")); } }
private void JoinMeetingBtn_Click(object sender, RoutedEventArgs e) { Button ConfirmBtn = sender as Button; V_MyMeetingInfosManagement MeetingV = ConfirmBtn.Tag as V_MyMeetingInfosManagement; T_OA_MEETINGSTAFF StaffT = new T_OA_MEETINGSTAFF(); StaffT = MeetingV.OAMeetingStaffT; DateTime DtNow = System.DateTime.Now; DateTime DtStart = Convert.ToDateTime(MeetingV.OAMeetingInfoT.STARTTIME); if (DtStart >= Convert.ToDateTime(MeetingV.OAMeetingInfoT.ENDTIME)) { Utility.ShowCustomMessage(MessageTypes.Message, Utility.GetResourceStr("CAUTION"), Utility.GetResourceStr("NOWGREATEENDNOTJOIN")); return; } if (DtNow >= DtStart) { //确认时间超过或等于会议开始时间 Utility.ShowCustomMessage(MessageTypes.Message, Utility.GetResourceStr("CAUTION"), Utility.GetResourceStr("NOWGREATESTARTNOJOIN")); return; } else { string Result = ""; SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow com = new SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow(); com.OnSelectionBoxClosed += (obj, result) => { try { FrmConfirmJoinMeeting form = new FrmConfirmJoinMeeting(MeetingV); EntityBrowser browser = new EntityBrowser(form); browser.MinHeight = 570; browser.MinWidth = 580; browser.ReloadDataEvent += new EntityBrowser.refreshGridView(browser_ReloadDataEvent); browser.Show <string>(DialogMode.Default, Common.ParentLayoutRoot, "", (result1) => { }, true); } catch (Exception ex) { //com.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow.titlename, Result); } }; com.SelectionBox(Utility.GetResourceStr("JOINMEETINGCONFIRM"), Utility.GetResourceStr("JOINMEETINGCONFIRM"), SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow.titlename, Result); } }
void btnDelete_Click(object sender, RoutedEventArgs e) { if (Permission != null) { string Result = ""; ComfirmWindow com = new ComfirmWindow(); com.OnSelectionBoxClosed += (obj, result) => { ServiceClient.SysPermissionDeleteAsync(Permission.PERMISSIONID); }; com.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), ComfirmWindow.titlename, Result); } else { ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("ERROR"), "请选择需要删除的记录", Utility.GetResourceStr("CONFIRM"), MessageIcon.Exclamation); } }
public void DoAction(string actionType) { switch (actionType) { case "0": refreshType = RefreshedTypes.All; Save(); break; case "3": string Result = ""; ComfirmWindow com = new ComfirmWindow(); com.OnSelectionBoxClosed += (obj, result) => { bool FBControl = true; ObservableCollection<string> businesstripId = new ObservableCollection<string>();//出差申请ID businesstripId.Add(Master_Golbal.BUSINESSTRIPID); this.RefreshUI(RefreshedTypes.ShowProgressBar); OaPersonOfficeClient.DeleteTravelmanagementAsync(businesstripId, FBControl); }; com.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), "确认是否删除此条记录?", ComfirmWindow.titlename, Result); break; } }
private void btnDelete_Click(object sender, RoutedEventArgs e) { selectDeleteList = GetSelectList(); if (selectDeleteList != null && selectDeleteList.Count > 0) { for (int i = 0; i < dg.SelectedItems.Count; i++) { conservationrecordInfo = selectDeleteList[i]; if (conservationrecordInfo.CHECKSTATE == ((int)CheckStates.UnSubmit).ToString()) { string Result = ""; SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow com = new SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow(); com.OnSelectionBoxClosed += (obj, result) => { if (selectDeleteList != null) { try { _VM.Del_VCRecordsAsync(selectDeleteList); } catch { } } }; com.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow.titlename, Result); } else { Utility.ShowCustomMessage(MessageTypes.Error, Utility.GetResourceStr("ERROR"), Utility.GetResourceStr("NOTONLYDIDNOSUBMITANDREVIEWTHEDATACANBEDELETEDBY")); return; } } } else { Utility.ShowCustomMessage(MessageTypes.Message, Utility.GetResourceStr("WARNING"), Utility.GetResourceStr("SELECTWARNING", "DELETE")); } }
private void btnDelete_Click(object sender, RoutedEventArgs e) { ObservableCollection<T_SYS_ROLE> selectItemList = new ObservableCollection<T_SYS_ROLE>(); foreach (object obj in DtGrid.SelectedItems) { if (((T_SYS_ROLE)obj).CHECKSTATE == ((int)CheckStates.UnSubmit).ToString()) { selectItemList.Add((T_SYS_ROLE)obj); } else { string strState = ((T_SYS_ROLE)obj).CHECKSTATE; switch (strState) { case "1": ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("TIPS"), "不能删除审核中的数据", Utility.GetResourceStr("CONFIRM"), MessageIcon.Exclamation); break; case "2": ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("TIPS"), "不能删除审核通过的数据", Utility.GetResourceStr("CONFIRM"), MessageIcon.Exclamation); break; case "3": ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("TIPS"), "不能删除审核不通过的数据", Utility.GetResourceStr("CONFIRM"), MessageIcon.Exclamation); break; } return; } } if (selectItemList == null) { //ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "DELETE"), Utility.GetResourceStr("CONFIRMBUTTON")); ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("TIPS"), Utility.GetResourceStr("SELECTERROR", "DELETE"), Utility.GetResourceStr("CONFIRM"), MessageIcon.Exclamation); return; } string Result = ""; ComfirmWindow com = new ComfirmWindow(); com.OnSelectionBoxClosed += (objcom, result) => { if (selectItemList.Count > 0) { try { string StrTip = ""; int i = 0; bool IsTrue = true; foreach (object obj in selectItemList) { if (!(SMT.SaaS.FrameworkUI.Common.Utility.ToolBarButtonOperationPermission((T_SYS_ROLE)obj, "T_SYS_ROLEAPP", OperationType.Delete, Common.CurrentLoginUserInfo.EmployeeID))) { //StrTip = "您不能删除您选中的第" + (i + 1).ToString() + "条,标题为" + ((T_SYS_ROLE)obj).APPROVALTITLE + "的信息"; //ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("ERROR"), StrTip, Utility.GetResourceStr("CONFIRM"), MessageIcon.Exclamation); //IsTrue = false; //return; } } //approvalManagement.DeleteApporvalListAsync(selectItemList); } catch { } } else { //Utility.ShowCustomMessage(MessageTypes.Error, Utility.GetResourceStr("ERROR"), Utility.GetResourceStr("NOTONLYDIDNOSUBMITANDREVIEWTHEDATACANBEDELETEDBY")); ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("TIPS"), Utility.GetResourceStr("NOTONLYDIDNOSUBMITANDREVIEWTHEDATACANBEDELETEDBY"), Utility.GetResourceStr("CONFIRM"), MessageIcon.Exclamation); } }; com.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), ComfirmWindow.titlename, Result); }
//删除 private void btnDelete_Click(object sender, RoutedEventArgs e) { ObservableCollection<T_OA_MAINTENANCERECORD> selectInfoList = GetSelectList(); if (selectInfoList != null && selectInfoList.Count > 0) { for (int i = 0; i < dg.SelectedItems.Count; i++) { maintenancerecord = selectInfoList[i]; if (maintenancerecord.CHECKSTATE == ((int)CheckStates.UnSubmit).ToString()) { string Result = ""; ComfirmWindow com = new ComfirmWindow(); com.OnSelectionBoxClosed += (obj, result) => { try { maWS.Del_VMRecordAsync(selectInfoList); } catch { } }; com.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), ComfirmWindow.titlename, Result); } else { Utility.ShowCustomMessage(MessageTypes.Error, Utility.GetResourceStr("ERROR"), Utility.GetResourceStr("NOTONLYDIDNOSUBMITANDREVIEWTHEDATACANBEDELETEDBY")); return; } } } else ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "DELETE"), Utility.GetResourceStr("CONFIRMBUTTON")); }
private void btnDelete_Click(object sender, RoutedEventArgs e) { selectDeleteList = GetSelectList(); if (selectDeleteList != null && selectDeleteList.Count > 0) { for (int i = 0; i < dg.SelectedItems.Count; i++) { conservationrecordInfo = selectDeleteList[i]; if (conservationrecordInfo.CHECKSTATE == ((int)CheckStates.UnSubmit).ToString()) { string Result = ""; SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow com = new SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow(); com.OnSelectionBoxClosed += (obj, result) => { if (selectDeleteList != null) { try {_VM.Del_VCRecordsAsync(selectDeleteList);} catch { } } }; com.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow.titlename, Result); } else { Utility.ShowCustomMessage(MessageTypes.Error, Utility.GetResourceStr("ERROR"), Utility.GetResourceStr("NOTONLYDIDNOSUBMITANDREVIEWTHEDATACANBEDELETEDBY")); return; } } } else { Utility.ShowCustomMessage(MessageTypes.Message, Utility.GetResourceStr("WARNING"), Utility.GetResourceStr("SELECTWARNING", "DELETE")); } }
void btnDelete_Click(object sender, RoutedEventArgs e) { string Result = ""; string strMsg = ""; if (SelectDepartment != null) { if (SelectDepartment.CHECKSTATE != Convert.ToInt32(CheckStates.UnSubmit).ToString()) { ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("CAUTION"), Utility.GetResourceStr("Msg_NoDeleteOrder"), Utility.GetResourceStr("CONFIRM"), MessageIcon.Exclamation); return; } //if (!SMT.SaaS.FrameworkUI.Common.Utility.ToolBarButtonOperationPermission(SelectDepartment, "T_HR_DEPARTMENT", SMT.SaaS.FrameworkUI.OperationType.Delete, SMT.SAAS.Main.CurrentContext.Common.CurrentLoginUserInfo.EmployeeID)) //{ // ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("CAUTION"), Utility.GetResourceStr("NODELETEPERMISSION", SelectDepartment.T_HR_DEPARTMENTDICTIONARY.DEPARTMENTNAME), // Utility.GetResourceStr("CONFIRM"), MessageIcon.Exclamation); // return; //} ComfirmWindow com = new ComfirmWindow(); com.OnSelectionBoxClosed += (obj, result) => { client.DepartmentDeleteAsync(SelectDepartment.DEPARTMENTID, strMsg); }; com.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), ComfirmWindow.titlename, Result); } else { //Utility.ShowCustomMessage(MessageTypes.Caution, Utility.GetResourceStr("ERROR"), Utility.GetResourceStr("SELECTERROR", "DELETE")); ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "DELETE"), Utility.GetResourceStr("CONFIRM"), MessageIcon.Exclamation); } }
private void btnDelete_Click(object sender, RoutedEventArgs e) { if (DaGr.SelectedItems.Count > 0) { string Result = ""; DelInfosList = new ObservableCollection<string>(); ComfirmWindow com = new ComfirmWindow(); com.OnSelectionBoxClosed += (obj, result) => { string StrTip = ""; for (int i = 0; i < DaGr.SelectedItems.Count; i++) { T_OA_SENDDOCTYPE doctype = new T_OA_SENDDOCTYPE(); doctype =DaGr.SelectedItems[i] as T_OA_SENDDOCTYPE; if (!(SMT.SaaS.FrameworkUI.Common.Utility.ToolBarButtonOperationPermission(doctype, "OABUMFDOCTYPE", OperationType.Delete, Common.CurrentLoginUserInfo.EmployeeID))) { StrTip = "您不能删除您选中的第" + (i + 1).ToString() + "条,标题为" + doctype.SENDDOCTYPE + "的信息"; ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("ERROR"), StrTip, Utility.GetResourceStr("CONFIRM"), MessageIcon.Exclamation); return; } string DocTypeID = ""; DocTypeID = (DaGr.SelectedItems[i] as T_OA_SENDDOCTYPE).SENDDOCTYPEID; if (!(DelInfosList.IndexOf(DocTypeID) > -1)) { DelInfosList.Add(DocTypeID); } } if(DelInfosList.Count >0) BumfClient.DocTypeBatchDelAsync(DelInfosList); else ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("TIPS"), "删除记录不能为空", Utility.GetResourceStr("CONFIRM"), MessageIcon.Exclamation); }; com.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), ComfirmWindow.titlename, Result); } else { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "DELETE"), Utility.GetResourceStr("CONFIRMBUTTON")); } }
void client_EmployeeIsEntryCompleted(object sender, EmployeeIsEntryCompletedEventArgs e) { if (e.Error != null && e.Error.Message != "") { //// 黑名单存在 //if (e.Error.Message == "BLACKLISTEXIST") // Utility.ShowCustomMessage(MessageTypes.Error, Utility.GetResourceStr("ERROR"), Utility.GetResourceStr("BLACKLISTEXIST")); ////离职 //else if (e.Error.Message == "EMPLOYEELEAVE") // Utility.ShowCustomMessage(MessageTypes.Error, Utility.GetResourceStr("ERROR"), Utility.GetResourceStr("EMPLOYEELEAVE")); //else ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("ERROR"), Utility.GetResourceStr("ERRORINFO"), Utility.GetResourceStr("CONFIRM"), MessageIcon.Error); } else { if (!string.IsNullOrEmpty(e.blackMessage)) { if (e.blackMessage != "0") { //Utility.ShowCustomMessage(MessageTypes.Error, Utility.GetResourceStr("ERROR"), Utility.GetResourceStr("BLACKLISTEXIST")); ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("CAUTION"), Utility.GetResourceStr("BLACKLISTEXIST"), Utility.GetResourceStr("CONFIRM"), MessageIcon.Exclamation); return; } } if (e.Result == false) { //Utility.ShowCustomMessage(MessageTypes.Error, Utility.GetResourceStr("ERROR"), Utility.GetResourceStr("已经在职")); ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("CAUTION"), Utility.GetResourceStr("已经在职"), Utility.GetResourceStr("CONFIRM"), MessageIcon.Exclamation); return; } if (e.leaveMessage.Count > 0) { leaveMessage.Clear(); leaveMessage.Add(e.leaveMessage[0]); leaveMessage.Add(e.leaveMessage[1]); if (!string.IsNullOrEmpty(e.leaveMessage[1])) { if (e.leaveMessage[1] == "LessThan") { string Result = ""; SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow com = new SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow(); com.OnSelectionBoxClosed += (obj, result) => { RefreshUI(); }; com.SelectionBox(Utility.GetResourceStr("WARING"), Utility.GetResourceStr("离职未满6个月,确定要入职吗?"), SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow.titlename, Result); } else if (e.leaveMessage[1] == "LimitEntry") { ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("CAUTION"), Utility.GetResourceStr("该身份证号已存在未提交或审核中的入职记录,请处理完后再入职."), Utility.GetResourceStr("CONFIRM"), MessageIcon.Exclamation); } else if (e.leaveMessage[1] == "UnApproved") { ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("CAUTION"), Utility.GetResourceStr("该身份证号已存在审核未通过的入职记录,请直接进行重新提交操作."), Utility.GetResourceStr("CONFIRM"), MessageIcon.Exclamation); } } else { RefreshUI(); } } else { RefreshUI(); } } }
void btnCreate_Click(object sender, RoutedEventArgs e) { if (dgAttSolAsignList.SelectedItems.Count > 0) { // T_HR_LEFTOFFICE temp = DtGrid.SelectedItems[0] as T_HR_LEFTOFFICE; T_HR_NOATTENDCARDEMPLOYEES tempview = dgAttSolAsignList.SelectedItems[0] as T_HR_NOATTENDCARDEMPLOYEES; if (tempview.CHECKSTATE == Convert.ToInt32(CheckStates.Approved).ToString()) { ComfirmWindow delComfirm = new ComfirmWindow(); delComfirm.OnSelectionBoxClosed += (obj, result) => { tempview.CHECKSTATE = "0"; clientAtt.UpdateNoAttendCardEmployeesRdAsync(tempview); }; string Result = ""; delComfirm.SelectionBox(Utility.GetResourceStr("确认"), Utility.GetResourceStr("请确认是否取消免打卡员工设置,确认后即刻生效不需要审核"), ComfirmWindow.titlename, Result); } else { ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("免打卡人员名单未审核通过,不能取消"), Utility.GetResourceStr("CONFIRM"), MessageIcon.Exclamation); } } else { //ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTDATAALERT"), Utility.GetResourceStr("CONFIRMBUTTON")); ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTDATAALERT"), Utility.GetResourceStr("CONFIRM"), MessageIcon.Exclamation); } }
private void Delete_Click(object sender, RoutedEventArgs e) { dg.ItemsSource = null; ObservableCollection<string> o = new ObservableCollection<string>(); T_OA_VEHICLEUSEAPP i = ((Button)sender).DataContext as T_OA_VEHICLEUSEAPP; o.Add(i.VEHICLEUSEAPPID); if (_lstVUseApp_Add.Contains(i)) { _lstVUseApp_Add.Remove(i); _lstVUseApp.Remove(i); } else if (_lstVUseApp.Contains(i)) { ComfirmWindow com = new ComfirmWindow(); if (_lstVUseApp.Count > 1) //不能为空 { string Result = ""; com.OnSelectionBoxClosed += (obj, result) => { _VM.Del_VDDetailsAsync(o); _lstVUseApp.Remove(i); }; com.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), ComfirmWindow.titlename, Result); } else ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("ERROR_VDUSEAPP"), Utility.GetResourceStr("CONFIRMBUTTON")); } dg.ItemsSource = _lstVUseApp; }
void btnDelete_Click(object sender, RoutedEventArgs e) { string Result = ""; if (DtGrid.SelectedItems.Count > 0) { ComfirmWindow com = new ComfirmWindow(); com.OnSelectionBoxClosed += (obj, result) => { ObservableCollection<string> ids = new ObservableCollection<string>(); foreach (T_HR_EMPLOYEECONTRACT tmp in DtGrid.SelectedItems) { if (tmp.CHECKSTATE != Convert.ToInt32(CheckStates.UnSubmit).ToString()) { ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("CAUTION"), Utility.GetResourceStr("Msg_NoDeleteOrder"), Utility.GetResourceStr("CONFIRM"), MessageIcon.Exclamation); break; } //if (!SMT.SaaS.FrameworkUI.Common.Utility.ToolBarButtonOperationPermission(tmp, "T_HR_EMPLOYEECONTRACT", SMT.SaaS.FrameworkUI.OperationType.Delete, SMT.SAAS.Main.CurrentContext.Common.CurrentLoginUserInfo.EmployeeID)) //{ // ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("CAUTION"), Utility.GetResourceStr("NOPERMISSIONDELETE", tmp.T_HR_EMPLOYEE.EMPLOYEECNAME + ",CONTRACTINFORMATION"), // Utility.GetResourceStr("CONFIRM"), MessageIcon.Exclamation); // return; //} ids.Add(tmp.EMPLOYEECONTACTID); } client.EmployeeContractDeleteAsync(ids); }; com.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), ComfirmWindow.titlename, Result); } else { //Utility.ShowCustomMessage(MessageTypes.Error, Utility.GetResourceStr("ERROR"), Utility.GetResourceStr("SELECTERROR", "DELETE")); ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "DELETE"), Utility.GetResourceStr("CONFIRM"), MessageIcon.Exclamation); } }
void btnDelete_Click(object sender, RoutedEventArgs e) { string Result = ""; string strMsg = string.Empty; if (DtGrid.SelectedItems.Count > 0) { //判断是否可以删除 ObservableCollection<string> ids = new ObservableCollection<string>(); foreach (T_HR_DEPARTMENTDICTIONARY tmp in DtGrid.SelectedItems) { if (tmp.CHECKSTATE != Convert.ToInt32(CheckStates.UnSubmit).ToString()) { ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("CAUTION"), Utility.GetResourceStr("Msg_NoDeleteOrder"), Utility.GetResourceStr("CONFIRM"), MessageIcon.Exclamation); return; } ids.Add(tmp.DEPARTMENTDICTIONARYID); } //提示是否删除 ComfirmWindow com = new ComfirmWindow(); com.OnSelectionBoxClosed += (obj, result) => { svc.DepartmentDictionaryDeleteAsync(ids, strMsg); }; com.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), ComfirmWindow.titlename, Result); } else { ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "DELETE"), Utility.GetResourceStr("CONFIRM"), MessageIcon.Exclamation); } }
void btnDelete_Click(object sender, RoutedEventArgs e) { #region ----- string Result = ""; if (DtGrid.SelectedItems.Count > 0) { V_COMPLAINRECORD tmpEnt = DtGrid.SelectedItems[0] as V_COMPLAINRECORD; if (tmpEnt.T_HR_KPIRECORDCOMPLAIN.CHECKSTATE == "0" || tmpEnt.T_HR_KPIRECORDCOMPLAIN.CHECKSTATE == "3") { System.Collections.ObjectModel.ObservableCollection<string> ids = new System.Collections.ObjectModel.ObservableCollection<string>(); foreach (V_COMPLAINRECORD tmp in DtGrid.SelectedItems) { ids.Add(tmp.T_HR_KPIRECORDCOMPLAIN.COMPLAINID); } ComfirmWindow com = new ComfirmWindow(); com.OnSelectionBoxClosed += (obj, result) => { client.ComplainRecordDeleteAsync(ids); }; com.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), ComfirmWindow.titlename, Result); } else { //Utility.ShowCustomMessage(MessageTypes.Error, Utility.GetResourceStr("ERROR"), Utility.GetResourceStr("NOTDELETE")); ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("CAUTION"), Utility.GetResourceStr("NOTDELETE"), Utility.GetResourceStr("CONFIRM"), MessageIcon.Exclamation); } } else { //Utility.ShowCustomMessage(MessageTypes.Error, Utility.GetResourceStr("ERROR"), Utility.GetResourceStr("SELECTERROR", "DELETE")); ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "DELETE"), Utility.GetResourceStr("CONFIRM"), MessageIcon.Exclamation); } #endregion }
/// <summary> /// 退房 /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void FrmHouseInfoManagement_Click(object sender, RoutedEventArgs e) { if (Househireapp != null) { if (Househireapp.houseAppObj.ISOK == "0") { //没有入住不能进行退房操作 Utility.ShowCustomMessage(MessageTypes.Message, Utility.GetResourceStr("WARING"), Utility.GetResourceStr("NOCOMEINCANNOTCHECKOUT")); return; } else { if (Househireapp.houseAppObj.ISBACK == "1") { Utility.ShowCustomMessage(MessageTypes.Message, Utility.GetResourceStr("WARING"), Utility.GetResourceStr("THEHOUSEISBACK")); return; } else { string Result = ""; SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow com = new SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow(); com.OnSelectionBoxClosed += (obj, result1) => { HouseHireAppForm form = new HouseHireAppForm(Action.Return, Househireapp.houseAppObj.HIREAPPID, checkState, "2"); EntityBrowser browser = new EntityBrowser(form); browser.ReloadDataEvent += new EntityBrowser.refreshGridView(browser_ReloadDataEvent); browser.Show <string>(DialogMode.Default, Common.ParentLayoutRoot, "", (result) => { }); }; com.SelectionBox(Utility.GetResourceStr("OUTHOUSECONFIRM"), Utility.GetResourceStr("OUTHOUSEALTER"), SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow.titlename, Result); } } } else { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "CHECKOUTHIRE"), Utility.GetResourceStr("CONFIRMBUTTON")); } //if (dgHireApp.SelectedItems.Count > 0) //{ // string Result = ""; // houseDelID = new ObservableCollection<string>(); //} //else //{ // ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "DELETE"), Utility.GetResourceStr("CONFIRMBUTTON")); //} ////ObservableCollection<string> hireAppID = GridHelper.GetSelectItem(dgHireApp, "myChkBox", Action.Edit); //T_OA_HIREAPP HireAppT = new T_OA_HIREAPP(); //V_HouseHireApp vApp = new V_HouseHireApp(); //if (dgHireApp.ItemsSource != null) //{ // foreach (object obj in dgHireApp.ItemsSource) // { // if (dgHireApp.Columns[0].GetCellContent(obj) != null) // { // CheckBox cb1 = dgHireApp.Columns[0].GetCellContent(obj).FindName("myChkBox") as CheckBox; //cb为 // if (cb1.IsChecked == true) // { // vApp = cb1.Tag as V_HouseHireApp; // HireAppT = vApp.houseAppObj; // break; // } // } // } //} //if (!string.IsNullOrEmpty(HireAppT.HIREAPPID)) //{ // if (HireAppT.ISOK == "0") // { // //没有入住不能进行退房操作 // Utility.ShowCustomMessage(MessageTypes.Message, Utility.GetResourceStr("WARING"), Utility.GetResourceStr("NOCOMEINCANNOTCHECKOUT")); // return; // } // else // { // if (HireAppT.ISBACK == "1") // { // Utility.ShowCustomMessage(MessageTypes.Message, Utility.GetResourceStr("WARING"), Utility.GetResourceStr("THEHOUSEISBACK")); // return; // } // else // { // string Result = ""; // SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow com = new SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow(); // com.OnSelectionBoxClosed += (obj, result1) => // { // HouseHireAppForm form = new HouseHireAppForm(Action.Return, HireAppT.HIREAPPID, checkState, "2"); // EntityBrowser browser = new EntityBrowser(form); // browser.ReloadDataEvent += new EntityBrowser.refreshGridView(browser_ReloadDataEvent); // browser.Show<string>(DialogMode.Default, Common.ParentLayoutRoot, "", (result) => { }); // }; // com.SelectionBox(Utility.GetResourceStr("OUTHOUSECONFIRM"), Utility.GetResourceStr("OUTHOUSEALTER"), SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow.titlename, Result); // } // } //} //else //{ // ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "CHECKOUTHIRE"), Utility.GetResourceStr("CONFIRMBUTTON")); //} }
/// <summary> /// 入住 /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void FrmHouseComein_Click(object sender, RoutedEventArgs e) { if (Househireapp != null) { if (Househireapp.houseAppObj.ISOK == "1") { Utility.ShowCustomMessage(MessageTypes.Message, Utility.GetResourceStr("WARING"), Utility.GetResourceStr("THEHOUSEISCOMEIN")); return; } else { string Result = ""; SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow com = new SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow(); com.OnSelectionBoxClosed += (obj, result1) => { //添加租赁记录并将,出租申请的标志改为确定入住 HouseHireAppForm form = new HouseHireAppForm(Action.Edit, Househireapp.houseAppObj.HIREAPPID, checkState, "1"); EntityBrowser browser = new EntityBrowser(form); browser.MinHeight = 500; browser.ReloadDataEvent += new EntityBrowser.refreshGridView(browser_ReloadDataEvent); browser.Show <string>(DialogMode.Default, Common.ParentLayoutRoot, "", (result) => { }, true); }; com.SelectionBox(Utility.GetResourceStr("COMEINHOUSECONFIRM"), Utility.GetResourceStr("COMEINHOUSEALTER"), SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow.titlename, Result); } } else { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "COMEINHIREHOUSE"), Utility.GetResourceStr("CONFIRMBUTTON")); } //T_OA_HIREAPP HireAppT = new T_OA_HIREAPP(); //V_HouseHireApp vApp = new V_HouseHireApp(); //if (dgHireApp.ItemsSource != null) //{ // foreach (object obj in dgHireApp.ItemsSource) // { // if (dgHireApp.Columns[0].GetCellContent(obj) != null) // { // CheckBox cb1 = dgHireApp.Columns[0].GetCellContent(obj).FindName("myChkBox") as CheckBox; //cb为 // if (cb1.IsChecked == true) // { // vApp = cb1.Tag as V_HouseHireApp; // HireAppT = vApp.houseAppObj; // break; // } // } // } //} //if (!string.IsNullOrEmpty(HireAppT.HIREAPPID)) //{ // if (HireAppT.ISOK == "1") // { // Utility.ShowCustomMessage(MessageTypes.Message, Utility.GetResourceStr("WARING"), Utility.GetResourceStr("THEHOUSEISCOMEIN")); // return; // } // else // { // string Result = ""; // SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow com = new SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow(); // com.OnSelectionBoxClosed += (obj, result1) => // { // //添加租赁记录并将,出租申请的标志改为确定入住 // HouseHireAppForm form = new HouseHireAppForm(Action.Edit, HireAppT.HIREAPPID, checkState, "1"); // EntityBrowser browser = new EntityBrowser(form); // browser.MinHeight = 500; // browser.ReloadDataEvent += new EntityBrowser.refreshGridView(browser_ReloadDataEvent); // browser.Show<string>(DialogMode.Default, Common.ParentLayoutRoot, "", (result) => { }, true); // }; // com.SelectionBox(Utility.GetResourceStr("COMEINHOUSECONFIRM"), Utility.GetResourceStr("COMEINHOUSEALTER"), SMT.SaaS.FrameworkUI.ChildWidow.ComfirmWindow.titlename, Result); // } //} //else //{ // ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "COMEINHIREHOUSE"), Utility.GetResourceStr("CONFIRMBUTTON")); //} }
private void btnCancelSubmit_Click(object sender, RoutedEventArgs e) { ComfirmWindow com = new ComfirmWindow(); com.OnSelectionBoxClosed += (obj, result) => { this.HandIn(AuditOperation.Cancel, AuditAction.Pass); }; com.SelectionBox("确定撤单", "确定撤单吗?", ComfirmWindow.titlename, ""); }
/// <summary> /// 删除指定的带薪假设置(物理删除,待定) /// </summary> /// <param name="sender"></param> /// <param name="e"></param> void btnDelete_Click(object sender, RoutedEventArgs e) { string strID = ""; if (dgFreeLeaveDaySetList.SelectedItems == null) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "DELETE"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } if (dgFreeLeaveDaySetList.SelectedItems.Count == 0) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "DELETE"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } foreach (object ovj in dgFreeLeaveDaySetList.SelectedItems) { T_HR_FREELEAVEDAYSET ent = ovj as T_HR_FREELEAVEDAYSET; string Result = ""; if (ent != null) { strID = ent.FREELEAVEDAYSETID.ToString(); ComfirmWindow delComfirm = new ComfirmWindow(); delComfirm.OnSelectionBoxClosed += (obj, result) => { clientAtt.RemoveFreeLeaveDaySetAsync(strID); }; delComfirm.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), ComfirmWindow.titlename, Result); } } }
void btnDelete_Click(object sender, RoutedEventArgs e) { agentsetId = new ObservableCollection<string>(); if (DaGr.SelectedItems.Count > 0) { for (int i = 0; i < DaGr.SelectedItems.Count; i++) { T_OA_AGENTSET ent = DaGr.SelectedItems[i] as T_OA_AGENTSET; agentsetId.Add((DaGr.SelectedItems[i] as T_OA_AGENTSET).AGENTSETID); string Result = ""; ComfirmWindow com = new ComfirmWindow(); com.OnSelectionBoxClosed += (obj, result) => { SoaChannel.DeleteAgentSetAsync(agentsetId); LoadData(); }; com.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), ComfirmWindow.titlename, Result); } } else { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "DELETE"), Utility.GetResourceStr("CONFIRMBUTTON")); } }
/// <summary> /// 2012-8-24 /// xiedx /// 初始化按钮 /// </summary> void _ImgButtonExecuteSalaryItemSql_Click(object sender, RoutedEventArgs e) { string Result = ""; ComfirmWindow com = new ComfirmWindow(); T_HR_SALARYITEM temp = new T_HR_SALARYITEM(); temp.SALARYITEMID = Guid.NewGuid().ToString(); if (string.IsNullOrWhiteSpace(companyID)) { temp.OWNERCOMPANYID = SMT.SAAS.Main.CurrentContext.Common.CurrentLoginUserInfo.UserPosts[0].CompanyID; companyName = SMT.SAAS.Main.CurrentContext.Common.CurrentLoginUserInfo.UserPosts[0].CompanyName; } else { temp.OWNERCOMPANYID = companyID; } temp.OWNERDEPARTMENTID = SMT.SAAS.Main.CurrentContext.Common.CurrentLoginUserInfo.UserPosts[0].DepartmentID; temp.OWNERPOSTID = SMT.SAAS.Main.CurrentContext.Common.CurrentLoginUserInfo.UserPosts[0].PostID; temp.OWNERID = SMT.SAAS.Main.CurrentContext.Common.CurrentLoginUserInfo.EmployeeID; temp.UPDATEUSERID = SMT.SAAS.Main.CurrentContext.Common.CurrentLoginUserInfo.EmployeeID; com.OnSelectionBoxClosed += (obj, result) => { ObservableCollection<string> ids = new ObservableCollection<string>(); client.ExecuteSalaryItemSqlAsync(temp); }; com.SelectionBox(Utility.GetResourceStr("CAUTION"), "该选项会初始化 "+companyName+" 的薪资,请向相关部门确认先", ComfirmWindow.titlename, Result); }
public void delete(string strid) { string Result = ""; string strMsg = string.Empty; //提示是否删除 ComfirmWindow com = new ComfirmWindow(); com.OnSelectionBoxClosed += (obj, result) => { client.DepartmentDeleteAsync(strid, strMsg); }; com.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("确定要删除该部门信息?"), ComfirmWindow.titlename, Result); }
void btnDelete_Click(object sender, RoutedEventArgs e) { //ComfirmBox deleComfir = new ComfirmBox(); //deleComfir.Title = Utility.GetResourceStr("DELETECONFIRM"); //deleComfir.MessageTextBox.Text = Utility.GetResourceStr("DELETEALTER"); //deleComfir.ButtonOK.Click += new RoutedEventHandler(ButtonOK1_Click); //deleComfir.Show(); string Result = ""; if (DtGrid.SelectedItems.Count > 0) { ObservableCollection<string> ids = new ObservableCollection<string>(); foreach (T_HR_SALARYITEM tmp in DtGrid.SelectedItems) { ids.Add(tmp.SALARYITEMID); } ComfirmWindow com = new ComfirmWindow(); com.OnSelectionBoxClosed += (obj, result) => { client.SalaryItemSetDeleteAsync(ids); }; com.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), ComfirmWindow.titlename, Result); } else { ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("ERROR"), Utility.GetResourceStr("SELECTERROR", "DELETE"), Utility.GetResourceStr("CONFIRM"), MessageIcon.Exclamation); //Utility.ShowCustomMessage(MessageTypes.Error, Utility.GetResourceStr("ERROR"), Utility.GetResourceStr("SELECTERROR", "DELETE")); } }
/// <summary> /// 删除指定考勤方案应用记录(物理删除,待定) /// </summary> /// <param name="sender"></param> /// <param name="e"></param> void btnDelete_Click(object sender, RoutedEventArgs e) { string strID = ""; if (dgAttSolAsignList.SelectedItems == null) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "DELETE"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } if (dgAttSolAsignList.SelectedItems.Count == 0) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "DELETE"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } ObservableCollection<string> strids = new ObservableCollection<string>(); foreach (object ovj in dgAttSolAsignList.SelectedItems) { T_HR_NOATTENDCARDEMPLOYEES ent = ovj as T_HR_NOATTENDCARDEMPLOYEES; if (ent != null) { strID = ent.NOATTENDCARDEMPLOYEESID.ToString(); if (ent.CHECKSTATE != Convert.ToInt32(CheckStates.UnSubmit).ToString()) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("DELETEAUDITERROR"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } strids.Add(strID); } } ComfirmWindow delComfirm = new ComfirmWindow(); delComfirm.OnSelectionBoxClosed += (obj, result) => { clientAtt.DeleteNoAttendCardEmployeesRdAsync(strids); }; string Result = ""; delComfirm.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), ComfirmWindow.titlename, Result); }
public void Save() { string Result = ""; ComfirmWindow com = new ComfirmWindow(); com.OnSelectionBoxClosed += (objects, result) => { RefreshUI(RefreshedTypes.ShowProgressBar); System.Collections.ObjectModel.ObservableCollection<T_HR_SALARYITEM> lists = new System.Collections.ObjectModel.ObservableCollection<T_HR_SALARYITEM>(); foreach (var ent in SalaryItemList) { lists.Add(ent); } client.FormulaTemplateAddAsync(lists); }; com.SelectionBox(Utility.GetResourceStr("SALARYITEM"), Utility.GetResourceStr("SALARYITEMDESC"), ComfirmWindow.confirmation, Result); }
//删除薪资体系设置 public void delete(string strID) { string Result = ""; //提示是否删除 ComfirmWindow com = new ComfirmWindow(); ObservableCollection<string> ids = new ObservableCollection<string>(); ids.Add(strID); com.OnSelectionBoxClosed += (obj, result) => { client.SalarySystemDeleteAsync(ids); }; com.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), ComfirmWindow.titlename, Result); }
private void BtnSet_FindClick(object sender, RoutedEventArgs e) { //string SysUserID = ""; ForbidInfosList.Add(sysUser.EMPLOYEEID); if (ForbidInfosList.Count() > 0) { string Result = ""; ComfirmWindow com = new ComfirmWindow(); com.OnSelectionBoxClosed += (obj, result) => { if (sysUser.STATE == "1") { ServiceClent.SysUserBatchUpdateAsync(ForbidInfosList, Common.CurrentLoginUserInfo.SysUserID, Common.CurrentLoginUserInfo.EmployeeName, "0"); } else { ServiceClent.SysUserBatchUpdateAsync(ForbidInfosList, Common.CurrentLoginUserInfo.SysUserID, Common.CurrentLoginUserInfo.EmployeeName, "1"); } }; if (sysUser.STATE == "1") { com.SelectionBox("禁用用户", "确定禁用用户吗?", ComfirmWindow.titlename, Result); } if (sysUser.STATE == "0") { com.SelectionBox("启用用户", "确定启用用户吗?", ComfirmWindow.titlename, Result); } } }
/// <summary> /// 删除 /// </summary> /// <param name="sender"></param> /// <param name="e"></param> void btnDelete_Click(object sender, RoutedEventArgs e) { string strID = ""; if (dgSTList.SelectedItems == null) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "DELETE"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } if (dgSTList.SelectedItems.Count == 0) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "DELETE"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } foreach (object ovj in dgSTList.SelectedItems) { T_HR_SCHEDULINGTEMPLATEMASTER entTemplateMaste = ovj as T_HR_SCHEDULINGTEMPLATEMASTER; string Result = ""; if (entTemplateMaste != null) { strID = entTemplateMaste.TEMPLATEMASTERID; ComfirmWindow delComfirm = new ComfirmWindow(); delComfirm.OnSelectionBoxClosed += (obj, result) => { clientAtt.RemoveSchedulingTemplateMasterAsync(strID); }; delComfirm.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), ComfirmWindow.titlename, Result); } } }
void btnDelete_Click(object sender, RoutedEventArgs e) { if (dgEvection.SelectedItems == null) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "DELETE"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } if (dgEvection.SelectedItems.Count == 0) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "DELETE"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } ObservableCollection<string> ids = new ObservableCollection<string>(); foreach (object ovj in dgEvection.SelectedItems) { T_HR_EMPLOYEEEVECTIONRECORD entEvection = ovj as T_HR_EMPLOYEEEVECTIONRECORD; if (entEvection != null) { ids.Add(entEvection.EVECTIONRECORDID); } } string Result = ""; if (ids.Count > 0) { ComfirmWindow delComfirm = new ComfirmWindow(); delComfirm.OnSelectionBoxClosed += (obj, result) => { client.EmployeeLeaveRecordDeleteAsync(ids); }; delComfirm.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), ComfirmWindow.titlename, Result); } }
private void btnDelete_Click(object sender, RoutedEventArgs e) { if (dgHouse.SelectedItems.Count > 0) { string Result = ""; issuanceDelID = new ObservableCollection<string>(); ComfirmWindow com = new ComfirmWindow(); com.OnSelectionBoxClosed += (obj, result) => { for (int i = 0; i < dgHouse.SelectedItems.Count; i++) { string GradeID = ""; GradeID = (dgHouse.SelectedItems[i] as T_OA_HOUSEINFOISSUANCE).ISSUANCEID; if ((dgHouse.SelectedItems[i] as T_OA_HOUSEINFOISSUANCE).CHECKSTATE == "0" || (dgHouse.SelectedItems[i] as T_OA_HOUSEINFOISSUANCE).CHECKSTATE == "3") { if (!(issuanceDelID.IndexOf(GradeID) > -1)) { issuanceDelID.Add(GradeID); } } } if (issuanceDelID.Count > 0) { client.DeleteIssuanceAsync(issuanceDelID); } else { Utility.ShowCustomMessage(MessageTypes.Message, Utility.GetResourceStr("CAUTION"), Utility.GetResourceStr("SELECTITEMSNOTDELETE")); } }; com.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), ComfirmWindow.titlename, Result); } else { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "DELETE"), Utility.GetResourceStr("CONFIRMBUTTON")); } //issuanceDelID = GridHelper.GetSelectItem(dgHouse, "myChkBox", Action.Delete); //if (issuanceDelID == null || issuanceDelID.Count == 0) //{ // //HtmlPage.Window.Alert("请先选择需要删除的房源信息记录"); // //Utility.ShowCustomMessage(MessageTypes.Message, Utility.GetResourceStr("ERROR"), Utility.GetResourceStr("SELECTERROR", "DELETE")); // ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "DELETE"), Utility.GetResourceStr("CONFIRMBUTTON")); //} //else //{ // //ComfirmBox deleComfirm = new ComfirmBox(); // //deleComfirm.Title = Utility.GetResourceStr("DELETECONFIRM"); // //deleComfirm.MessageTextBox.Text = Utility.GetResourceStr("DELETEALTER"); // //deleComfirm.ButtonOK.Click += new RoutedEventHandler(ButtonOK_Click); // //deleComfirm.Show(); // //if (HtmlPage.Window.Confirm("您确定要删除选中的房源信息记录吗?")) // //{ // // client.DeleteIssuanceAsync(issuanceDelID); // //} // string Result = ""; // ComfirmWindow com = new ComfirmWindow(); // com.OnSelectionBoxClosed += (obj, result) => // { // client.DeleteIssuanceAsync(issuanceDelID); // }; // com.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), ComfirmWindow.titlename, Result); //} }
private void btnDelect_Click(object sender, RoutedEventArgs e) { if (TimingTriggerDataGrid.SelectedItems.Count == 1) { pBar.Start(); string Result = ""; ComfirmWindow com = new ComfirmWindow(); com.OnSelectionBoxClosed += (obj, result) => { T_WF_TIMINGTRIGGERACTIVITY ent = TimingTriggerDataGrid.SelectedItem as T_WF_TIMINGTRIGGERACTIVITY; timingClient.DeleteTimingActivityAsync(ent.TRIGGERID); }; com.SelectionBox("删除确定", "你确定删除选中信息吗?", ComfirmWindow.titlename, Result); } else { ComfirmWindow.ConfirmationBox("提示信息", "请先选择一条需要删除的记录", "确定"); } }
//撤销部门 void btnCancel_Click(object sender, RoutedEventArgs e) { string Result = ""; string strMsg = ""; if (SelectDepartment != null) { if (SelectDepartment.CHECKSTATE != Convert.ToInt32(CheckStates.Approved).ToString()) { ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("ERROR"), Utility.GetResourceStr("审核通过的才能进行撤销"), Utility.GetResourceStr("CONFIRM"), MessageIcon.Exclamation); return; } if (SelectDepartment.EDITSTATE == Convert.ToInt32(EditStates.Canceled).ToString()) { ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("ERROR"), Utility.GetResourceStr("已经撤销了"), Utility.GetResourceStr("CONFIRM"), MessageIcon.Exclamation); return; } if (SelectDepartment.CHECKSTATE == Convert.ToInt32(CheckStates.Approved).ToString()) { ComfirmWindow com = new ComfirmWindow(); com.OnSelectionBoxClosed += (obj, result) => { SelectDepartment.EDITSTATE = Convert.ToInt32(EditStates.PendingCanceled).ToString(); SelectDepartment.CHECKSTATE = Convert.ToInt32(CheckStates.UnSubmit).ToString(); client.DepartmentCancelAsync(SelectDepartment, strMsg); }; com.SelectionBox(Utility.GetResourceStr("CANCELALTER"), Utility.GetResourceStr("CANCELCONFIRM"), ComfirmWindow.titlename, Result); } } else { //Utility.ShowCustomMessage(MessageTypes.Caution, Utility.GetResourceStr("ERROR"), Utility.GetResourceStr("SELECTERROR", "CANCEL")); ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "CANCEL"), Utility.GetResourceStr("CONFIRM"), MessageIcon.Exclamation); } }
void btnDelete_Click(object sender, RoutedEventArgs e) { WelfareProvisionID = new ObservableCollection<string>(); if (DaGr.SelectedItems.Count > 0) { for (int i = 0; i < DaGr.SelectedItems.Count; i++) { V_WelfareProvision ent = DaGr.SelectedItems[i] as V_WelfareProvision; if (ent.welfareProvision.CHECKSTATE == ((int)CheckStates.UnSubmit).ToString()) { WelfareProvisionID.Add((DaGr.SelectedItems[i] as V_WelfareProvision).welfareProvision.WELFAREDISTRIBUTEMASTERID); string Result = ""; ComfirmWindow com = new ComfirmWindow(); com.OnSelectionBoxClosed += (obj, result) => { BenefitsAdministration.DeleteWelfareProvisionAsync(WelfareProvisionID); LoadData(); }; com.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), ComfirmWindow.titlename, Result); } else { Utility.ShowCustomMessage(MessageTypes.Error, Utility.GetResourceStr("ERROR"), Utility.GetResourceStr("NOTONLYDIDNOSUBMITANDREVIEWTHEDATACANBEDELETEDBY")); return; } } } else { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "DELETE"), Utility.GetResourceStr("CONFIRMBUTTON")); } }