private void showEditWindow() { if (!CHelper.VerifyAccessRight(getPermissionKey("V", eType))) { return; } if (eType.Equals("1")) { String caption = CLanguage.getValue("edit") + " " + CLanguage.getValue("sale_customer"); CWinLoadParam param = new CWinLoadParam(); param.Caption = caption; param.Mode = "E"; param.ActualView = currentObj; param.ParentItemSources = itemSources; FactoryWindow.ShowWindow("WinAddEditCustomer", param); } else { String caption = CLanguage.getValue("edit") + " " + CLanguage.getValue("purchase_supplier"); CWinLoadParam param = new CWinLoadParam(); param.Caption = caption; param.Mode = "E"; param.ActualView = currentObj; param.ParentItemSources = itemSources; FactoryWindow.ShowWindow("WinAddEditSupplier", param); } }
private void cmdAdd_Click(object sender, RoutedEventArgs e) { if (!CHelper.VerifyAccessRight("PURCHASE_TAXDOC_ADD")) { return; } MenuItem mnu = (MenuItem)sender; CWinLoadParam param = new CWinLoadParam(); if (mnu.Name.Equals("mnuPP30")) { param.Caption = mnu.Header.ToString(); param.Mode = "A"; param.GenericType = "1"; param.ParentItemSources = itemSources; FactoryWindow.ShowWindow("WinAddEditTaxPP30", param); } else if (mnu.Name.Equals("mnuPP53")) { param.Caption = mnu.Header.ToString(); param.Mode = "A"; param.GenericType = "3"; param.ParentItemSources = itemSources; FactoryWindow.ShowWindow("WinAddEditTaxFormPRV3_53", param); } else if (mnu.Name.Equals("mnuPP3")) { param.Caption = mnu.Header.ToString(); param.Mode = "A"; param.GenericType = "2"; param.ParentItemSources = itemSources; FactoryWindow.ShowWindow("WinAddEditTaxFormPRV3_53", param); } }
public void ShowEditWindowEx(MVTaxDocument actDoc) { if (!CHelper.VerifyAccessRight("PURCHASE_TAXDOC_EDIT")) { return; } CWinLoadParam param = new CWinLoadParam(); TaxDocumentType dt = (TaxDocumentType)CUtil.StringToInt(actDoc.DocumentType); if (dt == TaxDocumentType.TaxDocPP30) { param.Caption = CUtil.TaxDocTypeToString(dt); param.Mode = "E"; param.ActualView = actDoc; FactoryWindow.ShowWindow("WinAddEditTaxPP30", param); } else { param.Caption = CUtil.TaxDocTypeToString(dt); param.Mode = "E"; param.GenericType = ""; param.ActualView = actDoc; FactoryWindow.ShowWindow("WinAddEditTaxFormPRV3_53", param); } }
private void cmdAdd_Click(object sender, RoutedEventArgs e) { if (!CHelper.VerifyAccessRight("HR_PAYROLL_ADD")) { return; } MenuItem mnu = (MenuItem)sender; CWinLoadParam param = new CWinLoadParam(); if (mnu.Name.Equals("mnuDaily")) { param.Caption = mnu.Header.ToString(); param.Mode = "A"; param.GenericType = "1"; param.ParentItemSources = itemSources; FactoryWindow.ShowWindow("WinAddEditPayrollDoc", param); } else if (mnu.Name.Equals("mnuMonthly")) { param.Caption = mnu.Header.ToString(); param.Mode = "A"; param.GenericType = "2"; param.ParentItemSources = itemSources; FactoryWindow.ShowWindow("WinAddEditPayrollDoc", param); } else if (mnu.Name.Equals("mnuBalance")) { param.Caption = mnu.Header.ToString(); param.Mode = "A"; param.GenericType = "0"; param.ParentItemSources = itemSources; FactoryWindow.ShowWindow("WinAddEditPayrollDoc", param); } }
private void cmdAdd_Click(object sender, RoutedEventArgs e) { if (!CHelper.VerifyAccessRight(getPermissionKey("A", eType))) { return; } if (eType.Equals("1")) { String caption = CLanguage.getValue("add") + " " + CLanguage.getValue("sale_customer"); CWinLoadParam param = new CWinLoadParam(); param.Caption = caption; param.Mode = "A"; param.ParentItemSources = itemSources; FactoryWindow.ShowWindow("WinAddEditCustomer", param); } else { String caption = CLanguage.getValue("add") + " " + CLanguage.getValue("purchase_supplier"); CWinLoadParam param = new CWinLoadParam(); param.Caption = caption; param.Mode = "A"; param.ParentItemSources = itemSources; FactoryWindow.ShowWindow("WinAddEditSupplier", param); } }
private void showEditWindow() { if (!CHelper.VerifyAccessRight("GENERAL_MASTER_VIEW")) { return; } String caption = CLanguage.getValue("edit"); CWinLoadParam param = new CWinLoadParam(); param.Caption = caption; param.GenericType = (currentViewObj as MMasterRef).RefType; param.Mode = "E"; param.ActualView = currentViewObj; Boolean isOK = FactoryWindow.ShowWindow("WinAddEditMasterRef", param); if (isOK) { refreshMasterRef(); rowCount = rowCount + 1; //lblTotal.Content = CUtil.FormatInt(rowCount.ToString()); } refreshMasterRef(); }
private void cmdAdd_Click(object sender, RoutedEventArgs e) { String caption = ItemText; if (dt == InventoryDocumentType.InvDocBorrow) { CWinLoadParam param = new CWinLoadParam(); param.Caption = (String)(sender as Button).Content + " " + caption; param.Mode = "A"; param.ActualParentView = mv; param.ActualView = currentViewObj; param.GenericType = loadParam.GenericType; vw.IsModified = FactoryWindow.ShowWindow("WinAddEditBorrowReturnItem", param); } else if (dt == InventoryDocumentType.InvDocReturn) { CCriteriaBorrowItem cr = new CCriteriaBorrowItem(); cr.SetActionEnable(false); cr.SetDefaultData(vw); cr.Init(""); WinMultiSelection w = new WinMultiSelection(cr, CLanguage.getValue("borrow_return_item")); w.ShowDialog(); if (w.IsOK) { addReturnDocItems(w.SelectedItems); vw.IsModified = true; } } }
private void showEditWindow() { if (!CHelper.VerifyAccessRight("CASH_XFER_VIEW")) { return; } MCashDocXfer v = (MCashDocXfer)currentObj; String winName = "WinAddEditCashExternalXfer"; if (v.CashXferType.Equals("1")) { winName = "WinAddEditCashTransfer"; } String caption = CLanguage.getValue("edit") + " " + CLanguage.getValue("Trans"); CWinLoadParam param = new CWinLoadParam(); param.Caption = caption; param.GenericType = ((int)docType).ToString(); param.Mode = "E"; param.ParentItemSources = itemSources; param.ActualView = currentObj; FactoryWindow.ShowWindow(winName, param); }
private void cmdAdd_Click(object sender, RoutedEventArgs e) { if (!CHelper.VerifyAccessRight("GENERAL_MASTER_ADD")) { return; } Boolean result = CHelper.ValidateComboBox(lbl, cbo, false); if (!result) { return; } MMasterRef v = (MMasterRef)cbo.SelectedItem; String caption = CLanguage.getValue("add"); CWinLoadParam param = new CWinLoadParam(); param.Caption = caption; param.GenericType = v.MasterID; param.Mode = "A"; param.ParentItemSources = (ObservableCollection <MBaseModel>)lsvMain.ItemsSource; Boolean isOK = FactoryWindow.ShowWindow("WinAddEditMasterRef", param); if (isOK) { refreshMasterRef(); rowCount = rowCount + 1; //lblTotal.Content = CUtil.FormatInt(rowCount.ToString()); } }
private void cmdAdd_Click(object sender, RoutedEventArgs e) { if (!CHelper.VerifyAccessRight("INVENTORY_ITEM_ADD")) { return; } if ((typ == 2) && (cit == null)) { CHelper.ShowErorMessage("", "ERROR_ITEM_ADD_PLS", null); return; } if ((typ == 2) && !cit.ChildCount.Equals("0")) { CHelper.ShowErorMessage(cit.CategoryName, "ERROR_NOT_LAST_CHILD", null); return; } String caption = CLanguage.getValue("add") + " " + CLanguage.getValue("inventory_item"); CWinLoadParam param = new CWinLoadParam(); param.Caption = caption; param.GenericType = cit.ItemCategoryID; param.Mode = "A"; param.ParentItemSources = itemsSourceGrid; Boolean isOK = FactoryWindow.ShowWindow("WinAddEditInventoryItem", param); if (isOK) { rowCount = rowCount + 1; lblTotal.Content = CUtil.FormatInt(rowCount.ToString()); } }
private void cmdAdd_Click(object sender, RoutedEventArgs e) { if (!CHelper.VerifyAccessRight("HR_OT_ADD")) { return; } MenuItem mnu = (MenuItem)sender; CWinLoadParam param = new CWinLoadParam(); if (mnu.Name.Equals("mnuDaily")) { param.Caption = CLanguage.getValue("add") + " " + CLanguage.getValue("hr_ot_form"); param.Mode = "A"; param.GenericType = "1"; param.ParentItemSources = itemSources; FactoryWindow.ShowWindow("WinAddEditOtDoc", param); } else if (mnu.Name.Equals("mnuMonthly")) { param.Caption = CLanguage.getValue("add") + " " + CLanguage.getValue("hr_ot_form"); param.Mode = "A"; param.GenericType = "2"; param.ParentItemSources = itemSources; FactoryWindow.ShowWindow("WinAddEditOtDoc", param); } }
private void mnuMasterRefAdd_Click(object sender, RoutedEventArgs e) { CComboConfig cfg = (CComboConfig)comboTypeConfigs[ComboLoadType]; ObservableCollection <MBaseModel> arr = new ObservableCollection <MBaseModel>(); MasterRefEnum rt = (MasterRefEnum)int.Parse(cfg.Type); //WinAddEditMasterRef w = new WinAddEditMasterRef(rt); //w.Caption = (String)(sender as MenuItem).Header + " " + Caption; //w.SetMasterRefType(rt); //w.Mode = "A"; //w.ParentItemSource = arr; //w.ShowDialog(); String caption = CLanguage.getValue("add") + " " + Caption; CWinLoadParam param = new CWinLoadParam(); param.Caption = caption; param.GenericType = cfg.Type; param.Mode = "A"; param.ParentItemSources = arr; Boolean isOK = FactoryWindow.ShowWindow("WinAddEditMasterRef", param); if (isOK) { CMasterReference.LoadAllMasterRefItems(OnixWebServiceAPI.GetAllMasterRefList, rt); } }
private void mnuSupplierAdd_Click(object sender, RoutedEventArgs e) { ObservableCollection <MBaseModel> arr = new ObservableCollection <MBaseModel>(); String caption = lookupTypeToCaption(Lookup); CWinLoadParam param = new CWinLoadParam(); param.Caption = caption; param.Mode = "A"; param.ParentItemSources = arr; FactoryWindow.ShowWindow("WinAddEditSupplier", param); }
private void mnuInventoryAdd_Click(object sender, RoutedEventArgs e) { ObservableCollection <MBaseModel> arr = new ObservableCollection <MBaseModel>(); String caption = CLanguage.getValue("add") + " " + CLanguage.getValue("inventory_item"); CWinLoadParam param = new CWinLoadParam(); param.Caption = caption; param.GenericType = ""; param.Mode = "A"; param.ParentItemSources = arr; FactoryWindow.ShowWindow("WinAddEditInventoryItem", param); }
private void mnuServiceAddOther_Click(object sender, RoutedEventArgs e) { ObservableCollection <MBaseModel> arr = new ObservableCollection <MBaseModel>(); String caption = CLanguage.getValue("add") + " " + CLanguage.getValue("service"); CWinLoadParam param = new CWinLoadParam(); param.Caption = caption; param.GenericType = ((int)ServiceLevel.ServiceLevelOther).ToString(); param.Mode = "A"; param.ParentItemSources = arr; FactoryWindow.ShowWindow("WinAddEditService", param); }
public void ShowEditWindowEx(MVStockCostDocument actDoc) { if (!CHelper.VerifyAccessRight("PURCHASE_COST_EDIT")) { return; } CWinLoadParam param = new CWinLoadParam(); param.Caption = CLanguage.getValue("ap_stock_cost"); param.Mode = "E"; param.ActualView = actDoc; FactoryWindow.ShowWindow("WinAddEditCostDocument", param); }
private void cmdAdd_Click(object sender, RoutedEventArgs e) { if (!CHelper.VerifyAccessRight("PURCHASE_COST_ADD")) { return; } CWinLoadParam param = new CWinLoadParam(); param.Caption = CLanguage.getValue("ap_stock_cost"); param.Mode = "A"; param.GenericType = "1"; param.ParentItemSources = itemSources; FactoryWindow.ShowWindow("WinAddEditCostDocument", param); }
private void mnuProjectAdd_Click(object sender, RoutedEventArgs e) { if (!CHelper.VerifyAccessRight("GENERAL_PROJECT_ADD")) { return; } String caption = CLanguage.getValue("add") + " " + lookupTypeToCaption(Lookup); CWinLoadParam param = new CWinLoadParam(); param.Caption = caption; param.Mode = "A"; param.ParentItemSources = new ObservableCollection <MBaseModel>(); FactoryWindow.ShowWindow("WinAddEditProject", param); }
public void ShowEditWindowEx(MVOTDocument actDoc) { if (!CHelper.VerifyAccessRight("HR_OT_VIEW")) { return; } CWinLoadParam param = new CWinLoadParam(); param.Caption = CLanguage.getValue("edit") + " " + CLanguage.getValue("hr_ot_form"); param.Mode = "E"; param.GenericType = actDoc.EmployeeType; param.ActualView = actDoc; FactoryWindow.ShowWindow("WinAddEditOtDoc", param); }
private void mnuEmployeeAdd_Click(object sender, RoutedEventArgs e) { if (!CHelper.VerifyAccessRight("GENERAL_EMPLOYEE_ADD")) { return; } String caption = CLanguage.getValue("edit") + " " + CLanguage.getValue("employee"); CWinLoadParam param = new CWinLoadParam(); param.Caption = caption; param.Mode = "A"; param.ParentItemSources = new ObservableCollection <MBaseModel>(); FactoryWindow.ShowWindow("WinAddEditEmployeeInfo", param); }
private void cmdAdd_Click(object sender, RoutedEventArgs e) { if (!CHelper.VerifyAccessRight("ADMIN_GROUP_ADD")) { return; } String caption = CLanguage.getValue("add") + " " + CLanguage.getValue("user_group"); CWinLoadParam param = new CWinLoadParam(); param.Caption = caption; param.Mode = "A"; param.ParentItemSources = itemSources; FactoryWindow.ShowWindow("WinAddEditUserGroup", param); }
private void cmdAdd_Click(object sender, RoutedEventArgs e) { if (!CHelper.VerifyAccessRight("GENERAL_PROJECT_ADD")) { return; } String caption = CLanguage.getValue("add") + " " + CLanguage.getValue("project"); CWinLoadParam param = new CWinLoadParam(); param.Caption = caption; param.Mode = "A"; param.ActualView = currentObj; param.ParentItemSources = itemSources; FactoryWindow.ShowWindow("WinAddEditProject", param); }
private void MnuMasterRefEdit_Click(object sender, RoutedEventArgs e) { if (!CHelper.VerifyAccessRight("HR_ORGCHART_VIEW")) { return; } CWinOrgChartLoadParam param = new CWinOrgChartLoadParam(); param.Mode = "E"; param.ActualView = currentViewObj; param.GenericType = currentViewObj.Category; param.ParentItemSources = vw.CurrentItemSource; param.CurrentPaths = vw.CurrentPath; FactoryWindow.ShowWindow("WinAddEditOrgChart", param); }
private void cmdAdd_Click(object sender, RoutedEventArgs e) { if (!CHelper.VerifyAccessRight("HR_LEAVE_ADD")) { return; } String caption = CLanguage.getValue("add") + " " + CLanguage.getValue("employee"); CWinLoadParam param = new CWinLoadParam(); param.Caption = caption; param.Mode = "A"; param.ParentItemSources = itemSources; FactoryWindow.ShowWindow("WinAddEditEmployeeInfo", param); }
private void cmdAddInternal_Click(object sender, RoutedEventArgs e) { if (!CHelper.VerifyAccessRight("CASH_XFER_ADD")) { return; } CWinLoadParam param = new CWinLoadParam(); param.Caption = CLanguage.getValue("add") + " " + CLanguage.getValue("Trans"); param.GenericType = ((int)docType).ToString(); param.Mode = "A"; param.ParentItemSources = itemSources; param.ActualView = currentObj; FactoryWindow.ShowWindow("WinAddEditCashTransfer", param); }
private void showEditWindow() { if (!CHelper.VerifyAccessRight("GENERAL_PROJECT_VIEW")) { return; } String caption = CLanguage.getValue("edit") + " " + CLanguage.getValue("project"); CWinLoadParam param = new CWinLoadParam(); param.Caption = caption; param.Mode = "E"; param.ActualView = currentObj; param.ParentItemSources = itemSources; FactoryWindow.ShowWindow("WinAddEditProject", param); }
private void showAccessRightWindow() { if (!CHelper.VerifyAccessRight("ADMIN_GROUP_VIEW")) { return; } String caption = CLanguage.getValue("edit") + " " + CLanguage.getValue("user_group"); CWinLoadParam param = new CWinLoadParam(); param.Caption = caption; param.Mode = "E"; param.ActualView = currentObj; FactoryWindow.ShowWindow("WinAddEditGroupAccessRight", param); }
private void CmdAllowanceAdd_Click(object sender, RoutedEventArgs e) { CWinLoadParam param = new CWinLoadParam(); param.Caption = CLanguage.getValue("add") + " " + CLanguage.getValue("hr_allowance_form"); param.Mode = "A"; param.ActualParentView = mv; param.GenericType = loadParam.GenericType; Boolean okClick = FactoryWindow.ShowWindow("WinAddEditPayrollExpenseItem", param); if (okClick) { (vw as MVOTDocument).CalculateTotalFields(); vw.IsModified = true; } }
private void MnuDaily_Click(object sender, RoutedEventArgs e) { CWinLoadParam param = new CWinLoadParam(); MenuItem mnu = (MenuItem)sender; param.Caption = CLanguage.getValue("add") + " " + CLanguage.getValue("hr_ot_form"); param.Mode = "A"; param.ActualParentView = mv; param.GenericType = (string)mnu.Tag; Boolean okClick = FactoryWindow.ShowWindow("WinAddEditOtDocItem", param); if (okClick) { (vw as MVOTDocument).CalculateTotalFields(); vw.IsModified = true; } }
private void showEditDeductWindow() { CWinLoadParam param = new CWinLoadParam(); param.Caption = CLanguage.getValue("edit") + " " + CLanguage.getValue("deduction_type"); param.Mode = "E"; param.ActualParentView = mv; param.ActualView = currentDeductionViewObj; param.GenericType = loadParam.GenericType; Boolean okClick = FactoryWindow.ShowWindow("WinAddEditPayrollDeductItem", param); if (okClick) { (vw as MVOTDocument).CalculateTotalFields(); vw.IsModified = true; } }