--- url: >- https://acquirer-api-docs-v4-en.pingpongx.com/en/notes/integrate/magento235/index.md description: >- Magento2.3.5-PPPay Plugin installation guide covers installation prerequisites, precautions, and detailed steps. Applicable for Magento version ≥2.3.5 and PHP version ≥7.1 environment, supporting curl and bcmath extensions. The document emphasizes the importance of monotonically increasing order numbers, and provides sandbox and production environment configuration parameters and command-line operation guide. --- # Magento2.3.5-PPPay Plugin Installation Guide ## Installation Prerequisites > - magento version>=2.3.5 > - php version >=7.1 > - php extension:curl bcmath > - chmod 777 /magentoRoot/var/log --- The following are non-essential settings, if 504 error occurs, you can check the following options - [ ] php ini execution timeout - [ ] nginx or apache execution timeout settings --- ::: danger Note 1. Order numbers under the same accId cannot be duplicated, must be monotonically increasing, otherwise order status issues will occur. 2. Orders from different databases cannot share the same accId. 3. If there have been transactions under accId, before installing the plugin, the id start value should be set to greater than the current maximum order id value. 4. When resetting the database, store, or migrating accId to another store, you should check the maximum order number under accId. ::: ### Plugin Download Pppay.zip ## Installation Process ### Magento Installation Path Rules After decompressing the plugin package, we first check the registration.php file in the plugin package ```php title="registration.php" line-numbersConfiguration->Sales->Payments Method->Ping Pong Pay` ![image.png](/magento235/1629294143209-dcc8a72d-8755-4f26-a375-98f613267516.png) 1. Configure parameters as shown in the following figure! [image.png](/magento235/1629294335798-7a795d99-5669-4423-ba7c-6fd1d3226dee.png) --- ## Environment Parameters ### Sandbox Environment Store Parameters ```text title="Sandbox Environment Store Parameters" line-numbers # [!code highlight] PingPong Sandbox Environment Store Parameters clientId: 2018092714313010016 accId: 2018092714313010016291 salt: F78BC96A55548B2319EE68E0 ``` ### Sandbox Environment Test Card Numbers ```text title="Sandbox Environment Test Card Numbers" line-numbers # [!code highlight] Standard Test Card Number Card Number: 4200000000000000 Expiry: 12/22 cvv: 123 cvv must be 3-digit pure numbers # [!code highlight] 3DS Transaction Test Card Number 3DS Transaction Card: 4711100000000000 ``` ### Environment Addresses ```text title="PingPong Payment Environment Addresses" line-numbers # [!code highlight] Sandbox Environment Address Sandbox Environment https://sandbox-acquirer-payment.pingpongx.com # [!code highlight] Production Environment Address Production Environment https://acquirer-payment.pingpongx.com ``` --- ### Integration Process #### Sandbox Environment Integration 1. Install plugin according to file. 1. After plugin installation is complete, payment self-test is required, and complete the following items: - [ ] Screenshot the page for entering card number - [ ] Screenshot the final redirect page after payment completion - [ ] Send screenshots to the integration group and notify technical support During the installation process, if there are any issues, you can seek technical support in the integration group. --- Precautions: > In sandbox environment, no deduction will be initiated from cardholders, shipping after payment will cause losses, not shipping may cause cardholders to file complaints. Therefore during integration, operations need to be cautious, after integration testing is passed, immediately close the payment channel, wait for production environment launch before opening. --- ## Production Environment Integration 1. After the plugin completes the first round of sandbox environment integration under technical support, it will enter the website information and account review stage, after passing, production environment parameters will be issued. 1. After obtaining production parameters, complete the following items - [ ] Replace sandbox environment parameters with production parameters. - [ ] Self-test payment and complete screenshots - [ ] Prepare a $1 product link. 3. Send screenshots and product link, and notify technical support, the customer/technical support will initiate a real transaction test on this product link. To verify integration results and website payment availability. 3. After completing real transaction testing, merchants need to initiate a refund to verify the refund process. 3. After completing the above process, website integration ends, payment channel officially launches, payment available. ## Production Environment Configuration ### Review Process Get notification from integration group or business/customer that review is passed. Login to [Merchant Backend](https://pay.pingpongx.com/aq/websiteList) ```text title="Merchant Backend Address"https://pay.pingpongx.com/aq/websiteList ``` #### Go to Website List As shown in the figure, go to Group Management->View Details->Website List #### Group Management > - ⚫ Select from menu bar 【Website Management】-【Group Management】to enter group management page > - ⚫ This function allows current merchant to click "Create Group" to create new group; system will default give a default group > - ⚫ Websites are under groups. > - ⚫ Click "View Details" to enter group details page, can modify group name, view copy ID number, view websites under group. ![image.png](/magento235/1629468866673-c4edef47-9708-4141-959c-feab1b3f6c26-20210821002721004.png) #### Select Website Select the corresponding website from the list according to the current integration website domain name ![image.png](/magento235/1629468928427-be88d189-e850-4479-a279-f853446fc371-20210821002730498.png) #### Get accId for corresponding domain website ![image.png](/magento235/1629468994781-7e5ba639-38ca-4593-a6cb-a3d213d71bb0-20210821002739821.png) #### Get Secret Key > Select from menu bar 【System Management】-【Secret Key Management】default enters secret key management page, can view website secret key on this page. After entering secret key management, can view secret keys corresponding to all websites, click "Secret Key Details" to view specific secret key fields. > Secret keys with status "Normal" can be used, when status is "Abnormal", will not be able to use, contact relevant business personnel for handling. ![image.png](/magento235/1629469253929-79e2ba85-c8c9-460f-bb79-e6b9301ae557-20210821002748739.png) --- ### M2 Common Commands #### Display Backend Administrator URI ```shell title="Display Backend Administrator URI" line-numbers php bin/magento info:adminuri ``` #### Uninstall Module For example, plugin name is Pppay_Pppay ```shell title="Uninstall Module" line-numbers php bin/magento module:uninstall --clear-static-content Pppay_Pppay ``` #### Enable Module Plugin For example, plugin name is Pppay_Pppay ```shell title="Enable Module Plugin" line-numbers php bin/magento module:enable --clear-static-content Pppay_Pppay ``` #### Disable Module Plugin For example, plugin name is Pppay_Pppay ```shell title="Disable Module Plugin" line-numbers php bin/magento module:disable --clear-static-content Pppay_Pppay ``` #### Plugin List (Enabled and Disabled) ```shell title="Plugin List" line-numbers php bin/magento module:status ``` #### Switch to Production Mode ```shell title="Switch to Production Mode" line-numbers php bin/magento deploy:mode:set production ``` #### Switch to Development Mode ```bash title="Switch to Development Mode" line-numbers php bin/magento deploy:mode:set developer ``` #### Code Compilation Check if code has syntax errors, such as whether called classes exist, etc. ```shell title="Code Compilation" line-numbers bin/magento setup:di:compile[!code highlight] ``` #### Generate Static Files Generate latest static files to pub/static. Default mode and generation mode must have these static files, otherwise will report errors. ```shell title="Generate Static Files" line-numbers bin/magento setup:static-content:deploy -f[!code highlight] ``` Will automatically generate static files for default language (usually English). That means the above command only generates static files for en_US. If you want to generate both English and Chinese simultaneously, need to specify language pack name after, which is: ```shell title="Generate Multi-language Static Files" line-numbers bin/magento setup:static-content:deploy en_US zh_Hans_CN -f[!code highlight] ``` #### Update Magento Database Data Custom tables in plugin/add product attributes/change a field, etc., any data related to database tables. Use this command to update to database. ```shell title="Update Magento Database Data" line-numbers php bin/magento setup:upgrade[!code highlight] ```