Class MSetup


  • public final class MSetup
    extends Object
    Initial Setup Model
    Version:
    $Id: MSetup.java,v 1.3 2006/07/30 00:51:02 jjanke Exp $
    Author:
    Jorg Janke, Teo Sarca, SC ARHIPAC SERVICE SRL
  • FR [ 1795384 ] Setup: create default accounts records is too rigid, Carlos Ruiz - globalqss
  • Setup correctly IsSOTrx for return documents
    • Field Detail

      • log

        protected CLogger log
        Logger
    • Constructor Detail

      • MSetup

        public MSetup​(Properties ctx,
                      int WindowNo)
        Constructor
        Parameters:
        ctx - context
        WindowNo - window
      • MSetup

        public MSetup​(Properties ctx,
                      int WindowNo,
                      boolean dryRun)
        Constructor
        Parameters:
        ctx - context
        WindowNo - window
    • Method Detail

      • createClient

        public boolean createClient​(String clientName,
                                    String orgValue,
                                    String orgName,
                                    String userClient,
                                    String userOrg,
                                    String phone,
                                    String phone2,
                                    String fax,
                                    String eMail,
                                    String taxID,
                                    String adminEmail,
                                    String userEmail,
                                    boolean isSetInitialPassword)
        Create Client Info. - Client, Trees, Org, Role, User, User_Role
        Parameters:
        clientName - client name
        orgName - org name
        userClient - user id client
        userOrg - user id org
        isSetInitialPassword -
        Returns:
        true if created
      • createAccounting

        public boolean createAccounting​(KeyNamePair currency,
                                        boolean hasProduct,
                                        boolean hasBPartner,
                                        boolean hasProject,
                                        boolean hasMCampaign,
                                        boolean hasSRegion,
                                        File AccountingFile)
      • createAccounting

        public boolean createAccounting​(KeyNamePair currency,
                                        boolean hasProduct,
                                        boolean hasBPartner,
                                        boolean hasProject,
                                        boolean hasMCampaign,
                                        boolean hasSRegion,
                                        boolean hasActivity,
                                        File AccountingFile,
                                        boolean useDefaultCoA,
                                        boolean inactivateDefaults)
        Create Accounting elements. - Calendar - Account Trees - Account Values - Accounting Schema - Default Accounts
        Parameters:
        currency - currency
        hasProduct - has product segment
        hasBPartner - has bp segment
        hasProject - has project segment
        hasMCampaign - has campaign segment
        hasSRegion - has sales region segment
        hasActivity - has activity segment
        AccountingFile - file name of accounting file
        inactivateDefaults - inactivate the default accounts after created
        useDefaultCoA - use the Default CoA (load and group summary account)
        Returns:
        true if created
      • createEntities

        public boolean createEntities​(int C_Country_ID,
                                      String City,
                                      int C_Region_ID,
                                      int C_Currency_ID,
                                      String postal,
                                      String address1)
        Create Default main entities. - Dimensions and BPGroup, Prod Category) - Location, Locator, Warehouse - PriceList - Cashbook, PaymentTerm
        Parameters:
        C_Country_ID - country
        City - city
        C_Region_ID - region
        C_Currency_ID - currency
        Returns:
        true if created
      • getAD_Client_ID

        public int getAD_Client_ID()
        Get Client
        Returns:
        AD_Client_ID
      • getAD_Org_ID

        public int getAD_Org_ID()
        Get AD_Org_ID
        Returns:
        AD_Org_ID
      • getAD_User_ID

        public int getAD_User_ID()
        Get AD_User_ID
        Returns:
        AD_User_ID
      • getInfo

        public String getInfo()
        Get Info
        Returns:
        Info
      • rollback

        public void rollback()
        Rollback Internal Transaction
      • getTrxName

        public String getTrxName()
        Returns:
        trxName