# CRM Setup : Here we have `two` modules . - CRM Customer Module (For bank's customer) - CRM Internal Module (For bank's internal team) ## 1. CRM Customer Module (For External Use) ### Files `env.local` Create a `env.local` file in the root of folder of this project. Content of the `env.local` must be as follows: ``` SESSION_COOKIE_NAME=crm_auth SESSION_COOKIE_PASSWORD=abcdefghijklmnopqrstuvwxyz01234567890 DB_HOST=localhost DB_PORT=5432 DB_NAME=crm DB_USER_NAME= DB_USER_PASS #Mantis MantisBT_Token= #CBS ONLINE_CBS_IP= ONLINE_CBS_PORT= #MESSAGE WEBSERVER_IP= WEBSERVER_PORT= ``` ### Requirement : - Node JS (Latest) - PostgreSQL (Latest) ### Deploy : - Install all node module ``` npm install ``` - In the PostgreSQL create one database, the database name will be "crm" - Build the application ``` npm run build ``` - Start the application ``` npm run start ``` - Open the following URL in the web browser for populate some data ``` http://localhost:3000/api/dev/populate ``` ### Application Url : ``` http://localhost:3000/login ``` ## 2. CRM Internal Module (Ticket Management System) Here we are using "mantisBT" (open source application) for ticket management system . ### Requirement : - Postgres server - XAMPP 8.2.12 / Apache server - PHP 8.2.12 ### Installation & deploy : - Create a folder into `htdocs` present under apache server. `e.g. folder path : C:\xampp\htdocs` `e.g. new folder : crm_internal` - Take the CRM Internet Module (MantisBT codebase) and paste it into the folder. `e.g. crm_internal`. - Open the folder into visual studio code . - Change the config_inc.php as per requirement. (Present in config folder) ``` //Sample $g_hostname = 'localhost'; $g_db_type = 'pgsql'; $g_database_name = 'kccb_ticket_tracker'; $g_db_username = $g_db_password = $g_db_table_prefix = 'kccb'; $g_db_table_suffix = ''; $g_default_timezone = 'Asia/Kolkata'; $g_crypto_master_salt = 'Abcdefghigklmnopqrst'; $g_path = 'http://localhost/crm_internal/'; //crm_internal is the folder name ``` - For first time installation remove the "$g_crypto_master_salt " and keep it null. ``` $g_crypto_master_salt = "" ``` - For install all the dependency and database run the below query ``` Install url : http://localhost/crm_internal/admin/install.php ``` - After successfully install ,Login in to CRM-Internal ``` Login : http://localhost/crm_internal/login_page.php ``` - Login Credential - For first time user - Username : Administrator - password : root ### Setup: - create a new user "kccb". - Log in to this user `kccb`. - Go to "My account". - Then create a API token. - Copy the API token. - And paste the token in `.env.local` file in place of `MantisBT_Token` - create development team's user as protected. - create a project, and keep the name as "KCCB".