mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2026-02-10 09:52:33 +01:00
Merge branch 'develop' of https://github.com/Dolibarr/dolibarr into test_pgsql_installation
This commit is contained in:
@@ -7,8 +7,13 @@ root = true
|
||||
charset = utf-8
|
||||
end_of_line = lf
|
||||
insert_final_newline = true
|
||||
|
||||
# PHP PSR-2 Coding Standards
|
||||
# http://www.php-fig.org/psr/psr-2/
|
||||
[*.php]
|
||||
indent_style = tab
|
||||
indent_style = space
|
||||
indent_size = 4
|
||||
trim_trailing_whitespace = true
|
||||
[*.js]
|
||||
indent_style = tab
|
||||
[*.css]
|
||||
|
||||
1
.github/CODEOWNERS
vendored
Normal file
1
.github/CODEOWNERS
vendored
Normal file
@@ -0,0 +1 @@
|
||||
htdocs/takepos @andreubisquerra
|
||||
84
.github/CODE_OF_CONDUCT.md
vendored
Normal file
84
.github/CODE_OF_CONDUCT.md
vendored
Normal file
@@ -0,0 +1,84 @@
|
||||
# Code of Conduct
|
||||
|
||||
## 1. Purpose
|
||||
|
||||
A primary goal of Dolibarr is to be inclusive to the largest number of contributors, with the most varied and diverse backgrounds possible. As such, we are committed to providing a friendly, safe and welcoming environment for all, regardless of gender, sexual orientation, ability, ethnicity, socioeconomic status, and religion (or lack thereof).
|
||||
|
||||
This code of conduct outlines our expectations for all those who participate in our community, as well as the consequences for unacceptable behavior.
|
||||
|
||||
We invite all those who participate in Dolibarr to help us create safe and positive experiences for everyone.
|
||||
|
||||
## 2. Open Source Citizenship
|
||||
|
||||
A supplemental goal of this Code of Conduct is to increase open source citizenship by encouraging participants to recognize and strengthen the relationships between our actions and their effects on our community.
|
||||
|
||||
Communities mirror the societies in which they exist and positive action is essential to counteract the many forms of inequality and abuses of power that exist in society.
|
||||
|
||||
If you see someone who is making an extra effort to ensure our community is welcoming, friendly, and encourages all participants to contribute to the fullest extent, we want to know.
|
||||
|
||||
## 3. Expected Behavior
|
||||
|
||||
The following behaviors are expected and requested of all community members:
|
||||
|
||||
* Participate in an authentic and active way. In doing so, you contribute to the health and longevity of this community.
|
||||
* Exercise consideration and respect in your speech and actions.
|
||||
* Attempt collaboration before conflict.
|
||||
* Refrain from demeaning, discriminatory, or harassing behavior and speech.
|
||||
* Be mindful of your surroundings and of your fellow participants. Alert community leaders if you notice a dangerous situation, someone in distress, or violations of this Code of Conduct, even if they seem inconsequential.
|
||||
* Remember that community event venues may be shared with members of the public; please be respectful to all patrons of these locations.
|
||||
|
||||
## 4. Unacceptable Behavior
|
||||
|
||||
The following behaviors are considered harassment and are unacceptable within our community:
|
||||
|
||||
* Violence, threats of violence or violent language directed against another person.
|
||||
* Sexist, racist, homophobic, transphobic, ableist or otherwise discriminatory jokes and language.
|
||||
* Posting or displaying sexually explicit or violent material.
|
||||
* Posting or threatening to post other people’s personally identifying information ("doxing").
|
||||
* Personal insults, particularly those related to gender, sexual orientation, race, religion, or disability.
|
||||
* Inappropriate photography or recording.
|
||||
* Inappropriate physical contact. You should have someone’s consent before touching them.
|
||||
* Unwelcome sexual attention. This includes, sexualized comments or jokes; inappropriate touching, groping, and unwelcomed sexual advances.
|
||||
* Deliberate intimidation, stalking or following (online or in person).
|
||||
* Advocating for, or encouraging, any of the above behavior.
|
||||
* Sustained disruption of community events, including talks and presentations.
|
||||
|
||||
## 5. Consequences of Unacceptable Behavior
|
||||
|
||||
Unacceptable behavior from any community member, including sponsors and those with decision-making authority, will not be tolerated.
|
||||
|
||||
Anyone asked to stop unacceptable behavior is expected to comply immediately.
|
||||
|
||||
If a community member engages in unacceptable behavior, the community organizers may take any action they deem appropriate, up to and including a temporary ban or permanent expulsion from the community without warning (and without refund in the case of a paid event).
|
||||
|
||||
## 6. Reporting Guidelines
|
||||
|
||||
If you are subject to or witness unacceptable behavior, or have any other concerns, please notify a community organizer as soon as possible. contact@dolibarr.org.
|
||||
|
||||
|
||||
|
||||
Additionally, community organizers are available to help community members engage with local law enforcement or to otherwise help those experiencing unacceptable behavior feel safe. In the context of in-person events, organizers will also provide escorts as desired by the person experiencing distress.
|
||||
|
||||
## 7. Addressing Grievances
|
||||
|
||||
If you feel you have been falsely or unfairly accused of violating this Code of Conduct, you should notify Dolibarr with a concise description of your grievance. Your grievance will be handled in accordance with our existing governing policies.
|
||||
|
||||
|
||||
|
||||
## 8. Scope
|
||||
|
||||
We expect all community participants (contributors, paid or otherwise; sponsors; and other guests) to abide by this Code of Conduct in all community venues–online and in-person–as well as in all one-on-one communications pertaining to community business.
|
||||
|
||||
This code of conduct and its related procedures also applies to unacceptable behavior occurring outside the scope of community activities when such behavior has the potential to adversely affect the safety and well-being of community members.
|
||||
|
||||
## 9. Contact info
|
||||
|
||||
contact@dolibarr.org
|
||||
|
||||
## 10. License and attribution
|
||||
|
||||
This Code of Conduct is distributed under a [Creative Commons Attribution-ShareAlike license](http://creativecommons.org/licenses/by-sa/3.0/).
|
||||
|
||||
Portions of text derived from the [Django Code of Conduct](https://www.djangoproject.com/conduct/) and the [Geek Feminism Anti-Harassment Policy](http://geekfeminism.wikia.com/wiki/Conference_anti-harassment/Policy).
|
||||
|
||||
Retrieved on November 22, 2016 from [http://citizencodeofconduct.org/](http://citizencodeofconduct.org/)
|
||||
36
.github/CONTRIBUTING.md
vendored
36
.github/CONTRIBUTING.md
vendored
@@ -38,7 +38,7 @@ We officially support versions N, N − 1 and N − 2 for N the latest version a
|
||||
Choose your base branch accordingly.
|
||||
|
||||
### General rules
|
||||
Please don't edit the ChangeLog file. File will be generated from your commit messages during release process by the project manager.
|
||||
Please don't edit the ChangeLog file. File will be generated from all commit messages during release process by the project manager.
|
||||
|
||||
### <a name="commits"></a>Commits
|
||||
Use clear commit messages with the following structure:
|
||||
@@ -56,13 +56,15 @@ You can add it to your git configuration using:
|
||||
git config --local commit.template .gitmessage
|
||||
```
|
||||
|
||||
where
|
||||
|
||||
#### Keyword
|
||||
In uppercase if you want to have the log comment appears into the generated ChangeLog file.
|
||||
|
||||
The keyword can be ommitted if your commit does not fit in any of the following categories:
|
||||
- Fix: for a bug fix
|
||||
- Close: for closing a referenced feature request
|
||||
- New: for an unreferenced new feature (Opening a feature request and using close is prefered)
|
||||
- Fix/FIX: for a bug fix
|
||||
- New/NEW: for an unreferenced new feature (Opening a feature request and using close is prefered)
|
||||
- Close/CLOSE: for closing a referenced feature request
|
||||
|
||||
#### Issuenum
|
||||
If your commit fixes a referenced bug or feature request.
|
||||
@@ -85,14 +87,14 @@ This section can span multiple lines.
|
||||
|
||||
Try to keep lines under 120 characters.
|
||||
|
||||
#### Samples
|
||||
#### Examples
|
||||
<pre>
|
||||
FIX|Fix #456 Short description (where #456 is number of bug fix, if it exists. In upper case to appear into ChangeLog)
|
||||
or
|
||||
CLOSE|Close #456 Short description (where #456 is number of feature request, if it exists. In upper case to appear into ChangeLog)
|
||||
or
|
||||
NEW|New Short description (In upper case to appear into ChangeLog, use this if you add a feature not tracked, otherwise use CLOSE #456)
|
||||
or
|
||||
CLOSE|Close #456 Short description (where #456 is number of feature request, if it exists. In upper case to appear into ChangeLog)
|
||||
or
|
||||
Short description (when the commit is not introducing feature nor closing a bug)
|
||||
|
||||
Long description (Can span accross multiple lines).
|
||||
@@ -104,13 +106,22 @@ When submitting a pull request, use same rule as [Commits](#commits) for the mes
|
||||
If your pull request only contains one commit, GitHub will be smart enough to fill it for you.
|
||||
Otherwise, please be a bit verbose about what you're providing.
|
||||
|
||||
Your Pull Request must pass the Continuous Integration checks.
|
||||
Your Pull Request (PR) must pass the Continuous Integration checks.
|
||||
Also, some code changes need a prior approbation:
|
||||
|
||||
* if you want to include a new external library (into htdocs/includes directory), please ask before to the project manager (@eldy) to see if such a library can be accepted.
|
||||
|
||||
* if you add a new table, you must first create a page on http://wiki.dolibarr.org/index.php/Category:Table_SQL (copy an existing page changing its name to see it into this index page). Than ask the project manager (@eldy) if the new data model you plan to add can be accepted as you suggest.
|
||||
|
||||
Once a PR has been submitted, you may need to wait for its integration. It is common that the project leader let the PR open for a long delay to allow
|
||||
every developer discuss about the PR.
|
||||
If your PR has errors reported by the Continuous Integration Platform, it means your PR is not valid and nothing will be done with it. It will be kept open to allow developers to fix this, or it may be closed several month later.
|
||||
If the PR is valid, and is kept open for a long time, a tag will also be added on the PR to describe the status of your PR.
|
||||
By putting your mouse on the tag, you will get a full explanation of the tag/status that explain why your PR has not been integrated yet.
|
||||
Around 95% of submitted PR are reviewed and tagged. Even if this is one of the most important ratio in Open Source world, don't expect the core team
|
||||
to reach the 100%. With the increasing popularity of Dolibarr, this ratio will probably decrease in future.
|
||||
|
||||
|
||||
### Resources
|
||||
[Developer documentation](http://wiki.dolibarr.org/index.php/Developer_documentation)
|
||||
|
||||
@@ -120,9 +131,12 @@ The source language (en_US) is maintained in the repository. See the [Code](#cod
|
||||
|
||||
All other translations are managed online at [Transifex](https://www.transifex.com/dolibarr-association/dolibarr/).
|
||||
|
||||
Join an existing translation team or create your own and translate into the interface.
|
||||
Translations done on transifex are available in the next major release.
|
||||
|
||||
Note: Sometimes, the source text (english) is modified. In such a case, the translation is reset. Transifex assume that if the original source
|
||||
has changed, the translation is surely no more correct so must be done again. But old translation is not lost and you can use the tab "History"
|
||||
to retreive all old translation of a source text, and restore the translation in one click with no need to retranslate it if there is no need to.
|
||||
|
||||
Your translations will be available in the next major release.
|
||||
|
||||
### Resources
|
||||
[Translator documentation](http://wiki.dolibarr.org/index.php/Translator_documentation)
|
||||
@@ -131,5 +145,5 @@ Documentation
|
||||
-------------
|
||||
The project's documentation is maintained on the [Wiki](http://wiki.dolibarr.org/index.php).
|
||||
|
||||
*Note*: to help prevent spam, you need to create an account before being able to edit.
|
||||
*Note*: to help prevent spam, you need to create an account before being able to edit. Everybody is welcome to contribute to its content.
|
||||
|
||||
|
||||
2
.gitignore
vendored
2
.gitignore
vendored
@@ -12,6 +12,7 @@ dolibarr_install.log
|
||||
upgrade.log
|
||||
doxygen_warnings.log
|
||||
/.project
|
||||
/.vscode
|
||||
.DS_Store
|
||||
.idea
|
||||
*.iml
|
||||
@@ -24,3 +25,4 @@ Thumbs.db
|
||||
htdocs/includes/autoload.php
|
||||
htdocs/includes/bin/
|
||||
htdocs/includes/composer/
|
||||
/.pydevproject
|
||||
|
||||
10
.mailmap
10
.mailmap
@@ -6,8 +6,8 @@ Laurent Destailleur <eldy@destailleur.fr> eldy <eldy@destailleur.fr>
|
||||
Laurent Destailleur <eldy@destailleur.fr> Laurent Destailleur <ldestailleur@teclib.com>
|
||||
Laurent Destailleur <eldy@destailleur.fr> eldy10 <eldy10@master8.(none)>
|
||||
Laurent Destailleur <eldy@destailleur.fr> Laurent Destailleur <ephpcsdy@destailleur.fr>
|
||||
Regis Houssin <regis.houssin@capnetworks.com> Regis Houssin <regis@dolibarr.fr>
|
||||
Regis Houssin <regis.houssin@capnetworks.com> Régis Houssin <regishoussin@device5.home>
|
||||
Regis Houssin <regis.houssin@inodbox.com> Regis Houssin <regis@dolibarr.fr>
|
||||
Regis Houssin <regis.houssin@inodbox.com> Régis Houssin <regishoussin@device5.home>
|
||||
Juanjo Menent <jmenent@2byte.es> simnandez <jmenent@2byte.es>
|
||||
Juanjo Menent <jmenent@2byte.es> Juanjo Menent <simnandez@gmail.com>
|
||||
Juanjo Menent <jmenent@2byte.es> Simnandez <jmenent@2byte.es>
|
||||
@@ -21,9 +21,9 @@ Florian Henry <florian.henry@open-concept.pro> FHenry <florian.henry.mail@gmail.
|
||||
Florian Henry <florian.henry@open-concept.pro> Florian HENRY <florian.henry@open-conept.pro>
|
||||
Florian Henry <florian.henry@open-concept.pro> FHenry <florian.henry@open-concept.pro>
|
||||
Florian Henry <florian.henry@open-concept.pro> HENRY Florian <florian.henry@open-concept.pro>
|
||||
Alexandre Spangaro <aspangaro.dolibarr@gmail.com> aspangaro <aspangaro.dolibarr@gmail.com>
|
||||
Alexandre Spangaro <aspangaro.dolibarr@gmail.com> Spangaro Alexandre <aspangaro.dolibarr@gmail.com>
|
||||
Alexandre Spangaro <aspangaro.dolibarr@gmail.com> Alexandre SPANGARO <aspangaro.dolibarr@gmail.com>
|
||||
Alexandre Spangaro <aspangaro@open-dsi.fr> aspangaro <aspangaro@open-dsi.fr>
|
||||
Alexandre Spangaro <aspangaro@open-dsi.fr> Spangaro Alexandre <aspangaro@open-dsi.fr>
|
||||
Alexandre Spangaro <aspangaro@open-dsi.fr> Alexandre SPANGARO <aspangaro@open-dsi.fr>
|
||||
Raphaël Doursenaud <rdoursenaud@gpcsolutions.fr> Raphaël Doursenaud <rdoursenaud@free.fr>
|
||||
Philippe Grand <philippe.grand@atoo-net.com> Grand Philippe <contact@atoo-net.com>
|
||||
Philippe Grand <philippe.grand@atoo-net.com> Philippe GRAND <philippe.grand@atoo-net.com>
|
||||
|
||||
346
.travis.yml
346
.travis.yml
@@ -2,8 +2,8 @@
|
||||
# from Dolibarr GitHub repository.
|
||||
# For syntax, see http://about.travis-ci.org/docs/user/languages/php/
|
||||
|
||||
# We use dist: precise to have php 5.3 available
|
||||
dist: precise
|
||||
# We use dist: trusty to have php 5.4+ available
|
||||
dist: trusty
|
||||
sudo: required
|
||||
|
||||
language: php
|
||||
@@ -20,8 +20,7 @@ addons:
|
||||
# To use the last version of pgloader, we add repo of postgresql
|
||||
- postgresql
|
||||
- sourceline: 'deb http://apt.postgresql.org/pub/repos/apt/ trusty-pgdg main'
|
||||
- key_url: 'https://www.postgresql.org/media/keys/ACCC4CF8.asc'
|
||||
- sourceline: 'deb http://http.us.debian.org/debian main non-free'
|
||||
- key_url: 'https://www.postgresql.org/media/keys/ACCC4CF8.asc'
|
||||
packages:
|
||||
# We need a webserver to test the webservices
|
||||
# Let's install Apache with.
|
||||
@@ -32,14 +31,13 @@ addons:
|
||||
- pgloader
|
||||
|
||||
php:
|
||||
- '5.3'
|
||||
- '5.4'
|
||||
- '5.5'
|
||||
- '5.6'
|
||||
- '7.0'
|
||||
- '7.1'
|
||||
- '7.2'
|
||||
#- hhvm only with dist: trusty
|
||||
- '7.3'
|
||||
- nightly
|
||||
|
||||
env:
|
||||
@@ -61,11 +59,28 @@ env:
|
||||
matrix:
|
||||
fast_finish: true
|
||||
allow_failures:
|
||||
- php: hhvm
|
||||
- php: nightly
|
||||
# We exclude some combinations not usefull to save Travis CPU
|
||||
exclude:
|
||||
- php: hhvm
|
||||
- php: '5.5'
|
||||
env: DB=mariadb
|
||||
- php: '5.6'
|
||||
env: DB=mariadb
|
||||
- php: '7.0'
|
||||
env: DB=mariadb
|
||||
- php: '7.1'
|
||||
env: DB=mariadb
|
||||
- php: '7.2'
|
||||
env: DB=mariadb
|
||||
- php: '5.5'
|
||||
env: DB=postgresql
|
||||
- php: '5.6'
|
||||
env: DB=postgresql
|
||||
- php: '7.0'
|
||||
env: DB=postgresql
|
||||
- php: '7.1'
|
||||
env: DB=postgresql
|
||||
- php: '7.2'
|
||||
env: DB=postgresql
|
||||
- php: nightly
|
||||
env: DB=postgresql
|
||||
@@ -95,7 +110,7 @@ before_install:
|
||||
pgloader --version
|
||||
echo
|
||||
fi
|
||||
|
||||
|
||||
install:
|
||||
- |
|
||||
echo "Updating Composer"
|
||||
@@ -114,157 +129,168 @@ install:
|
||||
|
||||
- |
|
||||
echo "Installing PHP Unit"
|
||||
if [ "$TRAVIS_PHP_VERSION" = '5.3' ] || [ "$TRAVIS_PHP_VERSION" = '5.4' ] || [ "$TRAVIS_PHP_VERSION" = '5.5' ]; then
|
||||
if [ "$TRAVIS_PHP_VERSION" = '5.4' ] || [ "$TRAVIS_PHP_VERSION" = '5.5' ]; then
|
||||
composer -n require phpunit/phpunit ^4
|
||||
fi
|
||||
if [ "$TRAVIS_PHP_VERSION" = '5.6' ] || [ "$TRAVIS_PHP_VERSION" = '7.0' ] || [ "$TRAVIS_PHP_VERSION" = '7.1' ]; then
|
||||
composer -n require phpunit/phpunit ^5
|
||||
fi
|
||||
if [ "$TRAVIS_PHP_VERSION" = '7.2' ] || [ "$TRAVIS_PHP_VERSION" = 'nightly' ]; then
|
||||
if [ "$TRAVIS_PHP_VERSION" = '7.2' ] || [ "$TRAVIS_PHP_VERSION" = '7.3' ] || [ "$TRAVIS_PHP_VERSION" = 'nightly' ]; then
|
||||
composer -n require phpunit/phpunit ^5
|
||||
fi
|
||||
echo
|
||||
|
||||
- |
|
||||
echo "Installing PHP CodeSniffer"
|
||||
composer -n require squizlabs/php_codesniffer ^2
|
||||
composer -n require squizlabs/php_codesniffer ^3
|
||||
echo
|
||||
|
||||
- |
|
||||
echo "Adding path of binaries tools installed by composer to the PATH"
|
||||
export PATH="$TRAVIS_BUILD_DIR/htdocs/includes/bin:$PATH"
|
||||
echo
|
||||
|
||||
|
||||
|
||||
|
||||
before_script:
|
||||
- |
|
||||
echo Start travis
|
||||
echo Current dir is `pwd`
|
||||
echo Home dir is `echo ~`
|
||||
echo TRAVIS_BUILD_DIR is $TRAVIS_BUILD_DIR
|
||||
- |
|
||||
echo Start travis
|
||||
echo Current dir is `pwd`
|
||||
echo Home dir is `echo ~`
|
||||
echo TRAVIS_BUILD_DIR is $TRAVIS_BUILD_DIR
|
||||
|
||||
- |
|
||||
echo "Re-enabling Xdebug for PHP CodeSniffer and PHP Unit"
|
||||
phpenv config-add /tmp/xdebug.ini
|
||||
echo
|
||||
|
||||
- |
|
||||
echo "Setting up PHP"
|
||||
echo
|
||||
echo "Set timezone"
|
||||
echo 'date.timezone = "Europe/Paris"' >> ~/.phpenv/versions/$PHP_VERSION_NAME/etc/php.ini
|
||||
if [ "$TRAVIS_PHP_VERSION" = '5.3' ] || [ "$TRAVIS_PHP_VERSION" = '5.4' ]; then
|
||||
#echo
|
||||
#echo "Enabling APC for PHP <= 5.4"
|
||||
# Documentation says it should be available for PHP <= 5.6 but it's not for 5.5 and 5.6!
|
||||
#echo 'extension = apc.so' >> ~/.phpenv/versions/$PHP_VERSION_NAME/etc/php.ini
|
||||
- |
|
||||
echo "Re-enabling Xdebug for PHP CodeSniffer and PHP Unit"
|
||||
phpenv config-add /tmp/xdebug.ini
|
||||
echo
|
||||
echo "Enabling Memcached for PHP <= 5.4"
|
||||
# Documentation says it should be available for all PHP versions but it's not for 5.5 and 5.6, 7.0, 7.1, 7.2 and nightly!
|
||||
echo 'extension = memcached.so' >> ~/.phpenv/versions/$PHP_VERSION_NAME/etc/php.ini
|
||||
fi
|
||||
phpenv rehash
|
||||
echo
|
||||
|
||||
- |
|
||||
if [ "$DEBUG" = true ]; then
|
||||
echo "Debugging informations"
|
||||
- |
|
||||
echo "Setting up PHP"
|
||||
echo
|
||||
echo "Set timezone"
|
||||
echo 'date.timezone = "Europe/Paris"' >> ~/.phpenv/versions/$PHP_VERSION_NAME/etc/php.ini
|
||||
if [ "$TRAVIS_PHP_VERSION" = '5.4' ]; then
|
||||
# Documentation says it should be available for all PHP versions but it's not for 5.5 and 5.6, 7.0, 7.1, 7.2 and nightly!
|
||||
echo
|
||||
echo "Enabling Memcached for PHP <= 5.4"
|
||||
echo 'extension = memcached.so' >> ~/.phpenv/versions/$PHP_VERSION_NAME/etc/php.ini
|
||||
fi
|
||||
phpenv rehash
|
||||
echo
|
||||
|
||||
- |
|
||||
echo "Versions information"
|
||||
# Check PHP
|
||||
php -i
|
||||
echo "PHP version"
|
||||
php -i | head -
|
||||
# Check PHP CodeSniffer installation
|
||||
echo "PHPCS version"
|
||||
which phpcs
|
||||
phpcs --version
|
||||
phpcs -i
|
||||
phpcs --version | head -
|
||||
phpcs -i | head -
|
||||
# Check PHPUnit installation
|
||||
echo "PHPUnit version"
|
||||
which phpunit
|
||||
phpunit --version
|
||||
# Check MySQL
|
||||
mysql --version
|
||||
mysql -e "SELECT VERSION();"
|
||||
phpunit --version | head -
|
||||
# Check Apache version
|
||||
echo "Apache version"
|
||||
apache2 -v | head -
|
||||
# Check MariaDb
|
||||
echo "MariaDb version"
|
||||
mysql --version | head -
|
||||
mysql -e "SELECT VERSION();" | head -
|
||||
echo
|
||||
fi
|
||||
|
||||
- |
|
||||
echo "Setting up database"
|
||||
if [ "$DB" = 'mysql' ] || [ "$DB" = 'mariadb' ] || [ "$DB" = 'postgresql' ]; then
|
||||
echo "MySQL"
|
||||
mysql -e 'DROP DATABASE IF EXISTS travis;'
|
||||
mysql -e 'CREATE DATABASE IF NOT EXISTS travis;'
|
||||
mysql -e 'GRANT ALL PRIVILEGES ON travis.* TO travis@127.0.0.1;'
|
||||
mysql -e 'FLUSH PRIVILEGES;'
|
||||
#mysql -D travis < dev/initdemo/mysqldump_dolibarr_3.5.0.sql
|
||||
fi
|
||||
if [ "$DB" = 'postgresql' ]; then
|
||||
#pgsql travis < dev/initdemo/mysqldump_dolibarr_3.5.0.sql
|
||||
#pgloader mysql://root:pass@127.0.0.1/base postgresql://dolibarrowner@127.0.0.1/dolibarr
|
||||
pgloader mysql://root@127.0.0.1/travis postgresql:///travis
|
||||
fi
|
||||
# TODO: SQLite
|
||||
echo
|
||||
|
||||
- |
|
||||
export CONF_FILE=htdocs/conf/conf.php
|
||||
echo "Setting up Dolibarr $CONF_FILE"
|
||||
echo '<?php ' > $CONF_FILE
|
||||
echo '$'dolibarr_main_url_root=\'http://127.0.0.1\'';' >> $CONF_FILE
|
||||
echo '$'dolibarr_main_document_root=\'$TRAVIS_BUILD_DIR/htdocs\'';' >> $CONF_FILE
|
||||
echo '$'dolibarr_main_data_root=\'$TRAVIS_BUILD_DIR/documents\'';' >> $CONF_FILE
|
||||
echo '$'dolibarr_main_db_host=\'127.0.0.1\'';' >> $CONF_FILE
|
||||
echo '$'dolibarr_main_db_name=\'travis\'';' >> $CONF_FILE
|
||||
echo '$'dolibarr_main_db_user=\'travis\'';' >> $CONF_FILE
|
||||
if [ "$DB" = 'mysql' ] || [ "$DB" = 'mariadb' ]; then
|
||||
echo '$'dolibarr_main_db_type=\'mysqli\'';' >> $CONF_FILE
|
||||
fi
|
||||
if [ "$DB" = 'postgresql' ]; then
|
||||
echo '$'dolibarr_main_db_type=\'pgsql\'';' >> $CONF_FILE
|
||||
fi
|
||||
# TODO: SQLite
|
||||
echo '$'dolibarr_main_authentication=\'dolibarr\'';' >> $CONF_FILE
|
||||
cat $CONF_FILE
|
||||
echo
|
||||
- |
|
||||
echo "Setting up database"
|
||||
if [ "$DB" = 'mysql' ] || [ "$DB" = 'mariadb' ] || [ "$DB" = 'postgresql' ]; then
|
||||
echo "MySQL"
|
||||
mysql -e 'DROP DATABASE IF EXISTS travis;'
|
||||
mysql -e 'CREATE DATABASE IF NOT EXISTS travis;'
|
||||
mysql -e 'GRANT ALL PRIVILEGES ON travis.* TO travis@127.0.0.1;'
|
||||
mysql -e 'FLUSH PRIVILEGES;'
|
||||
mysql -D travis < dev/initdemo/mysqldump_dolibarr_3.5.0.sql
|
||||
fi
|
||||
if [ "$DB" = 'postgresql' ]; then
|
||||
#pgloader mysql://root:pass@127.0.0.1/dolibarr_9 postgresql://dolibarrowner:dolibarrownerpass@127.0.0.1/dolibarr_dev
|
||||
echo pgloader mysql://root@127.0.0.1/travis postgresql:///travis
|
||||
pgloader mysql://root@127.0.0.1/travis postgresql:///travis
|
||||
echo 'ALTER SEQUENCE llx_accountingaccount_rowid_seq RENAME TO llx_accounting_account_rowid_seq' | psql travis
|
||||
echo 'ALTER SEQUENCE llx_accounting_account_rowid_seq RESTART WITH 1000001;' | psql travis
|
||||
#echo 'select * from INFORMATION_SCHEMA.COLUMNS where table_name = 'llx_accountingaccount' | psql travis
|
||||
#echo 'select * from information_schema.table_constraints;' | psql travis
|
||||
#echo 'ALTER TABLE "llx_accounting_account" DROP CONSTRAINT "idx_16390_primary"' | psql travis
|
||||
fi
|
||||
# TODO: SQLite
|
||||
echo
|
||||
|
||||
- |
|
||||
echo "Create documents directory and set permissions"
|
||||
# and admin/temp subdirectory needed for unit tests
|
||||
mkdir -p documents/admin/temp
|
||||
echo "first line" > documents/dolibarr.log
|
||||
echo
|
||||
- |
|
||||
export CONF_FILE=htdocs/conf/conf.php
|
||||
echo "Setting up Dolibarr $CONF_FILE"
|
||||
echo '<?php' > $CONF_FILE
|
||||
echo '$'dolibarr_main_url_root=\'http://127.0.0.1\'';' >> $CONF_FILE
|
||||
echo '$'dolibarr_main_document_root=\'$TRAVIS_BUILD_DIR/htdocs\'';' >> $CONF_FILE
|
||||
echo '$'dolibarr_main_data_root=\'$TRAVIS_BUILD_DIR/documents\'';' >> $CONF_FILE
|
||||
echo '$'dolibarr_main_db_host=\'127.0.0.1\'';' >> $CONF_FILE
|
||||
echo '$'dolibarr_main_db_name=\'travis\'';' >> $CONF_FILE
|
||||
echo '$'dolibarr_main_db_user=\'travis\'';' >> $CONF_FILE
|
||||
if [ "$DB" = 'mysql' ] || [ "$DB" = 'mariadb' ]; then
|
||||
echo '$'dolibarr_main_db_type=\'mysqli\'';' >> $CONF_FILE
|
||||
echo '$'dolibarr_main_db_port=\'3306\'';' >> $CONF_FILE
|
||||
fi
|
||||
if [ "$DB" = 'postgresql' ]; then
|
||||
echo '$'dolibarr_main_db_type=\'pgsql\'';' >> $CONF_FILE
|
||||
echo '$'dolibarr_main_db_port=\'5432\'';' >> $CONF_FILE
|
||||
fi
|
||||
# TODO: SQLite
|
||||
echo '$'dolibarr_main_authentication=\'dolibarr\'';' >> $CONF_FILE
|
||||
cat $CONF_FILE
|
||||
echo
|
||||
|
||||
- |
|
||||
echo "Setting up Apache + FPM"
|
||||
- |
|
||||
echo "Create documents directory and set permissions"
|
||||
# and admin/temp subdirectory needed for unit tests
|
||||
mkdir -p $TRAVIS_BUILD_DIR/documents/admin/temp
|
||||
sudo chmod -R a+rwx $TRAVIS_BUILD_DIR/documents
|
||||
echo "***** First line of dolibarr.log" > $TRAVIS_BUILD_DIR/documents/dolibarr.log
|
||||
echo
|
||||
|
||||
|
||||
- echo "Setting up Apache + FPM"
|
||||
- sudo apt-get update
|
||||
- sudo apt-get install apache2 libapache2-mod-fastcgi
|
||||
# enable php-fpm
|
||||
cp ~/.phpenv/versions/$PHP_VERSION_NAME/etc/php-fpm.conf.default ~/.phpenv/versions/$PHP_VERSION_NAME/etc/php-fpm.conf
|
||||
if [ "$TRAVIS_PHP_VERSION" = '7.0' ] || [ "$TRAVIS_PHP_VERSION" = '7.1' ] || [ "$TRAVIS_PHP_VERSION" = '7.2' ] || [ "$TRAVIS_PHP_VERSION" = 'nightly' ]; then
|
||||
# Copy the included pool
|
||||
cp ~/.phpenv/versions/$PHP_VERSION_NAME/etc/php-fpm.d/www.conf.default ~/.phpenv/versions/$PHP_VERSION_NAME/etc/php-fpm.d/www.conf
|
||||
fi
|
||||
if [ "$DEBUG" = true ]; then
|
||||
cat ~/.phpenv/versions/$PHP_VERSION_NAME/etc/php-fpm.conf
|
||||
fi
|
||||
sudo a2enmod rewrite actions fastcgi alias
|
||||
echo "cgi.fix_pathinfo = 1" >> ~/.phpenv/versions/$PHP_VERSION_NAME/etc/php.ini
|
||||
if [ "$DEBUG" = true ]; then
|
||||
cat ~/.phpenv/versions/$PHP_VERSION_NAME/etc/php.ini
|
||||
fi
|
||||
~/.phpenv/versions/$PHP_VERSION_NAME/sbin/php-fpm
|
||||
# configure apache virtual hosts
|
||||
sudo cp -f build/travis-ci/apache.conf /etc/apache2/sites-available/default
|
||||
sudo sed -e "s?%TRAVIS_BUILD_DIR%?$TRAVIS_BUILD_DIR?g" --in-place /etc/apache2/sites-available/default
|
||||
if [ "$DEBUG" = true ]; then
|
||||
sudo cat /etc/apache2/sites-available/default
|
||||
fi
|
||||
sudo service apache2 restart
|
||||
echo
|
||||
- sudo cp ~/.phpenv/versions/$(phpenv version-name)/etc/php-fpm.conf.default ~/.phpenv/versions/$(phpenv version-name)/etc/php-fpm.conf
|
||||
- |
|
||||
if [ "$TRAVIS_PHP_VERSION" = '7.0' ] || [ "$TRAVIS_PHP_VERSION" = '7.1' ] || [ "$TRAVIS_PHP_VERSION" = '7.2' ] || [ "$TRAVIS_PHP_VERSION" = '7.3' ] || [ "$TRAVIS_PHP_VERSION" = 'nightly' ]; then
|
||||
# Copy the included pool
|
||||
sudo cp ~/.phpenv/versions/$(phpenv version-name)/etc/php-fpm.d/www.conf.default ~/.phpenv/versions/$(phpenv version-name)/etc/php-fpm.d/www.conf
|
||||
fi
|
||||
- sudo a2enmod rewrite actions fastcgi alias
|
||||
- echo "cgi.fix_pathinfo = 1" >> ~/.phpenv/versions/$(phpenv version-name)/etc/php.ini
|
||||
- sudo sed -i -e "s,www-data,travis,g" /etc/apache2/envvars
|
||||
- sudo chown -R travis:travis /var/lib/apache2/fastcgi
|
||||
- ~/.phpenv/versions/$(phpenv version-name)/sbin/php-fpm
|
||||
# configure apache virtual hosts for precise
|
||||
#- sudo sed -e "s?%TRAVIS_BUILD_DIR%?$(pwd)?g" --in-place /etc/apache2/sites-available/default
|
||||
#- sudo cat /etc/apache2/sites-available/default
|
||||
# configure apache virtual hosts for trusty
|
||||
- sudo cp -f build/travis-ci/apache.conf /etc/apache2/sites-available/000-default.conf
|
||||
- sudo sed -e "s?%TRAVIS_BUILD_DIR%?$(pwd)?g" --in-place /etc/apache2/sites-available/000-default.conf
|
||||
- sudo cat /etc/apache2/sites-available/000-default.conf
|
||||
- sudo service apache2 restart
|
||||
|
||||
|
||||
|
||||
script:
|
||||
- |
|
||||
echo "Checking webserver availability"
|
||||
# Ensure we catch errors
|
||||
set -e
|
||||
wget http://127.0.0.1
|
||||
if [ "$DEBUG" = true ]; then
|
||||
cat index.html
|
||||
fi
|
||||
echo "Checking webserver availability by a wget -O - http://127.0.0.1"
|
||||
# Ensure we stop on error with set -e
|
||||
set +e
|
||||
# The wget should return a page with line '<meta name="generator" content="Dolibarr installer">
|
||||
wget -O - http://127.0.0.1 > test.html
|
||||
head test.html
|
||||
sudo cat /var/log/apache2/travis_error_log
|
||||
set +e
|
||||
echo
|
||||
|
||||
@@ -272,7 +298,8 @@ script:
|
||||
echo "Checking PHP syntax errors"
|
||||
# Ensure we catch errors
|
||||
set -e
|
||||
parallel-lint --exclude htdocs/includes --blame .
|
||||
#parallel-lint --exclude htdocs/includes --blame .
|
||||
parallel-lint --exclude htdocs/includes/sabre --exclude htdocs/includes/phpoffice/phpexcel/Classes/PHPExcel/Shared --exclude htdocs/includes/phpoffice/PhpSpreadsheet --exclude htdocs/includes/sebastian --exclude htdocs/includes/squizlabs/php_codesniffer/tests --exclude htdocs/includes/jakub-onderka/php-parallel-lint/tests --exclude htdocs/includes/mike42/escpos-php/example --exclude htdocs/includes/phpunit/php-token-stream/tests --exclude htdocs/includes/composer/autoload_static.php --blame .
|
||||
set +e
|
||||
echo
|
||||
|
||||
@@ -281,7 +308,8 @@ script:
|
||||
# Ensure we catch errors
|
||||
set -e
|
||||
# Exclusions are defined in the ruleset.xml file
|
||||
phpcs -s -n -p -d memory_limit=-1 --colors --tab-width=4 --standard=dev/setup/codesniffer/ruleset.xml --encoding=utf-8 .
|
||||
#phpcs -s -n -p -d memory_limit=-1 --colors --tab-width=4 --standard=dev/setup/codesniffer/ruleset.xml --encoding=utf-8 .
|
||||
phpcs -s -p -d memory_limit=-1 --extensions=php --colors --tab-width=4 --standard=dev/setup/codesniffer/ruleset.xml --encoding=utf-8 --runtime-set ignore_warnings_on_exit true .
|
||||
set +e
|
||||
echo
|
||||
|
||||
@@ -348,7 +376,7 @@ script:
|
||||
|
||||
- |
|
||||
echo "Upgrading Dolibarr"
|
||||
# Ensure we catch errors
|
||||
# Ensure we catch errors. Set this to +e if you want to go to the end to see log files.
|
||||
set +e
|
||||
cd htdocs/install
|
||||
php upgrade.php 3.5.0 3.6.0 ignoredbversion > $TRAVIS_BUILD_DIR/upgrade350360.log
|
||||
@@ -364,7 +392,7 @@ script:
|
||||
php upgrade2.php 3.8.0 3.9.0 > $TRAVIS_BUILD_DIR/upgrade380390-2.log
|
||||
php step5.php 3.8.0 3.9.0 > $TRAVIS_BUILD_DIR/upgrade380390-3.log
|
||||
php upgrade.php 3.9.0 4.0.0 ignoredbversion > $TRAVIS_BUILD_DIR/upgrade390400.log
|
||||
php upgrade2.php 3.9.0 4.0.0 MAIN_MODULE_API,MAIN_MODULE_SUPPLIERPROPOSAL > $TRAVIS_BUILD_DIR/upgrade390400-2.log
|
||||
php upgrade2.php 3.9.0 4.0.0 > $TRAVIS_BUILD_DIR/upgrade390400-2.log
|
||||
php step5.php 3.9.0 4.0.0 > $TRAVIS_BUILD_DIR/upgrade390400-3.log
|
||||
php upgrade.php 4.0.0 5.0.0 ignoredbversion > $TRAVIS_BUILD_DIR/upgrade400500.log
|
||||
php upgrade2.php 4.0.0 5.0.0 > $TRAVIS_BUILD_DIR/upgrade400500-2.log
|
||||
@@ -373,35 +401,41 @@ script:
|
||||
php upgrade2.php 5.0.0 6.0.0 > $TRAVIS_BUILD_DIR/upgrade500600-2.log
|
||||
php step5.php 5.0.0 6.0.0 > $TRAVIS_BUILD_DIR/upgrade500600-3.log
|
||||
php upgrade.php 6.0.0 7.0.0 ignoredbversion > $TRAVIS_BUILD_DIR/upgrade600700.log
|
||||
php upgrade2.php 6.0.0 7.0.0 MAIN_MODULE_WEBSITE,MAIN_MODULE_SUPPLIERPROPOSAL > $TRAVIS_BUILD_DIR/upgrade600700-2.log
|
||||
php upgrade2.php 6.0.0 7.0.0 > $TRAVIS_BUILD_DIR/upgrade600700-2.log
|
||||
php step5.php 6.0.0 7.0.0 > $TRAVIS_BUILD_DIR/upgrade600700-3.log
|
||||
php upgrade.php 7.0.0 8.0.0 ignoredbversion > $TRAVIS_BUILD_DIR/upgrade700800.log
|
||||
php upgrade2.php 7.0.0 8.0.0 > $TRAVIS_BUILD_DIR/upgrade700800-2.log
|
||||
php step5.php 7.0.0 8.0.0 > $TRAVIS_BUILD_DIR/upgrade700800-3.log
|
||||
php upgrade.php 8.0.0 9.0.0 ignoredbversion > $TRAVIS_BUILD_DIR/upgrade800900.log
|
||||
php upgrade2.php 8.0.0 9.0.0 > $TRAVIS_BUILD_DIR/upgrade800900-2.log
|
||||
php step5.php 8.0.0 9.0.0 > $TRAVIS_BUILD_DIR/upgrade800900-3.log
|
||||
php upgrade.php 9.0.0 10.0.0 ignoredbversion > $TRAVIS_BUILD_DIR/upgrade9001000.log
|
||||
php upgrade2.php 9.0.0 10.0.0 > $TRAVIS_BUILD_DIR/upgrade9001000-2.log
|
||||
php step5.php 9.0.0 10.0.0 > $TRAVIS_BUILD_DIR/upgrade9001000-3.log
|
||||
# Enable modules not enabled into original dump
|
||||
php upgrade2.php 0.0.0 0.0.0 MAIN_MODULE_API,MAIN_MODULE_SUPPLIERPROPOSAL,MAIN_MODULE_WEBSITE,MAIN_MODULE_TICKETSUP,MAIN_MODULE_ACCOUNTING > $TRAVIS_BUILD_DIR/enablemodule.log
|
||||
echo $?
|
||||
cd -
|
||||
set +e
|
||||
echo
|
||||
#cat $TRAVIS_BUILD_DIR/upgrade400500-2.log
|
||||
#cat $TRAVIS_BUILD_DIR/upgrade500600.log
|
||||
#cat $TRAVIS_BUILD_DIR/upgrade500600-2.log
|
||||
#cat $TRAVIS_BUILD_DIR/upgrade500600-3.log
|
||||
#cat /tmp/dolibarr_install.log
|
||||
|
||||
cat $TRAVIS_BUILD_DIR/enablemodule.log
|
||||
|
||||
- |
|
||||
echo "Unit testing"
|
||||
phpunit --version
|
||||
# Ensure we catch errors. Set this to +e if you want to go to the end to see dolibarr.log file.
|
||||
set -e
|
||||
phpunit -d memory_limit=-1 -c test/phpunit/phpunittest.xml test/phpunit/AllTests.php
|
||||
phpunitresult=$?
|
||||
echo "Phpunit return code = $phpunitresult"
|
||||
set +e
|
||||
|
||||
- |
|
||||
#echo "Output dolibarr.log"
|
||||
#cat documents/dolibarr.log
|
||||
|
||||
after_script:
|
||||
- |
|
||||
# Dolibarr log file
|
||||
#echo "After script"
|
||||
#cat documents/dolibarr.log
|
||||
|
||||
echo "After script - Output lines of dolibarr.log"
|
||||
ls $TRAVIS_BUILD_DIR/documents
|
||||
#cat $TRAVIS_BUILD_DIR/documents/dolibarr.log
|
||||
sudo tail -n 50 $TRAVIS_BUILD_DIR/documents/dolibarr.log
|
||||
|
||||
after_success:
|
||||
- |
|
||||
@@ -409,20 +443,24 @@ after_success:
|
||||
|
||||
after_failure:
|
||||
- |
|
||||
echo Failure
|
||||
# This part of code seems to be never executed, error or not ???
|
||||
echo "Debugging informations"
|
||||
echo Failure detected, so we show samples of log to help diagnose
|
||||
# This part of code is executed only if previous command that fails are enclosed with set +e
|
||||
# Upgrade log files
|
||||
cat *.log
|
||||
echo "Debugging informations"
|
||||
for ficlog in `ls $TRAVIS_BUILD_DIR/*.log`
|
||||
do
|
||||
echo "Debugging informations for file $ficlog"
|
||||
#cat $ficlog
|
||||
done
|
||||
# Apache log file
|
||||
sudo cat /var/log/apache2/error.log
|
||||
# Dolibarr log file
|
||||
cat documents/dolibarr.log
|
||||
echo "Debugging informations for file apache error.log"
|
||||
sudo cat /var/log/apache2/travis_error_log
|
||||
if [ "$DEBUG" = true ]; then
|
||||
# Dolibarr log file
|
||||
echo "Debugging informations for file dolibarr.log (latest 50 lines)"
|
||||
tail -n 50 $TRAVIS_BUILD_DIR/documents/dolibarr.log
|
||||
# MariaDB log file
|
||||
sudo cat /var/log/mysql/error.log
|
||||
echo "Debugging informations for file mysql error.log"
|
||||
sudo tail -n 50 /var/log/mysql/error.log
|
||||
# TODO: PostgreSQL log file
|
||||
echo
|
||||
fi
|
||||
|
||||
|
||||
37
.tx/config
37
.tx/config
@@ -20,6 +20,12 @@ source_file = htdocs/langs/en_US/agenda.lang
|
||||
source_lang = en_US
|
||||
type = MOZILLAPROPERTIES
|
||||
|
||||
[dolibarr.assets]
|
||||
file_filter = htdocs/langs/<lang>/assets.lang
|
||||
source_file = htdocs/langs/en_US/assets.lang
|
||||
source_lang = en_US
|
||||
type = MOZILLAPROPERTIES
|
||||
|
||||
[dolibarr.banks]
|
||||
file_filter = htdocs/langs/<lang>/banks.lang
|
||||
source_file = htdocs/langs/en_US/banks.lang
|
||||
@@ -32,6 +38,12 @@ source_file = htdocs/langs/en_US/bills.lang
|
||||
source_lang = en_US
|
||||
type = MOZILLAPROPERTIES
|
||||
|
||||
[dolibarr.blockedlog]
|
||||
file_filter = htdocs/langs/<lang>/blockedlog.lang
|
||||
source_file = htdocs/langs/en_US/blockedlog.lang
|
||||
source_lang = en_US
|
||||
type = MOZILLAPROPERTIES
|
||||
|
||||
[dolibarr.bookmarks]
|
||||
file_filter = htdocs/langs/<lang>/bookmarks.lang
|
||||
source_file = htdocs/langs/en_US/bookmarks.lang
|
||||
@@ -152,12 +164,6 @@ source_file = htdocs/langs/en_US/hrm.lang
|
||||
source_lang = en_US
|
||||
type = MOZILLAPROPERTIES
|
||||
|
||||
[dolibarr.incoterm]
|
||||
file_filter = htdocs/langs/<lang>/incoterm.lang
|
||||
source_file = htdocs/langs/en_US/incoterm.lang
|
||||
source_lang = en_US
|
||||
type = MOZILLAPROPERTIES
|
||||
|
||||
[dolibarr.install]
|
||||
file_filter = htdocs/langs/<lang>/install.lang
|
||||
source_file = htdocs/langs/en_US/install.lang
|
||||
@@ -230,6 +236,12 @@ source_file = htdocs/langs/en_US/modulebuilder.lang
|
||||
source_lang = en_US
|
||||
type = MOZILLAPROPERTIES
|
||||
|
||||
[dolibarr.mrp]
|
||||
file_filter = htdocs/langs/<lang>/mrp.lang
|
||||
source_file = htdocs/langs/en_US/mrp.lang
|
||||
source_lang = en_US
|
||||
type = MOZILLAPROPERTIES
|
||||
|
||||
[dolibarr.multicurrency]
|
||||
file_filter = htdocs/langs/<lang>/multicurrency.lang
|
||||
source_file = htdocs/langs/en_US/multicurrency.lang
|
||||
@@ -308,6 +320,12 @@ source_file = htdocs/langs/en_US/receiptprinter.lang
|
||||
source_lang = en_US
|
||||
type = MOZILLAPROPERTIES
|
||||
|
||||
[dolibarr.receptions]
|
||||
file_filter = htdocs/langs/<lang>/receptions.lang
|
||||
source_file = htdocs/langs/en_US/receptions.lang
|
||||
source_lang = en_US
|
||||
type = MOZILLAPROPERTIES
|
||||
|
||||
[dolibarr.resource]
|
||||
file_filter = htdocs/langs/<lang>/resource.lang
|
||||
source_file = htdocs/langs/en_US/resource.lang
|
||||
@@ -356,6 +374,12 @@ source_file = htdocs/langs/en_US/supplier_proposal.lang
|
||||
source_lang = en_US
|
||||
type = MOZILLAPROPERTIES
|
||||
|
||||
[dolibarr.ticket]
|
||||
file_filter = htdocs/langs/<lang>/ticket.lang
|
||||
source_file = htdocs/langs/en_US/ticket.lang
|
||||
source_lang = en_US
|
||||
type = MOZILLAPROPERTIES
|
||||
|
||||
[dolibarr.trips]
|
||||
file_filter = htdocs/langs/<lang>/trips.lang
|
||||
source_file = htdocs/langs/en_US/trips.lang
|
||||
@@ -385,3 +409,4 @@ file_filter = htdocs/langs/<lang>/workflow.lang
|
||||
source_file = htdocs/langs/en_US/workflow.lang
|
||||
source_lang = en_US
|
||||
type = MOZILLAPROPERTIES
|
||||
|
||||
|
||||
17
COPYRIGHT
17
COPYRIGHT
@@ -15,8 +15,9 @@ PHP libraries:
|
||||
AdoDb-Date 0.36 Modified BSD License Yes Date convertion (not into rpm package)
|
||||
ChromePHP 4.1.0 Apache Software License 2.0 Yes Return server log to chrome browser console
|
||||
CKEditor 4.6.2 LGPL-2.1+ Yes Editor WYSIWYG
|
||||
PHPDebugBar 1.15.0 MIT License Yes Used only by the module "debugbar" for developers
|
||||
EvalMath 1.0 BSD Yes Safe math expressions evaluation
|
||||
Escpos-php MIT License Yes Thermal receipt printer library, for use with ESC/POS compatible printers
|
||||
Escpos-php ? MIT License Yes Thermal receipt printer library, for use with ESC/POS compatible printers
|
||||
GeoIP 1.4 LGPL-2.1+ Yes Sample code to make geoip convert (not into deb package)
|
||||
Mobiledetect 2.8.17 MIT License Yes Detect mobile devices browsers
|
||||
NuSoap 0.9.5 LGPL 2.1+ Yes Library to develop SOAP Web services (not into rpm and deb package)
|
||||
@@ -24,17 +25,20 @@ PEAR Mail_MIME 1.8.9 BSD Yes
|
||||
odtPHP 1.0.1 GPL-2+ Yes Library to build/edit ODT files
|
||||
ParseDown 1.6 MIT License Yes Markdown parser
|
||||
PHPExcel 1.8.1 LGPL-2.1+ Yes Read/Write XLS files, read ODS files
|
||||
PHPSpreadSheet ? LGPL-2.1+ Yes Read/Write XLS files, read ODS files
|
||||
php-iban 1.4.7 LGPL-3+ Yes Parse and validate IBAN (and IIBAN) bank account information in PHP
|
||||
PHPoAuthLib 0.8.2 MIT License Yes Library to provide oauth1 and oauth2 to different service
|
||||
PHPPrintIPP 1.3 GPL-2+ Yes Library to send print IPP requests
|
||||
PSR/Logs 1.0 Library for logs (used by DebugBar)
|
||||
PSR/simple-cache Library for cache (used by PHPSpreadSheet)
|
||||
Restler 3.0.0RC6 LGPL-3+ Yes Library to develop REST Web services (+ swagger-ui js lib into dir explorer)
|
||||
TCPDF 6.2.12 LGPL-3+ Yes PDF generation
|
||||
TCPDF 6.2.25 LGPL-3+ Yes PDF generation
|
||||
TCPDI 1.0.0 LGPL-3+ / Apache 2.0 Yes FPDI replacement
|
||||
Swift Mailer 5.4.2-DEV MIT license Yes Comprehensive mailing tools for PHP
|
||||
Stripe 4.7.0 MIT licence Yes Library for Stripe module
|
||||
|
||||
JS libraries:
|
||||
jQuery 3.1.1 MIT License Yes JS library
|
||||
jQuery 3.3.1 MIT License Yes JS library
|
||||
jQuery UI 1.12.1 GPL and MIT License Yes JS library plugin UI
|
||||
jQuery select2 4.0.5 GPL and Apache License Yes JS library plugin for sexier multiselect
|
||||
jQuery blockUI 2.70.0 GPL and MIT License Yes JS library plugin blockUI (to use ajax popups)
|
||||
@@ -53,6 +57,13 @@ JsTimezoneDetect 1.0.6 MIT License Yes
|
||||
SwaggerUI 2.0.24 GPL-2+ Yes JS library to offer the REST API explorer
|
||||
Ace 1.2.8 BSD Yes JS library to get code syntaxique coloration in a textarea.
|
||||
|
||||
Image libraries:
|
||||
Octicons 8.1 MIT Yes
|
||||
|
||||
Font libraries:
|
||||
Fontawesome 5.7.2 Font Awesome Free licence Yes
|
||||
|
||||
|
||||
For licenses compatibility informations:
|
||||
http://www.gnu.org/licenses/licenses.en.html
|
||||
|
||||
|
||||
859
ChangeLog
859
ChangeLog
@@ -2,6 +2,820 @@
|
||||
English Dolibarr ChangeLog
|
||||
--------------------------------------------------------------
|
||||
|
||||
***** ChangeLog for 10.0.0 compared to 9.0.0 *****
|
||||
For Users:
|
||||
NEW: Module ticket is available as a stable module
|
||||
NEW: Experimental module "Vendor receptions"
|
||||
|
||||
For Developers:
|
||||
|
||||
|
||||
WARNING:
|
||||
|
||||
Following changes may create regressions for some external modules, but were necessary to make Dolibarr better:
|
||||
* Method GetUrlTrackingStatus were renamed into getUrlTrackingStatus for consistency with naming rules.
|
||||
* API getListOfCivility has been renamed into getListOfCivilities for consistency with naming rules.
|
||||
* Deprecated function img_phone as been removed. You can use img_picto(..., 'call|call_out') instead.;
|
||||
* Files for variables of themes were renamed from graph-color.php into theme_vars.inc.php to match naming
|
||||
convention of extension .inc.php for files to be included.
|
||||
* All methods set_draft() were renamed into setDraft().
|
||||
* Removed deprecated function function test_sql_and_script_inject that was replaced with testSqlAndScriptInject.
|
||||
* Method load_measuring_units were renamed into selectMeasuringUnits and select_measuring_units was deprecated.
|
||||
|
||||
|
||||
***** ChangeLog for 9.0.1 compared to 9.0.0 *****
|
||||
FIX: #10381
|
||||
FIX: #10460 compatibility with MariaDB 10.4
|
||||
FIX: #10485
|
||||
FIX: #10638
|
||||
FIX: Accountancy - Adding transaction with multicompany uses all the time 1st entity
|
||||
FIX: actioncomm export: ORDER BY clause is in wrong export property + event type filter does not work
|
||||
FIX: add fk_unit on addline action
|
||||
FIX: adding css by page if url is externam
|
||||
FIX: Bad link in menu manager
|
||||
FIX: better test on fetch
|
||||
FIX: can't add lines on invoices
|
||||
FIX: Check for old picture name if the new one was not found
|
||||
FIX: could not create several superadmin in transversal mode
|
||||
FIX: creation of menu entry with parent id not int
|
||||
FIX: creation of new left menu entry
|
||||
FIX: Default language of company is not set
|
||||
FIX: error on setup of password if pass generators have a .old file.
|
||||
FIX: error report not returned
|
||||
FIX: expedition: reset status on rollback + replace hardcoded status with const
|
||||
FIX: fetch module / pos source
|
||||
FIX: fk_default_warehouse missing in group by
|
||||
FIX: function sendEmailsReminder isn't completely developed, then MAIN_FEATURES_LEVEL must be 2 to "use" it
|
||||
FIX: if empty error message, we just see "error" displayed
|
||||
FIX: label of bank account
|
||||
FIX: line edit template: keep fk_parent_line
|
||||
FIX: Mark credit note as available for credit note in other currency
|
||||
FIX: missing access security checking with multicompany
|
||||
FIX: missing entity filter in function "build_filterField()" (export module)
|
||||
FIX: missing $ismultientitymanaged for previous/next ref
|
||||
FIX: Missing province in export of invoice
|
||||
FIX: must fetch member in current entity
|
||||
FIX: positive values creating diff on addline rounding
|
||||
FIX: positive values IN supplier credit notes creating diff on addline rounding
|
||||
FIX: Price in combo list of service does not use the correct price level
|
||||
FIX: project_title for display of getNomUrl()
|
||||
FIX: same thing here
|
||||
FIX: Show button POS Ticket only if invoice was generated by POS
|
||||
FIX: supplier invoice payment total doesn't care about deposit or credit
|
||||
FIX: supplier invoice product stats total ht is line total not invoice total
|
||||
FIX: The notes was also copied on invoice
|
||||
FIX: Transaction on leave approval and decrease ko if setup not complete
|
||||
FIX: Translation not loaded by scheduled jobs
|
||||
FIX: [URGENT] broken feature, "$usercancreate" is for Dolibarr 9
|
||||
FIX: we want to be able to reopen fourn credit note
|
||||
FIX: wrong feature2 when user rights "group_advance" is used
|
||||
FIX: wrong merged conflict
|
||||
FIX: wrong tests on fetch
|
||||
NEW: Add protection to avoid packaging if files non indexed exists
|
||||
|
||||
***** ChangeLog for 9.0.0 compared to 8.0.0 *****
|
||||
For Users:
|
||||
NEW: Stable module: DAV (WebDAV only for the moment)
|
||||
NEW: Stable module "Skype" has been replaced with module "Social Networks" to support more services.
|
||||
NEW: Stable module "Module Builder"
|
||||
NEW: Stable module: Website
|
||||
NEW: Experimental module "TakePos"
|
||||
NEW: Experimental module "Ticket"
|
||||
NEW: Experimental module "Data Privacy"
|
||||
NEW: Experimental module "Email Collector"
|
||||
NEW: Dolibarr can provide information in page title when multicompany is enabled of not, making
|
||||
Android application like DoliDroid able to provide native features for multicompany module.
|
||||
NEW: Compatibility with PHP 7.3 =>
|
||||
NEW: Add admin page for modulebuilder
|
||||
NEW: Add civility in list of members. Close #9251
|
||||
NEW: Add configuration to disable "customer/prospect" thirdparty type
|
||||
NEW: Add CONTRACT_ALLOW_TO_LINK_FROM_OTHER_COMPANY and CONTRACT_HIDE_UNSELECTABLES by SELECT_HIDE_UNSELECTABLES
|
||||
NEW: Add __DAY_TEXT__ and __MONTH_TEXT__ substitutions vars
|
||||
NEW: Add due date column in payment lists
|
||||
NEW: Add email in event history, for reminder email of expired subsription
|
||||
NEW: Add event tab on resource record
|
||||
NEW: Add FEC Export in accountancy
|
||||
NEW: Add filter on staff range in list of thirdparties
|
||||
NEW: Add a first complete template of website
|
||||
NEW: Add format code into exported filename of ledger
|
||||
NEW: Add hidden option EXPENSEREPORT_DEFAULT_VALIDATOR_UNCHANGEABLE
|
||||
NEW: Add hidden option MAIN_DOCUMENTS_DESCRIPTION_FIRST
|
||||
NEW: Add link to inventory code
|
||||
NEW: Add more common social networks fields for business
|
||||
NEW: Add option PDF_DISABLE_MYCOMPANY_LOGO to disable logo on PDF
|
||||
NEW: add option PROPOSAL_AUTO_ADD_AUTHOR_AS_CONTACT
|
||||
NEW: Add option to display thirdparty adress in combolist
|
||||
NEW: Add option to swap sender/recipient address on PDF
|
||||
NEW: Add option to display thirdparty adress in combolist
|
||||
NEW: Add project on pament of salaries
|
||||
NEW: Add SHIPPING_PDF_HIDE_WEIGHT_AND_VOLUME and
|
||||
NEW: Add somes hooks in bank planned entries
|
||||
NEW: Add supplier ref in item reception page
|
||||
NEW: Advanced permission to ignore price min
|
||||
NEW: Allow to enter a timespent with a numeric value
|
||||
NEW: Automatic position of scroll when creating an extrafield
|
||||
NEW: Can add autorefresh=X in any URLs to refresh page after X seconds
|
||||
NEW: can add project's task to agenda on create event form
|
||||
NEW: Can delete a website in experimental website module
|
||||
NEW: Can disable meteo on smartphone only
|
||||
NEW: Can export/import a website template
|
||||
NEW: Can filter on EEC, not EEC, etc... in binding step of accountancy
|
||||
NEW: Can mix offset before and after with rules for due date of invoices
|
||||
NEW: Can record the supplier product description
|
||||
NEW: Can select several prospect level in thirdparty filter.
|
||||
NEW: Can set 2 url in url field of thirdparty
|
||||
NEW: Can set if a field is mandatory on form level.
|
||||
NEW: Can set the default focus of each page.
|
||||
NEW: Add category filter on user list
|
||||
NEW: Change forgotten password link in general parameters
|
||||
NEW: Child label of variants change if parent label changes
|
||||
NEW: Compatibility with new Paybox HMAC requirement
|
||||
NEW: Each user can set its prefered default calendar page
|
||||
NEW: Enhancement in process to make manual bank conciliation
|
||||
NEW: Enhancement in the generic file manager
|
||||
NEW: Extrafield totalizable
|
||||
NEW: Hidden conf INVOICE_USE_DEFAULT_DOCUMENT
|
||||
NEW: hidden conf to search product by supplier ref
|
||||
NEW: hidden constant to be able to use a thirdparty for donation
|
||||
NEW: hidden option to define an invoice template for each invoice type
|
||||
NEW: Highlight lines on lists when they are checked
|
||||
NEW: Notification module support expense report+holiday validation and approval
|
||||
NEW: On customer/supplier card, add simple tooltip to amount boxes
|
||||
NEW: Page to check if the operations/items created between two dates have attached item(s) and possibility to download all attachements
|
||||
NEW: possibility to add all rights of all modules in one time
|
||||
NEW: redirect if only one result on global search on card
|
||||
NEW: Permission to ignore price min
|
||||
NEW: Can build an archive of full documents directory from backup page
|
||||
NEW: tag odt line_product_ref_fourn for supplier doc lines
|
||||
NEW: The binding step in accountancy has a country filter with autocompletion
|
||||
NEW: Top menu is always on screen with MD theme.
|
||||
NEW: Withdraw request massaction can include already partially paid invoices
|
||||
NEW: Option "Simplify interface for blind persons"
|
||||
NEW: Generic cash fence feature (compatible with several POS modules)
|
||||
|
||||
For developers:
|
||||
NEW: Add lib for multiselect with checkboxes
|
||||
NEW: Add function isValidMXRecord
|
||||
NEW: Add hook changeRoundingMode in update_price
|
||||
NEW: Add hook formconfirm to contractcard
|
||||
NEW: Add hook for virtual stock
|
||||
NEW: ADD url to see the last version of a external module
|
||||
NEW: Can enable a module, even external module, from command line
|
||||
NEW: Can set a tooltip help text on extrafields
|
||||
NEW: Add product search from barcode via REST api
|
||||
NEW: can add documents on agenda events using API REST
|
||||
NEW: Can set the datestart and dateend of cron job into module descriptor
|
||||
NEW: Close #9296 Add field ref_ext into llx_categorie
|
||||
NEW: move ticket dictionary in API /setup
|
||||
NEW: PHPUnitTest on Loan class #3163
|
||||
NEW: Code changes to be more compatible with PSR2
|
||||
NEW: Removed trigger USER_LOGOUT, USER_LOGIN, USER_LOGIN_FAILED (Some hooks are already dedicated for that)
|
||||
NEW: Add agenda documents in API REST
|
||||
NEW: Add "checked" field for new list engine compatibility
|
||||
NEW: REST API improvements
|
||||
NEW: Save external payment IDs into table of payment
|
||||
NEW: triggers add commercial and del commercial
|
||||
NEW: #9236 Allow to import shipment lines via API
|
||||
NEW: ADD civility list in API
|
||||
NEW: support selllist in the module builder
|
||||
NEW: optional param to show a specific extrafield
|
||||
NEW: hook formConfirm always called if hooked
|
||||
NEW: hook on dispatch order fourn
|
||||
|
||||
WARNING:
|
||||
|
||||
Following changes may create regressions for some external modules, but were necessary to make Dolibarr better:
|
||||
* If you use some links like viewimages.php?modulepart=mycompany&file=... in your external modules, you must
|
||||
replace them with links like viewimages.php?modulepart=mycompany&file=logos/... (note that link change only for
|
||||
modulepart=mycompany that now works like others).
|
||||
* Hidden option MAIN_PDF_SHIPPING_DISPLAY_AMOUNT_HT has been renamed into SHIPPING_PDF_DISPLAY_AMOUNT_HT
|
||||
* Remove the no more used and deprecated dol_print_graph function
|
||||
|
||||
|
||||
***** ChangeLog for 8.0.4 compared to 8.0.3 *****
|
||||
FIX: #10030 better german chart
|
||||
FIX: #10036
|
||||
FIX: #10080 Supplier translations are in english
|
||||
FIX: #10183 using backport of fix done in 9.0
|
||||
FIX: #10218 Bad redirection after deleting a user or group
|
||||
FIX: #3234
|
||||
FIX: #6580
|
||||
FIX: #8741
|
||||
FIX: #9629 #9625
|
||||
FIX: #9971
|
||||
FIX: avoid Class 'AdherentType' not found
|
||||
FIX: Can relaunch install on v8
|
||||
FIX: Can't create a thirdparty from member if customer code is mandatory.
|
||||
FIX: Can't delete a line of minimal stock per warehouse
|
||||
FIX: check if "entity" is already defined in "$param"
|
||||
FIX: contact/address tab issue when changing company
|
||||
FIX: contact/adress tab: when changing company ajax combo, the first contact change is not taken into account
|
||||
FIX: CVE-2018-19799
|
||||
FIX: CVE-2018-19992
|
||||
FIX: CVE-2018-19993
|
||||
FIX: CVE-2018-19994
|
||||
FIX: CVE-2018-19995 and CVE-2018-19998
|
||||
FIX: Error reported when creation of thirdparty from member fails
|
||||
FIX: export only prices of the current entity !
|
||||
FIX: Extrafields on shipment module
|
||||
FIX: filter on product category doesn't work
|
||||
FIX: form actions: select_type_actions could be too small + bad $db init
|
||||
FIX: form actions: select_type_actions could be too small + bad init
|
||||
FIX: fourn payment modes musn't be available on customer docs
|
||||
FIX: Function updatePrice with wrong parameters
|
||||
FIX: hidden extrafield
|
||||
FIX: if qty is 0
|
||||
FIX: If we change customer/supplier rule we can't edit old thirdparty.
|
||||
FIX: lang not loaded
|
||||
FIX: Lines are not inserted correctly if VAT have code
|
||||
FIX: marge sign
|
||||
FIX: Method setValid not found
|
||||
FIX: Migration do not create not used table
|
||||
FIX: missing action "edit" for the hook
|
||||
FIX: missing field "visible"
|
||||
FIX: Missing last month on vat report per month
|
||||
FIX: mode is only customer in stats fichinter
|
||||
FIX: OppStatusShort doesn't exists
|
||||
FIX: Remote ip detection was wrong with proxy (example: cloudflare)
|
||||
FIX: Removed not use table
|
||||
FIX: Replenishment with option STOCK_ALLOW_ADD_LIMIT_STOCK_BY_WAREHOUSE
|
||||
FIX: responsive
|
||||
FIX: Same on customer card
|
||||
FIX: same on lines
|
||||
FIX: screen size fall
|
||||
FIX: Select first mail model by default
|
||||
FIX: slow SQL query on creating a new supplier invoice
|
||||
FIX: sql query performance on list_qualified_avoir_supplier_invoices.
|
||||
FIX: supplier order list keep socid
|
||||
FIX: Same on customer card
|
||||
FIX: same on lines
|
||||
FIX: screen size fall
|
||||
FIX: Select first mail model by default
|
||||
FIX: slow SQL query on creating a new supplier invoice
|
||||
FIX: sql query performance on list_qualified_avoir_supplier_invoices.
|
||||
FIX: supplier order list keep socid
|
||||
FIX: Vendor translations are in english
|
||||
FIX: Warning: count()
|
||||
FIX: We want to be able to send PDF of paid invoices
|
||||
|
||||
***** ChangeLog for 8.0.3 compared to 8.0.2 *****
|
||||
FIX: #9161
|
||||
FIX: #9432
|
||||
FIX: #9432 Assign yourself as a commercial when you don't have permission to see all thirds
|
||||
FIX: #9510
|
||||
FIX: #9567
|
||||
FIX: According to french law, if seller is in France and buyer isn't in UE and isn't a company, TVA used = TVA product
|
||||
FIX: Amount when using mutlicurrency on PDF
|
||||
FIX: Backup of database without mysqladmin available from cron.
|
||||
FIX: Bad label on delete button
|
||||
FIX: bad link in notification
|
||||
FIX: Bad position of hook formattachOptions call
|
||||
FIX: Can't create shipping if have shipping line's extrafields
|
||||
FIX: check !empty exclude select element
|
||||
FIX: content lost when editing a label with "
|
||||
FIX: correct migration of old postgresql unique key
|
||||
FIX: credit note progression
|
||||
FIX: default accounting accounts on loan creation #9643
|
||||
FIX: Delete of draft invoice
|
||||
FIX: deletion on draft is allowed if we are allwoed to create
|
||||
FIX: Do not show check box if not applicable
|
||||
FIX: exclude element of the select
|
||||
FIX: extrafields of taks not visible in creation
|
||||
FIX: filter on employee
|
||||
FIX: invoice stats: situation invoices were not counted
|
||||
FIX: keep external module element when adding resource
|
||||
FIX: langs fr
|
||||
FIX: Link template invoice to contract
|
||||
FIX: Look and feel v8. Missing button "Create category"
|
||||
FIX: Menu to show/edit Users categories was missing
|
||||
FIX: missing name alias field in societe import/export #9091
|
||||
FIX: missing symbol for indian rupies
|
||||
FIX: Missing transaction around action
|
||||
FIX: modify parenting before task deletion
|
||||
FIX: nb of session in title
|
||||
FIX: need to filter on current entity on replenish
|
||||
FIX: number mailing for a contact with multicompany
|
||||
FIX: Option for prof id mandatory not working with custom type of company
|
||||
FIX: Option MAIN_DISABLE_NOTES_TAB #9611
|
||||
FIX: Pagination stats
|
||||
FIX: pdf typhon: order reference duplicate
|
||||
FIX: position 0 for emails templates
|
||||
FIX: previous situation invoice selection
|
||||
FIX: Product marge tabs on product card
|
||||
FIX: Product margin tab and credit note
|
||||
FIX: propal pdf: missing parenthesis for customs code
|
||||
FIX: properties on proposal must not be modified if error
|
||||
FIX: qty not visible for a lot when making shipment on a dedicated stock
|
||||
FIX: Quick hack to solve pb of bad definition of public holidays
|
||||
FIX: remain to pay for credit note was wrong on invoice list
|
||||
FIX: replenish wasn't caring about supplier price min quantity #9561
|
||||
FIX: Required extrafield value numeric should accept '0'
|
||||
FIX: ressource list with extrafields
|
||||
FIX: restore last seach criteria
|
||||
FIX: Selection of addmaindocfile is lost on error
|
||||
FIX: Sending of reminder for expired subscriptions
|
||||
FIX: shared link ko on proposals
|
||||
FIX: showOptionals: column mismatches
|
||||
FIX: situation invoice total with credit note
|
||||
FIX: situation invoice prev percent
|
||||
FIX: special code on create supplier invoice from supplier order
|
||||
FIX: Symbol of currency in substitution variables
|
||||
FIX: The max size for upload file was not corectly shown
|
||||
FIX: the member e-mail on resign and validation.
|
||||
FIX: thirdparty property of object not loaded when only one record
|
||||
FIX: title
|
||||
FIX: Title problem on admin RSS module
|
||||
FIX: Tooltip on invoice widget
|
||||
FIX: Total of timespent
|
||||
FIX: trackid into email sent from member module.
|
||||
FIX: translation in select unit form
|
||||
FIX: use discount with multicurrency
|
||||
FIX: Variable name
|
||||
FIX: When we delete a product, llx_product_association rows are not deleted
|
||||
FIX: when we're just admin and not super admin, if we create new user with transverse mode, we don't see it then we can't add him in usergroup
|
||||
FIX: wrong function name
|
||||
FIX: wrong occurence number of contract on contact card, we must only count externals
|
||||
FIX: wrong value for module part and return access denied
|
||||
FIX: Wrong variable name
|
||||
FIX: XSS vulnerability reported by Mary Princy E
|
||||
|
||||
***** ChangeLog for 8.0.2 compared to 8.0.1 *****
|
||||
FIX: #8452
|
||||
FIX: #9043
|
||||
FIX: #9316 Error when listing invoices
|
||||
FIX: #9317
|
||||
FIX: #9353 Bug: html error - div inside span on graphs
|
||||
FIX: #9355
|
||||
FIX: #9393 inconsistency behaviour. option FACTURE_ENABLE_NEGATIVE_LINES
|
||||
FIX: #9394
|
||||
FIX: #9396
|
||||
FIX: #9403
|
||||
FIX: #9412
|
||||
FIX: #9497
|
||||
FIX: Add paypal error message in alert email when online payment fails.
|
||||
FIX: better compatibility with multicompany
|
||||
FIX: capital must be empty and not 0 if undefined
|
||||
FIX: character making error on bill list
|
||||
FIX: Entering negative price on order.
|
||||
FIX: Expedition not showing extrafields on creation.
|
||||
FIX: Homepage links were using wrong topmenus
|
||||
FIX: inconsistency behaviour on option FACTURE_ENABLE_NEGATIVE_LINES
|
||||
FIX: invert mime type and name.
|
||||
FIX: invoice popup hide localtax2 and 3 if not defined.
|
||||
FIX: Lose filter on payment type or category after a sort on invoice list.
|
||||
FIX: Maxi debug to allow to load chart of account with multicompany.
|
||||
FIX: Missing translation in predefined email to membership renewal.
|
||||
FIX: Mixing tickets of different thirdparties.
|
||||
FIX: "Other ..." link so the "Back to" link works.
|
||||
FIX: PDF address: handle when contact thirdparty is different from thirdparty of document
|
||||
FIX: Problems with permissions of module to record payment of salaries
|
||||
FIX: remove debug
|
||||
FIX: Several fixes on the management of minimal amount for orders
|
||||
FIX: wrong var name
|
||||
|
||||
***** ChangeLog for 8.0.1 compared to 8.0.0 *****
|
||||
FIX: #9258
|
||||
FIX: #9328
|
||||
FIX: #9337
|
||||
FIX: adding GROUP BY for PostgreSQL
|
||||
FIX: API template for list pages in module builder
|
||||
FIX: API template for record page to delete a record
|
||||
FIX: a removed option was still in setup
|
||||
FIX: badge on time spent on project and tasks
|
||||
FIX: Delete file on smartphone
|
||||
FIX: Fetch function will fetch comments
|
||||
FIX: Fetch task will now fetch comments
|
||||
FIX: $fk_account is always empty, must be $soc->fk_account
|
||||
FIX: Force stripe api version to avoid trouble if we update stripe api
|
||||
FIX: get_product_vat_for_country functions.lib.php
|
||||
FIX: Get templates in a forced language
|
||||
FIX: hook on dispatch order fourn
|
||||
FIX: Language selection lost if error during creation of email template
|
||||
FIX: Look and feel v8
|
||||
FIX: propal.class.php
|
||||
FIX: Add calls to fetchComments function
|
||||
FIX: Remove fetchComments from project and task fetch function
|
||||
FIX: remove internal property isextrafieldmanaged from API returns
|
||||
FIX: sql error
|
||||
FIX: table llx_chargessociales doesn't exists
|
||||
FIX: trans on null object
|
||||
FIX: vat rate code not returned by get_product_vat_for_country
|
||||
FIX: warning for late template invoices to remove when suspended
|
||||
FIX: Add hidden option MAIN_xxx_IN_SOURCE_ADDRESS to solve legal issues on PDF
|
||||
FIX: Table llx_facture_rec_extrafields missing after migration
|
||||
|
||||
|
||||
***** ChangeLog for 8.0.0 compared to 7.0.0 *****
|
||||
For Users:
|
||||
NEW: Experimental module: Ticket
|
||||
NEW: Experimental module: WebDAV
|
||||
NEW: Accept anonymous events (no user assigned)
|
||||
NEW: Accountancy - Add import on general ledger
|
||||
NEW: Accountancy - Show journal name on journal page and hide button draft export (Add an option in admin)
|
||||
NEW: Can create event from record card of a company and/or member
|
||||
NEW: Add a button to create Stripe customer from the customer Payment mode tab
|
||||
NEW: Add accounting account number on product tooltip
|
||||
NEW: Add any predefined mail content
|
||||
NEW: Add arrows to navigate into containers in experimental website module
|
||||
NEW: Add a tab to specify accountant/auditor of the company
|
||||
NEW: Add Date delivery and Availability on Propals List
|
||||
NEW: Add date in goods reception supplier order table
|
||||
NEW: Add delivery_time_days of suppliers in export profile
|
||||
NEW: Add Documents'tab to expedition module
|
||||
NEW: Use dol_print_phone in thirdparty list page to format phone
|
||||
NEW: Add entry for the GDPR contact
|
||||
NEW: Add extrafield type "html"
|
||||
NEW: Add file number in accountant card and update export filename
|
||||
NEW: Add files management on products lot
|
||||
NEW: add filter on project task list
|
||||
NEW: Add hidden option COMPANY_AQUARIUM_CLEAN_REGEX to clean generated
|
||||
NEW: add internal stripe payment page for invoice
|
||||
NEW: Add key __USER_REMOTE_IP__ into available substitution variables
|
||||
NEW: Add link between credit note invoice and origin
|
||||
NEW: Add linked file tab to vat
|
||||
NEW: add link to stripe's info in bank menu
|
||||
NEW: Add margin filters
|
||||
NEW: Add mass action enable/disable on cron job list
|
||||
NEW: Add mass action on project's list to close projects
|
||||
NEW: Add method to register distributed payments on invoices
|
||||
NEW: Add multicurrency support for product buy price for supplier propales, orders and invoices
|
||||
NEW: Add name of day in the timesheet input page per day.
|
||||
NEW: add new parameters for tcpf encryption
|
||||
NEW: add optional esign field in pdf propal
|
||||
NEW: Add option BANK_ACCOUNT_ALLOW_EXTERNAL_DOWNLOAD
|
||||
NEW: Add option CONTRACT_SYNC_PLANNED_DATE_OF_SERVICES
|
||||
NEW: Add param $dolibarr_main_restrict_ip in config file to limit ips
|
||||
NEW: add pdf function to check if pdf file is protected/encrypted
|
||||
NEW: Add pdf template for stock/warehouse module
|
||||
NEW: Add phone format for a lot of countries
|
||||
NEW: Add product and product categories filters on customer margins
|
||||
NEW: Add product categories filter on product margin
|
||||
NEW: Add romanian chart of accounts
|
||||
NEW: Add stats in salaries module
|
||||
NEW: add stripe transaction
|
||||
NEW: Add tab contact on supplier proposals
|
||||
NEW: Add total of time spent in timespent page at top of page too.
|
||||
NEW: Add trigger CONTRACT_MODIFY
|
||||
NEW: Add triggers on ECM object and add fill src_object_type/id fields
|
||||
NEW: Add type of website container/page into dictionary
|
||||
NEW: advance target filtering can be used everywhere with tpl and fk_element
|
||||
NEW: Allow negative quantity for dispatch (supplier order)
|
||||
NEW: bank reconcile: checkbox to select all bank operations
|
||||
NEW: Better performance with openldap
|
||||
NEW: Can add filter actiontype and notactiontype on event ical export
|
||||
NEW: Can add product in supplier order/invoice even w/o predefined price
|
||||
NEW: cancel orders on massaction
|
||||
NEW: Can crop image files attached in "document" tabs of a member
|
||||
NEW: Can delete dir content in media and ECM module recursively
|
||||
NEW: Can dispatch if more than ordered (if hidden option set)
|
||||
NEW: Can edit the text color for title line of tables
|
||||
NEW: Can enter time spent from the list of time spent of project
|
||||
NEW: Can export leave requests
|
||||
NEW: Can filter on account range in general ledger grouped by account
|
||||
NEW: Can filter on country and taxid into the binding page
|
||||
NEW: Can filter on progression in timesheet
|
||||
NEW: Can fix the bank account of a payment if payment not conciliated
|
||||
NEW: Can force usage of shared link for photo of products
|
||||
NEW: Can get template of email from its label
|
||||
NEW: Can see Unit Purchase Value of product in stock movement
|
||||
NEW: Can select from the user list into send form email (For field to and CC)
|
||||
NEW: Can select sample to use when creating a new page
|
||||
NEW: can send mail from project card
|
||||
NEW: Can set position of images in module tickets
|
||||
NEW: Can set the reply-to into email sent
|
||||
NEW: Can set the start/end date of service line in invoice templates
|
||||
NEW: Can share any file from the "Document" tab.
|
||||
NEW: Can sort on priority in task scheduler list
|
||||
NEW: Can sort order of files in attach tab for leave and expensereport
|
||||
NEW: Can use setValueFrom without user modification field
|
||||
NEW: Cat set the encryption algorithm for extrafields of type password
|
||||
NEW: check idprof1 for country pt
|
||||
NEW: default add action: new param $backurlforcard to redirect to card
|
||||
NEW: default warehouse field for products + prefill warehouses when dispatching supplier orders
|
||||
NEW: Display price HT on all commercial area boards
|
||||
NEW: display total on contract service list
|
||||
NEW: display weight volume in proposal
|
||||
NEW: Edit of extrafields position page on the edit form
|
||||
NEW: Experimental DAV module provides a public and private directory
|
||||
NEW: export filter models can be share or not by user
|
||||
NEW: Externalsite module can accept iframe content.
|
||||
NEW: Filter export model is now by user
|
||||
NEW: Finish implementation of option PRODUIT_CUSTOMER_PRICES_BY_QTY_MULTIPRICES
|
||||
NEW: generalize use of button to create new element from list
|
||||
NEW: hidden conf AGENDA_NB_WEEKS_IN_VIEW_PER_USER to set nb weeks to show into per user view
|
||||
NEW: hidden conf to assign category to thirparty that are neither customer nor prospect or supplier
|
||||
NEW: hidden conf to set nb weeks to show into user view
|
||||
NEW: hidden option MAIN_DISABLE_FREE_LINES
|
||||
NEW: improve way of adding users/sales representative to thirdparty
|
||||
NEW: Introduce option THIRDPARTY_QUICKSEARCH_ON_FIELDS to personalize fields use to search on quick search.
|
||||
NEW: Introduce permission "approve" for "leave request" like for "expense report"
|
||||
NEW: Load product data optional fields to the line -> enables to use "line_options_{extrafield}"
|
||||
NEW: Look and feel v8 - Show Picto "+" on all links "Add record"
|
||||
NEW: Look and feel v8: Use a different picto for delete and unlink
|
||||
NEW: mail templates for projects
|
||||
NEW: Module variant supported on services
|
||||
NEW: monthly VAT report show "Claimed for the period" + "Paid during this
|
||||
NEW: Mutualize code for action="update_extras"
|
||||
NEW: On invoice card, show accounting account linked
|
||||
NEW: Online payment of invoice and subscription record the payment
|
||||
NEW: OnSearchAndListGoOnCustomerOrSupplierCard conf
|
||||
NEW: Optimize load of hooks classes (save 1-5Kb of memory)
|
||||
NEW: Option MAIN_SHOW_REGION_IN_STATE renamed into MAIN_SHOW_REGION_IN_STATE_SELECT are more complete
|
||||
NEW: Option to force all emails recipient
|
||||
NEW: Hidden option to send to salaries into emails forms
|
||||
NEW: order minimum amount
|
||||
NEW: add price in burger menu on mouvement list
|
||||
NEW: Report a list of leave requests for a month
|
||||
NEW: Section of files generated by mass action not visible if empty
|
||||
NEW: send mails from project card
|
||||
NEW: Show also size in bytes in tooltip if visible unit is not bytes
|
||||
NEW: Show keyboard shortcut of nav arrow into tooltip
|
||||
NEW: Show last result code of cron jobs in error in red
|
||||
NEW: Show region in company info & Global option to show state code MAIN_SHOW_STATE_CODE
|
||||
NEW: Show total number of records by category
|
||||
NEW: Show total of time consumed in week in time spent entry page
|
||||
NEW: Stripe online payments reuse the same stripe customer account
|
||||
NEW: Suggest link to pay online for customer orders
|
||||
NEW: supplier credit notes is now supported like for customer credit notes
|
||||
NEW: supplier order/order lines export: add supplier product ref
|
||||
NEW: supplier relative discounts
|
||||
NEW: Support alternative aliases of page name in website
|
||||
NEW: syslog file autoclean
|
||||
NEW: thirdparty categ filter on lists
|
||||
NEW: Use a css style for weekend in time spent
|
||||
NEW: Use common substitution rule for language to get translation in ODT
|
||||
NEW: Variable __ONLINE_PAYMENT_URL__ available in email templates
|
||||
|
||||
For developers:
|
||||
NEW: class reposition can also work on POST (not only GET)
|
||||
NEW: add a hook in dol_print_phone
|
||||
NEW: The field "visible" on extrafield can accept expression as condition
|
||||
NEW: Upgrade of Stripe lib to 6.4.1
|
||||
NEW: work on CommonObject 'array' field typeNew common object array
|
||||
NEW: method Form::selectArrayFilter() + use in left menu search
|
||||
NEW: [REST API] Add the possibility to remove a category from a thirdparty
|
||||
NEW: doActions on categorycard
|
||||
NEW: add "moreHtmlRef" hook
|
||||
NEW: add hook for more permissions control
|
||||
NEW: add hook moreHtmlStatus to complete to status on banners
|
||||
NEW: Add hook printEmail
|
||||
NEW: Add hook setContentSecurityPolicy
|
||||
NEW: Add password_hash as a hash algorithm
|
||||
NEW: Add dol_is_link function
|
||||
NEW: Adds a contact to an invoice with REST API
|
||||
NEW: Adds a payment for the list of invoices given as parameter
|
||||
NEW: adds billing contacts ids to REST API returns
|
||||
NEW: Add showempty parameter in country selection
|
||||
NEW: add printUserListWhere hook
|
||||
NEW: add "printUserPasswordField" hooks
|
||||
NEW: Call to trigger on payment social contribution creation
|
||||
NEW: Call to trigger on social contribution creation
|
||||
NEW: hook getnomurltooltip is replaced with hook getNomUrl more powerfull
|
||||
|
||||
WARNING:
|
||||
|
||||
Following changes may create regressions for some external modules, but were necessary to make Dolibarr better:
|
||||
* Remove old deprecated hook 'insertExtraFields'. Triggers must be used for action on CRUD events.
|
||||
* Hook 'maildao' was renamed into 'mail' into the method sendfile that send emails, and method was renamed from
|
||||
'doaction' into 'sendMail'.
|
||||
* Rename trigger CONTRACT_SERVICE_ACTIVATE into LINECONTRACT_ACTIVATE and
|
||||
CONTRACT_SERVICE_CLOSE into LINECONTRACT_CLOSE
|
||||
* Remove triggers *_CLONE. The trigger CREATE with context 'createfromclone' is already called so this is
|
||||
a duplicated feature. Cloning is not a business event, the business event is CREATE, so no trigger required.
|
||||
* PHP 5.3 is no more supported. Minimum PHP is now 5.4+
|
||||
* Remove the old deprecated code of doActions and getInstanceDao in canvas. The doActions of standard hooks are
|
||||
already available and are better.
|
||||
* Removed method fetch_prods() and get_each_prod() not used, keep only get_arbo_each_prod() that is better.
|
||||
* The hook contaxt commcard has been renamed thirdpartycomm
|
||||
* The hook contaxt thirdpartycard has been renamed thirdpartycontact
|
||||
* Remove method Categorie:get_nb_categories() that was not used.
|
||||
* Hook getnomurltooltip provide a duplicate feature compared to hook getNomUrl so all hooks getnomurltooltip
|
||||
are now replaced with hook getNomUrl.
|
||||
* The substitution key __CONTACTCIVNAME__ is no longer present, it has been replaced by __CONTACT_NAME_{TYPE}__
|
||||
where {TYPE} is contact type code (BILLING, SHIPPING, CUSTOMER, ... see contact type dictionnary).
|
||||
|
||||
|
||||
***** ChangeLog for 7.0.5 compared to 7.0.4 *****
|
||||
FIX: #3234
|
||||
FIX: #6580
|
||||
FIX: #8741
|
||||
FIX: #9934
|
||||
FIX: avoid Class 'AdherentType' not found
|
||||
FIX: Can't create a thirdparty from member if customer code is mandatory.
|
||||
FIX: Can't generate invoice pdf
|
||||
FIX: contact/adress tab: when changing company ajax combo, the first contact change is not taken into account
|
||||
FIX: Error generating ODT when option to use contact on doc on
|
||||
FIX: Error reported when creation of thirdparty from member fails
|
||||
FIX: filter on product category doesn't work
|
||||
FIX: form actions: select_type_actions could be too small + bad init
|
||||
FIX: fourn payment modes musn't be available on customer docs
|
||||
FIX: Function updatePrice with wrong parameters
|
||||
FIX: If we change customer/supplier rule we can't edit old thirdparty.
|
||||
FIX: Interface regression for bind people. Fix option MAIN_OPTIMIZEFORTEXTBROWSER
|
||||
FIX: Lines are not inserted correctly if VAT have code
|
||||
FIX: OppStatusShort doesn't exists
|
||||
FIX: pdf typhon: order reference duplicate
|
||||
FIX: propal pdf: missing parenthesis for customs code
|
||||
FIX: Same on customer card
|
||||
FIX: same on lines
|
||||
FIX: Select first mail model by default
|
||||
FIX: sql query performance on list_qualified_avoir_supplier_invoices.
|
||||
FIX: task time screen: last fix was overkill
|
||||
FIX: task time screen: prevent users with access to all project from assigning to tasks they're not allowed to do
|
||||
FIX: use discount with multicurrency
|
||||
FIX: Variable name
|
||||
FIX: We want to be able to send PDF of paid invoices
|
||||
FIX: When delete a product, llx_product_association rows are not deleted
|
||||
FIX: wrong occurence number of contract on contact card, we must only count externals
|
||||
|
||||
***** ChangeLog for 7.0.4 compared to 7.0.3 *****
|
||||
FIX: #8984 button create expense report
|
||||
FIX: #9032
|
||||
FIX: #9161
|
||||
FIX: #9328
|
||||
FIX: According to french law, if seller is in France and buyer isn't in UE and isn't a company, TVA used = TVA product
|
||||
FIX: Add calls to fetchComments function
|
||||
FIX: better compatibility with multicompany
|
||||
FIX: case when we valid form with keyboard
|
||||
FIX: character making error on bill list
|
||||
FIX: check !empty exclude select element
|
||||
FIX: combo into popup become crazy with IE10
|
||||
FIX: combo of stock in popup are crazy in IE
|
||||
FIX: Deletion of files in migration
|
||||
FIX: exclude element of the select
|
||||
FIX: extrafieldkey
|
||||
FIX: Fetch function will fetch comments
|
||||
FIX: Fetch task will now fetch comments
|
||||
FIX: filter supplier invoice list by societe name.
|
||||
FIX: $fk_account is always empty, must be $soc->fk_account
|
||||
FIX: Force stripe api version to avoid trouble if we update stripe api
|
||||
FIX: getEntity project and not projet
|
||||
FIX: Get templates in a forced language
|
||||
FIX: global $mysoc missing (to avoid php notice on lines 279, 280 & 281)
|
||||
FIX: Injection
|
||||
FIX: invoice stats: situation invoices were not counted
|
||||
FIX: keep context filter on contact list on change column displayed
|
||||
FIX: Keep same project when creating shipping from order
|
||||
FIX: langs fr
|
||||
FIX: Lose filter on payment type or category after a sort on invoice list
|
||||
FIX: Missing behavior
|
||||
FIX: missing hook to edit sql
|
||||
FIX: multicompany compatibility !
|
||||
FIX: need to filter on current entity on replenish
|
||||
FIX: Option MAIN_DISABLE_NOTES_TAB #9611
|
||||
FIX: page must always be 0 when we search (to avoid case : when we're on page 3 and we're looking for a precise thirdparty, we stay on page 3 and nothing's displaied)
|
||||
FIX: Pagination on related item pages
|
||||
FIX: Pagination on withdraw request list
|
||||
FIX: PDF address: handle when contact thirdparty different from document thirdparty
|
||||
FIX: PHP warning, undefined index notnull
|
||||
FIX: Product marge tabs on product card
|
||||
FIX: Product margin tab and credit note
|
||||
FIX: propal: correctly preset project when creating with origin/originid
|
||||
FIX: remain to pay for credit note was wrong on invoice list
|
||||
FIX: remove debug
|
||||
FIX: Remove fetchComments from project and task fetch function
|
||||
FIX: remove rowid for multicompany compatibility
|
||||
FIX: Search on Ref project on order list
|
||||
FIX: search on ref project on propal list
|
||||
FIX: showOptionals: column mismatches
|
||||
FIX: SQL Injections reported by mu shcor (ADLab of Venustech)
|
||||
FIX: stock replenish with multientity
|
||||
FIX: table llx_chargessociales doesn't exists
|
||||
FIX: we must see number of all shared projects
|
||||
FIX: when stock is empty for current entity but > 0 in other entity, until this commit product wasn't displaied on replenishment, it must depends on multientity stock sharing
|
||||
FIX: when we're just admin and not super admin, if we create new user with transverse mode, we don't see it then we can't add him in usergroup
|
||||
FIX: wrong function name
|
||||
FIX: Wrong position of firstname lastname
|
||||
FIX: wrong value for module part and return access denied
|
||||
FIX: Wrong variable and trigger name
|
||||
|
||||
***** ChangeLog for 7.0.3 compared to 7.0.2 *****
|
||||
FIX: 7.0 task contact card without withproject parameters
|
||||
FIX: #8722
|
||||
FIX: #8762
|
||||
FIX: #8813
|
||||
FIX: #8858 #8860 Backport better compatibility fix
|
||||
FIX: #8893 to get formatted price as substitution vars
|
||||
FIX: Avoid converting into reduction twice and draft invoice
|
||||
FIX: bad result on fetch ProductStockEntrepot
|
||||
FIX: Bad substitution key used for default send proposal email
|
||||
FIX: button to pay still visible when amount null used
|
||||
FIX: clause must not be there
|
||||
FIX: Contact tab not visible when using canvas
|
||||
FIX: dol_delete_file must work in a context without db handler loaded
|
||||
FIX: entity test must be on product_fourn_price table and not product table
|
||||
FIX: Fetch shipping will now fetch project id
|
||||
FIX: If we enable 3 steps for supplier order approbation, we must not delete all fourn rights def.
|
||||
FIX: intervention: extrafield error when calling insertExtrafields
|
||||
FIX: It's not possible to remove a contact which is assigned to an event #8852
|
||||
FIX: javascript showempty error
|
||||
FIX: Keep supplier proposal price for supplier order
|
||||
FIX: link for projets not linked to a thirdparties
|
||||
FIX: Missing extrafields in export of stock or products
|
||||
FIX: missing filters during ordering
|
||||
FIX: missing filters during reordering
|
||||
FIX: missing parenthesis
|
||||
FIX: need to filter on aa.entity for same accounting accounts available in several entities
|
||||
FIX: picto for type in product link in accountany list is wrong
|
||||
FIX: Problems in accountancy module when using multicompany module.
|
||||
FIX: proposal: missing contact type translation key
|
||||
FIX: pu_ht_devise was not converted to numeric so decimals were lost when calculating total_ht_devise
|
||||
FIX: Select user on add time spent form
|
||||
FIX: shipment: fk_proje(c)t not handled in fetch() and update() methods
|
||||
FIX: sometimes amounts are identical but php find them different.
|
||||
FIX: supplier order: product supplier ref not saved on addline
|
||||
FIX: test is_erasable() must be done before call function delete() too to avoid delete invoice with &action=delete in url
|
||||
FIX: wrong var name $search_month_lim
|
||||
|
||||
***** ChangeLog for 7.0.2 compared to 7.0.1 *****
|
||||
FIX: #8023
|
||||
FIX: #8259 can't update contact birthday with REST API
|
||||
FIX: #8359
|
||||
FIX: #8389
|
||||
FIX: #8478 !empty instead of count to avoid warning
|
||||
FIX: #8488
|
||||
FIX: #8559 Bug to generate cheque receipt
|
||||
FIX: #8571
|
||||
FIX: #8574
|
||||
FIX: #8580
|
||||
FIX: #8650
|
||||
FIX: actioncomm export: type filtering not working
|
||||
FIX: Add a test to avoid to reset binding by error.
|
||||
FIX: addline on invoice supplier manage rank on its own if not provided
|
||||
FIX: Add warning when expense report line not into range
|
||||
FIX: avoid Error: Call to undefined method mysqli::get_charset()
|
||||
FIX: avoid focus problem when select2 is in a modal dialog window
|
||||
FIX: Binding pages must start on fiscal month not calendar month
|
||||
FIX: button "Classify bill" on supplier order was not visible
|
||||
FIX: Button receive products not visible
|
||||
FIX: can bypass the CSRF protection with url with domain inside
|
||||
FIX: Can't edit option PROJECT_ALLOW_TO_LINK_FROM_OTHER_COMPANY
|
||||
FIX: commonobject: don't require notnull field if default set
|
||||
FIX: CommonObject: don't require 'notnull' field if 'default' set
|
||||
FIX: cron script disabled if module disabled
|
||||
FIX: CVE-2018-10092
|
||||
FIX: CVE-2018-10094
|
||||
FIX: CVE-2018-10095
|
||||
FIX: CVE-2018-9019
|
||||
FIX: CWE-89
|
||||
FIX: Data on income/expense report was always 0
|
||||
FIX: default addupdatedelete actions: uniformize add/update value checks
|
||||
FIX: default currency not set on supplier order creation from commercial menu #8459
|
||||
FIX: delete all product variants of a parent product
|
||||
FIX: Detail per account not visible when total < 0
|
||||
FIX: DOL_AUTOSET_COOKIE was not correctly setting value of cookie
|
||||
FIX: don't print empty date in CommonObject::showOutputField
|
||||
FIX: dont print empty date in CommonObject::showOutputField
|
||||
FIX: Draft invoice must be excluded from report
|
||||
FIX: environment shown on cron card
|
||||
FIX: Error in ContractLigne not return to Contract
|
||||
FIX: extrafields price and double were lost during a failed post.
|
||||
FIX: File name not visible in email preview
|
||||
FIX: filter/sorting on extrafield on contact list from contact tab
|
||||
FIX: Initial month on report income/expense per predefined group
|
||||
FIX: issue #8037
|
||||
FIX: Issue #8455
|
||||
FIX: issue #8470
|
||||
FIX: label in getnomurl projectlist
|
||||
FIX: limit access of email template page to internal users
|
||||
FIX: look and feel v7 "back to" for bookkeeping record
|
||||
FIX: Max nb of generation of recurring invoice should not show warning
|
||||
FIX: missing english name for object
|
||||
FIX: Missing include
|
||||
FIX: missing User object with API REST
|
||||
FIX: modulebuilder: could not create html fields
|
||||
FIX: modulebuilder: handle 'price' fieldtype
|
||||
FIX: multiple creation of same event
|
||||
FIX: Name of user not visible on journalizing expense report payments
|
||||
FIX: Not approved holidays must not be visible into timesheet
|
||||
FIX: Only approved expense report must be journalized
|
||||
FIX: payment term doc-specific label was not used
|
||||
FIX: payment term doc-specific label was not used (issue #8414)
|
||||
FIX: project category is type 6 not 5
|
||||
FIX: Projet is not prefilled when created from overwiew page
|
||||
FIX: Related contact printed in societe agenda
|
||||
FIX: Removed error when no error on accounting setup page
|
||||
FIX: remove var_dump
|
||||
FIX: sanitize setup params
|
||||
FIX: selectForFormsList: entity checked even is object not multi-entity managed
|
||||
FIX: service creation, right is tested regarding the product type
|
||||
FIX: some localtaxes errors
|
||||
FIX: Some report have data when several chart of accounts exists
|
||||
FIX: sql error using no category
|
||||
FIX: SQL Injection CWE-89
|
||||
FIX: Support or multicompany for sheduled jobs
|
||||
FIX: Test on mandatory status when closing proposal failed
|
||||
FIX: to allow IRPF not null even if main VAT is null.
|
||||
FIX: update wrong datetime extrafield
|
||||
FIX: Use priority to define order of sheduled jobs
|
||||
FIX: various modulebuilder-related issues
|
||||
FIX: view of balance before field
|
||||
FIX: weird password autocompletion in Goocle Chrome (issue #8479)
|
||||
FIX: weird password autocompletion in Google Chrome (issue #8479)
|
||||
FIX: When clearing filter, we must not save tmp criterias in session
|
||||
FIX: With x extrafields, request for multicompany label was done x times
|
||||
FIX: several XSS
|
||||
FIX: zip not filtered
|
||||
|
||||
***** ChangeLog for 7.0.1 compared to 7.0.0 *****
|
||||
FIX: #8139 User search does not work if MAIN_USE_OLD_SEARCH_FORM, missing list.php
|
||||
@@ -70,7 +884,7 @@ FIX: Use of undefined constant _ROWS_2
|
||||
FIX: warning when adding ECM files using old photo path
|
||||
|
||||
|
||||
***** ChangeLog for 7.0.0 compared to 6.0.5 *****
|
||||
***** ChangeLog for 7.0.0 compared to 6.0.7 *****
|
||||
For users:
|
||||
NEW: Add a preview icon after files that can be previewed (pdf + images)
|
||||
NEW: When payment is registered, PDF of invoices are also regenerated so payments
|
||||
@@ -357,8 +1171,49 @@ Following changes may create regressions for some external modules, but were nec
|
||||
multicompany module to a version that support Dolibarr v7, everything should work as expected.
|
||||
|
||||
|
||||
***** ChangeLog for 6.0.8 compared to 6.0.7 *****
|
||||
FIX: #8762
|
||||
FIX: #9032
|
||||
FIX: case when we valid form with keyboard
|
||||
FIX: clause must not be there
|
||||
FIX: dol_delete_file must work in a context without db handler loaded
|
||||
FIX: entity test must be on product_fourn_price table and not product table
|
||||
FIX: Fetch shipping will now fetch project id
|
||||
FIX: $fk_account is always empty, must be $soc->fk_account
|
||||
FIX: getEntity project and not projet
|
||||
FIX: If we enable 3 steps for supplier order approbation, we must not delete all fourn rights def.
|
||||
FIX: Keep supplier proposal price for supplier order
|
||||
FIX: langs fr
|
||||
FIX: missing filters during reordering
|
||||
FIX: need to filter on aa.entity for same accounting accounts available in several entities
|
||||
FIX: page must always be 0 when we search (to avoid case : when we're on page 3 and we're looking for a precise thirdparty, we stay on page 3 and nothing's displaied)
|
||||
FIX: PDF address: handle when contact thirdparty different from document thirdparty
|
||||
FIX: propal: correctly preset project when creating with origin/originid
|
||||
FIX: pu_ht_devise was not converted to numeric so decimals were lost when calculating total_ht_devise
|
||||
FIX: remain to pay for credit note was wrong on invoice list
|
||||
FIX: shipment: fk_proje(c)t not handled in fetch() and update() methods
|
||||
FIX: showOptionals: column mismatches
|
||||
FIX: sometimes amounts are identical but php find them different.
|
||||
FIX: test is_erasable() must be done before call function delete() too to avoid delete invoice with &action=delete in url
|
||||
FIX: we must see number of all shared projects
|
||||
FIX: wrong var name
|
||||
|
||||
***** ChangeLog for 6.0.6 compared to 6.0.6 *****
|
||||
***** ChangeLog for 6.0.7 compared to 6.0.6 *****
|
||||
FIX: #8023
|
||||
FIX: #8259 can't update contact birthday with REST API
|
||||
FIX: #8478 !empty instead of count to avoid warning
|
||||
FIX: #8488
|
||||
FIX: actioncomm export: type filtering not working
|
||||
FIX: addline on invoice supplier manage rank on its own if not provided
|
||||
FIX: issue #8037
|
||||
FIX: label in getnomurl projectlist
|
||||
FIX: payment term doc-specific label was not used
|
||||
FIX: payment term doc-specific label was not used (issue #8414)
|
||||
FIX: project category is type 6 not 5 !!
|
||||
FIX: some localtaxes errors
|
||||
FIX: weird password autocompletion in Google Chrome (issue #8479)
|
||||
|
||||
***** ChangeLog for 6.0.6 compared to 6.0.5 *****
|
||||
FIX: #7974 Contract - Invalid reference on the document
|
||||
FIX: #8139
|
||||
FIX: #8139 User search does not work if MAIN_USE_OLD_SEARCH_FORM, missing list.php
|
||||
|
||||
95
README-FR.md
95
README-FR.md
@@ -15,49 +15,55 @@ Dolibarr est distribué sous les termes de la licence GNU General Public License
|
||||
|
||||
## INSTALLER DOLIBARR
|
||||
|
||||
Si vous n'avez pas de connaissances techniques, et que vous recherchez
|
||||
un programme d'installation qui install Dolibarr ERP/CRM en quelques clics,
|
||||
vous devez vous réorienter vers DoliWamp (la version tout-en-un
|
||||
de Dolibarr pour Windows), DoliDeb (la version tout-en-un pour Debian ou
|
||||
Ubuntu) ou DoliRpm (la version tout-en-un de Dolibarr pour Fedora, Redhat,
|
||||
OpenSuse, Mandriva ou Mageia).
|
||||
### Configuration simple
|
||||
|
||||
Vous pouvez les télécharger depuis la rubrique *download* du portail officiel:
|
||||
https://www.dolibarr.org/
|
||||
Si vous avez peu de compétences techniques et que vous souhaitez installer Dolibarr ERP/CRM en quelques clics, vous pouvez utiliser l'une des versions pré-packagées avec les prérequis:
|
||||
|
||||
Si vous avez déjà installé un serveur Web avec PHP et une base de donnée (MariaDb/MySql/PostgreSql),
|
||||
vous pouvez installer Dolibarr avec cette version de la manière suivante:
|
||||
- DoliWamp pour Windows
|
||||
- DoliDeb pour Debian ou Ubuntu
|
||||
- DoliRpm pour Redhat, Fedora, OpenSuse, Mandriva ou Mageia
|
||||
|
||||
- Copier le répertoire "dolibarr" et son contenu dans la racine de votre serveur
|
||||
web, ou bien copier le répertoire sur le serveur et configurer ce serveur pour
|
||||
utiliser "dolibarr/htdocs" comme racine d'un nouveau virtual host (ce second
|
||||
choix requiert des compétences et habilitations en administration du serveur
|
||||
web).
|
||||
|
||||
- Créer un fichier vide "htdocs/conf/conf.php" et attribuer les permissions
|
||||
en lecture et écriture pour le user du serveur web (les permissions en
|
||||
écriture seront supprimées une fois l'installation terminée).
|
||||
Les packages peuvent être téléchargés à partir de [site web officiel] (https://www.dolibarr.org/).
|
||||
|
||||
- Depuis votre navigateur, appeler la page "install/" de dolibarr. L'url dépend
|
||||
du choix fait à la première etape:
|
||||
http://localhost/dolibarr/htdocs/install/
|
||||
ou
|
||||
http://yourdolibarrvirtualhost/install/
|
||||
|
||||
- Suivez les instructions fournies par l'installeur...
|
||||
### Configuration avancée
|
||||
|
||||
Vous pouvez aussi utiliser un serveur Web et une base de données prise en charge (MariaDB, MySQL ou PostgreSQL) pour installer la version standard.
|
||||
|
||||
- Décompressez l'archive .zip téléchargée pour copier le répertoire "dolibarr/htdocs" et tous ses fichiers à la racine du serveur Web ou récupérez-les directement à partir de GitHub (recommandé si vous connaissez git):
|
||||
|
||||
git clone https://github.com/dolibarr/dolibarr -b x.y (où x.y est la version principale comme 3.6, 9.0, ...)
|
||||
|
||||
- Configurez votre serveur Web pour qu'il utilise "*dolibarr/htdocs*" en tant que racine si votre serveur Web ne possède pas déjà de répertoire défini vers lequel pointer.
|
||||
|
||||
- Créez un fichier `htdocs/conf/conf.php` vide et définissez les autorisations d'*écrire* pour l'utilisateur de votre serveur Web (l'autorisation *écrire* sera supprimée une fois l'installation terminée)
|
||||
|
||||
- Depuis votre navigateur, allez à la page "install/" de dolibarr
|
||||
|
||||
L’URL dépendra de la façon dont votre configuration Web a été configurée pour pointer vers votre installation de dolibarr. Cela peut ressembler à:
|
||||
|
||||
http://localhost/dolibarr/htdocs/install/
|
||||
|
||||
ou
|
||||
|
||||
http://localhost/dolibarr/install/
|
||||
|
||||
ou
|
||||
|
||||
http://yourdolibarrvirtualhost/install/
|
||||
|
||||
- Suivez les instructions de l'installateur
|
||||
|
||||
|
||||
## METTRE A JOUR DOLIBARR
|
||||
|
||||
Pour mettre a jour Dolibarr depuis une vieille version vers celle ci:
|
||||
- Ecraser les vieux fichiers dans le vieux repertoire 'dolibarr' par les fichiers
|
||||
Pour mettre à jour Dolibarr depuis une vieille version vers celle ci:
|
||||
- Ecrasez les vieux fichiers dans le vieux répertoire 'dolibarr' par les fichiers
|
||||
fournis dans ce nouveau package.
|
||||
|
||||
- Au prochain accès, Dolibarr proposera la page de "mise a jour" des données (si necessaire).
|
||||
Si un fichier install.lock existe pour vérouiller le processus de mise à jour, il sera demandé de le supprimer manuellement (vous devriez trouver le fichier install.lock dans le répertoire utilisé pour stocker les documents générés ou transféré sur le serveur. Dans la plupart des cas, c'est le répertoire appelé "documents")
|
||||
|
||||
*Note: Le processus de migration peut etre lancé manuellement et plusieurs fois, sans risque, en appelant la page /install/*
|
||||
- Au prochain accès, Dolibarr proposera la page de "mise à jour" des données (si nécessaire).
|
||||
Si un fichier install.lock existe pour verrouiller le processus de mise à jour, il sera demandé de le supprimer manuellement (vous devriez trouver le fichier install.lock dans le répertoire utilisé pour stocker les documents générés ou transférés sur le serveur. Dans la plupart des cas, c'est le répertoire appelé "documents")
|
||||
|
||||
*Note: Le processus de migration peut être lancé manuellement et plusieurs fois, sans risque, en appelant la page /install/*
|
||||
|
||||
|
||||
## CE QUI EST NOUVEAU
|
||||
@@ -94,14 +100,15 @@ Voir fichier ChangeLog.
|
||||
|
||||
- Gestion de marque-pages
|
||||
- Gestion des promesses de dons
|
||||
- Gestion de la TVA NPR (non perçue récupérable - pour les utilisateurs français des DOM-TOM)
|
||||
- Rapports
|
||||
- Imports/Exports des données
|
||||
- Support des codes barres
|
||||
- Calcul des marges
|
||||
- Connectivité LDAP
|
||||
- Intégratn de ClickToDial
|
||||
- Intégration RSS
|
||||
- Intégation Skype
|
||||
- Intégration de système de paiements (Paypal, Strip, Paybox...)
|
||||
- Intégration de système de paiements (Paypal, Stripe, Paybox...)
|
||||
- …
|
||||
|
||||
### Divers:
|
||||
@@ -114,9 +121,18 @@ Voir fichier ChangeLog.
|
||||
- Application simple à utiliser.
|
||||
- Requiert PHP et MariaDb, Mysql ou Postgresql (Voir versions exactes sur https://wiki.dolibarr.org/index.php/Prérequis).
|
||||
- Compatible avec toutes les offres Cloud du marché respectant les prérequis de base de données et PHP.
|
||||
- Code simple et facilement personnalisable (pas de framework lourd; mécanisme de hook et triggers).
|
||||
- APIs.
|
||||
- Génération PDF et ODT des éléments (factures, propositions commerciales, commandes, bons expéditions, etc...)
|
||||
- Code simple et facilement personnalisable (pas de framework lourd; mécanisme de hook et triggers).
|
||||
- Support natif de nombreuses fonctions spécifiques aux pays comme:
|
||||
- La tax espagnole TE et ISPF
|
||||
- Gestion de la TVA NPR (non perçue récupérable - pour les utilisateurs français des DOM-TOM)
|
||||
- La loi française Finance 2016 et logiciels de caisse
|
||||
- La double taxe canadienne
|
||||
- Le timbre fiscal tunisien
|
||||
- Numérotation de facture de l'argentines (avec type A,B,C...)
|
||||
- Compatible avec vos processus RGPD
|
||||
- ...
|
||||
- …
|
||||
|
||||
### Extension
|
||||
@@ -126,7 +142,7 @@ Dolibarr peut aussi être étendu à volonté avec l'ajout de module/application
|
||||
|
||||
## CE QUE DOLIBARR NE PEUT PAS (ENCORE) FAIRE
|
||||
|
||||
Voici un liste de fonctionnalites pas encore gérées par Dolibarr:
|
||||
Voici un liste de fonctionnalités pas encore gérées par Dolibarr:
|
||||
- Dolibarr ne contient pas de module de Gestion de la paie.
|
||||
- Les tâches du module de gestion de projets n'ont pas de dépendances entre elle.
|
||||
- Dolibarr n'embarque pas de Webmail intégré nativement.
|
||||
@@ -135,12 +151,13 @@ Voici un liste de fonctionnalites pas encore gérées par Dolibarr:
|
||||
|
||||
## DOCUMENTATION
|
||||
|
||||
Les documentations utilisateur, développeur et traducteur sont disponible sous forme de ressources de la communautés via la site [Wiki](https://wiki.dolibarr.org).
|
||||
La documentation utilisateur, développeur et traducteur est disponible sous forme de ressources de la communauté via le site [Wiki](https://wiki.dolibarr.org).
|
||||
|
||||
|
||||
## CONTRIBUTING
|
||||
## CONTRIBUER
|
||||
|
||||
Voir le fichier [CONTRIBUTING](https://github.com/Dolibarr/dolibarr/blob/develop/.github/CONTRIBUTING.md)
|
||||
Ce projet existe grâce à ses nombreux contributeurs [[Contribuer](https://github.com/Dolibarr/dolibarr/blob/develop/.github/CONTRIBUTING.md)].
|
||||
<a href="https://github.com/Dolibarr/dolibarr/graphs/contributors"><img src="https://opencollective.com/dolibarr/contributors.svg?width=890&button=false" /></a>
|
||||
|
||||
|
||||
## CREDITS
|
||||
|
||||
63
README.md
63
README.md
@@ -1,6 +1,11 @@
|
||||
# DOLIBARR ERP & CRM
|
||||
|
||||
 
|
||||

|
||||
[](https://houndci.com)
|
||||
|
||||
|6|7|8|9|develop|
|
||||
|----------|----------|----------|----------|----------|
|
||||
||||||
|
||||
|
||||
Dolibarr ERP & CRM is a modern software package to manage your organization's activity (contacts, suppliers, invoices, orders, stocks, agenda…).
|
||||
|
||||
@@ -24,27 +29,6 @@ Other licenses apply for some included dependencies. See [COPYRIGHT](https://git
|
||||
|
||||
## INSTALLING
|
||||
|
||||
### Download
|
||||
|
||||
Releases can be downloaded from [official website](https://www.dolibarr.org/).
|
||||
|
||||
### Install from composer
|
||||
|
||||
If you do not already have Composer installed, you may do so by following the instructions at [getcomposer.org](https://getcomposer.org/). On Linux and macOS, you may run the following commands:
|
||||
|
||||
```bash
|
||||
curl -sS https://getcomposer.org/installer | php
|
||||
mv composer.phar /usr/local/bin/composer
|
||||
```
|
||||
|
||||
On Windows, you can download and run https://getcomposer.org/Composer-Setup.exe
|
||||
|
||||
You can then create a new project
|
||||
|
||||
```bash
|
||||
composer create-project dolibarr/dolibarr erp
|
||||
```
|
||||
|
||||
### Simple setup
|
||||
|
||||
If you have low technical skills and you're looking to install Dolibarr ERP/CRM in just a few clicks, you can use one of the packaged versions:
|
||||
@@ -53,16 +37,23 @@ If you have low technical skills and you're looking to install Dolibarr ERP/CRM
|
||||
- DoliDeb for Debian or Ubuntu
|
||||
- DoliRpm for Redhat, Fedora, OpenSuse, Mandriva or Mageia
|
||||
|
||||
Releases can be downloaded from [official website](https://www.dolibarr.org/).
|
||||
|
||||
### Advanced setup
|
||||
|
||||
You can use a Web server and a supported database (MariaDB, MySQL or PostgreSQL) to install the standard version.
|
||||
|
||||
- Uncompress the downloaded archive
|
||||
- Copy the "dolibarr" directory and all its files inside your web server root or anywhere you'd like and set up your web server to use "*dolibarr/htdocs*" as root for a new web server virtual host (second choice need to be server administrator)
|
||||
- Create an empty `htdocs/conf/conf.php` file and set permissions for your web server user (*write* permissions will be removed once install is finished)
|
||||
- Uncompress the downloaded .zip archive to copy the "dolibarr/htdocs" directory and all its files inside your web server root or get the files directly from GitHub (recommanded if you known git):
|
||||
|
||||
git clone https://github.com/dolibarr/dolibarr -b x.y (where x.y is main version like 3.6, 9.0, ...)
|
||||
|
||||
- Set up your web server to use "*dolibarr/htdocs*" as root if your web server does not have an already defined directory to point to.
|
||||
|
||||
- Create an empty `htdocs/conf/conf.php` file and set *write* permissions for your web server user (*write* permission will be removed once install is finished)
|
||||
|
||||
- From your browser, go to the dolibarr "install/" page
|
||||
|
||||
The URL will depends on choices made in the first step:
|
||||
The URL will depends on how you web setup was setup to point to your dolibarr installation. It may looks like:
|
||||
|
||||
http://localhost/dolibarr/htdocs/install/
|
||||
|
||||
@@ -76,6 +67,11 @@ You can use a Web server and a supported database (MariaDB, MySQL or PostgreSQL)
|
||||
|
||||
- Follow the installer instructions
|
||||
|
||||
### Saas/Cloud setup
|
||||
|
||||
If you don't have time to install it yourself, you can try some commercial 'ready to use' Cloud offers (See https://saas.dolibarr.org). However, this third solution is not free.
|
||||
|
||||
|
||||
|
||||
## UPGRADING
|
||||
|
||||
@@ -125,7 +121,6 @@ See the [ChangeLog](https://github.com/Dolibarr/dolibarr/blob/develop/ChangeLog)
|
||||
- Donations management
|
||||
- Reporting
|
||||
- Data export/import
|
||||
- Thirdparties and/or products categories
|
||||
- Barcodes support
|
||||
- Margin calculations
|
||||
- LDAP connectivity
|
||||
@@ -147,13 +142,15 @@ See the [ChangeLog](https://github.com/Dolibarr/dolibarr/blob/develop/ChangeLog)
|
||||
- Compatible with all Cloud solutions that match MySQL, PHP or PostgreSQL prerequisites.
|
||||
- APIs.
|
||||
- An easy to understand, maintain and develop code (PHP with no heavy framework; trigger and hook architecture)
|
||||
- Support for country specific features:
|
||||
- Support a lot of country specific features:
|
||||
- Spanish Tax RE and ISPF
|
||||
- French NPR VAT rate (VAT called "Non Perçue Récupérable" for DOM-TOM)
|
||||
- Canadian double taxes (federal/province) and other countries using cumulative VAT
|
||||
- Tunisian tax stamp
|
||||
- Argentina invoice numbering using A,B,C...
|
||||
- Compatible with [European directives](http://europa.eu/legislation_summaries/taxation/l31057_en.htm) (2006/112/CE ... 2010/45/UE)
|
||||
- Compatible with European GDPR rules
|
||||
- ...
|
||||
- PDF or ODT generation for invoice, proposals, orders...
|
||||
- …
|
||||
|
||||
@@ -162,7 +159,7 @@ See the [ChangeLog](https://github.com/Dolibarr/dolibarr/blob/develop/ChangeLog)
|
||||
Dolibarr can be extended with a lot of other external application or modules from third party developers available at the [DoliStore](https://www.dolistore.com).
|
||||
|
||||
|
||||
## FUTURE
|
||||
## WHAT DOLIBARR CAN'T DO YET
|
||||
|
||||
These are features that Dolibarr does **not** yet fully support:
|
||||
|
||||
@@ -179,7 +176,8 @@ Administrator, user, developer and translator's documentations are available alo
|
||||
|
||||
## CONTRIBUTING
|
||||
|
||||
See [CONTRIBUTING](https://github.com/Dolibarr/dolibarr/blob/develop/.github/CONTRIBUTING.md) file
|
||||
This project exists thanks to all the people who contribute. [[Contribute](https://github.com/Dolibarr/dolibarr/blob/develop/.github/CONTRIBUTING.md)].
|
||||
<a href="https://github.com/Dolibarr/dolibarr/graphs/contributors"><img src="https://opencollective.com/dolibarr/contributors.svg?width=890&button=false" /></a>
|
||||
|
||||
|
||||
## CREDITS
|
||||
@@ -199,3 +197,8 @@ Follow Dolibarr project on:
|
||||
- [LinkedIn](https://www.linkedin.com/company/association-dolibarr)
|
||||
- [YouTube](https://www.youtube.com/user/DolibarrERPCRM)
|
||||
- [GitHub](https://github.com/Dolibarr/dolibarr)
|
||||
|
||||
|
||||
### Sponsors
|
||||
|
||||
Support this project by becoming a sponsor. Your logo will show up here. 🙏 [[Become a sponsor/backer](https://opencollective.com/dolibarr#backer)]
|
||||
|
||||
15
build/README
15
build/README
@@ -16,18 +16,20 @@ Note: Prerequisites to build tgz, debian, rpm package
|
||||
> apt-get install tar dpkg dpatch p7zip-full rpm zip
|
||||
|
||||
Note: Prerequisites to build autoexe DoliWamp package:
|
||||
> apt-get install wine q4wine
|
||||
> Launch "wine cmd" to check a drive Z: pointing to / exists.
|
||||
> Install InnoSetup
|
||||
For example by running isetup-5.3.9.exe (http://www.jrsoftware.org)
|
||||
> Install WampServer into "C:\Program Files\Wamp"
|
||||
For example by running wampserver2.2e-php5.4.3-httpd-2.4.2-mysql5.5.24-x64.exe (http://www.wampserver.com)
|
||||
> Install WampServer addon to have versions: Apache2.2.11, Mysql5.0.45, Php5.3.0
|
||||
For example by running WampServer2-APACHE2211.exe (http://www.wampserver.com)
|
||||
For example by running wampserver2.5-Apache-2.4.9-Mysql-5.6.17-php5.5.12-32b.exe (http://www.wampserver.com)
|
||||
> Install WampServer addon to have versions: Mysql5.0.45
|
||||
For example by running WampServer2-MYSQL5045.exe (http://www.wampserver.com)
|
||||
For example by running WampServer2-PHP530.exe (http://www.wampserver.com)
|
||||
> To build from Windows (running from makepack-dolibarr.pl script is however
|
||||
recommanded), open file build/exe/doliwamp.iss and click on button "Compile".
|
||||
The .exe file will be build into directory build.
|
||||
|
||||
> Add path to ISCC into PATH windows var:
|
||||
Launch wine cmd, then regedit and add entry int HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\Session Manager\Environment\PATH
|
||||
|
||||
- To build a theme package, launch the script
|
||||
> perl makepack-dolibarrtheme.pl
|
||||
|
||||
@@ -46,9 +48,6 @@ generated packages will not contains this "build" directory.
|
||||
|
||||
We can find in "build", following sub-directories:
|
||||
|
||||
* aps:
|
||||
To build APS package.
|
||||
|
||||
* debian:
|
||||
To build Debian package.
|
||||
|
||||
|
||||
@@ -1,123 +0,0 @@
|
||||
<!-- Application namespaces and APS version (step 9) -->
|
||||
<application xmlns="http://apstandard.com/ns/1" version="1.1">
|
||||
<!-- Application common properties (step 9) -->
|
||||
<name>Dolibarr ERP-CRM</name>
|
||||
<version>__VERSION__</version>
|
||||
<release>__RELEASE__</release>
|
||||
<homepage>http://www.dolibarr.org/</homepage>
|
||||
<vendor>
|
||||
<name>Dolibarr</name>
|
||||
<homepage>http://www.dolibarr.org/</homepage>
|
||||
<icon path="images/appicon_64.png" />
|
||||
</vendor>
|
||||
<packager>
|
||||
<name>Laurent Destailleur</name>
|
||||
<homepage>http://www.nltechno.com</homepage>
|
||||
<uri>uuid:e743ee30-9fe8-11e0-a32e-0025115d642c</uri>
|
||||
</packager>
|
||||
<presentation>
|
||||
<summary>Dolibarr ERP-CRM, the easy to use software to manage small or medium companies, freelancers or foundations</summary>
|
||||
<description>
|
||||
Dolibarr is a free modular software (you see only
|
||||
features you need) to manage small and medium companies, freelancers
|
||||
or foundations.
|
||||
This OpenSource software is designed to provide all features you need to
|
||||
manage information on many aspects of your business
|
||||
into an intuitive and user-friendly graphical interface
|
||||
It's an OpenSource software you can install on a web server or as a
|
||||
standalone software. Dolibarr is designed to provide simplicity to end-user.
|
||||
</description>
|
||||
<icon path="images/appicon_64.png" />
|
||||
<screenshot path="images/dolibarr_screenshot1_640x480.png">
|
||||
<description>Screenshot 1</description>
|
||||
</screenshot>
|
||||
<changelog>
|
||||
<version version="3.1.0" release="0">
|
||||
<entry>See http://www.dolibarr.org/files/ChangeLog</entry>
|
||||
</version>
|
||||
</changelog>
|
||||
<categories>
|
||||
<category>Back office/Billing</category>
|
||||
<category>Back office/Accounting and Financial</category>
|
||||
<category>Back office/Customer Relationship Management</category>
|
||||
<category>Back office/Enterprise Resource Planning</category>
|
||||
</categories>
|
||||
<languages>
|
||||
<language>en</language>
|
||||
<language>fr</language>
|
||||
<language>es</language>
|
||||
<language>de</language>
|
||||
<language>pt</language>
|
||||
</languages>
|
||||
</presentation>
|
||||
<upgrade match="/application/version = '3.0'" />
|
||||
<!-- Application service (step 4) -->
|
||||
<service id="dolibarr">
|
||||
<!-- Service presentation properties (step 7) -->
|
||||
<license must-accept="false">
|
||||
<text>
|
||||
<name>GPL-3.0+</name>
|
||||
<file>COPYING</file>
|
||||
</text>
|
||||
</license>
|
||||
<presentation>
|
||||
<name>Dolibarr instance</name>
|
||||
<summary>Dolibarr services</summary>
|
||||
<entry-points>
|
||||
<entry class="frontpage" dst="/">
|
||||
<label>Application entry point</label>
|
||||
</entry>
|
||||
</entry-points>
|
||||
</presentation>
|
||||
<!-- Service settings (step 7) -->
|
||||
<settings>
|
||||
<!--
|
||||
<group>
|
||||
<name>Administrator's preferences</name>
|
||||
<setting id="admin_name" type="string" default-value="admin"
|
||||
min-length="1" max-length="32" regex="^[a-zA-Z][0-9a-zA-Z_\-]*">
|
||||
<name>Administrator's login</name>
|
||||
<error-message>
|
||||
Please make sure the text you entered starts with a letter and continues with either numbers, letters, underscores or hyphens.
|
||||
</error-message>
|
||||
</setting>
|
||||
<setting id="admin_password" type="password" min-length="1">
|
||||
<name>Password</name>
|
||||
</setting>
|
||||
</group>
|
||||
-->
|
||||
</settings>
|
||||
<!-- Service used technologies (step 6) -->
|
||||
<requirements xmlns:php="http://apstandard.com/ns/1/php"
|
||||
xmlns:db="http://apstandard.com/ns/1/db">
|
||||
<php:version min="4.2.0" />
|
||||
<php:extension>mysql</php:extension>
|
||||
<php:extension>mbstring</php:extension>
|
||||
<php:safe-mode>false</php:safe-mode>
|
||||
<db:db>
|
||||
<db:id>main</db:id>
|
||||
<db:default-name>dolibarr</db:default-name>
|
||||
<db:can-use-tables-prefix>false</db:can-use-tables-prefix>
|
||||
<db:server-type>mysql</db:server-type>
|
||||
<db:server-min-version>4.3.1</db:server-min-version>
|
||||
</db:db>
|
||||
</requirements>
|
||||
<!-- Content delivery settings (step 8) -->
|
||||
<provision>
|
||||
<url-mapping>
|
||||
<default-prefix>dolibarr</default-prefix>
|
||||
<installed-size>35000000</installed-size>
|
||||
<mapping url="/" path="htdocs" xmlns:php="http://apstandard.com/ns/1/php">
|
||||
<php:handler>
|
||||
<php:extension>php</php:extension>
|
||||
</php:handler>
|
||||
</mapping>
|
||||
</url-mapping>
|
||||
<!-- Service configuration script declaration (step 10) -->
|
||||
<configuration-script name="configure.php">
|
||||
<configuration-script-language>php</configuration-script-language>
|
||||
<status-control/>
|
||||
</configuration-script>
|
||||
</provision>
|
||||
</service>
|
||||
</application>
|
||||
@@ -1,121 +0,0 @@
|
||||
<!-- Application namespaces and APS version (step 9) -->
|
||||
<application xmlns="http://apstandard.com/ns/1" version="1.2">
|
||||
<!-- Application common properties (step 9) -->
|
||||
<id>dolibarr</id>
|
||||
<name>Dolibarr</name>
|
||||
<version>__VERSION__</version>
|
||||
<release>__RELEASE__</release>
|
||||
<homepage>http://www.dolibarr.org/</homepage>
|
||||
<vendor>
|
||||
<name>Dolibarr</name>
|
||||
<homepage>http://www.dolibarr.org/</homepage>
|
||||
<icon path="images/appicon_64.png" />
|
||||
</vendor>
|
||||
<packager>
|
||||
<name>Laurent Destailleur</name>
|
||||
<homepage>http://www.nltechno.com</homepage>
|
||||
<uri>uuid:e743ee30-9fe8-11e0-a32e-0025115d642c</uri>
|
||||
</packager>
|
||||
<presentation>
|
||||
<summary>Dolibarr ERP - CRM, the easy to use software to manage small or medium companies, freelancers or foundations</summary>
|
||||
<description>
|
||||
Dolibarr is a free modular software (you see only
|
||||
features you need) to manage small and medium companies, freelancers
|
||||
or foundations.
|
||||
This OpenSource software is designed to provide all features you need to
|
||||
manage information on many aspects of your business
|
||||
into an intuitive and user-friendly graphical interface
|
||||
It's an OpenSource software you can install on a web server or as a
|
||||
standalone software. Dolibarr is designed to provide simplicity to end-user.
|
||||
</description>
|
||||
<icon path="images/appicon_64.png" />
|
||||
<screenshot path="images/dolibarr_screenshot1_640x480.png">
|
||||
<description>Screenshot 1</description>
|
||||
</screenshot>
|
||||
<changelog>
|
||||
<version version="3.1.0" release="0">
|
||||
<entry>See http://www.dolibarr.org/files/ChangeLog</entry>
|
||||
</version>
|
||||
</changelog>
|
||||
<categories>
|
||||
<category>Back office/Billing</category>
|
||||
<category>Back office/Accounting and Financial</category>
|
||||
<category>Back office/Customer Relationship Management</category>
|
||||
<category>Back office/Enterprise Resource Planning</category>
|
||||
</categories>
|
||||
<languages>
|
||||
<language>en</language>
|
||||
<language>fr</language>
|
||||
<language>es</language>
|
||||
<language>de</language>
|
||||
<language>pt</language>
|
||||
</languages>
|
||||
</presentation>
|
||||
<upgrade match="/application/version = '3.0'" />
|
||||
<!-- Application service (step 4) -->
|
||||
<service id="dolibarr">
|
||||
<!-- Service presentation properties (step 7) -->
|
||||
<license must-accept="false">
|
||||
<text xml:lang="">
|
||||
<name>GPL-3.0+</name>
|
||||
<file>COPYING</file>
|
||||
</text>
|
||||
</license>
|
||||
<presentation>
|
||||
<name>Dolibarr instance</name>
|
||||
<entry-points>
|
||||
<entry class="frontpage" dst="/">
|
||||
<label>Application entry point</label>
|
||||
</entry>
|
||||
</entry-points>
|
||||
</presentation>
|
||||
<!-- Service settings (step 7) -->
|
||||
<settings>
|
||||
<group>
|
||||
<name>Administrator's preferences</name>
|
||||
<setting id="admin_name" type="string" default-value="admin"
|
||||
min-length="1" max-length="32" regex="^[a-zA-Z][0-9a-zA-Z_\-]*">
|
||||
<name>Administrator's login</name>
|
||||
<error-message>
|
||||
Please make sure the text you entered starts with a letter and continues with either numbers, letters, underscores or hyphens.
|
||||
</error-message>
|
||||
</setting>
|
||||
<setting id="admin_password" type="password" min-length="1">
|
||||
<name>Password</name>
|
||||
</setting>
|
||||
</group>
|
||||
</settings>
|
||||
<!-- Service used technologies (step 6) -->
|
||||
<requirements xmlns:php="http://apstandard.com/ns/1/php"
|
||||
xmlns:db="http://apstandard.com/ns/1/db">
|
||||
<php:version min="4.2.0" />
|
||||
<php:extension>mysql</php:extension>
|
||||
<php:extension>mbstring</php:extension>
|
||||
<php:safe-mode>false</php:safe-mode>
|
||||
<db:db>
|
||||
<db:id>main</db:id>
|
||||
<db:default-name>dolibarr</db:default-name>
|
||||
<db:can-use-tables-prefix>false</db:can-use-tables-prefix>
|
||||
<db:server-type>mysql</db:server-type>
|
||||
<db:server-min-version>4.3.1</db:server-min-version>
|
||||
</db:db>
|
||||
</requirements>
|
||||
<!-- Content delivery settings (step 8) -->
|
||||
<provision>
|
||||
<url-mapping>
|
||||
<default-prefix>dolibarr</default-prefix>
|
||||
<installed-size>35000000</installed-size>
|
||||
<mapping url="/" path="htdocs" xmlns:php="http://apstandard.com/ns/1/php">
|
||||
<php:handler>
|
||||
<php:extension>php</php:extension>
|
||||
</php:handler>
|
||||
</mapping>
|
||||
</url-mapping>
|
||||
<!-- Service configuration script declaration (step 10) -->
|
||||
<configuration-script name="configure.php">
|
||||
<script-language>php</script-language>
|
||||
<status-control/>
|
||||
</configuration-script>
|
||||
</provision>
|
||||
</service>
|
||||
</application>
|
||||
@@ -1,89 +0,0 @@
|
||||
<html><head>
|
||||
<title> Limitations of APS Support in the Panel </title>
|
||||
<meta name="Keywords" content="">
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||
<link rel="stylesheet" type="text/css" href="Limitations%20of%20APS%20Support%20in%20the%20Panel_fichiers/stylesheet.css">
|
||||
<link href="Limitations%20of%20APS%20Support%20in%20the%20Panel_fichiers/prettify.css" type="text/css" rel="stylesheet">
|
||||
<script type="text/javascript" src="Limitations%20of%20APS%20Support%20in%20the%20Panel_fichiers/prettify.js"></script>
|
||||
<script src="Limitations%20of%20APS%20Support%20in%20the%20Panel_fichiers/highlight.js"></script></head>
|
||||
|
||||
<body onload="prettyPrint()" link="#0000A0" text="#000000" vlink="#FF0000" alink="#008000" bgcolor="#FFFFFF">
|
||||
<h1 class="heading1">Limitations of APS Support in the Panel</h1>
|
||||
<h2 class="heading2">About This Document</h2>
|
||||
<p class="bodytext">This document is addressed to independent software
|
||||
vendors who plan to distribute web applications among the Panel users.
|
||||
The aim of the document is to help vendors find out whether they can
|
||||
package their applications to APS to make them available through the
|
||||
Panel.</p>
|
||||
<p class="bodytext">The document does not contain information about
|
||||
Application Packaging Standard itself or give application packaging
|
||||
instructions. It focuses on how the Panel implements APS and what APS
|
||||
packages are not supported by this implementation.</p>
|
||||
<p class="bodytext"></p>
|
||||
<h2 class="heading2">APS Support in the Panel</h2>
|
||||
<p class="bodytext"><em class="emphasis"><em class="emphasis">Application Packaging Standard</em></em> (<em class="emphasis">APS</em>)
|
||||
is a set of rules that defines a web application packaging format. This
|
||||
standard is designed to ease the integration of applications in a
|
||||
service provider's infrastructure. It covers provisioning, management,
|
||||
and integration of cloud-based services and applications.</p>
|
||||
<p class="bodytext">The Panel uses APS to offer third-party applications to hosting customers. These applications are presented in <em class="emphasis">APS catalog</em>, where the customers can buy or download them.</p>
|
||||
<p class="bodytext">Currently, the Panel does not support all aspects of
|
||||
APS. Therefore, customers may have problems trying to install certain
|
||||
applications. To find out whether your application is compatible with
|
||||
the Panel, see section <strong class="specialbold"><strong class="specialbold">Plesk Panel Restrictions.</strong></strong></p>
|
||||
<p class="bodytext">You can find more information about APS at http://www.apsstandard.org/.</p>
|
||||
<p class="bodytext">APS specification and supporting documents are available at http://www.apsstandard.org/isv/documentation/.</p>
|
||||
<p class="bodytext"></p>
|
||||
<h2 class="heading2">Restrictions on Packages Processing</h2>
|
||||
<p class="bodytext">The current Panel version has restrictions on APS
|
||||
applications processing. If an application requires performing
|
||||
restricted actions, the Panel will not install it. Particularly, these
|
||||
actions are the following:</p>
|
||||
<ul class="listbullet"><li class="listbullet">Sending e-mails or processing incoming mail.<p class="listcontinue">See <strong class="specialbold">Mail aspect</strong> of APS in <strong class="specialbold">APS Format Specification v1.2</strong>, section <strong class="specialbold">8.8. Mail </strong>at http://www.apsstandard.org/r/doc/package-format-specification-1.2/index.html#s.aspects.mail</p>
|
||||
</li><li class="listbullet">Changing the DNS resource records of an environment where the application works.<p class="listcontinue">See <strong class="specialbold">DNS aspect</strong> in <strong class="specialbold">APS Format Specification v1.2</strong>, section <strong class="specialbold">8.10. DNS Zone </strong>at http://www.apsstandard.org/r/doc/package-format-specification-1.2/index.html#s.aspects.dns</p>
|
||||
</li><li class="listbullet">Installing third-party dynamic libraries (*.dll, *.so).<p class="listcontinue">See<strong class="specialbold"> DLL aspect</strong> in <strong class="specialbold">APS Format Specification v1.2</strong>, section <strong class="specialbold">8.11. DLL Content Processing Method </strong>at http://www.apsstandard.org/r/doc/package-format-specification-1.2/index.html#s.aspects.dll</p>
|
||||
</li><li class="listbullet">Updating older version of application with
|
||||
complex changes in application settings or deployment logic. According
|
||||
to APS, such updates are called <em class="emphasis">upgrades. </em>For more information on the application updates, see the <strong class="specialbold">APS Format Specification v1.2</strong>, section <strong class="specialbold">5.1.15 Updates </strong>at http://www.apsstandard.org/r/doc/package-format-specification-1.2/index.html#s.metadata.common.update</li></ul><p class="bodytext">If
|
||||
you need you application to perform these actions, consider other ways
|
||||
of integration with the Panel: API RPC, modules or Panel Notifications.</p>
|
||||
<p class="bodytext">Also, the Panel does not support the following actions defined in the application package: </p>
|
||||
<ul class="listbullet"><li class="listbullet">Checking application settings for consistency via <strong class="specialbold">verification script. </strong>For more information on verification scripts, see the <strong class="specialbold">APS Format Specification v1.2</strong>, section <strong class="specialbold">5.3.3 Verification Script </strong>at http://www.apsstandard.org/r/doc/package-format-specification-1.2/index.html#s.metadata.provision.verification-script</li><li class="listbullet">Processing application resource usage reports defined by <strong class="specialbold">resource counters</strong> and passed by <strong class="specialbold">resource script</strong> . For more information on resource counters and resource scripts, see the <strong class="specialbold">APS Format Specification v1.2</strong>, section <strong class="specialbold">5.2.6. Resources</strong> at http://www.apsstandard.org/r/doc/package-format-specification-1.2/index.html#s.metadata.service.resources and <strong class="specialbold">5.3.3 Resources Script </strong>at http://www.apsstandard.org/r/doc/package-format-specification-1.2/index.html#s.metadata.provision.resource-script</li>
|
||||
|
||||
<h1 class="heading1">Copyright Notice</h1>
|
||||
<p class="copyright">Parallels Holdings, Ltd.</p>
|
||||
<p class="copyright">c/o Parallels International GmbH</p>
|
||||
<p class="copyright">Vordergasse 59</p>
|
||||
<p class="copyright">CH-Schaffhausen</p>
|
||||
<p class="copyright">Switzerland</p>
|
||||
<p class="copyright">Phone: +41-526320-411</p>
|
||||
<p class="copyright">Fax: +41-52672-2010</p>
|
||||
<p class="copyright"> </p>
|
||||
<p class="copyright">Copyright © 1999-2011 Parallels Holdings, Ltd. and its affiliates. All rights reserved. </p>
|
||||
<p class="copyright"> </p>
|
||||
<p class="copyright">This product is protected by United States and
|
||||
international copyright laws. The product's underlying technology,
|
||||
patents, and trademarks are listed at
|
||||
http://www.parallels.com/trademarks. </p>
|
||||
<p class="copyright"> </p>
|
||||
<p class="copyright">Microsoft, Windows, Windows Server, Windows NT, Windows Vista, and MS-DOS are registered trademarks of Microsoft Corporation.</p>
|
||||
<p class="copyright">Linux is a registered trademark of Linus Torvalds.</p>
|
||||
<p class="copyright">Mac is a registered trademark of Apple, Inc.</p>
|
||||
<p class="copyright">All other marks and names mentioned herein may be trademarks of their respective owners.</p>
|
||||
|
||||
|
||||
|
||||
<p class="bodytext">
|
||||
<a target="_blank" title="Send feedback through a web form" href="http://www.parallels.com/en/support/usersdoc/?problemSubject=Feedback+on+Help+Page+" onclick="var u = parent.BODY.location.href;
|
||||
u = u.replace(/.+\/([^/]+).htm$/,'$1');
|
||||
u+= '+of+the+'+parent.document.title.replace(/ /g,'+');
|
||||
|
||||
this.href+=u;
|
||||
|
||||
window.location.reload(false);">Please send us your feedback on this help page.</a></p>
|
||||
|
||||
|
||||
|
||||
|
||||
</ul></body></html>
|
||||
<!-- Edited by post-publisher -->
|
||||
@@ -1,64 +0,0 @@
|
||||
function last(href)
|
||||
{
|
||||
var ret = href.split("/");
|
||||
return ret[ret.length-1];
|
||||
}
|
||||
|
||||
function StopProcess()
|
||||
{
|
||||
LeftFrame = parent.TOC.document.location.href;
|
||||
LeftFrame = last(LeftFrame);
|
||||
if (LeftFrame == "dhtml_search.htm") return 1
|
||||
else return 0;
|
||||
}
|
||||
|
||||
|
||||
|
||||
function highlightTOC(str) {
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
if (StopProcess()) return;
|
||||
try {
|
||||
|
||||
str = str || parent.BODY.document.location.href;
|
||||
uri = last(str);
|
||||
list = parent.TOC.document.getElementsByTagName("a");
|
||||
for(i=0; i<list.length; i++)
|
||||
{
|
||||
if (last(list[i].href) == uri)
|
||||
{
|
||||
list[i].style.backgroundColor = "#6697cc";
|
||||
list[i].style.padding = "2px";
|
||||
list[i].style.color = "#ffffff";
|
||||
|
||||
} else {
|
||||
list[i].style.backgroundColor = "#ffffff";
|
||||
list[i].style.color = "#003380";
|
||||
}
|
||||
}
|
||||
} catch (e) {}
|
||||
}
|
||||
|
||||
function FindCorrectTOCPage()
|
||||
{
|
||||
if (StopProcess()) return;
|
||||
//Updated on 30.04.2008
|
||||
list = parent.BODY.document.getElementsByTagName("a") || document.getElementsByTagName("a");
|
||||
for(i=0; i<list.length; i++)
|
||||
{
|
||||
if (list[i].target == "TOC")
|
||||
{
|
||||
|
||||
if (last(list[i].href) != last(parent.TOC.document.location.href))
|
||||
{
|
||||
parent.TOC.document.location.href = list[i].href;
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
@@ -1,60 +0,0 @@
|
||||
/* Pretty printing styles. Used with prettify.js. */
|
||||
|
||||
.str { color: #FF0000; }
|
||||
.vr { color: #0000FF; }
|
||||
.kwd { color: #000080; font-weight: bold}
|
||||
.com { color: #EA8110; }
|
||||
.typ { color: #606; }
|
||||
.lit { color: #066; }
|
||||
.pun { color: #660; }
|
||||
.pln { color: #000; }
|
||||
.tag { color: #008; }
|
||||
.atn { color: #606; }
|
||||
.atv { color: #080; }
|
||||
.dec { color: #606; }
|
||||
pre.preformatted {
|
||||
|
||||
display: block;
|
||||
font-family: "Courier New", verdana, arial, helvetica, sans-serif;
|
||||
font-style: normal;
|
||||
font-variant: normal;
|
||||
font-weight: normal;
|
||||
font-size: 10pt;
|
||||
color: #000000;
|
||||
background-color: #f4f4f4;
|
||||
word-spacing: normal;
|
||||
letter-spacing: normal;
|
||||
vertical-align: baseline;
|
||||
text-decoration: none;
|
||||
text-transform: none;
|
||||
line-height: normal;
|
||||
margin-top: 0pt;
|
||||
margin-bottom: 0pt;
|
||||
margin-left: 0pt;
|
||||
margin-right: 6pt;
|
||||
padding-top: 1pt;
|
||||
padding-bottom: 1pt;
|
||||
padding-left: 5pt;
|
||||
padding-right: 5pt;
|
||||
float: none;
|
||||
clear: none;
|
||||
text-align: left;
|
||||
text-indent: 0cm;
|
||||
width: auto;
|
||||
height: auto;
|
||||
|
||||
}
|
||||
|
||||
@media print {
|
||||
.vr { color: #f0f; }
|
||||
.str { color: #060; }
|
||||
.kwd { color: #006; font-weight: bold; }
|
||||
.com { color: #600; font-style: italic; }
|
||||
.typ { color: #404; font-weight: bold; }
|
||||
.lit { color: #044; }
|
||||
.pun { color: #440; }
|
||||
.pln { color: #000; }
|
||||
.tag { color: #006; font-weight: bold; }
|
||||
.atn { color: #404; }
|
||||
.atv { color: #060; }
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@@ -1,20 +0,0 @@
|
||||
README (English)
|
||||
##################################################
|
||||
This directory is dedicated to APS package building
|
||||
##################################################
|
||||
|
||||
Docs for APS format 1.1:
|
||||
http://www.apsstandard.org/r/doc/aps-format-1.1-packaging-guide/index.htm
|
||||
|
||||
Docs for APS format 1.2 (need APP-LIST.xml):
|
||||
http://www.apsstandard.org/r/doc/aps-format-1.2-packaging-guide/index.htm
|
||||
|
||||
|
||||
To check an APS package on Debian:
|
||||
* Install libgdiplus with
|
||||
apt-get install libgdiplus
|
||||
* Install apslint.exe (http://www.apsstandard.org/r/doc/aps-format-1.2-packaging-guide/57414.htm)
|
||||
tar -xvf xxxx.tgz
|
||||
* Go into directory of apslint and run command
|
||||
mono ./apslint.exe '/media/DATA/Mes Developpements/dolibarr/build/dolibarr-3.1.0-dev.app.zip'
|
||||
|
||||
@@ -1,151 +0,0 @@
|
||||
#!/usr/bin/env php
|
||||
<?php
|
||||
/*-----------------------------------------------------
|
||||
*
|
||||
*----------------------------------------------------- */
|
||||
|
||||
// This is list of predefined variables when script is ran
|
||||
// We have to set them manually to run script outside context.
|
||||
/*putenv('SETTINGS_admin_name=admin');
|
||||
putenv('SETTINGS_admin_password=admin-ad');
|
||||
putenv('BASE_URL_SCHEME=http');
|
||||
putenv('BASE_URL_HOST=localhost');
|
||||
putenv('BASE_URL_PORT=0');
|
||||
putenv('BASE_URL_PATH=/');
|
||||
//putenv('WEB___DIR=/var/wwww/dolibarr/htdocs'); // WEB___DIR is dir to htdocs
|
||||
putenv('WEB___DIR=../htdocs'); // WEB___DIR is dir to htdocs
|
||||
putenv('DB_main_NAME=dolibarr');
|
||||
putenv('DB_main_HOST=localhost');
|
||||
putenv('DB_main_PORT=3306');
|
||||
putenv('DB_main_LOGIN=root');
|
||||
putenv('DB_main_PASSWORD=root');
|
||||
*/
|
||||
|
||||
// Check parameters
|
||||
if(count($_SERVER['argv']) < 2)
|
||||
{
|
||||
print "Usage: configure.php (install | upgrade <version> | configure | remove)\n";
|
||||
exit(1);
|
||||
}
|
||||
$command = $_SERVER['argv'][1]; //$command stores the argument with which the script was invoked.
|
||||
|
||||
|
||||
if($command == "install")
|
||||
{
|
||||
$db_id = 'main';
|
||||
|
||||
$rootdir = getenv("WEB___DIR");
|
||||
if ($rootdir != '/') $rootdir = preg_replace('/\/$/','',$rootdir); // Remove last /
|
||||
$datadir = $rootdir.'/dolibarr_documents';
|
||||
|
||||
//List of database-related variables that are passed to the configuration
|
||||
//script. See the 6.3.1.1.1. Environment variables section of the
|
||||
//Specification for details.
|
||||
$db_address = getenv("DB_${db_id}_HOST");
|
||||
$db_port = getenv("DB_${db_id}_PORT");
|
||||
$dblogin = getenv("DB_${db_id}_LOGIN");
|
||||
$dbpassword = getenv("DB_${db_id}_PASSWORD");
|
||||
$dbname = getenv("DB_${db_id}_NAME");
|
||||
|
||||
|
||||
//PHP functions for connecting to the mysql server and
|
||||
//executing SQL queries.
|
||||
//mysql_connect($dbaddress, $dblogin, $dbpassword);
|
||||
//mysql_select_db($dbname);
|
||||
/*
|
||||
$sql_queries = file($query_file);
|
||||
foreach ($sql_queries as $query) mysql_query($query);
|
||||
*/
|
||||
|
||||
|
||||
//Other code to be executed on invoking configure with
|
||||
//the install argument.
|
||||
|
||||
// Create empty config file
|
||||
$file=$rootdir.'/conf/conf.php';
|
||||
print "Create conf file ".$file."\n";
|
||||
$fp = fopen($file, 'wb');
|
||||
if ($fp)
|
||||
{
|
||||
fclose($fp);
|
||||
chmod($file,0775);
|
||||
}
|
||||
else
|
||||
{
|
||||
print "configure.php install: Unable to write file $file.\n";
|
||||
exit(1);
|
||||
}
|
||||
|
||||
// Create empty directory that will be used by software to store uploaded documents
|
||||
print "Create directory ".$datadir."\n";
|
||||
@mkdir($datadir);
|
||||
chmod($datadir,0775);
|
||||
|
||||
// Create install.forced.php into htdocs/install directory with value.
|
||||
// This will set parameters of install for web installer wizard.
|
||||
$file_source=$rootdir.'/../build/aps/install.forced.php.install';
|
||||
$file=$rootdir.'/install/install.forced.php';
|
||||
print "Create file ".$file.' from '.$file_source."\n";
|
||||
|
||||
$modify_hash=array(
|
||||
'WEB___DIR'=>$rootdir,
|
||||
'DB_'.$db_id.'_HOST'=>$db_address,
|
||||
'DB_'.$db_id.'_PORT'=>$db_port,
|
||||
'DB_'.$db_id.'_LOGIN'=>$dblogin,
|
||||
'DB_'.$db_id.'_PASSWORD'=>$dbpassword,
|
||||
'DB_'.$db_id.'_NAME'=>$dbname
|
||||
);
|
||||
|
||||
$file_content = fread(fopen($file_source, 'r'), filesize($file_source));
|
||||
foreach($modify_hash as $param => $val){
|
||||
$file_content = str_replace($param, php_quote($val), $file_content);
|
||||
}
|
||||
$fp = fopen($file, 'wb');
|
||||
if ($fp)
|
||||
{
|
||||
fputs($fp, $file_content);
|
||||
fputs($fp, "\n");
|
||||
fclose($fp);
|
||||
chmod($file,0775);
|
||||
}
|
||||
else
|
||||
{
|
||||
print "configure.php install: Unable to write file $file.\n";
|
||||
exit(2);
|
||||
}
|
||||
|
||||
exit(0);
|
||||
}
|
||||
|
||||
if($command == "remove")
|
||||
{
|
||||
//Code to be executed on invoking configure with the remove argument
|
||||
exit(0);
|
||||
}
|
||||
|
||||
if($command == "upgrade")
|
||||
{
|
||||
//Code to be executed on invoking configure with the upgrade argument
|
||||
exit(0);
|
||||
}
|
||||
|
||||
if($command == "configure")
|
||||
{
|
||||
//Code to be executed on invoking configure with the configure argument
|
||||
exit(0);
|
||||
}
|
||||
|
||||
print "configure.php: Error: unknown command $command.\n";
|
||||
exit(1);
|
||||
|
||||
|
||||
|
||||
// Content of file-util.php we need
|
||||
|
||||
function php_quote($val)
|
||||
{
|
||||
$res_val = str_replace("\\", "\\\\", $val);
|
||||
$res_val = str_replace("'", "\\'", $res_val);
|
||||
return $res_val;
|
||||
}
|
||||
|
||||
@@ -1,23 +0,0 @@
|
||||
<?php
|
||||
// File to force Dolibarr wizard installer choices.
|
||||
//
|
||||
// This file must be present into htdocs/install directory
|
||||
// during install process to be used.
|
||||
//
|
||||
//
|
||||
$force_install_noedit=1;
|
||||
$force_install_message='KeepDefaultValuesDeb';
|
||||
$force_install_main_data_root='WEB___DIR/dolibarr_documents';
|
||||
$force_install_type='mysqli';
|
||||
$force_install_dbserver='DB_main_HOST';
|
||||
$force_install_port='DB_main_PORT';
|
||||
$force_install_database='DB_main_NAME';
|
||||
$force_install_createdatabase='0';
|
||||
$force_install_databaselogin='DB_main_LOGIN';
|
||||
$force_install_databasepass='DB_main_PASSWORD';
|
||||
$force_install_createuser='0';
|
||||
$force_install_databaserootlogin='';
|
||||
$force_install_databaserootpass='';
|
||||
$force_install_dolibarrlogin='admin';
|
||||
$force_install_nophpinfo='1';
|
||||
$force_install_lockinstall='444';
|
||||
@@ -8,7 +8,7 @@ Copyright: 2002-2009, Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
||||
2003-2006, Jean-Louis Bergamo <jlb@j1b.org>
|
||||
2003-2013, Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
2003, Xavier Dutoit <doli@sydesy.com>
|
||||
2004-2013, Regis Houssin <regis.houssin@capnetworks.com>
|
||||
2004-2013, Regis Houssin <regis.houssin@inodbox.com>
|
||||
2004, Sebastien Di Cintio <sdicintio@ressource-toi.org>
|
||||
2004, Benoit Mortier <benoit.mortier@opensides.be>
|
||||
2004, Christophe Combelles <ccomb@free.fr>
|
||||
|
||||
1
build/debian/source/include-binaries
Normal file
1
build/debian/source/include-binaries
Normal file
@@ -0,0 +1 @@
|
||||
htdocs/install/doctemplates/websites/website_template-corporate.zip
|
||||
@@ -3,18 +3,30 @@ FROM php:7.0-apache
|
||||
ENV HOST_USER_ID 33
|
||||
ENV PHP_INI_DATE_TIMEZONE 'UTC'
|
||||
|
||||
RUN apt-get update && apt-get install -y libpng12-dev libjpeg-dev libldap2-dev \
|
||||
RUN apt-get update && apt-get install -y libpng-dev libjpeg-dev libldap2-dev \
|
||||
&& rm -rf /var/lib/apt/lists/* \
|
||||
&& docker-php-ext-configure gd --with-png-dir=/usr --with-jpeg-dir=/usr \
|
||||
&& docker-php-ext-install gd \
|
||||
&& docker-php-ext-configure ldap --with-libdir=lib/x86_64-linux-gnu/ \
|
||||
&& docker-php-ext-install ldap \
|
||||
&& docker-php-ext-install mysqli \
|
||||
&& apt-get purge -y libpng12-dev libjpeg-dev libldap2-dev
|
||||
&& apt-get purge -y libjpeg-dev libldap2-dev
|
||||
|
||||
COPY docker-run.sh /usr/local/bin/
|
||||
RUN chmod +x /usr/local/bin/docker-run.sh
|
||||
|
||||
RUN pecl install xdebug-2.5.5 && docker-php-ext-enable xdebug
|
||||
RUN echo 'zend_extension="/usr/local/lib/php/extensions/no-debug-non-zts-20151012/xdebug.so"' >> /usr/local/etc/php/php.ini
|
||||
RUN echo 'xdebug.remote_autostart=0' >> /usr/local/etc/php/php.ini
|
||||
RUN echo 'xdebug.remote_enable=1' >> /usr/local/etc/php/php.ini
|
||||
RUN echo 'xdebug.default_enable=0' >> /usr/local/etc/php/php.ini
|
||||
RUN echo 'xdebug.remote_host=docker.for.mac.host.internal' >> /usr/local/etc/php/php.ini
|
||||
RUN echo 'xdebug.remote_port=9000' >> /usr/local/etc/php/php.ini
|
||||
RUN echo 'xdebug.remote_connect_back=0' >> /usr/local/etc/php/php.ini
|
||||
RUN echo 'xdebug.profiler_enable=0' >> /usr/local/etc/php/php.ini
|
||||
RUN echo 'xdebug.remote_log="/tmp/xdebug.log"' >> /usr/local/etc/php/php.ini
|
||||
|
||||
|
||||
EXPOSE 80
|
||||
|
||||
ENTRYPOINT ["docker-run.sh"]
|
||||
|
||||
@@ -3,42 +3,27 @@ File added into doxygen generated documentation
|
||||
-->
|
||||
|
||||
|
||||
<!-- Google analytics -->
|
||||
<script>
|
||||
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
|
||||
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
|
||||
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
|
||||
})(window,document,'script','https://www.google-analytics.com/analytics.js','ga');
|
||||
|
||||
ga('create', 'UA-9049390-16', 'auto');
|
||||
ga('send', 'pageview');
|
||||
|
||||
</script>
|
||||
<!-- End google analytics -->
|
||||
|
||||
|
||||
<hr class="footer" />
|
||||
<address class="footer"><small>Generated on $datetime
|
||||
for <a href="https://www.dolibarr.org">$projectname</a> by Doxygen $doxygenversion </small></address>
|
||||
<address class="footer"><small>Generated on $datetime for <a href="https://www.dolibarr.org">$projectname</a> by Doxygen $doxygenversion </small></address>
|
||||
|
||||
|
||||
<!-- Google AdSense -->
|
||||
<div class="center">
|
||||
<script type="text/javascript"><!--
|
||||
google_ad_client = "pub-1071905880519467";
|
||||
/* PUBBANDEAUDOLIBARR */
|
||||
google_ad_slot = "1421205532";
|
||||
google_ad_width = 468;
|
||||
google_ad_height = 60;
|
||||
//-->
|
||||
</script>
|
||||
<script type="text/javascript" src="https://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
|
||||
</div>
|
||||
<!-- End google adsense -->
|
||||
<br>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Global site tag (gtag.js) - Google Analytics -->
|
||||
<script async src="https://www.googletagmanager.com/gtag/js?id=UA-9049390-16"></script>
|
||||
<script>
|
||||
window.dataLayer = window.dataLayer || [];
|
||||
function gtag(){dataLayer.push(arguments);}
|
||||
gtag('js', new Date());
|
||||
|
||||
gtag('config', 'UA-9049390-16');
|
||||
</script>
|
||||
|
||||
|
||||
<!-- Twitter ad collector -->
|
||||
<script src="//platform.twitter.com/oct.js" type="text/javascript"></script>
|
||||
<script type="text/javascript">twttr.conversion.trackPid('ntm4n', { tw_sale_amount: 0, tw_order_quantity: 0 });</script>
|
||||
|
||||
@@ -42,7 +42,7 @@ src="https://www.facebook.com/tr?id=1998533953704960&ev=PageView&noscript=1"
|
||||
<table width="100%">
|
||||
<tr>
|
||||
<td><div id="projectname">$projectname</div> - <span id="projectnumber">$projectnumber</span></td>
|
||||
<td align="right"><!-- banner start -->
|
||||
<td class="right"><!-- banner start -->
|
||||
<table cellpadding="0" cellspacing="0" class="moduletablemybanner">
|
||||
<tr>
|
||||
<td>
|
||||
|
||||
@@ -11,10 +11,10 @@ LaunchProgram=Launch %1
|
||||
AssocFileExtension=&Associate %1 with the %2 file extension
|
||||
AssocingFileExtension=Associating %1 with the %2 file extension...
|
||||
|
||||
YouWillInstallDoliWamp=You will install or upgrade DoliWamp (Apache+Mysql+PHP+Dolibarr) on your computer.
|
||||
ThisAssistantInstallOrUpgrade=This assistant installs or upgrades Dolibarr ERP-CRM and all required third party softwares (Apache, Mysql and PHP) optimized for a Dolibarr usage.
|
||||
IfYouHaveTechnicalKnowledge=If you have technical knowledge and plan to share your Apache, Mysql and PHP with other projects than Dolibarr, you should not use this assistant and make a manual installation of Dolibarr on your existing Apache, Mysql and PHP installation.
|
||||
ButIfYouLook=But if you look for an automatic setup, you''re on the good way...
|
||||
YouWillInstallDoliWamp=You will install or upgrade DoliWamp (so Dolibarr + all required third party softwares like Apache, Mysql and PHP) on your computer.
|
||||
ThisAssistantInstallOrUpgrade=WARNING: Using an ERP CRM installed on a local computer can be dangerous: if your computer break down, you can lose all your data. Do this if you are ready to manage backup yourself seriously. If not, use an installation in Saas instead (see https://saas.dolibarr.org).
|
||||
IfYouHaveTechnicalKnowledge=Moreover, if you have technical knowledges and want to manage your Apache, Mysql and PHP yourself, you should not use this assistant and make a manual installation of Dolibarr on your existing server with Apache, Mysql and PHP.
|
||||
ButIfYouLook=But if you look for an automatic setup on your local computer, you''re on the good way...
|
||||
DoYouWantToStart=Do you want to start installation/upgrade process ?
|
||||
|
||||
TechnicalParameters=Technical parameters
|
||||
@@ -32,7 +32,7 @@ PortAlreadyInUse=Port %1 seems to be already in use. You should cancel to go bac
|
||||
|
||||
FirefoxDetected=Firefox has been detected on your computer. Would you like to use it as the default browser for Dolibarr ?
|
||||
ChromeDetected=Chrome has been detected on your computer. Would you like to use it as the default browser for Dolibarr ?
|
||||
ChooseDefaultBrowser=Please choose your default browser. If you are not sure, just click Open :
|
||||
ChooseDefaultBrowser=Please choose your default browser (iexplore.exe, firefox.exe, chrome.exe, MicrosoftEdge.exe...). If you are not sure, just click Open :
|
||||
|
||||
LaunchNow=Launch Dolibarr now
|
||||
|
||||
@@ -43,5 +43,5 @@ DoliWampWillStartApacheMysql=DoliWamp installer will now start or restart Apache
|
||||
OldVersionFoundAndMoveInNew=An old database version has been found and moved to be used by new Dolibarr version
|
||||
OldVersionFoundButFailedToMoveInNew=An old database version has been found but could not be moved to be used with new Dolibarr version
|
||||
|
||||
DLLMissing=The "Visual C++ Redistributable for Visual Studio 2012" component is missing. Please install the 32-bit version (vcredit_x86.exe) first from https://www.microsoft.com/en-us/download/details.aspx?id=30679 and restart DoliWamp installation/upgrade.
|
||||
DLLMissing=Your Windows installation is missing The "Micrsoft Visual C++ Redistributable for Visual Studio 2012" component. Please install the 32-bit version (vcredist_x86.exe) first (you can find it at https://www.microsoft.com/en-us/download/) and restart DoliWamp installation/upgrade after.
|
||||
ContinueAnyway=Continue anyway (install process may fails without this prerequisite)
|
||||
|
||||
@@ -11,10 +11,10 @@ LaunchProgram=Ex
|
||||
AssocFileExtension=&Associer %1 avec l'extension de fichier %2
|
||||
AssocingFileExtension=Associe %1 avec l'extension de fichier %2...
|
||||
|
||||
YouWillInstallDoliWamp=Vous allez installer ou mettre <20> jour DoliWamp (Apache+Mysql+PHP+Dolibarr) sur votre ordinateur.
|
||||
ThisAssistantInstallOrUpgrade=Cet assistant installe ou met <20> jour Dolibarr ERP-CRM et tous ses composants pr<70>requis (Apache, Mysql et PHP) optimis<EFBFBD>s pour une utilisation de Dolibarr.
|
||||
IfYouHaveTechnicalKnowledge=Si vous avez des comp<6D>tences techniques et envisagez de partager votre Apache, Mysql et PHP avec d'autres applications que Dolibarr, vous ne devriez pas utiliser cet assistant mais faire plut<75>t une installation manuelle de Dolibarr sur un socle Apache, Mysql et PHP existant.
|
||||
ButIfYouLook=Mais si vous recherchez une installation cl<63> en main automatis<69>e, vous <20>tes sur la bonne voie...
|
||||
YouWillInstallDoliWamp=Vous allez installer ou mettre <20> jour DoliWamp sur votre ordinateur (donc Dolibarr + tous ses composants pr<70>requis comme Apache, Mysql et PHP).
|
||||
ThisAssistantInstallOrUpgrade=AVERTISSEMENT: L'utilisation d'un ERP CRM install<6C> sur un ordinateur local peut <20>tre dangereuse: si votre ordinateur tombe en panne, vous pouvez perdre toutes vos donn<6E>es. Faites-le si vous <20>tes pr<70>t <20> g<>rer les sauvegardes vous-m<>me s<>rieusement. Sinon, utilisez plut<75>t une installation en Saas (voir https://saas.dolibarr.org).
|
||||
IfYouHaveTechnicalKnowledge=De plus, si vous avez des comp<6D>tences techniques et envisagez de partager votre Apache, Mysql et PHP avec d''autres applications que Dolibarr, vous ne devriez pas utiliser cet assistant mais faire plut<75>t une installation manuelle de Dolibarr sur un serveur existant <20>quip<69> de Apache, Mysql et PHP.
|
||||
ButIfYouLook=Mais si vous recherchez une installation cl<63> en main automatis<69>e sur une poste local, vous <20>tes sur la bonne voie...
|
||||
DoYouWantToStart=Voulez-vous d<>marrer le processus d'installation/mise <20> jour ?
|
||||
|
||||
TechnicalParameters=Param<61>tres techniques
|
||||
@@ -33,7 +33,7 @@ PortAlreadyInUse=Le port %1 semble d
|
||||
|
||||
FirefoxDetected=Firefox a <20>t<EFBFBD> d<>tect<63> sur votre ordinateur. Voulez-vous en faire votre navigateur par d<>faut pour Dolibarr ?
|
||||
ChromeDetected=Chrome a <20>t<EFBFBD> d<>tect<63> sur votre ordinateur. Voulez-vous en faire votre navigateur par d<>faut pour Dolibarr ?
|
||||
ChooseDefaultBrowser=Merci de choisir votre navigateur par d<>faut. Si vous n'<27>tes pas s<>r, cliquez simplement sur Ouvrir :
|
||||
ChooseDefaultBrowser=Merci de choisir votre navigateur par d<>faut (iexplore.exe, firefox.exe, chrome.exe, MicrosoftEdge.exe...). Si vous n'<27>tes pas s<>r, cliquez simplement sur Ouvrir :
|
||||
|
||||
LaunchNow=Lancer Dolibarr maintenant
|
||||
|
||||
@@ -44,3 +44,5 @@ DoliWampWillStartApacheMysql=L'installeur DoliWamp va maintenant d
|
||||
OldVersionFoundAndMoveInNew=Une ancienne version de base a <20>t<EFBFBD> trouv<75>e et d<>plac<61>e pour fonctionner avec la nouvelle version de Dolibarr.
|
||||
OldVersionFoundButFailedToMoveInNew=Une ancienne version de base a <20>t<EFBFBD> trouv<75>e mais ne peut <20>tre d<>plac<61>e pour <20>tre utilis<69>e avec la nouvelle version de Dolibarr.
|
||||
|
||||
DLLMissing=L'installation de votre Windows est incompl<70>te. Il manque le composant "Micrsoft Visual C++ Redistributable for Visual Studio 2012". Installer la version 32-bit (vcredist_x86.exe) d'abord (vous pourrez le trouver <20> https://www.microsoft.com/fr-fr/download/) puis relancer l'installation de DoliWamp apr<70>s.
|
||||
ContinueAnyway=Continuer malgr<67> tout (le process d'installaton <20>chouera)
|
||||
|
||||
@@ -5,4 +5,4 @@ DOLIWAMP Package tools
|
||||
|
||||
This directory contains files used by makepack-dolibarr.pl
|
||||
script to build the all-in-on .EXE package DoliWamp, ready
|
||||
to be distributedt (for Windows).
|
||||
to be distributed (for Windows).
|
||||
@@ -28,11 +28,11 @@ OutputBaseFilename=__FILENAMEEXEDOLIWAMP__
|
||||
SourceDir=..\..\..
|
||||
AppId=doliwamp
|
||||
AppPublisher=NLTechno
|
||||
AppPublisherURL=http://www.nltechno.com
|
||||
AppSupportURL=http://www.dolibarr.org
|
||||
AppUpdatesURL=http://www.dolibarr.org
|
||||
AppPublisherURL=https://www.nltechno.com
|
||||
AppSupportURL=https://www.dolibarr.org
|
||||
AppUpdatesURL=https://www.dolibarr.org
|
||||
AppComments=DoliWamp includes Dolibarr, Apache, PHP and Mysql softwares.
|
||||
AppCopyright=Copyright (C) 2008-2017 Laurent Destailleur (NLTechno), Fabian Rodriguez (Le Goût du Libre)
|
||||
AppCopyright=Copyright (C) 2008-2019 Laurent Destailleur (NLTechno), Fabian Rodriguez (Le Goût du Libre)
|
||||
DefaultDirName=c:\dolibarr
|
||||
DefaultGroupName=Dolibarr
|
||||
;LicenseFile=COPYING
|
||||
@@ -100,9 +100,9 @@ Source: "build\exe\doliwamp\builddemosslfiles.bat.install"; DestDir: "{app}\"; F
|
||||
Source: "build\exe\doliwamp\UsedPort.exe"; DestDir: "{app}\"; Flags: ignoreversion;
|
||||
; PhpMyAdmin, Apache, Php, Mysql
|
||||
; Put here path of Wampserver applications
|
||||
; Value OK: apache 2.2.6, php 5.2.5 (5.2.11, 5.3.0 and 5.3.1 fails if php_exif, php_pgsql, php_zip is on), mysql 5.0.45
|
||||
; Value OK: apache 2.2.6, php 5.2.5 (5.2.11, 5.3.0 and 5.3.1 fails if php_exif, php_pgsql, php_zip is on), mysql 5.0.45
|
||||
; Value OK: apache 2.2.11, php 5.3.0 (if no php_exif, php_pgsql, php_zip), mysql 5.0.45
|
||||
; Value ???: apache 2.4.19, php 5.5.12, mysql 5.0.45 instead of 5.6.17 (wampserver2.5-Apache-2.4.9-Mysql-5.6.17-php5.5.12-32b.exe)
|
||||
; Value OK: apache 2.4.19, php 5.5.12, mysql 5.0.45 instead of 5.6.17 (wampserver2.5-Apache-2.4.9-Mysql-5.6.17-php5.5.12-32b.exe)
|
||||
Source: "C:\Program Files\Wamp\apps\phpmyadmin4.1.14\*.*"; DestDir: "{app}\apps\phpmyadmin4.1.14"; Flags: ignoreversion recursesubdirs; Excludes: "config.inc.php,wampserver.conf,*.log,*_log,darkblue_orange"
|
||||
Source: "C:\Program Files\Wamp\bin\apache\apache2.4.9\*.*"; DestDir: "{app}\bin\apache\apache2.4.9"; Flags: ignoreversion recursesubdirs; Excludes: "php.ini,httpd.conf,wampserver.conf,*.log,*_log"
|
||||
Source: "C:\Program Files\Wamp\bin\php\php5.5.12\*.*"; DestDir: "{app}\bin\php\php5.5.12"; Flags: ignoreversion recursesubdirs; Excludes: "php.ini,phpForApache.ini,wampserver.conf,*.log,*_log"
|
||||
|
||||
@@ -527,10 +527,10 @@ a:hover {
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<table width="100%"><tr><td align="left">
|
||||
<table width="100%"><tr><td class="left">
|
||||
<img src="index.php?img=pngLogo">
|
||||
</td>
|
||||
<td align="right">
|
||||
<td class="right">
|
||||
<ul class="utility">
|
||||
<li><a href="?lang={$langues[$langue]['autreLangueLien1']}">{$langues[$langue]['autreLangue1']}</a>
|
||||
- <a href="?lang={$langues[$langue]['autreLangueLien2']}">{$langues[$langue]['autreLangue2']}</a></li>
|
||||
@@ -587,4 +587,4 @@ a:hover {
|
||||
EOPAGE;
|
||||
|
||||
echo $pageContents;
|
||||
?>
|
||||
?>
|
||||
|
||||
@@ -3,4 +3,4 @@ REM Launch Dolibarr Admin center
|
||||
REM ----------------------------
|
||||
|
||||
REM Go to admin center page
|
||||
start "DoliWamp admin" "WAMPBROWSER" http://localhost:WAMPAPACHEPORT/
|
||||
start "WAMPBROWSER" http://localhost:WAMPAPACHEPORT/
|
||||
|
||||
@@ -4,4 +4,4 @@ REM ---------------------------
|
||||
|
||||
REM Go to help center page
|
||||
echo Please wait...
|
||||
start "Dolibarr Help center" "WAMPBROWSER" http://localhost:WAMPAPACHEPORT/dolibarr/support/
|
||||
start "WAMPBROWSER" http://localhost:WAMPAPACHEPORT/dolibarr/support/
|
||||
|
||||
@@ -3,7 +3,7 @@ REM Launch Dolibarr
|
||||
REM ---------------
|
||||
|
||||
REM If no lock file, we call install process
|
||||
IF NOT EXIST dolibarr_documents\install.lock start "Dolibarr" "WAMPBROWSER" http://localhost:WAMPAPACHEPORT/dolibarr/install/
|
||||
IF NOT EXIST dolibarr_documents\install.lock start "WAMPBROWSER" http://localhost:WAMPAPACHEPORT/dolibarr/install/
|
||||
|
||||
REM If lock file exists, we call home page
|
||||
IF EXIST dolibarr_documents\install.lock start "Dolibarr" "WAMPBROWSER" http://localhost:WAMPAPACHEPORT/dolibarr/
|
||||
IF EXIST dolibarr_documents\install.lock start "WAMPBROWSER" http://localhost:WAMPAPACHEPORT/dolibarr/
|
||||
|
||||
1
build/flatpack/org.flatpak.Dolibarr.json
Normal file
1
build/flatpack/org.flatpak.Dolibarr.json
Normal file
@@ -0,0 +1 @@
|
||||
Help wanted...
|
||||
@@ -22,6 +22,8 @@
|
||||
* \brief This script create a xml checksum file
|
||||
*/
|
||||
|
||||
if (! defined('NOREQUIREDB')) define('NOREQUIREDB', '1'); // Do not create database handler $db
|
||||
|
||||
$sapi_type = php_sapi_name();
|
||||
$script_file = basename(__FILE__);
|
||||
$path=dirname(__FILE__).'/';
|
||||
@@ -32,8 +34,8 @@ if (substr($sapi_type, 0, 3) == 'cgi') {
|
||||
exit;
|
||||
}
|
||||
|
||||
require_once($path."../htdocs/master.inc.php");
|
||||
require_once(DOL_DOCUMENT_ROOT."/core/lib/files.lib.php");
|
||||
require_once $path."../htdocs/master.inc.php";
|
||||
require_once DOL_DOCUMENT_ROOT."/core/lib/files.lib.php";
|
||||
|
||||
|
||||
/*
|
||||
@@ -43,23 +45,19 @@ require_once(DOL_DOCUMENT_ROOT."/core/lib/files.lib.php");
|
||||
$includecustom=0;
|
||||
$includeconstants=array();
|
||||
|
||||
if (empty($argv[1]))
|
||||
{
|
||||
print "Usage: ".$script_file." release=auto|x.y.z[-mybuild] [includecustom=1] [includeconstant=CC:MY_CONF_NAME:value]\n";
|
||||
if (empty($argv[1])) {
|
||||
print "Usage: ".$script_file." release=autostable|auto[-mybuild]|x.y.z[-mybuild] [includecustom=1] [includeconstant=CC:MY_CONF_NAME:value]\n";
|
||||
print "Example: ".$script_file." release=6.0.0 includecustom=1 includeconstant=FR:INVOICE_CAN_ALWAYS_BE_REMOVED:0 includeconstant=all:MAILING_NO_USING_PHPMAIL:1\n";
|
||||
exit -1;
|
||||
}
|
||||
parse_str($argv[1]);
|
||||
|
||||
$i=0;
|
||||
while ($i < $argc)
|
||||
{
|
||||
while ($i < $argc) {
|
||||
if (! empty($argv[$i])) parse_str($argv[$i]);
|
||||
if (preg_match('/includeconstant=/',$argv[$i]))
|
||||
{
|
||||
if (preg_match('/includeconstant=/', $argv[$i])) {
|
||||
$tmp=explode(':', $includeconstant, 3);
|
||||
if (count($tmp) != 3)
|
||||
{
|
||||
if (count($tmp) != 3) {
|
||||
print "Error: Bad parameter includeconstant ".$includeconstant."\n";
|
||||
exit -1;
|
||||
}
|
||||
@@ -68,30 +66,41 @@ while ($i < $argc)
|
||||
$i++;
|
||||
}
|
||||
|
||||
// If release is auto, we take current version
|
||||
$tmpver=explode('-', $release, 2);
|
||||
if ($tmpver[0] == 'auto')
|
||||
{
|
||||
$release=DOL_VERSION;
|
||||
if ($tmpver[1]) $release.='-'.$tmpver[1];
|
||||
if (empty($release)) {
|
||||
print "Error: Missing release paramater\n";
|
||||
print "Usage: ".$script_file." release=autostable|auto[-mybuild]|x.y.z[-mybuild] [includecustom=1] [includeconstant=CC:MY_CONF_NAME:value]\n";
|
||||
exit -1;
|
||||
}
|
||||
|
||||
if (empty($includecustom))
|
||||
{
|
||||
$tmpver=explode('-', $release, 2);
|
||||
if (DOL_VERSION != $tmpver[0])
|
||||
{
|
||||
print 'Error: When parameter "includecustom" is not set and there is no suffix in release parameter, version declared into filefunc.in.php ('.DOL_VERSION.') must be exact same value than "release" parameter ('.$tmpver[0].')'."\n";
|
||||
print "Usage: ".$script_file." release=x.y.z[-...] [includecustom=1]\n";
|
||||
exit -1;
|
||||
}
|
||||
$savrelease = $release;
|
||||
|
||||
// If release is auto, we take current version
|
||||
$tmpver=explode('-', $release, 2);
|
||||
if ($tmpver[0] == 'auto' || $tmpver[0] == 'autostable') {
|
||||
$release=DOL_VERSION;
|
||||
if ($tmpver[1] && $tmpver[0] == 'auto') $release.='-'.$tmpver[1];
|
||||
}
|
||||
else
|
||||
{
|
||||
if (! preg_match('/'.preg_quote(DOL_VERSION,'/').'-/',$release))
|
||||
{
|
||||
print 'Error: When parameter "includecustom" is set, version declared into filefunc.inc.php ('.DOL_VERSION.') must be used with a suffix into "release" parmater (ex: '.DOL_VERSION.'-mydistrib).'."\n";
|
||||
print "Usage: ".$script_file." release=x.y.z[-...] [includecustom=1]\n";
|
||||
|
||||
if (empty($includecustom)) {
|
||||
$tmpverbis=explode('-', $release, 2);
|
||||
if (empty($tmpverbis[1]) || $tmpver[0] == 'autostable') {
|
||||
if (DOL_VERSION != $tmpverbis[0] && $savrelease != 'auto') {
|
||||
print 'Error: When parameter "includecustom" is not set and there is no suffix in release parameter, version declared into filefunc.in.php ('.DOL_VERSION.') must be exact same value than "release" parameter ('.$tmpverbis[0].')'."\n";
|
||||
print "Usage: ".$script_file." release=autostable|auto[-mybuild]|x.y.z[-mybuild] [includecustom=1] [includeconstant=CC:MY_CONF_NAME:value]\n";
|
||||
exit -1;
|
||||
}
|
||||
} else {
|
||||
$tmpverter=explode('-', DOL_VERSION, 2);
|
||||
if ($tmpverter[0] != $tmpverbis[0]) {
|
||||
print 'Error: When parameter "includecustom" is not set, version declared into filefunc.in.php ('.DOL_VERSION.') must have value without prefix ('.$tmpverter[0].') that is exact same value than "release" parameter ('.$tmpverbis[0].')'."\n";
|
||||
print "Usage: ".$script_file." release=autostable|auto[-mybuild]|x.y.z[-mybuild] [includecustom=1] [includeconstant=CC:MY_CONF_NAME:value]\n";
|
||||
exit -1;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
if (! preg_match('/'.preg_quote(DOL_VERSION, '/').'-/', $release)) {
|
||||
print 'Error: When parameter "includecustom" is set, version declared into filefunc.inc.php ('.DOL_VERSION.') must be used with a suffix into "release" parameter (ex: '.DOL_VERSION.'-mydistrib).'."\n";
|
||||
print "Usage: ".$script_file." release=autostable|auto[-mybuild]|x.y.z[-mybuild] [includecustom=1] [includeconstant=CC:MY_CONF_NAME:value]\n";
|
||||
exit -1;
|
||||
}
|
||||
}
|
||||
@@ -99,10 +108,8 @@ else
|
||||
print "Release : ".$release."\n";
|
||||
print "Include custom in signature : ".$includecustom."\n";
|
||||
print "Include constants in signature : ";
|
||||
foreach ($includeconstants as $countrycode => $tmp)
|
||||
{
|
||||
foreach($tmp as $constname => $constvalue)
|
||||
{
|
||||
foreach ($includeconstants as $countrycode => $tmp) {
|
||||
foreach($tmp as $constname => $constvalue) {
|
||||
print $constname.'='.$constvalue." ";
|
||||
}
|
||||
}
|
||||
@@ -111,20 +118,18 @@ print "\n";
|
||||
//$outputfile=dirname(__FILE__).'/../htdocs/install/filelist-'.$release.'.xml';
|
||||
$outputdir=dirname(dirname(__FILE__)).'/htdocs/install';
|
||||
print 'Delete current files '.$outputdir.'/filelist*.xml'."\n";
|
||||
dol_delete_file($outputdir.'/filelist*.xml',0,1,1);
|
||||
dol_delete_file($outputdir.'/filelist*.xml', 0, 1, 1);
|
||||
|
||||
$checksumconcat=array();
|
||||
|
||||
$outputfile=$outputdir.'/filelist-'.$release.'.xml';
|
||||
$fp = fopen($outputfile,'w');
|
||||
$fp = fopen($outputfile, 'w');
|
||||
fputs($fp, '<?xml version="1.0" encoding="UTF-8" ?>'."\n");
|
||||
fputs($fp, '<checksum_list version="'.$release.'" date="'.dol_print_date(dol_now(), 'dayhourrfc').'" generator="'.$script_file.'">'."\n");
|
||||
|
||||
foreach ($includeconstants as $countrycode => $tmp)
|
||||
{
|
||||
foreach ($includeconstants as $countrycode => $tmp) {
|
||||
fputs($fp, '<dolibarr_constants country="'.$countrycode.'">'."\n");
|
||||
foreach($tmp as $constname => $constvalue)
|
||||
{
|
||||
foreach($tmp as $constname => $constvalue) {
|
||||
$valueforchecksum=(empty($constvalue)?'0':$constvalue);
|
||||
$checksumconcat[]=$valueforchecksum;
|
||||
fputs($fp, ' <constant name="'.$constname.'">'.$valueforchecksum.'</constant>'."\n");
|
||||
@@ -145,10 +150,10 @@ $files = dol_dir_list(DOL_DOCUMENT_ROOT, 'files', 1, $regextoinclude, $regextoex
|
||||
$dir='';
|
||||
$needtoclose=0;
|
||||
foreach ($files as $filetmp) {
|
||||
$file = $filetmp['fullname'];
|
||||
//$newdir = str_replace(dirname(__FILE__).'/../htdocs', '', dirname($file));
|
||||
$newdir = str_replace(DOL_DOCUMENT_ROOT, '', dirname($file));
|
||||
if ($newdir!=$dir) {
|
||||
$file = $filetmp['fullname'];
|
||||
//$newdir = str_replace(dirname(__FILE__).'/../htdocs', '', dirname($file));
|
||||
$newdir = str_replace(DOL_DOCUMENT_ROOT, '', dirname($file));
|
||||
if ($newdir!=$dir) {
|
||||
if ($needtoclose)
|
||||
fputs($fp, ' </dir>'."\n");
|
||||
fputs($fp, ' <dir name="'.$newdir.'" >'."\n");
|
||||
@@ -167,7 +172,7 @@ fputs($fp, '</dolibarr_htdocs_dir>'."\n");
|
||||
asort($checksumconcat); // Sort list of checksum
|
||||
//var_dump($checksumconcat);
|
||||
fputs($fp, '<dolibarr_htdocs_dir_checksum>'."\n");
|
||||
fputs($fp, md5(join(',',$checksumconcat))."\n");
|
||||
fputs($fp, md5(join(',', $checksumconcat))."\n");
|
||||
fputs($fp, '</dolibarr_htdocs_dir_checksum>'."\n");
|
||||
|
||||
|
||||
@@ -187,10 +192,10 @@ $files = dol_dir_list(dirname(__FILE__).'/../scripts/', 'files', 1, $regextoincl
|
||||
$dir='';
|
||||
$needtoclose=0;
|
||||
foreach ($files as $filetmp) {
|
||||
$file = $filetmp['fullname'];
|
||||
//$newdir = str_replace(dirname(__FILE__).'/../scripts', '', dirname($file));
|
||||
$newdir = str_replace(DOL_DOCUMENT_ROOT, '', dirname($file));
|
||||
$newdir = str_replace(dirname(__FILE__).'/../scripts', '', dirname($file));
|
||||
$file = $filetmp['fullname'];
|
||||
//$newdir = str_replace(dirname(__FILE__).'/../scripts', '', dirname($file));
|
||||
$newdir = str_replace(DOL_DOCUMENT_ROOT, '', dirname($file));
|
||||
$newdir = str_replace(dirname(__FILE__).'/../scripts', '', dirname($file));
|
||||
if ($newdir!=$dir) {
|
||||
if ($needtoclose)
|
||||
fputs($fp, ' </dir>'."\n");
|
||||
@@ -209,7 +214,7 @@ fputs($fp, '</dolibarr_script_dir>'."\n");
|
||||
|
||||
asort($checksumconcat); // Sort list of checksum
|
||||
fputs($fp, '<dolibarr_script_dir_checksum>'."\n");
|
||||
fputs($fp, md5(join(',',$checksumconcat))."\n");
|
||||
fputs($fp, md5(join(',', $checksumconcat))."\n");
|
||||
fputs($fp, '</dolibarr_script_dir_checksum>'."\n");
|
||||
|
||||
fputs($fp, '</checksum_list>'."\n");
|
||||
|
||||
@@ -22,7 +22,7 @@ $PUBLISHSTABLE="eldy,dolibarr\@frs.sourceforge.net:/home/frs/project/dolibarr";
|
||||
$PUBLISHBETARC="dolibarr\@vmprod1.dolibarr.org:/home/dolibarr/dolibarr.org/httpdocs/files";
|
||||
|
||||
|
||||
#@LISTETARGET=("TGZ","ZIP","RPM_GENERIC","RPM_FEDORA","RPM_MANDRIVA","RPM_OPENSUSE","DEB","APS","EXEDOLIWAMP","SNAPSHOT"); # Possible packages
|
||||
#@LISTETARGET=("TGZ","ZIP","RPM_GENERIC","RPM_FEDORA","RPM_MANDRIVA","RPM_OPENSUSE","DEB","EXEDOLIWAMP","SNAPSHOT"); # Possible packages
|
||||
@LISTETARGET=("TGZ","ZIP","RPM_GENERIC","RPM_FEDORA","RPM_MANDRIVA","RPM_OPENSUSE","DEB","EXEDOLIWAMP","SNAPSHOT"); # Possible packages
|
||||
%REQUIREMENTPUBLISH=(
|
||||
"SF"=>"git ssh rsync",
|
||||
@@ -36,8 +36,8 @@ $PUBLISHBETARC="dolibarr\@vmprod1.dolibarr.org:/home/dolibarr/dolibarr.org/httpd
|
||||
"RPM_FEDORA"=>"rpmbuild",
|
||||
"RPM_MANDRIVA"=>"rpmbuild",
|
||||
"RPM_OPENSUSE"=>"rpmbuild",
|
||||
"DEB"=>"dpkg",
|
||||
"APS"=>"zip",
|
||||
"DEB"=>"dpkg dpatch",
|
||||
"FLATPACK"=>"flatpack",
|
||||
"EXEDOLIWAMP"=>"ISCC.exe",
|
||||
"SNAPSHOT"=>"tar"
|
||||
);
|
||||
@@ -142,7 +142,6 @@ $FILENAMETGZ = "$PROJECT-$MAJOR.$MINOR.$BUILD";
|
||||
$FILENAMEZIP = "$PROJECT-$MAJOR.$MINOR.$BUILD";
|
||||
$FILENAMEXZ = "$PROJECT-$MAJOR.$MINOR.$BUILD";
|
||||
$FILENAMEDEB = "see later";
|
||||
$FILENAMEAPS = "$PROJECT-$MAJOR.$MINOR.$BUILD.app";
|
||||
$FILENAMEEXEDOLIWAMP = "DoliWamp-$MAJOR.$MINOR.$BUILD";
|
||||
# For RPM
|
||||
$ARCH='noarch';
|
||||
@@ -362,12 +361,12 @@ if ($nboftargetok) {
|
||||
}
|
||||
if (! $BUILD || $BUILD eq '0-rc') # For a major version
|
||||
{
|
||||
print 'cd ~/git/dolibarr_'.$MAJOR.'.'.$MINOR.'; git log `git rev-list --boundary '.$MAJOR.'.'.$MINOR.'..origin/develop | grep ^- | cut -c2- | head -n 1`.. --no-merges --pretty=short --oneline | sed -e "s/^[0-9a-z]* //" | grep -e \'^FIX\|NEW\' | sort -u | sed \'s/FIXED:/FIX:/g\' | sed \'s/FIXED :/FIX:/g\' | sed \'s/FIX :/FIX:/g\' | sed \'s/FIX /FIX: /g\' | sed \'s/NEW :/NEW:/g\' | sed \'s/NEW /NEW: /g\' > /tmp/aaa';
|
||||
print 'cd ~/git/dolibarr_'.$MAJOR.'.'.$MINOR.'; git log `git rev-list --boundary '.$MAJOR.'.'.$MINOR.'..origin/develop | grep ^- | cut -c2- | head -n 1`.. --no-merges --pretty=short --oneline | sed -e "s/^[0-9a-z]* //" | grep -e \'^FIX\|NEW\|CLOSE\' | sort -u | sed \'s/FIXED:/FIX:/g\' | sed \'s/FIXED :/FIX:/g\' | sed \'s/FIX :/FIX:/g\' | sed \'s/FIX /FIX: /g\' | sed \'s/CLOSE/NEW/g\' | sed \'s/NEW :/NEW:/g\' | sed \'s/NEW /NEW: /g\' > /tmp/aaa';
|
||||
}
|
||||
else # For a maintenance release
|
||||
{
|
||||
#print 'cd ~/git/dolibarr_'.$MAJOR.'.'.$MINOR.'; git log '.$MAJOR.'.'.$MINOR.'.'.($BUILD-1).'.. --no-merges --pretty=short --oneline | sed -e "s/^[0-9a-z]* //" | grep -e \'^FIX\|NEW\' | sort -u | sed \'s/FIXED:/FIX:/g\' | sed \'s/FIXED :/FIX:/g\' | sed \'s/FIX :/FIX:/g\' | sed \'s/FIX /FIX: /g\' | sed \'s/NEW :/NEW:/g\' | sed \'s/NEW /NEW: /g\' > /tmp/aaa';
|
||||
print 'cd ~/git/dolibarr_'.$MAJOR.'.'.$MINOR.'; git log '.$MAJOR.'.'.$MINOR.'.'.($BUILD-1).'.. | grep -v "Merge branch" | grep -v "Merge pull" | grep "^ " | sed -e "s/^[0-9a-z]* *//" | grep -e \'^FIX\|NEW\' | sort -u | sed \'s/FIXED:/FIX:/g\' | sed \'s/FIXED :/FIX:/g\' | sed \'s/FIX :/FIX:/g\' | sed \'s/FIX /FIX: /g\' | sed \'s/NEW :/NEW:/g\' | sed \'s/NEW /NEW: /g\' > /tmp/aaa';
|
||||
#print 'cd ~/git/dolibarr_'.$MAJOR.'.'.$MINOR.'; git log '.$MAJOR.'.'.$MINOR.'.'.($BUILD-1).'.. --no-merges --pretty=short --oneline | sed -e "s/^[0-9a-z]* //" | grep -e \'^FIX\|NEW\' | sort -u | sed \'s/FIXED:/FIX:/g\' | sed \'s/FIXED :/FIX:/g\' | sed \'s/FIX :/FIX:/g\' | sed \'s/FIX /FIX: /g\' | sed \'s/CLOSE/NEW/g\'| sed \'s/NEW :/NEW:/g\' | sed \'s/NEW /NEW: /g\' > /tmp/aaa';
|
||||
print 'cd ~/git/dolibarr_'.$MAJOR.'.'.$MINOR.'; git log '.$MAJOR.'.'.$MINOR.'.'.($BUILD-1).'.. | grep -v "Merge branch" | grep -v "Merge pull" | grep "^ " | sed -e "s/^[0-9a-z]* *//" | grep -e \'^FIX\|NEW\|CLOSE\' | sort -u | sed \'s/FIXED:/FIX:/g\' | sed \'s/FIXED :/FIX:/g\' | sed \'s/FIX :/FIX:/g\' | sed \'s/FIX /FIX: /g\' | sed \'s/CLOSE/NEW/g\' | sed \'s/NEW :/NEW:/g\' | sed \'s/NEW /NEW: /g\' > /tmp/aaa';
|
||||
|
||||
}
|
||||
print "\n";
|
||||
@@ -388,6 +387,15 @@ if ($nboftargetok) {
|
||||
#-----------------------
|
||||
if ($CHOOSEDTARGET{'-CHKSUM'})
|
||||
{
|
||||
$ret=`git ls-files . --exclude-standard --others`;
|
||||
if ($ret)
|
||||
{
|
||||
print "Some files exists in source directory and are not indexed neither excluded in .gitignore.\n";
|
||||
print $ret;
|
||||
print "Canceled.\n";
|
||||
exit;
|
||||
}
|
||||
|
||||
print 'Create xml check file with md5 checksum with command php '.$SOURCE.'/build/generate_filelist_xml.php release='.$MAJOR.'.'.$MINOR.'.'.$BUILD."\n";
|
||||
$ret=`php $SOURCE/build/generate_filelist_xml.php release=$MAJOR.$MINOR.$BUILD`;
|
||||
print $ret."\n";
|
||||
@@ -466,10 +474,12 @@ if ($nboftargetok) {
|
||||
$ret=`rm -f $BUILDROOT/$PROJECT/build/dolibarr_*.deb`;
|
||||
$ret=`rm -f $BUILDROOT/$PROJECT/build/dolibarr_*.dsc`;
|
||||
$ret=`rm -f $BUILDROOT/$PROJECT/build/dolibarr_*.tar.gz`;
|
||||
$ret=`rm -f $BUILDROOT/$PROJECT/build/dolibarr_*.tar.xz`;
|
||||
$ret=`rm -f $BUILDROOT/$PROJECT/build/dolibarr-*.deb`;
|
||||
$ret=`rm -f $BUILDROOT/$PROJECT/build/dolibarr-*.rpm`;
|
||||
$ret=`rm -f $BUILDROOT/$PROJECT/build/dolibarr-*.tar`;
|
||||
$ret=`rm -f $BUILDROOT/$PROJECT/build/dolibarr-*.tar.gz`;
|
||||
$ret=`rm -f $BUILDROOT/$PROJECT/build/dolibarr-*.tar.xz`;
|
||||
$ret=`rm -f $BUILDROOT/$PROJECT/build/dolibarr-*.tgz`;
|
||||
$ret=`rm -f $BUILDROOT/$PROJECT/build/dolibarr-*.xz`;
|
||||
$ret=`rm -f $BUILDROOT/$PROJECT/build/dolibarr-*.zip`;
|
||||
@@ -521,12 +531,21 @@ if ($nboftargetok) {
|
||||
$ret=`rm -f $BUILDROOT/$PROJECT/doc/images/dolibarr_screenshot12.png`;
|
||||
|
||||
# Security to avoid to package data files
|
||||
print "Remove documents dir\n";
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT/document`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT/documents`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/document`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/documents`;
|
||||
|
||||
print "Remove subdir of custom dir\n";
|
||||
print "find $BUILDROOT/$PROJECT/htdocs/custom/* -type d -exec rm -fr {} \\;\n";
|
||||
$ret=`find $BUILDROOT/$PROJECT/htdocs/custom/* -type d -exec rm -fr {} \\; >/dev/null 2>&1`; # For custom we want to remove all subdirs but not files
|
||||
print "find $BUILDROOT/$PROJECT/htdocs/custom/* -type l -exec rm -fr {} \\;\n";
|
||||
$ret=`find $BUILDROOT/$PROJECT/htdocs/custom/* -type l -exec rm -fr {} \\; >/dev/null 2>&1`; # For custom we want to remove all subdirs, even symbolic links, but not files
|
||||
|
||||
# Removed known external modules to avoid any error when packaging from env where external modules are tested
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/abricot*`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/accountingexport*`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/allscreens*`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/ancotec*`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/cabinetmed*`;
|
||||
@@ -541,12 +560,14 @@ if ($nboftargetok) {
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/multicompany*`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/ndf*`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/nltechno*`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/nomenclature*`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/of/`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/oscim*`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/pos*`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/teclib*`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/timesheet*`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/webmail*`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/accountingexport*`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/workstation*`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/themes/oblyon*`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/themes/allscreen*`;
|
||||
# Removed other test files
|
||||
@@ -577,6 +598,8 @@ if ($nboftargetok) {
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/phpoffice/phpexcel/Examples`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/phpoffice/phpexcel/unitTests`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/phpoffice/phpexcel/license.md`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/sabre/sabre/*/tests`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/stripe/tests`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/stripe/LICENSE`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/tcpdf/fonts/dejavu-fonts-ttf-*`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/tcpdf/fonts/freefont-*`;
|
||||
@@ -590,13 +613,6 @@ if ($nboftargetok) {
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/tecnickcom/tcpdf/tools`;
|
||||
$ret=`rm -f $BUILDROOT/$PROJECT/htdocs/includes/tecnickcom/tcpdf/LICENSE.TXT`;
|
||||
$ret=`rm -f $BUILDROOT/$PROJECT/htdocs/theme/common/octicons/LICENSE`;
|
||||
|
||||
|
||||
print "Remove subdir of custom dir\n";
|
||||
print "find $BUILDROOT/$PROJECT/htdocs/custom/* -type d -exec rm -fr {} \\;\n";
|
||||
$ret=`find $BUILDROOT/$PROJECT/htdocs/custom/* -type d -exec rm -fr {} \\; >/dev/null 2>&1`; # For custom we want to remove all subdirs but not files
|
||||
print "find $BUILDROOT/$PROJECT/htdocs/custom/* -type l -exec rm -fr {} \\;\n";
|
||||
$ret=`find $BUILDROOT/$PROJECT/htdocs/custom/* -type l -exec rm -fr {} \\; >/dev/null 2>&1`; # For custom we want to remove all subdirs, even symbolic links, but not files
|
||||
}
|
||||
|
||||
# Build package for each target
|
||||
@@ -690,7 +706,7 @@ if ($nboftargetok) {
|
||||
print "Go to directory $BUILDROOT\n";
|
||||
$olddir=getcwd();
|
||||
chdir("$BUILDROOT");
|
||||
$cmd= "xz -9 -r $BUILDROOT/$FILENAMEAPS.xz \*";
|
||||
$cmd= "xz -9 -r $BUILDROOT/$FILENAMEXZ.xz \*";
|
||||
print $cmd."\n";
|
||||
$ret= `$cmd`;
|
||||
chdir("$olddir");
|
||||
@@ -849,6 +865,8 @@ if ($nboftargetok) {
|
||||
unlink("$NEWDESTI/${FILENAMEDEB}.changes");
|
||||
print "Remove target ${FILENAMEDEB}.debian.tar.gz...\n";
|
||||
unlink("$NEWDESTI/${FILENAMEDEB}.debian.tar.gz");
|
||||
print "Remove target ${FILENAMEDEB}.debian.tar.xz...\n";
|
||||
unlink("$NEWDESTI/${FILENAMEDEB}.debian.tar.xz");
|
||||
print "Remove target ${FILENAMEDEBNATIVE}.orig.tar.gz...\n";
|
||||
unlink("$NEWDESTI/${FILENAMEDEBNATIVE}.orig.tar.gz");
|
||||
|
||||
@@ -1024,97 +1042,11 @@ if ($nboftargetok) {
|
||||
$ret=`mv $BUILDROOT/*_all.deb "$NEWDESTI/"`;
|
||||
$ret=`mv $BUILDROOT/*.dsc "$NEWDESTI/"`;
|
||||
$ret=`mv $BUILDROOT/*.orig.tar.gz "$NEWDESTI/"`;
|
||||
$ret=`mv $BUILDROOT/*.debian.tar.gz "$NEWDESTI/"`;
|
||||
$ret=`mv $BUILDROOT/*.debian.tar.xz "$NEWDESTI/"`;
|
||||
$ret=`mv $BUILDROOT/*.changes "$NEWDESTI/"`;
|
||||
next;
|
||||
}
|
||||
|
||||
if ($target eq 'APS')
|
||||
{
|
||||
$NEWDESTI=$DESTI;
|
||||
if ($NEWDESTI =~ /stable/)
|
||||
{
|
||||
mkdir($DESTI.'/package_aps');
|
||||
if (-d $DESTI.'/package_aps') { $NEWDESTI=$DESTI.'/package_aps'; }
|
||||
}
|
||||
|
||||
$newbuild = $BUILD;
|
||||
$newbuild =~ s/(dev|alpha)/0/gi; # dev
|
||||
$newbuild =~ s/beta/1/gi; # beta
|
||||
$newbuild =~ s/rc./2/gi; # rc
|
||||
if ($newbuild !~ /-/) { $newbuild.='-3'; } # finale
|
||||
# now newbuild is 0-0 or 0-3 for example
|
||||
$REL1 = $newbuild; $REL1 =~ s/-.*$//gi;
|
||||
if ($RPMSUBVERSION eq 'auto') { $RPMSUBVERSION = $newbuild; $RPMSUBVERSION =~ s/^.*-//gi; }
|
||||
print "Version is $MAJOR.$MINOR.$REL1-$RPMSUBVERSION\n";
|
||||
|
||||
print "Remove target $FILENAMEAPS.zip...\n";
|
||||
unlink "$NEWDESTI/$FILENAMEAPS.zip";
|
||||
|
||||
#rmdir "$BUILDROOT/$PROJECT.tmp";
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT.tmp`;
|
||||
print "Create directory $BUILDROOT/$PROJECT.tmp\n";
|
||||
$ret=`mkdir -p "$BUILDROOT/$PROJECT.tmp"`;
|
||||
print "Copy $BUILDROOT/$PROJECT to $BUILDROOT/$PROJECT.tmp\n";
|
||||
$cmd="cp -pr \"$BUILDROOT/$PROJECT\" \"$BUILDROOT/$PROJECT.tmp\"";
|
||||
$ret=`$cmd`;
|
||||
|
||||
print "Remove other files\n";
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT.tmp/$PROJECT/build/deb`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT.tmp/$PROJECT/build/dmg`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT.tmp/$PROJECT/build/doap`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT.tmp/$PROJECT/build/exe`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT.tmp/$PROJECT/build/live`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT.tmp/$PROJECT/build/patch`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT.tmp/$PROJECT/build/rpm`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT.tmp/$PROJECT/build/zip`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT.tmp/$PROJECT/build/perl`;
|
||||
|
||||
$APSVERSION="1.2";
|
||||
print "Create APS files $BUILDROOT/$PROJECT.tmp/$PROJECT/APP-META.xml\n";
|
||||
open (SPECFROM,"<$BUILDROOT/$PROJECT/build/aps/APP-META-$APSVERSION.xml") || die "Error";
|
||||
open (SPECTO,">$BUILDROOT/$PROJECT.tmp/$PROJECT/APP-META.xml") || die "Error";
|
||||
while (<SPECFROM>) {
|
||||
$newbuild = $BUILD;
|
||||
$newbuild =~ s/(dev|alpha)/0/gi; # dev
|
||||
$newbuild =~ s/beta/1/gi; # beta
|
||||
$newbuild =~ s/rc./2/gi; # rc
|
||||
if ($newbuild !~ /-/) { $newbuild.='-3'; } # finale
|
||||
# now newbuild is 0-0 or 0-3 for example
|
||||
$_ =~ s/__VERSION__/$MAJOR.$MINOR.$REL1/;
|
||||
$_ =~ s/__RELEASE__/$RPMSUBVERSION/;
|
||||
print SPECTO $_;
|
||||
}
|
||||
close SPECFROM;
|
||||
close SPECTO;
|
||||
print "Version set to $MAJOR.$MINOR.$newbuild\n";
|
||||
$cmd="cp -pr \"$BUILDROOT/$PROJECT/build/aps/configure.php\" \"$BUILDROOT/$PROJECT.tmp/$PROJECT/scripts/configure.php\"";
|
||||
$ret=`$cmd`;
|
||||
$cmd="cp -pr \"$BUILDROOT/$PROJECT/doc/images\" \"$BUILDROOT/$PROJECT.tmp/$PROJECT/images\"";
|
||||
$ret=`$cmd`;
|
||||
|
||||
print "Remove other files\n";
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT.tmp/$PROJECT/dev`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT.tmp/$PROJECT/doc`;
|
||||
|
||||
print "Build APP-LIST.xml files\n";
|
||||
|
||||
print "Compress $BUILDROOT/$PROJECT.tmp/$PROJECT into $FILENAMEAPS.zip...\n";
|
||||
|
||||
print "Go to directory $BUILDROOT/$PROJECT.tmp\/$PROJECT\n";
|
||||
$olddir=getcwd();
|
||||
chdir("$BUILDROOT\/$PROJECT.tmp\/$PROJECT");
|
||||
$cmd= "zip -9 -r $BUILDROOT/$FILENAMEAPS.zip \*";
|
||||
print $cmd."\n";
|
||||
$ret= `$cmd`;
|
||||
chdir("$olddir");
|
||||
|
||||
# Move to final dir
|
||||
print "Move $BUILDROOT/$FILENAMEAPS.zip to $NEWDESTI/$FILENAMEAPS.zip\n";
|
||||
$ret=`mv "$BUILDROOT/$FILENAMEAPS.zip" "$NEWDESTI/$FILENAMEAPS.zip"`;
|
||||
next;
|
||||
}
|
||||
|
||||
if ($target eq 'EXEDOLIWAMP')
|
||||
{
|
||||
$NEWDESTI=$DESTI;
|
||||
@@ -1136,7 +1068,7 @@ if ($nboftargetok) {
|
||||
$ret=`cat "$SOURCE/build/exe/doliwamp/doliwamp.iss" | sed -e 's/__FILENAMEEXEDOLIWAMP__/$FILENAMEEXEDOLIWAMP/g' > "$SOURCE/build/exe/doliwamp/doliwamp.tmp.iss"`;
|
||||
|
||||
print "Compil exe $FILENAMEEXEDOLIWAMP.exe file from iss file \"$SOURCEBACK\\build\\exe\\doliwamp\\doliwamp.tmp.iss\"\n";
|
||||
$cmd= "ISCC.exe \"Z:$SOURCEBACK\\build\\exe\\doliwamp\\doliwamp.tmp.iss\"";
|
||||
$cmd= "wine ISCC.exe \"Z:$SOURCEBACK\\build\\exe\\doliwamp\\doliwamp.tmp.iss\"";
|
||||
print "$cmd\n";
|
||||
$ret= `$cmd`;
|
||||
#print "$ret\n";
|
||||
@@ -1168,7 +1100,7 @@ if ($nboftargetok) {
|
||||
"$DESTI/package_debian-ubuntu/${FILENAMEDEB}_all.deb"=>'Dolibarr installer for Debian-Ubuntu (DoliDeb)',
|
||||
"$DESTI/package_debian-ubuntu/${FILENAMEDEB}_amd64.changes"=>'none', # none means it won't be published on SF
|
||||
"$DESTI/package_debian-ubuntu/${FILENAMEDEB}.dsc"=>'none', # none means it won't be published on SF
|
||||
"$DESTI/package_debian-ubuntu/${FILENAMEDEB}.debian.tar.gz"=>'none', # none means it won't be published on SF
|
||||
"$DESTI/package_debian-ubuntu/${FILENAMEDEB}.debian.tar.xz"=>'none', # none means it won't be published on SF
|
||||
"$DESTI/package_debian-ubuntu/${FILENAMEDEBSHORT}.orig.tar.gz"=>'none', # none means it won't be published on SF
|
||||
"$DESTI/package_windows/$FILENAMEEXEDOLIWAMP.exe"=>'Dolibarr installer for Windows (DoliWamp)',
|
||||
"$DESTI/standard/$FILENAMETGZ.tgz"=>'Dolibarr ERP-CRM',
|
||||
@@ -1181,8 +1113,7 @@ if ($nboftargetok) {
|
||||
"$DESTI/package_debian-ubuntu/${FILENAMEDEB}_all.deb"=>'package_debian-ubuntu',
|
||||
"$DESTI/package_debian-ubuntu/${FILENAMEDEB}_amd64.changes"=>'package_debian-ubuntu',
|
||||
"$DESTI/package_debian-ubuntu/${FILENAMEDEB}.dsc"=>'package_debian-ubuntu',
|
||||
"$DESTI/package_debian-ubuntu/${FILENAMEDEB}.debian.tar.gz"=>'package_debian-ubuntu',
|
||||
"$DESTI/package_debian-ubuntu/${FILENAMEDEBSHORT}.orig.tar.gz"=>'package_debian-ubuntu',
|
||||
"$DESTI/package_debian-ubuntu/${FILENAMEDEB}.debian.tar.xz"=>'package_debian-ubuntu',
|
||||
"$DESTI/package_debian-ubuntu/${FILENAMEDEBSHORT}.orig.tar.gz"=>'package_debian-ubuntu',
|
||||
"$DESTI/package_windows/$FILENAMEEXEDOLIWAMP.exe"=>'package_windows',
|
||||
"$DESTI/standard/$FILENAMETGZ.tgz"=>'standard',
|
||||
|
||||
@@ -43,9 +43,9 @@ To generate a changelog of a maintenance version x.y.z, you can do "cd ~/git/dol
|
||||
- Run makepack-dolibarr.pl to generate all packages.
|
||||
|
||||
- Check content of built packages.
|
||||
- Move build files into www.dolibarr.org web site
|
||||
(/home/dolibarr/wwwroot/files/stable).
|
||||
|
||||
- Run makepack-dolibarr.pl again with option to publish files on
|
||||
dolibarr foundation server (Dir /home/dolibarr/wwwroot/files/stable on www.dolibarr.org).
|
||||
- Run makepack-dolibarr.pl again with option to publish files on
|
||||
sourceforge. This will also add official tag.
|
||||
- Edit symbolic links in directory "/home/dolibarr/wwwroot/files/stable/xxx"
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
#----------------------------------------------------------------------------
|
||||
# \file dolibarr.pl
|
||||
# \brief Dolibarr script install for Virtualmin Pro
|
||||
# \author (c)2009-2017 Regis Houssin <regis.houssin@capnetworks.com>
|
||||
# \author (c)2009-2018 Regis Houssin <regis.houssin@inodbox.com>
|
||||
#----------------------------------------------------------------------------
|
||||
|
||||
|
||||
@@ -30,7 +30,7 @@ return "Regis Houssin";
|
||||
# script_dolibarr_versions()
|
||||
sub script_dolibarr_versions
|
||||
{
|
||||
return ( "5.0.4", "4.0.6", "3.9.4" );
|
||||
return ( "9.0.0", "8.0.3", "7.0.4", "6.0.8", "5.0.7" );
|
||||
}
|
||||
|
||||
sub script_dolibarr_release
|
||||
@@ -263,15 +263,16 @@ if ($upgrade) {
|
||||
local @params = ( [ "action", "upgrade" ],
|
||||
[ "versionfrom", $upgrade->{'version'} ],
|
||||
[ "versionto", $ver ],
|
||||
[ "installlock", "444" ],
|
||||
);
|
||||
local $p = $ver >= 3.8 ? "step5" : "etape5";
|
||||
local $err = &call_dolibarr_wizard_page(\@params, $p, $d, $opts);
|
||||
return (-1, "Dolibarr wizard failed : $err") if ($err);
|
||||
|
||||
# Remove the installation directory.
|
||||
local $dinstall = "$opts->{'dir'}/install";
|
||||
$dinstall =~ s/\/$//;
|
||||
$out = &run_as_domain_user($d, "rm -rf ".quotemeta($dinstall));
|
||||
# Remove the installation directory. (deprecated)
|
||||
# local $dinstall = "$opts->{'dir'}/install";
|
||||
# $dinstall =~ s/\/$//;
|
||||
# $out = &run_as_domain_user($d, "rm -rf ".quotemeta($dinstall));
|
||||
|
||||
}
|
||||
else {
|
||||
@@ -306,15 +307,18 @@ else {
|
||||
[ "login", "admin" ],
|
||||
[ "pass", $dompass ],
|
||||
[ "pass_verif", $dompass ],
|
||||
[ "installlock", "444" ],
|
||||
);
|
||||
local $p = $ver >= 3.8 ? "step5" : "etape5";
|
||||
local $err = &call_dolibarr_wizard_page(\@params, $p, $d, $opts);
|
||||
return (-1, "Dolibarr wizard failed : $err") if ($err);
|
||||
|
||||
# Remove the installation directory and protect config file.
|
||||
local $dinstall = "$opts->{'dir'}/install";
|
||||
$dinstall =~ s/\/$//;
|
||||
$out = &run_as_domain_user($d, "rm -rf ".quotemeta($dinstall));
|
||||
# Remove the installation directory (deprecated)
|
||||
# local $dinstall = "$opts->{'dir'}/install";
|
||||
# $dinstall =~ s/\/$//;
|
||||
# $out = &run_as_domain_user($d, "rm -rf ".quotemeta($dinstall));
|
||||
|
||||
# Protect config file
|
||||
&set_permissions_as_domain_user($d, 0644, $cfile);
|
||||
&set_permissions_as_domain_user($d, 0755, $cfiledir);
|
||||
}
|
||||
@@ -386,14 +390,18 @@ sub script_dolibarr_check_latest
|
||||
{
|
||||
local ($ver) = @_;
|
||||
local @vers = &osdn_package_versions("dolibarr",
|
||||
$ver >= 5.0 ? "dolibarr\\-(5\\.0\\.[0-9\\.]+)\\.tgz" :
|
||||
$ver >= 4.0 ? "dolibarr\\-(4\\.0\\.[0-9\\.]+)\\.tgz" :
|
||||
$ver >= 3.9 ? "dolibarr\\-(3\\.9\\.[0-9\\.]+)\\.tgz" :
|
||||
$ver >= 3.8 ? "dolibarr\\-(3\\.8\\.[0-9\\.]+)\\.tgz" :
|
||||
$ver >= 3.7 ? "dolibarr\\-(3\\.7\\.[0-9\\.]+)\\.tgz" :
|
||||
$ver >= 3.6 ? "dolibarr\\-(3\\.6\\.[0-9\\.]+)\\.tgz" :
|
||||
$ver >= 3.5 ? "dolibarr\\-(3\\.5\\.[0-9\\.]+)\\.tgz" :
|
||||
$ver >= 2.9 ? "dolibarr\\-(2\\.9\\.[0-9\\.]+)\\.tgz" :
|
||||
$ver >= 9.0 ? "dolibarr\\-(9\\.0\\.[0-9\\.]+)\\.tgz" :
|
||||
$ver >= 8.0 ? "dolibarr\\-(8\\.0\\.[0-9\\.]+)\\.tgz" :
|
||||
$ver >= 7.0 ? "dolibarr\\-(7\\.0\\.[0-9\\.]+)\\.tgz" :
|
||||
$ver >= 6.0 ? "dolibarr\\-(6\\.0\\.[0-9\\.]+)\\.tgz" :
|
||||
$ver >= 5.0 ? "dolibarr\\-(5\\.0\\.[0-9\\.]+)\\.tgz" :
|
||||
$ver >= 4.0 ? "dolibarr\\-(4\\.0\\.[0-9\\.]+)\\.tgz" :
|
||||
$ver >= 3.9 ? "dolibarr\\-(3\\.9\\.[0-9\\.]+)\\.tgz" :
|
||||
$ver >= 3.8 ? "dolibarr\\-(3\\.8\\.[0-9\\.]+)\\.tgz" :
|
||||
$ver >= 3.7 ? "dolibarr\\-(3\\.7\\.[0-9\\.]+)\\.tgz" :
|
||||
$ver >= 3.6 ? "dolibarr\\-(3\\.6\\.[0-9\\.]+)\\.tgz" :
|
||||
$ver >= 3.5 ? "dolibarr\\-(3\\.5\\.[0-9\\.]+)\\.tgz" :
|
||||
$ver >= 2.9 ? "dolibarr\\-(2\\.9\\.[0-9\\.]+)\\.tgz" :
|
||||
"dolibarr\\-(2\\.8\\.[0-9\\.]+)\\.tgz");
|
||||
return "Failed to find versions" if (!@vers);
|
||||
return $ver eq $vers[0] ? undef : $vers[0];
|
||||
|
||||
@@ -160,6 +160,7 @@ done >>%{name}.lang
|
||||
%_datadir/dolibarr/htdocs/adherents
|
||||
%_datadir/dolibarr/htdocs/admin
|
||||
%_datadir/dolibarr/htdocs/api
|
||||
%_datadir/dolibarr/htdocs/asset
|
||||
%_datadir/dolibarr/htdocs/asterisk
|
||||
%_datadir/dolibarr/htdocs/barcode
|
||||
%_datadir/dolibarr/htdocs/blockedlog
|
||||
@@ -176,8 +177,11 @@ done >>%{name}.lang
|
||||
%_datadir/dolibarr/htdocs/core
|
||||
%_datadir/dolibarr/htdocs/cron
|
||||
%_datadir/dolibarr/htdocs/custom
|
||||
%_datadir/dolibarr/htdocs/datapolicy
|
||||
%_datadir/dolibarr/htdocs/dav
|
||||
%_datadir/dolibarr/htdocs/don
|
||||
%_datadir/dolibarr/htdocs/ecm
|
||||
%_datadir/dolibarr/htdocs/emailcollector
|
||||
%_datadir/dolibarr/htdocs/expedition
|
||||
%_datadir/dolibarr/htdocs/expensereport
|
||||
%_datadir/dolibarr/htdocs/exports
|
||||
@@ -187,6 +191,7 @@ done >>%{name}.lang
|
||||
%_datadir/dolibarr/htdocs/ftp
|
||||
%_datadir/dolibarr/htdocs/holiday
|
||||
%_datadir/dolibarr/htdocs/hrm
|
||||
%_datadir/dolibarr/htdocs/ifttt
|
||||
%_datadir/dolibarr/htdocs/imports
|
||||
%_datadir/dolibarr/htdocs/includes
|
||||
%_datadir/dolibarr/htdocs/install
|
||||
@@ -210,6 +215,8 @@ done >>%{name}.lang
|
||||
%_datadir/dolibarr/htdocs/supplier_proposal
|
||||
%_datadir/dolibarr/htdocs/support
|
||||
%_datadir/dolibarr/htdocs/theme
|
||||
%_datadir/dolibarr/htdocs/takepos
|
||||
%_datadir/dolibarr/htdocs/ticket
|
||||
%_datadir/dolibarr/htdocs/user
|
||||
%_datadir/dolibarr/htdocs/variants
|
||||
%_datadir/dolibarr/htdocs/webservices
|
||||
|
||||
@@ -54,7 +54,7 @@ BuildRequires: desktop-file-utils
|
||||
Group: Applications/Productivity
|
||||
Requires: apache-base, apache-mod_php, php-cgi, php-cli, php-bz2, php-gd, php-ldap, php-imap, php-mysqli, php-openssl, fonts-ttf-dejavu
|
||||
Requires: mysql, mysql-client
|
||||
%else
|
||||
%else%_datadir/dolibarr/htdocs/datapolicy
|
||||
%if 0%{?suse_version}
|
||||
# Voir http://en.opensuse.org/openSUSE:Packaging_Conventions_RPM_Macros
|
||||
Group: Productivity/Office/Management
|
||||
@@ -124,7 +124,7 @@ cui hai bisogno ed essere facile da usare.
|
||||
|
||||
%if 0%{?sles_version}
|
||||
%{__rm} -rf $RPM_BUILD_ROOT
|
||||
%{__mkdir} $RPM_BUILD_ROOT
|
||||
%{__mkdir} $RPM_BUILD_ROOT%_datadir/dolibarr/htdocs/datapolicy
|
||||
%{__mkdir} $RPM_BUILD_ROOT%{_sysconfdir}
|
||||
%{__mkdir} $RPM_BUILD_ROOT%{_sysconfdir}/%{name}
|
||||
%else
|
||||
@@ -240,6 +240,7 @@ done >>%{name}.lang
|
||||
%_datadir/dolibarr/htdocs/adherents
|
||||
%_datadir/dolibarr/htdocs/admin
|
||||
%_datadir/dolibarr/htdocs/api
|
||||
%_datadir/dolibarr/htdocs/asset
|
||||
%_datadir/dolibarr/htdocs/asterisk
|
||||
%_datadir/dolibarr/htdocs/barcode
|
||||
%_datadir/dolibarr/htdocs/blockedlog
|
||||
@@ -256,8 +257,11 @@ done >>%{name}.lang
|
||||
%_datadir/dolibarr/htdocs/core
|
||||
%_datadir/dolibarr/htdocs/cron
|
||||
%_datadir/dolibarr/htdocs/custom
|
||||
%_datadir/dolibarr/htdocs/datapolicy
|
||||
%_datadir/dolibarr/htdocs/dav
|
||||
%_datadir/dolibarr/htdocs/don
|
||||
%_datadir/dolibarr/htdocs/ecm
|
||||
%_datadir/dolibarr/htdocs/emailcollector
|
||||
%_datadir/dolibarr/htdocs/expedition
|
||||
%_datadir/dolibarr/htdocs/expensereport
|
||||
%_datadir/dolibarr/htdocs/exports
|
||||
@@ -267,6 +271,7 @@ done >>%{name}.lang
|
||||
%_datadir/dolibarr/htdocs/ftp
|
||||
%_datadir/dolibarr/htdocs/holiday
|
||||
%_datadir/dolibarr/htdocs/hrm
|
||||
%_datadir/dolibarr/htdocs/ifttt
|
||||
%_datadir/dolibarr/htdocs/imports
|
||||
%_datadir/dolibarr/htdocs/includes
|
||||
%_datadir/dolibarr/htdocs/install
|
||||
@@ -290,6 +295,8 @@ done >>%{name}.lang
|
||||
%_datadir/dolibarr/htdocs/supplier_proposal
|
||||
%_datadir/dolibarr/htdocs/support
|
||||
%_datadir/dolibarr/htdocs/theme
|
||||
%_datadir/dolibarr/htdocs/takepos
|
||||
%_datadir/dolibarr/htdocs/ticket
|
||||
%_datadir/dolibarr/htdocs/user
|
||||
%_datadir/dolibarr/htdocs/variants
|
||||
%_datadir/dolibarr/htdocs/webservices
|
||||
|
||||
@@ -157,6 +157,7 @@ done >>%{name}.lang
|
||||
%_datadir/dolibarr/htdocs/adherents
|
||||
%_datadir/dolibarr/htdocs/admin
|
||||
%_datadir/dolibarr/htdocs/api
|
||||
%_datadir/dolibarr/htdocs/asset
|
||||
%_datadir/dolibarr/htdocs/asterisk
|
||||
%_datadir/dolibarr/htdocs/barcode
|
||||
%_datadir/dolibarr/htdocs/blockedlog
|
||||
@@ -173,8 +174,11 @@ done >>%{name}.lang
|
||||
%_datadir/dolibarr/htdocs/core
|
||||
%_datadir/dolibarr/htdocs/cron
|
||||
%_datadir/dolibarr/htdocs/custom
|
||||
%_datadir/dolibarr/htdocs/datapolicy
|
||||
%_datadir/dolibarr/htdocs/dav
|
||||
%_datadir/dolibarr/htdocs/don
|
||||
%_datadir/dolibarr/htdocs/ecm
|
||||
%_datadir/dolibarr/htdocs/emailcollector
|
||||
%_datadir/dolibarr/htdocs/expedition
|
||||
%_datadir/dolibarr/htdocs/expensereport
|
||||
%_datadir/dolibarr/htdocs/exports
|
||||
@@ -184,6 +188,7 @@ done >>%{name}.lang
|
||||
%_datadir/dolibarr/htdocs/ftp
|
||||
%_datadir/dolibarr/htdocs/holiday
|
||||
%_datadir/dolibarr/htdocs/hrm
|
||||
%_datadir/dolibarr/htdocs/ifttt
|
||||
%_datadir/dolibarr/htdocs/imports
|
||||
%_datadir/dolibarr/htdocs/includes
|
||||
%_datadir/dolibarr/htdocs/install
|
||||
@@ -207,6 +212,8 @@ done >>%{name}.lang
|
||||
%_datadir/dolibarr/htdocs/supplier_proposal
|
||||
%_datadir/dolibarr/htdocs/support
|
||||
%_datadir/dolibarr/htdocs/theme
|
||||
%_datadir/dolibarr/htdocs/takepos
|
||||
%_datadir/dolibarr/htdocs/ticket
|
||||
%_datadir/dolibarr/htdocs/user
|
||||
%_datadir/dolibarr/htdocs/variants
|
||||
%_datadir/dolibarr/htdocs/webservices
|
||||
|
||||
@@ -168,6 +168,7 @@ done >>%{name}.lang
|
||||
%_datadir/dolibarr/htdocs/adherents
|
||||
%_datadir/dolibarr/htdocs/admin
|
||||
%_datadir/dolibarr/htdocs/api
|
||||
%_datadir/dolibarr/htdocs/asset
|
||||
%_datadir/dolibarr/htdocs/asterisk
|
||||
%_datadir/dolibarr/htdocs/barcode
|
||||
%_datadir/dolibarr/htdocs/blockedlog
|
||||
@@ -184,8 +185,11 @@ done >>%{name}.lang
|
||||
%_datadir/dolibarr/htdocs/core
|
||||
%_datadir/dolibarr/htdocs/cron
|
||||
%_datadir/dolibarr/htdocs/custom
|
||||
%_datadir/dolibarr/htdocs/datapolicy
|
||||
%_datadir/dolibarr/htdocs/dav
|
||||
%_datadir/dolibarr/htdocs/don
|
||||
%_datadir/dolibarr/htdocs/ecm
|
||||
%_datadir/dolibarr/htdocs/emailcollector
|
||||
%_datadir/dolibarr/htdocs/expedition
|
||||
%_datadir/dolibarr/htdocs/expensereport
|
||||
%_datadir/dolibarr/htdocs/exports
|
||||
@@ -195,6 +199,7 @@ done >>%{name}.lang
|
||||
%_datadir/dolibarr/htdocs/ftp
|
||||
%_datadir/dolibarr/htdocs/holiday
|
||||
%_datadir/dolibarr/htdocs/hrm
|
||||
%_datadir/dolibarr/htdocs/ifttt
|
||||
%_datadir/dolibarr/htdocs/imports
|
||||
%_datadir/dolibarr/htdocs/includes
|
||||
%_datadir/dolibarr/htdocs/install
|
||||
@@ -218,6 +223,8 @@ done >>%{name}.lang
|
||||
%_datadir/dolibarr/htdocs/supplier_proposal
|
||||
%_datadir/dolibarr/htdocs/support
|
||||
%_datadir/dolibarr/htdocs/theme
|
||||
%_datadir/dolibarr/htdocs/takepos
|
||||
%_datadir/dolibarr/htdocs/ticket
|
||||
%_datadir/dolibarr/htdocs/user
|
||||
%_datadir/dolibarr/htdocs/variants
|
||||
%_datadir/dolibarr/htdocs/webservices
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
<VirtualHost *:80>
|
||||
DocumentRoot %TRAVIS_BUILD_DIR%/htdocs
|
||||
ErrorLog /var/log/apache2/travis_error_log
|
||||
|
||||
<Directory "%TRAVIS_BUILD_DIR%/htdocs">
|
||||
<Directory "%TRAVIS_BUILD_DIR%/htdocs/">
|
||||
Options FollowSymLinks MultiViews ExecCGI
|
||||
AllowOverride All
|
||||
Order deny,allow
|
||||
Allow from all
|
||||
Require all granted
|
||||
</Directory>
|
||||
|
||||
# Wire up Apache to use Travis CI's php-fpm.
|
||||
@@ -14,5 +14,9 @@
|
||||
Action php5-fcgi /php5-fcgi
|
||||
Alias /php5-fcgi /usr/lib/cgi-bin/php5-fcgi
|
||||
FastCgiExternalServer /usr/lib/cgi-bin/php5-fcgi -host 127.0.0.1:9000 -pass-header Authorization
|
||||
|
||||
<Directory /usr/lib/cgi-bin>
|
||||
Require all granted
|
||||
</Directory>
|
||||
</IfModule>
|
||||
</VirtualHost>
|
||||
|
||||
118
composer.json
118
composer.json
@@ -1,60 +1,62 @@
|
||||
{
|
||||
"name": "dolibarr/dolibarr",
|
||||
"type": "project",
|
||||
"description": "Dolibarr ERP & CRM is a modern and easy to use web software to manage your business",
|
||||
"keywords": [
|
||||
"erp",
|
||||
"crm",
|
||||
"invoice",
|
||||
"sme",
|
||||
"proposal",
|
||||
"order",
|
||||
"stock",
|
||||
"agenda"
|
||||
],
|
||||
"homepage": "https://www.dolibarr.org",
|
||||
"license": "GPL-3.0-or-later",
|
||||
"support": {
|
||||
"issues": "https://github.com/Dolibarr/dolibarr/issues",
|
||||
"forum": "https://www.dolibarr.org/forum",
|
||||
"wiki": "https://wiki.dolibarr.org",
|
||||
"source": "https://github.com/Dolibarr/dolibarr"
|
||||
},
|
||||
"config": {
|
||||
"vendor-dir": "htdocs/includes"
|
||||
},
|
||||
"require": {
|
||||
"php": ">=5.3.0",
|
||||
"ext-curl": "*",
|
||||
"ccampbell/chromephp": "4.1.0",
|
||||
"ckeditor/ckeditor": "4.5.9",
|
||||
"mike42/escpos-php": "1.2.1",
|
||||
"mobiledetect/mobiledetectlib": "2.8.17",
|
||||
"phpoffice/phpexcel": "1.8.1",
|
||||
"restler/framework": "3.0.0-RC6",
|
||||
"tecnickcom/tcpdf": "6.2.12"
|
||||
},
|
||||
"require-dev": {
|
||||
"jakub-onderka/php-parallel-lint": "^0",
|
||||
"jakub-onderka/php-console-highlighter": "^0",
|
||||
"phpunit/phpunit": "^4",
|
||||
"squizlabs/php_codesniffer": "^2",
|
||||
"phpunit/phpunit-selenium": "^2"
|
||||
},
|
||||
"suggest": {
|
||||
"ext-mysqlnd": "To use with MySQL or MariaDB",
|
||||
"ext-mysqli": "To use with MySQL or MariaDB",
|
||||
"ext-pgsql": "To use with PostgreSQL",
|
||||
"ext-mssql": "To use with MSSQL (experimental)",
|
||||
"ext-pdo_sqlite": "To use with SQLite (experimental)",
|
||||
"ext-gd": "Image manipulation (Required but maybe built-in PHP)",
|
||||
"ext-imagick": "Image manipulation (TCPDF)",
|
||||
"ext-mcrypt": "(Required but maybe built-in PHP)",
|
||||
"ext-openssl": "Secure connections (Emails, SOAP…)",
|
||||
"ext-mbstring": "Handle non UTF-8 databases",
|
||||
"ext-soap": "Native SOAP",
|
||||
"ext-zip": "ODT and Excel support",
|
||||
"ext-xml": "Excel support",
|
||||
"firephp/firephp-core": "Logging to Firebug console support"
|
||||
}
|
||||
"name" : "dolibarr/dolibarr",
|
||||
"type" : "project",
|
||||
"description" : "Dolibarr ERP & CRM is a modern and easy to use web software to manage your business",
|
||||
"keywords" : [
|
||||
"erp",
|
||||
"crm",
|
||||
"invoice",
|
||||
"sme",
|
||||
"proposal",
|
||||
"order",
|
||||
"stock",
|
||||
"agenda"
|
||||
],
|
||||
"homepage" : "https://www.dolibarr.org",
|
||||
"license" : "GPL-3.0-or-later",
|
||||
"support" : {
|
||||
"issues" : "https://github.com/Dolibarr/dolibarr/issues",
|
||||
"forum" : "https://www.dolibarr.org/forum",
|
||||
"wiki" : "https://wiki.dolibarr.org",
|
||||
"source" : "https://github.com/Dolibarr/dolibarr"
|
||||
},
|
||||
"config" : {
|
||||
"vendor-dir" : "htdocs/includes"
|
||||
},
|
||||
"require" : {
|
||||
"php" : ">=5.3.0",
|
||||
"ext-curl" : "*",
|
||||
"ccampbell/chromephp" : "4.1.0",
|
||||
"ckeditor/ckeditor" : "4.6.2",
|
||||
"mike42/escpos-php" : "1.2.1",
|
||||
"mobiledetect/mobiledetectlib" : "2.8.17",
|
||||
"phpoffice/phpexcel" : "1.8.1",
|
||||
"restler/framework" : "3.0.0-RC6",
|
||||
"tecnickcom/tcpdf" : "^6.2",
|
||||
"atgp/factur-x" : "^1.0",
|
||||
"luracast/restler": "^3.0"
|
||||
},
|
||||
"require-dev" : {
|
||||
"jakub-onderka/php-parallel-lint" : "^0",
|
||||
"jakub-onderka/php-console-highlighter" : "^0",
|
||||
"phpunit/phpunit" : "^4",
|
||||
"squizlabs/php_codesniffer" : "^2",
|
||||
"phpunit/phpunit-selenium" : "^2"
|
||||
},
|
||||
"suggest" : {
|
||||
"ext-mysqlnd" : "To use with MySQL or MariaDB",
|
||||
"ext-mysqli" : "To use with MySQL or MariaDB",
|
||||
"ext-pgsql" : "To use with PostgreSQL",
|
||||
"ext-mssql" : "To use with MSSQL (experimental)",
|
||||
"ext-pdo_sqlite" : "To use with SQLite (experimental)",
|
||||
"ext-gd" : "Image manipulation (Required but maybe built-in PHP)",
|
||||
"ext-imagick" : "Image manipulation (TCPDF)",
|
||||
"ext-mcrypt" : "(Required but maybe built-in PHP)",
|
||||
"ext-openssl" : "Secure connections (Emails, SOAP\u2026)",
|
||||
"ext-mbstring" : "Handle non UTF-8 databases",
|
||||
"ext-soap" : "Native SOAP",
|
||||
"ext-zip" : "ODT and Excel support",
|
||||
"ext-xml" : "Excel support",
|
||||
"firephp/firephp-core" : "Logging to Firebug console support"
|
||||
}
|
||||
}
|
||||
|
||||
341
composer.lock
generated
341
composer.lock
generated
@@ -4,9 +4,59 @@
|
||||
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file",
|
||||
"This file is @generated automatically"
|
||||
],
|
||||
"hash": "c586663818e933f26657871d86d01dc6",
|
||||
"content-hash": "09e891bb978d35a48902a5f57760aee9",
|
||||
"content-hash": "949d55d933c4e0725a2086a189595483",
|
||||
"packages": [
|
||||
{
|
||||
"name": "atgp/factur-x",
|
||||
"version": "v1.0.1",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/atgp/factur-x.git",
|
||||
"reference": "22e22c3b5dfbb0f25afbd7c3fe69a0305199414c"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/atgp/factur-x/zipball/22e22c3b5dfbb0f25afbd7c3fe69a0305199414c",
|
||||
"reference": "22e22c3b5dfbb0f25afbd7c3fe69a0305199414c",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"ext-dom": "*",
|
||||
"ext-fileinfo": "*",
|
||||
"ext-libxml": "*",
|
||||
"ext-simplexml": "*",
|
||||
"ext-zlib": "*",
|
||||
"php": ">=5.6",
|
||||
"setasign/fpdi-fpdf": "^2.0",
|
||||
"smalot/pdfparser": "^0.13.2"
|
||||
},
|
||||
"type": "library",
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"Atgp\\FacturX\\": "src/"
|
||||
}
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"license": [
|
||||
"MIT"
|
||||
],
|
||||
"authors": [
|
||||
{
|
||||
"name": "Lucas Gouy-Pailler",
|
||||
"email": "lucas.gouypailler@atgp.net"
|
||||
}
|
||||
],
|
||||
"description": "PHP library to manage your Factur-X / ZUGFeRD 2.0 PDF invoices files",
|
||||
"keywords": [
|
||||
"ZUGFeRD",
|
||||
"factur-x",
|
||||
"invoice",
|
||||
"pdf",
|
||||
"php",
|
||||
"xml"
|
||||
],
|
||||
"time": "2019-01-16T10:09:35+00:00"
|
||||
},
|
||||
{
|
||||
"name": "ccampbell/chromephp",
|
||||
"version": "4.1.0",
|
||||
@@ -48,20 +98,20 @@
|
||||
"log",
|
||||
"logging"
|
||||
],
|
||||
"time": "2013-06-26 03:44:33"
|
||||
"time": "2013-06-26T03:44:33+00:00"
|
||||
},
|
||||
{
|
||||
"name": "ckeditor/ckeditor",
|
||||
"version": "4.5.11",
|
||||
"version": "4.6.2",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/ckeditor/ckeditor-releases.git",
|
||||
"reference": "48155a1e1c7e84736b5a166ad3f33acea2a51255"
|
||||
"reference": "268078ab43195b6004d64bc8764c41f2f829640e"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/ckeditor/ckeditor-releases/zipball/48155a1e1c7e84736b5a166ad3f33acea2a51255",
|
||||
"reference": "48155a1e1c7e84736b5a166ad3f33acea2a51255",
|
||||
"url": "https://api.github.com/repos/ckeditor/ckeditor-releases/zipball/268078ab43195b6004d64bc8764c41f2f829640e",
|
||||
"reference": "268078ab43195b6004d64bc8764c41f2f829640e",
|
||||
"shasum": ""
|
||||
},
|
||||
"type": "library",
|
||||
@@ -89,7 +139,7 @@
|
||||
"text",
|
||||
"wysiwyg"
|
||||
],
|
||||
"time": "2016-09-07 13:32:39"
|
||||
"time": "2017-01-12T17:36:48+00:00"
|
||||
},
|
||||
{
|
||||
"name": "mike42/escpos-php",
|
||||
@@ -153,7 +203,7 @@
|
||||
"print",
|
||||
"receipt"
|
||||
],
|
||||
"time": "2016-04-25 01:14:07"
|
||||
"time": "2016-04-25T01:14:07+00:00"
|
||||
},
|
||||
{
|
||||
"name": "mobiledetect/mobiledetectlib",
|
||||
@@ -207,7 +257,7 @@
|
||||
"mobile detector",
|
||||
"php mobile detect"
|
||||
],
|
||||
"time": "2015-09-17 14:45:21"
|
||||
"time": "2015-09-17T14:45:21+00:00"
|
||||
},
|
||||
{
|
||||
"name": "phpoffice/phpexcel",
|
||||
@@ -264,7 +314,8 @@
|
||||
"xls",
|
||||
"xlsx"
|
||||
],
|
||||
"time": "2015-05-01 07:00:55"
|
||||
"abandoned": "phpoffice/phpspreadsheet",
|
||||
"time": "2015-05-01T07:00:55+00:00"
|
||||
},
|
||||
{
|
||||
"name": "restler/framework",
|
||||
@@ -273,12 +324,12 @@
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/Luracast/Restler-Framework.git",
|
||||
"reference": "3388d76e73a81f871ce5baa906271071b12cd17f"
|
||||
"reference": "6bc0968f8c8aa47c9a62d548b9d7e34f1ed4fc09"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/Luracast/Restler-Framework/zipball/3388d76e73a81f871ce5baa906271071b12cd17f",
|
||||
"reference": "3388d76e73a81f871ce5baa906271071b12cd17f",
|
||||
"url": "https://api.github.com/repos/Luracast/Restler-Framework/zipball/6bc0968f8c8aa47c9a62d548b9d7e34f1ed4fc09",
|
||||
"reference": "6bc0968f8c8aa47c9a62d548b9d7e34f1ed4fc09",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
@@ -325,20 +376,209 @@
|
||||
"rest",
|
||||
"server"
|
||||
],
|
||||
"time": "2016-06-21 12:42:18"
|
||||
"time": "2018-01-06T01:39:27+00:00"
|
||||
},
|
||||
{
|
||||
"name": "tecnickcom/tcpdf",
|
||||
"version": "6.2.12",
|
||||
"name": "setasign/fpdf",
|
||||
"version": "1.8.1",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/tecnickcom/TCPDF.git",
|
||||
"reference": "2f732eaa91b5665274689b1d40b285a7bacdc37f"
|
||||
"url": "https://github.com/Setasign/FPDF.git",
|
||||
"reference": "2c68c9e6c034ac3187d25968790139a73184cdb1"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/tecnickcom/TCPDF/zipball/2f732eaa91b5665274689b1d40b285a7bacdc37f",
|
||||
"reference": "2f732eaa91b5665274689b1d40b285a7bacdc37f",
|
||||
"url": "https://api.github.com/repos/Setasign/FPDF/zipball/2c68c9e6c034ac3187d25968790139a73184cdb1",
|
||||
"reference": "2c68c9e6c034ac3187d25968790139a73184cdb1",
|
||||
"shasum": ""
|
||||
},
|
||||
"type": "library",
|
||||
"autoload": {
|
||||
"classmap": [
|
||||
"fpdf.php"
|
||||
]
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"license": [
|
||||
"no usage restriction"
|
||||
],
|
||||
"authors": [
|
||||
{
|
||||
"name": "Olivier Plathey",
|
||||
"email": "oliver@fpdf.org",
|
||||
"homepage": "http://fpdf.org/"
|
||||
}
|
||||
],
|
||||
"description": "FPDF is a PHP class which allows to generate PDF files with pure PHP. F from FPDF stands for Free: you may use it for any kind of usage and modify it to suit your needs.",
|
||||
"homepage": "http://www.fpdf.org",
|
||||
"keywords": [
|
||||
"fpdf",
|
||||
"pdf"
|
||||
],
|
||||
"time": "2016-01-01T17:47:15+00:00"
|
||||
},
|
||||
{
|
||||
"name": "setasign/fpdi",
|
||||
"version": "v2.2.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/Setasign/FPDI.git",
|
||||
"reference": "3c266002f8044f61b17329f7cd702d44d73f0f7f"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/Setasign/FPDI/zipball/3c266002f8044f61b17329f7cd702d44d73f0f7f",
|
||||
"reference": "3c266002f8044f61b17329f7cd702d44d73f0f7f",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"ext-zlib": "*",
|
||||
"php": "^5.6 || ^7.0"
|
||||
},
|
||||
"require-dev": {
|
||||
"phpunit/phpunit": "~5.7",
|
||||
"setasign/fpdf": "~1.8",
|
||||
"setasign/tfpdf": "1.25",
|
||||
"tecnickcom/tcpdf": "~6.2"
|
||||
},
|
||||
"suggest": {
|
||||
"setasign/fpdf": "FPDI will extend this class but as it is also possible to use TCPDF or tFPDF as an alternative. There's no fixed dependency configured.",
|
||||
"setasign/fpdi-fpdf": "Use this package to automatically evaluate dependencies to FPDF.",
|
||||
"setasign/fpdi-tcpdf": "Use this package to automatically evaluate dependencies to TCPDF.",
|
||||
"setasign/fpdi-tfpdf": "Use this package to automatically evaluate dependencies to tFPDF."
|
||||
},
|
||||
"type": "library",
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"setasign\\Fpdi\\": "src/"
|
||||
}
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"license": [
|
||||
"MIT"
|
||||
],
|
||||
"authors": [
|
||||
{
|
||||
"name": "Jan Slabon",
|
||||
"email": "jan.slabon@setasign.com",
|
||||
"homepage": "https://www.setasign.com"
|
||||
},
|
||||
{
|
||||
"name": "Maximilian Kresse",
|
||||
"email": "maximilian.kresse@setasign.com",
|
||||
"homepage": "https://www.setasign.com"
|
||||
}
|
||||
],
|
||||
"description": "FPDI is a collection of PHP classes facilitating developers to read pages from existing PDF documents and use them as templates in FPDF. Because it is also possible to use FPDI with TCPDF, there are no fixed dependencies defined. Please see suggestions for packages which evaluates the dependencies automatically.",
|
||||
"homepage": "https://www.setasign.com/fpdi",
|
||||
"keywords": [
|
||||
"fpdf",
|
||||
"fpdi",
|
||||
"pdf"
|
||||
],
|
||||
"time": "2019-01-30T14:11:19+00:00"
|
||||
},
|
||||
{
|
||||
"name": "setasign/fpdi-fpdf",
|
||||
"version": "v2.2.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/Setasign/FPDI-FPDF.git",
|
||||
"reference": "e4363ac09e1b766b38ebea1c3cbe82b3480a11e9"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/Setasign/FPDI-FPDF/zipball/e4363ac09e1b766b38ebea1c3cbe82b3480a11e9",
|
||||
"reference": "e4363ac09e1b766b38ebea1c3cbe82b3480a11e9",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"setasign/fpdf": "^1.8",
|
||||
"setasign/fpdi": "^2.2"
|
||||
},
|
||||
"type": "library",
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"license": [
|
||||
"MIT"
|
||||
],
|
||||
"authors": [
|
||||
{
|
||||
"name": "Jan Slabon",
|
||||
"email": "jan.slabon@setasign.com",
|
||||
"homepage": "https://www.setasign.com"
|
||||
}
|
||||
],
|
||||
"description": "Kind of metadata package for dependencies of the latest versions of FPDI and FPDF.",
|
||||
"homepage": "https://www.setasign.com/fpdi",
|
||||
"keywords": [
|
||||
"fpdf",
|
||||
"fpdi",
|
||||
"pdf"
|
||||
],
|
||||
"time": "2019-01-30T14:38:19+00:00"
|
||||
},
|
||||
{
|
||||
"name": "smalot/pdfparser",
|
||||
"version": "v0.13.3",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/smalot/pdfparser.git",
|
||||
"reference": "c3a050fb9b47ec3a0ce1b6f1b6f48ec822ba04d6"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/smalot/pdfparser/zipball/c3a050fb9b47ec3a0ce1b6f1b6f48ec822ba04d6",
|
||||
"reference": "c3a050fb9b47ec3a0ce1b6f1b6f48ec822ba04d6",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"ext-mbstring": "*",
|
||||
"ext-zlib": "*",
|
||||
"php": ">=5.3.0",
|
||||
"tecnickcom/tcpdf": "~6.0"
|
||||
},
|
||||
"require-dev": {
|
||||
"atoum/atoum": "^2.8 | ^3.0"
|
||||
},
|
||||
"type": "library",
|
||||
"autoload": {
|
||||
"psr-0": {
|
||||
"Smalot\\PdfParser\\": "src/"
|
||||
}
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"license": [
|
||||
"LGPL-3.0"
|
||||
],
|
||||
"authors": [
|
||||
{
|
||||
"name": "Sebastien MALOT",
|
||||
"email": "sebastien@malot.fr"
|
||||
}
|
||||
],
|
||||
"description": "Pdf parser library. Can read and extract information from pdf file.",
|
||||
"homepage": "http://www.pdfparser.org",
|
||||
"keywords": [
|
||||
"extract",
|
||||
"parse",
|
||||
"parser",
|
||||
"pdf",
|
||||
"text"
|
||||
],
|
||||
"time": "2019-01-11T08:49:57+00:00"
|
||||
},
|
||||
{
|
||||
"name": "tecnickcom/tcpdf",
|
||||
"version": "6.2.26",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/tecnickcom/TCPDF.git",
|
||||
"reference": "367241059ca166e3a76490f4448c284e0a161f15"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/tecnickcom/TCPDF/zipball/367241059ca166e3a76490f4448c284e0a161f15",
|
||||
"reference": "367241059ca166e3a76490f4448c284e0a161f15",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
@@ -347,7 +587,6 @@
|
||||
"type": "library",
|
||||
"autoload": {
|
||||
"classmap": [
|
||||
"fonts",
|
||||
"config",
|
||||
"include",
|
||||
"tcpdf.php",
|
||||
@@ -368,13 +607,13 @@
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"license": [
|
||||
"LGPLv3"
|
||||
"LGPL-3.0"
|
||||
],
|
||||
"authors": [
|
||||
{
|
||||
"name": "Nicola Asuni",
|
||||
"email": "info@tecnick.com",
|
||||
"homepage": "http://nicolaasuni.tecnick.com"
|
||||
"role": "lead"
|
||||
}
|
||||
],
|
||||
"description": "TCPDF is a PHP class for generating PDF documents and barcodes.",
|
||||
@@ -388,7 +627,7 @@
|
||||
"pdf417",
|
||||
"qrcode"
|
||||
],
|
||||
"time": "2015-09-12 10:08:34"
|
||||
"time": "2018-10-16T17:24:05+00:00"
|
||||
}
|
||||
],
|
||||
"packages-dev": [
|
||||
@@ -444,7 +683,7 @@
|
||||
"constructor",
|
||||
"instantiate"
|
||||
],
|
||||
"time": "2015-06-14 21:17:01"
|
||||
"time": "2015-06-14T21:17:01+00:00"
|
||||
},
|
||||
{
|
||||
"name": "jakub-onderka/php-console-color",
|
||||
@@ -487,7 +726,7 @@
|
||||
"homepage": "http://www.acci.cz"
|
||||
}
|
||||
],
|
||||
"time": "2014-04-08 15:00:19"
|
||||
"time": "2014-04-08T15:00:19+00:00"
|
||||
},
|
||||
{
|
||||
"name": "jakub-onderka/php-console-highlighter",
|
||||
@@ -531,7 +770,7 @@
|
||||
"homepage": "http://www.acci.cz/"
|
||||
}
|
||||
],
|
||||
"time": "2015-04-20 18:58:01"
|
||||
"time": "2015-04-20T18:58:01+00:00"
|
||||
},
|
||||
{
|
||||
"name": "jakub-onderka/php-parallel-lint",
|
||||
@@ -578,7 +817,7 @@
|
||||
],
|
||||
"description": "This tool check syntax of PHP files about 20x faster than serial check.",
|
||||
"homepage": "https://github.com/JakubOnderka/PHP-Parallel-Lint",
|
||||
"time": "2015-12-15 10:42:16"
|
||||
"time": "2015-12-15T10:42:16+00:00"
|
||||
},
|
||||
{
|
||||
"name": "phpdocumentor/reflection-common",
|
||||
@@ -632,7 +871,7 @@
|
||||
"reflection",
|
||||
"static analysis"
|
||||
],
|
||||
"time": "2015-12-27 11:43:31"
|
||||
"time": "2015-12-27T11:43:31+00:00"
|
||||
},
|
||||
{
|
||||
"name": "phpdocumentor/reflection-docblock",
|
||||
@@ -677,7 +916,7 @@
|
||||
}
|
||||
],
|
||||
"description": "With this component, a library can provide support for annotations via DocBlocks or otherwise retrieve information that is embedded in a DocBlock.",
|
||||
"time": "2016-09-30 07:12:33"
|
||||
"time": "2016-09-30T07:12:33+00:00"
|
||||
},
|
||||
{
|
||||
"name": "phpdocumentor/type-resolver",
|
||||
@@ -724,7 +963,7 @@
|
||||
"email": "me@mikevanriel.com"
|
||||
}
|
||||
],
|
||||
"time": "2016-06-10 07:14:17"
|
||||
"time": "2016-06-10T07:14:17+00:00"
|
||||
},
|
||||
{
|
||||
"name": "phpspec/prophecy",
|
||||
@@ -786,7 +1025,7 @@
|
||||
"spy",
|
||||
"stub"
|
||||
],
|
||||
"time": "2016-06-07 08:13:47"
|
||||
"time": "2016-06-07T08:13:47+00:00"
|
||||
},
|
||||
{
|
||||
"name": "phpunit/php-code-coverage",
|
||||
@@ -848,7 +1087,7 @@
|
||||
"testing",
|
||||
"xunit"
|
||||
],
|
||||
"time": "2015-10-06 15:47:00"
|
||||
"time": "2015-10-06T15:47:00+00:00"
|
||||
},
|
||||
{
|
||||
"name": "phpunit/php-file-iterator",
|
||||
@@ -895,7 +1134,7 @@
|
||||
"filesystem",
|
||||
"iterator"
|
||||
],
|
||||
"time": "2015-06-21 13:08:43"
|
||||
"time": "2015-06-21T13:08:43+00:00"
|
||||
},
|
||||
{
|
||||
"name": "phpunit/php-text-template",
|
||||
@@ -936,7 +1175,7 @@
|
||||
"keywords": [
|
||||
"template"
|
||||
],
|
||||
"time": "2015-06-21 13:50:34"
|
||||
"time": "2015-06-21T13:50:34+00:00"
|
||||
},
|
||||
{
|
||||
"name": "phpunit/php-timer",
|
||||
@@ -980,7 +1219,7 @@
|
||||
"keywords": [
|
||||
"timer"
|
||||
],
|
||||
"time": "2016-05-12 18:03:57"
|
||||
"time": "2016-05-12T18:03:57+00:00"
|
||||
},
|
||||
{
|
||||
"name": "phpunit/php-token-stream",
|
||||
@@ -1029,7 +1268,7 @@
|
||||
"keywords": [
|
||||
"tokenizer"
|
||||
],
|
||||
"time": "2015-09-15 10:49:45"
|
||||
"time": "2015-09-15T10:49:45+00:00"
|
||||
},
|
||||
{
|
||||
"name": "phpunit/phpunit",
|
||||
@@ -1101,7 +1340,7 @@
|
||||
"testing",
|
||||
"xunit"
|
||||
],
|
||||
"time": "2016-07-21 06:48:14"
|
||||
"time": "2016-07-21T06:48:14+00:00"
|
||||
},
|
||||
{
|
||||
"name": "phpunit/phpunit-mock-objects",
|
||||
@@ -1157,7 +1396,7 @@
|
||||
"mock",
|
||||
"xunit"
|
||||
],
|
||||
"time": "2015-10-02 06:51:40"
|
||||
"time": "2015-10-02T06:51:40+00:00"
|
||||
},
|
||||
{
|
||||
"name": "phpunit/phpunit-selenium",
|
||||
@@ -1221,7 +1460,7 @@
|
||||
"testing",
|
||||
"xunit"
|
||||
],
|
||||
"time": "2016-03-01 10:33:56"
|
||||
"time": "2016-03-01T10:33:56+00:00"
|
||||
},
|
||||
{
|
||||
"name": "sebastian/comparator",
|
||||
@@ -1285,7 +1524,7 @@
|
||||
"compare",
|
||||
"equality"
|
||||
],
|
||||
"time": "2015-07-26 15:48:44"
|
||||
"time": "2015-07-26T15:48:44+00:00"
|
||||
},
|
||||
{
|
||||
"name": "sebastian/diff",
|
||||
@@ -1337,7 +1576,7 @@
|
||||
"keywords": [
|
||||
"diff"
|
||||
],
|
||||
"time": "2015-12-08 07:14:41"
|
||||
"time": "2015-12-08T07:14:41+00:00"
|
||||
},
|
||||
{
|
||||
"name": "sebastian/environment",
|
||||
@@ -1387,7 +1626,7 @@
|
||||
"environment",
|
||||
"hhvm"
|
||||
],
|
||||
"time": "2016-08-18 05:49:44"
|
||||
"time": "2016-08-18T05:49:44+00:00"
|
||||
},
|
||||
{
|
||||
"name": "sebastian/exporter",
|
||||
@@ -1454,7 +1693,7 @@
|
||||
"export",
|
||||
"exporter"
|
||||
],
|
||||
"time": "2016-06-17 09:04:28"
|
||||
"time": "2016-06-17T09:04:28+00:00"
|
||||
},
|
||||
{
|
||||
"name": "sebastian/global-state",
|
||||
@@ -1505,7 +1744,7 @@
|
||||
"keywords": [
|
||||
"global state"
|
||||
],
|
||||
"time": "2015-10-12 03:26:01"
|
||||
"time": "2015-10-12T03:26:01+00:00"
|
||||
},
|
||||
{
|
||||
"name": "sebastian/recursion-context",
|
||||
@@ -1558,7 +1797,7 @@
|
||||
],
|
||||
"description": "Provides functionality to recursively process PHP variables",
|
||||
"homepage": "http://www.github.com/sebastianbergmann/recursion-context",
|
||||
"time": "2015-11-11 19:50:13"
|
||||
"time": "2015-11-11T19:50:13+00:00"
|
||||
},
|
||||
{
|
||||
"name": "sebastian/version",
|
||||
@@ -1593,7 +1832,7 @@
|
||||
],
|
||||
"description": "Library that helps with managing the version number of Git-hosted PHP projects",
|
||||
"homepage": "https://github.com/sebastianbergmann/version",
|
||||
"time": "2015-06-21 13:59:46"
|
||||
"time": "2015-06-21T13:59:46+00:00"
|
||||
},
|
||||
{
|
||||
"name": "squizlabs/php_codesniffer",
|
||||
@@ -1671,7 +1910,7 @@
|
||||
"phpcs",
|
||||
"standards"
|
||||
],
|
||||
"time": "2016-09-01 23:53:02"
|
||||
"time": "2016-09-01T23:53:02+00:00"
|
||||
},
|
||||
{
|
||||
"name": "symfony/yaml",
|
||||
@@ -1720,7 +1959,7 @@
|
||||
],
|
||||
"description": "Symfony Yaml Component",
|
||||
"homepage": "https://symfony.com",
|
||||
"time": "2016-10-24 18:41:13"
|
||||
"time": "2016-10-24T18:41:13+00:00"
|
||||
},
|
||||
{
|
||||
"name": "webmozart/assert",
|
||||
@@ -1770,7 +2009,7 @@
|
||||
"check",
|
||||
"validate"
|
||||
],
|
||||
"time": "2016-08-09 15:02:57"
|
||||
"time": "2016-08-09T15:02:57+00:00"
|
||||
}
|
||||
],
|
||||
"aliases": [],
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
|
||||
This file describe changes made on external library after beeing included
|
||||
This file describes changes made on external libraries after being included
|
||||
in Dolibarr root.
|
||||
|
||||
|
||||
@@ -41,13 +41,6 @@ define('QR_FIND_FROM_RANDOM', false);
|
||||
|
||||
* Removed useless directories ("examples", "tools")
|
||||
|
||||
* Fix
|
||||
// initialize subsetchars
|
||||
$subsetchars = array();
|
||||
into
|
||||
// initialize subsetchars
|
||||
$subsetchars = array_fill(0, 256, true);
|
||||
|
||||
* Optionnaly, removed all fonts except
|
||||
dejavusans* (used by greek, arab, persan, romanian, turkish),
|
||||
freemono* (russian),
|
||||
@@ -55,23 +48,30 @@ into
|
||||
helvetica* (all other languages),
|
||||
zapfdingbats.php (for special chars like form checkboxes)
|
||||
|
||||
* Optionnaly, made freemono the default monotype font because we removed courier
|
||||
* Optionnaly, made freemono the default monotype font if we removed courier
|
||||
In htdocs/includes/tcpdf/tcpdf.php
|
||||
- protected $default_monospaced_font = 'courier';
|
||||
+ protected $default_monospaced_font = 'freemono';
|
||||
|
||||
|
||||
|
||||
|
||||
TCPDI:
|
||||
------
|
||||
Add fpdf_tpl.php 1.2
|
||||
Add tcpdi.php
|
||||
|
||||
Add tcpdi_parser.php and replace:
|
||||
require_once(dirname(__FILE__).'/include/tcpdf_filters.php');
|
||||
with:
|
||||
require_once(dirname(__FILE__).'/../tecnickcom/tcpdf/include/tcpdf_filters.php');
|
||||
|
||||
|
||||
* Fix by replacing
|
||||
} elseif (($key == '/Index') AND ($v[0] == PDF_TYPE_ARRAY AND count($v[1] >= 2))) {
|
||||
with
|
||||
} elseif (($key == '/Index') AND ($v[0] == PDF_TYPE_ARRAY AND count($v[1]) >= 2)) {
|
||||
|
||||
|
||||
|
||||
JSGANTT:
|
||||
@@ -90,6 +90,14 @@ var vTmpNode=this.newNode(vTmpCell, 'div', null, '');
|
||||
vTmpNode=this.newNode(vTmpNode, 'a', null, '', vLangs[vLang]['moreinfo']);
|
||||
vTmpNode.setAttribute('href',vTaskList[i].getLink());
|
||||
|
||||
* Replace '% Comp.' to have a smaller text column header
|
||||
'comp':'% Comp.'
|
||||
with
|
||||
'comp':'%'
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
JCROP:
|
||||
------
|
||||
@@ -101,6 +109,13 @@ JQUERYFILETREE:
|
||||
* Remove directory htdocs/includes/jquery/plugins/jqueryFileTree/connectors
|
||||
|
||||
|
||||
PHPEXCEL:
|
||||
---------
|
||||
* Replace in htdocs/includes/phpoffice/phpexcel/Classes/PHPExcel/Shared/OLE.php
|
||||
continue;
|
||||
with:
|
||||
continue 2;
|
||||
|
||||
|
||||
RESTLER:
|
||||
--------
|
||||
@@ -117,7 +132,7 @@ to get
|
||||
if ($className == 'Luracast\Restler\mixed') return;
|
||||
...
|
||||
|
||||
Change also file Luracast/Restler/explorer/index.html
|
||||
Change also content of file htdocs/includes/restler/framework/Luracast/Restler/explorer/index.html
|
||||
|
||||
+With swagger 2:
|
||||
|
||||
|
||||
@@ -40,7 +40,7 @@ $error=0;
|
||||
|
||||
// -------------------- START OF YOUR CODE HERE --------------------
|
||||
// Include Dolibarr environment
|
||||
require_once($path."../../htdocs/master.inc.php");
|
||||
require_once $path."../../htdocs/master.inc.php";
|
||||
// After this $db, $mysoc, $langs and $conf->entity are defined. Opened handler to database will be closed at end of file.
|
||||
|
||||
//$langs->setDefaultLang('en_US'); // To change default language of $langs
|
||||
@@ -48,8 +48,8 @@ $langs->load("main"); // To load language file for default language
|
||||
@set_time_limit(0);
|
||||
|
||||
// Load user and its permissions
|
||||
$result=$user->fetch('','admin'); // Load user for login 'admin'. Comment line to run as anonymous user.
|
||||
if (! $result > 0) { dol_print_error('',$user->error); exit; }
|
||||
$result=$user->fetch('', 'admin'); // Load user for login 'admin'. Comment line to run as anonymous user.
|
||||
if (! $result > 0) { dol_print_error('', $user->error); exit; }
|
||||
$user->getrights();
|
||||
|
||||
|
||||
@@ -58,7 +58,7 @@ print "***** ".$script_file." (".$version.") *****\n";
|
||||
// Start of transaction
|
||||
$db->begin();
|
||||
|
||||
require_once(DOL_DOCUMENT_ROOT."/compta/facture/class/facture.class.php");
|
||||
require_once DOL_DOCUMENT_ROOT."/compta/facture/class/facture.class.php";
|
||||
|
||||
// Create invoice object
|
||||
$obj = new Facture($db);
|
||||
@@ -89,13 +89,13 @@ if ($idobject > 0)
|
||||
else
|
||||
{
|
||||
$error++;
|
||||
dol_print_error($db,$obj->error);
|
||||
dol_print_error($db, $obj->error);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
$error++;
|
||||
dol_print_error($db,$obj->error);
|
||||
dol_print_error($db, $obj->error);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -40,7 +40,7 @@ $error=0;
|
||||
|
||||
// -------------------- START OF YOUR CODE HERE --------------------
|
||||
// Include Dolibarr environment
|
||||
require_once($path."../../htdocs/master.inc.php");
|
||||
require_once $path."../../htdocs/master.inc.php";
|
||||
// After this $db, $mysoc, $langs and $conf->entity are defined. Opened handler to database will be closed at end of file.
|
||||
|
||||
//$langs->setDefaultLang('en_US'); // To change default language of $langs
|
||||
@@ -48,8 +48,8 @@ $langs->load("main"); // To load language file for default language
|
||||
@set_time_limit(0);
|
||||
|
||||
// Load user and its permissions
|
||||
$result=$user->fetch('','admin'); // Load user for login 'admin'. Comment line to run as anonymous user.
|
||||
if (! $result > 0) { dol_print_error('',$user->error); exit; }
|
||||
$result=$user->fetch('', 'admin'); // Load user for login 'admin'. Comment line to run as anonymous user.
|
||||
if (! $result > 0) { dol_print_error('', $user->error); exit; }
|
||||
$user->getrights();
|
||||
|
||||
|
||||
@@ -59,7 +59,7 @@ print "***** ".$script_file." (".$version.") *****\n";
|
||||
// Start of transaction
|
||||
$db->begin();
|
||||
|
||||
require_once(DOL_DOCUMENT_ROOT."/commande/class/commande.class.php");
|
||||
require_once DOL_DOCUMENT_ROOT."/commande/class/commande.class.php";
|
||||
|
||||
// Create order object
|
||||
$com = new Commande($db);
|
||||
@@ -87,13 +87,13 @@ if ($idobject > 0)
|
||||
else
|
||||
{
|
||||
$error++;
|
||||
dol_print_error($db,$com->error);
|
||||
dol_print_error($db, $com->error);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
$error++;
|
||||
dol_print_error($db,$com->error);
|
||||
dol_print_error($db, $com->error);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -40,7 +40,7 @@ $error=0;
|
||||
|
||||
// -------------------- START OF YOUR CODE HERE --------------------
|
||||
// Include Dolibarr environment
|
||||
require_once($path."../../htdocs/master.inc.php");
|
||||
require_once $path."../../htdocs/master.inc.php";
|
||||
// After this $db, $mysoc, $langs and $conf->entity are defined. Opened handler to database will be closed at end of file.
|
||||
|
||||
//$langs->setDefaultLang('en_US'); // To change default language of $langs
|
||||
@@ -48,8 +48,8 @@ $langs->load("main"); // To load language file for default language
|
||||
@set_time_limit(0);
|
||||
|
||||
// Load user and its permissions
|
||||
$result=$user->fetch('','admin'); // Load user for login 'admin'. Comment line to run as anonymous user.
|
||||
if (! $result > 0) { dol_print_error('',$user->error); exit; }
|
||||
$result=$user->fetch('', 'admin'); // Load user for login 'admin'. Comment line to run as anonymous user.
|
||||
if (! $result > 0) { dol_print_error('', $user->error); exit; }
|
||||
$user->getrights();
|
||||
|
||||
|
||||
@@ -59,7 +59,7 @@ print "***** ".$script_file." (".$version.") *****\n";
|
||||
// Start of transaction
|
||||
$db->begin();
|
||||
|
||||
require_once(DOL_DOCUMENT_ROOT."/product/class/product.class.php");
|
||||
require_once DOL_DOCUMENT_ROOT."/product/class/product.class.php";
|
||||
|
||||
// Create instance of object
|
||||
$myproduct=new Product($db);
|
||||
@@ -86,7 +86,7 @@ if ($idobject > 0)
|
||||
else
|
||||
{
|
||||
$error++;
|
||||
dol_print_error($db,$myproduct->error);
|
||||
dol_print_error($db, $myproduct->error);
|
||||
}
|
||||
|
||||
// -------------------- END OF YOUR CODE --------------------
|
||||
|
||||
@@ -40,7 +40,7 @@ $error=0;
|
||||
|
||||
// -------------------- START OF YOUR CODE HERE --------------------
|
||||
// Include Dolibarr environment
|
||||
require_once($path."../../htdocs/master.inc.php");
|
||||
require_once $path."../../htdocs/master.inc.php";
|
||||
// After this $db, $mysoc, $langs and $conf->entity are defined. Opened handler to database will be closed at end of file.
|
||||
|
||||
//$langs->setDefaultLang('en_US'); // To change default language of $langs
|
||||
@@ -48,8 +48,8 @@ $langs->load("main"); // To load language file for default language
|
||||
@set_time_limit(0);
|
||||
|
||||
// Load user and its permissions
|
||||
$result=$user->fetch('','admin'); // Load user for login 'admin'. Comment line to run as anonymous user.
|
||||
if (! $result > 0) { dol_print_error('',$user->error); exit; }
|
||||
$result=$user->fetch('', 'admin'); // Load user for login 'admin'. Comment line to run as anonymous user.
|
||||
if (! $result > 0) { dol_print_error('', $user->error); exit; }
|
||||
$user->getrights();
|
||||
|
||||
|
||||
@@ -58,7 +58,7 @@ print "***** ".$script_file." (".$version.") *****\n";
|
||||
// Start of transaction
|
||||
$db->begin();
|
||||
|
||||
require_once(DOL_DOCUMENT_ROOT."/user/class/user.class.php");
|
||||
require_once DOL_DOCUMENT_ROOT."/user/class/user.class.php";
|
||||
|
||||
// Create user object
|
||||
$obj = new User($db);
|
||||
@@ -77,17 +77,17 @@ if ($idobject > 0)
|
||||
else
|
||||
{
|
||||
$error++;
|
||||
dol_print_error($db,$obj->error);
|
||||
dol_print_error($db, $obj->error);
|
||||
}
|
||||
}
|
||||
else if ($obj->error == 'ErrorLoginAlreadyExists')
|
||||
elseif ($obj->error == 'ErrorLoginAlreadyExists')
|
||||
{
|
||||
print "User with login ".$obj->login." already exists\n";
|
||||
}
|
||||
else
|
||||
{
|
||||
$error++;
|
||||
dol_print_error($db,$obj->error);
|
||||
dol_print_error($db, $obj->error);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -40,7 +40,7 @@ $error=0;
|
||||
|
||||
// -------------------- START OF YOUR CODE HERE --------------------
|
||||
// Include Dolibarr environment
|
||||
require_once($path."../../htdocs/master.inc.php");
|
||||
require_once $path."../../htdocs/master.inc.php";
|
||||
// After this $db, $mysoc, $langs and $conf->entity are defined. Opened handler to database will be closed at end of file.
|
||||
|
||||
//$langs->setDefaultLang('en_US'); // To change default language of $langs
|
||||
@@ -48,8 +48,8 @@ $langs->load("main"); // To load language file for default language
|
||||
@set_time_limit(0);
|
||||
|
||||
// Load user and its permissions
|
||||
$result=$user->fetch('','admin'); // Load user for login 'admin'. Comment line to run as anonymous user.
|
||||
if (! $result > 0) { dol_print_error('',$user->error); exit; }
|
||||
$result=$user->fetch('', 'admin'); // Load user for login 'admin'. Comment line to run as anonymous user.
|
||||
if (! $result > 0) { dol_print_error('', $user->error); exit; }
|
||||
$user->getrights();
|
||||
|
||||
|
||||
@@ -65,7 +65,7 @@ print 'Argument id_thirdparty='.$argv[1]."\n";
|
||||
// Start of transaction
|
||||
$db->begin();
|
||||
|
||||
require_once(DOL_DOCUMENT_ROOT."/contrat/class/contrat.class.php");
|
||||
require_once DOL_DOCUMENT_ROOT."/contrat/class/contrat.class.php";
|
||||
|
||||
// Create contract object
|
||||
$obj = new Contrat($db);
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
Example fo recurring event, 1 week, no end, exported by Google
|
||||
|
||||
# The recurring event were recorded every monday the 20150518. This is the Recurrence-id, but then
|
||||
# first occurence was moved on tuesday. So this record were added.
|
||||
# first occurrence was moved on tuesday. So this record were added.
|
||||
BEGIN:VEVENT
|
||||
DTSTART;TZID=Europe/Paris:20150519T100000
|
||||
DTEND;TZID=Europe/Paris:20150519T110000
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
README (English)
|
||||
--------------------------------
|
||||
|
||||
This directory contains example of well formated mail messages.
|
||||
This directory contains example of well formatted mail messages.
|
||||
This is to help to build the CMailFile.class.php code.
|
||||
|
||||
@@ -4,4 +4,4 @@ X-Mailer: Dolibarr version 2.7.0-beta (using php mail)
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/html; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
<html><head><title></title></head><body>Testé<br />fdsfsdf<br />fsdf<strong>sfd</strong>s<br />fssdfsd<br /></body></html>
|
||||
<html><head><title></title></head><body>Testé<br>fdsfsdf<br>fsdf<strong>sfd</strong>s<br>fssdfsd<br></body></html>
|
||||
|
||||
@@ -32,9 +32,9 @@ if (substr($sapi_type, 0, 3) == 'cgi') {
|
||||
|
||||
// Recupere root dolibarr
|
||||
//$path=preg_replace('/generate-produit.php/i','',$_SERVER["PHP_SELF"]);
|
||||
require (__DIR__. '/../../htdocs/master.inc.php');
|
||||
require_once(DOL_DOCUMENT_ROOT."/compta/facture/class/facture.class.php");
|
||||
require_once(DOL_DOCUMENT_ROOT."/societe/class/societe.class.php");
|
||||
require __DIR__. '/../../htdocs/master.inc.php';
|
||||
require_once DOL_DOCUMENT_ROOT."/compta/facture/class/facture.class.php";
|
||||
require_once DOL_DOCUMENT_ROOT."/societe/class/societe.class.php";
|
||||
|
||||
|
||||
/*
|
||||
@@ -43,59 +43,59 @@ require_once(DOL_DOCUMENT_ROOT."/societe/class/societe.class.php");
|
||||
|
||||
define(GEN_NUMBER_FACTURE, 1);
|
||||
$year = 2016;
|
||||
$dates = array (mktime(12,0,0,1,3,$year),
|
||||
mktime(12,0,0,1,9,$year),
|
||||
mktime(12,0,0,2,13,$year),
|
||||
mktime(12,0,0,2,23,$year),
|
||||
mktime(12,0,0,3,30,$year),
|
||||
mktime(12,0,0,4,3,$year),
|
||||
mktime(12,0,0,4,3,$year),
|
||||
mktime(12,0,0,5,9,$year),
|
||||
mktime(12,0,0,5,1,$year),
|
||||
mktime(12,0,0,5,13,$year),
|
||||
mktime(12,0,0,5,19,$year),
|
||||
mktime(12,0,0,5,23,$year),
|
||||
mktime(12,0,0,6,3,$year),
|
||||
mktime(12,0,0,6,19,$year),
|
||||
mktime(12,0,0,6,24,$year),
|
||||
mktime(12,0,0,7,3,$year),
|
||||
mktime(12,0,0,7,9,$year),
|
||||
mktime(12,0,0,7,23,$year),
|
||||
mktime(12,0,0,7,30,$year),
|
||||
mktime(12,0,0,8,9,$year),
|
||||
mktime(12,0,0,9,23,$year),
|
||||
mktime(12,0,0,10,3,$year),
|
||||
mktime(12,0,0,11,12,$year),
|
||||
mktime(12,0,0,11,13,$year),
|
||||
mktime(12,0,0,1,3,($year - 1)),
|
||||
mktime(12,0,0,1,9,($year - 1)),
|
||||
mktime(12,0,0,2,13,($year - 1)),
|
||||
mktime(12,0,0,2,23,($year - 1)),
|
||||
mktime(12,0,0,3,30,($year - 1)),
|
||||
mktime(12,0,0,4,3,($year - 1)),
|
||||
mktime(12,0,0,4,3,($year - 1)),
|
||||
mktime(12,0,0,5,9,($year - 1)),
|
||||
mktime(12,0,0,5,1,($year - 1)),
|
||||
mktime(12,0,0,5,13,($year - 1)),
|
||||
mktime(12,0,0,5,19,($year - 1)),
|
||||
mktime(12,0,0,5,23,($year - 1)),
|
||||
mktime(12,0,0,6,3,($year - 1)),
|
||||
mktime(12,0,0,6,19,($year - 1)),
|
||||
mktime(12,0,0,6,24,($year - 1)),
|
||||
mktime(12,0,0,7,3,($year - 1)),
|
||||
mktime(12,0,0,7,9,($year - 1)),
|
||||
mktime(12,0,0,7,23,($year - 1)),
|
||||
mktime(12,0,0,7,30,($year - 1)),
|
||||
mktime(12,0,0,8,9,($year - 1)),
|
||||
mktime(12,0,0,9,23,($year - 1)),
|
||||
mktime(12,0,0,10,3,($year - 1)),
|
||||
mktime(12,0,0,11,12,$year),
|
||||
mktime(12,0,0,11,13,$year),
|
||||
mktime(12,0,0,12,12,$year),
|
||||
mktime(12,0,0,12,13,$year),
|
||||
$dates = array (mktime(12, 0, 0, 1, 3, $year),
|
||||
mktime(12, 0, 0, 1, 9, $year),
|
||||
mktime(12, 0, 0, 2, 13, $year),
|
||||
mktime(12, 0, 0, 2, 23, $year),
|
||||
mktime(12, 0, 0, 3, 30, $year),
|
||||
mktime(12, 0, 0, 4, 3, $year),
|
||||
mktime(12, 0, 0, 4, 3, $year),
|
||||
mktime(12, 0, 0, 5, 9, $year),
|
||||
mktime(12, 0, 0, 5, 1, $year),
|
||||
mktime(12, 0, 0, 5, 13, $year),
|
||||
mktime(12, 0, 0, 5, 19, $year),
|
||||
mktime(12, 0, 0, 5, 23, $year),
|
||||
mktime(12, 0, 0, 6, 3, $year),
|
||||
mktime(12, 0, 0, 6, 19, $year),
|
||||
mktime(12, 0, 0, 6, 24, $year),
|
||||
mktime(12, 0, 0, 7, 3, $year),
|
||||
mktime(12, 0, 0, 7, 9, $year),
|
||||
mktime(12, 0, 0, 7, 23, $year),
|
||||
mktime(12, 0, 0, 7, 30, $year),
|
||||
mktime(12, 0, 0, 8, 9, $year),
|
||||
mktime(12, 0, 0, 9, 23, $year),
|
||||
mktime(12, 0, 0, 10, 3, $year),
|
||||
mktime(12, 0, 0, 11, 12, $year),
|
||||
mktime(12, 0, 0, 11, 13, $year),
|
||||
mktime(12, 0, 0, 1, 3, ($year - 1)),
|
||||
mktime(12, 0, 0, 1, 9, ($year - 1)),
|
||||
mktime(12, 0, 0, 2, 13, ($year - 1)),
|
||||
mktime(12, 0, 0, 2, 23, ($year - 1)),
|
||||
mktime(12, 0, 0, 3, 30, ($year - 1)),
|
||||
mktime(12, 0, 0, 4, 3, ($year - 1)),
|
||||
mktime(12, 0, 0, 4, 3, ($year - 1)),
|
||||
mktime(12, 0, 0, 5, 9, ($year - 1)),
|
||||
mktime(12, 0, 0, 5, 1, ($year - 1)),
|
||||
mktime(12, 0, 0, 5, 13, ($year - 1)),
|
||||
mktime(12, 0, 0, 5, 19, ($year - 1)),
|
||||
mktime(12, 0, 0, 5, 23, ($year - 1)),
|
||||
mktime(12, 0, 0, 6, 3, ($year - 1)),
|
||||
mktime(12, 0, 0, 6, 19, ($year - 1)),
|
||||
mktime(12, 0, 0, 6, 24, ($year - 1)),
|
||||
mktime(12, 0, 0, 7, 3, ($year - 1)),
|
||||
mktime(12, 0, 0, 7, 9, ($year - 1)),
|
||||
mktime(12, 0, 0, 7, 23, ($year - 1)),
|
||||
mktime(12, 0, 0, 7, 30, ($year - 1)),
|
||||
mktime(12, 0, 0, 8, 9, ($year - 1)),
|
||||
mktime(12, 0, 0, 9, 23, ($year - 1)),
|
||||
mktime(12, 0, 0, 10, 3, ($year - 1)),
|
||||
mktime(12, 0, 0, 11, 12, $year),
|
||||
mktime(12, 0, 0, 11, 13, $year),
|
||||
mktime(12, 0, 0, 12, 12, $year),
|
||||
mktime(12, 0, 0, 12, 13, $year),
|
||||
);
|
||||
|
||||
$ret=$user->fetch('','admin');
|
||||
$ret=$user->fetch('', 'admin');
|
||||
if (! $ret > 0)
|
||||
{
|
||||
print 'A user with login "admin" and all permissions must be created to use this script.'."\n";
|
||||
@@ -150,7 +150,7 @@ while ($i < GEN_NUMBER_FACTURE && $result >= 0)
|
||||
$object->mode_reglement_id = 3;
|
||||
|
||||
$fuser = new User($db);
|
||||
$fuser->fetch(mt_rand(1,2));
|
||||
$fuser->fetch(mt_rand(1, 2));
|
||||
$fuser->getRights();
|
||||
|
||||
$result=$object->create($fuser);
|
||||
@@ -163,10 +163,10 @@ while ($i < GEN_NUMBER_FACTURE && $result >= 0)
|
||||
$prodid = mt_rand(1, $num_prods);
|
||||
$product=new Product($db);
|
||||
$result=$product->fetch($prodids[$prodid]);
|
||||
$result=$object->addline($product->description, $product->price, mt_rand(1,5), 0, 0, 0, $prodids[$prodid], 0, '', '', 0, 0, '', $product->price_base_type, $product->price_ttc, $product->type);
|
||||
$result=$object->addline($product->description, $product->price, mt_rand(1, 5), 0, 0, 0, $prodids[$prodid], 0, '', '', 0, 0, '', $product->price_base_type, $product->price_ttc, $product->type);
|
||||
if ($result < 0)
|
||||
{
|
||||
dol_print_error($db,$propal->error);
|
||||
dol_print_error($db, $propal->error);
|
||||
}
|
||||
$xnbp++;
|
||||
}
|
||||
@@ -178,14 +178,11 @@ while ($i < GEN_NUMBER_FACTURE && $result >= 0)
|
||||
}
|
||||
else
|
||||
{
|
||||
dol_print_error($db,$object->error);
|
||||
dol_print_error($db, $object->error);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
dol_print_error($db,$object->error);
|
||||
dol_print_error($db, $object->error);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -20,8 +20,8 @@
|
||||
*/
|
||||
|
||||
/**
|
||||
* \file dev/initdata/generate-order.php
|
||||
* \brief Script example to inject random orders (for load tests)
|
||||
* \file dev/initdata/generate-order.php
|
||||
* \brief Script example to inject random orders (for load tests)
|
||||
*/
|
||||
|
||||
// Test si mode batch
|
||||
@@ -33,14 +33,14 @@ if (substr($sapi_type, 0, 3) == 'cgi') {
|
||||
|
||||
// Recupere root dolibarr
|
||||
//$path=preg_replace('/generate-commande.php/i','',$_SERVER["PHP_SELF"]);
|
||||
require (__DIR__. '/../../htdocs/master.inc.php');
|
||||
require __DIR__. '/../../htdocs/master.inc.php';
|
||||
include_once DOL_DOCUMENT_ROOT.'/societe/class/societe.class.php';
|
||||
include_once DOL_DOCUMENT_ROOT.'/contact/class/contact.class.php';
|
||||
include_once DOL_DOCUMENT_ROOT.'/compta/facture/class/facture.class.php';
|
||||
include_once DOL_DOCUMENT_ROOT.'/product/class/product.class.php';
|
||||
include_once DOL_DOCUMENT_ROOT.'/compta/paiement/class/paiement.class.php';
|
||||
include_once DOL_DOCUMENT_ROOT.'/contrat/class/contrat.class.php';
|
||||
require_once(DOL_DOCUMENT_ROOT."/commande/class/commande.class.php");
|
||||
require_once DOL_DOCUMENT_ROOT."/commande/class/commande.class.php";
|
||||
|
||||
|
||||
/*
|
||||
@@ -49,59 +49,59 @@ require_once(DOL_DOCUMENT_ROOT."/commande/class/commande.class.php");
|
||||
|
||||
define(GEN_NUMBER_COMMANDE, 10);
|
||||
$year = 2016;
|
||||
$dates = array (mktime(12,0,0,1,3,$year),
|
||||
mktime(12,0,0,1,9,$year),
|
||||
mktime(12,0,0,2,13,$year),
|
||||
mktime(12,0,0,2,23,$year),
|
||||
mktime(12,0,0,3,30,$year),
|
||||
mktime(12,0,0,4,3,$year),
|
||||
mktime(12,0,0,4,3,$year),
|
||||
mktime(12,0,0,5,9,$year),
|
||||
mktime(12,0,0,5,1,$year),
|
||||
mktime(12,0,0,5,13,$year),
|
||||
mktime(12,0,0,5,19,$year),
|
||||
mktime(12,0,0,5,23,$year),
|
||||
mktime(12,0,0,6,3,$year),
|
||||
mktime(12,0,0,6,19,$year),
|
||||
mktime(12,0,0,6,24,$year),
|
||||
mktime(12,0,0,7,3,$year),
|
||||
mktime(12,0,0,7,9,$year),
|
||||
mktime(12,0,0,7,23,$year),
|
||||
mktime(12,0,0,7,30,$year),
|
||||
mktime(12,0,0,8,9,$year),
|
||||
mktime(12,0,0,9,23,$year),
|
||||
mktime(12,0,0,10,3,$year),
|
||||
mktime(12,0,0,11,12,$year),
|
||||
mktime(12,0,0,11,13,$year),
|
||||
mktime(12,0,0,1,3,($year - 1)),
|
||||
mktime(12,0,0,1,9,($year - 1)),
|
||||
mktime(12,0,0,2,13,($year - 1)),
|
||||
mktime(12,0,0,2,23,($year - 1)),
|
||||
mktime(12,0,0,3,30,($year - 1)),
|
||||
mktime(12,0,0,4,3,($year - 1)),
|
||||
mktime(12,0,0,4,3,($year - 1)),
|
||||
mktime(12,0,0,5,9,($year - 1)),
|
||||
mktime(12,0,0,5,1,($year - 1)),
|
||||
mktime(12,0,0,5,13,($year - 1)),
|
||||
mktime(12,0,0,5,19,($year - 1)),
|
||||
mktime(12,0,0,5,23,($year - 1)),
|
||||
mktime(12,0,0,6,3,($year - 1)),
|
||||
mktime(12,0,0,6,19,($year - 1)),
|
||||
mktime(12,0,0,6,24,($year - 1)),
|
||||
mktime(12,0,0,7,3,($year - 1)),
|
||||
mktime(12,0,0,7,9,($year - 1)),
|
||||
mktime(12,0,0,7,23,($year - 1)),
|
||||
mktime(12,0,0,7,30,($year - 1)),
|
||||
mktime(12,0,0,8,9,($year - 1)),
|
||||
mktime(12,0,0,9,23,($year - 1)),
|
||||
mktime(12,0,0,10,3,($year - 1)),
|
||||
mktime(12,0,0,11,12,$year),
|
||||
mktime(12,0,0,11,13,$year),
|
||||
mktime(12,0,0,12,12,$year),
|
||||
mktime(12,0,0,12,13,$year),
|
||||
$dates = array (mktime(12, 0, 0, 1, 3, $year),
|
||||
mktime(12, 0, 0, 1, 9, $year),
|
||||
mktime(12, 0, 0, 2, 13, $year),
|
||||
mktime(12, 0, 0, 2, 23, $year),
|
||||
mktime(12, 0, 0, 3, 30, $year),
|
||||
mktime(12, 0, 0, 4, 3, $year),
|
||||
mktime(12, 0, 0, 4, 3, $year),
|
||||
mktime(12, 0, 0, 5, 9, $year),
|
||||
mktime(12, 0, 0, 5, 1, $year),
|
||||
mktime(12, 0, 0, 5, 13, $year),
|
||||
mktime(12, 0, 0, 5, 19, $year),
|
||||
mktime(12, 0, 0, 5, 23, $year),
|
||||
mktime(12, 0, 0, 6, 3, $year),
|
||||
mktime(12, 0, 0, 6, 19, $year),
|
||||
mktime(12, 0, 0, 6, 24, $year),
|
||||
mktime(12, 0, 0, 7, 3, $year),
|
||||
mktime(12, 0, 0, 7, 9, $year),
|
||||
mktime(12, 0, 0, 7, 23, $year),
|
||||
mktime(12, 0, 0, 7, 30, $year),
|
||||
mktime(12, 0, 0, 8, 9, $year),
|
||||
mktime(12, 0, 0, 9, 23, $year),
|
||||
mktime(12, 0, 0, 10, 3, $year),
|
||||
mktime(12, 0, 0, 11, 12, $year),
|
||||
mktime(12, 0, 0, 11, 13, $year),
|
||||
mktime(12, 0, 0, 1, 3, ($year - 1)),
|
||||
mktime(12, 0, 0, 1, 9, ($year - 1)),
|
||||
mktime(12, 0, 0, 2, 13, ($year - 1)),
|
||||
mktime(12, 0, 0, 2, 23, ($year - 1)),
|
||||
mktime(12, 0, 0, 3, 30, ($year - 1)),
|
||||
mktime(12, 0, 0, 4, 3, ($year - 1)),
|
||||
mktime(12, 0, 0, 4, 3, ($year - 1)),
|
||||
mktime(12, 0, 0, 5, 9, ($year - 1)),
|
||||
mktime(12, 0, 0, 5, 1, ($year - 1)),
|
||||
mktime(12, 0, 0, 5, 13, ($year - 1)),
|
||||
mktime(12, 0, 0, 5, 19, ($year - 1)),
|
||||
mktime(12, 0, 0, 5, 23, ($year - 1)),
|
||||
mktime(12, 0, 0, 6, 3, ($year - 1)),
|
||||
mktime(12, 0, 0, 6, 19, ($year - 1)),
|
||||
mktime(12, 0, 0, 6, 24, ($year - 1)),
|
||||
mktime(12, 0, 0, 7, 3, ($year - 1)),
|
||||
mktime(12, 0, 0, 7, 9, ($year - 1)),
|
||||
mktime(12, 0, 0, 7, 23, ($year - 1)),
|
||||
mktime(12, 0, 0, 7, 30, ($year - 1)),
|
||||
mktime(12, 0, 0, 8, 9, ($year - 1)),
|
||||
mktime(12, 0, 0, 9, 23, ($year - 1)),
|
||||
mktime(12, 0, 0, 10, 3, ($year - 1)),
|
||||
mktime(12, 0, 0, 11, 12, $year),
|
||||
mktime(12, 0, 0, 11, 13, $year),
|
||||
mktime(12, 0, 0, 12, 12, $year),
|
||||
mktime(12, 0, 0, 12, 13, $year),
|
||||
);
|
||||
|
||||
$ret=$user->fetch('','admin');
|
||||
$ret=$user->fetch('', 'admin');
|
||||
if ($ret <= 0)
|
||||
{
|
||||
print 'A user with login "admin" and all permissions must be created to use this script.'."\n";
|
||||
@@ -113,13 +113,13 @@ $societesid = array();
|
||||
$sql = "SELECT rowid FROM ".MAIN_DB_PREFIX."societe where client in (1, 3)";
|
||||
$resql=$db->query($sql);
|
||||
if ($resql) {
|
||||
$num_thirdparties = $db->num_rows($resql);
|
||||
$i = 0;
|
||||
while ($i < $num_thirdparties) {
|
||||
$i++;
|
||||
$row = $db->fetch_row($resql);
|
||||
$societesid[$i] = $row[0];
|
||||
}
|
||||
$num_thirdparties = $db->num_rows($resql);
|
||||
$i = 0;
|
||||
while ($i < $num_thirdparties) {
|
||||
$i++;
|
||||
$row = $db->fetch_row($resql);
|
||||
$societesid[$i] = $row[0];
|
||||
}
|
||||
}
|
||||
else { print "err"; }
|
||||
|
||||
@@ -127,35 +127,32 @@ $commandesid = array();
|
||||
$sql = "SELECT rowid FROM ".MAIN_DB_PREFIX."commande";
|
||||
$resql=$db->query($sql);
|
||||
if ($resql) {
|
||||
$num = $db->num_rows($resql);
|
||||
$i = 0;
|
||||
while ($i < $num) {
|
||||
$i++;
|
||||
$row = $db->fetch_row($resql);
|
||||
$commandesid[$i] = $row[0];
|
||||
}
|
||||
$num = $db->num_rows($resql);
|
||||
$i = 0;
|
||||
while ($i < $num) {
|
||||
$i++;
|
||||
$row = $db->fetch_row($resql);
|
||||
$commandesid[$i] = $row[0];
|
||||
}
|
||||
}
|
||||
else { print "err"; }
|
||||
|
||||
$prodids = array();
|
||||
$sql = "SELECT rowid FROM ".MAIN_DB_PREFIX."product WHERE tosell=1";
|
||||
$resql = $db->query($sql);
|
||||
if ($resql)
|
||||
{
|
||||
$num_prods = $db->num_rows($resql);
|
||||
$i = 0;
|
||||
while ($i < $num_prods)
|
||||
{
|
||||
$i++;
|
||||
if ($resql) {
|
||||
$num_prods = $db->num_rows($resql);
|
||||
$i = 0;
|
||||
while ($i < $num_prods) {
|
||||
$i++;
|
||||
|
||||
$row = $db->fetch_row($resql);
|
||||
$prodids[$i] = $row[0];
|
||||
$row = $db->fetch_row($resql);
|
||||
$prodids[$i] = $row[0];
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
print "Build ".GEN_NUMBER_COMMANDE." orders\n";
|
||||
for ($s = 0 ; $s < GEN_NUMBER_COMMANDE ; $s++)
|
||||
{
|
||||
@@ -173,18 +170,18 @@ for ($s = 0 ; $s < GEN_NUMBER_COMMANDE ; $s++)
|
||||
$object->cond_reglement_id = mt_rand(0, 2);
|
||||
$object->more_reglement_id = mt_rand(0, 7);
|
||||
$object->availability_id = mt_rand(0, 1);
|
||||
|
||||
|
||||
$listofuserid=array(12,13,16);
|
||||
|
||||
|
||||
$fuser = new User($db);
|
||||
$fuser->fetch($listofuserid[mt_rand(0,2)]);
|
||||
$fuser->fetch($listofuserid[mt_rand(0, 2)]);
|
||||
$fuser->getRights();
|
||||
|
||||
|
||||
$db->begin();
|
||||
|
||||
$result=$object->create($fuser);
|
||||
if ($result >= 0)
|
||||
{
|
||||
if ($result >= 0)
|
||||
{
|
||||
$nbp = mt_rand(2, 5);
|
||||
$xnbp = 0;
|
||||
while ($xnbp < $nbp)
|
||||
@@ -192,32 +189,31 @@ for ($s = 0 ; $s < GEN_NUMBER_COMMANDE ; $s++)
|
||||
$prodid = mt_rand(1, $num_prods);
|
||||
$product=new Product($db);
|
||||
$result=$product->fetch($prodids[$prodid]);
|
||||
$result=$object->addline($product->description, $product->price, mt_rand(1,5), 0, 0, 0, $prodids[$prodid], 0, 0, 0, $product->price_base_type, $product->price_ttc, '', '', $product->type);
|
||||
$result=$object->addline($product->description, $product->price, mt_rand(1, 5), 0, 0, 0, $prodids[$prodid], 0, 0, 0, $product->price_base_type, $product->price_ttc, '', '', $product->type);
|
||||
if ($result <= 0)
|
||||
{
|
||||
dol_print_error($db,$object->error);
|
||||
dol_print_error($db, $object->error);
|
||||
}
|
||||
$xnbp++;
|
||||
}
|
||||
|
||||
$result=$object->valid($fuser);
|
||||
if ($result > 0)
|
||||
{
|
||||
$result=$object->valid($fuser);
|
||||
if ($result > 0)
|
||||
{
|
||||
$db->commit();
|
||||
print " OK with ref ".$object->ref."\n";
|
||||
}
|
||||
else
|
||||
{
|
||||
}
|
||||
else
|
||||
{
|
||||
print " KO\n";
|
||||
$db->rollback();
|
||||
dol_print_error($db,$object->error);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
$db->rollback();
|
||||
dol_print_error($db, $object->error);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
print " KO\n";
|
||||
$db->rollback();
|
||||
dol_print_error($db,$object->error);
|
||||
}
|
||||
$db->rollback();
|
||||
dol_print_error($db, $object->error);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -33,7 +33,7 @@ if (substr($sapi_type, 0, 3) == 'cgi') {
|
||||
|
||||
// Recupere root dolibarr
|
||||
//$path=preg_replace('/generate-produit.php/i','',$_SERVER["PHP_SELF"]);
|
||||
require (__DIR__. '/../../htdocs/master.inc.php');
|
||||
require __DIR__. '/../../htdocs/master.inc.php';
|
||||
include_once DOL_DOCUMENT_ROOT.'/societe/class/societe.class.php';
|
||||
include_once DOL_DOCUMENT_ROOT.'/contact/class/contact.class.php';
|
||||
include_once DOL_DOCUMENT_ROOT.'/compta/facture/class/facture.class.php';
|
||||
@@ -49,7 +49,7 @@ include_once DOL_DOCUMENT_ROOT.'/contrat/class/contrat.class.php';
|
||||
define(GEN_NUMBER_PRODUIT, 100000);
|
||||
|
||||
|
||||
$ret=$user->fetch('','admin');
|
||||
$ret=$user->fetch('', 'admin');
|
||||
if (! $ret > 0)
|
||||
{
|
||||
print 'A user with login "admin" and all permissions must be created to use this script.'."\n";
|
||||
@@ -85,16 +85,14 @@ for ($s = 0 ; $s < GEN_NUMBER_PRODUIT ; $s++)
|
||||
{
|
||||
print "Product ".$s;
|
||||
$produit = new Product($db);
|
||||
$produit->type = mt_rand(0,1);
|
||||
$produit->type = mt_rand(0, 1);
|
||||
$produit->status = 1;
|
||||
$produit->ref = ($produit->type?'S':'P').time().$s;
|
||||
$produit->label = 'Label '.time().$s;
|
||||
$produit->description = 'Description '.time().$s;
|
||||
$produit->price = mt_rand(1,1000);
|
||||
$produit->price = mt_rand(1, 1000);
|
||||
$produit->tva_tx = "19.6";
|
||||
$ret=$produit->create($user);
|
||||
if ($ret < 0) print "Error $ret - ".$produit->error."\n";
|
||||
else print " OK with ref ".$produit->ref."\n";
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -33,11 +33,11 @@ if (substr($sapi_type, 0, 3) == 'cgi') {
|
||||
|
||||
// Recupere root dolibarr
|
||||
//$path=preg_replace('/generate-propale.php/i','',$_SERVER["PHP_SELF"]);
|
||||
require (__DIR__. '/../../htdocs/master.inc.php');
|
||||
require_once(DOL_DOCUMENT_ROOT."/compta/facture/class/facture.class.php");
|
||||
require_once(DOL_DOCUMENT_ROOT."/comm/propal/class/propal.class.php");
|
||||
require_once(DOL_DOCUMENT_ROOT."/commande/class/commande.class.php");
|
||||
require_once(DOL_DOCUMENT_ROOT."/societe/class/societe.class.php");
|
||||
require __DIR__. '/../../htdocs/master.inc.php';
|
||||
require_once DOL_DOCUMENT_ROOT."/compta/facture/class/facture.class.php";
|
||||
require_once DOL_DOCUMENT_ROOT."/comm/propal/class/propal.class.php";
|
||||
require_once DOL_DOCUMENT_ROOT."/commande/class/commande.class.php";
|
||||
require_once DOL_DOCUMENT_ROOT."/societe/class/societe.class.php";
|
||||
|
||||
/*
|
||||
* Parameters
|
||||
@@ -45,59 +45,59 @@ require_once(DOL_DOCUMENT_ROOT."/societe/class/societe.class.php");
|
||||
|
||||
define(GEN_NUMBER_PROPAL, 10);
|
||||
$year = 2016;
|
||||
$dates = array (mktime(12,0,0,1,3,$year),
|
||||
mktime(12,0,0,1,9,$year),
|
||||
mktime(12,0,0,2,13,$year),
|
||||
mktime(12,0,0,2,23,$year),
|
||||
mktime(12,0,0,3,30,$year),
|
||||
mktime(12,0,0,4,3,$year),
|
||||
mktime(12,0,0,4,3,$year),
|
||||
mktime(12,0,0,5,9,$year),
|
||||
mktime(12,0,0,5,1,$year),
|
||||
mktime(12,0,0,5,13,$year),
|
||||
mktime(12,0,0,5,19,$year),
|
||||
mktime(12,0,0,5,23,$year),
|
||||
mktime(12,0,0,6,3,$year),
|
||||
mktime(12,0,0,6,19,$year),
|
||||
mktime(12,0,0,6,24,$year),
|
||||
mktime(12,0,0,7,3,$year),
|
||||
mktime(12,0,0,7,9,$year),
|
||||
mktime(12,0,0,7,23,$year),
|
||||
mktime(12,0,0,7,30,$year),
|
||||
mktime(12,0,0,8,9,$year),
|
||||
mktime(12,0,0,9,23,$year),
|
||||
mktime(12,0,0,10,3,$year),
|
||||
mktime(12,0,0,11,12,$year),
|
||||
mktime(12,0,0,11,13,$year),
|
||||
mktime(12,0,0,1,3,($year - 1)),
|
||||
mktime(12,0,0,1,9,($year - 1)),
|
||||
mktime(12,0,0,2,13,($year - 1)),
|
||||
mktime(12,0,0,2,23,($year - 1)),
|
||||
mktime(12,0,0,3,30,($year - 1)),
|
||||
mktime(12,0,0,4,3,($year - 1)),
|
||||
mktime(12,0,0,4,3,($year - 1)),
|
||||
mktime(12,0,0,5,9,($year - 1)),
|
||||
mktime(12,0,0,5,1,($year - 1)),
|
||||
mktime(12,0,0,5,13,($year - 1)),
|
||||
mktime(12,0,0,5,19,($year - 1)),
|
||||
mktime(12,0,0,5,23,($year - 1)),
|
||||
mktime(12,0,0,6,3,($year - 1)),
|
||||
mktime(12,0,0,6,19,($year - 1)),
|
||||
mktime(12,0,0,6,24,($year - 1)),
|
||||
mktime(12,0,0,7,3,($year - 1)),
|
||||
mktime(12,0,0,7,9,($year - 1)),
|
||||
mktime(12,0,0,7,23,($year - 1)),
|
||||
mktime(12,0,0,7,30,($year - 1)),
|
||||
mktime(12,0,0,8,9,($year - 1)),
|
||||
mktime(12,0,0,9,23,($year - 1)),
|
||||
mktime(12,0,0,10,3,($year - 1)),
|
||||
mktime(12,0,0,11,12,$year),
|
||||
mktime(12,0,0,11,13,$year),
|
||||
mktime(12,0,0,12,12,$year),
|
||||
mktime(12,0,0,12,13,$year),
|
||||
$dates = array (mktime(12, 0, 0, 1, 3, $year),
|
||||
mktime(12, 0, 0, 1, 9, $year),
|
||||
mktime(12, 0, 0, 2, 13, $year),
|
||||
mktime(12, 0, 0, 2, 23, $year),
|
||||
mktime(12, 0, 0, 3, 30, $year),
|
||||
mktime(12, 0, 0, 4, 3, $year),
|
||||
mktime(12, 0, 0, 4, 3, $year),
|
||||
mktime(12, 0, 0, 5, 9, $year),
|
||||
mktime(12, 0, 0, 5, 1, $year),
|
||||
mktime(12, 0, 0, 5, 13, $year),
|
||||
mktime(12, 0, 0, 5, 19, $year),
|
||||
mktime(12, 0, 0, 5, 23, $year),
|
||||
mktime(12, 0, 0, 6, 3, $year),
|
||||
mktime(12, 0, 0, 6, 19, $year),
|
||||
mktime(12, 0, 0, 6, 24, $year),
|
||||
mktime(12, 0, 0, 7, 3, $year),
|
||||
mktime(12, 0, 0, 7, 9, $year),
|
||||
mktime(12, 0, 0, 7, 23, $year),
|
||||
mktime(12, 0, 0, 7, 30, $year),
|
||||
mktime(12, 0, 0, 8, 9, $year),
|
||||
mktime(12, 0, 0, 9, 23, $year),
|
||||
mktime(12, 0, 0, 10, 3, $year),
|
||||
mktime(12, 0, 0, 11, 12, $year),
|
||||
mktime(12, 0, 0, 11, 13, $year),
|
||||
mktime(12, 0, 0, 1, 3, ($year - 1)),
|
||||
mktime(12, 0, 0, 1, 9, ($year - 1)),
|
||||
mktime(12, 0, 0, 2, 13, ($year - 1)),
|
||||
mktime(12, 0, 0, 2, 23, ($year - 1)),
|
||||
mktime(12, 0, 0, 3, 30, ($year - 1)),
|
||||
mktime(12, 0, 0, 4, 3, ($year - 1)),
|
||||
mktime(12, 0, 0, 4, 3, ($year - 1)),
|
||||
mktime(12, 0, 0, 5, 9, ($year - 1)),
|
||||
mktime(12, 0, 0, 5, 1, ($year - 1)),
|
||||
mktime(12, 0, 0, 5, 13, ($year - 1)),
|
||||
mktime(12, 0, 0, 5, 19, ($year - 1)),
|
||||
mktime(12, 0, 0, 5, 23, ($year - 1)),
|
||||
mktime(12, 0, 0, 6, 3, ($year - 1)),
|
||||
mktime(12, 0, 0, 6, 19, ($year - 1)),
|
||||
mktime(12, 0, 0, 6, 24, ($year - 1)),
|
||||
mktime(12, 0, 0, 7, 3, ($year - 1)),
|
||||
mktime(12, 0, 0, 7, 9, ($year - 1)),
|
||||
mktime(12, 0, 0, 7, 23, ($year - 1)),
|
||||
mktime(12, 0, 0, 7, 30, ($year - 1)),
|
||||
mktime(12, 0, 0, 8, 9, ($year - 1)),
|
||||
mktime(12, 0, 0, 9, 23, ($year - 1)),
|
||||
mktime(12, 0, 0, 10, 3, ($year - 1)),
|
||||
mktime(12, 0, 0, 11, 12, $year),
|
||||
mktime(12, 0, 0, 11, 13, $year),
|
||||
mktime(12, 0, 0, 12, 12, $year),
|
||||
mktime(12, 0, 0, 12, 13, $year),
|
||||
);
|
||||
|
||||
$ret=$user->fetch('','admin');
|
||||
$ret=$user->fetch('', 'admin');
|
||||
if (! $ret > 0)
|
||||
{
|
||||
print 'A user with login "admin" and all permissions must be created to use this script.'."\n";
|
||||
@@ -157,7 +157,7 @@ $user->rights->propal->propal_advance->validate=1;
|
||||
|
||||
if (! empty($conf->global->PROPALE_ADDON) && is_readable(DOL_DOCUMENT_ROOT ."/core/modules/propale/".$conf->global->PROPALE_ADDON.".php"))
|
||||
{
|
||||
require_once(DOL_DOCUMENT_ROOT ."/core/modules/propale/".$conf->global->PROPALE_ADDON.".php");
|
||||
require_once DOL_DOCUMENT_ROOT ."/core/modules/propale/".$conf->global->PROPALE_ADDON.".php";
|
||||
}
|
||||
|
||||
$i=0;
|
||||
@@ -174,7 +174,7 @@ while ($i < GEN_NUMBER_PROPAL && $result >= 0)
|
||||
$object = new Propal($db);
|
||||
|
||||
$fuser = new User($db);
|
||||
$fuser->fetch(mt_rand(1,2));
|
||||
$fuser->fetch(mt_rand(1, 2));
|
||||
$fuser->getRights();
|
||||
|
||||
$object->contactid = $contids[$socids[$socid]][0];
|
||||
@@ -193,10 +193,10 @@ while ($i < GEN_NUMBER_PROPAL && $result >= 0)
|
||||
$prodid = mt_rand(1, $num_prods);
|
||||
$product=new Product($db);
|
||||
$result=$product->fetch($prodids[$prodid]);
|
||||
$result=$object->addline($product->description, $product->price, mt_rand(1,5), 0, 0, 0, $prodids[$prodid], 0);
|
||||
$result=$object->addline($product->description, $product->price, mt_rand(1, 5), 0, 0, 0, $prodids[$prodid], 0);
|
||||
if ($result < 0)
|
||||
{
|
||||
dol_print_error($db,$object->error);
|
||||
dol_print_error($db, $object->error);
|
||||
}
|
||||
$xnbp++;
|
||||
}
|
||||
@@ -211,13 +211,11 @@ while ($i < GEN_NUMBER_PROPAL && $result >= 0)
|
||||
{
|
||||
print " KO\n";
|
||||
$db->rollback();
|
||||
dol_print_error($db,$object->error);
|
||||
dol_print_error($db, $object->error);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
dol_print_error($db,$object->error);
|
||||
dol_print_error($db, $object->error);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -33,7 +33,7 @@ if (substr($sapi_type, 0, 3) == 'cgi') {
|
||||
|
||||
// Recupere root dolibarr
|
||||
//$path=preg_replace('/generate-societe.php/i','',$_SERVER["PHP_SELF"]);
|
||||
require (__DIR__. '/../../htdocs/master.inc.php');
|
||||
require __DIR__. '/../../htdocs/master.inc.php';
|
||||
include_once DOL_DOCUMENT_ROOT.'/societe/class/societe.class.php';
|
||||
include_once DOL_DOCUMENT_ROOT.'/contact/class/contact.class.php';
|
||||
include_once DOL_DOCUMENT_ROOT.'/compta/facture/class/facture.class.php';
|
||||
@@ -52,7 +52,7 @@ $listoflastname = array("Joe","Marc","Steve","Laurent","Nico","Isabelle","Doroth
|
||||
define(GEN_NUMBER_SOCIETE, 10);
|
||||
|
||||
|
||||
$ret=$user->fetch('','admin');
|
||||
$ret=$user->fetch('', 'admin');
|
||||
if (! $ret > 0)
|
||||
{
|
||||
print 'A user with login "admin" and all permissions must be created to use this script.'."\n";
|
||||
@@ -91,22 +91,22 @@ for ($s = 0 ; $s < GEN_NUMBER_SOCIETE ; $s++)
|
||||
$soc = new Societe($db);
|
||||
$soc->name = "Company num ".time()."$s";
|
||||
$soc->town = $listoftown[mt_rand(0, count($listoftown)-1)];
|
||||
$soc->client = mt_rand(1,2); // Une societe sur 2 est prospect, l'autre client
|
||||
$soc->fournisseur = mt_rand(0,1); // Une societe sur 2 est fournisseur
|
||||
$soc->client = mt_rand(1, 2); // Une societe sur 2 est prospect, l'autre client
|
||||
$soc->fournisseur = mt_rand(0, 1); // Une societe sur 2 est fournisseur
|
||||
$soc->code_client='CU'.time()."$s";
|
||||
$soc->code_fournisseur='SU'.time()."$s";
|
||||
$soc->tva_assuj=1;
|
||||
$soc->country_id=1;
|
||||
$soc->country_code='FR';
|
||||
// Un client sur 3 a une remise de 5%
|
||||
$user_remise=mt_rand(1,3); if ($user_remise==3) $soc->remise_percent=5;
|
||||
$user_remise=mt_rand(1, 3); if ($user_remise==3) $soc->remise_percent=5;
|
||||
print "> client=".$soc->client.", fournisseur=".$soc->fournisseur.", remise=".$soc->remise_percent."\n";
|
||||
$soc->note_private = 'Company created by the script generate-societe.php';
|
||||
$socid = $soc->create();
|
||||
|
||||
if ($socid >= 0)
|
||||
{
|
||||
$rand = mt_rand(1,4);
|
||||
$rand = mt_rand(1, 4);
|
||||
print "> Generates $rand contact(s)\n";
|
||||
for ($c = 0 ; $c < $rand ; $c++)
|
||||
{
|
||||
@@ -127,5 +127,3 @@ for ($s = 0 ; $s < GEN_NUMBER_SOCIETE ; $s++)
|
||||
print "Error: ".$soc->error."\n";
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
|
||||
/**
|
||||
* \file dev/initdata/import-product.php
|
||||
* \brief Script example to insert products from a csv file.
|
||||
* \brief Script example to insert products from a csv file.
|
||||
* To purge data, you can have a look at purge-data.php
|
||||
*/
|
||||
|
||||
@@ -35,8 +35,8 @@ if (substr($sapi_type, 0, 3) == 'cgi') {
|
||||
}
|
||||
|
||||
// Recupere root dolibarr
|
||||
$path=preg_replace('/import-products.php/i','',$_SERVER["PHP_SELF"]);
|
||||
require ($path."../../htdocs/master.inc.php");
|
||||
$path=preg_replace('/import-products.php/i', '', $_SERVER["PHP_SELF"]);
|
||||
require $path."../../htdocs/master.inc.php";
|
||||
include_once DOL_DOCUMENT_ROOT.'/societe/class/societe.class.php';
|
||||
include_once DOL_DOCUMENT_ROOT.'/product/class/product.class.php';
|
||||
|
||||
@@ -57,7 +57,7 @@ $error=0;
|
||||
|
||||
@set_time_limit(0);
|
||||
print "***** ".$script_file." (".$version.") pid=".dol_getmypid()." *****\n";
|
||||
dol_syslog($script_file." launched with arg ".implode(',',$argv));
|
||||
dol_syslog($script_file." launched with arg ".implode(',', $argv));
|
||||
|
||||
$mode = $argv[1];
|
||||
$filepath = $argv[2];
|
||||
@@ -66,7 +66,7 @@ $defaultlang = empty($argv[3])?'en_US':$argv[3];
|
||||
$startlinenb = empty($argv[4])?1:$argv[4];
|
||||
$endlinenb = empty($argv[5])?0:$argv[5];
|
||||
|
||||
if (empty($mode) || ! in_array($mode,array('test','confirm','confirmforced')) || empty($filepath)) {
|
||||
if (empty($mode) || ! in_array($mode, array('test','confirm','confirmforced')) || empty($filepath)) {
|
||||
print "Usage: $script_file (test|confirm|confirmforced) filepath.csv [defaultlang] [startlinenb] [endlinenb]\n";
|
||||
print "Usage: $script_file test myfilepath.csv fr_FR 2 1002\n";
|
||||
print "\n";
|
||||
@@ -78,7 +78,7 @@ if (! file_exists($filepath)) {
|
||||
exit(-1);
|
||||
}
|
||||
|
||||
$ret=$user->fetch('','admin');
|
||||
$ret=$user->fetch('', 'admin');
|
||||
if (! $ret > 0)
|
||||
{
|
||||
print 'A user with login "admin" and all permissions must be created to use this script.'."\n";
|
||||
@@ -93,7 +93,7 @@ if (! $confirmed)
|
||||
$input = trim(fgets(STDIN));
|
||||
}
|
||||
|
||||
// Open input and ouput files
|
||||
// Open input and output files
|
||||
$fhandle = fopen($filepath, 'r');
|
||||
if (! $fhandle)
|
||||
{
|
||||
@@ -118,22 +118,22 @@ while ($fields=fgetcsv($fhandle, $linelength, $delimiter, $enclosure, $escape))
|
||||
{
|
||||
$i++;
|
||||
$errorrecord=0;
|
||||
|
||||
|
||||
if ($startlinenb && $i < $startlinenb) continue;
|
||||
if ($endlinenb && $i > $endlinenb) continue;
|
||||
|
||||
|
||||
$nboflines++;
|
||||
|
||||
|
||||
$produit = new Product($db);
|
||||
$produit->type = 0;
|
||||
$produit->status = 1;
|
||||
$produit->ref = trim($fields[0]);
|
||||
|
||||
|
||||
print "Process line nb ".$i.", ref ".$produit->ref;
|
||||
$produit->label = trim($fields[2]);
|
||||
$produit->description = trim($fields[4]."\n".($fields[5] ? $fields[5].' x '.$fields[6].' x '.$fields[7] : ''));
|
||||
$produit->volume = price2num($fields[8]);
|
||||
$produit->volume_unit = 0;
|
||||
$produit->volume_unit = 0;
|
||||
$produit->weight = price2num($fields[9]);
|
||||
$produit->weight_units = 0; // -3 = g
|
||||
|
||||
@@ -142,9 +142,9 @@ while ($fields=fgetcsv($fhandle, $linelength, $delimiter, $enclosure, $escape))
|
||||
|
||||
$produit->status = 1;
|
||||
$produit->status_buy = 1;
|
||||
|
||||
|
||||
$produit->finished = 1;
|
||||
|
||||
|
||||
$produit->price_min = null;
|
||||
$produit->price_min_ttc = null;
|
||||
$produit->price = price2num($fields[11]);
|
||||
@@ -152,25 +152,25 @@ while ($fields=fgetcsv($fhandle, $linelength, $delimiter, $enclosure, $escape))
|
||||
$produit->price_base_type = 'TTC';
|
||||
$produit->tva_tx = price2num($fields[13]);
|
||||
$produit->tva_npr = 0;
|
||||
|
||||
|
||||
$produit->cost_price = price2num($fields[16]);
|
||||
|
||||
|
||||
// Extrafields
|
||||
$produit->array_options['options_ecotaxdeee']=price2num($fields[17]);
|
||||
|
||||
|
||||
$ret=$produit->create($user);
|
||||
if ($ret < 0)
|
||||
{
|
||||
print " - Error in create result code = ".$ret." - ".$produit->errorsToString();
|
||||
$errorrecord++;
|
||||
}
|
||||
else
|
||||
else
|
||||
{
|
||||
print " - Creation OK with ref ".$produit->ref." - id = ".$ret;
|
||||
}
|
||||
|
||||
dol_syslog("Add prices");
|
||||
|
||||
|
||||
// If we use price level, insert price for each level
|
||||
if (! $errorrecord && 1)
|
||||
{
|
||||
@@ -181,14 +181,14 @@ while ($fields=fgetcsv($fhandle, $linelength, $delimiter, $enclosure, $escape))
|
||||
print " - Error in updatePrice result code = ".$ret1." ".$ret2." - ".$produit->errorsToString();
|
||||
$errorrecord++;
|
||||
}
|
||||
else
|
||||
else
|
||||
{
|
||||
print " - updatePrice OK";
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
dol_syslog("Add multilangs");
|
||||
|
||||
|
||||
// Add alternative languages
|
||||
if (! $errorrecord && 1)
|
||||
{
|
||||
@@ -201,15 +201,15 @@ while ($fields=fgetcsv($fhandle, $linelength, $delimiter, $enclosure, $escape))
|
||||
print " - Error in setMultiLangs result code = ".$ret." - ".$produit->errorsToString();
|
||||
$errorrecord++;
|
||||
}
|
||||
else
|
||||
else
|
||||
{
|
||||
print " - setMultiLangs OK";
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
print "\n";
|
||||
|
||||
if ($errorrecord)
|
||||
|
||||
if ($errorrecord)
|
||||
{
|
||||
fwrite($fhandleerr, 'Error on record nb '.$i." - ".$produit->errorsToString()."\n");
|
||||
$error++; // $errorrecord will be reset
|
||||
|
||||
@@ -35,8 +35,8 @@ if (substr($sapi_type, 0, 3) == 'cgi') {
|
||||
}
|
||||
|
||||
// Recupere root dolibarr
|
||||
$path=preg_replace('/import-thirdparties.php/i','',$_SERVER["PHP_SELF"]);
|
||||
require ($path."../../htdocs/master.inc.php");
|
||||
$path=preg_replace('/import-thirdparties.php/i', '', $_SERVER["PHP_SELF"]);
|
||||
require $path."../../htdocs/master.inc.php";
|
||||
include_once DOL_DOCUMENT_ROOT.'/societe/class/societe.class.php';
|
||||
include_once DOL_DOCUMENT_ROOT.'/product/class/product.class.php';
|
||||
|
||||
@@ -57,7 +57,7 @@ $error=0;
|
||||
|
||||
@set_time_limit(0);
|
||||
print "***** ".$script_file." (".$version.") pid=".dol_getmypid()." *****\n";
|
||||
dol_syslog($script_file." launched with arg ".implode(',',$argv));
|
||||
dol_syslog($script_file." launched with arg ".implode(',', $argv));
|
||||
|
||||
$mode = $argv[1];
|
||||
$filepath = $argv[2];
|
||||
@@ -66,7 +66,7 @@ $filepatherr = $filepath.'.err';
|
||||
$startlinenb = empty($argv[3])?1:$argv[3];
|
||||
$endlinenb = empty($argv[4])?0:$argv[4];
|
||||
|
||||
if (empty($mode) || ! in_array($mode,array('test','confirm','confirmforced')) || empty($filepath)) {
|
||||
if (empty($mode) || ! in_array($mode, array('test','confirm','confirmforced')) || empty($filepath)) {
|
||||
print "Usage: $script_file (test|confirm|confirmforced) filepath.csv [startlinenb] [endlinenb]\n";
|
||||
print "Usage: $script_file test myfilepath.csv 2 1002\n";
|
||||
print "\n";
|
||||
@@ -78,7 +78,7 @@ if (! file_exists($filepath)) {
|
||||
exit(-1);
|
||||
}
|
||||
|
||||
$ret=$user->fetch('','admin');
|
||||
$ret=$user->fetch('', 'admin');
|
||||
if (! $ret > 0)
|
||||
{
|
||||
print 'A user with login "admin" and all permissions must be created to use this script.'."\n";
|
||||
@@ -93,7 +93,7 @@ if (! $confirmed)
|
||||
$input = trim(fgets(STDIN));
|
||||
}
|
||||
|
||||
// Open input and ouput files
|
||||
// Open input and output files
|
||||
$fhandle = fopen($filepath, 'r');
|
||||
if (! $fhandle)
|
||||
{
|
||||
@@ -199,13 +199,13 @@ while ($fields=fgetcsv($fhandle, $linelength, $delimiter, $enclosure, $escape))
|
||||
{
|
||||
$salesrep=new User($db);
|
||||
|
||||
$tmp=explode(' ',$fields[3],2);
|
||||
$tmp=explode(' ', $fields[3], 2);
|
||||
$salesrep->firstname = trim($tmp[0]);
|
||||
$salesrep->lastname = trim($tmp[1]);
|
||||
if ($salesrep->lastname) $salesrep->login = strtolower(substr($salesrep->firstname, 0, 1)) . strtolower(substr($salesrep->lastname, 0));
|
||||
else $salesrep->login=strtolower($salesrep->firstname);
|
||||
$salesrep->login=preg_replace('/ /','',$salesrep->login);
|
||||
$salesrep->fetch(0,$salesrep->login);
|
||||
$salesrep->login=preg_replace('/ /', '', $salesrep->login);
|
||||
$salesrep->fetch(0, $salesrep->login);
|
||||
|
||||
$result = $object->add_commercial($user, $salesrep->id);
|
||||
if ($result < 0)
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
|
||||
/**
|
||||
* \file dev/initdata/import-thirdparties.php
|
||||
* \brief Script example to insert thirdparties from a csv file.
|
||||
* \brief Script example to insert thirdparties from a csv file.
|
||||
* To purge data, you can have a look at purge-data.php
|
||||
*/
|
||||
|
||||
@@ -35,8 +35,8 @@ if (substr($sapi_type, 0, 3) == 'cgi') {
|
||||
}
|
||||
|
||||
// Recupere root dolibarr
|
||||
$path=preg_replace('/import-users.php/i','',$_SERVER["PHP_SELF"]);
|
||||
require ($path."../../htdocs/master.inc.php");
|
||||
$path=preg_replace('/import-users.php/i', '', $_SERVER["PHP_SELF"]);
|
||||
require $path."../../htdocs/master.inc.php";
|
||||
include_once DOL_DOCUMENT_ROOT.'/societe/class/societe.class.php';
|
||||
include_once DOL_DOCUMENT_ROOT.'/product/class/product.class.php';
|
||||
|
||||
@@ -57,7 +57,7 @@ $error=0;
|
||||
|
||||
@set_time_limit(0);
|
||||
print "***** ".$script_file." (".$version.") pid=".dol_getmypid()." *****\n";
|
||||
dol_syslog($script_file." launched with arg ".implode(',',$argv));
|
||||
dol_syslog($script_file." launched with arg ".implode(',', $argv));
|
||||
|
||||
$mode = $argv[1];
|
||||
$filepath = $argv[2];
|
||||
@@ -66,7 +66,7 @@ $filepatherr = $filepath.'.err';
|
||||
$startlinenb = empty($argv[3])?1:$argv[3];
|
||||
$endlinenb = empty($argv[4])?0:$argv[4];
|
||||
|
||||
if (empty($mode) || ! in_array($mode,array('test','confirm','confirmforced')) || empty($filepath)) {
|
||||
if (empty($mode) || ! in_array($mode, array('test','confirm','confirmforced')) || empty($filepath)) {
|
||||
print "Usage: $script_file (test|confirm|confirmforced) filepath.csv [startlinenb] [endlinenb]\n";
|
||||
print "Usage: $script_file test myfilepath.csv 2 1002\n";
|
||||
print "\n";
|
||||
@@ -78,7 +78,7 @@ if (! file_exists($filepath)) {
|
||||
exit(-1);
|
||||
}
|
||||
|
||||
$ret=$user->fetch('','admin');
|
||||
$ret=$user->fetch('', 'admin');
|
||||
if (! $ret > 0)
|
||||
{
|
||||
print 'A user with login "admin" and all permissions must be created to use this script.'."\n";
|
||||
@@ -93,7 +93,7 @@ if (! $confirmed)
|
||||
$input = trim(fgets(STDIN));
|
||||
}
|
||||
|
||||
// Open input and ouput files
|
||||
// Open input and output files
|
||||
$fhandle = fopen($filepath, 'r');
|
||||
if (! $fhandle)
|
||||
{
|
||||
@@ -118,39 +118,39 @@ while ($fields=fgetcsv($fhandle, $linelength, $delimiter, $enclosure, $escape))
|
||||
{
|
||||
$i++;
|
||||
$errorrecord=0;
|
||||
|
||||
|
||||
if ($startlinenb && $i < $startlinenb) continue;
|
||||
if ($endlinenb && $i > $endlinenb) continue;
|
||||
|
||||
|
||||
$nboflines++;
|
||||
|
||||
|
||||
$object = new User($db);
|
||||
$object->statut = 1;
|
||||
|
||||
$tmp=explode(' ',$fields[3],2);
|
||||
|
||||
$tmp=explode(' ', $fields[3], 2);
|
||||
$object->firstname = trim($tmp[0]);
|
||||
$object->lastname = trim($tmp[1]);
|
||||
if ($object->lastname) $object->login = strtolower(substr($object->firstname, 0, 1)) . strtolower(substr($object->lastname, 0));
|
||||
else $object->login=strtolower($object->firstname);
|
||||
$object->login=preg_replace('/ /','',$object->login);
|
||||
$object->login=preg_replace('/ /', '', $object->login);
|
||||
$object->password = 'init';
|
||||
|
||||
|
||||
print "Process line nb ".$i.", login ".$object->login;
|
||||
|
||||
|
||||
$ret=$object->create($user);
|
||||
if ($ret < 0)
|
||||
{
|
||||
print " - Error in create result code = ".$ret." - ".$object->errorsToString();
|
||||
$errorrecord++;
|
||||
}
|
||||
else
|
||||
else
|
||||
{
|
||||
print " - Creation OK with login ".$object->login." - id = ".$ret;
|
||||
}
|
||||
|
||||
print "\n";
|
||||
|
||||
if ($errorrecord)
|
||||
|
||||
if ($errorrecord)
|
||||
{
|
||||
fwrite($fhandleerr, 'Error on record nb '.$i." - ".$object->errorsToString()."\n");
|
||||
$error++; // $errorrecord will be reset
|
||||
|
||||
@@ -35,8 +35,8 @@ if (substr($sapi_type, 0, 3) == 'cgi') {
|
||||
}
|
||||
|
||||
// Recupere root dolibarr
|
||||
$path=preg_replace('/purge-data.php/i','',$_SERVER["PHP_SELF"]);
|
||||
require ($path."../../htdocs/master.inc.php");
|
||||
$path=preg_replace('/purge-data.php/i', '', $_SERVER["PHP_SELF"]);
|
||||
require $path."../../htdocs/master.inc.php";
|
||||
include_once DOL_DOCUMENT_ROOT.'/societe/class/societe.class.php';
|
||||
include_once DOL_DOCUMENT_ROOT.'/contact/class/contact.class.php';
|
||||
include_once DOL_DOCUMENT_ROOT.'/compta/facture/class/facture.class.php';
|
||||
@@ -44,8 +44,7 @@ include_once DOL_DOCUMENT_ROOT.'/product/class/product.class.php';
|
||||
include_once DOL_DOCUMENT_ROOT.'/compta/paiement/class/paiement.class.php';
|
||||
include_once DOL_DOCUMENT_ROOT.'/contrat/class/contrat.class.php';
|
||||
|
||||
$langs->load("main");
|
||||
$langs->load("errors");
|
||||
$langs->loadLangs(array("main", "errors"));
|
||||
|
||||
// Global variables
|
||||
$version=DOL_VERSION;
|
||||
@@ -54,133 +53,177 @@ $error=0;
|
||||
// List of sql to execute
|
||||
$sqls=array(
|
||||
'user'=>array(
|
||||
'DELETE FROM '.MAIN_DB_PREFIX."user_rights WHERE fk_user IN (SELECT rowid FROM ".MAIN_DB_PREFIX."user WHERE admin = 0 and login != 'admin')",
|
||||
'DELETE FROM '.MAIN_DB_PREFIX."user WHERE admin = 0 and login != 'admin'",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."user_rights WHERE fk_user IN (SELECT rowid FROM ".MAIN_DB_PREFIX."user WHERE admin = 0 and login != 'admin') AND fk_user IN (select rowid FROM ".MAIN_DB_PREFIX."user where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."user WHERE admin = 0 and login != 'admin' AND datec < '__DATE__'",
|
||||
),
|
||||
'event'=>array(
|
||||
//"DELETE FROM ".MAIN_DB_PREFIX."actioncomm WHERE lineid IN (SELECT rowid FROM ".MAIN_DB_PREFIX."bank WHERE datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."actioncomm WHERE datec < '__DATE__'",
|
||||
),
|
||||
'payment'=>array(
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."paiement_facture where fk_facture IN (select rowid FROM ".MAIN_DB_PREFIX."facture where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."paiement where rowid NOT IN (SELECT fk_paiement FROM ".MAIN_DB_PREFIX."paiement_facture)",
|
||||
),
|
||||
'bank'=>array(
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'bank_account',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'bank_class',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'bank_url',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'bank',
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."bank_class WHERE lineid IN (SELECT rowid FROM ".MAIN_DB_PREFIX."bank WHERE datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."bank_url WHERE fk_bank IN (SELECT rowid FROM ".MAIN_DB_PREFIX."bank WHERE datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."bank WHERE datec < '__DATE__'",
|
||||
),
|
||||
'contract'=>array(
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'contratdet',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'contrat',
|
||||
'bankaccount'=>array(
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."bank_account WHERE datec < '__DATE__'",
|
||||
),
|
||||
'invoice'=>array(
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'paiement_facture',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'facture_rec',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'facturedet',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'facture WHERE fk_facture_source IS NOT NULL',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'facture',
|
||||
'@payment',
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."societe_remise_except where fk_facture_source IN (select rowid FROM ".MAIN_DB_PREFIX."facture where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."societe_remise_except where fk_facture IN (select rowid FROM ".MAIN_DB_PREFIX."facture where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."societe_remise_except where fk_facture_line IN (select rowid FROM ".MAIN_DB_PREFIX."facturedet as fd WHERE fd.fk_facture IN (select rowid from ".MAIN_DB_PREFIX."facture where datec < '__DATE__'))",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."facture_rec where datec < '__DATE__'",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."facturedet WHERE fk_facture IN (select rowid FROM ".MAIN_DB_PREFIX."facture where datec < '__DATE__')",
|
||||
"UPDATE ".MAIN_DB_PREFIX."facture SET fk_facture_source = NULL WHERE fk_facture_source IN (select f2.rowid FROM (select * from ".MAIN_DB_PREFIX."facture) as f2 where f2.datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."facture where datec < '__DATE__'",
|
||||
),
|
||||
'accounting'=>array(
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."accounting_bookkeeping where doc_date < '__DATE__'",
|
||||
),
|
||||
'proposal'=>array(
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'propaldet',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'propal',
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."propaldet WHERE fk_propal IN (select rowid FROM ".MAIN_DB_PREFIX."propal where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."propal WHERE datec < '__DATE__'",
|
||||
),
|
||||
'supplier_proposal'=>array(
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'supplier_proposaldet',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'supplier_proposal',
|
||||
),
|
||||
'supplier_order'=>array(
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'commande_fournisseurdet',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'commande_fournisseur',
|
||||
),
|
||||
'supplier_invoice'=>array(
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'facture_fourn_det',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'facture_fourn',
|
||||
),
|
||||
'delivery'=>array(
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'livraisondet',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'livraison',
|
||||
),
|
||||
'shipment'=>array(
|
||||
'@delivery',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'expeditiondet_batch',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'expeditiondet_extrafields',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'expeditiondet',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'expedition_extrafields',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'expedition',
|
||||
"supplier_proposal"=>array(
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."supplier_proposaldet WHERE fk_supplier_proposal IN (select rowid FROM ".MAIN_DB_PREFIX."propal where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."supplier_proposal where datec < '__DATE__'",
|
||||
),
|
||||
'order'=>array(
|
||||
'@shipment',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'commandedet',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'commande',
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."commandedet WHERE fk_commande IN (select rowid FROM ".MAIN_DB_PREFIX."commande where date_creation < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."commande where date_creation < '__DATE__'",
|
||||
),
|
||||
'supplier_order'=>array(
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."commande_fournisseurdet WHERE fk_commande IN (select rowid FROM ".MAIN_DB_PREFIX."commande_fournisseur where date_creation < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."commande_fournisseur where date_creation < '__DATE__'",
|
||||
),
|
||||
'supplier_invoice'=>array(
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."facture_fourn_det WHERE fk_facture_fourn IN (select rowid FROM ".MAIN_DB_PREFIX."facture_fourn where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."facture_fourn where datec < '__DATE__'",
|
||||
),
|
||||
'shipment'=>array(
|
||||
'@delivery',
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."expeditiondet_batch WHERE fk_expeditiondet IN (select rowid FROM ".MAIN_DB_PREFIX."expeditiondet WHERE fk_expedition IN (select rowid FROM ".MAIN_DB_PREFIX."expedition where date_creation < '__DATE__'))",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."expeditiondet_extrafields WHERE fk_object IN (select rowid FROM ".MAIN_DB_PREFIX."expeditiondet WHERE fk_expedition IN (select rowid FROM ".MAIN_DB_PREFIX."expedition where date_creation < '__DATE__'))",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."expeditiondet WHERE fk_expedition IN (select rowid FROM ".MAIN_DB_PREFIX."expedition where date_creation < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."expedition_extrafields WHERE fk_object IN (select rowid FROM ".MAIN_DB_PREFIX."expedition where date_creation < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."expedition where date_creation < '__DATE__'",
|
||||
),
|
||||
'delivery'=>array(
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."livraisondet WHERE fk_livraison IN (select rowid FROM ".MAIN_DB_PREFIX."livraison where date_creation < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."livraison where date_creation < '__DATE__'",
|
||||
),
|
||||
'contract'=>array(
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."contratdet_extrafields WHERE fk_object IN (select rowid FROM ".MAIN_DB_PREFIX."contratdet WHERE fk_contrat IN (select rowid FROM ".MAIN_DB_PREFIX."contrat where datec < '__DATE__'))",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."contratdet WHERE fk_contrat IN (select rowid FROM ".MAIN_DB_PREFIX."contrat where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."contrat_extrafields WHERE fk_object IN (select rowid FROM ".MAIN_DB_PREFIX."contrat where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."contrat WHERE datec < '__DATE__'",
|
||||
),
|
||||
'intervention'=>array(
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'fichinterdet',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'fichinter',
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."fichinterdet WHERE fk_fichinter IN (select rowid FROM ".MAIN_DB_PREFIX."fichinter where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."fichinter where datec < '__DATE__'",
|
||||
),
|
||||
'stock'=>array(
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."stock_mouvement WHERE datem < '__DATE__'",
|
||||
),
|
||||
'product'=>array(
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'categorie_product',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'product_lang',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'product_price',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'product_fournisseur_price',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'product_batch',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'product_stock',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'product_lot',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'product',
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."categorie_product WHERE fk_product IN (select rowid FROM ".MAIN_DB_PREFIX."product where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."product_lang WHERE fk_product IN (select rowid FROM ".MAIN_DB_PREFIX."product where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."product_price_by_qty WHERE fk_product_price IN (select rowid FROM ".MAIN_DB_PREFIX."product_price where fk_product IN (select rowid FROM ".MAIN_DB_PREFIX."product where datec < '__DATE__'))",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."product_price WHERE fk_product IN (select rowid FROM ".MAIN_DB_PREFIX."product where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."product_fournisseur_price WHERE fk_product IN (select rowid FROM ".MAIN_DB_PREFIX."product where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."product_batch WHERE fk_product_stock IN (select rowid FROM ".MAIN_DB_PREFIX."product_stock where fk_product IN (select rowid FROM ".MAIN_DB_PREFIX."product where datec < '__DATE__'))",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."product_stock WHERE fk_product IN (select rowid FROM ".MAIN_DB_PREFIX."product where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."product_lot WHERE fk_product IN (select rowid FROM ".MAIN_DB_PREFIX."product where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."product where datec < '__DATE__'",
|
||||
),
|
||||
'project'=>array(
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'projet_task_time',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'projet_task',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'projet',
|
||||
// TODO set fk_project to null on object that refer to project
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."projet_task_time WHERE fk_task IN (select rowid FROM ".MAIN_DB_PREFIX."projet_task WHERE fk_projet IN (select rowid FROM ".MAIN_DB_PREFIX."projet where datec < '__DATE__'))",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."projet_task WHERE fk_projet IN (select rowid FROM ".MAIN_DB_PREFIX."projet where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."projet where datec < '__DATE__'",
|
||||
),
|
||||
'contact'=>array(
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'categorie_contact',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'socpeople',
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."categorie_contact WHERE fk_socpeople IN (select rowid FROM ".MAIN_DB_PREFIX."socpeople where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."socpeople where datec < '__DATE__'",
|
||||
),
|
||||
'thirdparty'=>array(
|
||||
'@contact',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'cabinetmed_cons',
|
||||
'UPDATE '.MAIN_DB_PREFIX.'adherent SET fk_soc = NULL',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'categorie_fournisseur',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'categorie_societe',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'societe_remise_except',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'societe_rib',
|
||||
'DELETE FROM '.MAIN_DB_PREFIX.'societe',
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."cabinetmed_cons WHERE fk_soc IN (select rowid FROM ".MAIN_DB_PREFIX."societe where datec < '__DATE__')",
|
||||
"UPDATE ".MAIN_DB_PREFIX."adherent SET fk_soc = NULL WHERE fk_soc IN (select rowid FROM ".MAIN_DB_PREFIX."societe where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."categorie_fournisseur WHERE fk_soc IN (select rowid FROM ".MAIN_DB_PREFIX."societe where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."categorie_societe WHERE fk_soc IN (select rowid FROM ".MAIN_DB_PREFIX."societe where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."societe_remise_except WHERE fk_soc IN (select rowid FROM ".MAIN_DB_PREFIX."societe where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."societe_rib WHERE fk_soc IN (select rowid FROM ".MAIN_DB_PREFIX."societe where datec < '__DATE__')",
|
||||
"DELETE FROM ".MAIN_DB_PREFIX."societe where datec < '__DATE__'",
|
||||
)
|
||||
);
|
||||
|
||||
|
||||
|
||||
|
||||
/*
|
||||
* Main
|
||||
*/
|
||||
|
||||
@set_time_limit(0);
|
||||
print "***** ".$script_file." (".$version.") pid=".dol_getmypid()." *****\n";
|
||||
dol_syslog($script_file." launched with arg ".implode(',',$argv));
|
||||
dol_syslog($script_file." launched with arg ".implode(',', $argv));
|
||||
|
||||
$mode = $argv[1];
|
||||
$option = $argv[2];
|
||||
$date = $argv[3];
|
||||
|
||||
if (empty($mode) || ! in_array($mode,array('test','confirm'))) {
|
||||
print "Usage: $script_file (test|confirm) (all|option) [dbtype dbhost dbuser dbpassword dbname dbport]\n";
|
||||
if (empty($mode) || ! in_array($mode, array('test','confirm'))) {
|
||||
print "Usage: $script_file (test|confirm) (all|option) (all|YYYY-MM-DD) [dbtype dbhost dbuser dbpassword dbname dbport]\n";
|
||||
print "\n";
|
||||
print "option can be ".implode(',',array_keys($sqls))."\n";
|
||||
print "option can be ".implode(',', array_keys($sqls))."\n";
|
||||
exit(-1);
|
||||
}
|
||||
if (empty($option))
|
||||
{
|
||||
print "Usage: $script_file (test|confirm) (all|option) (all|YYYY-MM-DD) [dbtype dbhost dbuser dbpassword dbname dbport]\n";
|
||||
print "\n";
|
||||
print "option must be defined with a value in list ".implode(',', array_keys($sqls))."\n";
|
||||
exit(-1);
|
||||
}
|
||||
if ($option != 'all')
|
||||
{
|
||||
$listofoptions=explode(',', $option);
|
||||
foreach($listofoptions as $cursoroption)
|
||||
{
|
||||
if (! in_array($cursoroption, array_keys($sqls))) {
|
||||
print "Usage: $script_file (test|confirm) (all|option) (all|YYYY-MM-DD) [dbtype dbhost dbuser dbpassword dbname dbport]\n";
|
||||
print "\n";
|
||||
print "option '".$cursoroption."' must be in list ".implode(',', array_keys($sqls))."\n";
|
||||
exit(-1);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (empty($date) || (! preg_match('/\d\d\d\d\-\d\d\-\d\d$/', $date) && $date != 'all')) {
|
||||
print "Usage: $script_file (test|confirm) (all|option) (all|YYYY-MM-DD) [dbtype dbhost dbuser dbpassword dbname dbport]\n";
|
||||
print "\n";
|
||||
print "date can be 'all' or 'YYYY-MM-DD' to delete record before YYYY-MM-DD\n";
|
||||
exit(-1);
|
||||
}
|
||||
|
||||
if (empty($option) || ! in_array($option, array_merge(array('all'),array_keys($sqls))) ) {
|
||||
print "Usage: $script_file (test|confirm) (all|option) [dbtype dbhost dbuser dbpassword dbname dbport]\n";
|
||||
print "\n";
|
||||
print "option can be ".implode(',',array_keys($sqls))."\n";
|
||||
exit(-1);
|
||||
}
|
||||
if ($date == 'all') $date = '2199-01-01';
|
||||
|
||||
// Replace database handler
|
||||
if (! empty($argv[3]))
|
||||
if (! empty($argv[4]))
|
||||
{
|
||||
$db->close();
|
||||
unset($db);
|
||||
$db=getDoliDBInstance($argv[3], $argv[4], $argv[5], $argv[6], $argv[7], $argv[8]);
|
||||
$db=getDoliDBInstance($argv[4], $argv[5], $argv[6], $argv[7], $argv[8], $argv[9]);
|
||||
$user=new User($db);
|
||||
}
|
||||
|
||||
//var_dump($user->db->database_name);
|
||||
$ret=$user->fetch('','admin');
|
||||
$ret=$user->fetch('', 'admin');
|
||||
if (! $ret > 0)
|
||||
{
|
||||
print 'An admin user with login "admin" must exists to use this script.'."\n";
|
||||
@@ -190,6 +233,7 @@ if (! $ret > 0)
|
||||
|
||||
|
||||
print "Purge all data for this database:\n";
|
||||
print "Before = ".$date."\n";
|
||||
print "Server = ".$db->database_host."\n";
|
||||
print "Database name = ".$db->database_name."\n";
|
||||
print "Database port = ".$db->database_port."\n";
|
||||
@@ -207,23 +251,27 @@ if (! $confirmed)
|
||||
* Process sql requests of a family
|
||||
*
|
||||
* @param string $family Name of family key of array $sqls
|
||||
* @param string $date Date value
|
||||
* @return int -1 if KO, 1 if OK
|
||||
*/
|
||||
function processfamily($family)
|
||||
function processfamily($family, $date)
|
||||
{
|
||||
global $db, $sqls;
|
||||
|
||||
$error=0;
|
||||
foreach($sqls[$family] as $sql)
|
||||
{
|
||||
if (preg_match('/^@/',$sql))
|
||||
if (preg_match('/^@/', $sql))
|
||||
{
|
||||
$newfamily=preg_replace('/@/','',$sql);
|
||||
processfamily($newfamily);
|
||||
$newfamily=preg_replace('/@/', '', $sql);
|
||||
processfamily($newfamily, $date);
|
||||
continue;
|
||||
}
|
||||
|
||||
$sql = preg_replace('/__DATE__/', $date, $sql);
|
||||
|
||||
print "Run sql: ".$sql."\n";
|
||||
|
||||
$resql=$db->query($sql);
|
||||
if (! $resql)
|
||||
{
|
||||
@@ -248,25 +296,29 @@ function processfamily($family)
|
||||
|
||||
$db->begin();
|
||||
|
||||
$oldfamily='';
|
||||
foreach($sqls as $family => $familysql)
|
||||
$listofoptions=explode(',', $option);
|
||||
foreach($listofoptions as $cursoroption)
|
||||
{
|
||||
if ($option && $option != 'all' && $option != $family) continue;
|
||||
|
||||
if ($family != $oldfamily) print "Process action for family ".$family."\n";
|
||||
$oldfamily = $family;
|
||||
|
||||
$result=processfamily($family);
|
||||
if ($result < 0)
|
||||
$oldfamily='';
|
||||
foreach($sqls as $family => $familysql)
|
||||
{
|
||||
$error++;
|
||||
break;
|
||||
if ($cursoroption && $cursoroption != 'all' && $cursoroption != $family) continue;
|
||||
|
||||
if ($family != $oldfamily) print "Process action for family ".$family."\n";
|
||||
$oldfamily = $family;
|
||||
|
||||
$result=processfamily($family, $date);
|
||||
if ($result < 0)
|
||||
{
|
||||
$error++;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if ($error || $mode != 'confirm')
|
||||
{
|
||||
print "Rollback any changes.\n";
|
||||
print "\nRollback any changes.\n";
|
||||
$db->rollback();
|
||||
}
|
||||
else
|
||||
@@ -276,4 +328,3 @@ else
|
||||
}
|
||||
|
||||
$db->close();
|
||||
|
||||
|
||||
@@ -1,3 +0,0 @@
|
||||
<?php
|
||||
// Wrapper to include main into htdocs
|
||||
include_once '/home/ldestailleur/git/dolibarr_3.8/htdocs/main.inc.php';
|
||||
@@ -1,3 +0,0 @@
|
||||
<?php
|
||||
// Wrapper to include master into htdocs
|
||||
include_once '/home/ldestailleur/git/dolibarr_3.8/htdocs/master.inc.php';
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 360 KiB |
@@ -6,11 +6,11 @@
|
||||
# WARNING: This script erase all data of database
|
||||
# with data into dump file
|
||||
#
|
||||
# Regis Houssin - regis.houssin@capnetworks.com
|
||||
# Regis Houssin - regis.houssin@inodbox.com
|
||||
# Laurent Destailleur - eldy@users.sourceforge.net
|
||||
#------------------------------------------------------
|
||||
# Usage: initdemo.sh
|
||||
# usage: initdemo.sh mysqldump_dolibarr_x.x.x.sql database port login pass
|
||||
# Usage: initdemo.sh confirm
|
||||
# usage: initdemo.sh confirm mysqldump_dolibarr_x.x.x.sql database port login pass
|
||||
#------------------------------------------------------
|
||||
|
||||
|
||||
@@ -31,11 +31,20 @@ fi
|
||||
|
||||
|
||||
# ----------------------------- command line params
|
||||
dumpfile=$1;
|
||||
base=$2;
|
||||
port=$3;
|
||||
admin=$4;
|
||||
passwd=$5;
|
||||
confirm=$1;
|
||||
dumpfile=$2;
|
||||
base=$3;
|
||||
port=$4;
|
||||
admin=$5;
|
||||
passwd=$6;
|
||||
|
||||
# ----------------------------- check params
|
||||
if [ "x$confirm" != "xconfirm" ]
|
||||
then
|
||||
echo "----- $0 -----"
|
||||
echo "Usage: initdemo.sh confirm [mysqldump_dolibarr_x.x.x.sql database port login pass]"
|
||||
exit
|
||||
fi
|
||||
|
||||
|
||||
# ----------------------------- if no params on command line
|
||||
@@ -132,11 +141,14 @@ then
|
||||
exit;;
|
||||
esac
|
||||
|
||||
|
||||
export documentdir=`cat $mydir/../../htdocs/conf/conf.php | grep '^\$dolibarr_main_data_root' | sed -e 's/$dolibarr_main_data_root=//' | sed -e 's/;//' | sed -e "s/'//g" | sed -e 's/"//g' `
|
||||
|
||||
|
||||
# ---------------------------- confirmation
|
||||
DIALOG=${DIALOG=dialog}
|
||||
$DIALOG --title "Init Dolibarr with demo values" --clear \
|
||||
--yesno "Do you confirm ? \n Dump file : '$dumpfile' \n Dump dir : '$mydir' \n Mysql database : '$base' \n Mysql port : '$port' \n Mysql login: '$admin' \n Mysql password : '$passwd'" 15 55
|
||||
--yesno "Do you confirm ? \n Dump file : '$dumpfile' \n Dump dir : '$mydir' \n Document dir : '$documentdir' \n Mysql database : '$base' \n Mysql port : '$port' \n Mysql login: '$admin' \n Mysql password : '$passwd'" 15 55
|
||||
|
||||
case $? in
|
||||
0) echo "Ok, start process...";;
|
||||
@@ -165,15 +177,44 @@ export res=$?
|
||||
export documentdir=`cat $mydir/../../htdocs/conf/conf.php | grep '^\$dolibarr_main_data_root' | sed -e 's/$dolibarr_main_data_root=//' | sed -e 's/;//' | sed -e "s/'//g" | sed -e 's/"//g' `
|
||||
if [ "x$documentdir" != "x" ]
|
||||
then
|
||||
$DIALOG --title "Reset document directory tpp" --clear \
|
||||
--inputbox "Delete and recreate document directory $documentdir/:" 16 55 n 2> $fichtemp
|
||||
|
||||
valret=$?
|
||||
|
||||
case $valret in
|
||||
0)
|
||||
rep=`cat $fichtemp`;;
|
||||
1)
|
||||
exit;;
|
||||
255)
|
||||
exit;;
|
||||
esac
|
||||
|
||||
echo "rep=$rep"
|
||||
if [ "x$rep" = "xy" ]; then
|
||||
echo rm -fr "$documentdir/*"
|
||||
rm -fr $documentdir/*
|
||||
fi
|
||||
|
||||
echo cp -pr $mydir/documents_demo/* "$documentdir/"
|
||||
cp -pr $mydir/documents_demo/* "$documentdir/"
|
||||
|
||||
mkdir "$documentdir/doctemplates/" 2>/dev/null
|
||||
echo cp -pr $mydir/../../htdocs/install/doctemplates/* "$documentdir/doctemplates/"
|
||||
cp -pr $mydir/../../htdocs/install/doctemplates/* "$documentdir/doctemplates/"
|
||||
mkdir -p "$documentdir/ecm/Administrative documents"
|
||||
mkdir -p "$documentdir/ecm/Images"
|
||||
|
||||
echo cp -pr $mydir/../../htdocs/install/medias/* "$documentdir/medias/image/"
|
||||
cp -pr $mydir/../../htdocs/install/medias/* "$documentdir/medias/image/"
|
||||
|
||||
mkdir -p "$documentdir/ecm/Administrative documents" 2>/dev/null
|
||||
mkdir -p "$documentdir/ecm/Images" 2>/dev/null
|
||||
rm -f "$documentdir/doctemplates/"*/index.html
|
||||
echo cp -pr $mydir/../../doc/images/* "$documentdir/ecm/Images"
|
||||
cp -pr $mydir/../../doc/images/* "$documentdir/ecm/Images"
|
||||
|
||||
chmod -R u+w "$documentdir/"
|
||||
chown -R www-data "$documentdir/"
|
||||
else
|
||||
echo Detection of documents directory from $mydir failed so demo files were not copied.
|
||||
fi
|
||||
|
||||
@@ -7853,7 +7853,7 @@ CREATE TABLE `llx_socpeople` (
|
||||
|
||||
LOCK TABLES `llx_socpeople` WRITE;
|
||||
/*!40000 ALTER TABLE `llx_socpeople` DISABLE KEYS */;
|
||||
INSERT INTO `llx_socpeople` VALUES (1,'2010-07-08 14:26:14','2016-01-16 15:07:51',1,1,NULL,'MR','Indra','Mahala','','','',297,117,'2010-07-08','Project leader','','','','','','','',NULL,0,0,1,12,'Met during a congress at Dubai','',NULL,NULL,NULL,1),(2,'2010-07-08 22:44:50','2010-07-08 20:59:57',NULL,1,NULL,'MR','Freeman','Public','','','',200,11,NULL,'','','','','','','',NULL,NULL,0,0,1,1,'A friend that is a free contact not linked to any company',NULL,NULL,NULL,NULL,1),(3,'2010-07-08 22:59:02','2016-01-22 17:30:07',NULL,1,NULL,'MR','Mywife','Nicy','','','',NULL,11,'1980-10-03','','','','','','','','',NULL,1,0,1,12,'This is a private contact','',NULL,NULL,NULL,1),(4,'2010-07-09 00:16:58','2010-07-08 22:16:58',6,1,NULL,'MR','Rotchield','Evan','','','',NULL,6,NULL,'Bank director','','','','','','',NULL,NULL,0,0,1,1,'The bank director',NULL,NULL,NULL,NULL,1),(6,'2011-08-01 02:41:26','2016-01-22 17:29:53',17,1,NULL,'','Bookkeeper','Bob','99 account street','123456','BigTown',NULL,4,NULL,'book keeper','','','','','','','',NULL,0,0,1,12,'','',NULL,NULL,NULL,1),(7,'2016-07-30 16:11:06','2016-07-30 12:16:07',NULL,1,'','MR','Dad','','','','',NULL,14,'1967-09-04','','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(8,'2016-07-30 16:13:03','2016-07-30 12:15:58',NULL,1,'','MLE','Mom','','','','',NULL,14,NULL,'','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(9,'2016-07-30 16:14:41','2016-07-30 12:15:51',NULL,1,'','MR','Francky','','','89455','Virigia',NULL,205,'1980-07-09','Baker','555-98989898','','','','francky@example.com','','','',0,0,12,12,'','',NULL,NULL,NULL,1),(10,'2016-07-30 16:26:22','2016-07-30 12:52:38',10,1,'','MR','Eldy','','','33600','Pessac',NULL,1,'1972-10-10','Dolibarr project leader','','','','','eldy@example.com','','','ldestailleur_200x200.jpg',0,0,NULL,12,'','',NULL,NULL,NULL,1);
|
||||
INSERT INTO `llx_socpeople` VALUES (1,'2010-07-08 14:26:14','2016-01-16 15:07:51',1,1,NULL,'MR','Indra','Mahala','','','',297,117,'2010-07-08','Project leader','','','','','','','',NULL,0,0,1,12,'Met during a congress at Dubai','',NULL,NULL,NULL,1),(2,'2010-07-08 22:44:50','2010-07-08 20:59:57',NULL,1,NULL,'MR','Freeman','Public','','','',200,11,NULL,'','','','','','','',NULL,NULL,0,0,1,1,'A friend that is a free contact not linked to any company',NULL,NULL,NULL,NULL,1),(3,'2010-07-08 22:59:02','2016-01-22 17:30:07',NULL,1,NULL,'MR','Mywife','Nicy','','','',NULL,11,'1980-10-03','','','','','','','','',NULL,1,0,1,12,'This is a private contact','',NULL,NULL,NULL,1),(4,'2010-07-09 00:16:58','2010-07-08 22:16:58',6,1,NULL,'MR','Rotchield','Evan','','','',NULL,6,NULL,'Bank director','','','','','','',NULL,NULL,0,0,1,1,'The bank director',NULL,NULL,NULL,NULL,1),(6,'2011-08-01 02:41:26','2016-01-22 17:29:53',17,1,NULL,'','Bookkeeper','Bob','99 account street','123456','BigTown',NULL,4,NULL,'book keeper','','','','','','','',NULL,0,0,1,12,'','',NULL,NULL,NULL,1),(7,'2016-07-30 16:11:06','2016-07-30 12:16:07',NULL,1,'','MR','Dad','','','','',NULL,14,'1967-09-04','','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(8,'2016-07-30 16:13:03','2016-07-30 12:15:58',NULL,1,'','MLE','Mom','','','','',NULL,14,NULL,'','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(9,'2016-07-30 16:14:41','2016-07-30 12:15:51',NULL,1,'','MR','Francky','','','89455','Virigia',NULL,205,'1980-07-09','Baker','555-98989898','','','','francky@example.com','','','',0,0,12,12,'','',NULL,NULL,NULL,1),(10,'2016-07-30 16:26:22','2016-07-30 12:52:38',10,1,'','MR','Eldy','','','33600','Pessac',NULL,1,'1972-10-10','Dolibarr project leader','','','','','demo@example.com','','','ldestailleur_200x200.jpg',0,0,NULL,12,'','',NULL,NULL,NULL,1);
|
||||
/*!40000 ALTER TABLE `llx_socpeople` ENABLE KEYS */;
|
||||
UNLOCK TABLES;
|
||||
|
||||
|
||||
@@ -8260,7 +8260,7 @@ CREATE TABLE `llx_socpeople` (
|
||||
|
||||
LOCK TABLES `llx_socpeople` WRITE;
|
||||
/*!40000 ALTER TABLE `llx_socpeople` DISABLE KEYS */;
|
||||
INSERT INTO `llx_socpeople` VALUES (1,'2010-07-08 14:26:14','2016-01-16 15:07:51',1,1,NULL,'MR','Indra','Mahala','','','',297,117,'2010-07-08','Project leader','','','','','','','',NULL,0,0,1,12,'Met during a congress at Dubai','',NULL,NULL,NULL,1),(2,'2010-07-08 22:44:50','2010-07-08 20:59:57',NULL,1,NULL,'MR','Freeman','Public','','','',200,11,NULL,'','','','','','','',NULL,NULL,0,0,1,1,'A friend that is a free contact not linked to any company',NULL,NULL,NULL,NULL,1),(3,'2010-07-08 22:59:02','2016-01-22 17:30:07',NULL,1,NULL,'MR','Mywife','Nicy','','','',NULL,11,'1980-10-03','','','','','','','','',NULL,1,0,1,12,'This is a private contact','',NULL,NULL,NULL,1),(4,'2010-07-09 00:16:58','2010-07-08 22:16:58',6,1,NULL,'MR','Rotchield','Evan','','','',NULL,6,NULL,'Bank director','','','','','','',NULL,NULL,0,0,1,1,'The bank director',NULL,NULL,NULL,NULL,1),(6,'2011-08-01 02:41:26','2016-01-22 17:29:53',17,1,NULL,'','Bookkeeper','Bob','99 account street','123456','BigTown',NULL,4,NULL,'book keeper','','','','','','','',NULL,0,0,1,12,'','',NULL,NULL,NULL,1),(7,'2016-07-30 16:11:06','2016-07-30 12:16:07',NULL,1,'','MR','Dad','','','','',NULL,14,'1967-09-04','','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(8,'2016-07-30 16:13:03','2016-07-30 12:15:58',NULL,1,'','MLE','Mom','','','','',NULL,14,NULL,'','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(9,'2016-07-30 16:14:41','2016-07-30 12:15:51',NULL,1,'','MR','Francky','','','89455','Virigia',NULL,205,'1980-07-09','Baker','555-98989898','','','','francky@example.com','','','',0,0,12,12,'','',NULL,NULL,NULL,1),(10,'2016-07-30 16:26:22','2016-07-30 12:52:38',10,1,'','MR','Eldy','','','33600','Pessac',NULL,1,'1972-10-10','Dolibarr project leader','','','','','eldy@example.com','','','ldestailleur_200x200.jpg',0,0,NULL,12,'','',NULL,NULL,NULL,1),(11,'2017-05-12 13:16:36','2017-05-12 09:18:20',11,1,'','MR','Smith','Laurent','45 Big road','897','Seattle',NULL,11,NULL,'Director','','','','','','','','ldestailleur_200x200.png',0,0,12,12,'','',NULL,NULL,NULL,1),(12,'2017-05-12 13:19:31','2017-05-12 09:19:42',11,1,'','MR','Einstein','','','','',NULL,11,NULL,'Genius','333444555','','','','genius@example.com','','','Einstein.jpg',0,0,12,12,'','',NULL,NULL,NULL,1);
|
||||
INSERT INTO `llx_socpeople` VALUES (1,'2010-07-08 14:26:14','2016-01-16 15:07:51',1,1,NULL,'MR','Indra','Mahala','','','',297,117,'2010-07-08','Project leader','','','','','','','',NULL,0,0,1,12,'Met during a congress at Dubai','',NULL,NULL,NULL,1),(2,'2010-07-08 22:44:50','2010-07-08 20:59:57',NULL,1,NULL,'MR','Freeman','Public','','','',200,11,NULL,'','','','','','','',NULL,NULL,0,0,1,1,'A friend that is a free contact not linked to any company',NULL,NULL,NULL,NULL,1),(3,'2010-07-08 22:59:02','2016-01-22 17:30:07',NULL,1,NULL,'MR','Mywife','Nicy','','','',NULL,11,'1980-10-03','','','','','','','','',NULL,1,0,1,12,'This is a private contact','',NULL,NULL,NULL,1),(4,'2010-07-09 00:16:58','2010-07-08 22:16:58',6,1,NULL,'MR','Rotchield','Evan','','','',NULL,6,NULL,'Bank director','','','','','','',NULL,NULL,0,0,1,1,'The bank director',NULL,NULL,NULL,NULL,1),(6,'2011-08-01 02:41:26','2016-01-22 17:29:53',17,1,NULL,'','Bookkeeper','Bob','99 account street','123456','BigTown',NULL,4,NULL,'book keeper','','','','','','','',NULL,0,0,1,12,'','',NULL,NULL,NULL,1),(7,'2016-07-30 16:11:06','2016-07-30 12:16:07',NULL,1,'','MR','Dad','','','','',NULL,14,'1967-09-04','','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(8,'2016-07-30 16:13:03','2016-07-30 12:15:58',NULL,1,'','MLE','Mom','','','','',NULL,14,NULL,'','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(9,'2016-07-30 16:14:41','2016-07-30 12:15:51',NULL,1,'','MR','Francky','','','89455','Virigia',NULL,205,'1980-07-09','Baker','555-98989898','','','','francky@example.com','','','',0,0,12,12,'','',NULL,NULL,NULL,1),(10,'2016-07-30 16:26:22','2016-07-30 12:52:38',10,1,'','MR','Eldy','','','33600','Pessac',NULL,1,'1972-10-10','Dolibarr project leader','','','','','demo@example.com','','','ldestailleur_200x200.jpg',0,0,NULL,12,'','',NULL,NULL,NULL,1),(11,'2017-05-12 13:16:36','2017-05-12 09:18:20',11,1,'','MR','Smith','Laurent','45 Big road','897','Seattle',NULL,11,NULL,'Director','','','','','','','','ldestailleur_200x200.png',0,0,12,12,'','',NULL,NULL,NULL,1),(12,'2017-05-12 13:19:31','2017-05-12 09:19:42',11,1,'','MR','Einstein','','','','',NULL,11,NULL,'Genius','333444555','','','','genius@example.com','','','Einstein.jpg',0,0,12,12,'','',NULL,NULL,NULL,1);
|
||||
/*!40000 ALTER TABLE `llx_socpeople` ENABLE KEYS */;
|
||||
UNLOCK TABLES;
|
||||
|
||||
|
||||
@@ -8612,7 +8612,7 @@ CREATE TABLE `llx_socpeople` (
|
||||
|
||||
LOCK TABLES `llx_socpeople` WRITE;
|
||||
/*!40000 ALTER TABLE `llx_socpeople` DISABLE KEYS */;
|
||||
INSERT INTO `llx_socpeople` VALUES (1,'2010-07-08 14:26:14','2016-01-16 15:07:51',1,1,NULL,'MR','Indra','Mahala','','','',297,117,'2010-07-08','Project leader','','','','','','','',NULL,0,0,1,12,'Met during a congress at Dubai','',NULL,NULL,NULL,1),(2,'2010-07-08 22:44:50','2010-07-08 20:59:57',NULL,1,NULL,'MR','Freeman','Public','','','',200,11,NULL,'','','','','','','',NULL,NULL,0,0,1,1,'A friend that is a free contact not linked to any company',NULL,NULL,NULL,NULL,1),(3,'2010-07-08 22:59:02','2016-01-22 17:30:07',NULL,1,NULL,'MR','Mywife','Nicy','','','',NULL,11,'1980-10-03','','','','','','','','',NULL,1,0,1,12,'This is a private contact','',NULL,NULL,NULL,1),(4,'2010-07-09 00:16:58','2010-07-08 22:16:58',6,1,NULL,'MR','Rotchield','Evan','','','',NULL,6,NULL,'Bank director','','','','','','',NULL,NULL,0,0,1,1,'The bank director',NULL,NULL,NULL,NULL,1),(6,'2011-08-01 02:41:26','2016-01-22 17:29:53',17,1,NULL,'','Bookkeeper','Bob','99 account street','123456','BigTown',NULL,4,NULL,'book keeper','','','','','','','',NULL,0,0,1,12,'','',NULL,NULL,NULL,1),(7,'2016-07-30 16:11:06','2016-07-30 12:16:07',NULL,1,'','MR','Dad','','','','',NULL,14,'1967-09-04','','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(8,'2016-07-30 16:13:03','2016-07-30 12:15:58',NULL,1,'','MLE','Mom','','','','',NULL,14,NULL,'','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(9,'2016-07-30 16:14:41','2016-07-30 12:15:51',NULL,1,'','MR','Francky','','','89455','Virigia',NULL,205,'1980-07-09','Baker','555-98989898','','','','francky@example.com','','','',0,0,12,12,'','',NULL,NULL,NULL,1),(10,'2016-07-30 16:26:22','2016-07-30 12:52:38',10,1,'','MR','Eldy','','','33600','Pessac',NULL,1,'1972-10-10','Dolibarr project leader','','','','','eldy@example.com','','','ldestailleur_200x200.jpg',0,0,NULL,12,'','',NULL,NULL,NULL,1),(11,'2017-05-12 13:16:36','2017-05-12 09:18:20',11,1,'','MR','Smith','Laurent','45 Big road','897','Seattle',NULL,11,NULL,'Director','','','','','','','','ldestailleur_200x200.png',0,0,12,12,'','',NULL,NULL,NULL,1),(12,'2017-05-12 13:19:31','2017-05-12 09:19:42',11,1,'','MR','Einstein','','','','',NULL,11,NULL,'Genius','333444555','','','','genius@example.com','','','Einstein.jpg',0,0,12,12,'','',NULL,NULL,NULL,1);
|
||||
INSERT INTO `llx_socpeople` VALUES (1,'2010-07-08 14:26:14','2016-01-16 15:07:51',1,1,NULL,'MR','Indra','Mahala','','','',297,117,'2010-07-08','Project leader','','','','','','','',NULL,0,0,1,12,'Met during a congress at Dubai','',NULL,NULL,NULL,1),(2,'2010-07-08 22:44:50','2010-07-08 20:59:57',NULL,1,NULL,'MR','Freeman','Public','','','',200,11,NULL,'','','','','','','',NULL,NULL,0,0,1,1,'A friend that is a free contact not linked to any company',NULL,NULL,NULL,NULL,1),(3,'2010-07-08 22:59:02','2016-01-22 17:30:07',NULL,1,NULL,'MR','Mywife','Nicy','','','',NULL,11,'1980-10-03','','','','','','','','',NULL,1,0,1,12,'This is a private contact','',NULL,NULL,NULL,1),(4,'2010-07-09 00:16:58','2010-07-08 22:16:58',6,1,NULL,'MR','Rotchield','Evan','','','',NULL,6,NULL,'Bank director','','','','','','',NULL,NULL,0,0,1,1,'The bank director',NULL,NULL,NULL,NULL,1),(6,'2011-08-01 02:41:26','2016-01-22 17:29:53',17,1,NULL,'','Bookkeeper','Bob','99 account street','123456','BigTown',NULL,4,NULL,'book keeper','','','','','','','',NULL,0,0,1,12,'','',NULL,NULL,NULL,1),(7,'2016-07-30 16:11:06','2016-07-30 12:16:07',NULL,1,'','MR','Dad','','','','',NULL,14,'1967-09-04','','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(8,'2016-07-30 16:13:03','2016-07-30 12:15:58',NULL,1,'','MLE','Mom','','','','',NULL,14,NULL,'','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(9,'2016-07-30 16:14:41','2016-07-30 12:15:51',NULL,1,'','MR','Francky','','','89455','Virigia',NULL,205,'1980-07-09','Baker','555-98989898','','','','francky@example.com','','','',0,0,12,12,'','',NULL,NULL,NULL,1),(10,'2016-07-30 16:26:22','2016-07-30 12:52:38',10,1,'','MR','Eldy','','','33600','Pessac',NULL,1,'1972-10-10','Dolibarr project leader','','','','','demo@example.com','','','ldestailleur_200x200.jpg',0,0,NULL,12,'','',NULL,NULL,NULL,1),(11,'2017-05-12 13:16:36','2017-05-12 09:18:20',11,1,'','MR','Smith','Laurent','45 Big road','897','Seattle',NULL,11,NULL,'Director','','','','','','','','ldestailleur_200x200.png',0,0,12,12,'','',NULL,NULL,NULL,1),(12,'2017-05-12 13:19:31','2017-05-12 09:19:42',11,1,'','MR','Einstein','','','','',NULL,11,NULL,'Genius','333444555','','','','genius@example.com','','','Einstein.jpg',0,0,12,12,'','',NULL,NULL,NULL,1);
|
||||
/*!40000 ALTER TABLE `llx_socpeople` ENABLE KEYS */;
|
||||
UNLOCK TABLES;
|
||||
|
||||
|
||||
@@ -9181,7 +9181,7 @@ CREATE TABLE `llx_socpeople` (
|
||||
|
||||
LOCK TABLES `llx_socpeople` WRITE;
|
||||
/*!40000 ALTER TABLE `llx_socpeople` DISABLE KEYS */;
|
||||
INSERT INTO `llx_socpeople` VALUES (1,'2010-07-08 14:26:14','2016-01-16 15:07:51',1,1,NULL,'MR','Indra','Mahala','','','',297,117,'2010-07-08','Project leader','','','','','','','',NULL,0,0,1,12,'Met during a congress at Dubai','',NULL,NULL,NULL,1),(2,'2010-07-08 22:44:50','2010-07-08 20:59:57',NULL,1,NULL,'MR','Freeman','Public','','','',200,11,NULL,'','','','','','','',NULL,NULL,0,0,1,1,'A friend that is a free contact not linked to any company',NULL,NULL,NULL,NULL,1),(3,'2010-07-08 22:59:02','2016-01-22 17:30:07',NULL,1,NULL,'MR','Mywife','Nicy','','','',NULL,11,'1980-10-03','','','','','','','','',NULL,1,0,1,12,'This is a private contact','',NULL,NULL,NULL,1),(4,'2010-07-09 00:16:58','2010-07-08 22:16:58',6,1,NULL,'MR','Rotchield','Evan','','','',NULL,6,NULL,'Bank director','','','','','','',NULL,NULL,0,0,1,1,'The bank director',NULL,NULL,NULL,NULL,1),(6,'2011-08-01 02:41:26','2016-01-22 17:29:53',17,1,NULL,'','Bookkeeper','Bob','99 account street','123456','BigTown',NULL,4,NULL,'book keeper','','','','','','','',NULL,0,0,1,12,'','',NULL,NULL,NULL,1),(7,'2016-07-30 16:11:06','2016-07-30 12:16:07',NULL,1,'','MR','Dad','','','','',NULL,14,'1967-09-04','','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(8,'2016-07-30 16:13:03','2016-07-30 12:15:58',NULL,1,'','MLE','Mom','','','','',NULL,14,NULL,'','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(9,'2016-07-30 16:14:41','2016-07-30 12:15:51',NULL,1,'','MR','Francky','','','89455','Virigia',NULL,205,'1980-07-09','Baker','555-98989898','','','','francky@example.com','','','',0,0,12,12,'','',NULL,NULL,NULL,1),(10,'2016-07-30 16:26:22','2016-07-30 12:52:38',10,1,'','MR','Eldy','','','33600','Pessac',NULL,1,'1972-10-10','Dolibarr project leader','','','','','eldy@example.com','','','ldestailleur_200x200.jpg',0,0,NULL,12,'','',NULL,NULL,NULL,1),(11,'2017-05-12 13:16:36','2017-05-12 09:18:20',11,1,'','MR','Smith','Laurent','45 Big road','897','Seattle',NULL,11,NULL,'Director','','','','','','','','ldestailleur_200x200.png',0,0,12,12,'','',NULL,NULL,NULL,1),(12,'2017-05-12 13:19:31','2017-05-12 09:19:42',11,1,'','MR','Einstein','','','','',NULL,11,NULL,'Genius','333444555','','','','genius@example.com','','','Einstein.jpg',0,0,12,12,'','',NULL,NULL,NULL,1);
|
||||
INSERT INTO `llx_socpeople` VALUES (1,'2010-07-08 14:26:14','2016-01-16 15:07:51',1,1,NULL,'MR','Indra','Mahala','','','',297,117,'2010-07-08','Project leader','','','','','','','',NULL,0,0,1,12,'Met during a congress at Dubai','',NULL,NULL,NULL,1),(2,'2010-07-08 22:44:50','2010-07-08 20:59:57',NULL,1,NULL,'MR','Freeman','Public','','','',200,11,NULL,'','','','','','','',NULL,NULL,0,0,1,1,'A friend that is a free contact not linked to any company',NULL,NULL,NULL,NULL,1),(3,'2010-07-08 22:59:02','2016-01-22 17:30:07',NULL,1,NULL,'MR','Mywife','Nicy','','','',NULL,11,'1980-10-03','','','','','','','','',NULL,1,0,1,12,'This is a private contact','',NULL,NULL,NULL,1),(4,'2010-07-09 00:16:58','2010-07-08 22:16:58',6,1,NULL,'MR','Rotchield','Evan','','','',NULL,6,NULL,'Bank director','','','','','','',NULL,NULL,0,0,1,1,'The bank director',NULL,NULL,NULL,NULL,1),(6,'2011-08-01 02:41:26','2016-01-22 17:29:53',17,1,NULL,'','Bookkeeper','Bob','99 account street','123456','BigTown',NULL,4,NULL,'book keeper','','','','','','','',NULL,0,0,1,12,'','',NULL,NULL,NULL,1),(7,'2016-07-30 16:11:06','2016-07-30 12:16:07',NULL,1,'','MR','Dad','','','','',NULL,14,'1967-09-04','','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(8,'2016-07-30 16:13:03','2016-07-30 12:15:58',NULL,1,'','MLE','Mom','','','','',NULL,14,NULL,'','','','','','','','','',1,0,12,12,'','',NULL,NULL,NULL,1),(9,'2016-07-30 16:14:41','2016-07-30 12:15:51',NULL,1,'','MR','Francky','','','89455','Virigia',NULL,205,'1980-07-09','Baker','555-98989898','','','','francky@example.com','','','',0,0,12,12,'','',NULL,NULL,NULL,1),(10,'2016-07-30 16:26:22','2016-07-30 12:52:38',10,1,'','MR','Eldy','','','33600','Pessac',NULL,1,'1972-10-10','Dolibarr project leader','','','','','demo@example.com','','','ldestailleur_200x200.jpg',0,0,NULL,12,'','',NULL,NULL,NULL,1),(11,'2017-05-12 13:16:36','2017-05-12 09:18:20',11,1,'','MR','Smith','Laurent','45 Big road','897','Seattle',NULL,11,NULL,'Director','','','','','','','','ldestailleur_200x200.png',0,0,12,12,'','',NULL,NULL,NULL,1),(12,'2017-05-12 13:19:31','2017-05-12 09:19:42',11,1,'','MR','Einstein','','','','',NULL,11,NULL,'Genius','333444555','','','','genius@example.com','','','Einstein.jpg',0,0,12,12,'','',NULL,NULL,NULL,1);
|
||||
/*!40000 ALTER TABLE `llx_socpeople` ENABLE KEYS */;
|
||||
UNLOCK TABLES;
|
||||
|
||||
|
||||
14172
dev/initdemo/mysqldump_dolibarr_8.0.0.sql
Normal file
14172
dev/initdemo/mysqldump_dolibarr_8.0.0.sql
Normal file
File diff suppressed because one or more lines are too long
13954
dev/initdemo/mysqldump_dolibarr_9.0.0.sql
Normal file
13954
dev/initdemo/mysqldump_dolibarr_9.0.0.sql
Normal file
File diff suppressed because one or more lines are too long
@@ -3,7 +3,7 @@
|
||||
# Script to remove setup of a Dolibarr installation.
|
||||
# Note: "dialog" tool need to be available.
|
||||
#
|
||||
# Regis Houssin - regis.houssin@capnetworks.com
|
||||
# Regis Houssin - regis.houssin@inodbox.com
|
||||
# Laurent Destailleur - eldy@users.sourceforge.net
|
||||
#------------------------------------------------------
|
||||
# WARNING: This script erase setup of instance,
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
# Script to extrac a database with demo values.
|
||||
# Note: "dialog" tool need to be available if no parameter provided.
|
||||
#
|
||||
# Regis Houssin - regis.houssin@capnetworks.com
|
||||
# Regis Houssin - regis.houssin@inodbox.com
|
||||
# Laurent Destailleur - eldy@users.sourceforge.net
|
||||
#------------------------------------------------------
|
||||
# Usage: savedemo.sh
|
||||
@@ -171,6 +171,8 @@ export list="
|
||||
--ignore-table=$base.llx_abonne_extrafields
|
||||
--ignore-table=$base.llx_abonne_type
|
||||
--ignore-table=$base.llx_abonnement
|
||||
--ignore-table=$base.llx_accountingaccount
|
||||
--ignore-table=$base.llx_accountingsystem
|
||||
--ignore-table=$base.llx_advanced_extrafields
|
||||
--ignore-table=$base.llx_advanced_extrafields_options
|
||||
--ignore-table=$base.llx_advanced_extrafields_values
|
||||
@@ -189,6 +191,9 @@ export list="
|
||||
--ignore-table=$base.llx_c_dolicloud_plans
|
||||
--ignore-table=$base.llx_c_pays
|
||||
--ignore-table=$base.llx_c_source
|
||||
--ignore-table=$base.llx_c_ticketsup_category
|
||||
--ignore-table=$base.llx_c_ticketsup_severity
|
||||
--ignore-table=$base.llx_c_ticketsup_type
|
||||
--ignore-table=$base.llx_cabinetmed_c_banques
|
||||
--ignore-table=$base.llx_cabinetmed_c_ccam
|
||||
--ignore-table=$base.llx_cabinetmed_c_examconclusion
|
||||
@@ -246,6 +251,8 @@ export list="
|
||||
--ignore-table=$base.llx_residence
|
||||
--ignore-table=$base.llx_residence_building
|
||||
--ignore-table=$base.llx_residence_building_links
|
||||
--ignore-table=$base.llx_societe_rib2
|
||||
--ignore-table=$base.llx_ticketsup
|
||||
--ignore-table=$base.llx_ultimatepdf
|
||||
--ignore-table=$base.llx_update_modules
|
||||
--ignore-table=$base.llx_ventilation_achat
|
||||
|
||||
@@ -41,15 +41,15 @@ $passwordbase=isset($argv[6])?$argv[6]:'';
|
||||
|
||||
// Include Dolibarr environment
|
||||
$res=0;
|
||||
if (! $res && file_exists($path."../../master.inc.php")) $res=@include($path."../../master.inc.php");
|
||||
if (! $res && file_exists($path."../../htdocs/master.inc.php")) $res=@include($path."../../htdocs/master.inc.php");
|
||||
if (! $res && file_exists("../master.inc.php")) $res=@include("../master.inc.php");
|
||||
if (! $res && file_exists("../../master.inc.php")) $res=@include("../../master.inc.php");
|
||||
if (! $res && file_exists("../../../master.inc.php")) $res=@include("../../../master.inc.php");
|
||||
if (! $res && preg_match('/\/nltechno([^\/]*)\//',$_SERVER["PHP_SELF"],$reg)) $res=@include($path."../../../dolibarr".$reg[1]."/htdocs/master.inc.php"); // Used on dev env only
|
||||
if (! $res && preg_match('/\/nltechno([^\/]*)\//',$_SERVER["PHP_SELF"],$reg)) $res=@include("../../../dolibarr".$reg[1]."/htdocs/master.inc.php"); // Used on dev env only
|
||||
if (! $res) die ("Failed to include master.inc.php file\n");
|
||||
include_once(DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php');
|
||||
if (! $res && file_exists($path."../../master.inc.php")) $res=@include $path."../../master.inc.php";
|
||||
if (! $res && file_exists($path."../../htdocs/master.inc.php")) $res=@include $path."../../htdocs/master.inc.php";
|
||||
if (! $res && file_exists("../master.inc.php")) $res=@include "../master.inc.php";
|
||||
if (! $res && file_exists("../../master.inc.php")) $res=@include "../../master.inc.php";
|
||||
if (! $res && file_exists("../../../master.inc.php")) $res=@include "../../../master.inc.php";
|
||||
if (! $res && preg_match('/\/nltechno([^\/]*)\//', $_SERVER["PHP_SELF"], $reg)) $res=@include $path."../../../dolibarr".$reg[1]."/htdocs/master.inc.php"; // Used on dev env only
|
||||
if (! $res && preg_match('/\/nltechno([^\/]*)\//', $_SERVER["PHP_SELF"], $reg)) $res=@include "../../../dolibarr".$reg[1]."/htdocs/master.inc.php"; // Used on dev env only
|
||||
if (! $res) die("Failed to include master.inc.php file\n");
|
||||
include_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php';
|
||||
|
||||
|
||||
/*
|
||||
@@ -58,7 +58,7 @@ include_once(DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php');
|
||||
|
||||
$login='';
|
||||
$server='';
|
||||
if (preg_match('/^(.*)@(.*):(.*)$/',$sourceserver,$reg))
|
||||
if (preg_match('/^(.*)@(.*):(.*)$/', $sourceserver, $reg))
|
||||
{
|
||||
$login=$reg[1];
|
||||
$server=$reg[2];
|
||||
@@ -84,7 +84,7 @@ print 'SFTP connect string : '.$sftpconnectstring."\n";
|
||||
|
||||
// SFTP connect
|
||||
if (! function_exists("ssh2_connect")) {
|
||||
dol_print_error('','ssh2_connect function does not exists'); exit(1);
|
||||
dol_print_error('', 'ssh2_connect function does not exists'); exit(1);
|
||||
}
|
||||
|
||||
$connection = ssh2_connect($server, 22);
|
||||
@@ -92,7 +92,7 @@ if ($connection)
|
||||
{
|
||||
if (! @ssh2_auth_password($connection, $login, $password))
|
||||
{
|
||||
dol_syslog("Could not authenticate with username ".$login." . and password ".preg_replace('/./', '*', $password),LOG_ERR);
|
||||
dol_syslog("Could not authenticate with username ".$login." . and password ".preg_replace('/./', '*', $password), LOG_ERR);
|
||||
exit(-5);
|
||||
}
|
||||
else
|
||||
@@ -112,11 +112,11 @@ if ($connection)
|
||||
ssh2_scp_recv($connection, $sourcefile, $targetdir.$targetfile);
|
||||
|
||||
$fullcommand="cat ".$targetdir.$targetfile." | mysql -h".$databaseserver." -u".$loginbase." -p".$passwordbase." -D ".$database;
|
||||
if (preg_match('/\.bz2$/',$targetfile))
|
||||
if (preg_match('/\.bz2$/', $targetfile))
|
||||
{
|
||||
$fullcommand="bzip2 -c -d ".$targetdir.$targetfile." | mysql -h".$databaseserver." -u".$loginbase." -p".$passwordbase." -D ".$database;
|
||||
}
|
||||
if (preg_match('/\.gz$/',$targetfile))
|
||||
if (preg_match('/\.gz$/', $targetfile))
|
||||
{
|
||||
$fullcommand="gzip -d ".$targetdir.$targetfile." | mysql -h".$databaseserver." -u".$loginbase." -p".$passwordbase." -D ".$database;
|
||||
}
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
* or see http://www.gnu.org/
|
||||
*
|
||||
*
|
||||
* Get a distant dump file and load it into a mysql database
|
||||
*/
|
||||
|
||||
@@ -36,15 +36,15 @@ $confirm=isset($argv[1])?$argv[1]:'';
|
||||
|
||||
// Include Dolibarr environment
|
||||
$res=0;
|
||||
if (! $res && file_exists($path."../../master.inc.php")) $res=@include($path."../../master.inc.php");
|
||||
if (! $res && file_exists($path."../../htdocs/master.inc.php")) $res=@include($path."../../htdocs/master.inc.php");
|
||||
if (! $res && file_exists("../master.inc.php")) $res=@include("../master.inc.php");
|
||||
if (! $res && file_exists("../../master.inc.php")) $res=@include("../../master.inc.php");
|
||||
if (! $res && file_exists("../../../master.inc.php")) $res=@include("../../../master.inc.php");
|
||||
if (! $res && preg_match('/\/nltechno([^\/]*)\//',$_SERVER["PHP_SELF"],$reg)) $res=@include($path."../../../dolibarr".$reg[1]."/htdocs/master.inc.php"); // Used on dev env only
|
||||
if (! $res && preg_match('/\/nltechno([^\/]*)\//',$_SERVER["PHP_SELF"],$reg)) $res=@include("../../../dolibarr".$reg[1]."/htdocs/master.inc.php"); // Used on dev env only
|
||||
if (! $res) die ("Failed to include master.inc.php file\n");
|
||||
include_once(DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php');
|
||||
if (! $res && file_exists($path."../../master.inc.php")) $res=@include $path."../../master.inc.php";
|
||||
if (! $res && file_exists($path."../../htdocs/master.inc.php")) $res=@include $path."../../htdocs/master.inc.php";
|
||||
if (! $res && file_exists("../master.inc.php")) $res=@include "../master.inc.php";
|
||||
if (! $res && file_exists("../../master.inc.php")) $res=@include "../../master.inc.php";
|
||||
if (! $res && file_exists("../../../master.inc.php")) $res=@include "../../../master.inc.php";
|
||||
if (! $res && preg_match('/\/nltechno([^\/]*)\//', $_SERVER["PHP_SELF"], $reg)) $res=@include $path."../../../dolibarr".$reg[1]."/htdocs/master.inc.php"; // Used on dev env only
|
||||
if (! $res && preg_match('/\/nltechno([^\/]*)\//', $_SERVER["PHP_SELF"], $reg)) $res=@include "../../../dolibarr".$reg[1]."/htdocs/master.inc.php"; // Used on dev env only
|
||||
if (! $res) die("Failed to include master.inc.php file\n");
|
||||
include_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php';
|
||||
|
||||
|
||||
/*
|
||||
@@ -74,7 +74,7 @@ $tables=array(
|
||||
|
||||
$year=2010;
|
||||
$currentyear=$tmp['year'];
|
||||
while ($year <= $currentyear)
|
||||
while ($year <= $currentyear)
|
||||
{
|
||||
//$year=2021;
|
||||
$delta=($currentyear - $year);
|
||||
@@ -84,7 +84,7 @@ while ($year <= $currentyear)
|
||||
{
|
||||
foreach($tables as $tablekey => $tableval)
|
||||
{
|
||||
print "\nCorrect ".$tablekey." for year ".$year." and move them to current year ".$currentyear." ";
|
||||
print "\nCorrect ".$tablekey." for year ".$year." and move them to current year ".$currentyear." ";
|
||||
$sql="select rowid from ".MAIN_DB_PREFIX.$tablekey." where ".$tableval[0]." between '".$year."-01-01' and '".$year."-12-31' and ".$tableval[0]." < DATE_ADD(NOW(), INTERVAL -1 YEAR)";
|
||||
//$sql="select rowid from ".MAIN_DB_PREFIX.$tablekey." where ".$tableval[0]." between '".$year."-01-01' and '".$year."-12-31' and ".$tableval[0]." > NOW()";
|
||||
$resql = $db->query($sql);
|
||||
@@ -110,14 +110,14 @@ while ($year <= $currentyear)
|
||||
//print $sql2."\n";
|
||||
$resql2 = $db->query($sql2);
|
||||
if (! $resql2) dol_print_error($db);
|
||||
}
|
||||
}
|
||||
$i++;
|
||||
}
|
||||
}
|
||||
else dol_print_error($db);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
$year++;
|
||||
}
|
||||
|
||||
|
||||
2
dev/resources/dbmodel/README
Normal file
2
dev/resources/dbmodel/README
Normal file
@@ -0,0 +1,2 @@
|
||||
This directory contains the file with the graphical database structure.
|
||||
It can be read with MySQL Workbench software.
|
||||
@@ -1,12 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<uml:Model xmi:version="2.1" xmlns:xmi="http://schema.omg.org/spec/XMI/2.1" xmlns:uml="http://www.eclipse.org/uml2/2.1.0/UML" xmi:id="_qb8akM37EdqwVrslYOdUDA">
|
||||
<packagedElement xmi:type="uml:Package" xmi:id="_w8IxIM37EdqwVrslYOdUDA" name="dolibarr">
|
||||
<packagedElement xmi:type="uml:Package" xmi:id="_T5aZ4FK9Ed60vaZbVikprw" name="OrdersModule"/>
|
||||
<packagedElement xmi:type="uml:Package" xmi:id="_ZhuGMlK9Ed60vaZbVikprw" name="InvoiceModule"/>
|
||||
<packagedElement xmi:type="uml:Package" xmi:id="_cf3SUlK9Ed60vaZbVikprw" name="UserModule"/>
|
||||
<packagedElement xmi:type="uml:Package" xmi:id="_maM0glK9Ed60vaZbVikprw" name="FoundationModule"/>
|
||||
<packagedElement xmi:type="uml:Package" xmi:id="_oqTO4lK9Ed60vaZbVikprw" name="ContractsModule"/>
|
||||
<packagedElement xmi:type="uml:Package" xmi:id="_rEq_klK9Ed60vaZbVikprw" name="ProposalsModule"/>
|
||||
<packagedElement xmi:type="uml:Package" xmi:id="_vxYmUlK9Ed60vaZbVikprw" name="EMailingManagement"/>
|
||||
</packagedElement>
|
||||
</uml:Model>
|
||||
@@ -1,53 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<diagrams:Diagrams xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:di="http://www.topcased.org/DI/1.0" xmlns:diagrams="http://www.topcased.org/Diagrams/1.0" xmi:id="_SI6FkFK9Ed60vaZbVikprw" activeDiagram="_SI6FkVK9Ed60vaZbVikprw">
|
||||
<model href="dolibarr.uml#_w8IxIM37EdqwVrslYOdUDA"/>
|
||||
<diagrams xmi:id="_SI6FkVK9Ed60vaZbVikprw" position="0,0" size="100,100" name="dolibarr" viewport="0,0">
|
||||
<property xmi:id="_SJ9OcFK9Ed60vaZbVikprw" key="pageFormatName" value="A4"/>
|
||||
<property xmi:id="_SJ9OcVK9Ed60vaZbVikprw" key="diagramWidth" value="840"/>
|
||||
<property xmi:id="_SJ9OclK9Ed60vaZbVikprw" key="diagramHeight" value="1188"/>
|
||||
<property xmi:id="_SJ9Oc1K9Ed60vaZbVikprw" key="pageMarginName" value="Small Margin"/>
|
||||
<property xmi:id="_SJ9OdFK9Ed60vaZbVikprw" key="diagramTopMargin" value="20"/>
|
||||
<property xmi:id="_SJ9OdVK9Ed60vaZbVikprw" key="diagramBottomMargin" value="20"/>
|
||||
<property xmi:id="_SJ9OdlK9Ed60vaZbVikprw" key="diagramLeftMargin" value="20"/>
|
||||
<property xmi:id="_SJ9Od1K9Ed60vaZbVikprw" key="diagramRightMargin" value="20"/>
|
||||
<property xmi:id="_SJ9OeFK9Ed60vaZbVikprw" key="orientation" value="portrait"/>
|
||||
<semanticModel xsi:type="di:EMFSemanticModelBridge" xmi:id="_SI6FklK9Ed60vaZbVikprw" presentation="org.topcased.modeler.uml.classdiagram">
|
||||
<element href="dolibarr.uml#_w8IxIM37EdqwVrslYOdUDA"/>
|
||||
</semanticModel>
|
||||
<contained xsi:type="di:GraphNode" xmi:id="_T2b-YFK9Ed60vaZbVikprw" position="15,190" size="176,81">
|
||||
<semanticModel xsi:type="di:EMFSemanticModelBridge" xmi:id="_T2b-YVK9Ed60vaZbVikprw" presentation="default">
|
||||
<element href="dolibarr.uml#_T5aZ4FK9Ed60vaZbVikprw"/>
|
||||
</semanticModel>
|
||||
</contained>
|
||||
<contained xsi:type="di:GraphNode" xmi:id="_ZhuGMFK9Ed60vaZbVikprw" position="15,118" size="177,68">
|
||||
<semanticModel xsi:type="di:EMFSemanticModelBridge" xmi:id="_ZhuGMVK9Ed60vaZbVikprw" presentation="default">
|
||||
<element href="dolibarr.uml#_ZhuGMlK9Ed60vaZbVikprw"/>
|
||||
</semanticModel>
|
||||
</contained>
|
||||
<contained xsi:type="di:GraphNode" xmi:id="_cf3SUFK9Ed60vaZbVikprw" position="15,10" size="174,81">
|
||||
<semanticModel xsi:type="di:EMFSemanticModelBridge" xmi:id="_cf3SUVK9Ed60vaZbVikprw" presentation="default">
|
||||
<element href="dolibarr.uml#_cf3SUlK9Ed60vaZbVikprw"/>
|
||||
</semanticModel>
|
||||
</contained>
|
||||
<contained xsi:type="di:GraphNode" xmi:id="_maM0gFK9Ed60vaZbVikprw" position="291,118" size="145,73">
|
||||
<semanticModel xsi:type="di:EMFSemanticModelBridge" xmi:id="_maM0gVK9Ed60vaZbVikprw" presentation="default">
|
||||
<element href="dolibarr.uml#_maM0glK9Ed60vaZbVikprw"/>
|
||||
</semanticModel>
|
||||
</contained>
|
||||
<contained xsi:type="di:GraphNode" xmi:id="_oqTO4FK9Ed60vaZbVikprw" position="15,274" size="179,80">
|
||||
<semanticModel xsi:type="di:EMFSemanticModelBridge" xmi:id="_oqTO4VK9Ed60vaZbVikprw" presentation="default">
|
||||
<element href="dolibarr.uml#_oqTO4lK9Ed60vaZbVikprw"/>
|
||||
</semanticModel>
|
||||
</contained>
|
||||
<contained xsi:type="di:GraphNode" xmi:id="_rEq_kFK9Ed60vaZbVikprw" position="15,358" size="181,73">
|
||||
<semanticModel xsi:type="di:EMFSemanticModelBridge" xmi:id="_rEq_kVK9Ed60vaZbVikprw" presentation="default">
|
||||
<element href="dolibarr.uml#_rEq_klK9Ed60vaZbVikprw"/>
|
||||
</semanticModel>
|
||||
</contained>
|
||||
<contained xsi:type="di:GraphNode" xmi:id="_vxYmUFK9Ed60vaZbVikprw" position="15,490" size="181,80">
|
||||
<semanticModel xsi:type="di:EMFSemanticModelBridge" xmi:id="_vxYmUVK9Ed60vaZbVikprw" presentation="default">
|
||||
<element href="dolibarr.uml#_vxYmUlK9Ed60vaZbVikprw"/>
|
||||
</semanticModel>
|
||||
</contained>
|
||||
</diagrams>
|
||||
</diagrams:Diagrams>
|
||||
Binary file not shown.
1
dev/resources/facturx-zugferd/README.txt
Normal file
1
dev/resources/facturx-zugferd/README.txt
Normal file
@@ -0,0 +1 @@
|
||||
See https://github.com/atgp/factur-x
|
||||
BIN
dev/resources/iso-normes/Accountancy-format_Ebp_txt.pdf
Normal file
BIN
dev/resources/iso-normes/Accountancy-format_Ebp_txt.pdf
Normal file
Binary file not shown.
@@ -4,6 +4,7 @@
|
||||
<description>Dolibarr coding standard.</description>
|
||||
|
||||
<exclude-pattern type="relative">build/html</exclude-pattern>
|
||||
<exclude-pattern type="relative">build/aps</exclude-pattern>
|
||||
<exclude-pattern type="relative">documents</exclude-pattern>
|
||||
<exclude-pattern type="relative">htdocs/custom</exclude-pattern>
|
||||
<exclude-pattern type="relative">htdocs/includes</exclude-pattern>
|
||||
@@ -11,42 +12,27 @@
|
||||
<exclude-pattern type="relative">*/nltechno*</exclude-pattern>
|
||||
<exclude-pattern type="relative">*/htdocs/includes</exclude-pattern>
|
||||
|
||||
<!-- List of all tests -->
|
||||
<!-- List of all tests -->
|
||||
|
||||
|
||||
|
||||
<!-- Rules from Internal Standard -->
|
||||
|
||||
|
||||
<rule ref="Internal.NoCodeFound">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
|
||||
|
||||
<!-- Rules from Generic Standard -->
|
||||
|
||||
<rule ref="Generic.CodeAnalysis.EmptyStatement" />
|
||||
|
||||
<rule ref="Generic.CodeAnalysis.EmptyStatement.DetectedCATCH">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
<rule ref="Generic.CodeAnalysis.EmptyStatement.DetectedFOREACH">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
<rule ref="Generic.CodeAnalysis.EmptyStatement.DetectedIF">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
<rule ref="Generic.CodeAnalysis.EmptyStatement.DetectedELSE">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
<rule ref="Generic.CodeAnalysis.EmptyStatement.DetectedELSEIF">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
|
||||
<rule ref="Generic.CodeAnalysis.EmptyStatement.NotAllowed">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
<rule ref="Generic.CodeAnalysis.EmptyStatement.NotAllowedWarning">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
<!-- Rules from Generic Standard -->
|
||||
|
||||
<rule ref="Generic.CodeAnalysis.EmptyStatement">
|
||||
<exclude name="Generic.CodeAnalysis.EmptyStatement.DetectedIf"/>
|
||||
<exclude name="Generic.CodeAnalysis.EmptyStatement.DetectedElse"/>
|
||||
<exclude name="Generic.CodeAnalysis.EmptyStatement.DetectedElseif"/>
|
||||
<exclude name="Generic.CodeAnalysis.EmptyStatement.DetectedCatch"/>
|
||||
<exclude name="Generic.CodeAnalysis.EmptyStatement.DetectedForeach"/>
|
||||
<exclude name="Generic.CodeAnalysis.EmptyStatement.NotAllowed"/>
|
||||
<exclude name="Generic.CodeAnalysis.EmptyStatement.NotAllowedWarning"/>
|
||||
</rule>
|
||||
|
||||
<!-- <rule ref="Generic.CodeAnalysis.ForLoopShouldBeWhileLoop" /> -->
|
||||
|
||||
@@ -62,6 +48,21 @@
|
||||
<rule ref="Generic.CodeAnalysis.UnusedFunctionParameter.Found">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
<rule ref="Generic.CodeAnalysis.UnusedFunctionParameter.FoundBeforeLastUsed">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
<rule ref="Generic.CodeAnalysis.UnusedFunctionParameter.FoundAfterLastUsed">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
<rule ref="Generic.CodeAnalysis.UnusedFunctionParameter.FoundInExtendedClass">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
<rule ref="Generic.CodeAnalysis.UnusedFunctionParameter.FoundInExtendedClassAfterLastUsed">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
<rule ref="Generic.CodeAnalysis.UnusedFunctionParameter.FoundInExtendedClassBeforeLastUsed">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
|
||||
<rule ref="Generic.CodeAnalysis.UselessOverridingMethod" />
|
||||
|
||||
@@ -82,7 +83,7 @@
|
||||
<!-- Lines can be 85 chars long, but never show errors -->
|
||||
<rule ref="Generic.Files.LineLength">
|
||||
<properties>
|
||||
<property name="lineLimit" value="1000" />
|
||||
<property name="lineLimit" value="500" />
|
||||
<property name="absoluteLineLimit" value="0" />
|
||||
</properties>
|
||||
</rule>
|
||||
@@ -109,16 +110,13 @@
|
||||
<rule ref="Generic.Functions.CallTimePassByReference" />
|
||||
|
||||
<rule ref="Generic.Functions.FunctionCallArgumentSpacing" />
|
||||
<rule ref="Generic.Functions.FunctionCallArgumentSpacing.NoSpaceAfterComma">
|
||||
<rule ref="Generic.Functions.FunctionCallArgumentSpacing.NoSpaceBeforeEquals">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
<rule ref="Generic.Functions.FunctionCallArgumentSpacing.NoSpaceBeforeEquals">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
<rule ref="Generic.Functions.FunctionCallArgumentSpacing.NoSpaceAfterEquals">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
<rule ref="Generic.Functions.FunctionCallArgumentSpacing.TooMuchSpaceAfterComma">
|
||||
<rule ref="Generic.Functions.FunctionCallArgumentSpacing.TooMuchSpaceAfterComma"> <!-- We don't want this rule, we want to be able to align params on several similare functions on different lines -->
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
|
||||
@@ -138,9 +136,7 @@
|
||||
|
||||
<rule ref="Generic.NamingConventions.ConstructorName" />
|
||||
<!-- Check if we use PHP4 constructor instead of __construct() -->
|
||||
<rule ref="Generic.NamingConventions.ConstructorName.OldStyle">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
<rule ref="Generic.NamingConventions.ConstructorName.OldStyle" />
|
||||
|
||||
<rule ref="Generic.NamingConventions.UpperCaseConstantName" />
|
||||
|
||||
@@ -148,7 +144,7 @@
|
||||
<rule ref="Generic.PHP.DeprecatedFunctions.Deprecated">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
|
||||
|
||||
<rule ref="Generic.PHP.DisallowShortOpenTag" />
|
||||
|
||||
<rule ref="Generic.PHP.ForbiddenFunctions" />
|
||||
@@ -156,23 +152,54 @@
|
||||
<!-- Warning when using @ before functions -->
|
||||
<!-- <rule ref="Generic.PHP.NoSilencedErrors" /> -->
|
||||
|
||||
<!-- Say if null, true, false must be uppercase -->
|
||||
<!-- <rule ref="Generic.PHP.UpperCaseConstant" /> -->
|
||||
<!-- Say if null, true, false must be uppercase (Rule 2.5 of PSR2 https://www.php-fig.org/psr/psr-2/) -->
|
||||
<rule ref="Generic.PHP.LowerCaseConstant" />
|
||||
|
||||
<rule ref="Generic.Strings.UnnecessaryStringConcat" />
|
||||
|
||||
<rule ref="Generic.Strings.UnnecessaryStringConcat.Found">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
|
||||
|
||||
<!-- Disallow usage of tab -->
|
||||
<!-- <rule ref="Generic.WhiteSpace.DisallowTabIndent" /> -->
|
||||
|
||||
<!-- Check indent are done with spaces and wiht correct number -->
|
||||
<!-- Check indent are done with spaces and with correct number -->
|
||||
<!-- Disabled as this does not support tab -->
|
||||
<!-- <rule ref="Generic.WhiteSpace.ScopeIndent" /> -->
|
||||
|
||||
<rule ref="Squiz.WhiteSpace.ScopeClosingBrace.Indent" />
|
||||
|
||||
<!-- There MUST NOT be trailing whitespace at the end of non-blank lines. -->
|
||||
<rule ref="Squiz.WhiteSpace.SuperfluousWhitespace">
|
||||
<properties>
|
||||
<property name="ignoreBlankLines" value="true"/>
|
||||
</properties>
|
||||
</rule>
|
||||
<rule ref="Squiz.WhiteSpace.SuperfluousWhitespace.StartFile">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
<rule ref="Squiz.WhiteSpace.SuperfluousWhitespace.EndFile">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
<rule ref="Squiz.WhiteSpace.SuperfluousWhitespace.EmptyLines">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
<rule ref="Squiz.WhiteSpace.ControlStructureSpacing.SpacingBeforeClose" />
|
||||
|
||||
<rule ref="Squiz.ControlStructures.ForEachLoopDeclaration.SpaceAfterOpen" />
|
||||
<rule ref="Squiz.ControlStructures.ForEachLoopDeclaration.SpaceBeforeClose" />
|
||||
|
||||
<rule ref="Squiz.Functions.MultiLineFunctionDeclaration" />
|
||||
<rule ref="Squiz.Functions.FunctionDeclarationArgumentSpacing">
|
||||
<properties>
|
||||
<property name="equalsSpacing" value="1"/>
|
||||
</properties>
|
||||
</rule>
|
||||
<rule ref="Squiz.Functions.FunctionDeclarationArgumentSpacing.SpacingAfterHint">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
<rule ref="Squiz.Scope.MethodScope.Missing" />
|
||||
|
||||
<!-- Rules from PEAR Standard -->
|
||||
|
||||
@@ -187,7 +214,7 @@
|
||||
<rule ref="PEAR.Commenting.ClassComment.Missing">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
|
||||
|
||||
<rule ref="PEAR.Commenting.ClassComment.MissingTag">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
@@ -207,14 +234,14 @@
|
||||
<rule ref="PEAR.Commenting.ClassComment.MissingLinkTag">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
|
||||
|
||||
<rule ref="PEAR.Commenting.ClassComment.MissingPackageTag">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
|
||||
|
||||
|
||||
<!--
|
||||
|
||||
|
||||
<!--
|
||||
<rule ref="PEAR.Commenting.FileComment" />
|
||||
<rule ref="PEAR.Commenting.FileComment.WrongStyle">
|
||||
<severity>0</severity>
|
||||
@@ -226,20 +253,20 @@
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
-->
|
||||
|
||||
|
||||
<rule ref="PEAR.Commenting.FunctionComment" />
|
||||
|
||||
<rule ref="PEAR.Commenting.FunctionComment.Empty">
|
||||
<severity>5</severity>
|
||||
</rule>
|
||||
|
||||
<rule ref="PEAR.Commenting.FunctionComment.MissingReturn">
|
||||
|
||||
<!--<rule ref="PEAR.Commenting.FunctionComment.MissingReturn">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
<rule ref="PEAR.Commenting.FunctionComment.Missing">
|
||||
</rule>-->
|
||||
<!--<rule ref="PEAR.Commenting.FunctionComment.Missing">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
|
||||
</rule>-->
|
||||
|
||||
<rule ref="PEAR.Commenting.FunctionComment.SpacingAfterParamType" />
|
||||
|
||||
<rule ref="PEAR.Commenting.FunctionComment.SpacingAfterParamName">
|
||||
@@ -255,11 +282,11 @@
|
||||
<rule ref="PEAR.Commenting.FunctionComment.ReturnNotRequired">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
|
||||
|
||||
<rule ref="PEAR.Commenting.FunctionComment.WrongStyle">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
|
||||
|
||||
<rule ref="PEAR.Commenting.FunctionComment.SpacingBeforeParamType">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
@@ -286,7 +313,20 @@
|
||||
<!-- <rule ref="PEAR.ControlStructures.MultiLineCondition" /> -->
|
||||
|
||||
<!-- Test if () are removed for includes -->
|
||||
<!-- <rule ref="PEAR.Files.IncludingFile"/> -->
|
||||
<rule ref="PEAR.Files.IncludingFile" />
|
||||
<!-- Disable some error messages that we do not want. -->
|
||||
<rule ref="PEAR.Files.IncludingFile.UseInclude">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
<rule ref="PEAR.Files.IncludingFile.UseIncludeOnce">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
<rule ref="PEAR.Files.IncludingFile.UseRequire">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
<rule ref="PEAR.Files.IncludingFile.UseRequireOnce">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
|
||||
<rule ref="PEAR.Formatting.MultiLineAssignment" />
|
||||
|
||||
@@ -306,24 +346,18 @@
|
||||
</rule>
|
||||
<rule ref="PEAR.Functions.FunctionCallSignature.SpaceBeforeOpenBracket">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
<rule ref="PEAR.Functions.FunctionCallSignature.SpaceAfterOpenBracket">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
<rule ref="PEAR.Functions.FunctionCallSignature.SpaceBeforeCloseBracket">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
<rule ref="PEAR.Functions.FunctionCallSignature.SpaceAfterCloseBracket">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
|
||||
|
||||
<rule ref="PEAR.Functions.ValidDefaultValue" />
|
||||
|
||||
<rule ref="PEAR.NamingConventions.ValidClassName" />
|
||||
<rule ref="PEAR.NamingConventions.ValidClassName.Invalid">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
|
||||
|
||||
<rule ref="PEAR.NamingConventions.ValidClassName.StartWithCapital">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
@@ -331,7 +365,7 @@
|
||||
<rule ref="PEAR.NamingConventions.ValidClassName.StartWithCaptial">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
|
||||
|
||||
<rule ref="PEAR.NamingConventions.ValidFunctionName" />
|
||||
|
||||
<rule ref="PEAR.NamingConventions.ValidFunctionName.FunctionDoubleUnderscore">
|
||||
@@ -348,31 +382,38 @@
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
|
||||
<rule ref="PEAR.NamingConventions.ValidFunctionName.NotCamelCaps">
|
||||
<!--<rule ref="PEAR.NamingConventions.ValidFunctionName.NotCamelCaps">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
</rule>-->
|
||||
<!--<rule ref="PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps">
|
||||
<severity>0</severity>
|
||||
</rule>-->
|
||||
<rule ref="PEAR.NamingConventions.ValidFunctionName.PrivateNoUnderscore">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
<rule ref="PEAR.NamingConventions.ValidVariableName" />
|
||||
|
||||
<rule ref="PSR2.Classes.ClassDeclaration" />
|
||||
<rule ref="PSR2.Methods.FunctionClosingBrace" />
|
||||
<rule ref="PSR2.ControlStructures.ElseIfDeclaration.NotAllowed" />
|
||||
|
||||
<!-- This is not in PSR2 -->
|
||||
<rule ref="PEAR.NamingConventions.ValidVariableName.PrivateNoUnderscore">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
|
||||
|
||||
<rule ref="PEAR.WhiteSpace.ObjectOperatorIndent" />
|
||||
|
||||
<!-- Need to be commented to be disabled
|
||||
<rule ref="PEAR.WhiteSpace.ScopeClosingBrace">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
|
||||
|
||||
<rule ref="PEAR.WhiteSpace.ScopeClosingBrace.Line">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
-->
|
||||
|
||||
|
||||
<!-- Already found as a Generic rule -->
|
||||
<!-- <rule ref="PEAR.WhiteSpace.ScopeIndent" /> -->
|
||||
|
||||
@@ -382,4 +423,10 @@
|
||||
<!-- The closing ?> tag MUST be omitted from files containing only PHP. -->
|
||||
<rule ref="Zend.Files.ClosingTag"/>
|
||||
|
||||
<rule ref="PSR2.Classes.ClassDeclaration" />
|
||||
<rule ref="PSR2.Methods.FunctionClosingBrace" />
|
||||
<rule ref="PSR2.Files.EndFileNewline.TooMany" />
|
||||
<rule ref="PSR2.Files.EndFileNewline.NoneFound" />
|
||||
<rule ref="PSR2.Methods.FunctionCallSignature.SpaceBeforeOpenBracket" />
|
||||
<rule ref="PSR2.Classes.PropertyDeclaration.VarUsed" />
|
||||
</ruleset>
|
||||
|
||||
@@ -17,14 +17,14 @@ fi
|
||||
# To detec
|
||||
if [ "x$1" = "xlist" ]
|
||||
then
|
||||
find . \( -iname "functions" -o -iname "*.md" -o -iname "*.html" -o -iname "*.htm" -o -iname "*.php" -o -iname "*.sh" -o -iname "*.cml" -o -iname "*.css" -o -iname "*.js" -o -iname "*.lang" -o -iname "*.pl" -o -iname "*.sql" -o -iname "*.txt" -o -iname "*.xml" -o -iname "*.pml" \) -exec file "{}" + | grep CRLF
|
||||
# find . \( -iname "*.md" -o -iname "*.html" -o -iname "*.htm" -o -iname "*.php" -o -iname "*.sh" -o -iname "*.cml" -o -iname "*.css" -o -iname "*.js" -o -iname "*.lang" -o -iname "*.pl" -o -iname "*.sql" -o -iname "*.txt" -o -iname "*.xml" \) -exec file "{}" + | grep -v 'htdocs\/includes' | grep CRLF
|
||||
find . \( -iname "functions" -o -iname "*.md" -o -iname "*.html" -o -iname "*.htm" -o -iname "*.php" -o -iname "*.sh" -o -iname "*.cml" -o -iname "*.css" -o -iname "*.js" -o -iname "*.lang" -o -iname "*.pl" -o -iname "*.sql" -o -iname "*.txt" -o -iname "*.xml" -o -iname "*.pml" \) -exec file "{}" + | grep -v 'documents\/website' | grep CRLF
|
||||
# find . \( -iname "*.md" -o -iname "*.html" -o -iname "*.htm" -o -iname "*.php" -o -iname "*.sh" -o -iname "*.cml" -o -iname "*.css" -o -iname "*.js" -o -iname "*.lang" -o -iname "*.pl" -o -iname "*.sql" -o -iname "*.txt" -o -iname "*.xml" \) -exec file "{}" + | grep -v 'documents\/website' | grep -v 'htdocs\/includes' | grep CRLF
|
||||
fi
|
||||
|
||||
# To convert
|
||||
if [ "x$1" = "xfix" ]
|
||||
then
|
||||
for fic in `find . \( -iname "functions" -o -iname "*.md" -o -iname "*.html" -o -iname "*.htm" -o -iname "*.php" -o -iname "*.sh" -o -iname "*.cml" -o -iname "*.css" -o -iname "*.js" -o -iname "*.lang" -o -iname "*.pl" -o -iname "*.sql" -o -iname "*.txt" -o -iname "*.xml" -o -iname "*.pml" \) -exec file "{}" + | grep CRLF | awk -F':' '{ print $1 }' `
|
||||
for fic in `find . \( -iname "functions" -o -iname "*.md" -o -iname "*.html" -o -iname "*.htm" -o -iname "*.php" -o -iname "*.sh" -o -iname "*.cml" -o -iname "*.css" -o -iname "*.js" -o -iname "*.lang" -o -iname "*.pl" -o -iname "*.sql" -o -iname "*.txt" -o -iname "*.xml" -o -iname "*.pml" \) -exec file "{}" + | grep -v 'documents\/website' | grep CRLF | awk -F':' '{ print $1 }' `
|
||||
do
|
||||
echo "Fix file $fic"
|
||||
dos2unix "$fic"
|
||||
|
||||
@@ -1,8 +1,18 @@
|
||||
#!/bin/sh
|
||||
|
||||
FROM=2016-01-01
|
||||
TO=2016-12-31
|
||||
if [ "x$1" = "x" ]; then
|
||||
echo "Usage: $0 YEAR"
|
||||
exit
|
||||
fi
|
||||
|
||||
|
||||
FROM=$1-01-01
|
||||
TO=$1-12-31
|
||||
|
||||
echo "Number of contributors for the year"
|
||||
echo "git log --since $FROM --before $TO | grep ^Author | sort -u -f -i -b | wc -l"
|
||||
git log --since $FROM --before $TO | grep ^Author | sort -u -f -i -b | wc -l
|
||||
|
||||
|
||||
echo "Number of commit for the year"
|
||||
git log --pretty='format:%cd' --date=format:'%Y' | uniq -c | awk '{print "Year: "$2", commits: "$1}' | grep "Year: $1"
|
||||
|
||||
@@ -1,10 +1,11 @@
|
||||
#/bin/bash
|
||||
Releases=("3.8" "3.9" "4.0" "5.0", "develop")
|
||||
Dates=("2010-01-01", "2011-01-01", "2012-01-01", "2013-01-01", "2014-01-01", "2015-01-01", "2016-07-01")
|
||||
Releases=("3.8" "3.9" "4.0" "5.0" "6.0" " 7.0" "develop")
|
||||
Dates=("2013-01-01", "2014-01-01", "2015-01-01", "2016-07-01", "2017-02-01", "2017-07-01", "2018-02-01", "2050-01-01")
|
||||
let "counter = 1"
|
||||
|
||||
for i in "${Releases[@]}"
|
||||
do
|
||||
echo "=== $counter git shortlog -s -n --after=${Dates[counter-1]} --before=${Dates[counter]}"
|
||||
git shortlog -s -n --after=${Dates[counter-1]} --before=${Dates[counter]}
|
||||
echo -n "Total $i: "
|
||||
git log --pretty=oneline --after=${Dates[counter-1]} --before=${Dates[counter]} | wc -l
|
||||
|
||||
130
dev/tools/snakeCaseToCamelCase.sh
Executable file
130
dev/tools/snakeCaseToCamelCase.sh
Executable file
@@ -0,0 +1,130 @@
|
||||
#!/bin/bash
|
||||
|
||||
## Need "rpl" package
|
||||
RPL_INSTALLED=$(dpkg -s rpl)
|
||||
if [[ -z ${RPL_INSTALLED} ]]; then
|
||||
echo "This bash need rpl command, you can install it with: sudo apt install rpl"
|
||||
fi
|
||||
|
||||
DIR_HTDOCS=$( cd "$( dirname "${BASH_SOURCE[0]}" )/../../htdocs" >/dev/null && pwd )
|
||||
|
||||
PATTERN=""
|
||||
if [[ -f $1 ]]; then
|
||||
TFile=("$1") # specific file
|
||||
elif [[ -n $1 ]]; then
|
||||
PATTERN=$1 # name of a particular file or pattern (ex: societe.class.php)
|
||||
else
|
||||
PATTERN="*.class.php" # *.lib.php
|
||||
fi
|
||||
|
||||
if [[ -n ${PATTERN} ]]; then
|
||||
TCLASSFILE=$(find "${DIR_HTDOCS}" -name "${PATTERN}" | grep -v "/custom/" | grep -v "/includes/" | grep -v -F -f "${DIR_HTDOCS}/../.gitignore")
|
||||
TFile=()
|
||||
I=0
|
||||
for f in ${TCLASSFILE}; do
|
||||
TFile[${I}]="${f}"
|
||||
((I++))
|
||||
done
|
||||
fi
|
||||
|
||||
|
||||
REGEX_FNC_W='^([[:blank:]]*)(public|private|protected)?[ \t]*(static)?[ \t]*[^\$\(]function[ \t]*([a-zA-Z0-9\-\_]*)[\(](.*)[\)][ \t]*([\{]?)$'
|
||||
INDENT=" "
|
||||
|
||||
for f in ${TFile[@]}; do
|
||||
# echo ${f}
|
||||
|
||||
IFS=$'\n'
|
||||
TLine=($(cat "${f}" | grep -E "${REGEX_FNC_W}"))
|
||||
|
||||
for LINE in ${TLine[@]}; do
|
||||
|
||||
if [[ ${LINE} =~ ^${REGEX_FNC_W}$ ]]; then
|
||||
FIRST_INDENT=${BASH_REMATCH[1]} # seem not work
|
||||
FNC_TYPE=${BASH_REMATCH[2]}
|
||||
STATIC=${BASH_REMATCH[3]}
|
||||
FNC_NAME=${BASH_REMATCH[4]}
|
||||
PARAMETERS_ORIGIN=${BASH_REMATCH[5]}
|
||||
BRACKET_END=${BASH_REMATCH[6]}
|
||||
|
||||
if [[ ${LINE} =~ ^([[:blank:]]*) ]]; then # but this seems work to get indentation
|
||||
FIRST_INDENT=${BASH_REMATCH[1]}
|
||||
fi
|
||||
|
||||
[[ ${FNC_NAME} =~ ^__ ]] && continue # skip magic function
|
||||
|
||||
CAMEL_CASE=$(echo "${FNC_NAME}" | sed -r 's/(_)([a-zA-Z0-9])/\U\2/g')
|
||||
[[ ${CAMEL_CASE} = ${FNC_NAME} ]] && continue # skip if no difference
|
||||
|
||||
#echo A: ${#FIRST_INDENT}
|
||||
#printf "${FIRST_INDENT}TEST INDENT\n"
|
||||
#echo B: ${FNC_TYPE}
|
||||
#echo C: ${STATIC}
|
||||
#echo D: ${FNC_NAME}
|
||||
#echo D: ${CAMEL_CASE}
|
||||
#echo E: ${PARAMETERS_ORIGIN}
|
||||
#echo F: ${BRACKET_END}
|
||||
#exit
|
||||
|
||||
[[ -n $(cat "${f}" | grep -i "function[[:blank:]]*${CAMEL_CASE}") ]] && continue # skip if already exists
|
||||
|
||||
TCommentLine=()
|
||||
J=1
|
||||
while :; do
|
||||
COMMENT=$(cat ${f} | grep -B ${J} ${LINE/\$/\\$} | head -n1 | grep -P '^[\t\ ]*(/\*\*|\*[^/]?|\*/)')
|
||||
if [[ -n ${COMMENT} ]]; then
|
||||
TCommentLine[${J}]="${COMMENT}"
|
||||
((J++))
|
||||
else
|
||||
break
|
||||
fi
|
||||
done
|
||||
|
||||
COMMENT_ORIGIN=""
|
||||
COMMENT_ORIGIN_WITH_DEPRECATED=""
|
||||
COMMENT_DUPLICATE=""
|
||||
if [[ ${#TCommentLine[@]} -gt 0 ]]; then
|
||||
for (( idx=${#TCommentLine[@]} ; idx>0 ; idx-- )) ; do
|
||||
COMMENT_ORIGIN="${COMMENT_ORIGIN}\n${TCommentLine[idx]}"
|
||||
done
|
||||
|
||||
COMMENT_DUPLICATE=${COMMENT_ORIGIN}
|
||||
|
||||
COMMENT_ORIGIN_WITH_DEPRECATED=$(echo "${COMMENT_ORIGIN%?} @deprecated\n${FIRST_INDENT} * @see ${CAMEL_CASE}\n${FIRST_INDENT} */")
|
||||
fi
|
||||
|
||||
PARAMETERS=${PARAMETERS_ORIGIN}
|
||||
TParam=()
|
||||
I=0
|
||||
while [[ ${PARAMETERS} =~ (\$[a-zA-Z0-9\_\-]+) ]]; do
|
||||
TParam[${I}]=${BASH_REMATCH[1]}
|
||||
PARAMETERS=${PARAMETERS#*"${BASH_REMATCH[1]}"}
|
||||
((I++))
|
||||
done
|
||||
|
||||
PARAMS_STR=$(printf ", %s" "${TParam[@]}")
|
||||
PARAMS_STR=${PARAMS_STR:2}
|
||||
|
||||
REPLACE=${LINE}
|
||||
[[ -z ${BRACKET_END} ]] && REPLACE="${LINE}\n${FIRST_INDENT}{\n${FIRST_INDENT}${INDENT}" || REPLACE="${LINE}\n${FIRST_INDENT}${INDENT}"
|
||||
[[ -n ${STATIC} ]] && REPLACE="${REPLACE}return self::" || REPLACE="${REPLACE}return \$this->"
|
||||
REPLACE="${REPLACE}${CAMEL_CASE}(${PARAMS_STR});\n${FIRST_INDENT}}\n\n"
|
||||
REPLACE="${REPLACE}${FIRST_INDENT}${COMMENT_ORIGIN}\n${FIRST_INDENT}"
|
||||
[[ -n ${STATIC} ]] && REPLACE="${REPLACE}${STATIC} "
|
||||
[[ -n ${FNC_TYPE} ]] && REPLACE="${REPLACE}${FNC_TYPE} "
|
||||
REPLACE="${REPLACE}function ${CAMEL_CASE}(${PARAMETERS_ORIGIN})"
|
||||
[[ -n ${BRACKET_END} ]] && REPLACE="${REPLACE}\n${FIRST_INDENT}{"
|
||||
|
||||
echo " ${FNC_NAME} -> ${CAMEL_CASE}"
|
||||
|
||||
if [[ -n ${COMMENT_ORIGIN_WITH_DEPRECATED} ]]; then
|
||||
rpl -e --quiet "${COMMENT_ORIGIN}" ${COMMENT_ORIGIN_WITH_DEPRECATED} "${f}"
|
||||
fi
|
||||
rpl -e --quiet "${LINE}" ${REPLACE} "${f}"
|
||||
|
||||
fi
|
||||
|
||||
done
|
||||
done
|
||||
|
||||
|
||||
@@ -21,14 +21,14 @@
|
||||
|
||||
<div class="center">
|
||||
|
||||
<div class="login_table" align="center">
|
||||
<div class="login_table center">
|
||||
|
||||
<!-- <tr><td colspan="2" valign="middle"> -->
|
||||
<div id="login_line1" align="center">
|
||||
<div id="login_line1" class="center">
|
||||
|
||||
<div id="login_left" style="display: inline-block; min-width: 250px; margin: 0 auto;"><div class="center">
|
||||
|
||||
<table class="none" summary="Login pass" cellpadding="2" align="center">
|
||||
<table class="none center" summary="Login pass" cellpadding="2">
|
||||
|
||||
<!-- Login -->
|
||||
<tr>
|
||||
@@ -50,7 +50,7 @@
|
||||
</div> <!-- end div left -->
|
||||
|
||||
<!-- </td>
|
||||
<td align="center" valign="middle">-->
|
||||
<td class="center" valign="middle">-->
|
||||
<div id="login_right" style="display: inline-block; min-width: 250px; margin: 0 auto;">
|
||||
|
||||
<img alt="Logo" title="" src="/dolibarrnew/theme/dolibarr_logo.png" id="img_logo" />
|
||||
|
||||
@@ -27,8 +27,8 @@
|
||||
* @since 2008-03-04
|
||||
*/
|
||||
|
||||
require_once('../../htdocs/includes/tecnickcom/tcpdf/config/tcpdf_config.php');
|
||||
require_once('../../htdocs/includes/tecnickcom/tcpdf/tcpdf.php');
|
||||
require_once '../../htdocs/includes/tecnickcom/tcpdf/config/tcpdf_config.php';
|
||||
require_once '../../htdocs/includes/tecnickcom/tcpdf/tcpdf.php';
|
||||
|
||||
// create new PDF document
|
||||
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
|
||||
@@ -101,7 +101,7 @@ $pdf->SetHeaderMargin(PDF_MARGIN_HEADER);
|
||||
$pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
|
||||
|
||||
//set auto page breaks
|
||||
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
|
||||
$pdf->SetAutoPageBreak(true, PDF_MARGIN_BOTTOM);
|
||||
|
||||
//set image scale factor
|
||||
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
|
||||
|
||||
@@ -47,8 +47,8 @@ print 'Files has been created. Check its name from your explorer'."\n";
|
||||
* @since 2008-09-15
|
||||
*/
|
||||
|
||||
require_once('../../htdocs/includes/tecnickcom/tcpdf/config/tcpdf_config.php');
|
||||
require_once('../../htdocs/includes/tecnickcom/tcpdf/tcpdf.php');
|
||||
require_once '../../htdocs/includes/tecnickcom/tcpdf/config/tcpdf_config.php';
|
||||
require_once '../../htdocs/includes/tecnickcom/tcpdf/tcpdf.php';
|
||||
|
||||
// create new PDF document
|
||||
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
|
||||
@@ -76,7 +76,7 @@ $pdf->SetHeaderMargin(PDF_MARGIN_HEADER);
|
||||
$pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
|
||||
|
||||
//set auto page breaks
|
||||
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
|
||||
$pdf->SetAutoPageBreak(true, PDF_MARGIN_BOTTOM);
|
||||
|
||||
//set image scale factor
|
||||
//$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
|
||||
|
||||
@@ -4,7 +4,7 @@ This directory contains tools to generate translation files for a new
|
||||
languages or to update translation files for existing languages.
|
||||
See Dolibarr Wiki page:
|
||||
http://wiki.dolibarr.org/index.php/Translator_documentation
|
||||
For more informations on how to use them.
|
||||
For more information on how to use them.
|
||||
|
||||
To install transifex client:
|
||||
sudo pip install --upgrade transifex-client
|
||||
|
||||
@@ -50,7 +50,7 @@ class autoTranslator
|
||||
* @param string $_apikey Api key
|
||||
* @return void
|
||||
*/
|
||||
function __construct($_destlang,$_refLang,$_langDir,$_limittofile,$_apikey)
|
||||
public function __construct($_destlang, $_refLang, $_langDir, $_limittofile, $_apikey)
|
||||
{
|
||||
|
||||
// Set enviorment variables
|
||||
@@ -63,9 +63,8 @@ class autoTranslator
|
||||
|
||||
// Translate
|
||||
//ini_set('default_charset','UTF-8');
|
||||
ini_set('default_charset',$this->_outputpagecode);
|
||||
$this->parse_refLangTranslationFiles();
|
||||
|
||||
ini_set('default_charset', $this->_outputpagecode);
|
||||
$this->parseRefLangTranslationFiles();
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -73,7 +72,7 @@ class autoTranslator
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
private function parse_refLangTranslationFiles()
|
||||
private function parseRefLangTranslationFiles()
|
||||
{
|
||||
|
||||
$files = $this->getTranslationFilesArray($this->_refLang);
|
||||
@@ -84,7 +83,7 @@ class autoTranslator
|
||||
$counter++;
|
||||
$fileContent = null;
|
||||
$refPath = $this->_langDir.$this->_refLang.self::DIR_SEPARATOR.$file;
|
||||
$fileContent = file($refPath,FILE_IGNORE_NEW_LINES|FILE_SKIP_EMPTY_LINES);
|
||||
$fileContent = file($refPath, FILE_IGNORE_NEW_LINES|FILE_SKIP_EMPTY_LINES);
|
||||
print "Processing file " . $file . ", with ".count($fileContent)." lines<br>\n";
|
||||
|
||||
// Define target dirs
|
||||
@@ -94,19 +93,19 @@ class autoTranslator
|
||||
$targetlangs=array();
|
||||
|
||||
// If we must process all languages
|
||||
$arraytmp=dol_dir_list($this->_langDir,'directories',0);
|
||||
$arraytmp=dol_dir_list($this->_langDir, 'directories', 0);
|
||||
foreach($arraytmp as $dirtmp)
|
||||
{
|
||||
if ($dirtmp['name'] === $this->_refLang) continue; // We discard source language
|
||||
$tmppart=explode('_',$dirtmp['name']);
|
||||
if (preg_match('/^en/i',$dirtmp['name'])) continue; // We discard en_* languages
|
||||
if (preg_match('/^fr/i',$dirtmp['name'])) continue; // We discard fr_* languages
|
||||
if (preg_match('/^es/i',$dirtmp['name'])) continue; // We discard es_* languages
|
||||
if (preg_match('/ca_ES/i',$dirtmp['name'])) continue; // We discard es_CA language
|
||||
if (preg_match('/pt_BR/i',$dirtmp['name'])) continue; // We discard pt_BR language
|
||||
if (preg_match('/nl_BE/i',$dirtmp['name'])) continue; // We discard nl_BE language
|
||||
if (preg_match('/^\./i',$dirtmp['name'])) continue; // We discard files .*
|
||||
if (preg_match('/^CVS/i',$dirtmp['name'])) continue; // We discard CVS
|
||||
$tmppart=explode('_', $dirtmp['name']);
|
||||
if (preg_match('/^en/i', $dirtmp['name'])) continue; // We discard en_* languages
|
||||
if (preg_match('/^fr/i', $dirtmp['name'])) continue; // We discard fr_* languages
|
||||
if (preg_match('/^es/i', $dirtmp['name'])) continue; // We discard es_* languages
|
||||
if (preg_match('/ca_ES/i', $dirtmp['name'])) continue; // We discard es_CA language
|
||||
if (preg_match('/pt_BR/i', $dirtmp['name'])) continue; // We discard pt_BR language
|
||||
if (preg_match('/nl_BE/i', $dirtmp['name'])) continue; // We discard nl_BE language
|
||||
if (preg_match('/^\./i', $dirtmp['name'])) continue; // We discard files .*
|
||||
if (preg_match('/^CVS/i', $dirtmp['name'])) continue; // We discard CVS
|
||||
$targetlangs[]=$dirtmp['name'];
|
||||
}
|
||||
//var_dump($targetlangs);
|
||||
@@ -123,7 +122,7 @@ class autoTranslator
|
||||
{
|
||||
// No file present, we generate file
|
||||
echo "File not found: " . $destPath . ". We generate it.<br>\n";
|
||||
$this->createTranslationFile($destPath,$my_destlang);
|
||||
$this->createTranslationFile($destPath, $my_destlang);
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -131,18 +130,18 @@ class autoTranslator
|
||||
}
|
||||
|
||||
// Translate lines
|
||||
$fileContentDest = file($destPath,FILE_IGNORE_NEW_LINES|FILE_SKIP_EMPTY_LINES);
|
||||
$fileContentDest = file($destPath, FILE_IGNORE_NEW_LINES|FILE_SKIP_EMPTY_LINES);
|
||||
$newlines=0;
|
||||
foreach($fileContent as $line){
|
||||
$key = $this->getLineKey($line);
|
||||
$value = $this->getLineValue($line);
|
||||
if ($key && $value)
|
||||
{
|
||||
$newlines+=$this->translateFileLine($fileContentDest,$file,$key,$value,$my_destlang);
|
||||
$newlines+=$this->translateFileLine($fileContentDest, $file, $key, $value, $my_destlang);
|
||||
}
|
||||
}
|
||||
|
||||
$this->updateTranslationFile($destPath,$file,$my_destlang);
|
||||
$this->updateTranslationFile($destPath, $file, $my_destlang);
|
||||
echo "New translated lines: " . $newlines . "<br>\n";
|
||||
//if ($counter ==3) die('fim');
|
||||
}
|
||||
@@ -157,7 +156,7 @@ class autoTranslator
|
||||
* @param string $my_destlang Target language code
|
||||
* @return void
|
||||
*/
|
||||
private function updateTranslationFile($destPath,$file,$my_destlang)
|
||||
private function updateTranslationFile($destPath, $file, $my_destlang)
|
||||
{
|
||||
$this->_time_end = date('Y-m-d H:i:s');
|
||||
|
||||
@@ -168,7 +167,7 @@ class autoTranslator
|
||||
fwrite($fp, "\n");
|
||||
fwrite($fp, "// START - Lines generated via autotranslator.php tool (".$this->_time.").\n");
|
||||
fwrite($fp, "// Reference language: ".$this->_refLang." -> ".$my_destlang."\n");
|
||||
foreach( $this->_translatedFiles[$file] as $line) {
|
||||
foreach($this->_translatedFiles[$file] as $line) {
|
||||
fwrite($fp, $line . "\n");
|
||||
}
|
||||
fwrite($fp, "// STOP - Lines generated via autotranslator.php tool (".$this->_time_end.").\n");
|
||||
@@ -184,7 +183,7 @@ class autoTranslator
|
||||
* @param string $my_destlang Target language code
|
||||
* @return void
|
||||
*/
|
||||
private function createTranslationFile($path,$my_destlang)
|
||||
private function createTranslationFile($path, $my_destlang)
|
||||
{
|
||||
$fp = fopen($path, 'w+');
|
||||
fwrite($fp, "/*\n");
|
||||
@@ -206,11 +205,11 @@ class autoTranslator
|
||||
* @param string $my_destlang Language code (ie: fr_FR)
|
||||
* @return int 0=Nothing translated, 1=Record translated
|
||||
*/
|
||||
private function translateFileLine($content,$file,$key,$value,$my_destlang)
|
||||
private function translateFileLine($content, $file, $key, $value, $my_destlang)
|
||||
{
|
||||
|
||||
//print "key =".$key."\n";
|
||||
foreach( $content as $line ) {
|
||||
foreach($content as $line) {
|
||||
$destKey = $this->getLineKey($line);
|
||||
$destValue = $this->getLineValue($line);
|
||||
// If translated return
|
||||
@@ -221,14 +220,16 @@ class autoTranslator
|
||||
}
|
||||
}
|
||||
|
||||
if ($key == 'CHARSET') $val=$this->_outputpagecode;
|
||||
else if (preg_match('/^Format/',$key)) $val=$value;
|
||||
else if ($value=='-') $val=$value;
|
||||
else
|
||||
{
|
||||
if ($key == 'CHARSET') {
|
||||
$val=$this->_outputpagecode;
|
||||
} elseif (preg_match('/^Format/', $key)) {
|
||||
$val=$value;
|
||||
} elseif ($value=='-') {
|
||||
$val=$value;
|
||||
} else {
|
||||
// If not translated then translate
|
||||
if ($this->_outputpagecode == 'UTF-8') $val=$this->translateTexts(array($value),substr($this->_refLang,0,2),substr($my_destlang,0,2));
|
||||
else $val=utf8_decode($this->translateTexts(array($value),substr($this->_refLang,0,2),substr($my_destlang,0,2)));
|
||||
if ($this->_outputpagecode == 'UTF-8') $val=$this->translateTexts(array($value), substr($this->_refLang, 0, 2), substr($my_destlang, 0, 2));
|
||||
else $val=utf8_decode($this->translateTexts(array($value), substr($this->_refLang, 0, 2), substr($my_destlang, 0, 2)));
|
||||
}
|
||||
|
||||
$val=trim($val);
|
||||
@@ -247,7 +248,7 @@ class autoTranslator
|
||||
*/
|
||||
private function getLineKey($line)
|
||||
{
|
||||
$arraykey = explode('=',$line,2);
|
||||
$arraykey = explode('=', $line, 2);
|
||||
return trim($arraykey[0]);
|
||||
}
|
||||
|
||||
@@ -259,7 +260,7 @@ class autoTranslator
|
||||
*/
|
||||
private function getLineValue($line)
|
||||
{
|
||||
$arraykey = explode('=',$line,2);
|
||||
$arraykey = explode('=', $line, 2);
|
||||
return trim(isset($arraykey[1])?$arraykey[1]:'');
|
||||
}
|
||||
|
||||
@@ -273,7 +274,7 @@ class autoTranslator
|
||||
{
|
||||
$dir = new DirectoryIterator($this->_langDir.$lang);
|
||||
while($dir->valid()) {
|
||||
if(!$dir->isDot() && $dir->isFile() && ! preg_match('/^\./',$dir->getFilename())) {
|
||||
if(!$dir->isDot() && $dir->isFile() && ! preg_match('/^\./', $dir->getFilename())) {
|
||||
$files[] = $dir->getFilename();
|
||||
}
|
||||
$dir->next();
|
||||
@@ -292,16 +293,16 @@ class autoTranslator
|
||||
private function translateTexts($src_texts, $src_lang, $dest_lang)
|
||||
{
|
||||
// We want to be sure that src_lang and dest_lang are using 2 chars only
|
||||
$tmp=explode('_',$src_lang);
|
||||
$tmp=explode('_', $src_lang);
|
||||
if (! empty($tmp[1]) && $tmp[0] == $tmp[1]) $src_lang=$tmp[0];
|
||||
$tmp=explode('_',$dest_lang);
|
||||
$tmp=explode('_', $dest_lang);
|
||||
if (! empty($tmp[1]) && $tmp[0] == $tmp[1]) $dest_lang=$tmp[0];
|
||||
|
||||
//setting language pair
|
||||
$lang_pair = $src_lang.'|'.$dest_lang;
|
||||
|
||||
$src_text_to_translate=preg_replace('/%s/','SSSSS',implode('',$src_texts));
|
||||
$src_text_to_translate=preg_replace('/'.preg_quote('\n\n').'/',' NNNNN ',$src_text_to_translate);
|
||||
$src_text_to_translate=preg_replace('/%s/', 'SSSSS', implode('', $src_texts));
|
||||
$src_text_to_translate=preg_replace('/'.preg_quote('\n\n').'/', ' NNNNN ', $src_text_to_translate);
|
||||
|
||||
// Define GET URL v1
|
||||
//$url = "http://ajax.googleapis.com/ajax/services/language/translate?v=1.0&q=".urlencode($src_text_to_translate)."&langpair=".urlencode($lang_pair);
|
||||
@@ -338,13 +339,12 @@ class autoTranslator
|
||||
}
|
||||
|
||||
$rep=$json['data']['translations'][0]['translatedText'];
|
||||
$rep=preg_replace('/SSSSS/i','%s',$rep);
|
||||
$rep=preg_replace('/NNNNN/i','\n\n',$rep);
|
||||
$rep=preg_replace('/'/i','\'',$rep);
|
||||
$rep=preg_replace('/SSSSS/i', '%s', $rep);
|
||||
$rep=preg_replace('/NNNNN/i', '\n\n', $rep);
|
||||
$rep=preg_replace('/'/i', '\'', $rep);
|
||||
|
||||
//print "OK ".join('',$src_texts).' => '.$rep."\n";
|
||||
|
||||
return $rep;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -37,8 +37,8 @@ if (substr($sapi_type, 0, 3) == 'cgi') {
|
||||
}
|
||||
|
||||
// Include Dolibarr environment
|
||||
require_once($path.'../../htdocs/master.inc.php');
|
||||
require_once($path.'../../htdocs/core/lib/files.lib.php');
|
||||
require_once $path.'../../htdocs/master.inc.php';
|
||||
require_once $path.'../../htdocs/core/lib/files.lib.php';
|
||||
// After this $db is an opened handler to database. We close it at end of file.
|
||||
|
||||
// Load main language strings
|
||||
@@ -88,9 +88,9 @@ if ($argv[2] != 'all')
|
||||
}
|
||||
}
|
||||
|
||||
require_once(DOL_DOCUMENT_ROOT."/../dev/translation/autotranslator.class.php");
|
||||
require_once DOL_DOCUMENT_ROOT."/../dev/translation/autotranslator.class.php";
|
||||
|
||||
$langParser = new autoTranslator($argv[2],$argv[1],$dir,$file,$argv[3]);
|
||||
$langParser = new autoTranslator($argv[2], $argv[1], $dir, $file, $argv[3]);
|
||||
|
||||
print "***** Finished *****\n";
|
||||
|
||||
|
||||
@@ -113,7 +113,7 @@ if (empty($files))
|
||||
|
||||
$dups=array();
|
||||
$exludefiles = array('.','..','README');
|
||||
$files = array_diff($files,$exludefiles);
|
||||
$files = array_diff($files, $exludefiles);
|
||||
// To force a file: $files=array('myfile.lang');
|
||||
if (isset($argv[2]))
|
||||
{
|
||||
@@ -128,10 +128,10 @@ foreach ($files AS $file) {
|
||||
$content = file($workdir.$file);
|
||||
foreach ($content AS $line => $row) {
|
||||
// don't want comment lines
|
||||
if (substr($row,0,1) !== '#') {
|
||||
if (substr($row, 0, 1) !== '#') {
|
||||
// don't want lines without the separator (why should those even be here, anyway...)
|
||||
if (strpos($row,'=')!==false) {
|
||||
$row_array = explode('=',$row); // $row_array[0] = key
|
||||
if (strpos($row, '=')!==false) {
|
||||
$row_array = explode('=', $row); // $row_array[0] = key
|
||||
$langstrings_3d[$path_file['basename']][$line+1]=$row_array[0];
|
||||
$langstrings_3dtrans[$path_file['basename']][$line+1]=$row_array[1];
|
||||
$langstrings_full[]=$row_array[0];
|
||||
@@ -215,8 +215,8 @@ foreach ($dups as $string => $pages)
|
||||
$s.="\n";
|
||||
|
||||
if ($duplicateinsamefile) $sduplicateinsamefile .= $s;
|
||||
else if ($inmain) $sinmainandother .= $s;
|
||||
else if ($inadmin) $sininstallandadmin .= $s;
|
||||
elseif ($inmain) $sinmainandother .= $s;
|
||||
elseif ($inadmin) $sininstallandadmin .= $s;
|
||||
else $sother .= $s;
|
||||
}
|
||||
|
||||
@@ -295,6 +295,10 @@ if ((! empty($_REQUEST['unused']) && $_REQUEST['unused'] == 'true') || (isset($a
|
||||
if (preg_match('/^DescADHERENT_/', $value)) $qualifiedforclean=0;
|
||||
if (preg_match('/^SubmitTranslation/', $value)) $qualifiedforclean=0;
|
||||
if (preg_match('/^ModuleCompanyCode/', $value)) $qualifiedforclean=0;
|
||||
if (preg_match('/InDolibarr$/', $value)) $qualifiedforclean=0;
|
||||
// admin.lang
|
||||
if (preg_match('/^DAV_ALLOW_PUBLIC_DIR/i', $value)) $qualifiedforclean=0;
|
||||
if (preg_match('/^DAV_ALLOW_ECM_DIR/i', $value)) $qualifiedforclean=0;
|
||||
// boxes.lang
|
||||
if (preg_match('/^BoxTitleLast/', $value)) $qualifiedforclean=0;
|
||||
if (preg_match('/^BoxTitleLatest/', $value)) $qualifiedforclean=0;
|
||||
@@ -351,7 +355,7 @@ if ((! empty($_REQUEST['unused']) && $_REQUEST['unused'] == 'true') || (isset($a
|
||||
$search = '-e "\''.$value.'\'" -e \'"'.$value.'"\' -e "('.$value.')" -e "('.$value.',"';
|
||||
$string = 'grep -R -m 1 -F --exclude=includes/* --include=*.php '.$search.' '.$htdocs.'* '.$scripts.'*';
|
||||
//print $string."<br>\n";
|
||||
exec($string,$output);
|
||||
exec($string, $output);
|
||||
if (empty($output)) {
|
||||
$unused[$value] = $line;
|
||||
echo $line; // $trad contains the \n
|
||||
@@ -368,7 +372,7 @@ if ((! empty($_REQUEST['unused']) && $_REQUEST['unused'] == 'true') || (isset($a
|
||||
{
|
||||
$filetosave='/tmp/'.($argv[2]?$argv[2]:"").'notused.lang';
|
||||
print "Strings in en_US that are never used are saved into file ".$filetosave.":\n";
|
||||
file_put_contents($filetosave, implode("",$unused));
|
||||
file_put_contents($filetosave, implode("", $unused));
|
||||
print "To remove from original file, run command :\n";
|
||||
if (($argv[2]?$argv[2]:"")) print 'cd htdocs/langs/en_US; mv '.($argv[2]?$argv[2]:"")." ".($argv[2]?$argv[2]:"").".tmp; ";
|
||||
print "diff ".($argv[2]?$argv[2]:"").".tmp ".$filetosave." | grep \< | cut -b 3- > ".($argv[2]?$argv[2]:"");
|
||||
@@ -384,4 +388,3 @@ if ($web)
|
||||
}
|
||||
|
||||
exit;
|
||||
|
||||
|
||||
@@ -81,14 +81,14 @@ if ($filesToProcess == 'all')
|
||||
{
|
||||
$dir = new DirectoryIterator('htdocs/langs/'.$lPrimary);
|
||||
while($dir->valid()) {
|
||||
if(!$dir->isDot() && $dir->isFile() && ! preg_match('/^\./',$dir->getFilename())) {
|
||||
if(!$dir->isDot() && $dir->isFile() && ! preg_match('/^\./', $dir->getFilename())) {
|
||||
$files[] = $dir->getFilename();
|
||||
}
|
||||
$dir->next();
|
||||
}
|
||||
$filesToProcess=$files;
|
||||
}
|
||||
else $filesToProcess=explode(',',$filesToProcess);
|
||||
else $filesToProcess=explode(',', $filesToProcess);
|
||||
|
||||
// Arguments should be OK here.
|
||||
|
||||
@@ -256,7 +256,7 @@ foreach($filesToProcess as $fileToProcess)
|
||||
|
||||
print "Read Primary File $lPrimaryFile and write ".$output.":\n";
|
||||
|
||||
fwrite($oh, "# Dolibarr language file - Source file is en_US - ".(preg_replace('/\.lang$/','',$fileToProcess))."\n");
|
||||
fwrite($oh, "# Dolibarr language file - Source file is en_US - ".(preg_replace('/\.lang$/', '', $fileToProcess))."\n");
|
||||
|
||||
$cnt = 0;
|
||||
while (($line = fgets($handle)) !== false)
|
||||
@@ -306,11 +306,11 @@ foreach($filesToProcess as $fileToProcess)
|
||||
//print "Found primary key = ".$key."\n";
|
||||
|
||||
// Key not in other file
|
||||
if (in_array($key, $arrayofkeytoalwayskeep) || preg_match('/^FormatDate/',$key) || preg_match('/^FormatHour/',$key))
|
||||
if (in_array($key, $arrayofkeytoalwayskeep) || preg_match('/^FormatDate/', $key) || preg_match('/^FormatHour/', $key))
|
||||
{
|
||||
//print "Key $key is a key we always want to see into secondary file (line: $cnt).\n";
|
||||
}
|
||||
else if ( ! array_key_exists($key, $aSecondary))
|
||||
elseif ( ! array_key_exists($key, $aSecondary))
|
||||
{
|
||||
//print "Key $key does NOT exist in secondary language (line: $cnt).\n";
|
||||
continue;
|
||||
@@ -320,7 +320,7 @@ foreach($filesToProcess as $fileToProcess)
|
||||
if (
|
||||
(! empty($aSecondary[$key]) && $aSecondary[$key] != $aPrimary[$key]
|
||||
&& ! empty($aEnglish[$key]) && $aSecondary[$key] != $aEnglish[$key])
|
||||
|| in_array($key, $arrayofkeytoalwayskeep) || preg_match('/^FormatDate/',$key) || preg_match('/^FormatHour/',$key)
|
||||
|| in_array($key, $arrayofkeytoalwayskeep) || preg_match('/^FormatDate/', $key) || preg_match('/^FormatHour/', $key)
|
||||
)
|
||||
{
|
||||
//print "Key $key differs (aSecondary=".$aSecondary[$key].", aPrimary=".$aPrimary[$key].", aEnglish=".$aEnglish[$key].") so we add it into new secondary language (line: $cnt).\n";
|
||||
|
||||
@@ -15,7 +15,7 @@ then
|
||||
echo "This push local files to transifex for project $project."
|
||||
echo "Note: If you push a language file (not source), file will be skipped if transifex file is newer."
|
||||
echo " Using -f will overwrite translation but not memory."
|
||||
echo "Usage: ./dev/translation/txpush.sh (source|xx_XX|all) [-r ".$project.".file] [-f] [--no-interactive]"
|
||||
echo "Usage: ./dev/translation/txpush.sh (source|xx_XX|all) [-r $project.file] [-f] [--no-interactive]"
|
||||
exit
|
||||
fi
|
||||
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user