2
0
forked from Wavyzz/dolibarr

Compare commits

..

131 Commits
9.0.1 ... 8.0.5

Author SHA1 Message Date
Juanjo Menent
7041c3246e Prepare 8.0.5 2019-05-11 22:35:56 +02:00
Juanjo Menent
40229c9d96 Merge pull request #11166 from simnandez/8.0
Merge branch '7.0' into 8.0
2019-05-11 18:06:20 +02:00
Juanjo Menent
f4ca6916cd Merge remote-tracking branch 'upstream/7.0' into 8.0
# Conflicts:
#	htdocs/contrat/services_list.php
#	htdocs/expensereport/list.php
#	htdocs/projet/list.php
2019-05-11 17:31:23 +02:00
Juanjo Menent
3a99ef7319 Fix: missing GETPOST params 2019-05-11 17:04:05 +02:00
Juanjo Menent
3ae2d71ea6 Fix: missing GETPOST params 2019-05-11 17:00:55 +02:00
Juanjo Menent
91ae365588 Fix: missing GETPOST params 2019-05-11 16:58:00 +02:00
Juanjo Menent
6206519456 Fix: missing GETPOST params 2019-05-11 16:54:56 +02:00
Juanjo Menent
2e6cb2afaa Fix: missing GETPOST params 2019-05-11 16:53:16 +02:00
Juanjo Menent
dc9f8a349f Fix: missing GETPOST params 2019-05-11 16:50:31 +02:00
Juanjo Menent
80ef97e215 FIX: #11025 2019-05-11 16:41:01 +02:00
Juanjo Menent
759427f6ac FIX: #11025 2019-05-11 16:36:35 +02:00
Juanjo Menent
81bf7d07e3 Merge remote-tracking branch 'upstream/7.0' into 7.0 2019-05-11 16:32:02 +02:00
Juanjo Menent
72dd3705ed Merge remote-tracking branch 'upstream/7.0' into 7.0 2019-05-10 09:13:33 +02:00
Laurent Destailleur
6a5af0511d Merge pull request #11105 from atm-greg/FIX_stock_movement_link_to_project
fix project link for stock correction
2019-05-03 11:27:17 +02:00
atm-greg
e0c3cf8360 fix project link for stock correction 2019-05-03 10:24:49 +02:00
Laurent Destailleur
45d618cd7a Merge branch '8.0' of git@github.com:Dolibarr/dolibarr.git into 8.0 2019-05-02 14:37:54 +02:00
Laurent Destailleur
ae7ba162f2 Merge branch '7.0' of git@github.com:Dolibarr/dolibarr.git into 8.0 2019-05-02 14:37:46 +02:00
Laurent Destailleur
1a16dc1166 Merge pull request #11089 from frederic34/patch-5
Fix do not delete all discount when splitting (supplier)
2019-05-02 14:05:49 +02:00
Laurent Destailleur
50b1a54dca FIX Update/delete currency on same languages 2019-05-01 14:06:30 +02:00
Frédéric FRANCE
d9a1c2b235 Fix do not delete all discount when splitting 2019-04-30 13:54:50 +02:00
Laurent Destailleur
a7530b7eff Merge branch '7.0' of git@github.com:Dolibarr/dolibarr.git into 8.0 2019-04-27 13:28:36 +02:00
Laurent Destailleur
0532598ecf Merge branch '7.0' of git@github.com:Dolibarr/dolibarr.git into 7.0 2019-04-27 13:28:05 +02:00
Laurent Destailleur
410a3801da Merge branch '6.0' of git@github.com:Dolibarr/dolibarr.git into 7.0 2019-04-27 13:27:52 +02:00
Laurent Destailleur
5259547b96 Merge pull request #11069 from atm-gauthier/6.0_fix_select_prev_situ
Fix prev situation invoice selection (backport fix 8.0)
2019-04-25 18:59:48 +02:00
gauthier
31897f54ac Fix prev situation invoice selection (backport fix 8.0) 2019-04-25 12:37:05 +02:00
Laurent Destailleur
50a4d54d8a Merge branch '8.0' of git@github.com:Dolibarr/dolibarr.git into 8.0 2019-04-25 01:37:32 +02:00
Laurent Destailleur
07caf22647 Merge branch '7.0' of git@github.com:Dolibarr/dolibarr.git into 8.0 2019-04-25 01:37:25 +02:00
Laurent Destailleur
b62323939e Merge pull request #11064 from atm-greg/FIX_create_supplier_invoice_button
FIX test to display create invoice button on supplier_order card
2019-04-24 21:07:15 +02:00
atm-greg
70017da95a testing if customer invoice module is activated doesn't make sense on supplier commande card... 2019-04-24 14:59:54 +02:00
Laurent Destailleur
fb01f550f4 Merge pull request #11016 from ATM-Nicolas/fix_activity_perweek
FIX : Total per day in timespent per week
2019-04-24 10:21:08 +02:00
Laurent Destailleur
21b79d314a Merge pull request #11059 from atm-greg/FIX_actioncomm_for_long_trigger_name
fix actioncomm module for long trigger names
2019-04-24 10:06:55 +02:00
atm-greg
6e425d1895 add origin of line in fourn orderstoinvoice.php 2019-04-24 08:56:06 +02:00
atm-greg
3231e54abd fix actioncomm module for long trigger names 2019-04-23 16:19:58 +02:00
Laurent Destailleur
bf7fcce1b2 Merge branch '7.0' of git@github.com:Dolibarr/dolibarr.git into 8.0 2019-04-23 12:24:25 +02:00
Laurent Destailleur
11d737f23a Merge pull request #11029 from ATM-Marc/FIX_7.0_sort_events
FIX: actioncomm: sort events by date after external calendars and hook (into 7.0)
2019-04-19 13:06:09 +02:00
Laurent Destailleur
c9445ee700 Merge pull request #11038 from atm-john/FIX_error_messages_not_displayed
FIX error messages not displayed
2019-04-19 12:55:30 +02:00
John BOTELLA
0855d84ccf FIX error messages not displayed 2019-04-18 10:40:34 +02:00
Laurent Destailleur
91af1f8702 Merge pull request #11011 from ATM-Nicolas/fix_search_contact_list
FIX : Wrong variable name
2019-04-16 23:43:58 +02:00
Laurent Destailleur
c0defe3965 Update index.php 2019-04-16 23:27:45 +02:00
Marc de Lima Lucio
1669d497b4 FIX: actioncomm: sort events by date after external calendars and hook 2019-04-16 17:36:27 +02:00
ATM-Nicolas
93365addd1 FIX : Total per day shows 00:00 if the total time spent is equal to 12:00 2019-04-15 11:40:58 +02:00
ATM-Nicolas
d4a7c0abc6 FIX : Wrong variable name 2019-04-15 10:05:46 +02:00
Juanjo Menent
1b5cabad71 Fix: #10956 2019-04-12 18:50:48 +02:00
Laurent Destailleur
6cd24ab210 Merge pull request #10998 from atm-gauthier/8.0_fix_ProductAccountancySellIntraCode_is_feature_level_1
FIX : Product accountancey sell intra code must be visible if main feature level 1
2019-04-11 16:20:11 +02:00
gauthier
9a24007c0a FIX : better test 2019-04-11 15:32:50 +02:00
gauthier
524b186959 FIX : Product accountancey sell intra code must be visible if main feature level 1 2019-04-11 15:19:40 +02:00
Laurent Destailleur
ffca289bff Merge branch '7.0' of git@github.com:Dolibarr/dolibarr.git into 8.0 2019-04-08 14:04:42 +02:00
Laurent Destailleur
125796b0f5 Merge pull request #10967 from atm-ph/fix_7.0_timesheet_init_hook
Fix no init hook on timesheet
2019-04-08 13:49:21 +02:00
Laurent Destailleur
c1f0826005 Update perweek.php 2019-04-08 13:49:16 +02:00
Laurent Destailleur
153e563c9f Update perday.php 2019-04-08 13:49:05 +02:00
Laurent Destailleur
cd1322de79 Merge pull request #10959 from atm-arnaud/8.0_fix_shipping_default_warehouse_if_one
FIX shipping default warehouse if only one warehouse
2019-04-08 13:32:34 +02:00
atm-ph
ea87b2ddb6 Fix no init hook on timesheet 2019-04-05 11:26:11 +02:00
Laurent Destailleur
eaf9a2402a Fix length of label 2019-04-04 17:39:51 +02:00
Laurent Destailleur
4489db2a70 Fix field surface/weight not loaded 2019-04-04 17:06:26 +02:00
atm-arnaud
0b6c7d2d63 FIX shipping default warehouse if only one warehouse 2019-04-04 11:17:44 +02:00
Laurent Destailleur
17a61b3232 Merge branch '7.0' of git@github.com:Dolibarr/dolibarr.git into 8.0 2019-04-02 19:34:49 +02:00
Laurent Destailleur
26fbd6e2ec Merge branch '7.0' of git@github.com:Dolibarr/dolibarr.git into 7.0 2019-04-02 19:34:16 +02:00
Laurent Destailleur
cb1489e2fa Merge branch '6.0' of git@github.com:Dolibarr/dolibarr.git into 7.0 2019-04-02 19:34:10 +02:00
Laurent Destailleur
2f51221660 Merge pull request #10933 from atm-greg/Add_final_hooks_on_replenish
Add all missing hooks on replenish
2019-03-31 18:50:34 +02:00
Laurent Destailleur
f671b8bce7 Merge pull request #10945 from aspangaro/7_p1
FIX: Don't show accountingjournal:getNomUrl without data
2019-03-31 18:49:50 +02:00
Laurent Destailleur
143cbba09b Update card.php 2019-03-31 18:49:38 +02:00
Laurent Destailleur
5dfc1c0897 Merge pull request #10921 from atm-greg/Fix_hook_in_margins_heads
FIX missing hook completeTabsHead in margins module
2019-03-31 18:21:48 +02:00
Alexandre SPANGARO
5588fe5b81 FIX: Don't show journal:getNomUrl without data
ErrorBadValueForParamNotAString
2019-03-30 09:42:13 +01:00
atm-greg
957fae1081 missing params 2019-03-28 11:07:27 +01:00
atm-greg
11343e986c add all missing hooks on replenish 2019-03-28 10:47:32 +01:00
atm-greg
83d7750274 FIX missing hook completeTabsHead in margins module 2019-03-27 09:33:51 +01:00
Laurent Destailleur
e5f54bd14c FIX Remane of project 2019-03-26 12:35:44 +01:00
Laurent Destailleur
3ede626932 FIX If we build one invoice for several orders, we must put the ref of
order on the line to not lose information.

Conflicts:
	htdocs/commande/list.php
	htdocs/core/actions_massactions.inc.php
2019-03-23 22:34:10 +01:00
Laurent Destailleur
37cc5b7d35 Merge pull request #10901 from fmarcet/8.0
FIX: The minimum amount filter does not work in VAT report by customer
2019-03-22 12:27:30 +01:00
Ferran Marcet
f37c1b9287 FIX: The minimum amount filter does not work in the VAT report per customer 2019-03-22 09:28:50 +01:00
Laurent Destailleur
75b94d373f Merge pull request #10897 from frederic34/patch-4
Update extrafields.class.php
2019-03-21 18:27:04 +01:00
Laurent Destailleur
1075ef8cf2 Merge branch '7.0' of git@github.com:Dolibarr/dolibarr.git into 8.0 2019-03-21 18:25:43 +01:00
Laurent Destailleur
f7f20df323 Merge pull request #10891 from atm-greg/Add_hook_on_replenish
Add hook on replenish
2019-03-21 18:23:06 +01:00
Frédéric FRANCE
d10b94e72b Update extrafields.class.php 2019-03-21 14:08:49 +01:00
Laurent Destailleur
a1fe1bb58c FIX when 2 extra fields are mandatory in 2 different entities 2019-03-21 12:33:39 +01:00
Laurent Destailleur
032aa869e4 FIX Can't insert if there is extrafields mandatory on another entity.
FIX Can't set default value of extrafield of type varchar
2019-03-21 12:14:15 +01:00
Laurent Destailleur
4c85068a85 FIX Can't insert if there is extrafields mandatory on another entity. 2019-03-21 11:53:04 +01:00
Laurent Destailleur
b11403103b Merge branch '8.0' of git@github.com:Dolibarr/dolibarr.git into 8.0 2019-03-19 13:09:48 +01:00
Laurent Destailleur
8664594fc8 Merge branch '7.0' of git@github.com:Dolibarr/dolibarr.git into 8.0 2019-03-19 13:09:39 +01:00
Laurent Destailleur
775aa5ff91 Merge pull request #10870 from hregis/8.0_mc2
FIX missing entity filter and wrong var name
2019-03-19 11:11:22 +01:00
Laurent Destailleur
89087c6847 Merge pull request #10800 from atm-quentin/FIX_wrong_vat_deposit_invoice
Wrong vat if deposit from propal with multiple vat
2019-03-18 11:14:11 +01:00
Regis Houssin
57091f08b0 FIX missing entity filter and wrong var name 2019-03-18 10:53:43 +01:00
Laurent Destailleur
468af5380f Merge pull request #10857 from atm-maxime/fix_creditnote_refund
Fix #9961 : deal with supplier credit note refund like with customers
2019-03-16 19:40:22 +01:00
Maxime Kohlhaas
46b39dd6a9 Fix #9961 : deal with supplier credit note refund like with customers 2019-03-16 18:13:43 +01:00
Laurent Destailleur
ae35c982af Merge pull request #9652 from atm-gauthier/7.0_fix_round_debitcredit
FIX : need to round with 2 decimals to avoid movements not correctly balanced
2019-03-16 14:27:03 +01:00
Laurent Destailleur
55718cc7da Merge pull request #10855 from atm-maxime/fix_missing_lang
Fix #9311
2019-03-16 13:43:35 +01:00
Laurent Destailleur
efeb7b0c22 Merge pull request #10854 from atm-maxime/fix_civility_third_creation
Fix #10177
2019-03-16 13:41:29 +01:00
Maxime Kohlhaas
21e2d36421 Fix #9311 2019-03-16 09:28:47 +01:00
Maxime Kohlhaas
68945c7d51 Fix #10177 2019-03-16 09:11:43 +01:00
Laurent Destailleur
681d626284 Merge branch '7.0' of git@github.com:Dolibarr/dolibarr.git into 8.0 2019-03-15 19:17:31 +01:00
Laurent Destailleur
4bb45ad1c1 Merge pull request #10824 from atm-gauthier/7.0_fix_nocreateline_deposit_if_amount_zero
FIX : when we create deposit with multi tva, we mustn't add line if a…
2019-03-15 19:16:56 +01:00
Laurent Destailleur
b33c366b02 Update card.php 2019-03-15 19:16:49 +01:00
Laurent Destailleur
abf529770d Merge branch '7.0' of git@github.com:Dolibarr/dolibarr.git into 8.0 2019-03-15 19:13:23 +01:00
Laurent Destailleur
482a37a2c9 Merge pull request #10850 from atm-ph/fix_7.0_var_name
Fix var name
2019-03-15 19:12:55 +01:00
atm-ph
2da60fb885 Fix var name 2019-03-15 15:15:03 +01:00
Laurent Destailleur
84bff41543 Merge branch '7.0' of git@github.com:Dolibarr/dolibarr.git into 8.0 2019-03-15 11:00:24 +01:00
Laurent Destailleur
6c2cad3d48 Merge branch '6.0' of git@github.com:Dolibarr/dolibarr.git into 7.0
Conflicts:
	htdocs/core/lib/security.lib.php
2019-03-15 11:00:00 +01:00
Laurent Destailleur
8711e51bce Merge pull request #10841 from atm-gauthier/6.0_notest_tab_documents_on_expensereport
FIX : no need to test anything to display documents tabs on expense report
2019-03-15 10:56:53 +01:00
gauthier
8375b47e74 FIX : in fact expensereport must be in $check array 2019-03-15 10:21:50 +01:00
Laurent Destailleur
a8bd8a2101 Merge branch '7.0' of git@github.com:Dolibarr/dolibarr.git into 8.0 2019-03-14 18:49:24 +01:00
Laurent Destailleur
5ec8adb7f5 Merge branch '6.0' of git@github.com:Dolibarr/dolibarr.git into 7.0 2019-03-14 18:48:35 +01:00
Laurent Destailleur
4f84a1614c Merge pull request #10808 from ATM-Marc/FIX_8.0_shipment_hooks
FIX: several hooks in shipping/delivery cards
2019-03-14 18:07:57 +01:00
gauthier
3fb6978bc8 FIX : no need to test anything to display documents tabs on expense report 2019-03-14 17:36:49 +01:00
Laurent Destailleur
eab1e13343 Merge pull request #10839 from atm-gauthier/6.0_fix_useless_join
FIX : useless join
2019-03-14 17:12:38 +01:00
gauthier
885797b748 FIX : useless join 2019-03-14 17:00:51 +01:00
Laurent Destailleur
feaca165ad Merge pull request #10809 from joanlouis/fix-extrafields-calls-from-cards-8
Fix extrafields calls from cards for Dolibarr 8 See #10803
2019-03-14 14:22:31 +01:00
gauthier
a524bbc5c6 FIX : when we create deposit with multi tva, we mustn't add line if amount = 0 (example when we have a 100% reduc on one of origin invoice line) 2019-03-13 15:59:41 +01:00
Marc de Lima Lucio
36b44b1348 FIX: several hooks in shipping/delivery cards 2019-03-12 11:28:36 +01:00
Joan Louis
17647de4cc Fix extrafields calls from cards for Dolibarr 8 See #10803 2019-03-12 11:24:54 +01:00
Laurent Destailleur
15cc21b89f Merge pull request #10783 from aspangaro/8.0_EBP_export-TXT
FIX: Accountancy - Format EBP import
2019-03-11 17:52:34 +01:00
atm-quentin
ab781c32c7 Wrong vat if deposit from propal with multiple vat 2019-03-11 11:28:25 +01:00
Alexandre SPANGARO
49f72b6a9a Merge remote-tracking branch 'upstream/8.0' into 8.0_EBP_export-TXT 2019-03-09 05:50:16 +01:00
Laurent Destailleur
5596b2e9bf Merge branch '7.0' of git@github.com:Dolibarr/dolibarr.git into 8.0
Conflicts:
	htdocs/fourn/class/fournisseur.facture.class.php
2019-03-09 00:02:56 +01:00
Laurent Destailleur
520387c03d Merge branch '6.0' of git@github.com:Dolibarr/dolibarr.git into 7.0
Conflicts:
	htdocs/holiday/card.php
2019-03-09 00:01:29 +01:00
Laurent Destailleur
4022d5f529 FIX Can not create contract with numbering module without autogen rule 2019-03-08 23:58:04 +01:00
Laurent Destailleur
233bd4374a Fix phpcs 2019-03-08 19:52:26 +01:00
Alexandre SPANGARO
d926657534 FIX: Accountancy - Format EBP import
Add doc
2019-03-08 10:57:14 +01:00
Laurent Destailleur
9a9fd15077 Fix doxygen 2019-03-07 14:10:33 +01:00
Laurent Destailleur
d2f1d0cc33 Merge branch '7.0' of git@github.com:Dolibarr/dolibarr.git into 8.0
Conflicts:
	htdocs/fourn/class/fournisseur.facture.class.php
2019-03-07 14:06:11 +01:00
Laurent Destailleur
e96f84a3d6 Merge pull request #10765 from altatof/sd8
FIX : supplier discount was not retrieved when choosing a product
2019-03-07 13:26:44 +01:00
Laurent Destailleur
0349f9bfaa Update objectline_create.tpl.php 2019-03-07 13:26:25 +01:00
Laurent Destailleur
2ae3d75df4 Merge pull request #10752 from atm-gauthier/7.0_fix_fourninvoice_specialcode
FIX : we need to keep originline special_code
2019-03-07 12:29:00 +01:00
Laurent Destailleur
e3fb228a4d Update fournisseur.facture.class.php 2019-03-07 12:28:19 +01:00
Christophe Battarel
96b8da0d62 fix supllier discount 2019-03-06 22:04:01 +01:00
gauthier
0ff2905180 FIX : we need to keep originline special_code 2019-03-06 12:10:24 +01:00
Laurent Destailleur
22bb62d900 Merge pull request #10737 from atm-gauthier/6.0_fix_wrong_redirect_link
FIX : wrong redirect link on holiday refuse
2019-03-05 18:43:57 +01:00
Laurent Destailleur
3db8218cba Merge pull request #10745 from frederic34/patch-6
add session newtoken
2019-03-05 18:41:50 +01:00
Frédéric FRANCE
1bbf6737ec add session newtoken 2019-03-05 15:27:31 +01:00
gauthier
dada8c8ff5 FIX : wrong redirect link on holiday refuse 2019-03-04 17:23:29 +01:00
gauthier
2142ccee8a FIX : better method 2019-02-08 15:17:40 +01:00
gauthier
d6a9da57e1 FIX : need to round with 2 decimals to avoid movements not correctly balanced 2018-10-01 14:11:19 +02:00
3314 changed files with 79777 additions and 148121 deletions

View File

@@ -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@inodbox.com> Regis Houssin <regis@dolibarr.fr>
Regis Houssin <regis.houssin@inodbox.com> Régis Houssin <regishoussin@device5.home>
Regis Houssin <regis.houssin@capnetworks.com> Regis Houssin <regis@dolibarr.fr>
Regis Houssin <regis.houssin@capnetworks.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>

View File

@@ -2,7 +2,7 @@
# from Dolibarr GitHub repository.
# For syntax, see http://about.travis-ci.org/docs/user/languages/php/
# We use dist: trusty to have php 5.4+ available
# We use dist: trusty to have php 5.4+ available
dist: trusty
sudo: required
@@ -20,7 +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'
- key_url: 'https://www.postgresql.org/media/keys/ACCC4CF8.asc'
packages:
# We need a webserver to test the webservices
# Let's install Apache with.
@@ -37,7 +37,6 @@ php:
- '7.0'
- '7.1'
- '7.2'
- '7.3'
- nightly
env:
@@ -70,8 +69,6 @@ matrix:
env: DB=mariadb
- php: '7.1'
env: DB=mariadb
- php: '7.2'
env: DB=mariadb
- php: '5.5'
env: DB=postgresql
- php: '5.6'
@@ -80,8 +77,6 @@ matrix:
env: DB=postgresql
- php: '7.1'
env: DB=postgresql
- php: '7.2'
env: DB=postgresql
- php: nightly
env: DB=postgresql
@@ -110,7 +105,7 @@ before_install:
pgloader --version
echo
fi
install:
- |
echo "Updating Composer"
@@ -135,14 +130,14 @@ install:
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" = '7.3' ] || [ "$TRAVIS_PHP_VERSION" = 'nightly' ]; then
if [ "$TRAVIS_PHP_VERSION" = '7.2' ] || [ "$TRAVIS_PHP_VERSION" = 'nightly' ]; then
composer -n require phpunit/phpunit ^5
fi
echo
- |
echo "Installing PHP CodeSniffer"
composer -n require squizlabs/php_codesniffer ^3
composer -n require squizlabs/php_codesniffer ^2
echo
- |
@@ -170,9 +165,13 @@ before_script:
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 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
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
@@ -200,7 +199,7 @@ before_script:
mysql --version | head -
mysql -e "SELECT VERSION();" | head -
echo
- |
echo "Setting up database"
if [ "$DB" = 'mysql' ] || [ "$DB" = 'mariadb' ] || [ "$DB" = 'postgresql' ]; then
@@ -208,18 +207,13 @@ before_script:
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 -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
#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
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
@@ -227,7 +221,7 @@ before_script:
- |
export CONF_FILE=htdocs/conf/conf.php
echo "Setting up Dolibarr $CONF_FILE"
echo '<?php' > $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
@@ -236,11 +230,9 @@ before_script:
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
@@ -250,9 +242,8 @@ before_script:
- |
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
mkdir -p documents/admin/temp
echo "first line" > documents/dolibarr.log
echo
@@ -262,7 +253,7 @@ before_script:
# enable php-fpm
- 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
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
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
@@ -285,12 +276,11 @@ before_script:
script:
- |
echo "Checking webserver availability by a wget -O - http://127.0.0.1"
# Ensure we stop on error with set -e
set +e
# Ensure we catch errors
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
@@ -298,8 +288,7 @@ script:
echo "Checking PHP syntax errors"
# Ensure we catch errors
set -e
#parallel-lint --exclude htdocs/includes --blame .
parallel-lint --exclude htdocs/includes/sabre --exclude htdocs/includes/phpoffice/phpexcel/Classes/PHPExcel/Shared --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 .
parallel-lint --exclude htdocs/includes --blame .
set +e
echo
@@ -319,7 +308,7 @@ script:
- |
echo "Upgrading Dolibarr"
# Ensure we catch errors. Set this to +e if you want to go to the end to see log files.
# Ensure we catch errors
set +e
cd htdocs/install
php upgrade.php 3.5.0 3.6.0 ignoredbversion > $TRAVIS_BUILD_DIR/upgrade350360.log
@@ -335,7 +324,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 > $TRAVIS_BUILD_DIR/upgrade390400-2.log
php upgrade2.php 3.9.0 4.0.0 MAIN_MODULE_API,MAIN_MODULE_SUPPLIERPROPOSAL > $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
@@ -344,38 +333,38 @@ 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 > $TRAVIS_BUILD_DIR/upgrade600700-2.log
php upgrade2.php 6.0.0 7.0.0 MAIN_MODULE_WEBSITE,MAIN_MODULE_SUPPLIERPROPOSAL > $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 upgrade2.php 7.0.0 8.0.0 MAIN_MODULE_TICKETSUP > $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
# 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 /tmp/dolibarr_install.log
cat $TRAVIS_BUILD_DIR/enablemodule.log
#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 $TRAVIS_BUILD_DIR/upgrade600700-2.log
cat /tmp/dolibarr_install.log
- |
echo "Unit testing"
# 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:
- |
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
# Dolibarr log file
#echo "After script"
#cat documents/dolibarr.log
after_success:
- |
@@ -383,24 +372,20 @@ after_success:
after_failure:
- |
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
echo Failure
# This part of code seems to be never executed, error or not ???
echo "Debugging informations"
# Upgrade log files
for ficlog in `ls $TRAVIS_BUILD_DIR/*.log`
do
echo "Debugging informations for file $ficlog"
#cat $ficlog
done
cat *.log
echo "Debugging informations"
# Apache log file
echo "Debugging informations for file apache error.log"
sudo cat /var/log/apache2/travis_error_log
sudo cat /var/log/apache2/error.log
# Dolibarr log file
cat documents/dolibarr.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
echo "Debugging informations for file mysql error.log"
sudo tail -n 50 /var/log/mysql/error.log
sudo cat /var/log/mysql/error.log
# TODO: PostgreSQL log file
echo
fi

View File

@@ -53,10 +53,6 @@ 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
For licenses compatibility informations:
http://www.gnu.org/licenses/licenses.en.html

215
ChangeLog
View File

@@ -3,173 +3,89 @@ English Dolibarr ChangeLog
--------------------------------------------------------------
***** ChangeLog for 9.0.1 compared to 9.0.0 *****
***** ChangeLog for 8.0.5 compared to 8.0.4 *****
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: #11025
FIX: Accountancy - Add transaction with multicompany use all the time 1st entity
FIX: Accountancy - Format EBP import
FIX: actioncomm export: ORDER BY clause is in wrong export property + event type filter does not work
FIX: actioncomm: sort events by date after external calendars and hook
FIX: action list: add printFieldListSelect and printFieldListWhere hooks
FIX: add fk_unit on addline action
FIX: adding css by page if url is externam
FIX: Bad link in menu manager
FIX: avoid php warning
FIX: bad sql request
FIX: better method
FIX: better test
FIX: better test on fetch
FIX: broken external authentication module feature and avoid warning
FIX: Can not create contract with numbering module without autogen rule
FIX: can't add lines on invoices
FIX: Can't generate invoice pdf
FIX: Can't insert if there is extrafields mandatory on another entity.
FIX: Can't insert if there is extrafields mandatory on another entity. FIX: Can't set default value of extrafield of type varchar
FIX: Check for old picture name if the new one was not found
FIX: Civility not saved when creating a member.
FIX: $conf->fournisseur->commande->enabled doesn't exist, we must use $conf->fournisseur->enabled
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: credit note can have negative value
FIX: Default value on sales representative on third party creation
FIX: Don't show journal:getNomUrl without data
FIX: Erreur dans le Total
FIX: error messages not displayed
FIX: expedition: reset status on rollback + replace hardcoded status with const
FIX: fetch module / pos source
FIX: Fix PHP warning "count(): Parameter must be an array..."
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: holidays get natural_search if search params are set only
FIX: if empty error message, we just see "error" displayed
FIX: label of bank account
FIX: if(!method_exists(dol_loginfunction))
FIX: If we build one invoice for several orders, we must put the ref of order on the line to not lose information.
FIX: in fact expensereport must be in $check array
FIX: Interface regression for bind people. Fix option MAIN_OPTIMIZEFORTEXTBROWSER
FIX: line edit template: keep fk_parent_line
FIX: Loan impossible to account
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 entity filter and wrong var name
FIX: missing entity filter in function "build_filterField()" (export)
FIX: Missing field in import/export of users
FIX: missing hook completeTabsHead in margins module
FIX: missing $ismultientitymanaged for previous/next ref
FIX: Missing province in export of invoice
FIX: multicompany compatibility
FIX: must fetch member in current entity
FIX: need an order by in case we found other invoice with same number but not same date
FIX: need to round with 2 decimals to avoid movements not correctly balanced
FIX: no need to test anything to display documents tabs on expense report
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: problem with multicompany transverse mode
FIX: Product accountancey sell intra code must be visible if main feature level 1
FIX: project_title for display of getNomUrl()
FIX: quick search for supplier orders
FIX: Remane of project
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: Selection of email recipient with option MAIN_OPTIMIZEFORTEXTBROWSER
FIX: several hooks in shipping/delivery cards
FIX: shipping default warehouse if only one warehouse
FIX: SQL injection on rowid of dict.php
FIX: 'statut' is ignored when updating a user with the REST API.
FIX: supplier invoice payment total dont 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: The minimum amount filter does not work in the VAT report per customer
FIX: Total per day shows 00:00 if the total time spent is equal to 12:00
FIX: Update/delete currency on same languages
FIX: [URGENT] broken feature, "$usercancreate" is for Dolibarr 9
FIX: useless join
FIX: we need to keep originline special_code
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 project on payment of salaries
NEW: Add SHIPPING_PDF_HIDE_WEIGHT_AND_VOLUME and
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 somes hooks in bank planned entries
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
FIX: when 2 extra fields are mandatory in 2 different entities
FIX: when we add a payment on an invoice which already has payments with credit note or deposit amount, and then we get an excess received, discount amount must be $total_paiements + $total_creditnote_and_deposit - $object->total_ttc;
FIX: when we create deposit with multi tva, we mustn't add line if amount = 0 (example when we have a 100% reduc on one of origin invoice line)
FIX: wrong redirect link on holiday refuse
FIX: wrong test enabled
FIX: Wrong variable name
FIX: XSS
***** ChangeLog for 8.0.4 compared to 8.0.3 *****
FIX: #10030 better german chart
@@ -385,17 +301,18 @@ 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: Accept anonmymous 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: Can create event from record card of a company and member
NEW: Add a button to create Stripe customer from the 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 any predefined mail content
NEW: Add arrows to navigate into containers in 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
@@ -482,7 +399,7 @@ 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 assign category to thirparty that are not customer nor prospect nor 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

View File

@@ -15,55 +15,49 @@ Dolibarr est distribué sous les termes de la licence GNU General Public License
## INSTALLER DOLIBARR
### Configuration simple
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).
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:
Vous pouvez les télécharger depuis la rubrique *download* du portail officiel:
https://www.dolibarr.org/
- DoliWamp pour Windows
- DoliDeb pour Debian ou Ubuntu
- DoliRpm pour Redhat, Fedora, OpenSuse, Mandriva ou Mageia
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:
Les packages peuvent être téléchargés à partir de [site web officiel] (https://www.dolibarr.org/).
- 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).
### Configuration avancée
- 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...
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
    LURL 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 à jour Dolibarr depuis une vieille version vers celle ci:
- Ecrasez les vieux fichiers dans le vieux répertoire 'dolibarr' par les fichiers
Pour mettre a jour Dolibarr depuis une vieille version vers celle ci:
- Ecraser les vieux fichiers dans le vieux repertoire 'dolibarr' par les fichiers
fournis dans ce nouveau package.
- 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/*
- 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/*
## CE QUI EST NOUVEAU
@@ -100,15 +94,14 @@ 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, Stripe, Paybox...)
- Intégration de système de paiements (Paypal, Strip, Paybox...)
-
### Divers:
@@ -121,18 +114,9 @@ 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
@@ -142,7 +126,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 fonctionnalités pas encore gérées par Dolibarr:
Voici un liste de fonctionnalites 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.
@@ -151,7 +135,7 @@ Voici un liste de fonctionnalités pas encore gérées par Dolibarr:
## DOCUMENTATION
La documentation utilisateur, développeur et traducteur est disponible sous forme de ressources de la communauté via le site [Wiki](https://wiki.dolibarr.org).
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).
## CONTRIBUER

View File

@@ -1,11 +1,6 @@
# DOLIBARR ERP & CRM
![Downloads per day](https://img.shields.io/sourceforge/dm/dolibarr.svg)
[![Reviewed by Hound](https://img.shields.io/badge/Reviewed_by-Hound-8E64B0.svg)](https://houndci.com)
|6|7|8|9|develop|
|----------|----------|----------|----------|----------|
|![Build status](https://img.shields.io/travis/Dolibarr/dolibarr/6.0.svg)|![Build status](https://img.shields.io/travis/Dolibarr/dolibarr/7.0.svg)|![Build status](https://img.shields.io/travis/Dolibarr/dolibarr/8.0.svg)|![Build status](https://img.shields.io/travis/Dolibarr/dolibarr/9.0.svg)|![Build status](https://img.shields.io/travis/Dolibarr/dolibarr/develop.svg)|
![Build status](https://img.shields.io/travis/Dolibarr/dolibarr/8.0.svg) ![Downloads per day](https://img.shields.io/sourceforge/dm/dolibarr.svg)
Dolibarr ERP & CRM is a modern software package to manage your organization's activity (contacts, suppliers, invoices, orders, stocks, agenda…).
@@ -29,6 +24,27 @@ 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:
@@ -37,23 +53,16 @@ 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 .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 you'r web server does not have directory to point to already defined.
- 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)
- 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)
- From your browser, go to the dolibarr "install/" page
The URL will depends on how you web setup was setup to point to your dolibarr installation. It may looks like:
The URL will depends on choices made in the first step:
http://localhost/dolibarr/htdocs/install/
@@ -116,6 +125,7 @@ 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
@@ -137,15 +147,13 @@ 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 a lot of country specific features:
- Support for 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...
-

View File

@@ -16,20 +16,18 @@ 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.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.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-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
@@ -48,6 +46,9 @@ 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.

123
build/aps/APP-META-1.1.xml Normal file
View File

@@ -0,0 +1,123 @@
<!-- 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>

121
build/aps/APP-META-1.2.xml Normal file
View File

@@ -0,0 +1,121 @@
<!-- 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>

View File

@@ -0,0 +1,89 @@
<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:&nbsp;+41-526320-411</p>
<p class="copyright">Fax: +41-52672-2010</p>
<p class="copyright">&nbsp;</p>
<p class="copyright">Copyright © 1999-2011 Parallels Holdings, Ltd. and its affiliates.&nbsp;All rights reserved.&nbsp;</p>
<p class="copyright">&nbsp;</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.&nbsp;</p>
<p class="copyright">&nbsp;</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 -->

View File

@@ -0,0 +1,64 @@
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;
}
}
}
}

View File

@@ -0,0 +1,60 @@
/* 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

20
build/aps/README Normal file
View File

@@ -0,0 +1,20 @@
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'

151
build/aps/configure.php Executable file
View File

@@ -0,0 +1,151 @@
#!/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;
}

View File

@@ -0,0 +1,23 @@
<?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';

View File

@@ -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@inodbox.com>
2004-2013, Regis Houssin <regis.houssin@capnetworks.com>
2004, Sebastien Di Cintio <sdicintio@ressource-toi.org>
2004, Benoit Mortier <benoit.mortier@opensides.be>
2004, Christophe Combelles <ccomb@free.fr>

View File

@@ -1 +0,0 @@
htdocs/install/doctemplates/websites/website_template-corporate.zip

View File

@@ -3,30 +3,18 @@ FROM php:7.0-apache
ENV HOST_USER_ID 33
ENV PHP_INI_DATE_TIMEZONE 'UTC'
RUN apt-get update && apt-get install -y libpng-dev libjpeg-dev libldap2-dev \
RUN apt-get update && apt-get install -y libpng12-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 libjpeg-dev libldap2-dev
&& apt-get purge -y libpng12-dev 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"]

View File

@@ -3,27 +3,42 @@ 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>

View File

@@ -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 (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...
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...
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 (iexplore.exe, firefox.exe, chrome.exe, MicrosoftEdge.exe...). If you are not sure, just click Open :
ChooseDefaultBrowser=Please choose your default browser. 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=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.
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.
ContinueAnyway=Continue anyway (install process may fails without this prerequisite)

View File

@@ -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 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...
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...
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 (iexplore.exe, firefox.exe, chrome.exe, MicrosoftEdge.exe...). Si vous n'<27>tes pas s<>r, cliquez simplement sur Ouvrir :
ChooseDefaultBrowser=Merci de choisir votre navigateur par d<>faut. Si vous n'<27>tes pas s<>r, cliquez simplement sur Ouvrir :
LaunchNow=Lancer Dolibarr maintenant
@@ -44,5 +44,3 @@ 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)

View File

@@ -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 distributed (for Windows).
to be distributedt (for Windows).

View File

@@ -32,7 +32,7 @@ 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-2019 Laurent Destailleur (NLTechno), Fabian Rodriguez (Le Goût du Libre)
AppCopyright=Copyright (C) 2008-2017 Laurent Destailleur (NLTechno), Fabian Rodriguez (Le Goût du Libre)
DefaultDirName=c:\dolibarr
DefaultGroupName=Dolibarr
;LicenseFile=COPYING

View File

@@ -3,4 +3,4 @@ REM Launch Dolibarr Admin center
REM ----------------------------
REM Go to admin center page
start "WAMPBROWSER" http://localhost:WAMPAPACHEPORT/
start "DoliWamp admin" "WAMPBROWSER" http://localhost:WAMPAPACHEPORT/

View File

@@ -4,4 +4,4 @@ REM ---------------------------
REM Go to help center page
echo Please wait...
start "WAMPBROWSER" http://localhost:WAMPAPACHEPORT/dolibarr/support/
start "Dolibarr Help center" "WAMPBROWSER" http://localhost:WAMPAPACHEPORT/dolibarr/support/

View File

@@ -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 "WAMPBROWSER" http://localhost:WAMPAPACHEPORT/dolibarr/install/
IF NOT EXIST dolibarr_documents\install.lock start "Dolibarr" "WAMPBROWSER" http://localhost:WAMPAPACHEPORT/dolibarr/install/
REM If lock file exists, we call home page
IF EXIST dolibarr_documents\install.lock start "WAMPBROWSER" http://localhost:WAMPAPACHEPORT/dolibarr/
IF EXIST dolibarr_documents\install.lock start "Dolibarr" "WAMPBROWSER" http://localhost:WAMPAPACHEPORT/dolibarr/

View File

@@ -1 +0,0 @@
Help wanted...

View File

@@ -34,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");
/*

View File

@@ -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","EXEDOLIWAMP","SNAPSHOT"); # Possible packages
#@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
%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 dpatch",
"FLATPACK"=>"flatpack",
"DEB"=>"dpkg",
"APS"=>"zip",
"EXEDOLIWAMP"=>"ISCC.exe",
"SNAPSHOT"=>"tar"
);
@@ -142,6 +142,7 @@ $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';
@@ -387,15 +388,6 @@ 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";
@@ -544,8 +536,6 @@ if ($nboftargetok) {
$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*`;
@@ -560,14 +550,12 @@ 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/workstation*`;
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/accountingexport*`;
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/themes/oblyon*`;
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/themes/allscreen*`;
# Removed other test files
@@ -598,8 +586,6 @@ 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-*`;
@@ -706,7 +692,7 @@ if ($nboftargetok) {
print "Go to directory $BUILDROOT\n";
$olddir=getcwd();
chdir("$BUILDROOT");
$cmd= "xz -9 -r $BUILDROOT/$FILENAMEXZ.xz \*";
$cmd= "xz -9 -r $BUILDROOT/$FILENAMEAPS.xz \*";
print $cmd."\n";
$ret= `$cmd`;
chdir("$olddir");
@@ -1047,6 +1033,92 @@ if ($nboftargetok) {
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;
@@ -1068,7 +1140,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= "wine ISCC.exe \"Z:$SOURCEBACK\\build\\exe\\doliwamp\\doliwamp.tmp.iss\"";
$cmd= "ISCC.exe \"Z:$SOURCEBACK\\build\\exe\\doliwamp\\doliwamp.tmp.iss\"";
print "$cmd\n";
$ret= `$cmd`;
#print "$ret\n";

View File

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

View File

@@ -30,7 +30,7 @@ return "Regis Houssin";
# script_dolibarr_versions()
sub script_dolibarr_versions
{
return ( "9.0.0", "8.0.3", "7.0.4", "6.0.8", "5.0.7" );
return ( "7.0.0", "6.0.5", "5.0.7" );
}
sub script_dolibarr_release
@@ -263,16 +263,15 @@ 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. (deprecated)
# local $dinstall = "$opts->{'dir'}/install";
# $dinstall =~ s/\/$//;
# $out = &run_as_domain_user($d, "rm -rf ".quotemeta($dinstall));
# Remove the installation directory.
local $dinstall = "$opts->{'dir'}/install";
$dinstall =~ s/\/$//;
$out = &run_as_domain_user($d, "rm -rf ".quotemeta($dinstall));
}
else {
@@ -307,18 +306,15 @@ 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 (deprecated)
# local $dinstall = "$opts->{'dir'}/install";
# $dinstall =~ s/\/$//;
# $out = &run_as_domain_user($d, "rm -rf ".quotemeta($dinstall));
# Protect config file
# 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));
&set_permissions_as_domain_user($d, 0644, $cfile);
&set_permissions_as_domain_user($d, 0755, $cfiledir);
}
@@ -390,8 +386,6 @@ sub script_dolibarr_check_latest
{
local ($ver) = @_;
local @vers = &osdn_package_versions("dolibarr",
$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" :

View File

@@ -177,11 +177,9 @@ 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
@@ -214,7 +212,6 @@ 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

View File

@@ -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%_datadir/dolibarr/htdocs/datapolicy
%else
%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%_datadir/dolibarr/htdocs/datapolicy
%{__mkdir} $RPM_BUILD_ROOT
%{__mkdir} $RPM_BUILD_ROOT%{_sysconfdir}
%{__mkdir} $RPM_BUILD_ROOT%{_sysconfdir}/%{name}
%else
@@ -257,11 +257,9 @@ 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
@@ -294,7 +292,6 @@ 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

View File

@@ -174,11 +174,9 @@ 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
@@ -211,7 +209,6 @@ 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

View File

@@ -185,11 +185,9 @@ 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
@@ -222,7 +220,6 @@ 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

View File

@@ -1,6 +1,5 @@
<VirtualHost *:80>
DocumentRoot %TRAVIS_BUILD_DIR%/htdocs
ErrorLog /var/log/apache2/travis_error_log
<Directory "%TRAVIS_BUILD_DIR%/htdocs/">
Options FollowSymLinks MultiViews ExecCGI

View File

@@ -1,5 +1,5 @@
This file describes changes made on external libraries after being included
This file describe changes made on external library after beeing included
in Dolibarr root.
@@ -48,23 +48,6 @@ into
// initialize subsetchars
$subsetchars = array_fill(0, 256, true);
* Replace the continue into switch with a break:
case 're': {
// justify block
if (!TCPDF_STATIC::empty_string($this->lispacer)) {
$this->lispacer = '';
continue;
}
into
case 're': {
// justify block
if (!TCPDF_STATIC::empty_string($this->lispacer)) {
$this->lispacer = '';
break;
}
* Optionnaly, removed all fonts except
dejavusans* (used by greek, arab, persan, romanian, turkish),
freemono* (russian),
@@ -78,24 +61,17 @@ In htdocs/includes/tcpdf/tcpdf.php
+ 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:

View File

@@ -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
@@ -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);

View File

@@ -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
@@ -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);

View File

@@ -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
@@ -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);

View File

@@ -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
@@ -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);

View File

@@ -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
@@ -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);

View File

@@ -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&eacute;<br>fdsfsdf<br>fsdf<strong>sfd</strong>s<br>fssdfsd<br></body></html>
<html><head><title></title></head><body>Test&eacute;<br />fdsfsdf<br />fsdf<strong>sfd</strong>s<br />fssdfsd<br /></body></html>

View File

@@ -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");
/*
@@ -185,4 +185,7 @@ while ($i < GEN_NUMBER_FACTURE && $result >= 0)
{
dol_print_error($db,$object->error);
}
}

View File

@@ -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");
/*

View File

@@ -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';

View File

@@ -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
@@ -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;
@@ -218,4 +218,6 @@ while ($i < GEN_NUMBER_PROPAL && $result >= 0)
{
dol_print_error($db,$object->error);
}
}

View File

@@ -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';

View File

@@ -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
*/
@@ -36,7 +36,7 @@ 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";
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';
@@ -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

View File

@@ -36,7 +36,7 @@ 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";
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';

View File

@@ -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
*/
@@ -36,7 +36,7 @@ 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";
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';
@@ -118,15 +118,15 @@ 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);
$object->firstname = trim($tmp[0]);
$object->lastname = trim($tmp[1]);
@@ -134,23 +134,23 @@ while ($fields=fgetcsv($fhandle, $linelength, $delimiter, $enclosure, $escape))
else $object->login=strtolower($object->firstname);
$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

View File

@@ -36,7 +36,7 @@ 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";
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,7 +44,8 @@ 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->loadLangs(array("main", "errors"));
$langs->load("main");
$langs->load("errors");
// Global variables
$version=DOL_VERSION;

View File

@@ -0,0 +1,3 @@
<?php
// Wrapper to include main into htdocs
include_once '/home/ldestailleur/git/dolibarr_3.8/htdocs/main.inc.php';

View File

@@ -0,0 +1,3 @@
<?php
// Wrapper to include master into htdocs
include_once '/home/ldestailleur/git/dolibarr_3.8/htdocs/master.inc.php';

Binary file not shown.

After

Width:  |  Height:  |  Size: 360 KiB

View File

@@ -6,11 +6,11 @@
# WARNING: This script erase all data of database
# with data into dump file
#
# Regis Houssin - regis.houssin@inodbox.com
# Regis Houssin - regis.houssin@capnetworks.com
# Laurent Destailleur - eldy@users.sourceforge.net
#------------------------------------------------------
# Usage: initdemo.sh confirm
# usage: initdemo.sh confirm mysqldump_dolibarr_x.x.x.sql database port login pass
# Usage: initdemo.sh
# usage: initdemo.sh mysqldump_dolibarr_x.x.x.sql database port login pass
#------------------------------------------------------
@@ -31,20 +31,11 @@ fi
# ----------------------------- command line params
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
dumpfile=$1;
base=$2;
port=$3;
admin=$4;
passwd=$5;
# ----------------------------- if no params on command line
@@ -141,14 +132,11 @@ 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 Document dir : '$documentdir' \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 Mysql database : '$base' \n Mysql port : '$port' \n Mysql login: '$admin' \n Mysql password : '$passwd'" 15 55
case $? in
0) echo "Ok, start process...";;
@@ -177,44 +165,15 @@ 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/"
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
mkdir -p "$documentdir/ecm/Administrative documents"
mkdir -p "$documentdir/ecm/Images"
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

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -3,7 +3,7 @@
# Script to remove setup of a Dolibarr installation.
# Note: "dialog" tool need to be available.
#
# Regis Houssin - regis.houssin@inodbox.com
# Regis Houssin - regis.houssin@capnetworks.com
# Laurent Destailleur - eldy@users.sourceforge.net
#------------------------------------------------------
# WARNING: This script erase setup of instance,

View File

@@ -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@inodbox.com
# Regis Houssin - regis.houssin@capnetworks.com
# Laurent Destailleur - eldy@users.sourceforge.net
#------------------------------------------------------
# Usage: savedemo.sh
@@ -171,8 +171,6 @@ 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
@@ -191,9 +189,6 @@ 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
@@ -251,8 +246,6 @@ 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

View File

@@ -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 && 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';
include_once(DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php');
/*

View File

@@ -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 && 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';
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++;
}

View File

@@ -0,0 +1,12 @@
<?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>

View File

@@ -0,0 +1,53 @@
<?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>

View File

@@ -4,7 +4,6 @@
<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>
@@ -12,29 +11,43 @@
<exclude-pattern type="relative">*/nltechno*</exclude-pattern>
<exclude-pattern type="relative">*/htdocs/includes</exclude-pattern>
<exclude-pattern type="relative">*.min.css</exclude-pattern>
<exclude-pattern type="relative">*.js</exclude-pattern>
<!-- 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">
<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.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>
<!-- <rule ref="Generic.CodeAnalysis.ForLoopShouldBeWhileLoop" /> -->
@@ -50,22 +63,7 @@
<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" />
<!--
@@ -149,7 +147,7 @@
<rule ref="Generic.PHP.DeprecatedFunctions.Deprecated">
<severity>0</severity>
</rule>
<rule ref="Generic.PHP.DisallowShortOpenTag" />
<rule ref="Generic.PHP.ForbiddenFunctions" />
@@ -165,7 +163,7 @@
<rule ref="Generic.Strings.UnnecessaryStringConcat.Found">
<severity>0</severity>
</rule>
<!-- Disallow usage of tab -->
<!-- <rule ref="Generic.WhiteSpace.DisallowTabIndent" /> -->
@@ -173,24 +171,7 @@
<!-- Disabled as this does not support tab -->
<!-- <rule ref="Generic.WhiteSpace.ScopeIndent" /> -->
<!-- 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.Functions.MultiLineFunctionDeclaration" />
<!-- Rules from PEAR Standard -->
@@ -205,7 +186,7 @@
<rule ref="PEAR.Commenting.ClassComment.Missing">
<severity>0</severity>
</rule>
<rule ref="PEAR.Commenting.ClassComment.MissingTag">
<severity>0</severity>
</rule>
@@ -225,14 +206,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>
@@ -244,20 +225,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">
@@ -273,11 +254,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>
@@ -304,20 +285,7 @@
<!-- <rule ref="PEAR.ControlStructures.MultiLineCondition" /> -->
<!-- Test if () are removed for includes -->
<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.Files.IncludingFile"/> -->
<rule ref="PEAR.Formatting.MultiLineAssignment" />
@@ -347,14 +315,14 @@
<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>
@@ -362,7 +330,7 @@
<rule ref="PEAR.NamingConventions.ValidClassName.StartWithCaptial">
<severity>0</severity>
</rule>
<rule ref="PEAR.NamingConventions.ValidFunctionName" />
<rule ref="PEAR.NamingConventions.ValidFunctionName.FunctionDoubleUnderscore">
@@ -379,37 +347,31 @@
<severity>0</severity>
</rule>
<!--<rule ref="PEAR.NamingConventions.ValidFunctionName.NotCamelCaps">
<rule ref="PEAR.NamingConventions.ValidFunctionName.NotCamelCaps">
<severity>0</severity>
</rule>-->
<!--<rule ref="PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps">
<severity>0</severity>
</rule>-->
</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" />
<!-- 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" /> -->

View File

@@ -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 -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
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
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 -v 'documents\/website' | 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 CRLF | awk -F':' '{ print $1 }' `
do
echo "Fix file $fic"
dos2unix "$fic"

View File

@@ -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);

View File

@@ -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);

View File

@@ -64,7 +64,8 @@ class autoTranslator
// Translate
//ini_set('default_charset','UTF-8');
ini_set('default_charset',$this->_outputpagecode);
$this->parseRefLangTranslationFiles();
$this->parse_refLangTranslationFiles();
}
/**
@@ -72,7 +73,7 @@ class autoTranslator
*
* @return void
*/
private function parseRefLangTranslationFiles()
private function parse_refLangTranslationFiles()
{
$files = $this->getTranslationFilesArray($this->_refLang);
@@ -345,4 +346,5 @@ class autoTranslator
return $rep;
}
}

View File

@@ -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,7 +88,7 @@ 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]);

View File

@@ -295,7 +295,6 @@ 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;

Binary file not shown.

Before

Width:  |  Height:  |  Size: 268 KiB

After

Width:  |  Height:  |  Size: 124 KiB

View File

@@ -11,15 +11,15 @@ informations on Dolibarr.<br>
But if you are looking for other resources (downloads, documentation, addons, ...), you can find this
on Internet on web following sites:<br>
<br>
* <a href="https://wiki.dolibarr.org">Dolibarr wiki (documentation)</a><br>
* <a href="http://wiki.dolibarr.org">Dolibarr wiki (documentation)</a><br>
<br>
* <a href="https://www.dolibarr.org">Dolibarr portal (official website)</a><br>
* <a href="http://www.dolibarr.org">Dolibarr portal (official website)</a><br>
<br>
* <a href="https://demo.dolibarr.org">Dolibarr demo (online)</a><br>
* <a href="http://demo.dolibarr.org">Dolibarr demo (online)</a><br>
<br>
* <a href="https://www.nltechno.com/pages/dolibarrwinbin.php">DoliWamp, the Dolibarr for Windows</a><br>
* <a href="http://www.nltechno.com/pages/dolibarrwinbin.php">DoliWamp, the Dolibarr for Windows</a><br>
<br>
* <a href="https://www.dolistore.com">DoliStore (official addons/plugins market place)</a><br>
* <a href="http://www.dolistore.com">DoliStore (official addons/plugins market place)</a><br>
</body>
</html>

View File

@@ -9,19 +9,19 @@ Téléchargement
* Dolibarr ERP/CRM can be downloaded at sourceforge:
http://sourceforge.net/projects/dolibarr/files
or from Dolibarr official web site:
https://www.dolibarr.org
http://www.dolibarr.org
* Most external modules are only available on DoliStore:
https://www.dolistore.org
http://www.dolistore.org
--------------------------------
Documentation utilisateur
--------------------------------
* Pour une prise en main et installation rapide, consultez le fichier
* Pour une prise en main et installation rapide, consulter le fichier
README-FR à la racine.
* Une documentation utilisateur francophone plus consistante est disponible en
* Une documentation utilisateur francophone plus consistente est disponible en
ligne sur le wiki de Dolibarr à l'adresse:
https://wiki.dolibarr.org
http://wiki.dolibarr.org

View File

@@ -4,4 +4,4 @@ User guide
--------------------------------
* All Dolibarr guides are available, on line, on the Dolibarr Web site:
https://www.dolibarr.org
http://www.dolibarr.org

View File

@@ -3,9 +3,9 @@ README (french)
Documentation utilisateur
--------------------------------
* Pour une prise en main et installation rapide, consultez le fichier
* Pour une prise en main et installation rapide, consulter le fichier
README-FR à la racine.
* Une documentation utilisateur francophone plus consistante est disponible en
* Une documentation utilisateur francophone plus consistente est disponible en
ligne sur le site Web de Dolibarr à l'adresse:
https://www.dolibarr.fr
http://www.dolibarr.fr

6
htdocs/.gitignore vendored
View File

@@ -23,8 +23,4 @@
/cabinetmed*
/webmail*
/conf/conf.php
/subtotal*
/abricot*
/nomenclature*
/of/
/workstation/
/subtotal/

View File

@@ -38,11 +38,11 @@ $id = GETPOST('id', 'int');
$rowid = GETPOST('rowid', 'int');
$contextpage=GETPOST('contextpage','aZ')?GETPOST('contextpage','aZ'):'accountingaccountlist'; // To manage different context of search
$search_account = GETPOST('search_account','alpha');
$search_label = GETPOST('search_label','alpha');
$search_accountparent = GETPOST('search_accountparent','alpha');
$search_pcgtype = GETPOST('search_pcgtype','alpha');
$search_pcgsubtype = GETPOST('search_pcgsubtype','alpha');
$search_account = GETPOST("search_account");
$search_label = GETPOST("search_label");
$search_accountparent = GETPOST("search_accountparent");
$search_pcgtype = GETPOST("search_pcgtype");
$search_pcgsubtype = GETPOST("search_pcgsubtype");
// Security check
if ($user->societe_id > 0) accessforbidden();
@@ -133,7 +133,7 @@ if (empty($reshook))
}
$offsetforchartofaccount+=($conf->entity * 100000000);
$result = run_sql($sqlfile, 1, $conf->entity, 1, '', 'default', 32768, 0, $offsetforchartofaccount);
$result = run_sql($sqlfile, 1, $conf->entity, 1, '', 'default', $offsetforchartofaccount);
if ($result > 0)
{
@@ -427,6 +427,5 @@ if ($resql)
dol_print_error($db);
}
// End of page
llxFooter();
$db->close();

View File

@@ -2,7 +2,7 @@
/* Copyright (C) 2004 Rodolphe Quiedeville <rodolphe@quiedeville.org>
* Copyright (C) 2004-2015 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2004 Benoit Mortier <benoit.mortier@opensides.be>
* Copyright (C) 2005-2012 Regis Houssin <regis.houssin@inodbox.com>
* Copyright (C) 2005-2012 Regis Houssin <regis.houssin@capnetworks.com>
* Copyright (C) 2010-2016 Juanjo Menent <jmenent@2byte.es>
* Copyright (C) 2011-2018 Philippe Grand <philippe.grand@atoo-net.com>
* Copyright (C) 2011 Remy Younes <ryounes@gmail.com>
@@ -44,7 +44,7 @@ if (! empty($conf->accounting->enabled)) require_once DOL_DOCUMENT_ROOT . '/core
// Load translation files required by the page
$langs->loadLangs(array("errors","admin","companies","resource","holiday","compta","accountancy","hrm"));
$action=GETPOST('action','aZ09')?GETPOST('action','aZ09'):'view';
$action=GETPOST('action','alpha')?GETPOST('action','alpha'):'view';
$confirm=GETPOST('confirm','alpha');
$id=31;
$rowid=GETPOST('rowid','alpha');
@@ -55,8 +55,8 @@ $acts[1] = "disable";
$actl[0] = img_picto($langs->trans("Disabled"),'switch_off');
$actl[1] = img_picto($langs->trans("Activated"),'switch_on');
$listoffset=GETPOST('listoffset','alpha');
$listlimit=GETPOST('listlimit','int')>0?GETPOST('listlimit','int'):1000;
$listoffset=GETPOST('listoffset');
$listlimit=GETPOST('listlimit')>0?GETPOST('listlimit'):1000;
$active = 1;
$sortfield = GETPOST("sortfield",'aZ09comma');
@@ -139,13 +139,13 @@ $sourceList=array();
* Actions
*/
if (GETPOST('button_removefilter','alpha') || GETPOST('button_removefilter.x','alpha') || GETPOST('button_removefilter_x','alpha'))
if (GETPOST('button_removefilter') || GETPOST('button_removefilter.x') || GETPOST('button_removefilter_x'))
{
$search_country_id = '';
}
// Actions add or modify an entry into a dictionary
if (GETPOST('actionadd','alpha') || GETPOST('actionmodify','alpha'))
if (GETPOST('actionadd') || GETPOST('actionmodify'))
{
$listfield=explode(',', str_replace(' ', '',$tabfield[$id]));
$listfieldinsert=explode(',',$tabfieldinsert[$id]);
@@ -235,7 +235,7 @@ if (GETPOST('actionadd','alpha') || GETPOST('actionmodify','alpha'))
if ($_POST["accountancy_code_buy"] <= 0) $_POST["accountancy_code_buy"]=''; // If empty, we force to null
// Si verif ok et action add, on ajoute la ligne
if ($ok && GETPOST('actionadd','alpha'))
if ($ok && GETPOST('actionadd'))
{
if ($tabrowid[$id])
{
@@ -247,6 +247,7 @@ if (GETPOST('actionadd','alpha') || GETPOST('actionmodify','alpha'))
{
$obj = $db->fetch_object($result);
$newid=($obj->newid + 1);
} else {
dol_print_error($db);
}
@@ -299,7 +300,7 @@ if (GETPOST('actionadd','alpha') || GETPOST('actionmodify','alpha'))
}
// Si verif ok et action modify, on modifie la ligne
if ($ok && GETPOST('actionmodify','alpha'))
if ($ok && GETPOST('actionmodify'))
{
if ($tabrowid[$id]) { $rowidcol=$tabrowid[$id]; }
else { $rowidcol="rowid"; }
@@ -340,7 +341,7 @@ if (GETPOST('actionadd','alpha') || GETPOST('actionmodify','alpha'))
//$_GET["id"]=GETPOST('id', 'int'); // Force affichage dictionnaire en cours d'edition
}
if (GETPOST('actioncancel','alpha'))
if (GETPOST('actioncancel'))
{
//$_GET["id"]=GETPOST('id', 'int'); // Force affichage dictionnaire en cours d'edition
}
@@ -523,18 +524,62 @@ if ($id)
$valuetoshow=ucfirst($fieldlist[$field]); // Par defaut
$valuetoshow=$langs->trans($valuetoshow); // try to translate
$align="left";
if ($fieldlist[$field]=='source') { $valuetoshow=$langs->trans("Contact"); }
if ($fieldlist[$field]=='price') { $valuetoshow=$langs->trans("PriceUHT"); }
if ($fieldlist[$field]=='taux') {
if ($tabname[$id] != MAIN_DB_PREFIX."c_revenuestamp") $valuetoshow=$langs->trans("Rate");
else $valuetoshow=$langs->trans("Amount");
$align='right';
}
if ($fieldlist[$field]=='localtax1_type') { $valuetoshow=$langs->trans("UseLocalTax")." 2"; $align="center"; $sortable=0; }
if ($fieldlist[$field]=='localtax1') { $valuetoshow=$langs->trans("Rate")." 2";}
if ($fieldlist[$field]=='localtax2_type') { $valuetoshow=$langs->trans("UseLocalTax")." 3"; $align="center"; $sortable=0; }
if ($fieldlist[$field]=='localtax2') { $valuetoshow=$langs->trans("Rate")." 3";}
if ($fieldlist[$field]=='organization') { $valuetoshow=$langs->trans("Organization"); }
if ($fieldlist[$field]=='lang') { $valuetoshow=$langs->trans("Language"); }
if ($fieldlist[$field]=='type') {
if ($tabname[$id] == MAIN_DB_PREFIX."c_paiement") $valuetoshow=$form->textwithtooltip($langs->trans("Type"),$langs->trans("TypePaymentDesc"),2,1,img_help(1,''));
else $valuetoshow=$langs->trans("Type");
}
if ($fieldlist[$field]=='code') { $valuetoshow=$langs->trans("Code"); }
if ($fieldlist[$field]=='libelle' || $fieldlist[$field]=='label')
{
$valuetoshow=$langs->trans("Label");
if ($id != 25) $valuetoshow.="*";
}
if ($fieldlist[$field]=='libelle_facture') { $valuetoshow=$langs->trans("LabelOnDocuments")."*"; }
if ($fieldlist[$field]=='country') {
if (in_array('region_id',$fieldlist)) { print '<td>&nbsp;</td>'; continue; } // For region page, we do not show the country input
$valuetoshow=$langs->trans("Country");
}
if ($fieldlist[$field]=='country_id') { $valuetoshow=''; }
if ($fieldlist[$field]=='recuperableonly') { $valuetoshow=$langs->trans("NPR"); $align="center"; }
if ($fieldlist[$field]=='nbjour') { $valuetoshow=$langs->trans("NbOfDays"); }
if ($fieldlist[$field]=='type_cdr') { $valuetoshow=$langs->trans("AtEndOfMonth"); $align="center"; }
if ($fieldlist[$field]=='decalage') { $valuetoshow=$langs->trans("Offset"); }
if ($fieldlist[$field]=='width') { $valuetoshow=$langs->trans("Width"); }
if ($fieldlist[$field]=='height') { $valuetoshow=$langs->trans("Height"); }
if ($fieldlist[$field]=='unit') { $valuetoshow=$langs->trans("MeasuringUnit"); }
if ($fieldlist[$field]=='region_id' || $fieldlist[$field]=='country_id') { $valuetoshow=''; }
if ($fieldlist[$field]=='accountancy_code'){ $valuetoshow=$langs->trans("AccountancyCode"); }
if ($fieldlist[$field]=='accountancy_code_sell'){ $valuetoshow=$langs->trans("AccountancyCodeSell"); }
if ($fieldlist[$field]=='accountancy_code_buy'){ $valuetoshow=$langs->trans("AccountancyCodeBuy"); }
if ($fieldlist[$field]=='pcg_version' || $fieldlist[$field]=='fk_pcg_version') { $valuetoshow=$langs->trans("Pcg_version"); }
if ($fieldlist[$field]=='account_parent') { $valuetoshow=$langs->trans("Accountparent"); }
if ($fieldlist[$field]=='pcg_type') { $valuetoshow=$langs->trans("Pcg_type"); }
if ($fieldlist[$field]=='pcg_subtype') { $valuetoshow=$langs->trans("Pcg_subtype"); }
if ($fieldlist[$field]=='sortorder') { $valuetoshow=$langs->trans("SortOrder"); }
if ($fieldlist[$field]=='short_label') { $valuetoshow=$langs->trans("ShortLabel"); }
if ($fieldlist[$field]=='type_template') { $valuetoshow=$langs->trans("TypeOfTemplate"); }
if ($fieldlist[$field]=='range_account') { $valuetoshow=$langs->trans("Range"); }
if ($fieldlist[$field]=='sens') { $valuetoshow=$langs->trans("Sens"); }
if ($fieldlist[$field]=='category_type') { $valuetoshow=$langs->trans("Calculated"); }
if ($fieldlist[$field]=='formula') { $valuetoshow=$langs->trans("Formula"); }
if ($id == 2) // Special cas for state page
{
if ($fieldlist[$field]=='region_id') { $valuetoshow='&nbsp;'; $showfield=1; }
if ($fieldlist[$field]=='region') { $valuetoshow=$langs->trans("Country").'/'.$langs->trans("Region"); $showfield=1; }
}
if ($valuetoshow != '')
{
@@ -559,7 +604,7 @@ if ($id)
$obj = new stdClass();
// If data was already input, we define them in obj to populate input fields.
if (GETPOST('actionadd','alpha'))
if (GETPOST('actionadd'))
{
foreach ($fieldlist as $key=>$val)
{
@@ -664,15 +709,50 @@ if ($id)
*/
$valuetoshow=ucfirst($fieldlist[$field]); // By defaut
$valuetoshow=$langs->trans($valuetoshow); // try to translate
if ($fieldlist[$field]=='source') { $valuetoshow=$langs->trans("Contact"); }
if ($fieldlist[$field]=='price') { $valuetoshow=$langs->trans("PriceUHT"); }
if ($fieldlist[$field]=='taux') {
if ($tabname[$id] != MAIN_DB_PREFIX."c_revenuestamp") $valuetoshow=$langs->trans("Rate");
else $valuetoshow=$langs->trans("Amount");
$align='right';
}
if ($fieldlist[$field]=='localtax1_type') { $valuetoshow=$langs->trans("UseLocalTax")." 2"; $align="center"; $sortable=0; }
if ($fieldlist[$field]=='localtax1') { $valuetoshow=$langs->trans("Rate")." 2"; $sortable=0; }
if ($fieldlist[$field]=='localtax2_type') { $valuetoshow=$langs->trans("UseLocalTax")." 3"; $align="center"; $sortable=0; }
if ($fieldlist[$field]=='localtax2') { $valuetoshow=$langs->trans("Rate")." 3"; $sortable=0; }
if ($fieldlist[$field]=='organization') { $valuetoshow=$langs->trans("Organization"); }
if ($fieldlist[$field]=='lang') { $valuetoshow=$langs->trans("Language"); }
if ($fieldlist[$field]=='type') { $valuetoshow=$langs->trans("Type"); }
if ($fieldlist[$field]=='code') { $valuetoshow=$langs->trans("Code"); }
if ($fieldlist[$field]=='libelle' || $fieldlist[$field]=='label')
{
$valuetoshow=$langs->trans("Label");
if ($id != 25) $valuetoshow.="*";
}
if ($fieldlist[$field]=='libelle_facture') { $valuetoshow=$langs->trans("LabelOnDocuments")."*"; }
if ($fieldlist[$field]=='country') { $valuetoshow=$langs->trans("Country"); }
if ($fieldlist[$field]=='country_id') { $showfield=0; }
if ($fieldlist[$field]=='recuperableonly') { $valuetoshow=$langs->trans("NPR"); $align="center"; }
if ($fieldlist[$field]=='nbjour') { $valuetoshow=$langs->trans("NbOfDays"); }
if ($fieldlist[$field]=='type_cdr') { $valuetoshow=$langs->trans("AtEndOfMonth"); $align="center"; }
if ($fieldlist[$field]=='decalage') { $valuetoshow=$langs->trans("Offset"); }
if ($fieldlist[$field]=='width') { $valuetoshow=$langs->trans("Width"); }
if ($fieldlist[$field]=='height') { $valuetoshow=$langs->trans("Height"); }
if ($fieldlist[$field]=='unit') { $valuetoshow=$langs->trans("MeasuringUnit"); }
if ($fieldlist[$field]=='region_id' || $fieldlist[$field]=='country_id') { $showfield=0; }
if ($fieldlist[$field]=='accountancy_code'){ $valuetoshow=$langs->trans("AccountancyCode"); }
if ($fieldlist[$field]=='accountancy_code_sell'){ $valuetoshow=$langs->trans("AccountancyCodeSell"); $sortable=0; }
if ($fieldlist[$field]=='accountancy_code_buy'){ $valuetoshow=$langs->trans("AccountancyCodeBuy"); $sortable=0; }
if ($fieldlist[$field]=='fk_pcg_version') { $valuetoshow=$langs->trans("Pcg_version"); }
if ($fieldlist[$field]=='account_parent') { $valuetoshow=$langs->trans("Accountsparent"); }
if ($fieldlist[$field]=='pcg_type') { $valuetoshow=$langs->trans("Pcg_type"); }
if ($fieldlist[$field]=='pcg_subtype') { $valuetoshow=$langs->trans("Pcg_subtype"); }
if ($fieldlist[$field]=='sortorder') { $valuetoshow=$langs->trans("SortOrder"); }
if ($fieldlist[$field]=='short_label') { $valuetoshow=$langs->trans("ShortLabel"); }
if ($fieldlist[$field]=='type_template') { $valuetoshow=$langs->trans("TypeOfTemplate"); }
if ($fieldlist[$field]=='range_account') { $valuetoshow=$langs->trans("Range"); }
if ($fieldlist[$field]=='sens') { $valuetoshow=$langs->trans("Sens"); }
if ($fieldlist[$field]=='category_type') { $valuetoshow=$langs->trans("Calculated"); }
if ($fieldlist[$field]=='formula') { $valuetoshow=$langs->trans("Formula"); }
// Affiche nom du champ
if ($showfield)
@@ -752,9 +832,120 @@ if ($id)
$valuetoshow=($key != "Country".strtoupper($obj->country_code)?$obj->country_code." - ".$key:$obj->country);
}
}
else if ($fieldlist[$field]=='country_id') {
else if ($fieldlist[$field]=='recuperableonly' || $fieldlist[$field]=='type_cdr' || $fieldlist[$field] == 'deductible' || $fieldlist[$field] == 'category_type') {
if(empty($valuetoshow)) $valuetoshow = $langs->trans('None');
elseif($valuetoshow == 1) $valuetoshow = $langs->trans('AtEndOfMonth');
elseif($valuetoshow == 2) $valuetoshow = $langs->trans('CurrentNext');
$align="center";
}
else if ($fieldlist[$field]=='price' || preg_match('/^amount/i',$fieldlist[$field])) {
$valuetoshow=price($valuetoshow);
}
else if ($fieldlist[$field]=='libelle_facture') {
$langs->loadLangs(array("bills"));
$key=$langs->trans("PaymentCondition".strtoupper($obj->code));
$valuetoshow=($obj->code && $key != "PaymentCondition".strtoupper($obj->code)?$key:$obj->{$fieldlist[$field]});
$valuetoshow=nl2br($valuetoshow);
}
else if ($fieldlist[$field]=='label' && $tabname[$id]==MAIN_DB_PREFIX.'c_country') {
$key=$langs->trans("Country".strtoupper($obj->code));
$valuetoshow=($obj->code && $key != "Country".strtoupper($obj->code)?$key:$obj->{$fieldlist[$field]});
}
else if ($fieldlist[$field]=='label' && $tabname[$id]==MAIN_DB_PREFIX.'c_availability') {
$langs->loadLangs(array("propal"));
$key=$langs->trans("AvailabilityType".strtoupper($obj->code));
$valuetoshow=($obj->code && $key != "AvailabilityType".strtoupper($obj->code)?$key:$obj->{$fieldlist[$field]});
}
else if ($fieldlist[$field]=='libelle' && $tabname[$id]==MAIN_DB_PREFIX.'c_actioncomm') {
$key=$langs->trans("Action".strtoupper($obj->code));
$valuetoshow=($obj->code && $key != "Action".strtoupper($obj->code)?$key:$obj->{$fieldlist[$field]});
}
else if (! empty($obj->code_iso) && $fieldlist[$field]=='label' && $tabname[$id]==MAIN_DB_PREFIX.'c_currencies') {
$key=$langs->trans("Currency".strtoupper($obj->code_iso));
$valuetoshow=($obj->code_iso && $key != "Currency".strtoupper($obj->code_iso)?$key:$obj->{$fieldlist[$field]});
}
else if ($fieldlist[$field]=='libelle' && $tabname[$id]==MAIN_DB_PREFIX.'c_typent') {
$key=$langs->trans(strtoupper($obj->code));
$valuetoshow=($key != strtoupper($obj->code)?$key:$obj->{$fieldlist[$field]});
}
else if ($fieldlist[$field]=='libelle' && $tabname[$id]==MAIN_DB_PREFIX.'c_prospectlevel') {
$key=$langs->trans(strtoupper($obj->code));
$valuetoshow=($key != strtoupper($obj->code)?$key:$obj->{$fieldlist[$field]});
}
else if ($fieldlist[$field]=='label' && $tabname[$id]==MAIN_DB_PREFIX.'c_civility') {
$key=$langs->trans("Civility".strtoupper($obj->code));
$valuetoshow=($obj->code && $key != "Civility".strtoupper($obj->code)?$key:$obj->{$fieldlist[$field]});
}
else if ($fieldlist[$field]=='libelle' && $tabname[$id]==MAIN_DB_PREFIX.'c_type_contact') {
$langs->loadLangs(array("agenda"));
$key=$langs->trans("TypeContact_".$obj->element."_".$obj->source."_".strtoupper($obj->code));
$valuetoshow=($obj->code && $key != "TypeContact_".$obj->element."_".$obj->source."_".strtoupper($obj->code)?$key:$obj->{$fieldlist[$field]});
}
else if ($fieldlist[$field]=='libelle' && $tabname[$id]==MAIN_DB_PREFIX.'c_payment_term') {
$langs->loadLangs(array("bills"));
$key=$langs->trans("PaymentConditionShort".strtoupper($obj->code));
$valuetoshow=($obj->code && $key != "PaymentConditionShort".strtoupper($obj->code)?$key:$obj->{$fieldlist[$field]});
}
else if ($fieldlist[$field]=='libelle' && $tabname[$id]==MAIN_DB_PREFIX.'c_paiement') {
$langs->loadLangs(array("bills"));
$key=$langs->trans("PaymentType".strtoupper($obj->code));
$valuetoshow=($obj->code && $key != "PaymentType".strtoupper($obj->code)?$key:$obj->{$fieldlist[$field]});
}
else if ($fieldlist[$field]=='label' && $tabname[$id]==MAIN_DB_PREFIX.'c_input_reason') {
$key=$langs->trans("DemandReasonType".strtoupper($obj->code));
$valuetoshow=($obj->code && $key != "DemandReasonType".strtoupper($obj->code)?$key:$obj->{$fieldlist[$field]});
}
else if ($fieldlist[$field]=='libelle' && $tabname[$id]==MAIN_DB_PREFIX.'c_input_method') {
$langs->loadLangs(array("orders"));
$key=$langs->trans($obj->code);
$valuetoshow=($obj->code && $key != $obj->code)?$key:$obj->{$fieldlist[$field]};
}
else if ($fieldlist[$field]=='libelle' && $tabname[$id]==MAIN_DB_PREFIX.'c_shipment_mode') {
$langs->loadLangs(array("sendings"));
$key=$langs->trans("SendingMethod".strtoupper($obj->code));
$valuetoshow=($obj->code && $key != "SendingMethod".strtoupper($obj->code)?$key:$obj->{$fieldlist[$field]});
}
else if ($fieldlist[$field] == 'libelle' && $tabname[$id]==MAIN_DB_PREFIX.'c_paper_format')
{
$key = $langs->trans('PaperFormat'.strtoupper($obj->code));
$valuetoshow = ($obj->code && $key != 'PaperFormat'.strtoupper($obj->code) ? $key : $obj->{$fieldlist[$field]});
}
else if ($fieldlist[$field] == 'label' && $tabname[$id] == MAIN_DB_PREFIX.'c_type_fees')
{
$langs->loadLangs(array("trips"));
$key = $langs->trans(strtoupper($obj->code));
$valuetoshow = ($obj->code && $key != strtoupper($obj->code) ? $key : $obj->{$fieldlist[$field]});
}
else if ($fieldlist[$field]=='region_id' || $fieldlist[$field]=='country_id') {
$showfield=0;
}
else if ($fieldlist[$field]=='unicode') {
$valuetoshow = $langs->getCurrencySymbol($obj->code,1);
}
else if ($fieldlist[$field]=='label' && $tabname[$_GET["id"]]==MAIN_DB_PREFIX.'c_units') {
$langs->loadLangs(array("products"));
$valuetoshow=$langs->trans($obj->{$fieldlist[$field]});
}
else if ($fieldlist[$field]=='short_label' && $tabname[$_GET["id"]]==MAIN_DB_PREFIX.'c_units') {
$langs->loadLangs(array("products"));
$valuetoshow = $langs->trans($obj->{$fieldlist[$field]});
}
else if (($fieldlist[$field] == 'unit') && ($tabname[$id] == MAIN_DB_PREFIX.'c_paper_format'))
{
$key = $langs->trans('SizeUnit'.strtolower($obj->unit));
$valuetoshow = ($obj->code && $key != 'SizeUnit'.strtolower($obj->unit) ? $key : $obj->{$fieldlist[$field]});
}
else if ($fieldlist[$field]=='taux') {
$valuetoshow = price($valuetoshow, 0, $langs, 0, 0);
$align="right";
}
else if (in_array($fieldlist[$field],array('recuperableonly')))
{
$align="center";
}
else if ($fieldlist[$field]=='accountancy_code' || $fieldlist[$field]=='accountancy_code_sell' || $fieldlist[$field]=='accountancy_code_buy') {
$valuetoshow = length_accountg($valuetoshow);
}
$class='tddict';
if ($fieldlist[$field] == 'tracking') $class.=' tdoverflowauto';
@@ -765,6 +956,17 @@ if ($id)
// Can an entry be erased or disabled ?
$iserasable=1;$canbedisabled=1;$canbemodified=1; // true by default
if (isset($obj->code) && $id != 10)
{
if (($obj->code == '0' || $obj->code == '' || preg_match('/unknown/i',$obj->code))) { $iserasable = 0; $canbedisabled = 0; }
else if ($obj->code == 'RECEP') { $iserasable = 0; $canbedisabled = 0; }
else if ($obj->code == 'EF0') { $iserasable = 0; $canbedisabled = 0; }
}
if (isset($obj->type) && in_array($obj->type, array('system', 'systemauto'))) { $iserasable=0; }
if (in_array($obj->code, array('AC_OTH','AC_OTH_AUTO')) || in_array($obj->type, array('systemauto'))) { $canbedisabled=0; $canbedisabled = 0; }
$canbemodified=$iserasable;
if ($obj->code == 'RECEP') $canbemodified=1;
$url = $_SERVER["PHP_SELF"].'?'.($page?'page='.$page.'&':'').'sortfield='.$sortfield.'&sortorder='.$sortorder.'&rowid='.(! empty($obj->rowid)?$obj->rowid:(! empty($obj->code)?$obj->code:'')).'&code='.(! empty($obj->code)?urlencode($obj->code):'');
if ($param) $url .= '&'.$param;
@@ -802,7 +1004,7 @@ if ($id)
print '<br>';
// End of page
llxFooter();
$db->close();
@@ -853,7 +1055,53 @@ function fieldListAccountModel($fieldlist, $obj='', $tabname='', $context='')
print '</td>';
}
}
elseif ($fieldlist[$field] == 'type_cdr') {
elseif ($fieldlist[$field] == 'region')
{
print '<td>';
$formcompany->select_region($region_id,'region');
print '</td>';
}
elseif ($fieldlist[$field] == 'region_id')
{
$region_id = (! empty($obj->{$fieldlist[$field]})?$obj->{$fieldlist[$field]}:0);
print '<td>';
print '<input type="hidden" name="'.$fieldlist[$field].'" value="'.$region_id.'">';
print '</td>';
}
elseif ($fieldlist[$field] == 'lang')
{
print '<td>';
print $formadmin->select_language($conf->global->MAIN_LANG_DEFAULT,'lang');
print '</td>';
}
// Le type de template
elseif ($fieldlist[$field] == 'type_template')
{
print '<td>';
print $form->selectarray('type_template', $elementList,(! empty($obj->{$fieldlist[$field]})?$obj->{$fieldlist[$field]}:''));
print '</td>';
}
// Le type de l'element (pour les type de contact)
elseif ($fieldlist[$field] == 'element')
{
print '<td>';
print $form->selectarray('element', $elementList,(! empty($obj->{$fieldlist[$field]})?$obj->{$fieldlist[$field]}:''));
print '</td>';
}
// La source de l'element (pour les type de contact)
elseif ($fieldlist[$field] == 'source')
{
print '<td>';
print $form->selectarray('source', $sourceList,(! empty($obj->{$fieldlist[$field]})?$obj->{$fieldlist[$field]}:''));
print '</td>';
}
elseif ($fieldlist[$field] == 'type' && $tabname == MAIN_DB_PREFIX."c_actioncomm")
{
print '<td>';
print 'user<input type="hidden" name="type" value="user">';
print '</td>';
}
elseif ($fieldlist[$field] == 'recuperableonly' || $fieldlist[$field] == 'type_cdr' || $fieldlist[$field] == 'deductible' || $fieldlist[$field] == 'category_type') {
if ($fieldlist[$field] == 'type_cdr') print '<td align="center">';
else print '<td>';
if ($fieldlist[$field] == 'type_cdr') {
@@ -863,9 +1111,49 @@ function fieldListAccountModel($fieldlist, $obj='', $tabname='', $context='')
}
print '</td>';
}
elseif (in_array($fieldlist[$field],array('nbjour','decalage','taux','localtax1','localtax2'))) {
$align="left";
if (in_array($fieldlist[$field],array('taux','localtax1','localtax2'))) $align="right"; // Fields aligned on right
print '<td align="'.$align.'">';
print '<input type="text" class="flat" value="'.(isset($obj->{$fieldlist[$field]})?$obj->{$fieldlist[$field]}:'').'" size="3" name="'.$fieldlist[$field].'">';
print '</td>';
}
elseif (in_array($fieldlist[$field], array('libelle_facture'))) {
print '<td><textarea cols="30" rows="'.ROWS_2.'" class="flat" name="'.$fieldlist[$field].'">'.(! empty($obj->{$fieldlist[$field]})?$obj->{$fieldlist[$field]}:'').'</textarea></td>';
}
elseif (in_array($fieldlist[$field], array('content')))
{
print '<td>';
if ($context != 'hide')
{
//print '<textarea cols="3" rows="'.ROWS_2.'" class="flat" name="'.$fieldlist[$field].'">'.(! empty($obj->{$fieldlist[$field]})?$obj->{$fieldlist[$field]}:'').'</textarea>';
$okforextended=true;
$doleditor = new DolEditor($fieldlist[$field], (! empty($obj->{$fieldlist[$field]})?$obj->{$fieldlist[$field]}:''), '', 140, 'dolibarr_mailings', 'In', 0, false, $okforextended, ROWS_5, '90%');
print $doleditor->Create(1);
}
else print '&nbsp;';
print '</td>';
}
elseif ($fieldlist[$field] == 'price' || preg_match('/^amount/i',$fieldlist[$field])) {
print '<td><input type="text" class="flat" value="'.price((! empty($obj->{$fieldlist[$field]})?$obj->{$fieldlist[$field]}:'')).'" size="8" name="'.$fieldlist[$field].'"></td>';
}
elseif ($fieldlist[$field] == 'code' && isset($obj->{$fieldlist[$field]})) {
print '<td><input type="text" class="flat" value="'.(! empty($obj->{$fieldlist[$field]})?$obj->{$fieldlist[$field]}:'').'" size="10" name="'.$fieldlist[$field].'"></td>';
}
elseif ($fieldlist[$field] == 'accountancy_code' || $fieldlist[$field] == 'accountancy_code_sell' || $fieldlist[$field] == 'accountancy_code_buy')
{
print '<td>';
if (! empty($conf->accounting->enabled))
{
$accountancy_account = (! empty($obj->$fieldlist[$field]) ? $obj->$fieldlist[$field] : 0);
print $formaccounting->select_account($accountancy_account, $fieldlist[$field], 1, '', 1, 1, 'maxwidth200 maxwidthonsmartphone');
}
else
{
print '<input type="text" size="10" class="flat" value="'.(isset($obj->$fieldlist[$field])?$obj->$fieldlist[$field]:'').'" name="'.$fieldlist[$field].'">';
}
print '</td>';
}
else
{
print '<td>';
@@ -873,6 +1161,7 @@ function fieldListAccountModel($fieldlist, $obj='', $tabname='', $context='')
if ($fieldlist[$field]=='code') $size='size="8" ';
if ($fieldlist[$field]=='position') $size='size="4" ';
if ($fieldlist[$field]=='libelle') $size='centpercent';
if ($fieldlist[$field]=='tracking') $class='centpercent';
if ($fieldlist[$field]=='sortorder' || $fieldlist[$field]=='sens' || $fieldlist[$field]=='category_type') $size='size="2" ';
print '<input type="text" '.$size.' class="flat'.($class?' '.$class:'').'" value="'.(isset($obj->{$fieldlist[$field]})?$obj->{$fieldlist[$field]}:'').'" name="'.$fieldlist[$field].'">';
print '</td>';

View File

@@ -1,7 +1,7 @@
<?php
/* Copyright (C) 2013-2014 Olivier Geffroy <jeff@jeffinfo.com>
* Copyright (C) 2013-2018 Alexandre Spangaro <aspangaro@zendsi.com>
* Copyright (C) 2014 Florian Henry <florian.henry@open-concept.pro>
/* Copyright (C) 2013-2014 Olivier Geffroy <jeff@jeffinfo.com>
* Copyright (C) 2013-2017 Alexandre Spangaro <aspangaro@zendsi.com>
* Copyright (C) 2014 Florian Henry <florian.henry@open-concept.pro>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -41,7 +41,6 @@ $id = GETPOST('id', 'int');
$ref = GETPOST('ref', 'alpha');
$rowid = GETPOST('rowid', 'int');
$cancel = GETPOST('cancel','alpha');
$accountingaccount = GETPOST('accountingaccount','alpha');
// Security check
@@ -74,28 +73,25 @@ if ($action == 'add' && $user->rights->accounting->chartofaccount)
// To manage zero or not at the end of the accounting account
if($conf->global->ACCOUNTING_MANAGE_ZERO == 1)
{
$account_number = GETPOST('account_number','string');
$account_number = GETPOST('account_number');
}
else
{
$account_number = clean_account(GETPOST('account_number','string'));
$account_number = clean_account(GETPOST('account_number'));
}
if (GETPOST('account_parent','int') <= 0)
{
if (GETPOST('account_parent') <= 0) {
$account_parent = 0;
}
else
{
} else {
$account_parent = GETPOST('account_parent','int');
}
$object->fk_pcg_version = $obj->pcg_version;
$object->pcg_type = GETPOST('pcg_type','alpha');
$object->pcg_subtype = GETPOST('pcg_subtype','alpha');
$object->pcg_type = GETPOST('pcg_type');
$object->pcg_subtype = GETPOST('pcg_subtype');
$object->account_number = $account_number;
$object->account_parent = $account_parent;
$object->account_category = GETPOST('account_category','alpha');
$object->account_category = GETPOST('account_category');
$object->label = GETPOST('label', 'alpha');
$object->active = 1;
@@ -139,28 +135,25 @@ if ($action == 'add' && $user->rights->accounting->chartofaccount)
// To manage zero or not at the end of the accounting account
if($conf->global->ACCOUNTING_MANAGE_ZERO == 1)
{
$account_number = GETPOST('account_number','string');
$account_number = GETPOST('account_number');
}
else
{
$account_number = clean_account(GETPOST('account_number','string'));
$account_number = clean_account(GETPOST('account_number'));
}
if (GETPOST('account_parent','int') <= 0)
{
if (GETPOST('account_parent') <= 0) {
$account_parent = 0;
}
else
{
} else {
$account_parent = GETPOST('account_parent','int');
}
$object->fk_pcg_version = $obj->pcg_version;
$object->pcg_type = GETPOST('pcg_type','alpha');
$object->pcg_subtype = GETPOST('pcg_subtype','alpha');
$object->pcg_type = GETPOST('pcg_type');
$object->pcg_subtype = GETPOST('pcg_subtype');
$object->account_number = $account_number;
$object->account_parent = $account_parent;
$object->account_category = GETPOST('account_category','alpha');
$object->account_category = GETPOST('account_category');
$object->label = GETPOST('label', 'alpha');
$result = $object->update($user);
@@ -230,7 +223,7 @@ if ($action == 'create') {
// Account number
print '<tr><td class="titlefieldcreate"><span class="fieldrequired">' . $langs->trans("AccountNumber") . '</span></td>';
print '<td><input name="account_number" size="30" value="' . $accountingaccount . '"></td></tr>';
print '<td><input name="account_number" size="30" value="' . $object->account_number . '"></td></tr>';
// Label
print '<tr><td><span class="fieldrequired">' . $langs->trans("Label") . '</span></td>';
@@ -404,6 +397,6 @@ else if ($id > 0 || $ref) {
}
}
// End of page
llxFooter();
$db->close();

View File

@@ -37,9 +37,9 @@ $id = GETPOST('id', 'int');
$rowid = GETPOST('rowid', 'int');
$cancel = GETPOST('cancel','alpha');
$action = GETPOST('action','aZ09');
$cat_id = GETPOST('account_category','int');
$cat_id = GETPOST('account_category');
$selectcpt = GETPOST('cpt_bk', 'array');
$cpt_id = GETPOST('cptid','int');
$cpt_id = GETPOST('cptid');
if ($cat_id == 0) {
$cat_id = null;
@@ -184,6 +184,6 @@ if ($action == 'display' || $action == 'delete') {
print "</table>";
}
// End of page
llxFooter();
$db->close();

View File

@@ -34,7 +34,7 @@ require_once DOL_DOCUMENT_ROOT.'/core/class/html.formaccounting.class.php';
// Load translation files required by the page
$langs->loadLangs(array("errors","admin","companies","resource","holiday","accountancy","hrm"));
$action=GETPOST('action','aZ09')?GETPOST('action','aZ09'):'view';
$action=GETPOST('action','alpha')?GETPOST('action','alpha'):'view';
$confirm=GETPOST('confirm','alpha');
$id=32;
$rowid=GETPOST('rowid','alpha');
@@ -51,8 +51,8 @@ $acts[1] = "disable";
$actl[0] = img_picto($langs->trans("Disabled"),'switch_off');
$actl[1] = img_picto($langs->trans("Activated"),'switch_on');
$listoffset=GETPOST('listoffset','alpha');
$listlimit=GETPOST('listlimit','int')>0?GETPOST('listlimit','int'):1000;
$listoffset=GETPOST('listoffset');
$listlimit=GETPOST('listlimit')>0?GETPOST('listlimit'):1000;
$active = 1;
$sortfield = GETPOST("sortfield",'aZ09comma');
@@ -134,13 +134,13 @@ $sourceList=array();
* Actions
*/
if (GETPOST('button_removefilter','alpha') || GETPOST('button_removefilter.x','alpha') || GETPOST('button_removefilter_x','alpha'))
if (GETPOST('button_removefilter') || GETPOST('button_removefilter.x') || GETPOST('button_removefilter_x'))
{
$search_country_id = '';
}
// Actions add or modify an entry into a dictionary
if (GETPOST('actionadd','alpha') || GETPOST('actionmodify','alpha'))
if (GETPOST('actionadd') || GETPOST('actionmodify'))
{
$listfield=explode(',', str_replace(' ', '',$tabfield[$id]));
$listfieldinsert=explode(',',$tabfieldinsert[$id]);
@@ -202,6 +202,7 @@ if (GETPOST('actionadd','alpha') || GETPOST('actionmodify','alpha'))
{
$obj = $db->fetch_object($result);
$newid=($obj->newid + 1);
} else {
dol_print_error($db);
}
@@ -249,7 +250,7 @@ if (GETPOST('actionadd','alpha') || GETPOST('actionmodify','alpha'))
}
// Si verif ok et action modify, on modifie la ligne
if ($ok && GETPOST('actionmodify','alpha'))
if ($ok && GETPOST('actionmodify'))
{
if ($tabrowid[$id]) { $rowidcol=$tabrowid[$id]; }
else { $rowidcol="rowid"; }
@@ -290,7 +291,7 @@ if (GETPOST('actionadd','alpha') || GETPOST('actionmodify','alpha'))
//$_GET["id"]=GETPOST('id', 'int'); // Force affichage dictionnaire en cours d'edition
}
if (GETPOST('actioncancel','alpha'))
if (GETPOST('actioncancel'))
{
//$_GET["id"]=GETPOST('id', 'int'); // Force affichage dictionnaire en cours d'edition
}
@@ -512,7 +513,7 @@ if ($id)
$obj = new stdClass();
// If data was already input, we define them in obj to populate input fields.
if (GETPOST('actionadd','alpha'))
if (GETPOST('actionadd'))
{
foreach ($fieldlist as $key=>$val)
{
@@ -799,7 +800,7 @@ if ($id)
print '<br>';
// End of page
llxFooter();
$db->close();

View File

@@ -43,7 +43,7 @@ if (empty($user->rights->accounting->chartofaccount))
accessforbidden();
}
$action = GETPOST('action', 'aZ09');
$action = GETPOST('action', 'alpha');
$list_account_main = array (
@@ -76,7 +76,7 @@ $list_account = array (
$accounting_mode = empty($conf->global->ACCOUNTING_MODE) ? 'RECETTES-DEPENSES' : $conf->global->ACCOUNTING_MODE;
if (GETPOST('change_chart', 'alpha'))
if (GETPOST('change_chart'))
{
$chartofaccounts = GETPOST('chartofaccounts', 'int');
@@ -190,6 +190,5 @@ print '<div class="center"><input type="submit" class="button" value="' . $langs
print '</form>';
// End of page
llxFooter();
$db->close();

View File

@@ -41,10 +41,10 @@ if (empty($user->rights->accounting->chartofaccount))
accessforbidden();
}
$action = GETPOST('action', 'aZ09');
$action = GETPOST('action', 'alpha');
// Parameters ACCOUNTING_EXPORT_*
$main_option = array(
$main_option = array (
'ACCOUNTING_EXPORT_PREFIX_SPEC',
);
@@ -79,7 +79,6 @@ $model_option = array (
/*
* Actions
*/
if ($action == 'update') {
$error = 0;
@@ -125,8 +124,6 @@ if ($action == 'update') {
}
}
/*
* View
*/
@@ -270,7 +267,7 @@ if ($num2) {
} else {
print '<input type="text" size="20" id="'. $label .'" name="' . $key['label'] . '" value="' . $conf->global->$label . '">';
}
print '</td></tr>';
}
@@ -281,6 +278,5 @@ print '<div class="center"><input type="submit" class="button" value="' . dol_es
print '</form>';
// End of page
llxFooter();
$db->close();

View File

@@ -156,6 +156,6 @@ if ($result)
dol_print_error($db);
}
// End of page
llxFooter();
$db->close();

View File

@@ -1,6 +1,5 @@
<?php
/* Copyright (C) 2014-2016 Alexandre Spangaro <aspangaro@zendsi.com>
* Copyright (C) 2018 Frédéric France <frederic.france@netlogic.fr>
/* Copyright (C) 2014-2016 Alexandre Spangaro <aspangaro@zendsi.com>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -38,7 +37,7 @@ if (empty($user->rights->accounting->fiscalyear))
$error = 0;
$action = GETPOST('action', 'aZ09');
$action = GETPOST('action', 'alpha');
$confirm = GETPOST('confirm', 'alpha');
$id = GETPOST('id', 'int');
@@ -166,16 +165,16 @@ if ($action == 'create')
print '<table class="border" width="100%">';
// Label
print '<tr><td class="titlefieldcreate fieldrequired">' . $langs->trans("Label") . '</td><td><input name="label" size="32" value="' . GETPOST('label', 'alpha') . '"></td></tr>';
print '<tr><td class="titlefieldcreate fieldrequired">' . $langs->trans("Label") . '</td><td><input name="label" size="32" value="' . GETPOST("label") . '"></td></tr>';
// Date start
print '<tr><td class="fieldrequired">' . $langs->trans("DateStart") . '</td><td>';
print $form->selectDate(($date_start ? $date_start : ''), 'fiscalyear');
print $form->select_date(($date_start ? $date_start : ''), 'fiscalyear');
print '</td></tr>';
// Date end
print '<tr><td class="fieldrequired">' . $langs->trans("DateEnd") . '</td><td>';
print $form->selectDate(($date_end ? $date_end : - 1), 'fiscalyearend');
print $form->select_date(($date_end ? $date_end : - 1), 'fiscalyearend');
print '</td></tr>';
/*
@@ -183,7 +182,7 @@ if ($action == 'create')
print '<tr>';
print '<td class="fieldrequired">' . $langs->trans("Status") . '</td>';
print '<td class="valeur">';
print $form->selectarray('statut', $statut2label, GETPOST('statut', 'int'));
print $form->selectarray('statut', $statut2label, GETPOST('statut'));
print '</td></tr>';
*/
@@ -226,12 +225,12 @@ if ($action == 'create')
// Date start
print '<tr><td class="fieldrequired">' . $langs->trans("DateStart") . '</td><td>';
print $form->selectDate($object->date_start ? $object->date_start : - 1, 'fiscalyear');
print $form->select_date($object->date_start ? $object->date_start : - 1, 'fiscalyear');
print '</td></tr>';
// Date end
print '<tr><td class="fieldrequired">' . $langs->trans("DateEnd") . '</td><td>';
print $form->selectDate($object->date_end ? $object->date_end : - 1, 'fiscalyearend');
print $form->select_date($object->date_end ? $object->date_end : - 1, 'fiscalyearend');
print '</td></tr>';
// Statut
@@ -319,6 +318,5 @@ if ($action == 'create')
}
}
// End of page
llxFooter();
$db->close();

View File

@@ -58,6 +58,5 @@ if ($id) {
print '</div>';
}
// End of page
llxFooter();
$db->close();

View File

@@ -1,8 +1,7 @@
<?php
/* Copyright (C) 2013-2014 Olivier Geffroy <jeff@jeffinfo.com>
* Copyright (C) 2013-2017 Alexandre Spangaro <aspangaro@zendsi.com>
* Copyright (C) 2013-2017 Alexandre Spangaro <aspangaro@zendsi.com>
* Copyright (C) 2014 Florian Henry <florian.henry@open-concept.pro>
* Copyright (C) 2018 Frédéric France <frederic.france@netlogic.fr>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -19,7 +18,7 @@
*/
/**
* \file htdocs/accountancy/admin/importaccounts.php
* \file htdocs/accountancy/admin/importaccounts.php
* \ingroup Advanced accountancy
* \brief Page import accounting account
*/
@@ -72,10 +71,10 @@ if ($_POST["action"] == 'import') {
$accounting = new AccountingAccount($db);
$monLabel = (string) GETPOST('label' . $maLigneCochee);
$monParentAccount = (string) GETPOST('AccountParent' . $maLigneCochee);
$monType = (string) GETPOST('pcgType' . $maLigneCochee);
$monSubType = (string) GETPOST('pcgSubType' . $maLigneCochee);
$monLabel = GETPOST('label' . $maLigneCochee);
$monParentAccount = GETPOST('AccountParent' . $maLigneCochee);
$monType = GETPOST('pcgType' . $maLigneCochee);
$monSubType = GETPOST('pcgSubType' . $maLigneCochee);
$accounting->fk_pcg_version = $obj->pcg_version;
$accounting->account_number = $maLigneCochee;
@@ -84,7 +83,7 @@ if ($_POST["action"] == 'import') {
$accounting->pcg_type = $monType;
$accounting->pcg_subtype = $monSubType;
$accounting->active = 1;
$result = $accounting->create($user);
if ($result > 0) {
setEventMessages($langs->trans("AccountingAccountAdd"), null, 'mesgs');
@@ -102,7 +101,7 @@ if ($_POST["action"] == 'import') {
print '<div><font color="red">' . $langs->trans("EndProcessing") . '</font></div>';
}
// list accounting account from product
// list accounting account from product
$sql = "(SELECT p.rowid as product_id, p.accountancy_code_sell as accounting ";
$sql .= " FROM " . MAIN_DB_PREFIX . "product as p ";
@@ -173,15 +172,14 @@ if ($result) {
print '</tr>';
$i ++;
}
print '<tr><td colspan="8">&nbsp;</td></tr><tr><td colspan="8" align="center"><input type="submit" class="butAction" value="' . $langs->trans("Import") . '"></td></tr>';
print '</table>';
print '</form>';
} else {
print $db->error();
}
// End of page
llxFooter();
$db->close();

View File

@@ -41,7 +41,7 @@ if (empty($user->rights->accounting->chartofaccount))
accessforbidden();
}
$action = GETPOST('action', 'aZ09');
$action = GETPOST('action', 'alpha');
// Parameters ACCOUNTING_* and others
$list = array (
@@ -295,6 +295,5 @@ print '<br>';
print '<br>';
print '</form>';
// End of page
llxFooter();
$db->close();

View File

@@ -34,7 +34,7 @@ require_once DOL_DOCUMENT_ROOT.'/accountancy/class/accountingjournal.class.php';
// Load translation files required by the page
$langs->loadLangs(array("admin","compta","accountancy"));
$action=GETPOST('action','aZ09')?GETPOST('action','aZ09'):'view';
$action=GETPOST('action','alpha')?GETPOST('action','alpha'):'view';
$confirm=GETPOST('confirm','alpha');
$id=35;
$rowid=GETPOST('rowid','alpha');
@@ -51,8 +51,8 @@ $acts[1] = "disable";
$actl[0] = img_picto($langs->trans("Disabled"),'switch_off');
$actl[1] = img_picto($langs->trans("Activated"),'switch_on');
$listoffset=GETPOST('listoffset', 'alpha');
$listlimit=GETPOST('listlimit', 'int')>0?GETPOST('listlimit', 'int'):1000;
$listoffset=GETPOST('listoffset');
$listlimit=GETPOST('listlimit')>0?GETPOST('listlimit'):1000;
$active = 1;
$sortfield = GETPOST("sortfield",'alpha');
@@ -128,28 +128,28 @@ complete_dictionary_with_modules($taborder,$tabname,$tablib,$tabsql,$tabsqlsort,
// Define elementList and sourceList (used for dictionary type of contacts "llx_c_type_contact")
$elementList = array();
// Must match ids defined into eldy.lib.php
$sourceList = array(
'1' => $langs->trans('AccountingJournalType1'),
'2' => $langs->trans('AccountingJournalType2'),
'3' => $langs->trans('AccountingJournalType3'),
'4' => $langs->trans('AccountingJournalType4'),
'5' => $langs->trans('AccountingJournalType5'),
'8' => $langs->trans('AccountingJournalType8'),
'9' => $langs->trans('AccountingJournalType9'),
);
// Must match ids defined into eldy.lib.php
$sourceList = array(
'1' => $langs->trans('AccountingJournalType1'),
'2' => $langs->trans('AccountingJournalType2'),
'3' => $langs->trans('AccountingJournalType3'),
'4' => $langs->trans('AccountingJournalType4'),
'5' => $langs->trans('AccountingJournalType5'),
'8' => $langs->trans('AccountingJournalType8'),
'9' => $langs->trans('AccountingJournalType9')
);
/*
* Actions
*/
if (GETPOST('button_removefilter', 'alpha') || GETPOST('button_removefilter.x', 'alpha') || GETPOST('button_removefilter_x', 'alpha'))
if (GETPOST('button_removefilter') || GETPOST('button_removefilter.x') || GETPOST('button_removefilter_x'))
{
$search_country_id = '';
}
// Actions add or modify an entry into a dictionary
if (GETPOST('actionadd', 'alpha') || GETPOST('actionmodify', 'alpha'))
if (GETPOST('actionadd') || GETPOST('actionmodify'))
{
$listfield=explode(',', str_replace(' ', '',$tabfield[$id]));
$listfieldinsert=explode(',',$tabfieldinsert[$id]);
@@ -190,7 +190,7 @@ if (GETPOST('actionadd', 'alpha') || GETPOST('actionmodify', 'alpha'))
if ($_POST["accountancy_code_buy"] <= 0) $_POST["accountancy_code_buy"]=''; // If empty, we force to null
// Si verif ok et action add, on ajoute la ligne
if ($ok && GETPOST('actionadd', 'alpha'))
if ($ok && GETPOST('actionadd'))
{
if ($tabrowid[$id])
{
@@ -202,6 +202,7 @@ if (GETPOST('actionadd', 'alpha') || GETPOST('actionmodify', 'alpha'))
{
$obj = $db->fetch_object($result);
$newid=($obj->newid + 1);
} else {
dol_print_error($db);
}
@@ -251,7 +252,7 @@ if (GETPOST('actionadd', 'alpha') || GETPOST('actionmodify', 'alpha'))
}
// Si verif ok et action modify, on modifie la ligne
if ($ok && GETPOST('actionmodify', 'alpha'))
if ($ok && GETPOST('actionmodify'))
{
if ($tabrowid[$id]) { $rowidcol=$tabrowid[$id]; }
else { $rowidcol="rowid"; }
@@ -293,10 +294,10 @@ if (GETPOST('actionadd', 'alpha') || GETPOST('actionmodify', 'alpha'))
//$_GET["id"]=GETPOST('id', 'int'); // Force affichage dictionnaire en cours d'edition
}
//if (GETPOST('actioncancel', 'alpha'))
//{
// $_GET["id"]=GETPOST('id', 'int'); // Force affichage dictionnaire en cours d'edition
//}
if (GETPOST('actioncancel'))
{
//$_GET["id"]=GETPOST('id', 'int'); // Force affichage dictionnaire en cours d'edition
}
if ($action == 'confirm_delete' && $confirm == 'yes') // delete
{
@@ -461,7 +462,7 @@ if ($id)
$obj = new stdClass();
// If data was already input, we define them in obj to populate input fields.
if (GETPOST('actionadd', 'alpha'))
if (GETPOST('actionadd'))
{
foreach ($fieldlist as $key=>$val)
{
@@ -503,7 +504,7 @@ if ($id)
$paramwithsearch = $param;
if ($sortorder) $paramwithsearch.= '&sortorder='.$sortorder;
if ($sortfield) $paramwithsearch.= '&sortfield='.$sortfield;
if (GETPOST('from', 'alpha')) $paramwithsearch.= '&from='.GETPOST('from','alpha');
if (GETPOST('from')) $paramwithsearch.= '&from='.GETPOST('from','alpha');
// There is several pages
if ($num > $listlimit)
@@ -682,7 +683,7 @@ if ($id)
print '<br>';
// End of page
llxFooter();
$db->close();

View File

@@ -45,7 +45,7 @@ if (! $user->rights->accounting->bind->write)
accessforbidden();
// search & action GETPOST
$action = GETPOST('action', 'aZ09');
$action = GETPOST('action', 'alpha');
$codeventil_buy = GETPOST('codeventil_buy', 'array');
$codeventil_sell = GETPOST('codeventil_sell', 'array');
$chk_prod = GETPOST('chk_prod', 'array');
@@ -62,8 +62,8 @@ $search_current_account_valid = GETPOST('search_current_account_valid', 'alpha')
if ($search_current_account_valid == '') $search_current_account_valid='withoutvalidaccount';
$accounting_product_mode = GETPOST('accounting_product_mode', 'alpha');
$btn_changeaccount = GETPOST('changeaccount', 'alpha');
$btn_changetype = GETPOST('changetype', 'alpha');
$btn_changeaccount = GETPOST('changeaccount');
$btn_changetype = GETPOST('changetype');
$limit = GETPOST('limit','int')?GETPOST('limit','int'):(empty($conf->global->ACCOUNTING_LIMIT_LIST_VENTILATION)?$conf->liste_limit:$conf->global->ACCOUNTING_LIMIT_LIST_VENTILATION);
$sortfield = GETPOST("sortfield",'alpha');
@@ -173,6 +173,7 @@ if ($action == 'update') {
$cpt++;
}
}
if ($ko) setEventMessages($langs->trans("XLineFailedToBeBinded", $ko), null, 'errors');
@@ -494,6 +495,5 @@ if ($result)
dol_print_error($db);
}
// End of page
llxFooter();
$db->close();

View File

@@ -1,8 +1,7 @@
<?php
/* Copyright (C) 2016 Olivier Geffroy <jeff@jeffinfo.com>
* Copyright (C) 2016 Florian Henry <florian.henry@open-concept.pro>
* Copyright (C) 2016-2018 Alexandre Spangaro <aspangaro@zendsi.com>
* Copyright (C) 2018 Frédéric France <frederic.france@netlogic.fr>
/* Copyright (C) 2016 Olivier Geffroy <jeff@jeffinfo.com>
* Copyright (C) 2016 Florian Henry <florian.henry@open-concept.pro>
* Copyright (C) 2016-2018 Alexandre Spangaro <aspangaro@zendsi.com>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -41,7 +40,7 @@ $langs->loadLangs(array("accountancy"));
$page = GETPOST("page");
$sortorder = GETPOST("sortorder", 'alpha');
$sortfield = GETPOST("sortfield", 'alpha');
$action = GETPOST('action', 'aZ09');
$action = GETPOST('action', 'alpha');
if (GETPOST("exportcsv",'alpha')) $action = 'export_csv';
// Load variable for pagination
@@ -150,7 +149,6 @@ if ($action == 'export_csv')
$sep = $conf->global->ACCOUNTING_EXPORT_SEPARATORCSV;
$filename = 'balance';
$type_export = 'balance';
include DOL_DOCUMENT_ROOT . '/accountancy/tpl/export_journal.tpl.php';
$result = $object->fetchAllBalance($sortorder, $sortfield, $limit, 0, $filter);
@@ -167,18 +165,13 @@ if ($action == 'export_csv')
print price($line->credit - $line->debit) . $sep;
print "\n";
}
exit;
}
else {
$title_page = $langs->trans("AccountBalance");
$title_page = $langs->trans("AccountBalance");
llxHeader('', $title_page);
llxHeader('', $title_page);
if ($action != 'export_csv')
{
// List
$nbtotalofrecords = '';
if (empty($conf->global->MAIN_DISABLE_FULL_SCANLIST))
@@ -211,9 +204,9 @@ if ($action != 'export_csv')
$moreforfilter .= '<div class="divsearchfield">';
$moreforfilter .= $langs->trans('DateStart') . ': ';
$moreforfilter .= $form->selectDate($search_date_start?$search_date_start:-1, 'date_start', 0, 0, 1, '', 1, 0);
$moreforfilter .= $form->select_date($search_date_start?$search_date_start:-1, 'date_start', 0, 0, 1, '', 1, 0, 1);
$moreforfilter .= $langs->trans('DateEnd') . ': ';
$moreforfilter .= $form->selectDate($search_date_end?$search_date_end:-1, 'date_end', 0, 0, 1, '', 1, 0);
$moreforfilter .= $form->select_date($search_date_end?$search_date_end:-1, 'date_end', 0, 0, 1, '', 1, 0, 1);
$moreforfilter .= '</div>';
if (! empty($moreforfilter)) {
@@ -265,7 +258,7 @@ if ($action != 'export_csv')
$description = $object->get_compte_desc($line->numero_compte); // Search description of the account
$root_account_description = $object->get_compte_racine($line->numero_compte);
if (empty($description)) {
$link = '<a href="../admin/card.php?action=create&accountingaccount=' . length_accountg($line->numero_compte) . '">' . img_edit_add() . '</a>';
$link = '<a href="../admin/card.php?action=create&compte=' . length_accountg($line->numero_compte) . '">' . img_edit_add() . '</a>';
}
print '<tr class="oddeven">';
@@ -274,7 +267,7 @@ if ($action != 'export_csv')
{
// Affiche un Sous-Total par compte comptable
if ($displayed_account != "") {
print '<tr class="liste_total"><td align="right" colspan="2">' . $langs->trans("SubTotal") . ':</td><td class="nowrap" align="right">' . price($sous_total_debit) . '</td><td class="nowrap" align="right">' . price($sous_total_credit) . '</td><td class="nowrap" align="right">' . price(price2num($sous_total_credit - $sous_total_debit)) . '</td>';
print '<tr class="liste_total"><td align="right" colspan="2">' . $langs->trans("SubTotal") . ':</td><td class="nowrap" align="right">' . price($sous_total_debit) . '</td><td class="nowrap" align="right">' . price($sous_total_credit) . '</td><td class="nowrap" align="right">' . price($sous_total_credit - $sous_total_debit) . '</td>';
print "<td>&nbsp;</td>\n";
print '</tr>';
}
@@ -305,18 +298,18 @@ if ($action != 'export_csv')
$sous_total_credit += $line->credit;
}
print '<tr class="liste_total"><td align="right" colspan="2">' . $langs->trans("SubTotal") . ':</td><td class="nowrap" align="right">' . price($sous_total_debit) . '</td><td class="nowrap" align="right">' . price($sous_total_credit) . '</td><td class="nowrap" align="right">' . price(price2num($sous_total_credit - $sous_total_debit)) . '</td>';
print '<tr class="liste_total"><td align="right" colspan="2">' . $langs->trans("SubTotal") . ':</td><td class="nowrap" align="right">' . price($sous_total_debit) . '</td><td class="nowrap" align="right">' . price($sous_total_credit) . '</td><td class="nowrap" align="right">' . price($sous_total_credit - $sous_total_debit) . '</td>';
print "<td>&nbsp;</td>\n";
print '</tr>';
print '<tr class="liste_total"><td align="right" colspan="2">' . $langs->trans("AccountBalance") . ':</td><td class="nowrap" align="right">' . price($total_debit) . '</td><td class="nowrap" align="right">' . price($total_credit) . '</td><td class="nowrap" align="right">' . price(price2num($total_credit - $total_debit)) . '</td>';
print '<tr class="liste_total"><td align="right" colspan="2">' . $langs->trans("AccountBalance") . ':</td><td class="nowrap" align="right">' . price($total_debit) . '</td><td class="nowrap" align="right">' . price($total_credit) . '</td><td class="nowrap" align="right">' . price($total_credit - $total_debit) . '</td>';
print "<td>&nbsp;</td>\n";
print '</tr>';
print "</table>";
print '</form>';
llxFooter();
}
// End of page
llxFooter();
$db->close();

View File

@@ -64,7 +64,7 @@ $result = $db->query($sql);
if ($result) {
$row = $db->fetch_row($result);
$nbfac = $row[0];
$db->free($result);
}
@@ -85,7 +85,7 @@ print '<td align="center">' . $langs->trans("SeptemberMin") . '</td>';
print '<td align="center">' . $langs->trans("OctoberMin") . '</td>';
print '<td align="center">' . $langs->trans("NovemberMin") . '</td>';
print '<td align="center">' . $langs->trans("DecemberMin") . '</td>';
print '<td align="center"><strong>Total</strong></td>';
print '<td align="center"><b>Total</b></td>';
print '</tr>';
$sql = "SELECT bk.numero_compte AS 'compte',";
@@ -111,11 +111,11 @@ $resql = $db->query($sql);
if ($resql) {
$i = 0;
$num = $db->num_rows($resql);
while ( $i < $num ) {
$row = $db->fetch_row($resql);
print '<tr class="oddeven"><td width="14%">' . length_accountg($row[0]) . '</td>';
print '<td align="right" width="6.5%">' . price($row[1]) . '</td>';
print '<td align="right" width="6.5%">' . price($row[2]) . '</td>';
@@ -129,9 +129,9 @@ if ($resql) {
print '<td align="right" width="6.5%">' . price($row[10]) . '</td>';
print '<td align="right" width="6.5%">' . price($row[11]) . '</td>';
print '<td align="right" width="6.5%">' . price($row[12]) . '</td>';
print '<td align="right" width="8%"><strong>' . price($row[13]) . '</strong></td>';
print '<td align="right" width="8%"><b>' . price($row[13]) . '</b></td>';
print '</tr>';
$i ++;
}
$db->free($resql);
@@ -140,6 +140,5 @@ if ($resql) {
}
print "</table>\n";
// End of page
llxFooter();
$db->close();

View File

@@ -1,9 +1,8 @@
<?php
/* Copyright (C) 2013-2017 Olivier Geffroy <jeff@jeffinfo.com>
* Copyright (C) 2013-2017 Florian Henry <florian.henry@open-concept.pro>
* Copyright (C) 2013-2018 Alexandre Spangaro <aspangaro@zendsi.com>
* Copyright (C) 2017 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2018 Frédéric France <frederic.france@netlogic.fr>
/* Copyright (C) 2013-2017 Olivier Geffroy <jeff@jeffinfo.com>
* Copyright (C) 2013-2017 Florian Henry <florian.henry@open-concept.pro>
* Copyright (C) 2013-2018 Alexandre Spangaro <aspangaro@zendsi.com>
* Copyright (C) 2017 Laurent Destailleur <eldy@users.sourceforge.net>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -32,7 +31,6 @@ require_once DOL_DOCUMENT_ROOT . '/core/class/html.formaccounting.class.php';
require_once DOL_DOCUMENT_ROOT . '/compta/facture/class/facture.class.php';
require_once DOL_DOCUMENT_ROOT . '/fourn/class/fournisseur.facture.class.php';
require_once DOL_DOCUMENT_ROOT . '/accountancy/class/accountingjournal.class.php';
require_once DOL_DOCUMENT_ROOT . '/accountancy/class/accountingaccount.class.php';
// Load translation files required by the page
$langs->loadLangs(array("accountancy", "bills", "compta"));
@@ -50,21 +48,12 @@ if ($user->societe_id > 0) {
$mesg = '';
$accountingaccount = new AccountingAccount($db);
$accountingjournal = new AccountingJournal($db);
$accountingaccount_number = GETPOST('accountingaccount_number','alphanohtml');
$accountingaccount->fetch(null, $accountingaccount_number, true);
$accountingaccount_label = $accountingaccount->label;
$journal_code = GETPOST('code_journal','alpha');
$accountingjournal->fetch(null, $journal_code);
$journal_label = $accountingjournal->label;
$account_number = GETPOST('account_number','alphanohtml');
$subledger_account = GETPOST('subledger_account','alphanohtml');
if ($subledger_account == - 1) {
$subledger_account = null;
}
$label_compte = GETPOST('label_compte','alphanohtml');
$label_operation= GETPOST('label_operation','alphanohtml');
$debit = price2num(GETPOST('debit','alpha'));
$credit = price2num(GETPOST('credit','alpha'));
@@ -90,7 +79,7 @@ if ($action == "confirm_update") {
setEventMessages($langs->trans('ErrorDebitCredit'), null, 'errors');
$action='update';
}
if (empty($accountingaccount_number) || $accountingaccount_number == '-1')
if (empty($account_number) || $account_number == '-1')
{
$error++;
setEventMessages($langs->trans('ErrorFieldRequired', $langs->transnoentitiesnoconv("AccountAccountingShort")), null, 'errors');
@@ -106,9 +95,9 @@ if ($action == "confirm_update") {
$error++;
setEventMessages($object->error, $object->errors, 'errors');
} else {
$object->numero_compte = $accountingaccount_number;
$object->numero_compte = $account_number;
$object->subledger_account = $subledger_account;
$object->label_compte = $accountingaccount_label;
$object->label_compte = $label_compte;
$object->label_operation= $label_operation;
$object->debit = $debit;
$object->credit = $credit;
@@ -149,7 +138,7 @@ else if ($action == "add") {
setEventMessages($langs->trans('ErrorDebitCredit'), null, 'errors');
$action='';
}
if (empty($accountingaccount_number) || $accountingaccount_number == '-1')
if (empty($account_number) || $account_number == '-1')
{
$error++;
setEventMessages($langs->trans('ErrorFieldRequired', $langs->transnoentitiesnoconv("AccountAccountingShort")), null, 'errors');
@@ -159,9 +148,9 @@ else if ($action == "add") {
if (! $error) {
$object = new BookKeeping($db);
$object->numero_compte = $accountingaccount_number;
$object->numero_compte = $account_number;
$object->subledger_account = $subledger_account;
$object->label_compte = $accountingaccount_label;
$object->label_compte = $label_compte;
$object->label_operation= $label_operation;
$object->debit = $debit;
$object->credit = $credit;
@@ -169,8 +158,7 @@ else if ($action == "add") {
$object->doc_type = GETPOST('doc_type','alpha');
$object->piece_num = $piece_num;
$object->doc_ref = GETPOST('doc_ref','alpha');
$object->code_journal = $journal_code;
$object->journal_label = $journal_label;
$object->code_journal = GETPOST('code_journal','alpha');
$object->fk_doc = GETPOST('fk_doc','alpha');
$object->fk_docdet = GETPOST('fk_docdet','alpha');
@@ -223,12 +211,12 @@ else if ($action == "confirm_create") {
$object = new BookKeeping($db);
if (! $journal_code || $journal_code == '-1') {
if (! GETPOST('code_journal','alpha') || GETPOST('code_journal','alpha') == '-1') {
setEventMessages($langs->trans('ErrorFieldRequired', $langs->transnoentitiesnoconv("Journal")), null, 'errors');
$action='create';
$error++;
}
if (! GETPOST('next_num_mvt', 'alpha'))
if (! GETPOST('next_num_mvt'))
{
setEventMessages($langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv("NumPiece")), null, 'errors');
$error++;
@@ -243,8 +231,7 @@ else if ($action == "confirm_create") {
$object->doc_type = GETPOST('doc_type','alpha');
$object->piece_num = GETPOST('next_num_mvt','alpha');
$object->doc_ref = GETPOST('doc_ref','alpha');
$object->code_journal = $journal_code;
$object->journal_label = $journal_label;
$object->code_journal = GETPOST('code_journal','alpha');
$object->fk_doc = 0;
$object->fk_docdet = 0;
$object->montant = 0;
@@ -265,7 +252,7 @@ else if ($action == "confirm_create") {
}
if ($action == 'setdate') {
$datedoc = dol_mktime(0, 0, 0, GETPOST('doc_datemonth', 'int'), GETPOST('doc_dateday', 'int'), GETPOST('doc_dateyear', 'int'));
$datedoc = dol_mktime(0, 0, 0, GETPOST('doc_datemonth'), GETPOST('doc_dateday'), GETPOST('doc_dateyear'));
$result = $object->updateByMvt($piece_num,'doc_date',$db->idate($datedoc),$mode);
if ($result < 0) {
setEventMessages($object->error, $object->errors, 'errors');
@@ -279,8 +266,8 @@ if ($action == 'setdate') {
}
if ($action == 'setjournal') {
$result = $object->updateByMvt($piece_num, 'code_journal', $journal_code, $mode);
$result = $object->updateByMvt($piece_num, 'journal_label', $journal_label, $mode);
$journaldoc = trim(GETPOST('code_journal','alpha'));
$result = $object->updateByMvt($piece_num, 'code_journal', $journaldoc, $mode);
if ($result < 0) {
setEventMessages($object->error, $object->errors, 'errors');
} else {
@@ -324,6 +311,7 @@ if ($action == 'valid') {
$html = new Form($db);
$formaccounting = new FormAccounting($db);
$accountjournal = new AccountingJournal($db);
llxHeader('', $langs->trans("CreateMvts"));
@@ -362,13 +350,13 @@ if ($action == 'create')
print '<tr>';
print '<td class="titlefieldcreate fieldrequired">' . $langs->trans("Docdate") . '</td>';
print '<td>';
print $html->selectDate('', 'doc_date', '', '', '', "create_mvt", 1, 1);
print $html->select_date('', 'doc_date', '', '', '', "create_mvt", 1, 1);
print '</td>';
print '</tr>';
print '<tr>';
print '<td class="fieldrequired">' . $langs->trans("Codejournal") . '</td>';
print '<td>' . $formaccounting->select_journal($journal_code,'code_journal',0,0,1,1) . '</td>';
print '<td>' . $formaccounting->select_journal(GETPOST('code_journal'),'code_journal',0,1,array(),1,1) . '</td>';
print '</tr>';
print '<tr>';
@@ -444,7 +432,7 @@ if ($action == 'create')
print '<input type="hidden" name="token" value="' . $_SESSION ['newtoken'] . '">';
print '<input type="hidden" name="action" value="setdate">';
print '<input type="hidden" name="mode" value="'.$mode.'">';
print $form->selectDate($object->doc_date ? $object->doc_date : - 1, 'doc_date', '', '', '', "setdate");
$form->select_date($object->doc_date ? $object->doc_date : - 1, 'doc_date', '', '', '', "setdate");
print '<input type="submit" class="button" value="' . $langs->trans('Modify') . '">';
print '</form>';
} else {
@@ -471,7 +459,7 @@ if ($action == 'create')
print '<input type="submit" class="button" value="' . $langs->trans('Modify') . '">';
print '</form>';
} else {
print $object->code_journal ;
print $object->code_journal ;
}
print '</td>';
print '</tr>';
@@ -601,6 +589,7 @@ if ($action == 'create')
print_liste_field_titre("AccountAccountingShort");
print_liste_field_titre("SubledgerAccount");
print_liste_field_titre("LabelAccount");
print_liste_field_titre("LabelOperation");
print_liste_field_titre("Debit", "", "", "", "", 'align="right"');
print_liste_field_titre("Credit", "", "", "", "", 'align="right"');
@@ -615,7 +604,7 @@ if ($action == 'create')
if ($action == 'update' && $line->id == $id) {
print '<td>';
print $formaccounting->select_account($line->numero_compte, 'accountingaccount_number', 1, array (), 1, 1, '');
print $formaccounting->select_account($line->numero_compte, 'account_number', 1, array (), 1, 1, '');
print '</td>';
print '<td>';
// TODO For the moment we keep a free input text instead of a combo. The select_auxaccount has problem because it does not
@@ -629,6 +618,7 @@ if ($action == 'create')
print '<input type="text" name="subledger_account" value="'.$line->subledger_account.'">';
}
print '</td>';
print '<td><input type="text" class="minwidth100" name="label_compte" value="' . $line->label_compte . '"/></td>';
print '<td><input type="text" class="minwidth200" name="label_operation" value="' . $line->label_operation. '"/></td>';
print '<td align="right"><input type="text" size="6" class="right" name="debit" value="' . price($line->debit) . '"/></td>';
print '<td align="right"><input type="text" size="6" class="right" name="credit" value="' . price($line->credit) . '"/></td>';
@@ -637,9 +627,9 @@ if ($action == 'create')
print '<input type="submit" class="button" name="update" value="' . $langs->trans("Update") . '">';
print '</td>';
} else {
$accountingaccount->fetch(null, $line->numero_compte, true);
print '<td>' . $accountingaccount->getNomUrl(0,1,1,'',0) . '</td>';
print '<td>' . length_accountg($line->numero_compte) . '</td>';
print '<td>' . length_accounta($line->subledger_account) . '</td>';
print '<td>' . $line->label_compte . '</td>';
print '<td>' . $line->label_operation. '</td>';
print '<td align="right">' . price($line->debit) . '</td>';
print '<td align="right">' . price($line->credit) . '</td>';
@@ -661,8 +651,8 @@ if ($action == 'create')
print "</tr>\n";
}
$total_debit = price2num($total_debit);
$total_credit = price2num($total_credit);
$total_debit = price2num($total_debit, 'MT');
$total_credit = price2num($total_credit, 'MT');
if ($total_debit != $total_credit)
{
@@ -672,7 +662,7 @@ if ($action == 'create')
if ($action == "" || $action == 'add') {
print '<tr class="oddeven">';
print '<td>';
print $formaccounting->select_account($accountingaccount_number, 'accountingaccount_number', 1, array (), 1, 1, '');
print $formaccounting->select_account($account_number, 'account_number', 1, array (), 1, 1, '');
print '</td>';
print '<td>';
// TODO For the moment we keep a fre input text instead of a combo. The select_auxaccount has problem because it does not
@@ -686,6 +676,7 @@ if ($action == 'create')
print '<input type="text" name="subledger_account" value="">';
}
print '</td>';
print '<td><input type="text" class="minwidth100" name="label_compte" value=""/></td>';
print '<td><input type="text" class="minwidth200" name="label_operation" value=""/></td>';
print '<td align="right"><input type="text" size="6" class="right" name="debit" value=""/></td>';
print '<td align="right"><input type="text" size="6" class="right" name="credit" value=""/></td>';
@@ -723,6 +714,5 @@ if ($action == 'create')
dol_fiche_end();
// End of page
llxFooter();
$db->close();

View File

@@ -1,9 +1,8 @@
<?php
/* Copyright (C) 2013-2016 Olivier Geffroy <jeff@jeffinfo.com>
* Copyright (C) 2013-2016 Florian Henry <florian.henry@open-concept.pro>
* Copyright (C) 2013-2018 Alexandre Spangaro <aspangaro@zendsi.com>
* Copyright (C) 2016-2017 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2018 Frédéric France <frederic.france@netlogic.fr>
/* Copyright (C) 2013-2016 Olivier Geffroy <jeff@jeffinfo.com>
* Copyright (C) 2013-2016 Florian Henry <florian.henry@open-concept.pro>
* Copyright (C) 2013-2017 Alexandre Spangaro <aspangaro@zendsi.com>
* Copyright (C) 2016-2017 Laurent Destailleur <eldy@users.sourceforge.net>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -36,10 +35,10 @@ require_once DOL_DOCUMENT_ROOT . '/core/lib/date.lib.php';
// Load translation files required by the page
$langs->loadLangs(array("accountancy"));
$action = GETPOST('action', 'aZ09');
$action = GETPOST('action', 'alpha');
$search_mvt_num = GETPOST('search_mvt_num', 'int');
$search_doc_type = GETPOST("search_doc_type", 'alpha');
$search_doc_ref = GETPOST("search_doc_ref", 'alpha');
$search_doc_type = GETPOST("search_doc_type");
$search_doc_ref = GETPOST("search_doc_ref");
$search_date_start = dol_mktime(0, 0, 0, GETPOST('search_date_startmonth', 'int'), GETPOST('search_date_startday', 'int'), GETPOST('search_date_startyear', 'int'));
$search_date_end = dol_mktime(0, 0, 0, GETPOST('search_date_endmonth', 'int'), GETPOST('search_date_endday', 'int'), GETPOST('search_date_endyear', 'int'));
$search_doc_date = dol_mktime(0, 0, 0, GETPOST('doc_datemonth', 'int'), GETPOST('doc_dateday', 'int'), GETPOST('doc_dateyear', 'int'));
@@ -79,7 +78,6 @@ $search_direction = GETPOST('search_direction', 'alpha');
$search_debit = GETPOST('search_debit', 'alpha');
$search_credit = GETPOST('search_credit', 'alpha');
$search_ledger_code = GETPOST('search_ledger_code', 'alpha');
$search_lettering_code = GETPOST('search_lettering_code', 'alpha');
// Load variable for pagination
$limit = GETPOST('limit','int')?GETPOST('limit', 'int'):(empty($conf->global->ACCOUNTING_LIMIT_LIST_VENTILATION)?$conf->liste_limit:$conf->global->ACCOUNTING_LIMIT_LIST_VENTILATION);
@@ -139,14 +137,11 @@ $arrayfields=array(
't.label_operation'=>array('label'=>$langs->trans("Label"), 'checked'=>1),
't.debit'=>array('label'=>$langs->trans("Debit"), 'checked'=>1),
't.credit'=>array('label'=>$langs->trans("Credit"), 'checked'=>1),
't.lettering_code'=>array('label'=>$langs->trans("LetteringCode"), 'checked'=>1),
't.code_journal'=>array('label'=>$langs->trans("Codejournal"), 'checked'=>1),
't.date_creation'=>array('label'=>$langs->trans("DateCreation"), 'checked'=>0),
't.tms'=>array('label'=>$langs->trans("DateModification"), 'checked'=>0),
);
if (empty($conf->global->ACCOUNTING_ENABLE_LETTERING)) unset($arrayfields['t.lettering_code']);
/*
* Actions
@@ -180,7 +175,6 @@ if (GETPOST('button_removefilter_x','alpha') || GETPOST('button_removefilter.x',
$search_date_modification_end = '';
$search_debit = '';
$search_credit = '';
$search_lettering_code = '';
}
// Must be after the remove filter action, before the export.
@@ -277,10 +271,6 @@ if (! empty($search_credit)) {
$filter['t.credit'] = $search_credit;
$param .= '&search_credit=' . urlencode($search_credit);
}
if (! empty($search_lettering_code)) {
$filter['t.lettering_code'] = $search_lettering_code;
$param .= '&search_lettering_code=' . urlencode($search_lettering_code);
}
if ($action == 'delbookkeeping') {
@@ -346,7 +336,7 @@ if ($action == 'delmouvconfirm') {
}
}
// Export into a file with format defined into setup (FEC, CSV, ...)
// Export into a file with format defined into setup
if ($action == 'export_file') {
$result = $object->fetchAll($sortorder, $sortfield, 0, 0, $filter);
@@ -359,9 +349,7 @@ if ($action == 'export_file') {
{
$accountancyexport = new AccountancyExport($db);
$accountancyexport->export($object->lines);
if (!empty($accountancyexport->errors))
{
if (!empty($accountancyexport->errors)) {
setEventMessages('', $accountancyexport->errors, 'errors');
}
exit;
@@ -477,11 +465,11 @@ if (! empty($arrayfields['t.doc_date']['checked']))
print '<td class="liste_titre center">';
print '<div class="nowrap">';
print $langs->trans('From') . ' ';
print $form->selectDate($search_date_start?$search_date_start:-1, 'search_date_start', 0, 0, 1);
print $form->select_date($search_date_start?$search_date_start:-1, 'search_date_start', 0, 0, 1);
print '</div>';
print '<div class="nowrap">';
print $langs->trans('to') . ' ';
print $form->selectDate($search_date_end?$search_date_end:-1, 'search_date_end', 0, 0, 1);
print $form->select_date($search_date_end?$search_date_end:-1, 'search_date_end', 0, 0, 1);
print '</div>';
print '</td>';
}
@@ -557,13 +545,6 @@ if (! empty($arrayfields['t.credit']['checked']))
print '<input type="text" class="flat" name="search_credit" size="4" value="'.dol_escape_htmltag($search_credit).'">';
print '</td>';
}
// Lettering code
if (! empty($arrayfields['t.lettering_code']['checked']))
{
print '<td class="liste_titre center">';
print '<input type="text" size="3" class="flat" name="search_lettering_code" value="' . $search_lettering_code . '"/>';
print '</td>';
}
// Code journal
if (! empty($arrayfields['t.code_journal']['checked']))
{
@@ -575,11 +556,11 @@ if (! empty($arrayfields['t.date_creation']['checked']))
print '<td class="liste_titre center">';
print '<div class="nowrap">';
print $langs->trans('From') . ' ';
print $form->selectDate($search_date_creation_start, 'date_creation_start', 0, 0, 1);
print $form->select_date($search_date_creation_start, 'date_creation_start', 0, 0, 1);
print '</div>';
print '<div class="nowrap">';
print $langs->trans('to') . ' ';
print $form->selectDate($search_date_creation_end, 'date_creation_end', 0, 0, 1);
print $form->select_date($search_date_creation_end, 'date_creation_end', 0, 0, 1);
print '</div>';
print '</td>';
}
@@ -589,11 +570,11 @@ if (! empty($arrayfields['t.tms']['checked']))
print '<td class="liste_titre center">';
print '<div class="nowrap">';
print $langs->trans('From') . ' ';
print $form->selectDate($search_date_modification_start, 'date_modification_start', 0, 0, 1);
print $form->select_date($search_date_modification_start, 'date_modification_start', 0, 0, 1);
print '</div>';
print '<div class="nowrap">';
print $langs->trans('to') . ' ';
print $form->selectDate($search_date_modification_end, 'date_modification_end', 0, 0, 1);
print $form->select_date($search_date_modification_end, 'date_modification_end', 0, 0, 1);
print '</div>';
print '</td>';
}
@@ -613,7 +594,6 @@ if (! empty($arrayfields['t.subledger_account']['checked'])) print_liste_field_t
if (! empty($arrayfields['t.label_operation']['checked'])) print_liste_field_titre($arrayfields['t.label_operation']['label'], $_SERVER['PHP_SELF'], "t.label_operation", "", $param, "", $sortfield, $sortorder);
if (! empty($arrayfields['t.debit']['checked'])) print_liste_field_titre($arrayfields['t.debit']['label'], $_SERVER['PHP_SELF'], "t.debit", "", $param, 'align="right"', $sortfield, $sortorder);
if (! empty($arrayfields['t.credit']['checked'])) print_liste_field_titre($arrayfields['t.credit']['label'], $_SERVER['PHP_SELF'], "t.credit", "", $param, 'align="right"', $sortfield, $sortorder);
if (! empty($arrayfields['t.lettering_code']['checked'])) print_liste_field_titre($arrayfields['t.lettering_code']['label'], $_SERVER['PHP_SELF'], "t.lettering_code", "", $param, 'align="center"', $sortfield, $sortorder);
if (! empty($arrayfields['t.code_journal']['checked'])) print_liste_field_titre($arrayfields['t.code_journal']['label'], $_SERVER['PHP_SELF'], "t.code_journal", "", $param, 'align="center"', $sortfield, $sortorder);
if (! empty($arrayfields['t.date_creation']['checked'])) print_liste_field_titre($arrayfields['t.date_creation']['label'], $_SERVER['PHP_SELF'], "t.date_creation", "", $param, 'align="center"', $sortfield, $sortorder);
if (! empty($arrayfields['t.tms']['checked'])) print_liste_field_titre($arrayfields['t.tms']['label'], $_SERVER['PHP_SELF'], "t.tms", "", $param, 'align="center"', $sortfield, $sortorder);
@@ -698,13 +678,6 @@ if ($num > 0)
$totalarray['totalcredit'] += $line->credit;
}
// Lettering code
if (! empty($arrayfields['t.lettering_code']['checked']))
{
print '<td align="center">' . $line->lettering_code . '</td>';
if (! $i) $totalarray['nbfield']++;
}
// Journal code
if (! empty($arrayfields['t.code_journal']['checked']))
{
@@ -759,6 +732,7 @@ if ($num > 0)
else print '<td></td>';
}
print '</tr>';
}
}
@@ -773,6 +747,6 @@ print '</div>';
print '</form>';
// End of page
llxFooter();
$db->close();

View File

@@ -3,7 +3,6 @@
* Copyright (C) 2013-2016 Olivier Geffroy <jeff@jeffinfo.com>
* Copyright (C) 2013-2016 Florian Henry <florian.henry@open-concept.pro>
* Copyright (C) 2013-2018 Alexandre Spangaro <aspangaro@zendsi.com>
* Copyright (C) 2018 Frédéric France <frederic.france@netlogic.fr>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -288,10 +287,10 @@ print '</td>';
print '<td class="liste_titre"></td>';
print '<td class="liste_titre" align="center">';
print $langs->trans('From') . ': ';
print $form->selectDate($search_date_start, 'search_date_start', 0, 0, 1);
print $form->select_date($search_date_start, 'search_date_start', 0, 0, 1);
print '<br>';
print $langs->trans('to') . ': ';
print $form->selectDate($search_date_end, 'search_date_end', 0, 0, 1);
print $form->select_date($search_date_end, 'search_date_end', 0, 0, 1);
print '</td>';
print '<td class="liste_titre"><input type="text" size="7" class="flat" name="search_doc_ref" value="' . dol_escape_htmltag($search_doc_ref) . '"/></td>';
print '<td class="liste_titre"><input type="text" size="7" class="flat" name="search_label_operation" value="' . dol_escape_htmltag($search_label_operation) . '"/></td>';
@@ -422,6 +421,5 @@ print '</tr>';
print "</table>";
print '</form>';
// End of page
llxFooter();
$db->close();

Some files were not shown because too many files have changed in this diff Show More