Install Splash Module
Manual Installation
- Download latest stable version here : Splash Modules
- Copy module contents on Dolibarr htdocs folder (htdocs/custom/splash)
- Enable & Configure the module
Requirements
- PHP 7.1+
- Dolibarr 9.0 or later
- An active Splash Sync User Account
Configure Splash Module
Enable the Module
Configuration of you module is available in Settings » Modules » Interfaces » Splash
Connect to your Splash Account
First, you need to create access keys for you module in our website. To do so, on Splash workspace, go to Servers » Add a Server and note your id & encryption keys.
Then, enter the keys on Module’s configuration (take care not to forget any character).
Setup default Parameters
To work correctly, this module need few parameters to be selected. These defaults values will be used upon objects creation/modification.
Default Language
Select which language package module should use for communication with Splash Server.
Default User
Select which user will be used for all actions executed by Splash Module.
We highly recommend creation of a dedicated user for Splash.
Be aware Splash Module will take care of Users rights policy, this user must have appropriated right on Dolibarr.
Default Warehouse / Bank Account / Payment Method
Define these values to be used if no value is specified.
Check results of Self-Tests
Each time you update your configuration, module will verify your parameters and ensure communication with Splash is working fine. Ensure all tests are passed… this is critical!
Test Environment (Docker)
You want to try this module? Adjust it to your needs? Or develop new features? Ok! Let’s build a DEV environment!!
Using Docker & Docker Compose, you can start a full developer project.
For each module, we predefined most common possible installations.
Requirements on Local System
- Git git-scm.com
- Php Composer getcomposer.org/
- Docker & Docker-Compose www.docker.com/
- No active Splash Sync User Account is needed!
Clone Module Sources
First, you need to download the sources and compile the module locally.
$ git clone https://github.com/SplashSync/Php-Console myModule
$ cd myModule
$ composer install --no-dev
Build whole Docker Compose Environment
Then, just build the docker environment.
$ docker-compose up
This may take a while but in the end, you should have all your environment working!
Access your Environment
To facilitate access to your instances, we fixed all containers IPs on docker-compose.yml
file.
In this file, you should find a comment with target IPs of your environment containers.
I.e. for Prestashop:
################################################################################
# Docker Compose File
#
# This Docker File intend to Create a Complete Dev Environment
# for Splash Modules on Prestashop
#
# To us different PS Version coinfigured, you need to add hosts to /etc/hosts
#
# 172.102.0.10 latest.prestashop.local
# 172.102.0.16 ps1-6.prestashop.local
# 172.102.0.17 ps1-7.prestashop.local
# 172.102.0.100 toolkit.prestashop.local
#
################################################################################
So, if you browse IP 172.102.0.10, you should find your App working!!
All usefull details of the installtion are visible on docker-compose.yml
file.
For an easier usage, you can cut/paste all IPs to your /etc/hosts. This will make the App available from Url, not only IP.
Test, Develop & Debug using our toolkit
Have you seen this last container available? It’s Splash ToolKit!!
It’s done for developpers and should already be pre-setuped for you Apps!
Just browse the url, and log with user “admin” and password “admin”!
Clear cache?
If your configuration changed, you may have a pretty error… you need to clear the cache!
How? Just run this docker command:
$ docker-compose exec toolkit rm -Rf var/cache/*
Test your connector locally??
Yes, you can! All you need to run our complete core test sequence is already provided by Splash Toolkit.
How? Just run phpunit using this docker command:
$ docker-compose exec toolkit vendor/bin/phpunit