Skip to content

Commit

Permalink
Merge branch 'develop' of github.com:Dolibarr/dolibarr into NEW_SUBMI…
Browse files Browse the repository at this point in the history
…T_FOR_ALL_MARK_2
  • Loading branch information
atm-jonathan committed Sep 12, 2024
2 parents 1cd9358 + df1f157 commit 36d2ce7
Show file tree
Hide file tree
Showing 976 changed files with 10,206 additions and 7,141 deletions.
6 changes: 6 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,12 @@ repos:
# Check that there are no files that have are the same when uppercased (conflict on windows)
- id: check-case-conflict

# Gitleaks is a SAST tool for detecting and preventing hardcoded secrets like passwords, api keys, and tokens in git repos
- repo: https://github.com/gitleaks/gitleaks.git
rev: v8.16.1
hooks:
- id: gitleaks

# Beautify shell scripts
- repo: https://github.com/lovesegfault/beautysh.git
rev: v6.2.1
Expand Down
2 changes: 2 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ The following changes may create regressions for some external modules, but were
* Prepare your module for deprecation of triggers code XXX_INSERT to support also XXX_CREATE.
* More class properties (with old name in french) are now deprecated in favor of the property name in english.
* The json emulator dol_json_encode/decode() is removed. The native json PHP module must be enabled/available (this is the case by default with most PHP installation).
* The experimental and deprecated module WebserviceClient is completely removed (SOAP technology is deprecated). May be replaced with the stable module Webhook.



***** ChangeLog for 20.0.0 compared to 19.0 *****
Expand Down
2 changes: 2 additions & 0 deletions build/rpm/dolibarr_fedora.spec
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,7 @@ done >>%{name}.lang
%_datadir/dolibarr/htdocs/accountancy
%_datadir/dolibarr/htdocs/adherents
%_datadir/dolibarr/htdocs/admin
%_datadir/dolibarr/htdocs/ai
%_datadir/dolibarr/htdocs/api
%_datadir/dolibarr/htdocs/asset
%_datadir/dolibarr/htdocs/asterisk
Expand Down Expand Up @@ -228,6 +229,7 @@ done >>%{name}.lang
%_datadir/dolibarr/htdocs/user
%_datadir/dolibarr/htdocs/variants
%_datadir/dolibarr/htdocs/webhook
%_datadir/dolibarr/htdocs/webportal
%_datadir/dolibarr/htdocs/webservices
%_datadir/dolibarr/htdocs/website
%_datadir/dolibarr/htdocs/workstation
Expand Down
2 changes: 2 additions & 0 deletions build/rpm/dolibarr_generic.spec
Original file line number Diff line number Diff line change
Expand Up @@ -239,6 +239,7 @@ done >>%{name}.lang
%_datadir/dolibarr/htdocs/accountancy
%_datadir/dolibarr/htdocs/adherents
%_datadir/dolibarr/htdocs/admin
%_datadir/dolibarr/htdocs/ai
%_datadir/dolibarr/htdocs/api
%_datadir/dolibarr/htdocs/asset
%_datadir/dolibarr/htdocs/asterisk
Expand Down Expand Up @@ -309,6 +310,7 @@ done >>%{name}.lang
%_datadir/dolibarr/htdocs/user
%_datadir/dolibarr/htdocs/variants
%_datadir/dolibarr/htdocs/webhook
%_datadir/dolibarr/htdocs/webportal
%_datadir/dolibarr/htdocs/webservices
%_datadir/dolibarr/htdocs/website
%_datadir/dolibarr/htdocs/workstation
Expand Down
52 changes: 27 additions & 25 deletions build/rpm/dolibarr_mandriva.spec
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
#---------------------------------------------------------
# Spec file to build a rpm file
#
# This is an example to build a rpm file. You can use this
# file to build a package for your own distributions and
# This is an example to build a rpm file. You can use this
# file to build a package for your own distributions and
# edit it if you need to match your rules.
# --------------------------------------------------------

Name: dolibarr
Version: __VERSION__
Release: __RELEASE__
Summary: ERP and CRM software for small and medium companies or foundations
Summary: ERP and CRM software for small and medium companies or foundations
Summary(es): Software ERP y CRM para pequeñas y medianas empresas, asociaciones o autónomos
Summary(fr): Logiciel ERP & CRM de gestion de PME/PMI, auto-entrepreneurs ou associations
Summary(it): Programmo gestionale per piccole imprese, fondazioni e liberi professionisti
Expand All @@ -25,42 +25,42 @@ BuildArch: noarch
BuildRoot: %{_tmppath}/%{name}-%{version}-build

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
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

# Set yes to build test package, no for release (this disable need of /usr/bin/php not found by OpenSuse)
AutoReqProv: no


%description
An easy to use CRM & ERP open source/free software package for small
and medium companies, foundations or freelances. It includes different
features for Enterprise Resource Planning (ERP) and Customer Relationship
An easy to use CRM & ERP open source/free software package for small
and medium companies, foundations or freelances. It includes different
features for Enterprise Resource Planning (ERP) and Customer Relationship
Management (CRM) but also for different other activities.
Dolibarr was designed to provide only features you need and be easy to
Dolibarr was designed to provide only features you need and be easy to
use.

%description -l es
Un software ERP y CRM para pequeñas y medianas empresas, asociaciones
o autónomos. Incluye diferentes funcionalidades para la Planificación
o autónomos. Incluye diferentes funcionalidades para la Planificación
de Recursos Empresariales (ERP) y Gestión de la Relación con los
Clientes (CRM) así como para para otras diferentes actividades.
Clientes (CRM) así como para para otras diferentes actividades.
Dolibarr ha sido diseñado para suministrarle solamente las funcionalidades
que necesita y haciendo hincapié en su facilidad de uso.

%description -l fr
Logiciel ERP & CRM de gestion de PME/PMI, autoentrepreneurs,
artisans ou associations. Il permet de gérer vos clients, prospect,
Logiciel ERP & CRM de gestion de PME/PMI, autoentrepreneurs,
artisans ou associations. Il permet de gérer vos clients, prospect,
fournisseurs, devis, factures, comptes bancaires, agenda, campagnes mailings
et bien d'autres choses dans une interface pensée pour la simplicité.

%description -l it
Un programmo gestionale per piccole e medie
imprese, fondazioni e liberi professionisti. Include varie funzionalità per
Enterprise Resource Planning e gestione dei clienti (CRM), ma anche ulteriori
attività. Progettato per poter fornire solo ciò di cui hai bisogno
attività. Progettato per poter fornire solo ciò di cui hai bisogno
ed essere facile da usare.
Programmo web, progettato per poter fornire solo ciò di
Programmo web, progettato per poter fornire solo ciò di
cui hai bisogno ed essere facile da usare.


Expand Down Expand Up @@ -102,7 +102,7 @@ cui hai bisogno ed essere facile da usare.
%{__cp} -pr build/tgz/* $RPM_BUILD_ROOT%{_datadir}/%{name}/build/tgz
%{__cp} -pr htdocs $RPM_BUILD_ROOT%{_datadir}/%{name}
%{__cp} -pr scripts $RPM_BUILD_ROOT%{_datadir}/%{name}
%{__rm} -rf $RPM_BUILD_ROOT%{_datadir}/%{name}/htdocs/includes/ckeditor/_source
%{__rm} -rf $RPM_BUILD_ROOT%{_datadir}/%{name}/htdocs/includes/ckeditor/_source
%{__rm} -rf $RPM_BUILD_ROOT%{_datadir}/%{name}/htdocs/includes/fonts

# Lang
Expand All @@ -111,8 +111,8 @@ echo "%dir %{_datadir}/%{name}/htdocs/langs" >> %{name}.lang
for i in $RPM_BUILD_ROOT%{_datadir}/%{name}/htdocs/langs/*_*
do
lang=$(basename $i)
lang1=`expr substr $lang 1 2`;
lang2=`expr substr $lang 4 2 | tr "[:upper:]" "[:lower:]"`;
lang1=`expr substr $lang 1 2`;
lang2=`expr substr $lang 4 2 | tr "[:upper:]" "[:lower:]"`;
echo "%dir %{_datadir}/%{name}/htdocs/langs/${lang}" >> %{name}.lang
if [ "$lang1" = "$lang2" ] ; then
echo "%lang(${lang1}) %{_datadir}/%{name}/htdocs/langs/${lang}/*.lang"
Expand Down Expand Up @@ -156,6 +156,7 @@ done >>%{name}.lang
%_datadir/dolibarr/htdocs/accountancy
%_datadir/dolibarr/htdocs/adherents
%_datadir/dolibarr/htdocs/admin
%_datadir/dolibarr/htdocs/ai
%_datadir/dolibarr/htdocs/api
%_datadir/dolibarr/htdocs/asset
%_datadir/dolibarr/htdocs/asterisk
Expand Down Expand Up @@ -226,6 +227,7 @@ done >>%{name}.lang
%_datadir/dolibarr/htdocs/user
%_datadir/dolibarr/htdocs/variants
%_datadir/dolibarr/htdocs/webhook
%_datadir/dolibarr/htdocs/webportal
%_datadir/dolibarr/htdocs/webservices
%_datadir/dolibarr/htdocs/website
%_datadir/dolibarr/htdocs/workstation
Expand Down Expand Up @@ -259,7 +261,7 @@ export apachegroup='apache';
# Remove dolibarr install/upgrade lock file if it exists
%{__rm} -f $docdir/install.lock

# Create empty directory for uploaded files and generated documents
# Create empty directory for uploaded files and generated documents
echo Create document directory $docdir
%{__mkdir} -p $docdir

Expand All @@ -269,7 +271,7 @@ echo Create document directory $docdir
# If a conf already exists and its content was already completed by installer
export config=%{_sysconfdir}/dolibarr/conf.php
if [ -s $config ] && grep -q "File generated by" $config
then
then
# File already exist. We add params not found.
echo Add new params to overwrite path to use shared libraries/fonts
grep -q -c "dolibarr_lib_FPDI_PATH" $config || [ ! -d "/usr/share/php/fpdi" ] || echo "<?php \$dolibarr_lib_FPDI_PATH='/usr/share/php/fpdi'; ?>" >> $config
Expand Down Expand Up @@ -321,9 +323,9 @@ fi
echo
echo "----- Dolibarr %version-%release - (c) Dolibarr dev team -----"
echo "Dolibarr files are now installed (into /usr/share/dolibarr)."
echo "To finish installation and use Dolibarr, click on the menu"
echo "To finish installation and use Dolibarr, click on the menu"
echo "entry Dolibarr ERP-CRM or call the following page from your"
echo "web browser:"
echo "web browser:"
echo "http://localhost/dolibarr/"
echo "-------------------------------------------------------"
echo
Expand All @@ -339,15 +341,15 @@ then

# Define vars
export apachelink="%{_sysconfdir}/httpd/conf.d/dolibarr.conf"

# Remove apache link
if [ -L $apachelink ] ;
then
echo "Delete apache config link for Dolibarr ($apachelink)"
%{__rm} -f $apachelink
status=purge
fi

# Restart web servers if required
if [ "x$status" = "xpurge" ] ;
then
Expand Down
54 changes: 28 additions & 26 deletions build/rpm/dolibarr_opensuse.spec
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
#---------------------------------------------------------
# Spec file to build a rpm file
#
# This is an example to build a rpm file. You can use this
# file to build a package for your own distributions and
# This is an example to build a rpm file. You can use this
# file to build a package for your own distributions and
# edit it if you need to match your rules.
# --------------------------------------------------------

Name: dolibarr
Version: __VERSION__
Release: __RELEASE__
Summary: ERP and CRM software for small and medium companies or foundations
Summary: ERP and CRM software for small and medium companies or foundations
Summary(es): Software ERP y CRM para pequeñas y medianas empresas, asociaciones o autónomos
Summary(fr): Logiciel ERP & CRM de gestion de PME/PMI, auto-entrepreneurs ou associations
Summary(it): Programmo gestionale per piccole imprese, fondazioni e liberi professionisti
Expand All @@ -26,7 +26,7 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-build

Group: Productivity/Office/Management
Requires: apache2, apache2-mod_php, php >= 5.3.0, php-gd, php-ldap, php-imap, php-mysql, php-openssl, dejavu
Requires: mysql-community-server, mysql-community-server-client
Requires: mysql-community-server, mysql-community-server-client
%if 0%{?suse_version}
BuildRequires: update-desktop-files fdupes
%endif
Expand All @@ -36,34 +36,34 @@ AutoReqProv: no


%description
An easy to use CRM & ERP open source/free software package for small
and medium companies, foundations or freelances. It includes different
features for Enterprise Resource Planning (ERP) and Customer Relationship
An easy to use CRM & ERP open source/free software package for small
and medium companies, foundations or freelances. It includes different
features for Enterprise Resource Planning (ERP) and Customer Relationship
Management (CRM) but also for different other activities.
Dolibarr was designed to provide only features you need and be easy to
Dolibarr was designed to provide only features you need and be easy to
use.

%description -l es
Un software ERP y CRM para pequeñas y medianas empresas, asociaciones
o autónomos. Incluye diferentes funcionalidades para la Planificación
o autónomos. Incluye diferentes funcionalidades para la Planificación
de Recursos Empresariales (ERP) y Gestión de la Relación con los
Clientes (CRM) así como para para otras diferentes actividades.
Clientes (CRM) así como para para otras diferentes actividades.
Dolibarr ha sido diseñado para suministrarle solamente las funcionalidades
que necesita y haciendo hincapié en su facilidad de uso.

%description -l fr
Logiciel ERP & CRM de gestion de PME/PMI, autoentrepreneurs,
artisans ou associations. Il permet de gérer vos clients, prospect,
Logiciel ERP & CRM de gestion de PME/PMI, autoentrepreneurs,
artisans ou associations. Il permet de gérer vos clients, prospect,
fournisseurs, devis, factures, comptes bancaires, agenda, campagnes mailings
et bien d'autres choses dans une interface pensée pour la simplicité.

%description -l it
Un programmo gestionale per piccole e medie
imprese, fondazioni e liberi professionisti. Include varie funzionalità per
Enterprise Resource Planning e gestione dei clienti (CRM), ma anche ulteriori
attività. Progettato per poter fornire solo ciò di cui hai bisogno
attività. Progettato per poter fornire solo ciò di cui hai bisogno
ed essere facile da usare.
Programmo web, progettato per poter fornire solo ciò di
Programmo web, progettato per poter fornire solo ciò di
cui hai bisogno ed essere facile da usare.


Expand Down Expand Up @@ -102,7 +102,7 @@ cui hai bisogno ed essere facile da usare.
%{__cp} -pr build/tgz/* $RPM_BUILD_ROOT%{_datadir}/%{name}/build/tgz
%{__cp} -pr htdocs $RPM_BUILD_ROOT%{_datadir}/%{name}
%{__cp} -pr scripts $RPM_BUILD_ROOT%{_datadir}/%{name}
%{__rm} -rf $RPM_BUILD_ROOT%{_datadir}/%{name}/htdocs/includes/ckeditor/_source
%{__rm} -rf $RPM_BUILD_ROOT%{_datadir}/%{name}/htdocs/includes/ckeditor/_source
%{__rm} -rf $RPM_BUILD_ROOT%{_datadir}/%{name}/htdocs/includes/fonts

# Lang
Expand All @@ -111,8 +111,8 @@ echo "%dir %{_datadir}/%{name}/htdocs/langs" >> %{name}.lang
for i in $RPM_BUILD_ROOT%{_datadir}/%{name}/htdocs/langs/*_*
do
lang=$(basename $i)
lang1=`expr substr $lang 1 2`;
lang2=`expr substr $lang 4 2 | tr "[:upper:]" "[:lower:]"`;
lang1=`expr substr $lang 1 2`;
lang2=`expr substr $lang 4 2 | tr "[:upper:]" "[:lower:]"`;
echo "%dir %{_datadir}/%{name}/htdocs/langs/${lang}" >> %{name}.lang
if [ "$lang1" = "$lang2" ] ; then
echo "%lang(${lang1}) %{_datadir}/%{name}/htdocs/langs/${lang}/*.lang"
Expand Down Expand Up @@ -166,6 +166,7 @@ done >>%{name}.lang
%_datadir/dolibarr/htdocs/accountancy
%_datadir/dolibarr/htdocs/adherents
%_datadir/dolibarr/htdocs/admin
%_datadir/dolibarr/htdocs/ai
%_datadir/dolibarr/htdocs/api
%_datadir/dolibarr/htdocs/asset
%_datadir/dolibarr/htdocs/asterisk
Expand Down Expand Up @@ -236,6 +237,7 @@ done >>%{name}.lang
%_datadir/dolibarr/htdocs/user
%_datadir/dolibarr/htdocs/variants
%_datadir/dolibarr/htdocs/webhook
%_datadir/dolibarr/htdocs/webportal
%_datadir/dolibarr/htdocs/webservices
%_datadir/dolibarr/htdocs/website
%_datadir/dolibarr/htdocs/workstation
Expand Down Expand Up @@ -269,7 +271,7 @@ export apachegroup='www';
# Remove dolibarr install/upgrade lock file if it exists
%{__rm} -f $docdir/install.lock

# Create empty directory for uploaded files and generated documents
# Create empty directory for uploaded files and generated documents
echo Create document directory $docdir
%{__mkdir} -p $docdir

Expand All @@ -279,7 +281,7 @@ echo Create document directory $docdir
# If a conf already exists and its content was already completed by installer
export config=%{_sysconfdir}/dolibarr/conf.php
if [ -s $config ] && grep -q "File generated by" $config
then
then
# File already exist. We add params not found.
echo Add new params to overwrite path to use shared libraries/fonts
grep -q -c "dolibarr_lib_FPDI_PATH" $config || [ ! -d "/usr/share/php/fpdi" ] || echo "<?php \$dolibarr_lib_FPDI_PATH='/usr/share/php/fpdi'; ?>" >> $config
Expand All @@ -291,7 +293,7 @@ then
grep -q -c "dolibarr_js_JQUERY" $config || [ ! -d "/usr/share/javascript/jquery" ] || echo "<?php \$dolibarr_js_JQUERY='/javascript/jquery'; ?>" >> $config
grep -q -c "dolibarr_js_JQUERY_UI" $config || [ ! -d "/usr/share/javascript/jquery-ui" ] || echo "<?php \$dolibarr_js_JQUERY_UI='/javascript/jquery-ui'; ?>" >> $config
grep -q -c "dolibarr_js_JQUERY_FLOT" $config || [ ! -d "/usr/share/javascript/flot" ] || echo "<?php \$dolibarr_js_JQUERY_FLOT='/javascript/flot'; ?>" >> $config
grep -q -c "dolibarr_font_DOL_DEFAULT_TTF_BOLD" $config || echo "<?php \$dolibarr_font_DOL_DEFAULT_TTF_BOLD='/usr/share/fonts/truetype/DejaVuSans-Bold.ttf'; ?>" >> $config
grep -q -c "dolibarr_font_DOL_DEFAULT_TTF_BOLD" $config || echo "<?php \$dolibarr_font_DOL_DEFAULT_TTF_BOLD='/usr/share/fonts/truetype/DejaVuSans-Bold.ttf'; ?>" >> $config
fi

# Create a config link dolibarr.conf
Expand Down Expand Up @@ -331,9 +333,9 @@ fi
echo
echo "----- Dolibarr %version-%release - (c) Dolibarr dev team -----"
echo "Dolibarr files are now installed (into /usr/share/dolibarr)."
echo "To finish installation and use Dolibarr, click on the menu"
echo "To finish installation and use Dolibarr, click on the menu"
echo "entry Dolibarr ERP-CRM or call the following page from your"
echo "web browser:"
echo "web browser:"
echo "http://localhost/dolibarr/"
echo "-------------------------------------------------------"
echo
Expand All @@ -346,18 +348,18 @@ if [ "x$1" = "x0" ] ;
then
# Remove
echo "Removed package"

# Define vars
export apachelink="%{_sysconfdir}/apache2/conf.d/dolibarr.conf"

# Remove apache link
if [ -L $apachelink ] ;
then
echo "Delete apache config link for Dolibarr ($apachelink)"
%{__rm} -f $apachelink
status=purge
fi

# Restart web servers if required
if [ "x$status" = "xpurge" ] ;
then
Expand Down
Loading

0 comments on commit 36d2ce7

Please sign in to comment.