private void onAddTaxPayer() { addTaxPayerEntity = new TaxPayerEntity(); DocumentManager.Web.Model.taxpayer taxpayer = new DocumentManager.Web.Model.taxpayer(); addTaxPayerEntity.TaxPayer = taxpayer; addTaxPayerEntity.Update(); switch (GroupID) { case 0: { TaxPayerWindow lTaxPayerWindow = new TaxPayerWindow(TaxPayerWindowType.ADD, addTaxPayerEntity, TaxPayerTypeList, GroupID); lTaxPayerWindow.Closed += AddTaxPayer_Closed; lTaxPayerWindow.Show(); } break; case 1: { TaxPayerWindowJA lTaxPayerWindow = new TaxPayerWindowJA(TaxPayerWindowType.ADD, addTaxPayerEntity, TaxPayerTypeList, GroupID); lTaxPayerWindow.Closed += AddTaxPayer_Closed; lTaxPayerWindow.Show(); } break; case 2: { TaxPayerWindowPP lTaxPayerWindow = new TaxPayerWindowPP(TaxPayerWindowType.ADD, addTaxPayerEntity, TaxPayerTypeList, GroupID); lTaxPayerWindow.Closed += AddTaxPayer_Closed; lTaxPayerWindow.Show(); } break; case 3: { TaxPayerWindowZP lTaxPayerWindow = new TaxPayerWindowZP(TaxPayerWindowType.ADD, addTaxPayerEntity, TaxPayerTypeList, GroupID); lTaxPayerWindow.Closed += AddTaxPayer_Closed; lTaxPayerWindow.Show(); } break; } //TaxPayerWindow lTaxPayerWindow = new TaxPayerWindow(TaxPayerWindowType.ADD, addTaxPayerEntity, TaxPayerTypeList, GroupID); //lTaxPayerWindow.Closed += AddTaxPayer_Closed; //lTaxPayerWindow.Show(); }
private void onModifyTaxPayer() { switch (GroupID) { case 0: { TaxPayerWindow lTaxPayerWindow = new TaxPayerWindow(TaxPayerWindowType.MODIFY, SelectTaxPayerEntity, TaxPayerTypeList, GroupID); lTaxPayerWindow.Closed += TaxPayerWindow_Closed; lTaxPayerWindow.Show(); } break; case 1: { TaxPayerWindowJA lTaxPayerWindow = new TaxPayerWindowJA(TaxPayerWindowType.MODIFY, SelectTaxPayerEntity, TaxPayerTypeList, GroupID); lTaxPayerWindow.Closed += TaxPayerWindow_Closed; lTaxPayerWindow.Show(); } break; case 2: { TaxPayerWindowPP lTaxPayerWindow = new TaxPayerWindowPP(TaxPayerWindowType.MODIFY, SelectTaxPayerEntity, TaxPayerTypeList, GroupID); lTaxPayerWindow.Closed += TaxPayerWindow_Closed; lTaxPayerWindow.Show(); } break; case 3: { TaxPayerWindowZP lTaxPayerWindow = new TaxPayerWindowZP(TaxPayerWindowType.MODIFY, SelectTaxPayerEntity, TaxPayerTypeList, GroupID); lTaxPayerWindow.Closed += TaxPayerWindow_Closed; lTaxPayerWindow.Show(); } break; } //TaxPayerWindow lTaxPayerWindow = new TaxPayerWindow(TaxPayerWindowType.MODIFY, SelectTaxPayerEntity, TaxPayerTypeList, GroupID); //lTaxPayerWindow.Closed += TaxPayerWindow_Closed; //lTaxPayerWindow.Show(); }