Magento 2: Install JMango360 plugin with COMMAND LINE

Magento 2: Install JMango360 plugin with COMMAND LINE

Important update
If the current plugin version is lower than 1.8.5 and you want to upgrade to the latest version, please remove the current plugin before upgrading:
  1. $ php composer.phar remove jmango360/japi
Plugin compatibility
Compatible payment methods: All gateway methods and hosted methods which meet the requirements below:  
  1. hosted methods should be redirected from place order page
  2. if succeed, they should return to checkout/onepage/success page
  3. if fail, they should return to checkout/cart page
Supported product types: All product types, except virtual and downloadable products.

JMango360 plugin M2 is compatible with Magento Community/Enterprise 2.1 and newer. You can install the plugin from Magento Marketplace or with Command Line. Below is how to install the plugin with Command Line. Before installing the plugin, remember to back up your store.

Pre-requisites

  • PHP version must support CLI.
  • All the settings need to be done in the shell access modePHP Composer (PHP packages manager) must be installed (download from https://getcomposer.org/download/). Please scroll to the bottom of this article to find the way to install PHP Composer.

Installation

Step 1: Configure the JMango360 repo for Composer.
  • Open Shell.
  • Paste command line below then press Enter.
$ composer config repositories.jmango360 vcs https://gitlab.jmango360.com/m2repo/m2repo
$ composer config repositories.jmango360-onepage vcs https://gitlab.jmango360.com/m2repo/m2onepage

If the command lines above do not work for you, please use the following:

$ composer config repositories.jmango360 vcs https://gitlab.jmango360.com/m2repo/m2repo.git
$ composer config repositories.jmango360-onepage vcs https://gitlab.jmango360.com/m2repo/m2onepage.git

Step 2: Add the module to Composer. Copy then paste command line below into Shell then press Enter.
$ composer require jmango360/api jmango360/onepage

Step 3: Installation/Upgrade. After the Composer downloads the module code. You need to enable the module first.
  • Copy then paste command line below into Shell then press Enter.
$ php bin/magento module:enable Jmango360_Japi Jmango360_Onepage
  • To complete the setup, run the upgrade script below:
$ php bin/magento setup:upgrade
$ php bin/magento setup:di:compile

Step 4: Re-generate static files. Generate all static files for the theme "Magento/luma" (required) for all available languages used in the website. For instance:
$ php bin/magento setup:static-content:deploy -t Magento/luma [other themes] [other languages]

Step 5: Configure in Magento Admin. Go to Stores > Configuration > Services > JMango360 Mobile.

Update

Step 1: You need to update the Composer in order to download the new code.
$ composer update jmango360/api jmango360/onepage

Step 2
 : Run the Magento upgrade script again.

$ php bin/magento setup:upgrade
$ php bin/magento setup:di:compile
 
Step 3: Regenerate static files. Generate all static files in the theme "Magento/luma" (required) for all available languages in the website. For instance:
$ php bin/magento setup:static-content:deploy -t Magento/luma [other themes] [other languages]


Did you know?

1. Check the PHP version if it supports CLI

  • Copy and paste the command line below into Shell then press Enter.
$ php -v
  • If the returned result is matched with the command line below, it means your PHP supported CLI.

PHP 7.0.16-1~dotdeb+8.1 (cli) ( NTS )
Copyright (c) 1997-2017 The PHP Group
Zend Engine v3.0.0, Copyright (c) 1998-2017 Zend Technologies with Zend OPcache
v7.0.16-1~dotdeb+8.1, Copyright (c) 1999-2017, by Zend Technologies

2. Check PHP installed 
  • Copy and paste the command line below into Shell then press Enter.
$ composer -V
  • If Composer is installed, the returned result will be the same with this one.
Composer version 1.4.2 2017-05-17 08:17:52

3. Composer error ‘The remote end hung up unexpectedly’

This Git’s issue occurs when you clone with HTTPS. To solve it, you may need to clone with SSH. Please send your server’s SSH public key to our Support Team so we will import it to our server ‘gitlab.jmango360.com’.
    • Related Articles

    • Magento 2: Install JMango360 PWA plugin with COMMAND LINE

      Important update:  If the current PWA plugin version is lower than 1.8.5 and you want to upgrade to the latest version, please remove the current plugin before upgrading: $ php composer.phar remove jmango360/japi Plugin compatibility: Compatible ...
    • Magento 2: Install JMango360 plugin from Magento Marketplace

      Plugin compatibility Compatible payment methods: All gateway methods and hosted methods which meet the requirements below:   hosted methods should be redirected from place order page if succeed, they should return to checkout/onepage/success page if ...
    • Magento 1: Configure the plugin

      After you install the JMango360 plugin successfully on your Magento site, please go to Magento Admin to configure the plugin. Navigate to the Admin menu > JMango360 > Settings. Connection Credentials Version: The version of the plugin. User Name: The ...
    • Magento 1: Install JMango360 plugin by FTP

      Plugin compatibility Compatible payment methods: All gateway methods and hosted methods which meet the requirements below:   hosted methods should be redirected from place order page if succeed, they should return to checkout/onepage/success page if ...
    • Magento 1: Configure the PWA plugin

      After you install the JMango360 PWA plugin successfully on your Magento site, please go to Magento Admin to configure the PWA plugin. Navigate to the Admin menu > JMango360 > Settings. Connection Credentials Version: The version of the PWA plugin. ...