2
0
forked from Wavyzz/dolibarr

Compare commits

...

387 Commits

Author SHA1 Message Date
Laurent Destailleur
58b2b91928 Fix: removed warning 2012-07-08 16:55:42 +02:00
Laurent Destailleur
d11e22c970 Merge branch '3.2' of https://github.com/Dolibarr/dolibarr.git into 3.2 2012-07-07 20:22:35 +02:00
Laurent Destailleur
0428d5eee4 Prepare 3.2 release 2012-07-07 20:21:44 +02:00
Regis Houssin
dd60c384a5 Fix: missing object 2012-07-07 12:27:45 +02:00
Regis Houssin
ba896c024d Fix: problem with template 2012-07-07 11:01:48 +02:00
Regis Houssin
928af1a2b3 Fix: security 2012-07-07 08:00:18 +02:00
Regis Houssin
7382f4e3ee Fix: bad link and uniformize code 2012-07-06 10:23:28 +02:00
Regis Houssin
a3c74aa9bd Fix: price field is obsolete 2012-07-06 09:53:45 +02:00
Regis Houssin
59c84747ac Revert "Fix: wrong link"
This reverts commit 45f09da98a.
2012-07-05 15:49:45 +02:00
Regis Houssin
45f09da98a Fix: wrong link 2012-07-05 15:40:13 +02:00
Regis Houssin
5c2d8656cc Fix: missing images files filter 2012-07-03 21:13:58 +02:00
Regis Houssin
a13bf2b93f Fix: test if ckeditor is enable 2012-07-03 16:42:34 +02:00
Regis Houssin
65304f2e77 Fix: missing shipping linked object box 2012-07-02 22:40:48 +02:00
Regis Houssin
8a6cd7f84d New: check the real version and remove specific php settings 2012-07-02 21:00:25 +02:00
Regis Houssin
ea21064ca2 Fix: access problem if thirdparty module is disable 2012-07-02 20:06:08 +02:00
Regis Houssin
4e395e741c Merge pull request #237 from simnandez/3.2
Trad: Add missing translations
2012-07-02 09:01:18 -07:00
simnandez
b5a12ff088 Trad: Add missing translations 2012-07-02 17:36:41 +02:00
Regis Houssin
9623d50f48 Fix: big problem with linked elements 2012-07-02 17:11:35 +02:00
Regis Houssin
deecfe5d07 Fix: wrong sql request 2012-07-02 16:14:44 +02:00
Regis Houssin
1f98a23587 Fix: compatibility with multicompany
Conflicts:
	htdocs/product/class/product.class.php
2012-07-02 15:46:31 +02:00
Regis Houssin
1d5db424a1 Fix: missing contract reference 2012-07-02 10:38:40 +02:00
Regis Houssin
8d0cafc687 Fix: sql request error 2012-07-02 10:15:03 +02:00
Laurent Destailleur
57958e25bf Prepare 3.2 release 2012-06-30 02:21:59 +02:00
Laurent Destailleur
9edb149d2c Prepare 3.2 final 2012-06-30 01:48:25 +02:00
Laurent Destailleur
622720132d Use stable url 2012-06-30 01:45:54 +02:00
Laurent Destailleur
bdd8b393f9 Merge branch '3.2' of ssh://git@github.com/Dolibarr/dolibarr.git into 3.2 2012-06-30 01:15:50 +02:00
Regis Houssin
55ac02382b Fix: missing parameters ! 2012-06-29 10:09:15 +02:00
Regis Houssin
70cd7b87e9 Merge branch '3.2' of git+ssh://git@github.com/Dolibarr/dolibarr.git into 3.2 2012-06-29 09:36:33 +02:00
Regis Houssin
18ae5ff6ea New: remove linked elements invalid 2012-06-29 09:36:18 +02:00
Laurent Destailleur
52c2d39194 Fix: Can't modifiy accountancy code sell 2012-06-28 19:59:33 +02:00
Laurent Destailleur
0b56923de5 Fix: Panicum module for supplier accountancy code 2012-06-28 19:49:54 +02:00
jfefe
189cba6c41 Fix : use lastname to test contact ldap synchro (not name) 2012-06-27 13:29:45 +02:00
Laurent Destailleur
de5612ae0b Fix: Missing include 2012-06-27 13:28:51 +02:00
Laurent Destailleur
f23d826e0a Fix: Bad hour 2012-06-27 01:41:44 +02:00
Laurent Destailleur
62f14e3dd5 Fix: Removed warning. Fix compatibility. 2012-06-26 23:13:03 +02:00
Laurent Destailleur
643e077c68 Fix: turkish language 2012-06-24 20:01:34 +02:00
Laurent Destailleur
5e490f8530 Fix: Remove warning 2012-06-24 19:43:26 +02:00
Laurent Destailleur
a67f6cc732 Fix: Preview of shiping receipts 2012-06-23 21:00:43 +02:00
Laurent Destailleur
06c17b806e Fix: fckeditor ko on linux package 2012-06-23 20:17:31 +02:00
Laurent Destailleur
8deeac403a Fix: Label was not translated 2012-06-23 15:03:02 +02:00
Laurent Destailleur
ed724b82d3 Fix: We must not define language var if parm not defined.
Conflicts:
	htdocs/master.inc.php
2012-06-20 23:38:31 +02:00
Regis Houssin
9fed7fba30 Fix: missing not empty test 2012-06-20 22:24:26 +02:00
Laurent Destailleur
cb04444301 Fix: If option to not manage a login is on, login is not output into
info message.
Fix: Bad error management
2012-06-19 21:55:28 +02:00
Laurent Destailleur
8c030f4f81 Fix: rebuild_merge_pdf does not regenerate files already existing by
default.
2012-06-19 21:34:55 +02:00
Regis Houssin
4ef651d50b Merge pull request #231 from simnandez/3.2
3.2
2012-06-18 01:30:10 -07:00
simnandez
6bd438fc7f Doc: Update ChangeLog 2012-06-18 10:24:52 +02:00
Laurent Destailleur
657c7eb4cf Merge branch '3.2' of ssh://git@github.com/Dolibarr/dolibarr.git into
3.2

Conflicts:
	build/exe/doliwamp/doliwamp.iss
	build/makepack-howto.txt
2012-06-17 22:35:47 +02:00
Laurent Destailleur
a00439b375 Prepare release 2012-06-17 22:30:01 +02:00
Laurent Destailleur
cb6f9f40b8 Prepare release 2012-06-17 19:22:44 +02:00
Laurent Destailleur
cfa8ca5c52 Fix: Removed warning 2012-06-17 17:45:25 +02:00
Laurent Destailleur
3354b35e75 Fix: Avoid warning if param is empty 2012-06-17 17:34:21 +02:00
Laurent Destailleur
3556adc11d Fix: Permissions for click2dial tab 2012-06-16 00:10:47 +02:00
Regis Houssin
0d83691c5b Merge pull request #229 from simnandez/3.2
Fix: [ bug #427 ] Bad links to wiki help in certains menus
2012-06-15 06:57:54 -07:00
simnandez
bcfd35648b Fix: [ bug #427 ] Bad links to wiki help in certains menus 2012-06-15 15:54:56 +02:00
Laurent Destailleur
554a5b4c29 Merge branch '3.2' of https://github.com/Dolibarr/dolibarr into 3.2 2012-06-15 12:44:31 +02:00
Laurent Destailleur
eb543f0606 Fix: missing a return into clean_url function 2012-06-15 12:44:11 +02:00
Regis Houssin
1f4d3207fe Merge pull request #227 from simnandez/3.2
Fix: [ bug #427 ] Bad links to wiki help in certains menus
2012-06-15 03:28:20 -07:00
simnandez
83d75aaa31 Fix: [ bug #427 ] Bad links to wiki help in certains menus 2012-06-15 12:20:45 +02:00
Laurent Destailleur
2e74a4ba85 Fix: The fix made by renaming PDF_ADDALSOTARGETDETAILS into MAIN_PDF_ADDALSOSOURCEDETAILS was fixing things in the wrong direction. The regression was the missing data on the recipient compared to 3.1.1 2012-06-15 11:26:16 +02:00
Laurent Destailleur
5d502aa7d1 Fix: function dol_nboflines_bis 2012-06-15 00:17:12 +02:00
Laurent Destailleur
c28c5c1003 Fix: Bad calculation of nb of line. Fix: Bad position of lines into pdf_soleil 2012-06-14 20:01:47 +02:00
Laurent Destailleur
383195581f Fix: Messy source address 2012-06-14 17:51:56 +02:00
Laurent Destailleur
6c27963d1d Fix: Use order date for stats, not valid date. 2012-06-14 16:34:34 +02:00
Laurent Destailleur
6406d4e64c Fix: typo error 2012-06-13 20:16:21 +02:00
Laurent Destailleur
142e7e55d7 Merge branch '3.2' of ssh://git@github.com/Dolibarr/dolibarr.git into 3.2 2012-06-13 20:14:48 +02:00
Regis Houssin
56188ca798 Merge branch '3.2' of git+ssh://git@github.com/Dolibarr/dolibarr.git into 3.2 2012-06-12 23:15:25 +02:00
Regis Houssin
c8c31b2167 Fix: mutualize ckeditor parameters 2012-06-12 23:14:54 +02:00
Regis Houssin
86aab20c0a Merge pull request #224 from simnandez/3.2
Fix: Missing translation key
2012-06-11 13:02:22 -07:00
Laurent Destailleur
4c52e477e4 Fix: Removed non greek sentences 2012-06-09 12:41:03 +02:00
Laurent Destailleur
b8b400a5a4 Fix: No alpha here, this breaks ability to submit html content with
images or links.
2012-06-09 12:40:51 +02:00
simnandez
92cb694f55 Fix: Missing translation key 2012-06-09 09:05:14 +02:00
Laurent Destailleur
2be18e834a Fix: Turkish translation 2012-06-09 00:25:31 +02:00
Laurent Destailleur
b554dfc3d2 Fix: Missing translation key 2012-06-09 00:25:22 +02:00
Laurent Destailleur
183ba3e8ca Fix: Another fix for var not initialized 2012-06-08 22:26:54 +02:00
Laurent Destailleur
f2365a4c8d Fix: A lot of pb into javascript. Javascripts code for same feature was
not inserted always at same place (sometinmes at low level, and
sometimes at high level). This was creating conflict into javascript.

Conflicts:
	htdocs/product/class/product.class.php
2012-06-08 22:25:45 +02:00
Regis Houssin
db840bf8de Fix: remove deprecated code can cause warning 2012-06-08 18:20:06 +02:00
Regis Houssin
4713738ea3 Fix: avoid warning 2012-06-08 18:19:55 +02:00
Laurent Destailleur
d8894b149e Merge branch '3.2' of ssh://git@github.com/Dolibarr/dolibarr.git into 3.2 2012-06-06 23:13:41 +02:00
Laurent Destailleur
407978991c Fix: bad error management 2012-06-06 23:05:59 +02:00
Regis Houssin
0d1159d862 Fix: problem with external module 2012-06-06 23:02:46 +02:00
Laurent Destailleur
06442f4755 Fix: Var not initialized 2012-06-06 21:39:37 +02:00
Regis Houssin
54dd02413f Fix: missing search in alternative root directory 2012-06-06 14:05:04 +02:00
Laurent Destailleur
7feff22c1a Fxi: Bad permission check 2012-06-06 00:23:13 +02:00
Laurent Destailleur
a5a4ef538d Fix: Exclude temp file 2012-06-06 00:23:00 +02:00
Laurent Destailleur
c8bd77ddd7 Fix: Missing permission check 2012-06-06 00:22:43 +02:00
Laurent Destailleur
1c32b4231d Merge branch '3.2' of ssh://git@github.com/Dolibarr/dolibarr.git into 3.2 2012-06-05 12:55:12 +02:00
Laurent Destailleur
31560e19df Fix with PHP 5.2 2012-06-05 12:54:34 +02:00
Regis Houssin
e9a8ec1795 Merge branch '3.2' of git+ssh://git@github.com/Dolibarr/dolibarr.git into 3.2 2012-06-04 11:26:01 +02:00
Regis Houssin
26aa12de97 Fix: don't exclude savant and jstree for externals modules ! 2012-06-04 11:25:17 +02:00
Laurent Destailleur
00d185f648 Fix: Use wrong handler. Make install fails. 2012-06-04 02:15:10 +02:00
Regis Houssin
4e05640ecb Fix: date format error 2012-06-03 23:56:27 +02:00
Regis Houssin
ff33cb4a88 Fix: merge array of hookmanager errors 2012-06-03 23:55:05 +02:00
Laurent Destailleur
5ce0fe1405 Fix: Solve error Method Not Implemented 2012-06-01 21:24:54 +02:00
Laurent Destailleur
7c61f6fd88 Fix: Try a fix for the _FILES escape problem. 2012-06-01 21:00:03 +02:00
Laurent Destailleur
42b3e109d7 Merge branch '3.2' of ssh://git@github.com/Dolibarr/dolibarr.git into 3.2 2012-06-01 20:58:00 +02:00
Regis Houssin
d11971dbbd Merge pull request #217 from GPCsolutions/3.2
Fixed a bug in intervention's list navigation
2012-06-01 02:19:29 -07:00
Raphaël Doursenaud
20d90831e1 Fixed a bug in interventions' list navigation
The navigation arrows were referencing "index.php" file thus
preventing navigation between pages.
The actual name of the file is "list.php".
2012-06-01 10:52:39 +02:00
Laurent Destailleur
0160fb8c5e Fix: an url must be with url escape format. 2012-06-01 10:12:15 +02:00
Laurent Destailleur
a51114d571 Fix: regression. quote was no more supported. 2012-06-01 09:34:43 +02:00
Laurent Destailleur
52f270d623 Merge branch '3.2' of ssh://git@github.com/Dolibarr/dolibarr.git into 3.2 2012-06-01 09:28:49 +02:00
Regis Houssin
9c42cdc7d3 Fix: clear file name send by php 2012-06-01 07:14:29 +02:00
Raphaël Doursenaud
d79b65ce49 Fixed a bug preventing invoice sorting by authors 2012-06-01 06:52:59 +02:00
Laurent Destailleur
2b85a2fcd4 Merge pull request #216 from GPCsolutions/82af0ed28f223d1324c8843abb106c8ee6af9a4b
Fixed a bug preventing invoice sorting by authors
2012-05-31 17:57:40 -07:00
Laurent Destailleur
4fd98dfb72 Fix: Revert a lot of commits made on wrong branch. No new features, no
change on architecture on a beta, only bug fixes on visible features.
2012-06-01 02:22:39 +02:00
Laurent Destailleur
06eca56e00 Revert "Fix: replace Bootstrap version by jQueryUI version"
This reverts commit 03ec0d7cc5.
2012-06-01 02:07:35 +02:00
Laurent Destailleur
2d818fc886 Revert "Fix: add max file size"
This reverts commit 8b224e9e2d.
2012-06-01 02:07:24 +02:00
Laurent Destailleur
180908bfe1 Revert "Fix: reload page after file upload completed"
This reverts commit 368af101ef.
2012-06-01 02:07:11 +02:00
Laurent Destailleur
3dcf553a47 Revert "New: update jQuery and jQuery UI"
This reverts commit 7ed980fab5.
2012-06-01 02:07:02 +02:00
Laurent Destailleur
f9bda74e22 Revert "Fix: stock message in session and reload the page for avoid url problem with jQuery fileupload"
This reverts commit 4deeb20dd8.
2012-06-01 02:06:53 +02:00
Laurent Destailleur
73f1d8ee99 Revert "Fix: more clean code for new version of jQuery fileupload"
This reverts commit d7308525ae.
2012-06-01 02:06:43 +02:00
Laurent Destailleur
1a73347866 Merge branch '3.2' of ssh://git@github.com/Dolibarr/dolibarr.git into 3.2 2012-06-01 01:54:24 +02:00
Regis Houssin
d7308525ae Fix: more clean code for new version of jQuery fileupload 2012-05-31 21:12:40 +02:00
Regis Houssin
4deeb20dd8 Fix: stock message in session and reload the page for avoid url problem
with jQuery fileupload
2012-05-31 21:12:25 +02:00
Raphaël Doursenaud
0a8016e2aa Merge branch '3.2' of https://github.com/Dolibarr/dolibarr into 3.2 2012-05-31 10:09:14 +02:00
Regis Houssin
7ed980fab5 New: update jQuery and jQuery UI 2012-05-30 23:40:45 +02:00
Regis Houssin
368af101ef Fix: reload page after file upload completed 2012-05-30 23:37:02 +02:00
Regis Houssin
8b224e9e2d Fix: add max file size 2012-05-30 23:36:50 +02:00
Regis Houssin
03ec0d7cc5 Fix: replace Bootstrap version by jQueryUI version 2012-05-30 23:36:40 +02:00
Regis Houssin
a717297a8c Works on jQuery fileupload upgrade (Todo: css problem) 2012-05-30 23:36:17 +02:00
Raphaël Doursenaud
086a0ae340 Merge branch '3.2' of https://github.com/Dolibarr/dolibarr into 3.2 2012-05-30 17:36:04 +02:00
Regis Houssin
599971b27a Merge pull request #214 from simnandez/3.2
Trad: Add translation
2012-05-30 07:40:22 -07:00
Simnandez
f23462a173 Trad: Add translation 2012-05-30 16:28:13 +02:00
Laurent Destailleur
a83c7d0992 Fix: Regression with quot management. Try a better fix. 2012-05-30 12:49:22 +02:00
Laurent Destailleur
f67636d0f3 Merge branch '3.2' of ssh://git@github.com/Dolibarr/dolibarr.git into 3.2 2012-05-30 12:47:58 +02:00
Laurent Destailleur
92fe8ebe1d Fix: js not escaped 2012-05-30 12:33:47 +02:00
Raphaël Doursenaud
2812bfae7a Merge branch '3.2' of https://github.com/Dolibarr/dolibarr into 3.2 2012-05-30 10:29:15 +02:00
Regis Houssin
1a969e61e9 Fix: can't delete a files with quote 2012-05-30 08:31:59 +02:00
Laurent Destailleur
fd9565934c A better fix to remove files from document list 2012-05-30 04:11:37 +02:00
Laurent Destailleur
a465814fd4 More fix for canvas features
Conflicts:
	htdocs/product/canvas/product/tpl/card_create.tpl.php
	htdocs/product/fiche.php
2012-05-30 03:50:53 +02:00
Laurent Destailleur
514babeab1 Fix: delete of documents is done by page of element, not by the view
wrapper.

Conflicts:
	htdocs/langs/en_US/main.lang
	htdocs/langs/fr_FR/main.lang
	htdocs/projet/fiche.php
2012-05-30 00:18:11 +02:00
Regis Houssin
caadf396e2 Merge branch '3.2' of git+ssh://git@github.com/Dolibarr/dolibarr.git into 3.2 2012-05-30 00:09:49 +02:00
Regis Houssin
5c2922a17b Fix: big problem with files upload and more compatible with external
modules

Conflicts:
	htdocs/compta/facture.php
2012-05-30 00:09:38 +02:00
Laurent Destailleur
1618ce29c7 Fix: Return empty image instead of error when file not found. 2012-05-30 00:06:44 +02:00
Laurent Destailleur
f11430dec8 Removed deprecated strings 2012-05-29 22:22:00 +02:00
Laurent Destailleur
ea51673ce7 Update de_de translation (manual translation) 2012-05-29 22:19:02 +02:00
Laurent Destailleur
d9d32bb9f5 Merge branch '3.2' of ssh://git@github.com/Dolibarr/dolibarr.git into 3.2 2012-05-29 22:18:45 +02:00
Raphaël Doursenaud
76f8d1d37c Merge branch '3.2' of https://github.com/Dolibarr/dolibarr into 3.2 2012-05-29 10:18:39 +02:00
Regis Houssin
1cbd628971 Merge branch '3.2' of git+ssh://git@github.com/Dolibarr/dolibarr.git into 3.2 2012-05-29 09:56:20 +02:00
Regis Houssin
46ae38c86d Fix: clone object before all treatment 2012-05-29 09:56:05 +02:00
Laurent Destailleur
b6c9a37415 Fix: Avoid to have a special php module. 2012-05-28 23:06:32 +02:00
Laurent Destailleur
79cafb1c12 Fix: Subscription must use company name when type is "moral" 2012-05-28 22:14:00 +02:00
Regis Houssin
21d30c1b3e Fix: jquery fileupload broken feature 2012-05-25 20:54:45 +02:00
Raphaël Doursenaud
82af0ed28f Fixed a bug preventing invoice sorting by authors 2012-05-25 16:35:46 +02:00
Raphaël Doursenaud
ffaadcc930 Merge branch '3.2' of https://github.com/Dolibarr/dolibarr into 3.2 2012-05-24 10:46:18 +02:00
Laurent Destailleur
95b976c3d5 Fix: Bad action reset 2012-05-23 17:49:08 +02:00
Laurent Destailleur
190bcf61e4 Fix: Permissions to see project 2012-05-23 14:30:55 +02:00
Laurent Destailleur
229ae171de Fix: bug on projects visibility for external users 2012-05-23 13:10:51 +02:00
Laurent Destailleur
face8fc0be Merge branch '3.2' of ssh://git@github.com/Dolibarr/dolibarr.git into 3.2 2012-05-23 13:10:15 +02:00
Laurent Destailleur
72f67f640d Merge pull request #203 from GPCsolutions/3.2
3.2
2012-05-23 02:58:43 -07:00
Laurent Destailleur
0b7b27e795 Fix: extrafield repair was using bad hardcoded values. 2012-05-23 11:50:55 +02:00
Laurent Destailleur
04bb23d9bf Fix: [ bug #411 ] Can't modify most properties 2012-05-23 11:20:59 +02:00
Laurent Destailleur
ed48969630 Fix: [ bug #409 ] List of vat rates for supplier prices must use the
seller country.

Conflicts:
	htdocs/install/mysql/migration/3.1.0-3.2.0.sql
	htdocs/product/fournisseurs.php
2012-05-23 11:07:18 +02:00
Raphaël Doursenaud
96294403e2 Merge branch '3.2' of https://github.com/Dolibarr/dolibarr into 3.2 2012-05-22 15:15:07 +02:00
Laurent Destailleur
c1b1dcc5e7 Fix: Translation of payment term/cond 2012-05-21 20:24:20 +02:00
Regis Houssin
646651e731 Merge pull request #206 from FHenry/3.2
3.2
2012-05-21 07:11:38 -07:00
Regis Houssin
90c4e6598b Merge pull request #207 from simnandez/3.2
[ bug #399 ] Bad calculation of local taxes in update line products
2012-05-21 07:10:14 -07:00
juanjo
952864f532 [ bug #399 ] Bad calculation of local taxes in update line products 2012-05-21 15:39:15 +02:00
FHenry
23226ad472 correct bug #410 2012-05-21 11:00:08 +02:00
Laurent Destailleur
6cf8c5c102 Fix: Check for duplicate must ignore spaces before and after 2012-05-21 10:38:48 +02:00
Raphaël Doursenaud
1b1b58ad5a Merge branch '3.2' of https://github.com/Dolibarr/dolibarr into 3.2 2012-05-21 10:08:41 +02:00
Laurent Destailleur
1725e5b591 Fix: [ bug #405 ] Late icon always displayed on comm/propal.php 2012-05-21 00:08:36 +02:00
Laurent Destailleur
7a49d56589 Fix: Missing name 2012-05-16 17:07:01 +02:00
Raphaël Doursenaud
43f1fbed01 Trim payment amounts
This allows to ignore trailing characters that may triggers a warning because the payment looks greater than what's
required
2012-05-16 17:03:15 +02:00
Laurent Destailleur
a8913704e9 Fix: W3C 2012-05-16 12:35:21 +02:00
Raphaël Doursenaud
f7476d5727 Merge branch '3.2' of https://github.com/Dolibarr/dolibarr into 3.2 2012-05-15 12:04:26 +02:00
Cédric Salvador
68c1fa6c34 Fix: error in syslog call 2012-05-15 11:41:41 +02:00
Laurent Destailleur
94f9fb2e2f Fix: daylight depends also on year (not only month and day) 2012-05-15 00:49:57 +02:00
Regis Houssin
0ade601a11 Fix: add quote with date 2012-05-14 21:08:17 +02:00
Laurent Destailleur
dc1457b96a Fix: Bad timezone function. Daylight was not used. 2012-05-14 21:07:49 +02:00
Laurent Destailleur
ceb5f161f6 Fix: bad translation 2012-05-14 21:07:24 +02:00
Laurent Destailleur
b4440a6b2e Fix: Exclude nltechno modules from demo 2012-05-14 21:06:48 +02:00
Laurent Destailleur
fd362f1108 Fix: Clean sql 2012-05-13 18:04:00 +02:00
Laurent Destailleur
6f1fd1ae53 Fix: pgsql 2012-05-13 17:36:43 +02:00
Laurent Destailleur
5c62e8865a Fix: W3C 2012-05-13 17:11:31 +02:00
Laurent Destailleur
e13696db55 Fix: syntax error in name of pgsql util proc.
Fix: Add a proc to fix pgsql problems.
2012-05-13 16:41:45 +02:00
Laurent Destailleur
964bb0968f Fix: Missing log when error 2012-05-13 14:44:22 +02:00
Laurent Destailleur
91faac4c87 Fix: Bad phpunit test 2012-05-13 14:44:10 +02:00
Laurent Destailleur
06679ede7c Fix: style 2012-05-13 14:43:41 +02:00
Laurent Destailleur
4a4cdc0839 Fix: Style 2012-05-13 14:36:22 +02:00
Laurent Destailleur
ee31359488 Fix: pgsql compatibility not complete. 2012-05-13 14:33:46 +02:00
Laurent Destailleur
230f4f8f57 Fix: Missing lang 2012-05-12 18:31:04 +02:00
Laurent Destailleur
4278a113a0 Fix: hour reported is not user hour. To fix this, we show both hour
"server and user" but only if it differs.

Conflicts:
	htdocs/core/lib/functions2.lib.php
2012-05-12 16:31:51 +02:00
Laurent Destailleur
da0dc3472b Fix: Pb with backtopage
Conflicts:
	htdocs/adherents/fiche.php
2012-05-12 15:59:28 +02:00
Laurent Destailleur
e94b20f684 Fix: SQL error 2012-05-12 15:28:26 +02:00
Laurent Destailleur
be85c5c381 Fix: [ bug #404 ] Impossible d'ajouter un contact lorsque le module LDAP
est actif (erreur Array 1)
2012-05-12 12:34:18 +02:00
Laurent Destailleur
d4ca08db00 Fix: Bug #402 2012-05-11 21:27:29 +02:00
Raphaël Doursenaud
8416014cff Merge branch '3.2' of https://github.com/Dolibarr/dolibarr into 3.2 2012-05-11 15:46:23 +02:00
Laurent Destailleur
c0691b01eb Fix: Synchro with group not done when editing group only of a user. 2012-05-11 12:48:29 +02:00
Laurent Destailleur
795310b934 Fix: A lot of fix for LDAP synchro 2012-05-11 12:13:47 +02:00
Raphaël Doursenaud
3e72bdbc87 Merge branch '3.2' of https://github.com/Dolibarr/dolibarr into 3.2 2012-05-11 11:48:35 +02:00
Regis Houssin
791c08c006 Fix: [Bug #403] Insertion Image via l'éditeur WISIWIG plante 2012-05-11 10:15:10 +02:00
Laurent Destailleur
7c7d0bd495 Fix: vat rates 2012-05-10 23:08:19 +02:00
Laurent Destailleur
9bd8e3434e Merge branch '3.2' of ssh://git@github.com/Dolibarr/dolibarr.git into 3.2 2012-05-10 22:51:30 +02:00
Laurent Destailleur
a8f69ad16f Update pad files for 3.2 2012-05-10 22:43:50 +02:00
Regis Houssin
fc46a1ff97 Fix: fetch object for hookmanager 2012-05-10 19:30:54 +02:00
Raphaël Doursenaud
decdc2a9a3 Merge branch '3.2' of https://github.com/Dolibarr/dolibarr into 3.2 2012-05-10 15:05:02 +02:00
Laurent Destailleur
bd0be8f358 Fix: escape html tag value 2012-05-09 20:41:41 +02:00
Laurent Destailleur
7700293bdf Fix: Bad warning 2012-05-09 18:17:18 +02:00
Laurent Destailleur
60c77f3d50 Fix: Bad warning 2012-05-09 17:59:54 +02:00
Laurent Destailleur
9f770d862d Fix: Not escaped html value 2012-05-09 17:48:10 +02:00
Laurent Destailleur
ca67f976b6 Fix: Validate broken, missing warning on bad email. 2012-05-09 17:18:56 +02:00
Laurent Destailleur
e722138608 Fix: regression sql error
Conflicts:
	htdocs/core/modules/mailings/modules_mailings.php
2012-05-09 17:18:07 +02:00
Laurent Destailleur
32d2b0a9d6 Fix: Warning GETPOST with alpha and int must be used ONLY if content is
not a free text.
2012-05-09 16:19:54 +02:00
Laurent Destailleur
30026ecddb Merge branch '3.2' of ssh://git@github.com/Dolibarr/dolibarr.git into 3.2 2012-05-09 16:03:57 +02:00
Laurent Destailleur
d53a56f13f Fix: Missing extrafields 2012-05-09 16:02:26 +02:00
Laurent Destailleur
49c7a1f2b4 Fix: Fails to delete member 2012-05-09 15:21:43 +02:00
Regis Houssin
b9b2dbe9b1 Fix: more compatibility with multicompany 2012-05-09 12:44:30 +02:00
Regis Houssin
1726720d16 Merge pull request #198 from simnandez/3.2
3.2
2012-05-09 01:49:32 -07:00
simnandez
84a09808fc Fix:[ bug #399 ] Bad calculation of local taxes in update line products 2012-05-09 10:29:12 +02:00
Laurent Destailleur
f47d6c71ed Fix: Regression in packager 2012-05-08 23:56:51 +02:00
Laurent Destailleur
b623392062 Fix: Load lang 2012-05-08 23:00:13 +02:00
Laurent Destailleur
425ca83a99 Fix: [ bug #397 ] Product VAT is not coming from buying price 2012-05-08 21:55:52 +02:00
Laurent Destailleur
15efd9e8a1 Fix: update price for pgsql 2012-05-08 19:34:12 +02:00
Laurent Destailleur
50443f1977 Fix: Missing error management 2012-05-08 15:39:20 +02:00
Laurent Destailleur
2bb87aabbe Fix: bad br 2012-05-07 20:46:18 +02:00
Laurent Destailleur
2519690020 Fix: corrupted extra tables. 2012-05-07 20:44:20 +02:00
Raphaël Doursenaud
ea0e05b07c Fix: Typo 2012-05-07 19:07:59 +02:00
Laurent Destailleur
21d028c064 Fix: Width of gantt chart 2012-05-07 19:07:29 +02:00
Laurent Destailleur
c9a35c4e3a Too shadow with IE 2012-05-07 19:07:13 +02:00
Laurent Destailleur
22006aa4dc Fix: Better fix for gant view 2012-05-07 19:06:43 +02:00
Laurent Destailleur
82b31e1f5b Fix: Works with checkbox htdocs/core/class/html.form.class.php 2012-05-07 19:06:23 +02:00
Raphaël Doursenaud
7a3ef9bf8a Merge branch '3.2' of https://github.com/Dolibarr/dolibarr into 3.2 2012-05-07 15:52:48 +02:00
Regis Houssin
d0480f1d90 Fix: wrong permission 2012-05-07 11:16:09 +02:00
Raphaël Doursenaud
9b4b8db189 Merge branch '3.2' of https://github.com/Dolibarr/dolibarr into 3.2 2012-05-07 10:04:35 +02:00
Regis Houssin
562be023c6 Fix: [Bug #384] Gantt doesn't display beyond 20 tasks 2012-05-07 09:59:36 +02:00
Laurent Destailleur
4799c6692e Fix: Removed warning and fix pb with extra fields. 2012-05-06 20:54:58 +02:00
Laurent Destailleur
01d37ad159 Fix: pagecode when using postgresql 2012-05-06 15:31:43 +02:00
Laurent Destailleur
1b2a4f4742 Fix: log must be before request 2012-05-06 15:28:51 +02:00
Laurent Destailleur
bfba7bbc7f Fix: foreign key on non existing field 2012-05-06 15:27:31 +02:00
Laurent Destailleur
8d95ae1884 Fix: Typo 2012-05-06 02:36:55 +02:00
Laurent Destailleur
748ac3a5a7 Fix: setStatut works for user class 2012-05-06 00:06:07 +02:00
Laurent Destailleur
5ea6b99593 Fix: several fixes 2012-05-06 00:03:54 +02:00
Regis Houssin
33b9c5af45 Fix: [bug #385] Can't delete a task 2012-05-05 09:28:40 +02:00
Regis Houssin
85e797596f Fix: [Bug #388] Can't modify products after moving with arrows 2012-05-05 09:20:47 +02:00
Regis Houssin
34fe219dcb Merge branch '3.2' of git+ssh://git@github.com/Dolibarr/dolibarr.git into 3.2 2012-05-05 09:03:21 +02:00
Regis Houssin
2fe16db244 Fix: bad parameters 2012-05-05 09:03:04 +02:00
Laurent Destailleur
ebf73de8cd Fix: % must be sprintf format. 2012-05-05 03:02:13 +02:00
Laurent Destailleur
b26c3266ed Fix: Manual fix of italian language 2012-05-05 02:58:59 +02:00
Regis Houssin
f4759a0e6e Merge branch '3.2' of git+ssh://git@github.com/Dolibarr/dolibarr.git into 3.2 2012-05-04 13:21:50 +02:00
Regis Houssin
656d4942a6 Fix: MultiCompany compatibility for public page 2012-05-04 13:21:28 +02:00
Laurent Destailleur
7921965fe2 Fix: Use correct dest dir. 2012-05-03 23:13:21 +02:00
Laurent Destailleur
5953f18f54 Fix: filter on status 2012-05-03 22:58:51 +02:00
Laurent Destailleur
7a6a462ef2 Fix: Bad cr 2012-05-03 22:13:23 +02:00
Regis Houssin
21a4dd9685 Fix: missing entity field in contract
Fix: multicompany compatibility

Conflicts:
	htdocs/contrat/class/contrat.class.php
2012-05-03 18:45:26 +02:00
Regis Houssin
41e8011a80 Fix: changelog 2012-05-03 11:29:59 +02:00
Regis Houssin
46987ea4bd Merge pull request #193 from simnandez/3.2
Trad: add missing translations
2012-05-02 09:21:02 -07:00
simnandez
6c7206d210 Trad: add missing translations 2012-05-02 18:17:21 +02:00
Laurent Destailleur
39e34357a1 Merge branch '3.2' of ssh://git@github.com/Dolibarr/dolibarr.git into 3.2 2012-05-02 17:33:26 +02:00
Laurent Destailleur
557c96455e Fix: Use de_De language for de_de, not de_at 2012-05-02 17:30:02 +02:00
Raphaël Doursenaud
ea07afd6c2 Merge branch '3.2' of https://github.com/Dolibarr/dolibarr into 3.2 2012-05-02 17:29:16 +02:00
Laurent Destailleur
7e933ca175 Merge pull request #191 from simnandez/3.2
Trad: [ bug #378 ] status for order i, process is "waiting for reception"
2012-05-02 07:35:03 -07:00
Laurent Destailleur
47c0b8272d Fix: Middle
Conflicts:
	htdocs/core/tpl/login.tpl.php
2012-05-02 14:19:34 +02:00
Laurent Destailleur
afd9b817be Fix: Missing translation 2012-05-02 13:42:49 +02:00
Laurent Destailleur
f5cc12895a Fix: Missing picto 2012-05-02 13:42:34 +02:00
simnandez
c7daf233cd Trad: [ bug #378 ] status for order i, process is "waiting for
reception"
2012-05-02 09:21:52 +02:00
Laurent Destailleur
9edd80b850 Fix: Clean database to allow constraints 2012-05-01 15:28:11 +02:00
Laurent Destailleur
67adc11086 Fix: [ bug #378 ] status for order i, process is "waiting for reception" 2012-05-01 15:09:50 +02:00
Laurent Destailleur
129bb0cf2f Fix: awful IE 2012-04-30 19:15:16 +02:00
Laurent Destailleur
69b429914f Fix: Firstname/Lastname lost
Conflicts:
	htdocs/admin/tools/update.php
2012-04-30 19:03:14 +02:00
Laurent Destailleur
74887b5850 Fix: Removed warnings 2012-04-30 09:33:43 +02:00
Laurent Destailleur
3641a4b5bb Fix: Regression 2012-04-29 21:49:03 +02:00
Laurent Destailleur
d4d598d0aa Fix: left align 2012-04-28 20:51:51 +02:00
Laurent Destailleur
450ccf31a7 Fix: Bad declaration of error_reporting
Conflicts:
	htdocs/filefunc.inc.php
2012-04-28 18:52:05 +02:00
Laurent Destailleur
6b9717b250 Fix: Use same algo to scan modules than admin/modules page 2012-04-28 18:50:30 +02:00
Laurent Destailleur
2a19e9d2a1 Fix: Var can't be static 2012-04-28 18:24:53 +02:00
Laurent Destailleur
9200847eaa Fix: Try a better fix. Format of content of table should depend of
content and output rules and not on how data was input.
2012-04-28 15:44:04 +02:00
Laurent Destailleur
3918335bf7 No new feature into a beta. Also this feature is a security
hole for the moment, so it should not be enabled as a common default
feautre but must be kept hidden.
2012-04-28 15:32:48 +02:00
Laurent Destailleur
99006125fd Fix: export of print sheets 2012-04-28 14:57:16 +02:00
Raphaël Doursenaud
dfcfb48057 Typo: instantanée ne prend qu'un n. 2012-04-26 15:48:22 +02:00
Raphaël Doursenaud
62ecc497fa Fix: typo in unset 2012-04-26 15:43:27 +02:00
Regis Houssin
f7b0e1a976 Merge pull request #178 from simnandez/3.2
Fix: Bad include
2012-04-26 01:50:43 -07:00
Regis Houssin
0092f1bc89 Fix: problem of line break between label and description when
using fckeditor
2012-04-26 10:29:46 +02:00
simnandez
6e84b8ca63 Fix: Bad include 2012-04-26 08:50:39 +02:00
FHenry
fa0e1ca87e remove useless line 2012-04-25 18:37:16 +02:00
FHenry
58df839271 Rename global variable from MAIN_SOCIETE_UNSUBSCRIBE to
MAILING_EMAIL_UNSUBSCRIBE to be reliable on dolibarr implementation

Conflicts:
	htdocs/admin/mailing.php
2012-04-25 18:36:58 +02:00
FHenry
d5b21a05b2 Remove Eclipse variable warning 2012-04-25 18:33:30 +02:00
FHenry
455789d575 Remove Eclipse Warning (Undeclare variable) 2012-04-25 18:33:09 +02:00
Regis Houssin
965057307f Merge pull request #176 from simnandez/3.2
Update ChangeLog with fixes
2012-04-25 09:27:38 -07:00
simnandez
2515d27d19 Update ChangeLog with fixes 2012-04-22 18:17:16 +02:00
Laurent Destailleur
d390f3137f Fix: [ bug #367 ] "Multi-tiers" fonctionality inverted in project
contacts.
2012-04-21 19:44:05 +02:00
Laurent Destailleur
2b77a99fa3 Fix: [ bug #372 ] Upgrade error from 3.1.0 to 3.2.0 Beta 2012-04-21 19:12:20 +02:00
Laurent Destailleur
3a2caa3e46 Fix: Try a fix for the lost mainmenu session. 2012-04-20 20:38:49 +02:00
Laurent Destailleur
a9c03aa01e Merge branch '3.2' of ssh://git@github.com/Dolibarr/dolibarr.git into 3.2
Conflicts:
	htdocs/core/menus/standard/eldy.lib.php
2012-04-20 14:50:09 +02:00
Laurent Destailleur
32339b03fd Add log to try to find the mainmenu lost bug. 2012-04-20 14:48:40 +02:00
Laurent Destailleur
52f324002c Add log to try to find the mainmenu lost bug. 2012-04-20 14:39:20 +02:00
Laurent Destailleur
db53aa53b6 Fix: Lines useless 2012-04-20 14:24:02 +02:00
Laurent Destailleur
ab80f6aaa7 Fix: Can clone a proposal 2012-04-20 14:06:59 +02:00
Laurent Destailleur
eff43a8e0c Fix: wrong encoding of special chars 2012-04-20 13:59:35 +02:00
Laurent Destailleur
e503b2d858 Fix: Field must be reset after adding. 2012-04-20 13:50:23 +02:00
Laurent Destailleur
216df5ad07 Fix: Add hidden option to restore lost feature. 2012-04-20 13:46:40 +02:00
Laurent Destailleur
907c7f748d Fix: Bad CR for public note. Must work when text is full text with \n
and also when text is HTML with br.
2012-04-20 13:41:55 +02:00
Laurent Destailleur
91b8f33ea5 Fix: textarea field was not detected 2012-04-20 13:36:51 +02:00
Laurent Destailleur
5580a4cc30 Fix: Missing translation 2012-04-20 13:23:57 +02:00
Laurent Destailleur
cb8b5188be Change to help to fight the mainmenu lost bug. 2012-04-20 13:08:58 +02:00
Laurent Destailleur
8e9f3cabf3 Fix: left menu for home menu 2012-04-20 12:52:36 +02:00
Laurent Destailleur
c31c40a61e Fix: Force mainmenu. This does not solve completely bug of eaccelerator
but provide a way to have access to system menu to help to diagnose.
2012-04-20 12:10:55 +02:00
Raphaël Doursenaud
6958fe9693 Merge remote-tracking branch 'upstream/3.2' into 3.2 2012-04-20 11:06:09 +02:00
Laurent Destailleur
e0e3c07670 Fix: upload dir 2012-04-20 09:43:44 +02:00
Laurent Destailleur
64c4d59466 Merge pull request #173 from simnandez/3.2
Fix: [ bug #368 ] Product list
2012-04-20 00:29:54 -07:00
simnandez
312f81004f Fix: [ bug #370 ] Filter in accountancy -> suppliers_bills 2012-04-19 20:20:08 +02:00
simnandez
5f001c1079 Fix: [ bug #370 ] Filter in accountancy -> suppliers_bills 2012-04-19 20:14:37 +02:00
simnandez
12a3ce7746 Fix: [ bug #368 ] Product list 2012-04-19 19:10:21 +02:00
Regis Houssin
6b07571f09 Merge branch '3.2' of git+ssh://git@github.com/Dolibarr/dolibarr.git into 3.2 2012-04-18 18:54:37 +02:00
Laurent Destailleur
294cc73481 Merge branch '3.2' of ssh://git@github.com/Dolibarr/dolibarr.git into 3.2 2012-04-18 17:17:00 +02:00
Laurent Destailleur
0f20381453 Fix: Script to build package for doliwamp is now ok. 2012-04-18 17:16:07 +02:00
Laurent Destailleur
2187f3fda7 Fix: Bad case 2012-04-18 15:38:29 +02:00
Regis Houssin
5f7d552c71 Fix: Bug #369 2012-04-18 12:43:17 +02:00
Regis Houssin
ef36cbc1be Merge branch '3.2' of git+ssh://git@github.com/Dolibarr/dolibarr.git into 3.2 2012-04-18 12:21:44 +02:00
Laurent Destailleur
5b609c7ea1 Fix: project info are not lost when submiting actions on tasks 2012-04-18 12:21:12 +02:00
Laurent Destailleur
672dc99145 Fix: project info are not lost when submiting actions on tasks 2012-04-18 12:16:35 +02:00
Laurent Destailleur
54f588cb90 Merge branch '3.2' of ssh://git@github.com/Dolibarr/dolibarr.git into 3.2 2012-04-18 12:16:04 +02:00
Laurent Destailleur
7cb3e6f780 Fix: Restore broken feature 2012-04-18 11:56:52 +02:00
Laurent Destailleur
d41d516072 Merge branch '3.2' of ssh://git@github.com/Dolibarr/dolibarr.git into 3.2 2012-04-18 11:52:49 +02:00
FHenry
f235caf4ec Fix: Bug #362 and clean code 2012-04-18 11:17:26 +02:00
Laurent Destailleur
4ddb9023d7 Fix: restore broken features 2012-04-18 01:04:26 +02:00
Laurent Destailleur
ca7fa84d80 Fix: eldy theme still works without css3 2012-04-17 10:34:54 +02:00
Cédric Salvador
6e291ad70f Merge remote-tracking branch 'upstream/3.2' into 3.2
Conflicts:
	htdocs/core/class/conf.class.php
2012-04-16 15:32:39 +02:00
Laurent Destailleur
435ee2cc26 Fix: Must use tms date 2012-04-16 12:12:03 +02:00
Regis Houssin
6c7eb59f31 Fix: remove unnecessary function 2012-04-16 11:40:24 +02:00
Laurent Destailleur
ab94865c71 Fix: Generate donation document 2012-04-16 01:28:10 +02:00
Laurent Destailleur
8ec22d9f67 Fix: numbering when reset is on was wrong for past dates 2012-04-15 20:33:13 +02:00
Laurent Destailleur
fb59b5c69a Fix: date must be quoted 2012-04-15 19:20:39 +02:00
Laurent Destailleur
a31a74134c Fix: date must be quoted 2012-04-15 19:18:44 +02:00
Laurent Destailleur
5169437c2d Fix: commit at wrong place 2012-04-15 18:51:42 +02:00
Regis Houssin
f9b2f29547 Fix: sorry it's ok 2012-04-15 18:33:49 +02:00
Regis Houssin
64ddee017b Fix: you can not delete project document folder in delete task method 2012-04-15 18:18:16 +02:00
FHenry
1a56c5b021 correct bug 364 2012-04-15 17:52:47 +02:00
FHenry
779e33d490 Corect bug #364 2012-04-15 17:52:38 +02:00
FHenry
c628cfd99a Correct bug 363 2012-04-15 17:52:28 +02:00
FHenry
3abffac52a Correct bug #363 2012-04-15 17:52:13 +02:00
Laurent Destailleur
25640853f5 Merge branch '3.2' of ssh://git@github.com/Dolibarr/dolibarr.git into 3.2 2012-04-15 15:22:12 +02:00
Laurent Destailleur
b0c55c77c3 Fix: dump file to use must be last one 2012-04-15 15:21:24 +02:00
Regis Houssin
a17f7d1041 Fix: security update for multicompany
Conflicts:
	htdocs/adherents/fiche.php
2012-04-15 11:32:21 +02:00
Regis Houssin
779eacd9c1 Fix: right access error 2012-04-15 10:10:55 +02:00
Regis Houssin
a4359d6eaa Fix: disable php display errors with $dolibarr_main_prod 2012-04-15 09:33:03 +02:00
Laurent Destailleur
c3040f9609 Germany data not complete. 2012-04-14 19:30:10 +02:00
Laurent Destailleur
e446d8c7a2 Fix: Some bug into rpm and debian packaging. 2012-04-14 15:36:12 +02:00
Laurent Destailleur
6212d1a425 Fix: licence pb with fedora 2012-04-14 13:25:26 +02:00
Laurent Destailleur
42c8b25597 Fix: rpm packages 2012-04-14 13:02:21 +02:00
Laurent Destailleur
381ce5fee3 Fix: bad permissions 2012-04-14 12:41:08 +02:00
Laurent Destailleur
71c43c9069 Fix: debian epiphany and iceweasel browsers. 2012-04-14 03:18:42 +02:00
Laurent Destailleur
2ee9ca9c79 Fix: logo size was too large 2012-04-14 02:52:14 +02:00
Laurent Destailleur
16fccd7892 Fix: Work with debian 6 2012-04-14 02:43:34 +02:00
Laurent Destailleur
346fd0d09b Revert "Fix: plugin not into debian"
This reverts commit 4f5456c8d8.
2012-04-14 01:35:41 +02:00
Laurent Destailleur
4f5456c8d8 Fix: plugin not into debian 2012-04-14 01:22:54 +02:00
Laurent Destailleur
a8f66a9b09 Merge branch '3.2' of ssh://git@github.com/Dolibarr/dolibarr.git into 3.2 2012-04-13 20:08:37 +02:00
Laurent Destailleur
ab52d046b9 Fix: Avoid error when removing not correctly installed package 2012-04-13 19:55:14 +02:00
Laurent Destailleur
7e843d855a Fix: regression 2012-04-13 19:49:21 +02:00
FHenry
a11e4ceb44 Correction Bug #358 2012-04-13 19:14:05 +02:00
Regis Houssin
4f490f3e2d New: add possibility to define a page break, its very important for
internal and external modules (milestone)
2012-04-12 20:53:31 +02:00
FHenry
28aa89c659 correct bug #360 2012-04-12 11:18:55 +02:00
Laurent Destailleur
0e4ca576ec Merge branch '3.2' of ssh://git@github.com/Dolibarr/dolibarr.git into 3.2 2012-04-12 00:02:28 +02:00
Laurent Destailleur
53a78838f8 Fix: Avoid call if function not defined 2012-04-11 17:28:04 +02:00
Regis Houssin
eb6008bb4d Fix: missing langs object 2012-04-11 16:27:39 +02:00
Laurent Destailleur
a748466758 Fix: this must not be used inside static classes 2012-04-11 14:45:12 +02:00
Laurent Destailleur
c7317ed2a1 Add dump of 3.2.0 demo 2012-04-11 12:14:55 +02:00
Laurent Destailleur
1e526a2a03 Revert "uniformise code"
This reverts commit 06761d9753.
2012-04-11 10:49:46 +02:00
Laurent Destailleur
b141f3caf5 Revert "to add delivery date"
This reverts commit 8a20b670e7.
2012-04-11 10:49:18 +02:00
Laurent Destailleur
5aae71f9de Revert "to add delivery date"
This reverts commit b948ee1212.
2012-04-11 10:48:35 +02:00
Laurent Destailleur
bb917bea08 Revert "Add __MAILTOEMAIL__ and configutation gobal varialbe of Check Read and unsubscribe in Admin part"
This reverts commit 2a12b24644.
2012-04-11 10:48:02 +02:00
Laurent Destailleur
3870428f16 Merge branch '3.2' of ssh://git@github.com/Dolibarr/dolibarr.git into 3.2 2012-04-11 10:46:06 +02:00
Laurent Destailleur
307c010b90 Fix: Removed warning 2012-04-11 08:32:29 +02:00
Regis Houssin
d7e579e234 Fix: invert emetteur and problem with long phone number 2012-04-11 08:32:00 +02:00
Regis Houssin
45e34aba65 Fix: missing company logo and invert from to ! 2012-04-11 08:31:47 +02:00
FHenry
2a12b24644 Add __MAILTOEMAIL__ and configutation gobal varialbe of Check Read and
unsubscribe in Admin part
2012-04-11 08:24:52 +02:00
Grand Philippe
b948ee1212 to add delivery date 2012-04-11 08:20:48 +02:00
Grand Philippe
8a20b670e7 to add delivery date 2012-04-11 08:20:37 +02:00
Regis Houssin
6ef98b3d46 Fix: restore dolibarr version for this branch 2012-04-11 08:11:27 +02:00
Laurent Destailleur
d3198894b8 Merge branch '3.2' of https://github.com/Dolibarr/dolibarr into 3.2 2012-04-10 12:40:23 +02:00
Laurent Destailleur
231fd6b2ae Fix: Removed warning 2012-04-10 12:37:53 +02:00
Regis Houssin
8f32a35faa Fix: invert emetteur and problem with long phone number 2012-04-10 12:34:02 +02:00
Regis Houssin
6616254504 Merge branch '3.2' of git+ssh://git@github.com/Dolibarr/dolibarr.git into 3.2 2012-04-10 12:06:37 +02:00
Regis Houssin
a98e57c596 Fix: missing company logo and invert from to ! 2012-04-10 12:06:26 +02:00
Laurent Destailleur
d4cc4b4288 Fix: bad link 2012-04-10 11:16:47 +02:00
Laurent Destailleur
1104387b72 Fix: Bad link 2012-04-10 11:13:15 +02:00
Laurent Destailleur
49bb9d774d Fix: W3C 2012-04-10 11:00:56 +02:00
Laurent Destailleur
58b0751599 Fix: translation 2012-04-10 10:55:03 +02:00
Regis Houssin
dc46b82cf3 Fix: best practice 2012-04-10 08:44:43 +02:00
Laurent Destailleur
141fa014e6 Revert code because it does not fix security hole completely. Also it
does work on origin but at a transition level.
Sanitizing for command line data must not appears inside a function used
for http data. I prefer fixing this at the source and also using a rule
that clean all attacks completely instead of a rule that clean "most
problem but not all".
2012-04-10 01:24:52 +02:00
Laurent Destailleur
b6b873cfc5 Revert "Fix: security"
This reverts commit 56daf57cb1.
2012-04-10 01:11:37 +02:00
Regis Houssin
ae8b16b9fc Fix: add special test 2012-04-09 22:53:28 +02:00
Regis Houssin
64d60d1270 Fix: sql injection 2012-04-09 22:49:19 +02:00
Regis Houssin
56daf57cb1 Fix: security 2012-04-09 22:27:40 +02:00
Laurent Destailleur
9a4314947d Fix: Rounding 2012-04-09 09:00:24 +02:00
Laurent Destailleur
d892f36fe8 Fix: rounding 2012-04-09 08:59:29 +02:00
Laurent Destailleur
4804530468 Fix: Back page to list of contacts(cherry picked from commit 2d9ed89a8d) 2012-04-09 01:13:45 +02:00
Laurent Destailleur
06b0330d84 New logo 2012-04-08 23:33:07 +02:00
386 changed files with 19635 additions and 13189 deletions

View File

@@ -2,11 +2,7 @@
English Dolibarr ChangeLog
--------------------------------------------------------------
***** ChangeLog for 3.3 compared to 3.2 *****
***** ChangeLog for 3.2 compared to 3.1 *****
***** ChangeLog for 3.2.0 compared to 3.1.2 *****
WARNING: PHP lower than 5.x are no more supported.
WARNING: Because of a major datastructure change onto supplier prices tables, be aware
to make a backup of your database before making upgrade.
@@ -70,6 +66,10 @@ For users:
- Fix: Can use POS module with several concurrent users.
- Fix: Installer don't fails with Mysql version that added a ssl_cypher field.
- Fix: Sanitize input parameters.
- Fix: [ bug #368 ] Product list
- Fix: [ bug #370 ] Filter in accountancy -> suppliers_bills
- Fix: [ bug #399 ] Bad calculation of local taxes in update line products
- Fix: [ bug #427 ] Bad links to wiki help in certains menus
For developers:
- New: Can add a left menu into an existing top menu or left menu.
@@ -98,6 +98,20 @@ For developers:
WARNING: To reduce technic debt, all functions dolibarr_xxx were renamed int dol_xxx.
***** ChangeLog for 3.1.2 compared to 3.1.1 *****
- Fix: Can clone a proposal
- Fix: Add member ID in substitution method
- Fix: Duplicate end tag and missing form parts
- Fix: Support companies with no prof id.
- Fix: Sanitize data
- Fix: Bug #318
- Fix: Bug #369
- Fix: More bugs
***** ChangeLog for 3.1.1 compared to 3.1.0 *****
- New: Add option FACTURE_DEPOSITS_ARE_JUST_PAYMENTS. With this option added,

View File

@@ -1,9 +1,9 @@
dolibarr (3.3.0+nmu1) unstable; urgency=low
dolibarr (3.2.0+nmu1) unstable; urgency=low
* Non-maintainer upload.
* New upstream release.
closes: bug#634783
-- Dolibarr team <contact@dolibarr.org> Mon, 10 Aug 2011 12:00:00 +0100
-- Dolibarr team <contact@dolibarr.org> Mon, 18 Jun 2012 12:00:00 +0100
# For a changelog file dedicated to end users, see /usr/share/doc/dolibarr/ChangeLog.gz

View File

@@ -9,13 +9,12 @@ Build-Depends: debhelper (>= 7), po-debconf, dpatch
Package: dolibarr
Depends: libapache2-mod-php5 | libapache2-mod-php5filter | php5-cgi | php5-fpm | php5,
php5-mysql | php5-mysqli,
php5-cli, php5-curl, php5-gd, php5-ldap, php-pear, php-mail-mime, php5-geoip, php-fpdf,
php5-cli, php5-curl, php5-gd, php5-ldap, php-pear, php-mail-mime, php5-geoip,
php-fpdf,
libphp-adodb,
libfpdi-php,
libfpdf-tpl-php,
libnusoap-php,
libphp-pclzip,
libjs-jquery, libjs-jquery-ui, libjs-flot, ckeditor,
libjs-jquery, libjs-jquery-ui, ckeditor,
ttf-dejavu-core,
xdg-utils,
mysql-server,

View File

@@ -6,11 +6,10 @@ Installed-Size: 61200
Depends: libapache2-mod-php5 | libapache2-mod-php5filter | php5-cgi | php5-fpm | php5,
php5-mysql | php5-mysqli,
php5-cli, php5-curl, php5-gd, php5-ldap, php-pear, php-mail-mime, php5-geoip,
libphp-adodb,
libnusoap-php,
libphp-pclzip,
libfpdi-php,
libfpdf-tpl-php,
ckeditor,
libjs-jquery, libjs-jquery-ui, ckeditor,
ttf-dejavu-core,
xdg-utils,
mysql-server

View File

@@ -83,7 +83,8 @@ case "$1" in
chown -R root:www-data $installconfig
chmod -R 660 $installconfig
if [ ! -s $config ]
# If a conf already exists and its content was already completed by installer
if [ ! -s $config ] || ! grep -q "File generated by" $config
then
# Create an empty conf.php with permission to web server
echo Create empty file $config
@@ -93,17 +94,17 @@ case "$1" in
else
# File already exist. We add params not found.
echo Add new params to overwrite path to use shared libraries/fonts
grep -q -c "dolibarr_lib_ADODB_PATH" $config || echo "<?php \$dolibarr_lib_ADODB_PATH='/usr/share/php/adodb'; ?>" >> $config
grep -q -c "dolibarr_lib_FPDI_PATH" $config || echo "<?php \$dolibarr_lib_FPDI_PATH='/usr/share/php/fpdi'; ?>" >> $config
grep -q -c "dolibarr_lib_GEOIP_PATH" $config || echo "<?php \$dolibarr_lib_GEOIP_PATH=''; ?>" >> $config
grep -q -c "dolibarr_lib_NUSOAP_PATH" $config || echo "<?php \$dolibarr_lib_NUSOAP_PATH='/usr/share/php/nusoap'; ?>" >> $config
grep -q -c "dolibarr_lib_ODTPHP_PATHTOPCLZIP" $config || echo "<?php \$dolibarr_lib_ODTPHP_PATHTOPCLZIP='/usr/share/php/libphp-pclzip'; ?>" >> $config
grep -q -c "dolibarr_lib_PHPEXCEL_PATH" $config || echo "<?php \$dolibarr_lib_PHPEXCEL_PATH=''; ?>" >> $config
grep -q -c "dolibarr_lib_TCPDF_PATH" $config || echo "<?php \$dolibarr_lib_TCPDF_PATH=''; ?>" >> $config
grep -q -c "dolibarr_js_CKEDITOR" $config || echo "<?php \$dolibarr_js_CKEDITOR='/javascript/ckeditor'; ?>" >> $config
grep -q -c "dolibarr_js_JQUERY" $config || echo "<?php \$dolibarr_js_JQUERY='/javascript/jquery'; ?>" >> $config
grep -q -c "dolibarr_js_JQUERY_UI" $config || echo "<?php \$dolibarr_js_JQUERY_UI='/javascript/jquery-ui'; ?>" >> $config
grep -q -c "dolibarr_js_JQUERY_FLOT" $config || echo "<?php \$dolibarr_js_JQUERY_FLOT='/javascript/flot'; ?>" >> $config
grep -q -c "dolibarr_lib_ADODB_PATH" $config || [ ! -d "/usr/share/php/adodb" ] || echo "<?php \$dolibarr_lib_ADODB_PATH='/usr/share/php/adodb'; ?>" >> $config
grep -q -c "dolibarr_lib_FPDI_PATH" $config || [ ! -d "/usr/share/php/fpdi" ] || echo "<?php \$dolibarr_lib_FPDI_PATH='/usr/share/php/fpdi'; ?>" >> $config
#grep -q -c "dolibarr_lib_GEOIP_PATH" $config || echo "<?php \$dolibarr_lib_GEOIP_PATH=''; ?>" >> $config
grep -q -c "dolibarr_lib_NUSOAP_PATH" $config || [ ! -d "/usr/share/php/nusoap" ] || echo "<?php \$dolibarr_lib_NUSOAP_PATH='/usr/share/php/nusoap'; ?>" >> $config
grep -q -c "dolibarr_lib_ODTPHP_PATHTOPCLZIP" $config || [ ! -d "/usr/share/php/libphp-pclzip" ] || echo "<?php \$dolibarr_lib_ODTPHP_PATHTOPCLZIP='/usr/share/php/libphp-pclzip'; ?>" >> $config
#grep -q -c "dolibarr_lib_PHPEXCEL_PATH" $config || echo "<?php \$dolibarr_lib_PHPEXCEL_PATH=''; ?>" >> $config
#grep -q -c "dolibarr_lib_TCPDF_PATH" $config || echo "<?php \$dolibarr_lib_TCPDF_PATH=''; ?>" >> $config
grep -q -c "dolibarr_js_CKEDITOR" $config || [ ! -d "/usr/share/javascript/ckeditor" ] || echo "<?php \$dolibarr_js_CKEDITOR='/javascript/ckeditor'; ?>" >> $config
grep -q -c "dolibarr_js_JQUERY" $config || [ ! -d "/usr/share/javascript/jquery" ] || echo "<?php \$dolibarr_js_JQUERY='/javascript/jquery'; ?>" >> $config
grep -q -c "dolibarr_js_JQUERY_UI" $config || [ ! -d "/usr/share/javascript/jquery-ui" ] || echo "<?php \$dolibarr_js_JQUERY_UI='/javascript/jquery-ui'; ?>" >> $config
grep -q -c "dolibarr_js_JQUERY_FLOT" $config || [ ! -d "/usr/share/javascript/flot" ] || echo "<?php \$dolibarr_js_JQUERY_FLOT='/javascript/flot'; ?>" >> $config
grep -q -c "dolibarr_font_DOL_DEFAULT_TTF_BOLD" $config || echo "<?php \$dolibarr_font_DOL_DEFAULT_TTF_BOLD='/usr/share/fonts/truetype/ttf-dejavu/DejaVuSans-Bold.ttf'; ?>" >> $config
fi

View File

@@ -3,7 +3,8 @@
#
# see: dh_installdeb(1)
set -e
#set -e
set +e
# summary of how this script can be called:
# * <postrm> `remove'

View File

@@ -27,7 +27,7 @@ $force_install_lockinstall='444';
// Value to overwrite path to use shared libraries/fonts instead of embedded one
$force_dolibarr_lib_ADODB_PATH='/usr/share/php/adodb';
$force_dolibarr_lib_FPDI_PATH='/usr/share/php/fpdi';
//$force_dolibarr_lib_FPDI_PATH='/usr/share/php/fpdi';
$force_dolibarr_lib_GEOIP_PATH='';
$force_dolibarr_lib_NUSOAP_PATH='/usr/share/php/nusoap';
$force_dolibarr_lib_ODTPHP_PATHTOPCLZIP='/usr/share/php/libphp-pclzip';
@@ -36,7 +36,7 @@ $force_dolibarr_lib_TCPDF_PATH='';
$force_dolibarr_js_CKEDITOR='/javascript/ckeditor';
$force_dolibarr_js_JQUERY='/javascript/jquery';
$force_dolibarr_js_JQUERY_UI='/javascript/jquery-ui';
$force_dolibarr_js_JQUERY_FLOT='/javascript/flot';
//$force_dolibarr_js_JQUERY_FLOT='/javascript/flot';
$force_dolibarr_font_DOL_DEFAULT_TTF_BOLD='/usr/share/fonts/truetype/ttf-dejavu/DejaVuSans-Bold.ttf';
?>

View File

@@ -93,17 +93,18 @@ clean:
# clean from all embedded libraries (we use package dependencies instead)
rm -fr htdocs/includes/adodbtime
rm -fr htdocs/includes/ckeditor
rm -fr htdocs/includes/fpdfi
# rm -fr htdocs/includes/fpdfi
rm -fr htdocs/includes/fonts
rm -fr htdocs/includes/geoip
rm -fr htdocs/includes/nusoap
rm -fr htdocs/includes/odtphp/zip/pclzip
rm -fr htdocs/includes/jquery/css
rm -fr htdocs/includes/jquery/js
rm -fr htdocs/includes/jquery/plugins/flot
# rm -fr htdocs/includes/jquery/plugins/flot
rm -fr htdocs/includes/jquery/plugins/jstree
rm -fr htdocs/includes/jquery/plugins/lightbox
rm -fr htdocs/includes/jquery/plugins/mobile
rm -fr htdocs/includes/jquery/plugins/multiselect
rm -fr htdocs/includes/phpexcel/PHPExcel/Shared/PDF
rm -fr htdocs/includes/phpexcel/PHPExcel/Shared/PCLZip
rm -fr htdocs/includes/tcpdf/fonts/dejavu-fonts-ttf-2.33

View File

@@ -31,7 +31,7 @@ PROJECT_NAME = dolibarr
# This could be handy for archiving the generated documentation or
# if some version control system is used.
PROJECT_NUMBER = 3.3.0
PROJECT_NUMBER = 3.2.0
# The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute)
# base path where the generated documentation will be put.

View File

@@ -16,13 +16,14 @@
[Setup]
; ----- Change this -----
AppName=DoliWamp
; DoliWamp-x.x.x or DoliWamp-x.x.x-dev or DoliWamp-x.x.x-beta
AppVerName=DoliWamp-3.3.0-alpha
; DoliWamp-x.x x or DoliWamp-x.x.x-dev or DoliWamp-x.x.x-beta
OutputBaseFilename=DoliWamp-3.3.0-alpha
; DoliWamp-x.x.x or DoliWamp-x.x.x-alpha or DoliWamp-x.x.x-beta or DoliWamp-x.x.x-rc or DoliWamp-x.x.x
AppVerName=DoliWamp-3.2.0
; DoliWamp-x.x x or DoliWamp-x.x.x-alpha or DoliWamp-x.x.x-beta or DoliWamp-x.x.x-rc or DoliWamp-x.x.x
OutputBaseFilename=DoliWamp-3.2.0
; Define full path from wich all relative path are defined
; You must modify this to put here your dolibarr root directory
SourceDir=c:\Documents and Settings\ldestail\git\dolibarr
;SourceDir=C:\Documents and Settings\ldestail\git\dolibarr_old
SourceDir=Z:\home\ldestail\git\dolibarr_old
; ----- End of change
;OutputManifestFile=build\doliwampbuild.log
AppId=doliwamp
@@ -31,7 +32,7 @@ AppPublisherURL=http://www.nltechno.com
AppSupportURL=http://www.dolibarr.org
AppUpdatesURL=http://www.dolibarr.org
AppComments=DoliWamp includes Dolibarr, Apache, PHP and Mysql softwares.
AppCopyright=Copyright (C) 2008-2011 Laurent Destailleur, NLTechno
AppCopyright=Copyright (C) 2008-2012 Laurent Destailleur, NLTechno
DefaultDirName=c:\dolibarr
DefaultGroupName=Dolibarr
;LicenseFile=COPYING

View File

@@ -9,8 +9,8 @@ use Cwd;
$PROJECT="dolibarr";
$MAJOR="3";
$MINOR="3";
$BUILD="0-alpha"; # Mettre x pour release, x-dev pour dev, x-beta pour beta, x-rc pour release candidate
$MINOR="2";
$BUILD="0"; # Mettre x pour release, x-dev pour dev, x-beta pour beta, x-rc pour release candidate
$RPMSUBVERSION="auto"; # auto use value found into BUILD
@LISTETARGET=("TGZ","ZIP","RPM_GENERIC","RPM_FEDORA","RPM_MANDRIVA","RPM_OPENSUSE","DEB","APS","EXEDOLIWAMP","SNAPSHOT"); # Possible packages
@@ -24,7 +24,7 @@ $RPMSUBVERSION="auto"; # auto use value found into BUILD
"RPM_OPENSUSE"=>"rpmbuild",
"DEB"=>"dpkg",
"APS"=>"zip",
"EXEDOLIWAMP"=>"iscc.exe"
"EXEDOLIWAMP"=>"ISCC.exe"
);
%ALTERNATEPATH=(
"7z"=>"7-ZIP",
@@ -38,7 +38,7 @@ $FILENAMEZIP="$PROJECT-$MAJOR.$MINOR.$BUILD";
$FILENAMERPM="$PROJECT-$MAJOR.$MINOR.$BUILD-$RPMSUBVERSION";
$FILENAMEDEB="${PROJECT}_${MAJOR}.${MINOR}.${BUILD}";
$FILENAMEAPS="$PROJECT-$MAJOR.$MINOR.$BUILD.app";
$FILENAMEEXEDOLIWAMP="$PROJECT-$MAJOR.$MINOR.$BUILD";
$FILENAMEEXEDOLIWAMP="DoliWamp-$MAJOR.$MINOR.$BUILD";
if (-d "/usr/src/redhat") { $RPMDIR="/usr/src/redhat"; } # redhat
if (-d "/usr/src/RPM") { $RPMDIR="/usr/src/RPM"; } # mandrake
@@ -102,7 +102,8 @@ for (0..@ARGV-1) {
$FILENAMESNAPSHOT.="-".$PREFIX;
}
}
if ($ENV{"DESTI"}) { $DESTI = $ENV{"DESTI"}; } # Force output dir if env DESTI is defined
if ($ENV{"DESTIBETARC"} && $BUILD =~ /[a-z]/i) { $DESTI = $ENV{"DESTIBETARC"}; } # Force output dir if env DESTI is defined
if ($ENV{"DESTISTABLE"} && $BUILD =~ /^[0-9]+$/) { $DESTI = $ENV{"DESTISTABLE"}; } # Force output dir if env DESTI is defined
print "Makepack version $VERSION\n";
@@ -165,7 +166,7 @@ $atleastonerpm=0;
foreach my $target (keys %CHOOSEDTARGET) {
if ($target =~ /RPM/i)
{
if ($atleastonerpm && ! $ENV{"DESTI"})
if ($atleastonerpm && ($DESTI eq "$SOURCE/build"))
{
print "Error: You asked creation of several rpms. Because all rpm have same name, you must defined an environment variable DESTI to tell packager where it can create subdirs for each generated package.\n";
exit;
@@ -323,7 +324,6 @@ if ($nboftargetok) {
$ret=`rm -f $BUILDROOT/$PROJECT/.gitignore $BUILDROOT/$PROJECT/*/.gitignore $BUILDROOT/$PROJECT/*/*/.gitignore $BUILDROOT/$PROJECT/*/*/*/.gitignore $BUILDROOT/$PROJECT/*/*/*/*/.gitignore $BUILDROOT/$PROJECT/*/*/*/*/*/.gitignore $BUILDROOT/$PROJECT/*/*/*/*/*/*/.gitignore`;
$ret=`rm -f $BUILDROOT/$PROJECT/htdocs/includes/geoip/sample*.*`;
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/jquery/plugins/lightbox`;
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/jquery/plugins/jstree`;
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/nusoap/lib/Mail`;
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/phpexcel/license.txt`;
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/phpexcel/PHPExcel/Shared/PDF`;
@@ -763,8 +763,10 @@ if ($nboftargetok) {
print "Remove target $FILENAMEEXEDOLIWAMP.exe...\n";
unlink "$NEWDESTI/$FILENAMEEXEDOLIWAMP.exe";
print "Compil exe $FILENAMEEXEDOLIWAMP.exe file from iss file \"$SOURCE\\build\\exe\\doliwamp\\doliwamp.iss\"\n";
$cmd= "iscc.exe \"$SOURCE\\build\\exe\\doliwamp\\doliwamp.iss\"";
$SOURCEBACK=$SOURCE;
$SOURCEBACK =~ s/\//\\/g;
print "Compil exe $FILENAMEEXEDOLIWAMP.exe file from iss file \"$SOURCEBACK\\build\\exe\\doliwamp\\doliwamp.iss\"\n";
$cmd= "ISCC.exe \"$SOURCEBACK\\build\\exe\\doliwamp\\doliwamp.iss\"";
print "$cmd\n";
$ret= `$cmd`;
#print "$ret\n";
@@ -772,6 +774,8 @@ if ($nboftargetok) {
# Move to final dir
print "Move \"$SOURCE\\build\\$FILENAMEEXEDOLIWAMP.exe\" to $NEWDESTI/$FILENAMEEXEDOLIWAMP.exe\n";
rename("$SOURCE/build/$FILENAMEEXEDOLIWAMP.exe","$NEWDESTI/$FILENAMEEXEDOLIWAMP.exe");
print "Move $SOURCE/build/$FILENAMEEXEDOLIWAMP.exe to $NEWDESTI/$FILENAMEEXEDOLIWAMP.exe\n";
$ret=`mv "$SOURCE/build/$FILENAMEEXEDOLIWAMP.exe" "$NEWDESTI/$FILENAMEEXEDOLIWAMP.exe"`;
next;
}
}

View File

@@ -8,7 +8,7 @@ This files describe steps made by Dolibarr packaging team to make a
beta version of Dolibarr, step by step.
- Check all files are commited.
- Update version/info in / directory (README*.txt, ChangeLog...)
- Update version/info in /ChangeLog and /filefunc.inc.php
- Update version number with x.x.x in build/doxygen/dolibarr-doxygen.doxyfile
- Update version number with x.x.x in build/perl/virtualmin/dolibarr.pl
- Update version number with x.x.x-y in build/makepack-dolibarr.pl
@@ -34,7 +34,7 @@ This files describe steps made by Dolibarr packaging team to make a
complete release of Dolibarr, step by step.
- Check all files are commited.
- Update version/info in / directory (README*.txt, ChangeLog...)
- Update version/info in /ChangeLog and /filefunc.inc.php
- Update version number with x.x.x-y in build/makepack-dolibarr.pl
- Update version number with x.x.x-y in build/exe/doliwamp/doliwamp.iss
- Update version number with x.x.x-y in htdocs/filefunc.inc.php

View File

@@ -4,10 +4,10 @@
<CompanyName />
<Program_Info>
<Program_Name>DoliWamp</Program_Name>
<Program_Version>3.1.0</Program_Version>
<Program_Release_Month>07</Program_Release_Month>
<Program_Release_Day>09</Program_Release_Day>
<Program_Release_Year>2011</Program_Release_Year>
<Program_Version>3.2..0</Program_Version>
<Program_Release_Month>05</Program_Release_Month>
<Program_Release_Day>10</Program_Release_Day>
<Program_Release_Year>2012</Program_Release_Year>
<Program_Cost_Dollars />
<Program_Cost_Other_Code />
<Program_Cost_Other />
@@ -43,6 +43,7 @@
<Char_Desc_250>DoliWamp is the Dolibarr ERP/CRM for Windows, the easy to use open source software to manage your activity (invoices, customers, suppliers, contracts, agenda, emailings...) and any other things a small or mid-sized business or a foundation needs.</Char_Desc_250>
<Char_Desc_450>DoliWamp is the Dolibarr ERP/CRM autoinstaller for Windows users with no technical knowledge to install Dolibarr and all its prerequisites (Apache, Mysql, PHP) with just one auto-exe file. Dolibarr ERP/CRM is a software built by modules addition (you enable only features you need), to manage small or mid-sized businesses, freelancers or foundations.</Char_Desc_450>
<Char_Desc_2000>DoliWamp is the Dolibarr ERP/CRM for Windows. Dolibarr ERP &amp; CRM is a software built by modules addition (you enable only features you need), to manage small or mid-sized businesses, freelancers or foundations (You can manage or follow contacts, invoices, orders, commercial proposals, products, stock management, agenda, mass emailings, members of a foundation, bank accounts...). Based on a WAMP, MAMP or LAMP server (Apache, Mysql, PHP for all Operating Systems), you can install it as a standalone program or use it from anywhere with any web browser. Dolibarr is an OpenSource project. It differs from other ERP or CRM softwares (like OpenAguila, OpenBravo, OpenERP, Neogia, Compiere, etc) because everything was made to be more simple: Simple to install, Simple to use, Simple to develop.
DoliWamp is the auto-installer for Windows users with no technical knowledge to install Dolibarr ERP/CRM and all its prerequisites (Apache, Mysql, PHP) with just one auto-exe file.</Char_Desc_2000>
@@ -81,6 +82,11 @@ DoliWamp is the auto-installer for Windows users with no technical knowledge to
</Web_Info>
<Permissions>
<Distribution_Permissions>GNU GPL</Distribution_Permissions>
<EULA>GNU GPL</EULA>
</Permissions>
<ASP>
<ASP_FORM>Y</ASP_FORM>
<ASP_Member>N</ASP_Member>
<ASP_Member_Number />
</ASP>
<Affiliates>
@@ -187,9 +193,4 @@ DoliWamp is the auto-installer for Windows users with no technical knowledge to
<Affiliates_Yaskifo_Order_Page />
<Affiliates_Yaskifo_Vendor_ID />
<Affiliates_Yaskifo_Product_ID />
</Affiliates>
<ASP>
<ASP_FORM>Y</ASP_FORM>
<ASP_Member>N</ASP_Member>
<ASP_Member_Number />
<Affiliates_Yaskifo_Maximum_Commission_Rate />

View File

@@ -4,10 +4,10 @@
<CompanyName />
<Program_Info>
<Program_Name>Dolibarr</Program_Name>
<Program_Version>3.1..0</Program_Version>
<Program_Release_Month>07</Program_Release_Month>
<Program_Release_Day>09</Program_Release_Day>
<Program_Release_Year>2011</Program_Release_Year>
<Program_Version>3.2.0</Program_Version>
<Program_Release_Month>05</Program_Release_Month>
<Program_Release_Day>10</Program_Release_Day>
<Program_Release_Year>2012</Program_Release_Year>
<Program_Cost_Dollars />
<Program_Cost_Other_Code />
<Program_Cost_Other />
@@ -43,11 +43,31 @@
<Char_Desc_250>Dolibarr ERP &amp; CRM, the easy to use open source software to manage your activity (invoices, customers, suppliers, contracts, agenda, emailings...) and any other things a small or mid-sized business or a foundation needs to follow.</Char_Desc_250>
<Char_Desc_450>Dolibarr ERP &amp; CRM is a software built by modules addition (you enable only features you need), to manage small or medium companies, freelancers or foundations. We can say Dolibarr is an ERP or CRM. Dolibarr is also available with an auto-installer for Windows users with no technical knowledge to install Dolibarr and all its prerequisites (Apache, Mysql, PHP) with just one auto-exe file. See DoliWamp software for this.</Char_Desc_450>
<Char_Desc_2000>Dolibarr ERP &amp; CRM is a software built by modules addition (you enable only features you need), to manage small or mid-sized businesses, freelancers or foundations. We can say Dolibarr is an ERP or CRM (or both depending on activated modules). It's an OpenSource project base on a WAMP, MAMP or LAMP server (Apache, Mysql, PHP for all Operating Systems). Dolibarr differs from other ERP or CRM softwares (like OpenAguila, OpenBravo, OpenERP, Neogia, Compiere, etc) because everything was made to be more simple:
Simple to install
Simple to use
Simple to develop
Note that Dolibarr is also available with an auto-installer for Windows or Ubuntu users with no technical knowledge to install Dolibarr and all its prerequisites (Apache, Mysql, PHP) with just one auto-exe file. This version is called DoliWamp (for Windows) or DoliBuntu (for Ubuntu/Debian).</Char_Desc_2000>
</English>
<French>
<Keywords>dolibarr, erp, crm, invoices, commercial proposals, orders, accounting, stock, products, agenda, bank, business, company, foundation, management, sme, doliwamp</Keywords>
<Char_Desc_45>Dolibarr ERP &amp; CRM</Char_Desc_45>
<Char_Desc_80>Dolibarr ERP &amp; CRM, le gestionnaire simple pour gérer votre activité</Char_Desc_80>
<Char_Desc_250>Dolibarr ERP &amp; CRM, le logiciel simple et OpenSource pour gérer votre activité (factures, devis, facturation, commandes, compta, trésorerie, stocks, produits, agenda, comptes bancaires, associations)</Char_Desc_250>
<Char_Desc_450>Dolibarr ERP/CRM est un logiciel modulaire (on n'active que les fonctions que l'on désire) de gestions de TPE/PME, d'indépendants, d'entrepreneurs ou d'associations. En terme plus techniques, c'est un ERP et CRM. C'est un projet OpenSource qui s'exécute au sein d'un serveur Web et peut donc être accessible depuis n'importe quel lieu disposant d'une connexion Internet (Projet basé sur un serveur WAMP, MAMP ou LAMP: Apache, MySQL, PHP).</Char_Desc_450>
<Char_Desc_2000>Dolibarr ERP/CRM est un logiciel modulaire (on n'active que les fonctions que l'on désire) de gestions de TPE/PME, d'indépendants, d'entrepreneurs ou d'associations. En terme plus techniques, c'est un ERP et CRM. C'est un projet OpenSource qui s'exécute au sein d'un serveur Web et peut donc être accessible depuis n'importe quel lieu disposant d'une connexion Internet (Projet basé sur un serveur WAMP, MAMP ou LAMP: Apache, MySQL, PHP). Dolibarr vient compléter les offres déjà nombreuses de logiciels de cette catégorie (comme OpenBravo, OpenERP, SugarCRM, Neogia, Compiere, etc.) mais se démarque par le fait qu'ici tout est fait pour offrir de la simplicité (règle des 3 S):
Simple pour l'installation (avec au choix des installeurs clé en main pour ceux qui ignorent comment installer un serveur Web, ou une installation manuelle)
@@ -56,18 +76,6 @@ Note that Dolibarr is also available with an auto-installer for Windows or Ubunt
Simple pour l'utilisation (fonctions modulaires pour ne pas surcharger les menus, informations claires à la saisie)
<Char_Desc_250>Dolibarr è un a gestionale open source e gratuito per piccole e medie imprese, fondazioni e liberi professionisti. Include varie funzionalità per Enterprise Resource Planning e gestione dei clienti (CRM), ma anche ulteriori attività.</Char_Desc_250>
<Char_Desc_450>Dolibarr è un programma gestionale open source e gratuito per piccole e medie imprese, fondazioni e liberi professionisti. Include varie funzionalità per Enterprise Resource Planning e gestione dei clienti (CRM), ma anche ulteriori attività. Dolibar è progettato per poter fornire solo ciò di cui hai bisogno ed essere facile da usare.</Char_Desc_450>
<Char_Desc_2000>Dolibarr è un programma gestionale open source e gratuito per piccole e medie imprese, fondazioni e liberi professionisti. Include varie funzionalità per Enterprise Resource Planning e gestione dei clienti (CRM), ma anche ulteriori attività. Dolibar è progettato per poter fornire solo ciò di cui hai bisogno ed essere facile da usare. Dolibar è completamente web-based, progettato per poter fornire solo ciò di cui hai bisogno ed essere facile da usare.</Char_Desc_2000>
</Italian>
<French>
<Keywords>dolibarr, erp, crm, invoices, commercial proposals, orders, accounting, stock, products, agenda, bank, business, company, foundation, management, sme, doliwamp</Keywords>
<Char_Desc_45>Dolibarr ERP &amp; CRM</Char_Desc_45>
<Char_Desc_80>Dolibarr ERP &amp; CRM, le gestionnaire simple pour gérer votre activité</Char_Desc_80>
<Char_Desc_250>Dolibarr ERP &amp; CRM, le logiciel simple et OpenSource pour gérer votre activité (factures, devis, facturation, commandes, compta, trésorerie, stocks, produits, agenda, comptes bancaires, associations)</Char_Desc_250>
<Char_Desc_450>Dolibarr ERP/CRM est un logiciel modulaire (on n'active que les fonctions que l'on désire) de gestions de TPE/PME, d'indépendants, d'entrepreneurs ou d'associations. En terme plus techniques, c'est un ERP et CRM. C'est un projet OpenSource qui s'exécute au sein d'un serveur Web et peut donc être accessible depuis n'importe quel lieu disposant d'une connexion Internet (Projet basé sur un serveur WAMP, MAMP ou LAMP: Apache, MySQL, PHP).</Char_Desc_450>
<Char_Desc_2000>Dolibarr ERP/CRM est un logiciel modulaire (on n'active que les fonctions que l'on désire) de gestions de TPE/PME, d'indépendants, d'entrepreneurs ou d'associations. En terme plus techniques, c'est un ERP et CRM. C'est un projet OpenSource qui s'exécute au sein d'un serveur Web et peut donc être accessible depuis n'importe quel lieu disposant d'une connexion Internet (Projet basé sur un serveur WAMP, MAMP ou LAMP: Apache, MySQL, PHP). Dolibarr vient compléter les offres déjà nombreuses de logiciels de cette catégorie (comme OpenBravo, OpenERP, SugarCRM, Neogia, Compiere, etc.) mais se démarque par le fait qu'ici tout est fait pour offrir de la simplicité (règle des 3 S):
Simple pour le développement (pas de frameworks lourds).
@@ -88,6 +96,11 @@ Dolibarr intègre en effet sa propre architecture (design patterns) permettant
<Web_Info>
<Application_URLs>
<Application_Info_URL>http://www.dolibarr.org</Application_Info_URL>
<Application_Order_URL>http://www.dolibarr.org</Application_Order_URL>
<Application_Screenshot_URL>http://www.dolibarr.org/images/dolibarr_screenshot1.png</Application_Screenshot_URL>
<Application_Icon_URL>http://www.dolibarr.org/images/dolibarr.gif</Application_Icon_URL>
<Application_XML_File_URL>http://www.dolibarr.org/files/pad_dolibarr.xml</Application_XML_File_URL>
</Application_URLs>
<Download_URLs>
<Primary_Download_URL>http://www.dolibarr.org/files/dolibarr.tgz</Primary_Download_URL>
<Secondary_Download_URL>http://www.dolibarr.org/files/dolibarr.tgz</Secondary_Download_URL>
@@ -194,9 +207,4 @@ Dolibarr intègre en effet sa propre architecture (design patterns) permettant
<Affiliates_Shareasale_Product_ID />
<Affiliates_Shareasale_Maximum_Commission_Rate />
<Affiliates_SWReg_Order_Page />
<Affiliates_VFree_Vendor_ID />
<Affiliates_VFree_Product_ID />
<Affiliates_VFree_Maximum_Commission_Rate />
<Affiliates_Yaskifo_Order_Page />
<Affiliates_Yaskifo_Vendor_ID />
<Affiliates_SWReg_Vendor_ID />

View File

@@ -6,26 +6,26 @@
<MASTER_PAD_INFO>Portable Application Description, or PAD for short, is a data set that is used by shareware authors to disseminate information to anyone interested in their software products. To find out more go to http://pad.asp-software.org</MASTER_PAD_INFO>
</MASTER_PAD_VERSION_INFO>
<Company_Info>
<Company_Name>Dolibarr team</Company_Name>
<Address_1>11 rue raymond Queneau</Address_1>
<Company_Name>NLTechno</Company_Name>
<Address_1>11 Rue raymond Queneau</Address_1>
<Address_2 />
<City_Town>Rueil Malmaison</City_Town>
<State_Province />
<Zip_Postal_Code>92500</Zip_Postal_Code>
<Country>FRANCE</Country>
<Company_WebSite_URL>http://www.dolibarr.org</Company_WebSite_URL>
<Company_WebSite_URL>http://www.nltechno.com</Company_WebSite_URL>
<Contact_Info>
<Author_First_Name>Dolibarr team</Author_First_Name>
<Author_Last_Name>Dolibarr team</Author_Last_Name>
<Author_Email>dolibarr-dev@nongnu.org</Author_Email>
<Contact_First_Name>Dolibarr team</Contact_First_Name>
<Contact_Last_Name>Dolibarr team</Contact_Last_Name>
<Contact_Email>dolibarr-dev@nongnu.org</Contact_Email>
<Author_First_Name>NLTechno</Author_First_Name>
<Author_Last_Name>NLTechno</Author_Last_Name>
<Author_Email>dolibarr@nltechno.com</Author_Email>
<Contact_First_Name>NLTechno</Contact_First_Name>
<Contact_Last_Name>NLTechno</Contact_Last_Name>
<Contact_Email>dolibarr@nltechno.com</Contact_Email>
</Contact_Info>
<Support_Info>
<Sales_Email>dolibarr-dev@nongnu.org</Sales_Email>
<Support_Email>dolibarr-dev@nongnu.org</Support_Email>
<General_Email>dolibarr-dev@nongnu.org</General_Email>
<Sales_Email>dolibarr@nltechno.com</Sales_Email>
<Support_Email>dolibarr@nltechno.com</Support_Email>
<General_Email>dolibarr@nltechno.com</General_Email>
<Sales_Phone />
<Support_Phone />
<General_Phone />
@@ -34,10 +34,10 @@
</Company_Info>
<Program_Info>
<Program_Name>Dolibarr</Program_Name>
<Program_Version>3.1.0</Program_Version>
<Program_Release_Month>07</Program_Release_Month>
<Program_Release_Day>09</Program_Release_Day>
<Program_Release_Year>2011</Program_Release_Year>
<Program_Version>3.2.0</Program_Version>
<Program_Release_Month>06</Program_Release_Month>
<Program_Release_Day>18</Program_Release_Day>
<Program_Release_Year>2012</Program_Release_Year>
<Program_Cost_Dollars />
<Program_Cost_Other_Code />
<Program_Cost_Other />
@@ -46,14 +46,14 @@
<Program_Install_Support>No Install Support</Program_Install_Support>
<Program_OS_Support>Linux,Mac OS X,Mac Other,Unix,Win2000,Win7 x32,Win7 x64,Win98,WinOther,WinServer,WinVista,WinVista x64,WinXP,Other</Program_OS_Support>
<Program_Language>English,Arabic,Catalan,Chinese,Danish,Dutch,Finnish,French,German,Greek,Icelandic,Italian,Norwegian,Polish,Portuguese,Romanian,Russian,Slovenian,Spanish,Swedish,Turkish</Program_Language>
<Program_Change_Info>Increase performances, Setup process is easier, Reduce number of clicks required to use software</Program_Change_Info>
<Program_Change_Info>http://www.dolibarr.org</Program_Change_Info>
<Program_Specific_Category>Business</Program_Specific_Category>
<Program_Category_Class>Business::Accounting &amp; Finance</Program_Category_Class>
<Program_System_Requirements>None</Program_System_Requirements>
<File_Info>
<File_Size_Bytes>18037439</File_Size_Bytes>
<File_Size_K>18037</File_Size_K>
<File_Size_MB>18.03</File_Size_MB>
<File_Size_Bytes>9359175</File_Size_Bytes>
<File_Size_K>9139</File_Size_K>
<File_Size_MB>8.93</File_Size_MB>
</File_Info>
<Expire_Info>
<Has_Expire_Info>N</Has_Expire_Info>
@@ -73,9 +73,13 @@
<Char_Desc_250>Dolibarr ERP &amp; CRM, the easy to use open source software to manage your activity (invoices, customers, suppliers, contracts, agenda, emailings...) and any other things a small or mid-sized business or a foundation needs to follow.</Char_Desc_250>
<Char_Desc_450>Dolibarr ERP &amp; CRM is a software built by modules addition (you enable only features you need), to manage small or medium companies, freelancers or foundations. We can say Dolibarr is an ERP or CRM. Dolibarr is also available with an auto-installer for Windows users with no technical knowledge to install Dolibarr and all its prerequisites (Apache, Mysql, PHP) with just one auto-exe file. See DoliWamp software for this.</Char_Desc_450>
<Char_Desc_2000>Dolibarr ERP &amp; CRM is a software built by modules addition (you enable only features you need), to manage small or mid-sized businesses, freelancers or foundations. We can say Dolibarr is an ERP or CRM (or both depending on activated modules). It's an OpenSource project base on a WAMP, MAMP or LAMP server (Apache, Mysql, PHP for all Operating Systems). Dolibarr differs from other ERP or CRM softwares (like OpenAguila, OpenBravo, OpenERP, Neogia, Compiere, etc) because everything was made to be more simple:
Simple to install
Simple to use
@@ -85,9 +89,13 @@ Note that Dolibarr is also available with an auto-installer for Windows or Ubunt
Note that Dolibarr is also available with an auto-installer for Windows or Ubuntu users with no technical knowledge to install Dolibarr and all its prerequisites (Apache, Mysql, PHP) with just one auto-exe file. This version is called DoliWamp (for Windows) or DoliBuntu (for Ubuntu/Debian).</Char_Desc_2000>
</English>
<French>
<Keywords>dolibarr, erp, crm, invoices, commercial proposals, orders, accounting, stock, products, agenda, bank, business, company, foundation, management, sme, doliwamp</Keywords>
<Char_Desc_45>Dolibarr ERP &amp; CRM</Char_Desc_45>
<Char_Desc_80>Dolibarr ERP &amp; CRM, le gestionnaire simple pour gérer votre activité</Char_Desc_80>
<Char_Desc_250>Dolibarr ERP &amp; CRM, le logiciel simple et OpenSource pour gérer votre activité (factures, devis, facturation, commandes, compta, trésorerie, stocks, produits, agenda, comptes bancaires, associations)</Char_Desc_250>
<Char_Desc_450>Dolibarr ERP/CRM est un logiciel modulaire (on n'active que les fonctions que l'on désire) de gestions de TPE/PME, d'indépendants, d'entrepreneurs ou d'associations. En terme plus techniques, c'est un ERP et CRM. C'est un projet OpenSource qui s'exécute au sein d'un serveur Web et peut donc être accessible depuis n'importe quel lieu disposant d'une connexion Internet (Projet basé sur un serveur WAMP, MAMP ou LAMP: Apache, MySQL, PHP).</Char_Desc_450>
<Char_Desc_2000>Dolibarr ERP/CRM est un logiciel modulaire (on n'active que les fonctions que l'on désire) de gestions de TPE/PME, d'indépendants, d'entrepreneurs ou d'associations. En terme plus techniques, c'est un ERP et CRM. C'est un projet OpenSource qui s'exécute au sein d'un serveur Web et peut donc être accessible depuis n'importe quel lieu disposant d'une connexion Internet (Projet basé sur un serveur WAMP, MAMP ou LAMP: Apache, MySQL, PHP). Dolibarr vient compléter les offres déjà nombreuses de logiciels de cette catégorie (comme OpenBravo, OpenERP, SugarCRM, Neogia, Compiere, etc.) mais se démarque par le fait qu'ici tout est fait pour offrir de la simplicité (règle des 3 S):
@@ -118,6 +126,11 @@ Dolibarr intègre en effet sa propre architecture (design patterns) permettant
<Web_Info>
<Application_URLs>
<Application_Info_URL>http://www.dolibarr.org</Application_Info_URL>
<Application_Order_URL>http://www.dolibarr.org</Application_Order_URL>
<Application_Screenshot_URL>http://www.dolibarr.org/images/dolibarr_screenshot1.png</Application_Screenshot_URL>
<Application_Icon_URL>http://www.dolibarr.org/images/dolibarr.gif</Application_Icon_URL>
<Application_XML_File_URL>http://www.dolibarr.org/files/pad_dolibarr.xml</Application_XML_File_URL>
</Application_URLs>
<Download_URLs>
<Primary_Download_URL>http://www.dolibarr.org/files/dolibarr.tgz</Primary_Download_URL>
<Secondary_Download_URL>http://www.dolibarr.org/files/dolibarr.tgz</Secondary_Download_URL>
@@ -224,9 +237,4 @@ Dolibarr intègre en effet sa propre architecture (design patterns) permettant
<Affiliates_Shareasale_Product_ID />
<Affiliates_Shareasale_Maximum_Commission_Rate />
<Affiliates_SWReg_Order_Page />
<Affiliates_VFree_Vendor_ID />
<Affiliates_VFree_Product_ID />
<Affiliates_VFree_Maximum_Commission_Rate />
<Affiliates_Yaskifo_Order_Page />
<Affiliates_Yaskifo_Vendor_ID />
<Affiliates_SWReg_Vendor_ID />

View File

@@ -34,10 +34,10 @@
</Company_Info>
<Program_Info>
<Program_Name>DoliWamp</Program_Name>
<Program_Version>3.1.0</Program_Version>
<Program_Release_Month>07</Program_Release_Month>
<Program_Release_Day>09</Program_Release_Day>
<Program_Release_Year>2011</Program_Release_Year>
<Program_Version>3.2.0</Program_Version>
<Program_Release_Month>06</Program_Release_Month>
<Program_Release_Day>18</Program_Release_Day>
<Program_Release_Year>2012</Program_Release_Year>
<Program_Cost_Dollars />
<Program_Cost_Other_Code />
<Program_Cost_Other />
@@ -94,8 +94,8 @@ DoliWamp is the auto-installer for Windows users with no technical knowledge to
</Italian>
</Program_Descriptions>
<Web_Info>
<Application_URLs>
<Application_Info_URL>http://www.nltechno.com/pages/dolibarrwinbin.php</Application_Info_URL>
<Application_URLs>
<Application_Info_URL>http://www.nltechno.com/doliwamp/</Application_Info_URL>
<Application_Order_URL>http://www.nltechno.com/doliwamp/</Application_Order_URL>
<Application_Screenshot_URL>http://www.dolibarr.org/images/dolibarr_screenshot1.png</Application_Screenshot_URL>
<Application_Icon_URL>http://www.dolibarr.org/images/dolibarr.gif</Application_Icon_URL>

View File

@@ -30,7 +30,7 @@ return "Regis Houssin";
# script_dolibarr_versions()
sub script_dolibarr_versions
{
return ( "3.3.0", "3.2.0", "3.1.0", "3.0.1", "2.9.0" );
return ( "3.2.0", "3.1.1", "3.0.1", "2.9.0" );
}
sub script_dolibarr_category
@@ -43,13 +43,6 @@ sub script_dolibarr_php_vers
return ( 5 );
}
sub script_dolibarr_php_vars
{
return ( [ 'memory_limit', '64M', '+' ],
[ 'upload_max_filesize', '10M', '+' ],
[ 'max_execution_time', '60', '+' ] );
}
sub script_dolibarr_php_modules
{
local ($d, $ver, $phpver, $opts) = @_;
@@ -348,21 +341,32 @@ if ($opts->{'newdb'}) {
return (1, "Dolibarr directory and tables deleted.");
}
# script_dolibarr_latest(version)
# Returns a URL and regular expression or callback func to get the version
sub script_dolibarr_latest
# script_dolibarr_realversion(&domain, &opts)
# Returns the real version number of some script install, or undef if unknown
sub script_dolibarr_realversion
{
local ($d, $opts, $sinfo) = @_;
local $lref = &read_file_lines("$opts->{'dir'}/filefunc.inc.php", 1);
foreach my $l (@$lref) {
if ($l =~ /'DOL_VERSION','([0-9a-z\.\-]+)'/) {
return $1;
}
}
return undef;
}
# script_dolibarr_check_latest(version)
# Checks if some version is the latest for this project, and if not returns
# a newer one. Otherwise returns undef.
sub script_dolibarr_check_latest
{
local ($ver) = @_;
if ($ver >= 3.0) {
return ( "http://sourceforge.net/projects/dolibarr/files/".
"Dolibarr%20ERP-CRM",
"(3\\.[0-9\\.]+)" );
}
elsif ($ver >= 2.9) {
return ( "http://www.dolibarr.fr/files/stable/",
"dolibarr\\-(2\\.[0-9\\.]+)" );
}
return ( );
local @vers = &osdn_package_versions("dolibarr",
$ver >= 3 ? "dolibarr\\-(3\\.[0-9\\.]+)\\.tgz" :
$ver >= 2.9 ? "dolibarr\\-(2\\.9\\.[0-9\\.]+)\\.tgz" :
"dolibarr\\-(2\\.8\\.[0-9\\.]+)\\.tgz");
return "Failed to find versions" if (!@vers);
return $ver eq $vers[0] ? undef : $vers[0];
}
sub script_dolibarr_site
@@ -376,4 +380,3 @@ return 2;
}
1;

View File

@@ -217,6 +217,26 @@ echo Create document directory $docdir
# Set correct owner on config files
%{__chown} -R root:$apachegroup /etc/dolibarr/*
# If a conf already exists and its content was already completed by installer
export config=%{_sysconfdir}/dolibarr/conf.php
if [ -s $config ] && grep -q "File generated by" $config
then
# File already exist. We add params not found.
echo Add new params to overwrite path to use shared libraries/fonts
grep -q -c "dolibarr_lib_ADODB_PATH" $config || [ ! -d "/usr/share/php/adodb" ] || echo "<?php \$dolibarr_lib_ADODB_PATH='/usr/share/php/adodb'; ?>" >> $config
grep -q -c "dolibarr_lib_FPDI_PATH" $config || [ ! -d "/usr/share/php/fpdi" ] || echo "<?php \$dolibarr_lib_FPDI_PATH='/usr/share/php/fpdi'; ?>" >> $config
#grep -q -c "dolibarr_lib_GEOIP_PATH" $config || echo "<?php \$dolibarr_lib_GEOIP_PATH=''; ?>" >> $config
grep -q -c "dolibarr_lib_NUSOAP_PATH" $config || [ ! -d "/usr/share/php/nusoap" ] || echo "<?php \$dolibarr_lib_NUSOAP_PATH='/usr/share/php/nusoap'; ?>" >> $config
grep -q -c "dolibarr_lib_ODTPHP_PATHTOPCLZIP" $config || [ ! -d "/usr/share/php/libphp-pclzip" ] || echo "<?php \$dolibarr_lib_ODTPHP_PATHTOPCLZIP='/usr/share/php/libphp-pclzip'; ?>" >> $config
#grep -q -c "dolibarr_lib_PHPEXCEL_PATH" $config || echo "<?php \$dolibarr_lib_PHPEXCEL_PATH=''; ?>" >> $config
#grep -q -c "dolibarr_lib_TCPDF_PATH" $config || echo "<?php \$dolibarr_lib_TCPDF_PATH=''; ?>" >> $config
grep -q -c "dolibarr_js_CKEDITOR" $config || [ ! -d "/usr/share/javascript/ckeditor" ] || echo "<?php \$dolibarr_js_CKEDITOR='/javascript/ckeditor'; ?>" >> $config
grep -q -c "dolibarr_js_JQUERY" $config || [ ! -d "/usr/share/javascript/jquery" ] || echo "<?php \$dolibarr_js_JQUERY='/javascript/jquery'; ?>" >> $config
grep -q -c "dolibarr_js_JQUERY_UI" $config || [ ! -d "/usr/share/javascript/jquery-ui" ] || echo "<?php \$dolibarr_js_JQUERY_UI='/javascript/jquery-ui'; ?>" >> $config
grep -q -c "dolibarr_js_JQUERY_FLOT" $config || [ ! -d "/usr/share/javascript/flot" ] || echo "<?php \$dolibarr_js_JQUERY_FLOT='/javascript/flot'; ?>" >> $config
grep -q -c "dolibarr_font_DOL_DEFAULT_TTF_BOLD" $config || echo "<?php \$dolibarr_font_DOL_DEFAULT_TTF_BOLD='/usr/share/fonts/dejavu/DejaVuSans-Bold.ttf'; ?>" >> $config
fi
# Create config for se $seconfig
echo Add SE Linux permissions for dolibarr
# semanage add records into /etc/selinux/targeted/contexts/files/file_contexts.local
@@ -292,5 +312,5 @@ fi
%changelog
* Wed Mar 4 2012 Laurent Destailleur 3.3.0-0.1.a
* Mon Jun 18 2012 Laurent Destailleur 3.2.0-0.3
- Initial version (#723326)

View File

@@ -254,6 +254,26 @@ fi
# Set correct owner on config files
%{__chown} -R root:$apachegroup /etc/dolibarr/*
# If a conf already exists and its content was already completed by installer
export config=%{_sysconfdir}/dolibarr/conf.php
if [ -s $config ] && grep -q "File generated by" $config
then
# File already exist. We add params not found.
echo Add new params to overwrite path to use shared libraries/fonts
grep -q -c "dolibarr_lib_ADODB_PATH" $config || [ ! -d "/usr/share/php/adodb" ] || echo "<?php \$dolibarr_lib_ADODB_PATH='/usr/share/php/adodb'; ?>" >> $config
grep -q -c "dolibarr_lib_FPDI_PATH" $config || [ ! -d "/usr/share/php/fpdi" ] || echo "<?php \$dolibarr_lib_FPDI_PATH='/usr/share/php/fpdi'; ?>" >> $config
#grep -q -c "dolibarr_lib_GEOIP_PATH" $config || echo "<?php \$dolibarr_lib_GEOIP_PATH=''; ?>" >> $config
grep -q -c "dolibarr_lib_NUSOAP_PATH" $config || [ ! -d "/usr/share/php/nusoap" ] || echo "<?php \$dolibarr_lib_NUSOAP_PATH='/usr/share/php/nusoap'; ?>" >> $config
grep -q -c "dolibarr_lib_ODTPHP_PATHTOPCLZIP" $config || [ ! -d "/usr/share/php/libphp-pclzip" ] || echo "<?php \$dolibarr_lib_ODTPHP_PATHTOPCLZIP='/usr/share/php/libphp-pclzip'; ?>" >> $config
#grep -q -c "dolibarr_lib_PHPEXCEL_PATH" $config || echo "<?php \$dolibarr_lib_PHPEXCEL_PATH=''; ?>" >> $config
#grep -q -c "dolibarr_lib_TCPDF_PATH" $config || echo "<?php \$dolibarr_lib_TCPDF_PATH=''; ?>" >> $config
grep -q -c "dolibarr_js_CKEDITOR" $config || [ ! -d "/usr/share/javascript/ckeditor" ] || echo "<?php \$dolibarr_js_CKEDITOR='/javascript/ckeditor'; ?>" >> $config
grep -q -c "dolibarr_js_JQUERY" $config || [ ! -d "/usr/share/javascript/jquery" ] || echo "<?php \$dolibarr_js_JQUERY='/javascript/jquery'; ?>" >> $config
grep -q -c "dolibarr_js_JQUERY_UI" $config || [ ! -d "/usr/share/javascript/jquery-ui" ] || echo "<?php \$dolibarr_js_JQUERY_UI='/javascript/jquery-ui'; ?>" >> $config
grep -q -c "dolibarr_js_JQUERY_FLOT" $config || [ ! -d "/usr/share/javascript/flot" ] || echo "<?php \$dolibarr_js_JQUERY_FLOT='/javascript/flot'; ?>" >> $config
grep -q -c "dolibarr_font_DOL_DEFAULT_TTF_BOLD" $config || echo "<?php \$dolibarr_font_DOL_DEFAULT_TTF_BOLD='/usr/share/fonts/truetype/ttf-dejavu/DejaVuSans-Bold.ttf'; ?>" >> $config
fi
# Create config for se $seconfig
if [ "x$os" = "xfedora-redhat" -a -s /sbin/restorecon ]; then
echo Add SE Linux permissions for dolibarr
@@ -348,5 +368,5 @@ fi
%changelog
* Wed Mar 4 2012 Laurent Destailleur 3.3.0-0.1.a
* Mon Jun 18 2012 Laurent Destailleur 3.2.0-0.3
- Initial version (#723326)

View File

@@ -214,6 +214,26 @@ echo Create document directory $docdir
# Set correct owner on config files
%{__chown} -R root:$apachegroup /etc/dolibarr/*
# If a conf already exists and its content was already completed by installer
export confcomplete=`grep -c "File generated by" %{_sysconfdir}/dolibarr/conf.php 2>/dev/null`
if [ -s %{_sysconfdir}/dolibarr/conf.php -a "x$confcomplete" != "x0" ]
then
# File already exist. We add params not found.
echo Add new params to overwrite path to use shared libraries/fonts
grep -q -c "dolibarr_lib_ADODB_PATH" $config || [ ! -d "/usr/share/php/adodb" ] || echo "<?php \$dolibarr_lib_ADODB_PATH='/usr/share/php/adodb'; ?>" >> $config
grep -q -c "dolibarr_lib_FPDI_PATH" $config || [ ! -d "/usr/share/php/fpdi" ] || echo "<?php \$dolibarr_lib_FPDI_PATH='/usr/share/php/fpdi'; ?>" >> $config
#grep -q -c "dolibarr_lib_GEOIP_PATH" $config || echo "<?php \$dolibarr_lib_GEOIP_PATH=''; ?>" >> $config
grep -q -c "dolibarr_lib_NUSOAP_PATH" $config || [ ! -d "/usr/share/php/nusoap" ] || echo "<?php \$dolibarr_lib_NUSOAP_PATH='/usr/share/php/nusoap'; ?>" >> $config
grep -q -c "dolibarr_lib_ODTPHP_PATHTOPCLZIP" $config || [ ! -d "/usr/share/php/libphp-pclzip" ] || echo "<?php \$dolibarr_lib_ODTPHP_PATHTOPCLZIP='/usr/share/php/libphp-pclzip'; ?>" >> $config
#grep -q -c "dolibarr_lib_PHPEXCEL_PATH" $config || echo "<?php \$dolibarr_lib_PHPEXCEL_PATH=''; ?>" >> $config
#grep -q -c "dolibarr_lib_TCPDF_PATH" $config || echo "<?php \$dolibarr_lib_TCPDF_PATH=''; ?>" >> $config
grep -q -c "dolibarr_js_CKEDITOR" $config || [ ! -d "/usr/share/javascript/ckeditor" ] || echo "<?php \$dolibarr_js_CKEDITOR='/javascript/ckeditor'; ?>" >> $config
grep -q -c "dolibarr_js_JQUERY" $config || [ ! -d "/usr/share/javascript/jquery" ] || echo "<?php \$dolibarr_js_JQUERY='/javascript/jquery'; ?>" >> $config
grep -q -c "dolibarr_js_JQUERY_UI" $config || [ ! -d "/usr/share/javascript/jquery-ui" ] || echo "<?php \$dolibarr_js_JQUERY_UI='/javascript/jquery-ui'; ?>" >> $config
grep -q -c "dolibarr_js_JQUERY_FLOT" $config || [ ! -d "/usr/share/javascript/flot" ] || echo "<?php \$dolibarr_js_JQUERY_FLOT='/javascript/flot'; ?>" >> $config
grep -q -c "dolibarr_font_DOL_DEFAULT_TTF_BOLD" $config || echo "<?php \$dolibarr_font_DOL_DEFAULT_TTF_BOLD='/usr/share/fonts/TTF/dejavu/DejaVuSans-Bold.ttf'; ?>" >> $config
fi
# Create a config link dolibarr.conf
if [ ! -L $apachelink ]; then
echo Create dolibarr web server config link $apachelink
@@ -281,5 +301,5 @@ fi
%changelog
* Wed Mar 4 2012 Laurent Destailleur 3.3.0-0.1.a
* Mon Jun 18 2012 Laurent Destailleur 3.2.0-0.3
- Initial version (#723326)

View File

@@ -219,6 +219,26 @@ echo Create document directory $docdir
# Set correct owner on config files
%{__chown} -R root:$apachegroup /etc/dolibarr/*
# If a conf already exists and its content was already completed by installer
export config=%{_sysconfdir}/dolibarr/conf.php
if [ -s $config ] && grep -q "File generated by" $config
then
# File already exist. We add params not found.
echo Add new params to overwrite path to use shared libraries/fonts
grep -q -c "dolibarr_lib_ADODB_PATH" $config || [ ! -d "/usr/share/php/adodb" ] || echo "<?php \$dolibarr_lib_ADODB_PATH='/usr/share/php/adodb'; ?>" >> $config
grep -q -c "dolibarr_lib_FPDI_PATH" $config || [ ! -d "/usr/share/php/fpdi" ] || echo "<?php \$dolibarr_lib_FPDI_PATH='/usr/share/php/fpdi'; ?>" >> $config
#grep -q -c "dolibarr_lib_GEOIP_PATH" $config || echo "<?php \$dolibarr_lib_GEOIP_PATH=''; ?>" >> $config
grep -q -c "dolibarr_lib_NUSOAP_PATH" $config || [ ! -d "/usr/share/php/nusoap" ] || echo "<?php \$dolibarr_lib_NUSOAP_PATH='/usr/share/php/nusoap'; ?>" >> $config
grep -q -c "dolibarr_lib_ODTPHP_PATHTOPCLZIP" $config || [ ! -d "/usr/share/php/libphp-pclzip" ] || echo "<?php \$dolibarr_lib_ODTPHP_PATHTOPCLZIP='/usr/share/php/libphp-pclzip'; ?>" >> $config
#grep -q -c "dolibarr_lib_PHPEXCEL_PATH" $config || echo "<?php \$dolibarr_lib_PHPEXCEL_PATH=''; ?>" >> $config
#grep -q -c "dolibarr_lib_TCPDF_PATH" $config || echo "<?php \$dolibarr_lib_TCPDF_PATH=''; ?>" >> $config
grep -q -c "dolibarr_js_CKEDITOR" $config || [ ! -d "/usr/share/javascript/ckeditor" ] || echo "<?php \$dolibarr_js_CKEDITOR='/javascript/ckeditor'; ?>" >> $config
grep -q -c "dolibarr_js_JQUERY" $config || [ ! -d "/usr/share/javascript/jquery" ] || echo "<?php \$dolibarr_js_JQUERY='/javascript/jquery'; ?>" >> $config
grep -q -c "dolibarr_js_JQUERY_UI" $config || [ ! -d "/usr/share/javascript/jquery-ui" ] || echo "<?php \$dolibarr_js_JQUERY_UI='/javascript/jquery-ui'; ?>" >> $config
grep -q -c "dolibarr_js_JQUERY_FLOT" $config || [ ! -d "/usr/share/javascript/flot" ] || echo "<?php \$dolibarr_js_JQUERY_FLOT='/javascript/flot'; ?>" >> $config
grep -q -c "dolibarr_font_DOL_DEFAULT_TTF_BOLD" $config || echo "<?php \$dolibarr_font_DOL_DEFAULT_TTF_BOLD='/usr/share/fonts/truetype/DejaVuSans-Bold.ttf'; ?>" >> $config
fi
# Create a config link dolibarr.conf
if [ ! -L $apachelink ]; then
echo Create dolibarr web server config link $apachelink
@@ -286,5 +306,5 @@ fi
%changelog
* Wed Mar 4 2012 Laurent Destailleur 3.3.0-0.1.a
* Mon Jun 18 2012 Laurent Destailleur 3.2.0-0.3
- Initial version (#723326)

View File

@@ -30,6 +30,6 @@ $force_dolibarr_lib_TCPDF_PATH='';
//$force_dolibarr_js_JQUERY='/javascript/jquery';
//$force_dolibarr_js_JQUERY_UI='/javascript/jquery-ui';
//$force_dolibarr_js_JQUERY_FLOT='/javascript/flot';
$force_dolibarr_font_DOL_DEFAULT_TTF_BOLD='/usr/share/fonts/truetype';
$force_dolibarr_font_DOL_DEFAULT_TTF_BOLD='/usr/share/fonts/truetype/DejaVuSans-Bold.ttf';
?>

View File

@@ -11,7 +11,7 @@
#------------------------------------------------------
export dumpfile="mysqldump_dolibarr_3.1.0.sql"
export dumpfile=`ls mysqldump_dolibarr_*.sql | sort | tail -n 1`
export mydir=`echo "$0" | sed -e 's/initdemo.sh//'`;
if [ "x$mydir" = "x" ]
then

File diff suppressed because one or more lines are too long

View File

@@ -50,7 +50,7 @@ $action = GETPOST('action','alpha');
if ($action == 'update' || $action == 'add')
{
$constname=GETPOST('constname','alpha');
$constvalue=(GETPOST('constvalue_'.$constname,'alpha') ? GETPOST('constvalue_'.$constname,'alpha') : GETPOST('constvalue','alpha'));
$constvalue=(GETPOST('constvalue_'.$constname) ? GETPOST('constvalue_'.$constname) : GETPOST('constvalue'));
if (($constname=='ADHERENT_CARD_TYPE' || $constname=='ADHERENT_ETIQUETTE_TYPE') && $constvalue == -1) $constvalue='';
if ($constname=='ADHERENT_LOGIN_NOT_REQUIRED') // Invert choice
@@ -60,7 +60,7 @@ if ($action == 'update' || $action == 'add')
}
$consttype=GETPOST('consttype','alpha');
$constnote=GETPOST('constnote','alpha');
$constnote=GETPOST('constnote');
$res=dolibarr_set_const($db,$constname,$constvalue,$type[$consttype],0,$constnote,$conf->entity);
if (! $res > 0) $error++;
@@ -78,7 +78,7 @@ if ($action == 'update' || $action == 'add')
// Action activation d'un sous module du module adherent
if ($action == 'set')
{
$result=dolibarr_set_const($db, GETPOST('name','alpha'),GETPOST('value','alpha'),'',0,'',$conf->entity);
$result=dolibarr_set_const($db, GETPOST('name','alpha'),GETPOST('value'),'',0,'',$conf->entity);
if ($result < 0)
{
print $db->error();

View File

@@ -40,7 +40,7 @@ $mesg=isset($_GET["mesg"])?'<div class="ok">'.$_GET["mesg"].'</div>':'';
$id = GETPOST('id','int');
// Security check
if (! $user->rights->adherent->lire) accessforbidden();
$result=restrictedArea($user,'adherent',$id);
$object = new Adherent($db);
$result=$object->fetch($id);

View File

@@ -39,8 +39,12 @@ $langs->load("users");
$langs->load("mails");
$action=GETPOST('action','alpha');
$rowid=GETPOST('rowid','int');
$typeid=GETPOST('typeid','int');
// Security check
if (! $user->rights->adherent->cotisation->lire) accessforbidden();
$result=restrictedArea($user,'adherent',$rowid);
$object = new Adherent($db);
$extrafields = new ExtraFields($db);
@@ -50,10 +54,6 @@ $errmsg='';
$defaultdelay=1;
$defaultdelayunit='y';
$action=GETPOST('action');
$rowid=GETPOST('rowid');
$typeid=GETPOST('typeid');
if ($rowid)
{
// Load member

View File

@@ -153,7 +153,7 @@ if ((! empty($foruserid) || ! empty($foruserlogin) || ! empty($mode)) && ! $mesg
}
// Build and output PDF
if (empty($mode) || $mode=='card' || $mode='cardlogin')
if (empty($mode) || $mode=='card' || $mode=='cardlogin')
{
if (! count($arrayofmembers))
{

View File

@@ -184,7 +184,7 @@ class Adherent extends CommonObject
*/
function makeSubstitution($text)
{
global $langs;
global $conf,$langs;
$birthday = dol_print_date($this->naiss,'day');
@@ -202,8 +202,11 @@ class Adherent extends CommonObject
$infos.= $langs->transnoentities("Town").": ".$this->town."\n";
$infos.= $langs->transnoentities("Country").": ".$this->country."\n";
$infos.= $langs->transnoentities("EMail").": ".$this->email."\n";
if (empty($conf->global->ADHERENT_LOGIN_NOT_REQUIRED))
{
$infos.= $langs->transnoentities("Login").": ".$this->login."\n";
$infos.= $langs->transnoentities("Password").": ".$this->pass."\n";
}
$infos.= $langs->transnoentities("Birthday").": ".$birthday."\n";
$infos.= $langs->transnoentities("Photo").": ".$this->photo."\n";
$infos.= $langs->transnoentities("Public").": ".yn($this->public);
@@ -696,6 +699,10 @@ class Adherent extends CommonObject
$resql=$this->db->query($sql);
if ($resql)
{
$sql = "DELETE FROM ".MAIN_DB_PREFIX."categorie_member WHERE fk_member = ".$rowid;
dol_syslog(get_class($this)."::delete sql=".$sql);
$resql=$this->db->query($sql);
$sql = "DELETE FROM ".MAIN_DB_PREFIX."cotisation WHERE fk_adherent = ".$rowid;
dol_syslog(get_class($this)."::delete sql=".$sql);
$resql=$this->db->query($sql);
@@ -968,7 +975,7 @@ class Adherent extends CommonObject
*/
function fetch($rowid,$ref='',$fk_soc='')
{
global $conf, $langs;
global $langs;
$sql = "SELECT d.rowid, d.civilite, d.prenom as firstname, d.nom as lastname, d.societe, d.fk_soc, d.statut, d.public, d.adresse as address, d.cp as zip, d.ville as town, d.note,";
$sql.= " d.email, d.phone, d.phone_perso, d.phone_mobile, d.login, d.pass,";
@@ -989,10 +996,12 @@ class Adherent extends CommonObject
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."c_departements as dep ON d.fk_departement = dep.rowid";
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."user as u ON d.rowid = u.fk_member";
$sql.= " WHERE d.fk_adherent_type = t.rowid";
$sql.= " AND d.entity = ".$conf->entity;
if ($rowid) $sql.= " AND d.rowid=".$rowid;
elseif ($ref || $fk_soc) {
$sql.= " AND d.entity IN (".getEntity().")";
if ($ref) $sql.= " AND d.rowid='".$ref."'";
elseif ($fk_soc) $sql.= " AND d.fk_soc='".$fk_soc."'";
else $sql.= " AND d.rowid=".$rowid;
}
dol_syslog(get_class($this)."::fetch sql=".$sql);
$resql=$this->db->query($sql);

View File

@@ -1,7 +1,7 @@
<?php
/* Copyright (C) 2002-2007 Rodolphe Quiedeville <rodolphe@quiedeville.org>
* Copyright (C) 2004-2010 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2005-2007 Regis Houssin <regis@dolibarr.fr>
* Copyright (C) 2005-2012 Regis Houssin <regis@dolibarr.fr>
* Copyright (C) 2010 Juanjo Menent <jmenent@2byte.es>
*
* This program is free software; you can redistribute it and/or modify
@@ -27,22 +27,26 @@
require("../main.inc.php");
require_once(DOL_DOCUMENT_ROOT."/core/lib/member.lib.php");
require_once(DOL_DOCUMENT_ROOT."/core/lib/files.lib.php");
require_once(DOL_DOCUMENT_ROOT."/core/lib/images.lib.php");
require_once(DOL_DOCUMENT_ROOT."/core/class/html.formfile.class.php");
require_once(DOL_DOCUMENT_ROOT."/adherents/class/adherent.class.php");
require_once(DOL_DOCUMENT_ROOT."/adherents/class/adherent_type.class.php");
$langs->load("members");
$langs->load("companies");
$langs->load('other');
$id=GETPOST('id','int');
$action=GETPOST('action','alpha');
$confirm=GETPOST('confirm','alpha');
$mesg = "";
// Security check
$id = GETPOST('id','int');
if ($user->societe_id > 0)
{
$id = $user->societe_id;
}
//$result = restrictedArea($user, 'societe', $id);
$result=restrictedArea($user,'adherent',$id);
// Get parameters
$sortfield = GETPOST("sortfield",'alpha');
@@ -65,15 +69,24 @@ $upload_dir = $conf->adherent->dir_output . "/" . get_exdir($id,2,0,1) . '/' . $
*/
// Envoie fichier
if ( $_POST["sendit"] && ! empty($conf->global->MAIN_UPLOAD_DOC))
if ($_POST["sendit"] && ! empty($conf->global->MAIN_UPLOAD_DOC))
{
require_once(DOL_DOCUMENT_ROOT."/core/lib/files.lib.php");
if (dol_mkdir($upload_dir) >= 0)
{
$resupload=dol_move_uploaded_file($_FILES['userfile']['tmp_name'], $upload_dir . "/" . $_FILES['userfile']['name'],0,0,$_FILES['userfile']['error']);
$resupload=dol_move_uploaded_file($_FILES['userfile']['tmp_name'], $upload_dir . "/" . dol_unescapefile($_FILES['userfile']['name']),0,0,$_FILES['userfile']['error']);
if (is_numeric($resupload) && $resupload > 0)
{
if (image_format_supported($upload_dir . "/" . $_FILES['userfile']['name']) == 1)
{
// Create small thumbs for image (Ratio is near 16/9)
// Used on logon for example
$imgThumbSmall = vignette($upload_dir . "/" . $_FILES['userfile']['name'], $maxwidthsmall, $maxheightsmall, '_small', $quality, "thumbs");
// Create mini thumbs for image (Ratio is near 16/9)
// Used on menu or for setup page for example
$imgThumbMini = vignette($upload_dir . "/" . $_FILES['userfile']['name'], $maxwidthmini, $maxheightmini, '_mini', $quality, "thumbs");
}
$mesg = '<div class="ok">'.$langs->trans("FileTransferComplete").'</div>';
}
else
@@ -96,11 +109,12 @@ if ( $_POST["sendit"] && ! empty($conf->global->MAIN_UPLOAD_DOC))
}
// Suppression fichier
if ($_REQUEST['action'] == 'confirm_deletefile' && $_REQUEST['confirm'] == 'yes')
if ($action == 'confirm_deletefile' && $confirm == 'yes')
{
$file = $upload_dir . "/" . $_GET['urlfile']; // Do not use urldecode here ($_GET and $_REQUEST are already decoded by PHP).
$langs->load("other");
$file = $upload_dir . "/" . GETPOST('urlfile'); // Do not use urldecode here ($_GET and $_REQUEST are already decoded by PHP).
dol_delete_file($file);
$mesg = '<div class="ok">'.$langs->trans("FileWasRemoved").'</div>';
$mesg = '<div class="ok">'.$langs->trans("FileWasRemoved",GETPOST('urlfile')).'</div>';
}
@@ -197,21 +211,21 @@ if ($id > 0)
/*
* Confirmation suppression fichier
*/
if ($_GET['action'] == 'delete')
if ($action == 'delete')
{
$ret=$form->form_confirm($_SERVER["PHP_SELF"].'?id='.$_GET["id"].'&urlfile='.urldecode($_GET["urlfile"]), $langs->trans('DeleteFile'), $langs->trans('ConfirmDeleteFile'), 'confirm_deletefile', '', 0, 1);
$ret=$form->form_confirm($_SERVER["PHP_SELF"].'?id='.$member->id.'&urlfile='.urlencode(GETPOST("urlfile")), $langs->trans('DeleteFile'), $langs->trans('ConfirmDeleteFile'), 'confirm_deletefile', '', 0, 1);
if ($ret == 'html') print '<br>';
}
// Affiche formulaire upload
$formfile=new FormFile($db);
$formfile->form_attach_new_file(DOL_URL_ROOT.'/adherents/document.php?id='.$id,'',0,0,$user->rights->adherent->creer);
$formfile->form_attach_new_file(DOL_URL_ROOT.'/adherents/document.php?id='.$member->id,'',0,0,$user->rights->adherent->creer,50,$object);
// List of document
$param='&socid='.$societe->id;
$formfile->list_of_documents($filearray,$member,'member',$param, 0, get_exdir($id,2,0,1).'/'.$id.'/');
$formfile->list_of_documents($filearray,$member,'member',$param, 0, get_exdir($member->id,2,0,1).'/'.$member->id.'/');
print "<br><br>";
}
@@ -226,9 +240,7 @@ else
print $langs->trans("ErrorRecordNotFound");
}
$db->close();
llxFooter();
$db->close();
?>

View File

@@ -41,13 +41,6 @@ $langs->load("bills");
$langs->load("members");
$langs->load("users");
// Security check
if (! $user->rights->adherent->lire) accessforbidden();
$object = new Adherent($db);
$extrafields = new ExtraFields($db);
$errmsg=''; $errmsgs=array();
$action=GETPOST('action','alpha');
$confirm=GETPOST('confirm','alpha');
@@ -56,6 +49,14 @@ $typeid=GETPOST('typeid','int');
$userid=GETPOST('userid','int');
$socid=GETPOST('socid','int');
// Security check
$result=restrictedArea($user,'adherent',$rowid);
$object = new Adherent($db);
$extrafields = new ExtraFields($db);
$errmsg=''; $errmsgs=array();
if ($rowid > 0)
{
// Load member
@@ -67,16 +68,12 @@ if ($rowid > 0)
if ($object->user_id)
{
// $user est le user qui edite, $object->user_id est l'id de l'utilisateur lies au membre edite
$caneditfielduser=( (($user->id == $object->user_id) && $user->rights->user->self->creer)
|| (($user->id != $object->user_id) && $user->rights->user->user->creer) );
$caneditpassworduser=( (($user->id == $object->user_id) && $user->rights->user->self->password)
|| (($user->id != $adh->user_id) && $user->rights->user->user->password) );
$caneditfielduser=((($user->id == $object->user_id) && $user->rights->user->self->creer)
|| (($user->id != $object->user_id) && $user->rights->user->user->creer));
$caneditpassworduser=((($user->id == $object->user_id) && $user->rights->user->self->password)
|| (($user->id != $object->user_id) && $user->rights->user->user->password));
}
}
else
{
accessforbidden();
}
// Define variables to know what current user can do on members
$canaddmember=$user->rights->adherent->creer;
@@ -163,7 +160,7 @@ if ($action == 'confirm_create_user' && $confirm == 'yes' && $user->rights->user
{
// Creation user
$nuser = new User($db);
$result=$nuser->create_from_member($object,GETPOST('login','alpha'));
$result=$nuser->create_from_member($object,GETPOST('login'));
if ($result < 0)
{
@@ -184,7 +181,7 @@ if ($action == 'confirm_create_thirdparty' && $confirm == 'yes' && $user->rights
{
// Creation user
$company = new Societe($db);
$result=$company->create_from_member($object,GETPOST('companyname','alpha'));
$result=$company->create_from_member($object,GETPOST('companyname'));
if ($result < 0)
{
@@ -203,8 +200,13 @@ if ($action == 'confirm_sendinfo' && $confirm == 'yes')
{
if ($object->email)
{
$from=$conf->email_from;
if ($conf->global->ADHERENT_MAIL_FROM) $from=$conf->global->ADHERENT_MAIL_FROM;
$result=$object->send_an_email($langs->transnoentitiesnoconv("ThisIsContentOfYourCard")."\n\n%INFOS%\n\n",$langs->transnoentitiesnoconv("CardContent"));
$mesg=$langs->trans("CardSent");
$langs->load("mails");
$mesg=$langs->trans("MailSuccessfulySent", $from, $object->email);
}
}
@@ -822,8 +824,8 @@ if ($action == 'edit')
$res=$object->fetch($rowid);
if ($res < 0) { dol_print_error($db,$object->error); exit; }
//$res=$object->fetch_optionals($object->id,$extralabels);
//if ($res < 0) { dol_print_error($db); exit; }
$res=$object->fetch_optionals($object->id,$extralabels);
if ($res < 0) { dol_print_error($db); exit; }
$adht = new AdherentType($db);
$adht->fetch($object->typeid);
@@ -1049,13 +1051,14 @@ if ($action == 'edit')
if ($rowid && $action != 'edit')
{
dol_htmloutput_mesg($mesg);
/* ************************************************************************** */
/* */
/* Mode affichage */
/* */
/* ************************************************************************** */
//$object = new Adherent($db);
$res=$object->fetch($rowid);
if ($res < 0) { dol_print_error($db,$object->error); exit; }
$res=$object->fetch_optionals($object->id,$extralabels);
@@ -1509,7 +1512,7 @@ if ($rowid && $action != 'edit')
}
// Action SPIP
if ($conf->global->ADHERENT_USE_SPIP)
if ($conf->mailmanspip->enabled && $conf->global->ADHERENT_USE_SPIP)
{
$isinspip=$object->is_in_spip();
if ($isinspip == 1)

View File

@@ -2,6 +2,7 @@
/* Copyright (C) 2001-2002 Rodolphe Quiedeville <rodolphe@quiedeville.org>
* Copyright (C) 2003 Jean-Louis Bergamo <jlb@j1b.org>
* Copyright (C) 2004-2012 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2005-2012 Regis Houssin <regis@dolibarr.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
@@ -59,7 +60,10 @@ $AdherentType=array();
$sql = "SELECT t.rowid, t.libelle, t.cotisation,";
$sql.= " d.statut, count(d.rowid) as somme";
$sql.= " FROM ".MAIN_DB_PREFIX."adherent_type as t";
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."adherent as d ON t.rowid = d.fk_adherent_type";
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."adherent as d";
$sql.= " ON t.rowid = d.fk_adherent_type";
$sql.= " AND d.entity IN (".getEntity().")";
$sql.= " WHERE t.entity IN (".getEntity().")";
$sql.= " GROUP BY t.rowid, t.libelle, t.cotisation, d.statut";
dol_syslog("index.php::select nb of members by type sql=".$sql, LOG_DEBUG);
@@ -94,8 +98,9 @@ $now=dol_now();
// old rule: uptodate = if type does not need payment, that end date is null, if type need payment that end date is in future)
$sql = "SELECT count(*) as somme , d.fk_adherent_type";
$sql.= " FROM ".MAIN_DB_PREFIX."adherent as d, ".MAIN_DB_PREFIX."adherent_type as t";
//$sql.= " WHERE d.statut = 1 AND ((t.cotisation = 0 AND d.datefin IS NULL) OR d.datefin >= ".$db->idate($now).')';
$sql.= " WHERE d.statut = 1 AND d.datefin >= ".$db->idate($now);
$sql.= " WHERE d.entity IN (".getEntity().")";
//$sql.= " AND d.statut = 1 AND ((t.cotisation = 0 AND d.datefin IS NULL) OR d.datefin >= ".$db->idate($now).')';
$sql.= " AND d.statut = 1 AND d.datefin >= ".$db->idate($now);
$sql.= " AND t.rowid = d.fk_adherent_type";
$sql.= " GROUP BY d.fk_adherent_type";
@@ -212,7 +217,8 @@ $sql = "SELECT a.rowid, a.statut, a.nom as lastname, a.prenom as firstname,";
$sql.= " a.tms as datem, datefin as date_end_subscription,";
$sql.= " ta.rowid as typeid, ta.libelle, ta.cotisation";
$sql.= " FROM ".MAIN_DB_PREFIX."adherent as a, ".MAIN_DB_PREFIX."adherent_type as ta";
$sql.= " WHERE a.fk_adherent_type = ta.rowid";
$sql.= " WHERE a.entity IN (".getEntity().")";
$sql.= " AND a.fk_adherent_type = ta.rowid";
$sql.= $db->order("a.tms","DESC");
$sql.= $db->plimit($max, 0);
@@ -260,11 +266,12 @@ else
*/
$max=5;
$sql = "SELECT a.rowid, a.statut, a.nom, a.prenom,";
$sql = "SELECT a.rowid, a.statut, a.nom as lastname, a.prenom as firstname,";
$sql.= " datefin as date_end_subscription,";
$sql.= " c.rowid as cid, c.tms as datem, c.datec as datec, c.dateadh as date_start, c.datef as date_end, c.cotisation";
$sql.= " FROM ".MAIN_DB_PREFIX."adherent as a, ".MAIN_DB_PREFIX."cotisation as c";
$sql.= " WHERE c.fk_adherent = a.rowid";
$sql.= " WHERE a.entity IN (".getEntity().")";
$sql.= " AND c.fk_adherent = a.rowid";
$sql.= $db->order("c.tms","DESC");
$sql.= $db->plimit($max, 0);
@@ -350,7 +357,8 @@ $numb=0;
$sql = "SELECT c.cotisation, c.dateadh";
$sql.= " FROM ".MAIN_DB_PREFIX."adherent as d, ".MAIN_DB_PREFIX."cotisation as c";
$sql.= " WHERE d.rowid = c.fk_adherent";
$sql.= " WHERE d.entity IN (".getEntity().")";
$sql.= " AND d.rowid = c.fk_adherent";
if(isset($date_select) && $date_select != '')
{
$sql .= " AND dateadh LIKE '$date_select%'";
@@ -406,7 +414,6 @@ print '</td></tr>';
print '</table>';
$db->close();
llxFooter();
$db->close();
?>

View File

@@ -1,6 +1,6 @@
<?php
/* Copyright (C) 2005-2009 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2005-2006 Regis Houssin <regis@dolibarr.fr>
* Copyright (C) 2005-2012 Regis Houssin <regis@dolibarr.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
@@ -32,8 +32,10 @@ $langs->load("bills");
$langs->load("members");
$langs->load("users");
if (!$user->rights->adherent->lire)
accessforbidden();
$id=(GETPOST('id','int') ? GETPOST('id','int') : GETPOST('rowid','int'));
// Security check
$result=restrictedArea($user,'adherent',$id);
/*
@@ -43,9 +45,8 @@ if (!$user->rights->adherent->lire)
llxHeader('',$langs->trans("Member"),'EN:Module_Foundations|FR:Module_Adh&eacute;rents|ES:M&oacute;dulo_Miembros');
$adh = new Adherent($db);
$adh->id=$_GET["id"];
$adh->fetch($_GET["id"]);
$adh->info($_GET["id"]);
$adh->fetch($id);
$adh->info($id);
$head = member_prepare_head($adh);
@@ -59,7 +60,6 @@ print '</td></tr></table>';
print '</div>';
$db->close();
llxFooter();
$db->close();
?>

View File

@@ -52,7 +52,7 @@ $search_login=GETPOST("search_login");
$type=GETPOST("type");
$search_email=GETPOST("search_email");
$search_categ=GETPOST("search_categ");
$sall=GETPOST("sall",'int');
$sall=GETPOST("sall");
if (GETPOST("button_removefilter"))
{

View File

@@ -27,14 +27,15 @@ require_once(DOL_DOCUMENT_ROOT.'/core/lib/member.lib.php');
require_once(DOL_DOCUMENT_ROOT.'/adherents/class/adherent.class.php');
require_once(DOL_DOCUMENT_ROOT."/adherents/class/adherent_type.class.php");
$action=GETPOST('action');
$id=GETPOST('id','int');
$langs->load("companies");
$langs->load("members");
$langs->load("bills");
if (!$user->rights->adherent->lire) accessforbidden();
$action=GETPOST('action','alpha');
$id=GETPOST('id','int');
// Security check
$result=restrictedArea($user,'adherent',$id);
$object = new Adherent($db);
$result=$object->fetch($id);
@@ -49,7 +50,7 @@ if ($result > 0)
* Actions
*/
if ($_POST["action"] == 'update' && $user->rights->adherent->creer && ! $_POST["cancel"])
if ($action == 'update' && $user->rights->adherent->creer && ! $_POST["cancel"])
{
$db->begin();
@@ -174,7 +175,7 @@ if ($id)
}
$db->close();
llxFooter();
$db->close();
?>

View File

@@ -73,7 +73,8 @@ if ($mode)
$data = array();
$sql.="SELECT COUNT(d.rowid) as nb, MAX(d.datevalid) as lastdate, c.code, c.libelle as label";
$sql.=" FROM ".MAIN_DB_PREFIX."adherent as d LEFT JOIN ".MAIN_DB_PREFIX."c_pays as c on d.pays = c.rowid";
$sql.=" WHERE d.statut = 1";
$sql.=" WHERE d.entity IN (".getEntity().")";
$sql.=" AND d.statut = 1";
$sql.=" GROUP BY c.libelle, c.code";
//print $sql;
}
@@ -88,7 +89,8 @@ if ($mode)
$sql.=" FROM ".MAIN_DB_PREFIX."adherent as d LEFT JOIN ".MAIN_DB_PREFIX."c_departements as c on d.fk_departement = c.rowid";
$sql.=" LEFT JOIN ".MAIN_DB_PREFIX."c_regions as r on c.fk_region = r.code_region";
$sql.=" LEFT JOIN ".MAIN_DB_PREFIX."c_pays as p on d.pays = p.rowid";
$sql.=" WHERE d.statut = 1";
$sql.=" WHERE d.entity IN (".getEntity().")";
$sql.=" AND d.statut = 1";
$sql.=" GROUP BY p.libelle, p.code, c.nom";
//print $sql;
}
@@ -102,7 +104,8 @@ if ($mode)
$sql.="SELECT COUNT(d.rowid) as nb, MAX(d.datevalid) as lastdate, p.code, p.libelle as label, d.ville as label2";
$sql.=" FROM ".MAIN_DB_PREFIX."adherent as d";
$sql.=" LEFT JOIN ".MAIN_DB_PREFIX."c_pays as p on d.pays = p.rowid";
$sql.=" WHERE d.statut = 1";
$sql.=" WHERE d.entity IN (".getEntity().")";
$sql.=" AND d.statut = 1";
$sql.=" GROUP BY p.libelle, p.code, d.ville";
//print $sql;
}

View File

@@ -1,7 +1,7 @@
<?php
/* Copyright (C) 2003 Rodolphe Quiedeville <rodolphe@quiedeville.org>
* Copyright (C) 2004-2011 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2005-2009 Regis Houssin <regis@dolibarr.fr>
* Copyright (C) 2005-2012 Regis Houssin <regis@dolibarr.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

View File

@@ -2,7 +2,7 @@
/* Copyright (C) 2001-2002 Rodolphe Quiedeville <rodolphe@quiedeville.org>
* Copyright (C) 2003 Jean-Louis Bergamo <jlb@j1b.org>
* Copyright (C) 2004-2011 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2005-2011 Regis Houssin <regis@dolibarr.fr>
* Copyright (C) 2005-2012 Regis Houssin <regis@dolibarr.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
@@ -50,7 +50,7 @@ if (! $sortorder) { $sortorder="DESC"; }
if (! $sortfield) { $sortfield="d.nom"; }
// Security check
if (! $user->rights->adherent->lire) accessforbidden();
$result=restrictedArea($user,'adherent',$rowid,'adherent_type');
if (GETPOST('button_removefilter'))
{
@@ -153,7 +153,8 @@ if (! $rowid && $action != 'create' && $action != 'edit')
$sql = "SELECT d.rowid, d.libelle, d.cotisation, d.vote";
$sql .= " FROM ".MAIN_DB_PREFIX."adherent_type as d";
$sql.= " FROM ".MAIN_DB_PREFIX."adherent_type as d";
$sql.= " WHERE d.entity IN (".getEntity().")";
$result = $db->query($sql);
if ($result)
@@ -267,10 +268,8 @@ if ($rowid > 0)
if ($action != 'edit')
{
$adht = new AdherentType($db);
$adht->id = $rowid;
$adht->fetch($rowid);
$h=0;
$head[$h][0] = $_SERVER["PHP_SELF"].'?rowid='.$adht->id;
@@ -344,7 +343,7 @@ if ($rowid > 0)
$sql.= " t.libelle as type, t.cotisation";
$sql.= " FROM ".MAIN_DB_PREFIX."adherent as d, ".MAIN_DB_PREFIX."adherent_type as t";
$sql.= " WHERE d.fk_adherent_type = t.rowid ";
$sql.= " AND d.entity = ".$conf->entity;
$sql.= " AND d.entity IN (".getEntity().")";
$sql.= " AND t.rowid = ".$adht->id;
if ($sall)
{

View File

@@ -35,6 +35,7 @@ require_once(DOL_DOCUMENT_ROOT.'/commande/class/commande.class.php');
$langs->load("admin");
$langs->load("errors");
$langs->load("orders");
if (! $user->admin) accessforbidden();

View File

@@ -40,9 +40,6 @@ if (!$user->admin) accessforbidden();
$action=GETPOST('action','alpha');
$value=GETPOST('value','alpha');
$label = GETPOST('label','alpha');
$scandir = GETPOST('scandir','alpha');
$type='shipping';
if (empty($conf->global->EXPEDITION_ADDON_NUMBER))
{
@@ -53,59 +50,6 @@ if (empty($conf->global->EXPEDITION_ADDON_NUMBER))
/*
* Actions
*/
if ($action == 'updateMask')
{
$maskconst=GETPOST('maskconstexpedition','alpha');
$maskvalue=GETPOST('maskexpedition','alpha');
if ($maskconst) $res = dolibarr_set_const($db,$maskconst,$maskvalue,'chaine',0,'',$conf->entity);
if (! $res > 0) $error++;
if (! $error)
{
$mesg = "<font class=\"ok\">".$langs->trans("SetupSaved")."</font>";
}
else
{
$mesg = "<font class=\"error\">".$langs->trans("Error")."</font>";
}
}
if ($action == 'set_SHIPPING_FREE_TEXT')
{
$freetext=GETPOST('SHIPPING_FREE_TEXT','alpha');
$res = dolibarr_set_const($db, "SHIPPING_FREE_TEXT",$freetext,'chaine',0,'',$conf->entity);
if (! $res > 0) $error++;
if (! $error)
{
$mesg = "<font class=\"ok\">".$langs->trans("SetupSaved")."</font>";
}
else
{
$mesg = "<font class=\"error\">".$langs->trans("Error")."</font>";
}
}
if ($action == 'set_SHIPPING_DRAFT_WATERMARK')
{
$draft=GETPOST('SHIPPING_DRAFT_WATERMARK','alpha');
$res = dolibarr_set_const($db, "SHIPPING_DRAFT_WATERMARK",trim($draft),'chaine',0,'',$conf->entity);
if (! $res > 0) $error++;
if (! $error)
{
$mesg = "<font class=\"ok\">".$langs->trans("SetupSaved")."</font>";
}
else
{
$mesg = "<font class=\"error\">".$langs->trans("Error")."</font>";
}
}
if ($action == 'specimen')
{
$modele=GETPOST('module','alpha');
@@ -118,11 +62,11 @@ if ($action == 'specimen')
$dirmodels=array_merge(array('/'),(array) $conf->modules_parts['models']);
foreach($dirmodels as $reldir)
{
$file=dol_buildpath($reldir."core/modules/expedition/doc/pdf_".$modele.".modules.php",0);
$file=dol_buildpath($reldir."core/modules/expedition/doc/pdf_expedition_".$modele.".modules.php",0);
if (file_exists($file))
{
$filefound=1;
$classname = "pdf_".$modele;
$classname = "pdf_expedition_".$modele;
break;
}
}
@@ -140,8 +84,8 @@ if ($action == 'specimen')
}
else
{
$mesg='<font class="error">'.$obj->error.'</font>';
dol_syslog($obj->error, LOG_ERR);
$mesg='<font class="error">'.$module->error.'</font>';
dol_syslog($module->error, LOG_ERR);
}
}
else
@@ -154,13 +98,30 @@ if ($action == 'specimen')
// Activate a model
if ($action == 'set')
{
$ret = addDocumentModel($value, $type, $label, $scandir);
$label = GETPOST('label','alpha');
$scandir = GETPOST('scandir','alpha');
$type='shipping';
$sql = "INSERT INTO ".MAIN_DB_PREFIX."document_model (nom, type, entity, libelle, description)";
$sql.= " VALUES ('".$db->escape($value)."','".$type."',".$conf->entity.", ";
$sql.= ($label?"'".$db->escape($label)."'":'null').", ";
$sql.= (! empty($scandir)?"'".$db->escape($scandir)."'":"null");
$sql.= ")";
if ($db->query($sql))
{
}
}
if ($action == 'del')
{
$ret = delDocumentModel($value, $type);
if ($ret > 0)
$type='shipping';
$sql = "DELETE FROM ".MAIN_DB_PREFIX."document_model";
$sql.= " WHERE nom = '".$db->escape($value)."'";
$sql.= " AND type = '".$type."'";
$sql.= " AND entity = ".$conf->entity;
if ($db->query($sql))
{
if ($conf->global->EXPEDITION_ADDON_PDF == "$value") dolibarr_del_const($db, 'EXPEDITION_ADDON_PDF',$conf->entity);
}
@@ -169,18 +130,37 @@ if ($action == 'del')
// Set default model
if ($action == 'setdoc')
{
$label = GETPOST('label','alpha');
$scandir = GETPOST('scandir','alpha');
$db->begin();
if (dolibarr_set_const($db, "EXPEDITION_ADDON_PDF",$value,'chaine',0,'',$conf->entity))
{
// La constante qui a ete lue en avant du nouveau set
// on passe donc par une variable pour avoir un affichage coherent
$conf->global->EXPEDITION_ADDON_PDF = $value;
}
// On active le modele
$ret = delDocumentModel($value, $type);
if ($ret > 0)
$type='shipping';
$sql_del = "DELETE FROM ".MAIN_DB_PREFIX."document_model";
$sql_del.= " WHERE nom = '".$db->escape($value)."'";
$sql_del.= " AND type = '".$type."'";
$sql_del.= " AND entity = ".$conf->entity;
$result1=$db->query($sql_del);
$sql = "INSERT INTO ".MAIN_DB_PREFIX."document_model (nom, type, entity, libelle, description)";
$sql.= " VALUES ('".$db->escape($value)."', '".$type."', ".$conf->entity.", ";
$sql.= ($label?"'".$db->escape($label)."'":'null').", ";
$sql.= (! empty($scandir)?"'".$db->escape($scandir)."'":"null");
$sql.= ")";
$result2=$db->query($sql);
if ($result1 && $result2)
{
$ret = addDocumentModel($value, $type, $label, $scandir);
$db->commit();
}
else
{
$db->rollback();
}
}
@@ -260,8 +240,28 @@ if ($action == 'setmod')
// TODO Verifier si module numerotation choisi peut etre active
// par appel methode canBeActivated
dolibarr_set_const($db, "EXPEDITION_ADDON",$value,'chaine',0,'',$conf->entity);
$module=GETPOST('module','alpha');
dolibarr_set_const($db, "EXPEDITION_ADDON",$module,'chaine',0,'',$conf->entity);
}
if ($action == 'updateMask')
{
$maskconst=GETPOST('maskconstexpedition','alpha');
$maskvalue=GETPOST('maskexpedition','alpha');
if ($maskconst) $res = dolibarr_set_const($db,$maskconst,$maskvalue,'chaine',0,'',$conf->entity);
if (! $res > 0) $error++;
if (! $error)
{
$mesg = "<font class=\"ok\">".$langs->trans("SetupSaved")."</font>";
}
else
{
$mesg = "<font class=\"error\">".$langs->trans("Error")."</font>";
}
}
if ($action == 'setmodel')
@@ -269,6 +269,39 @@ if ($action == 'setmodel')
dolibarr_set_const($db, "EXPEDITION_ADDON_NUMBER",$value,'chaine',0,'',$conf->entity);
}
if ($action == 'set_SHIPPING_DRAFT_WATERMARK')
{
$draft=GETPOST('SHIPPING_DRAFT_WATERMARK','alpha');
$res = dolibarr_set_const($db, "SHIPPING_DRAFT_WATERMARK",trim($draft),'chaine',0,'',$conf->entity);
if (! $res > 0) $error++;
if (! $error)
{
$mesg = "<font class=\"ok\">".$langs->trans("SetupSaved")."</font>";
}
else
{
$mesg = "<font class=\"error\">".$langs->trans("Error")."</font>";
}
}
if ($action == 'set_SHIPPING_FREE_TEXT')
{
$free=GETPOST('SHIPPING_FREE_TEXT','alpha');
$res = dolibarr_set_const($db, "SHIPPING_FREE_TEXT",$free,'chaine',0,'',$conf->entity);
if (! $res > 0) $error++;
if (! $error)
{
$mesg = "<font class=\"ok\">".$langs->trans("SetupSaved")."</font>";
}
else
{
$mesg = "<font class=\"error\">".$langs->trans("Error")."</font>";
}
}
/*
* View

View File

@@ -381,7 +381,7 @@ foreach ($dirmodels as $reldir)
}
else
{
print '<a href="'.$_SERVER["PHP_SELF"].'?action=setmod&amp;value='.preg_replace('/\.php$/','',$file).'&amp;scandir='.$module->scandir.'&amp;label='.urlencode($module->name).'" alt="'.$langs->trans("Default").'">'.img_picto($langs->trans("Disabled"),'switch_off').'</a>';
print '<a href="'.$_SERVER["PHP_SELF"].'?action=setmod&value='.preg_replace('/\.php$/','',$file).'&scandir='.$module->scandir.'&label='.urlencode($module->name).'" alt="'.$langs->trans("Default").'">'.img_picto($langs->trans("Disabled"),'switch_off').'</a>';
}
print '</td>';
@@ -535,7 +535,7 @@ foreach ($dirmodels as $reldir)
if (in_array($name, $def))
{
print '<td align="center">'."\n";
print '<a href="'.$_SERVER["PHP_SELF"].'?action=del&amp;value='.$name.'">';
print '<a href="'.$_SERVER["PHP_SELF"].'?action=del&value='.$name.'">';
print img_picto($langs->trans("Enabled"),'switch_on');
print '</a>';
print '</td>';
@@ -543,7 +543,7 @@ foreach ($dirmodels as $reldir)
else
{
print "<td align=\"center\">\n";
print '<a href="'.$_SERVER["PHP_SELF"].'?action=set&amp;value='.$name.'&amp;scandir='.$module->scandir.'&amp;label='.urlencode($module->name).'">'.img_picto($langs->trans("Disabled"),'switch_off').'</a>';
print '<a href="'.$_SERVER["PHP_SELF"].'?action=set&value='.$name.'&scandir='.$module->scandir.'&label='.urlencode($module->name).'">'.img_picto($langs->trans("Disabled"),'switch_off').'</a>';
print "</td>";
}
@@ -555,7 +555,7 @@ foreach ($dirmodels as $reldir)
}
else
{
print '<a href="'.$_SERVER["PHP_SELF"].'?action=setdoc&amp;value='.$name.'&amp;scandir='.$module->scandir.'&amp;label='.urlencode($module->name).'" alt="'.$langs->trans("Default").'">'.img_picto($langs->trans("Disabled"),'off').'</a>';
print '<a href="'.$_SERVER["PHP_SELF"].'?action=setdoc&value='.$name.'&scandir='.$module->scandir.'&label='.urlencode($module->name).'" alt="'.$langs->trans("Default").'">'.img_picto($langs->trans("Disabled"),'off').'</a>';
}
print '</td>';

View File

@@ -86,7 +86,9 @@ foreach($modules as $const => $desc)
if (GETPOST('save','alpha'))
{
dolibarr_set_const($db, "FCKEDITOR_TEST", GETPOST('formtestfield','alpha'),'chaine',0,'',$conf->entity);
$res=dolibarr_set_const($db, "FCKEDITOR_TEST", GETPOST('formtestfield'),'chaine',0,'',$conf->entity);
if ($res > 0) $mesg=$langs->trans("RecordModifiedSuccessfully");
}
@@ -103,15 +105,21 @@ print '<br>';
$var=true;
print '<table class="noborder" width="100%">';
print '<tr class="liste_titre">';
print '<td colspan="2">'.$langs->trans("ActivateFCKeditor").'</td>';
print '<td align="center" width="100">'.$langs->trans("Action").'</td>';
print "</tr>\n";
// Modules
foreach($modules as $const => $desc)
if (empty($conf->use_javascript_ajax))
{
dol_htmloutput_errors('',array($langs->trans("NotAvailable"),$langs->trans("JavascriptDisabled")),1);
}
else
{
print '<table class="noborder" width="100%">';
print '<tr class="liste_titre">';
print '<td colspan="2">'.$langs->trans("ActivateFCKeditor").'</td>';
print '<td align="center" width="100">'.$langs->trans("Action").'</td>';
print "</tr>\n";
// Modules
foreach($modules as $const => $desc)
{
// Si condition non remplie, on ne propose pas l'option
if (! $conditions[$const]) continue;
@@ -133,26 +141,28 @@ foreach($modules as $const => $desc)
print "</td>";
print '</tr>';
}
}
print '</table>'."\n";
print '</table>'."\n";
dol_htmloutput_mesg($mesg);
print '<br>'."\n";
print_fiche_titre($langs->trans("TestSubmitForm"),'','');
print '<form name="formtest" method="POST" action="'.$_SERVER["PHP_SELF"].'">'."\n";
$uselocalbrowser=true;
$editor=new DolEditor('formtestfield',isset($conf->global->FCKEDITOR_TEST)?$conf->global->FCKEDITOR_TEST:'Test','',200,'dolibarr_notes','In', true, $uselocalbrowser);
$editor->Create();
print '<center><br><input class="button" type="submit" name="save" value="'.$langs->trans("Save").'"></center>'."\n";
print '</form>'."\n";
print '<br>'."\n";
print_fiche_titre($langs->trans("TestSubmitForm"),'','');
print '<form name="formtest" method="POST" action="'.$_SERVER["PHP_SELF"].'">'."\n";
$uselocalbrowser=true;
$editor=new DolEditor('formtestfield',isset($conf->global->FCKEDITOR_TEST)?$conf->global->FCKEDITOR_TEST:'Test','',200,'dolibarr_notes','In', true, $uselocalbrowser);
$editor->Create();
print '<center><br><input class="button" type="submit" name="save" value="'.$langs->trans("Save").'"></center>'."\n";
print '</form>'."\n";
/*
/*
print '<!-- Result -->';
print $_POST["formtestfield"];
print '<!-- Result -->';
print $conf->global->FCKEDITOR_TEST;
*/
}
$db->close();

View File

@@ -218,7 +218,7 @@ if ($action == 'edit') // Edit
// Hide wiki link on login page
$var=!$var;
print '<tr '.$bc[$var].'><td width="35%">'.$langs->trans("DisableLinkToHelp",img_picto('',DOL_URL_ROOT.'/theme/common/helpdoc.png','',1)).'</td><td>';
print '<tr '.$bc[$var].'><td width="35%">'.$langs->trans("DisableLinkToHelp",img_picto('',DOL_URL_ROOT.'/theme/'.$conf->theme.'/img/helpdoc.png','',1)).'</td><td>';
print $form->selectyesno('MAIN_HELP_DISABLELINK',isset($conf->global->MAIN_HELP_DISABLELINK)?$conf->global->MAIN_HELP_DISABLELINK:0,1);
print '</td>';
print '<td width="20">&nbsp;</td>';
@@ -366,7 +366,7 @@ else // Show
// Link to wiki help
$var=!$var;
print '<tr '.$bc[$var].'><td width="35%">'.$langs->trans("DisableLinkToHelp",img_picto('',DOL_URL_ROOT.'/theme/common/helpdoc.png','',1)).'</td><td colspan="2">';
print '<tr '.$bc[$var].'><td width="35%">'.$langs->trans("DisableLinkToHelp",img_picto('',DOL_URL_ROOT.'/theme/'.$conf->theme.'/img/helpdoc.png','',1)).'</td><td colspan="2">';
print yn($conf->global->MAIN_HELP_DISABLELINK,1);
print '</td></tr>';

View File

@@ -48,7 +48,7 @@ if ($action == 'setvalue' && $user->admin)
$db->begin();
if (! dolibarr_set_const($db, 'LDAP_SERVER_TYPE',GETPOST("type"),'chaine',0,'',$conf->entity)) $error++;
if (! dolibarr_set_const($db, 'LDAP_SERVER_PROTOCOLVERSION',GETPOST("version"),'chaine',0,'',$conf->entity)) $error++;
if (! dolibarr_set_const($db, 'LDAP_SERVER_PROTOCOLVERSION',GETPOST("LDAP_SERVER_PROTOCOLVERSION"),'chaine',0,'',$conf->entity)) $error++;
if (! dolibarr_set_const($db, 'LDAP_SERVER_HOST',GETPOST("host"),'chaine',0,'',$conf->entity)) $error++;
if (! dolibarr_set_const($db, 'LDAP_SERVER_HOST_SLAVE',GETPOST("slave"),'chaine',0,'',$conf->entity)) $error++;
if (! dolibarr_set_const($db, 'LDAP_SERVER_PORT',GETPOST("port"),'chaine',0,'',$conf->entity)) $error++;
@@ -169,7 +169,7 @@ print '<tr '.$bc[$var].'><td>'.$langs->trans("Version").'</td><td>';
$arraylist=array();
$arraylist['3']='Version 3';
$arraylist['2']='Version 2';
print $form->selectarray('version',$arraylist,$conf->global->LDAP_SERVER_PROTOCOLVERSION);
print $form->selectarray('LDAP_SERVER_PROTOCOLVERSION',$arraylist,$conf->global->LDAP_SERVER_PROTOCOLVERSION);
print '</td><td>'.$langs->trans("LDAPServerProtocolVersion").'</td></tr>';
// Serveur primaire

View File

@@ -49,6 +49,8 @@ if ($action == 'setvalue' && $user->admin)
if (! $res > 0) $error++;
$res=dolibarr_set_const($db, "MAILING_EMAIL_ERRORSTO",$mailerror,'chaine',0,'',$conf->entity);
if (! $res > 0) $error++;
$res=dolibarr_set_const($db, "MAILING_EMAIL_UNSUBSCRIBE",$checkread,'chaine',0,'',$conf->entity);
if (! $res > 0) $error++;
if (! $error)
{
@@ -101,11 +103,31 @@ print '<input size="32" type="text" name="MAILING_EMAIL_ERRORSTO" value="'.$conf
if (!empty($conf->global->MAILING_EMAIL_ERRORSTO) && ! isValidEmail($conf->global->MAILING_EMAIL_ERRORSTO)) print ' '.img_warning($langs->trans("BadEMail"));
print '</td></tr>';
/*
$var=!$var;
print '<tr '.$bc[$var].'><td>';
print $langs->trans("ActivateCheckRead").'</td><td>';
if ($conf->global->MAILING_EMAIL_UNSUBSCRIBE==1)
{
print '<a href="'.$_SERVER["PHP_SELF"].'?action=setvalue&value=0">';
print img_picto($langs->trans("Enabled"),'switch_on');
print '</a>';
}
else
{
print '<a href="'.$_SERVER["PHP_SELF"].'?action=setvalue&value=1">';
print img_picto($langs->trans("Disabled"),'switch_off');
print '</a>';
}
print '</td></tr>';
*/
print '<tr><td colspan="3" align="center"><input type="submit" class="button" value="'.$langs->trans("Modify").'"></td></tr>';
print '</table></form>';
$db->close();
llxFooter();
$db->close();
?>

View File

@@ -147,6 +147,7 @@ if (! empty($_POST['removedfile']) || ! empty($_POST['removedfilehtml']))
$result = dol_delete_file($pathtodelete,1);
if ($result >= 0)
{
$langs->load("other");
$message = '<div class="ok">'.$langs->trans("FileWasRemoved",$filetodelete).'</div>';
//print_r($_FILES);

View File

@@ -222,13 +222,13 @@ foreach ($dirmodels as $reldir)
print '</td>'."\n";
print '<td align="center">';
if ($conf->global->PROJECT_ADDON == $classname)
if ($conf->global->PROJECT_ADDON == 'mod_'.$classname)
{
print img_picto($langs->trans("Activated"),'switch_on');
}
else
{
print '<a href="'.$_SERVER["PHP_SELF"].'?action=setmod&amp;value='.$classname.'" alt="'.$langs->trans("Default").'">'.img_picto($langs->trans("Disabled"),'switch_off').'</a>';
print '<a href="'.$_SERVER["PHP_SELF"].'?action=setmod&amp;value=mod_'.$classname.'" alt="'.$langs->trans("Default").'">'.img_picto($langs->trans("Disabled"),'switch_off').'</a>';
}
print '</td>';

View File

@@ -46,7 +46,7 @@ if ($_POST["sendit"] && ! empty($conf->global->MAIN_UPLOAD_DOC))
$result=dol_mkdir($upload_dir); // Create dir if not exists
if ($result >= 0)
{
$resupload=dol_move_uploaded_file($_FILES['userfile']['tmp_name'], $upload_dir . "/" . $_FILES['userfile']['name'],1,0,$_FILES['userfile']['error']);
$resupload=dol_move_uploaded_file($_FILES['userfile']['tmp_name'], $upload_dir . "/" . dol_unescapefile($_FILES['userfile']['name']),1,0,$_FILES['userfile']['error']);
if (is_numeric($resupload) && $resupload > 0)
{

View File

@@ -1,5 +1,5 @@
<?php
/* Copyright (C) 2005-2011 Laurent Destailleur <eldy@users.sourceforge.net>
/* Copyright (C) 2005-2012 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2005-2009 Regis Houssin <regis@dolibarr.fr>
* Copyright (C) 2007 Rodolphe Quiedeville <rodolphe@quiedeville.org>
*
@@ -178,14 +178,14 @@ $var=true;
$var=!$var;
print '<tr '.$bc[$var].'><td width="140"><input '.$bc[$var].' type="checkbox" name="SYSLOG_FILE_ON" '.$option.' value="1" '.($syslog_file_on?' checked="checked"':'').'> '.$langs->trans("SyslogSimpleFile").'</td>';
print '<td width="250" nowrap="nowrap">'.$langs->trans("SyslogFilename").': <input type="text" class="flat" name="filename" '.$option.' size="60" value="'.$defaultsyslogfile.'">';
print '<td nowrap="nowrap">'.$langs->trans("SyslogFilename").': <input type="text" class="flat" name="filename" '.$option.' size="60" value="'.$defaultsyslogfile.'">';
print '</td>';
print "<td align=\"left\">".$form->textwithpicto('',$langs->trans("YouCanUseDOL_DATA_ROOT"));
print '</td></tr>';
$var=!$var;
print '<tr '.$bc[$var].'><td width="140"><input '.$bc[$var].' type="checkbox" name="SYSLOG_SYSLOG_ON" '.$option.' value="1" '.($syslog_syslog_on?' checked="checked"':'').'> '.$langs->trans("SyslogSyslog").'</td>';
print '<td width="250" nowrap="nowrap">'.$langs->trans("SyslogFacility").': <input type="text" class="flat" name="facility" '.$option.' value="'.$defaultsyslogfacility.'">';
print '<td nowrap="nowrap">'.$langs->trans("SyslogFacility").': <input type="text" class="flat" name="facility" '.$option.' value="'.$defaultsyslogfacility.'">';
print '</td>';
print "<td align=\"left\">".$form->textwithpicto('','Only LOG_USER supported on Windows');
print '</td></tr>';
@@ -202,7 +202,7 @@ try
if (! class_exists('FirePHP')) print ' disabled="disabled"';
else print ($syslog_firephp_on?' checked="checked"':"");
print '> '.$langs->trans("FirePHP").'</td>';
print '<td width="250" nowrap="nowrap">';
print '<td nowrap="nowrap">';
print '</td>';
print "<td align=\"left\">".$form->textwithpicto('','FirePHP must be installed onto PHP and FirePHP plugin for Firefox must also be installed');
print '</td></tr>';
@@ -232,7 +232,7 @@ print '<td align="right"><input type="submit" class="button" '.$option.' value="
print "</tr>\n";
$var=true;
$var=!$var;
print '<tr '.$bc[$var].'><td width=\"140\">'.$langs->trans("SyslogLevel").'</td>';
print '<tr '.$bc[$var].'><td width="140">'.$langs->trans("SyslogLevel").'</td>';
print '<td colspan="2"><select class="flat" name="level" '.$option.'>';
print '<option value="'.LOG_EMERG.'" '.($conf->global->SYSLOG_LEVEL==LOG_EMERG?'SELECTED':'').'>LOG_EMERG ('.LOG_EMERG.')</option>';
print '<option value="'.LOG_ALERT.'" '.($conf->global->SYSLOG_LEVEL==LOG_ALERT?'SELECTED':'').'>LOG_ALERT ('.LOG_ALERT.')</option>';

View File

@@ -157,10 +157,16 @@ $txt =$langs->trans("OSTZ").' (variable system TZ): '.($_ENV["TZ"]?$_ENV["TZ"]:$
$txt.=$langs->trans("PHPTZ").' (php.ini date.timezone): '.(ini_get("date.timezone")?ini_get("date.timezone"):$langs->trans("NotDefined")).''."\n"; // date.timezone must be in valued defined in http://fr3.php.net/manual/en/timezones.europe.php
$var=!$var;
print '<tr '.$bc[$var].'><td width="300">'.$langs->trans("CurrentTimeZone").'</td><td>'; // Timezone server PHP
$a=getServerTimeZoneString();
$a.=' '.(getServerTimeZoneInt()>=0?'+':'').getServerTimeZoneInt();
$a.=' ('.(getServerTimeZoneInt()>=0?'+':'').(getServerTimeZoneInt()*3600).')';
print $form->textwithtooltip($a,$txt,2,1,img_info(''));
$a=getServerTimeZoneInt('now');
$b=getServerTimeZoneInt('winter');
$c=getServerTimeZoneInt('summer');
$daylight=(is_numeric($c) && is_numeric($b))?round($c-$b):'unknown';
//print $a." ".$b." ".$c." ".$daylight;
$val=($a>=0?'+':'').$a;
$val.=' ('.($a==='unknown'?'unknown':($a>=0?'+':'').($a*3600)).')';
$val.=' &nbsp; &nbsp; &nbsp; '.getServerTimeZoneString().' '.($b>=0?'+':'').$b.' ('.($b>=0?'+':'').($b*3600).')';
$val.=' &nbsp; &nbsp; &nbsp; '.$langs->trans("DaylingSavingTime").': '.($daylight==='unknown'?'unknown':yn($daylight));
print $form->textwithtooltip($val,$txt,2,1,img_info(''));
print '</td></tr>'."\n"; // value defined in http://fr3.php.net/manual/en/timezones.europe.php
$var=!$var;
print '<tr '.$bc[$var].'><td width="300">&nbsp; => '.$langs->trans("CurrentHour").'</td><td>'.dol_print_date(dol_now(),'dayhour','tzserver').'</td></tr>'."\n";

View File

@@ -47,12 +47,12 @@ $modules = array();
$modules_names = array();
$modules_files = array();
// Search modules dirs
$modulesdir = array();
foreach ($conf->file->dol_document_root as $type => $dirroot)
{
$modulesdir[] = $dirroot . "/core/modules/";
$modulesdir[$dirroot . '/core/modules/'] = $dirroot . '/core/modules/';
if ($type == 'alt')
{
$handle=@opendir($dirroot);
if (is_resource($handle))
{
@@ -62,14 +62,15 @@ foreach ($conf->file->dol_document_root as $type => $dirroot)
{
if (is_dir($dirroot . '/' . $file . '/core/modules/'))
{
$modulesdir[] = $dirroot . '/' . $file . '/core/modules/';
$modulesdir[$dirroot . '/' . $file . '/core/modules/'] = $dirroot . '/' . $file . '/core/modules/';
}
}
}
closedir($handle);
}
}
}
//var_dump($modulesdir);
// Load list of modules
foreach($modulesdir as $dir)

View File

@@ -33,9 +33,7 @@ if ($_GET["msg"]) $message='<div class="error">'.$_GET["msg"].'</div>';
$urldolibarr='http://www.dolibarr.org/downloads/';
//$urldolibarrmodules='http://www.dolibarr.org/downloads/cat_view/65-modulesaddon';
$urldolibarrmodules='http://www.dolistore.com/';
//$urldolibarrthemes='http://www.dolibarr.org/';
$urldolibarrthemes='http://www.dolistore.com/';
$dolibarrroot=preg_replace('/([\\/]+)$/i','',DOL_DOCUMENT_ROOT);
$dolibarrroot=preg_replace('/([^\\/]+)$/i','',$dolibarrroot);

View File

@@ -87,7 +87,7 @@ $workflow=array(
//, 'propal' => array('WORKFLOW_PROPAL_AUTOCREATE_INVOICE')
)
);
$workflow = array_merge($workflow, $conf->modules_parts['workflow']);
if (! empty($conf->modules_parts['workflow']) && is_array($conf->modules_parts['workflow'])) $workflow = array_merge($workflow, $conf->modules_parts['workflow']);
foreach($workflow as $child => $parents)
{

View File

@@ -75,7 +75,7 @@ if ($id || $ref)
$objecttype = 'adherent&categorie';
$objectid = isset($id)?$id:(isset($ref)?$ref:'');
$dbtablename = 'adherent';
$fieldid = isset($ref)?'ref':'rowid';
$fieldid = ! empty($ref)?'ref':'rowid';
}
}

View File

@@ -31,6 +31,7 @@ require_once(DOL_DOCUMENT_ROOT."/contact/class/contact.class.php");
require_once(DOL_DOCUMENT_ROOT."/comm/action/class/cactioncomm.class.php");
require_once(DOL_DOCUMENT_ROOT."/comm/action/class/actioncomm.class.php");
require_once(DOL_DOCUMENT_ROOT."/core/lib/files.lib.php");
require_once(DOL_DOCUMENT_ROOT."/core/lib/images.lib.php");
require_once(DOL_DOCUMENT_ROOT."/core/class/html.formfile.class.php");
if ($conf->projet->enabled) require_once(DOL_DOCUMENT_ROOT."/projet/class/project.class.php");
@@ -67,16 +68,23 @@ if (! $sortfield) $sortfield="name";
*/
if ( $_POST["sendit"] && ! empty($conf->global->MAIN_UPLOAD_DOC))
{
require_once(DOL_DOCUMENT_ROOT."/core/lib/files.lib.php");
// Creation repertoire si n'existe pas
$upload_dir = $conf->agenda->dir_output.'/'.dol_sanitizeFileName($objectid);
if (dol_mkdir($upload_dir) >= 0)
{
$resupload=dol_move_uploaded_file($_FILES['userfile']['tmp_name'], $upload_dir . "/" . $_FILES['userfile']['name'],0,0,$_FILES['userfile']['error']);
$resupload=dol_move_uploaded_file($_FILES['userfile']['tmp_name'], $upload_dir . "/" . dol_unescapefile($_FILES['userfile']['name']),0,0,$_FILES['userfile']['error']);
if (is_numeric($resupload) && $resupload > 0)
{
if (image_format_supported($upload_dir . "/" . $_FILES['userfile']['name']) == 1)
{
// Create small thumbs for image (Ratio is near 16/9)
// Used on logon for example
$imgThumbSmall = vignette($upload_dir . "/" . $_FILES['userfile']['name'], $maxwidthsmall, $maxheightsmall, '_small', $quality, "thumbs");
// Create mini thumbs for image (Ratio is near 16/9)
// Used on menu or for setup page for example
$imgThumbMini = vignette($upload_dir . "/" . $_FILES['userfile']['name'], $maxwidthmini, $maxheightmini, '_mini', $quality, "thumbs");
}
$mesg = '<div class="ok">'.$langs->trans("FileTransferComplete").'</div>';
}
else

View File

@@ -420,7 +420,7 @@ if ($action == 'create')
print '<form name="formaction" action="'.DOL_URL_ROOT.'/comm/action/fiche.php" method="POST">';
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
print '<input type="hidden" name="action" value="add_action">';
print '<input type="hidden" name="backtopage" value="'.((! empty($backtopage) && $backtopage != '1') ? $backtopage : $_SERVER["HTTP_REFERER"]).'">';
if ($backtopage) print '<input type="hidden" name="backtopage" value="'.($backtopage != '1' ? $backtopage : $_SERVER["HTTP_REFERER"]).'">';
if (GETPOST("actioncode") == 'AC_RDV') print_fiche_titre($langs->trans("AddActionRendezVous"));
else print_fiche_titre($langs->trans("AddAnAction"));
@@ -673,7 +673,7 @@ if ($id)
print '<input type="hidden" name="action" value="update">';
print '<input type="hidden" name="id" value="'.$id.'">';
print '<input type="hidden" name="ref_ext" value="'.$act->ref_ext.'">';
print '<input type="hidden" name="backtopage" value="'.((! empty($backtopage) && $backtopage != '1')? $backtopage : $_SERVER["HTTP_REFERER"]).'">';
if ($backtopage) print '<input type="hidden" name="backtopage" value="'.($backtopage != '1'? $backtopage : $_SERVER["HTTP_REFERER"]).'">';
print '<table class="border" width="100%">';
@@ -741,7 +741,7 @@ if ($id)
// Contact
print '<td>'.$langs->trans("Contact").'</td><td width="30%">';
print $form->selectarray("contactid", $act->societe->contact_array(), $act->contact->id, 1);
print $form->selectarray("contactid", (empty($act->societe->id)?array():$act->societe->contact_array()), $act->contact->id, 1);
print '</td></tr>';
// Project

View File

@@ -121,7 +121,7 @@ if ($action=='delete_action')
* View
*/
$help_url='EN:Module_Agenda_En|FR:Module_Agenda|ES:M&omodulodulo_Agenda';
$help_url='EN:Module_Agenda_En|FR:Module_Agenda|ES:M&oacute;dulo_Agenda';
llxHeader('',$langs->trans("Agenda"),$help_url);
$form=new Form($db);

View File

@@ -151,6 +151,10 @@ if ($action == 'delete')
$sql="DELETE FROM ".MAIN_DB_PREFIX."mailing_cibles where rowid=".$id;
$resql=$db->query($sql);
if ($resql)
{ //on récurpére l'id du mailing
$id = GETPOST('id','int');
if (!empty($id))
{
$file = $dirmod."/modules_mailings.php";
$classname = "MailingTargets";
@@ -158,6 +162,15 @@ if ($action == 'delete')
$obj = new $classname($db);
$obj->update_nb($id);
Header("Location: cibles.php?id=".$id);
exit;
}
else
{
Header("Location: liste.php");
exit;
}
}
else
{

View File

@@ -57,7 +57,7 @@ $substitutionarray=array(
'__SIGNATURE__' => 'Signature',
'__PERSONALIZED__' => 'Personalized'
);
if ($conf->global->MAIN_SOCIETE_UNSUBSCRIBE)
if ($conf->global->MAILING_EMAIL_UNSUBSCRIBE)
{
$substitutionarray=array_merge(
$substitutionarray,
@@ -81,7 +81,7 @@ $substitutionarrayfortest=array(
'__SIGNATURE__' => 'TESTSignature',
'__PERSONALIZED__' => 'TESTPersonalized'
);
if ($conf->global->MAIN_SOCIETE_UNSUBSCRIBE)
if ($conf->global->MAILING_EMAIL_UNSUBSCRIBE)
{
$substitutionarrayfortest=array_merge(
$substitutionarrayfortest,
@@ -681,14 +681,12 @@ else
$ret=$form->form_confirm($_SERVER["PHP_SELF"]."?id=".$object->id,$langs->trans("ValidMailing"),$langs->trans("ConfirmValidMailing"),"confirm_valid",'','',1);
if ($ret == 'html') print '<br>';
}
// Confirm reset
else if ($action == 'reset')
{
$ret=$form->form_confirm($_SERVER["PHP_SELF"]."?id=".$object->id,$langs->trans("ResetMailing"),$langs->trans("ConfirmResetMailing",$object->ref),"confirm_reset",'','',2);
if ($ret == 'html') print '<br>';
}
// Confirm delete
else if ($action == 'delete')
{
@@ -696,7 +694,8 @@ else
if ($ret == 'html') print '<br>';
}
else if ($action != 'edit')
if ($action != 'edit')
{
/*
* Mailing en mode visu
@@ -747,12 +746,12 @@ else
// From
print '<tr><td>'.$form->editfieldkey("MailFrom",'email_from',$object->email_from,$object,$user->rights->mailing->creer && $object->statut < 3,'string').'</td><td colspan="3">';
print $form->editfieldval("MailFrom",'email_from',$object->email_from,$object,$user->rights->mailing->creer && $object->statut < 3,'string');
print $form->editfieldval("MailFrom",'email_from',$object->email_from,$object,$user->rights->mailing->creer && $object->statut < 3,'email');
print '</td></tr>';
// Errors to
print '<tr><td>'.$form->editfieldkey("MailErrorsTo",'email_errorsto',$object->email_errorsto,$object,$user->rights->mailing->creer && $object->statut < 3,'string').'</td><td colspan="3">';
print $form->editfieldval("MailErrorsTo",'email_errorsto',$object->email_errorsto,$object,$user->rights->mailing->creer && $object->statut < 3,'string');
print $form->editfieldval("MailErrorsTo",'email_errorsto',$object->email_errorsto,$object,$user->rights->mailing->creer && $object->statut < 3,'email');
print '</td></tr>';
// Status
@@ -763,7 +762,7 @@ else
print $langs->trans("TotalNbOfDistinctRecipients");
print '</td><td colspan="3">';
$nbemail = ($object->nbemail?$object->nbemail:img_warning('').' <font class="warning">'.$langs->trans("NoTargetYet").'</font>');
if (!empty($conf->global->MAILING_LIMIT_SENDBYWEB) && is_numeric($nbemail) && $conf->global->MAILING_LIMIT_SENDBYWEB < $nbemail)
if ($object->statut != 3 && !empty($conf->global->MAILING_LIMIT_SENDBYWEB) && is_numeric($nbemail) && $conf->global->MAILING_LIMIT_SENDBYWEB < $nbemail)
{
if ($conf->global->MAILING_LIMIT_SENDBYWEB > 0)
{
@@ -955,9 +954,13 @@ else
print '<table class="border" width="100%">';
// Ref
print '<tr><td width="25%">'.$langs->trans("Ref").'</td><td colspan="3">'.$object->id.'</td></tr>';
// Topic
print '<tr><td width="25%">'.$langs->trans("MailTitle").'</td><td colspan="3">'.$object->titre.'</td></tr>';
// From
print '<tr><td width="25%">'.$langs->trans("MailFrom").'</td><td colspan="3">'.dol_print_email($object->email_from,0,0,0,0,1).'</td></tr>';
// To
print '<tr><td width="25%">'.$langs->trans("MailErrorsTo").'</td><td colspan="3">'.dol_print_email($object->email_errorsto,0,0,0,0,1).'</td></tr>';
// Status
@@ -1043,7 +1046,7 @@ else
print '<br><i>'.$langs->trans("CommonSubstitutions").':<br>';
print '__ID__ = '.$langs->trans("IdRecord").'<br>';
print '__EMAIL__ = '.$langs->trans("EMail").'<br>';
if ($conf->global->MAIN_SOCIETE_UNSUBSCRIBE)
if ($conf->global->MAILING_EMAIL_UNSUBSCRIBE)
{
print '__CHECK_READ__ = '.$langs->trans("CheckRead").'<br>';
print '__UNSUSCRIBE__ = '.$langs->trans("MailUnsubcribe").'<br>';

View File

@@ -1,5 +1,5 @@
<?php
/* Copyright (C) 2005-2009 Laurent Destailleur <eldy@users.sourceforge.net>
/* Copyright (C) 2005-2012 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2005-2010 Regis Houssin <regis@dolibarr.fr>
*
* This program is free software; you can redistribute it and/or modify
@@ -155,7 +155,7 @@ if ($result)
{
print '<td align="center">';
$nbemail = $obj->nbemail;
if (!empty($conf->global->MAILING_LIMIT_SENDBYWEB) && $conf->global->MAILING_LIMIT_SENDBYWEB < $nbemail)
if ($obj->statut != 3 && !empty($conf->global->MAILING_LIMIT_SENDBYWEB) && $conf->global->MAILING_LIMIT_SENDBYWEB < $nbemail)
{
$text=$langs->trans('LimitSendingEmailing',$conf->global->MAILING_LIMIT_SENDBYWEB);
print $form->textwithpicto($nbemail,$text,1,'warning');
@@ -192,7 +192,7 @@ else
dol_print_error($db);
}
$db->close();
llxFooter();
$db->close();
?>

View File

@@ -136,6 +136,7 @@ if ($action == 'confirm_clone' && $confirm == 'yes')
else if ($action == 'confirm_delete' && $confirm == 'yes' && $user->rights->propale->supprimer)
{
$object->fetch($id);
$object->fetch_thirdparty();
$result=$object->delete($user);
if ($result > 0)
{
@@ -834,6 +835,7 @@ else if ($action == "addline" && $user->rights->propale->creer)
unset($_POST['np_price']);
unset($_POST['dp_desc']);
unset($_POST['np_tva_tx']);
unset($_POST['np_desc']);
}
else
{
@@ -1146,7 +1148,7 @@ if ($id > 0 || ! empty($ref))
//'text' => $langs->trans("ConfirmClone"),
//array('type' => 'checkbox', 'name' => 'clone_content', 'label' => $langs->trans("CloneMainAttributes"), 'value' => 1),
//array('type' => 'checkbox', 'name' => 'update_prices', 'label' => $langs->trans("PuttingPricesUpToDate"), 'value' => 1),
array('type' => 'other', 'name' => 'socid', 'label' => $langs->trans("SelectThirdParty"), 'value' => $form->select_company(GETPOST('socid','int'),'socid','(s.client=1 OR s.client=3)'))
array('type' => 'other', 'name' => 'socid', 'label' => $langs->trans("SelectThirdParty"), 'value' => $form->select_company(GETPOST('socid','int'),'socid','(s.client=1 OR s.client=2 OR s.client=3)'))
);
// Paiement incomplet. On demande si motif = escompte ou autre
$formconfirm=$form->formconfirm($_SERVER["PHP_SELF"].'?id='.$object->id,$langs->trans('ClonePropal'),$langs->trans('ConfirmClonePropal',$object->ref),'confirm_clone',$formquestion,'yes',1);
@@ -2002,7 +2004,7 @@ else
print '</td>';
print '<td width="20" class="nobordernopadding" nowrap="nowrap">';
if ($objp->fk_statut == 1 && $objp->dfv < ($now - $conf->propal->cloture->warning_delay)) print img_warning($langs->trans("Late"));
if ($objp->fk_statut == 1 && $db->jdate($objp->dfv) < ($now - $conf->propal->cloture->warning_delay)) print img_warning($langs->trans("Late"));
print '</td>';
print '<td width="16" align="right" class="nobordernopadding">';

View File

@@ -1588,6 +1588,7 @@ class Propal extends CommonObject
if ($this->db->query($sql))
{
$this->statut = 0;
$this->brouillon = 1;
return 1;
}
else
@@ -1809,7 +1810,7 @@ class Propal extends CommonObject
{
dol_delete_preview($this);
if (!dol_delete_file($file))
if (! dol_delete_file($file,0,0,0,$this)) // For triggers
{
$this->error='ErrorFailToDeleteFile';
$this->db->rollback();

View File

@@ -28,6 +28,7 @@ require("../../main.inc.php");
require_once(DOL_DOCUMENT_ROOT."/comm/propal/class/propal.class.php");
require_once(DOL_DOCUMENT_ROOT."/core/lib/propal.lib.php");
require_once(DOL_DOCUMENT_ROOT."/core/lib/files.lib.php");
require_once(DOL_DOCUMENT_ROOT."/core/lib/images.lib.php");
require_once(DOL_DOCUMENT_ROOT."/core/class/html.formfile.class.php");
$langs->load('compta');
@@ -74,9 +75,18 @@ if ($_POST["sendit"] && ! empty($conf->global->MAIN_UPLOAD_DOC))
if (dol_mkdir($upload_dir) >= 0)
{
$resupload=dol_move_uploaded_file($_FILES['userfile']['tmp_name'], $upload_dir . "/" . $_FILES['userfile']['name'],0,0,$_FILES['userfile']['error']);
$resupload=dol_move_uploaded_file($_FILES['userfile']['tmp_name'], $upload_dir . "/" . dol_unescapefile($_FILES['userfile']['name']),0,0,$_FILES['userfile']['error']);
if (is_numeric($resupload) && $resupload > 0)
{
if (image_format_supported($upload_dir . "/" . $_FILES['userfile']['name']) == 1)
{
// Create small thumbs for image (Ratio is near 16/9)
// Used on logon for example
$imgThumbSmall = vignette($upload_dir . "/" . $_FILES['userfile']['name'], $maxwidthsmall, $maxheightsmall, '_small', $quality, "thumbs");
// Create mini thumbs for image (Ratio is near 16/9)
// Used on menu or for setup page for example
$imgThumbMini = vignette($upload_dir . "/" . $_FILES['userfile']['name'], $maxwidthmini, $maxheightmini, '_mini', $quality, "thumbs");
}
$mesg = '<div class="ok">'.$langs->trans("FileTransferComplete").'</div>';
}
else
@@ -104,12 +114,13 @@ if ($action == 'confirm_deletefile' && $confirm == 'yes')
{
if ($object->fetch($id))
{
$langs->load("other");
$object->fetch_thirdparty();
$upload_dir = $conf->propal->dir_output . "/" . dol_sanitizeFileName($object->ref);
$file = $upload_dir . '/' . $_GET['urlfile']; // Do not use urldecode here ($_GET and $_REQUEST are already decoded by PHP).
$file = $upload_dir . '/' . GETPOST('urlfile'); // Do not use urldecode here ($_GET and $_REQUEST are already decoded by PHP).
dol_delete_file($file,0,0,0,$object);
$mesg = '<div class="ok">'.$langs->trans("FileWasRemoved").'</div>';
$mesg = '<div class="ok">'.$langs->trans("FileWasRemoved",GETPOST('urlfile')).'</div>';
}
}
@@ -181,13 +192,13 @@ if ($id > 0 || ! empty($ref))
*/
if ($action == 'delete')
{
$ret=$form->form_confirm($_SERVER["PHP_SELF"].'?id='.$id.'&urlfile='.urldecode($_GET["urlfile"]), $langs->trans('DeleteFile'), $langs->trans('ConfirmDeleteFile'), 'confirm_deletefile', '', 0, 1);
$ret=$form->form_confirm($_SERVER["PHP_SELF"].'?id='.$id.'&urlfile='.urlencode(GETPOST("urlfile")), $langs->trans('DeleteFile'), $langs->trans('ConfirmDeleteFile'), 'confirm_deletefile', '', 0, 1);
if ($ret == 'html') print '<br>';
}
// Affiche formulaire upload
$formfile=new FormFile($db);
$formfile->form_attach_new_file(DOL_URL_ROOT.'/comm/propal/document.php?id='.$object->id,'',0,0,$user->rights->propale->creer);
$formfile->form_attach_new_file(DOL_URL_ROOT.'/comm/propal/document.php?id='.$object->id,'',0,0,$user->rights->propale->creer,50,$object);
// List of document

View File

@@ -1,7 +1,7 @@
<?php
/* Copyright (C) 2003-2004 Rodolphe Quiedeville <rodolphe@quiedeville.org>
* Copyright (C) 2004-2011 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2005-2009 Regis Houssin <regis@dolibarr.fr>
* Copyright (C) 2005-2012 Regis Houssin <regis@dolibarr.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
@@ -48,9 +48,10 @@ if ($user->societe_id > 0)
*/
$propalstatic=new Propal($db);
$companystatic=new Societe($db);
$form = new Form($db);
$formfile = new FormFile($db);
$help_url="EN:Module_Commercial_Proposals|FR:Module_Propositions_commerciales|ES:Módulo Presupuestos";
$help_url="EN:Module_Commercial_Proposals|FR:Module_Propositions_commerciales|ES:Módulo_Presupuestos";
llxHeader("",$langs->trans("ProspectionArea"),$help_url);
@@ -155,7 +156,7 @@ else
*/
if ($conf->propal->enabled)
{
$sql = "SELECT c.rowid, c.ref, s.nom, s.rowid as socid";
$sql = "SELECT c.rowid, c.ref, s.nom as socname, s.rowid as socid, s.canvas, s.client";
$sql.= " FROM ".MAIN_DB_PREFIX."propal as c";
$sql.= ", ".MAIN_DB_PREFIX."societe as s";
if (!$user->rights->societe->client->voir && !$socid) $sql.= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc";
@@ -182,9 +183,18 @@ if ($conf->propal->enabled)
$var=!$var;
$obj = $db->fetch_object($resql);
print "<tr $bc[$var]>";
print '<td nowrap="nowrap">';
print "<a href=".DOL_URL_ROOT."/comm/propal.php?id=".$obj->rowid.">".img_object($langs->trans("ShowPropal"),"propal").' '.$obj->ref."</a></td>";
print '<td><a href="'.DOL_URL_ROOT.'/comm/fiche.php?socid='.$obj->socid.'">'.img_object($langs->trans("ShowCompany"),"company").' '.dol_trunc($obj->nom,24).'</a></td></tr>';
$propalstatic->id=$obj->rowid;
$propalstatic->ref=$obj->ref;
print '<td nowrap="nowrap">'.$propalstatic->getNomUrl(1).'</td>';
$companystatic->id=$obj->socid;
$companystatic->name=$obj->socname;
$companystatic->client=$obj->client;
$companystatic->canvas=$obj->canvas;
print '<td>'.$companystatic->getNomUrl(1,'customer',24).'</td>';
print '</tr>';
$i++;
}
}
@@ -201,7 +211,7 @@ $max=5;
* Last modified proposals
*/
$sql = "SELECT c.rowid, c.ref, c.fk_statut, s.nom, s.rowid as socid,";
$sql = "SELECT c.rowid, c.ref, c.fk_statut, s.nom as socname, s.rowid as socid, s.canvas, s.client,";
$sql.= " date_cloture as datec";
$sql.= " FROM ".MAIN_DB_PREFIX."propal as c";
$sql.= ", ".MAIN_DB_PREFIX."societe as s";
@@ -255,7 +265,12 @@ if ($resql)
print '</td>';
print '<td><a href="'.DOL_URL_ROOT.'/comm/fiche.php?socid='.$obj->socid.'">'.img_object($langs->trans("ShowCompany"),"company").' '.$obj->nom.'</a></td>';
$companystatic->id=$obj->socid;
$companystatic->name=$obj->socname;
$companystatic->client=$obj->client;
$companystatic->canvas=$obj->canvas;
print '<td>'.$companystatic->getNomUrl(1,'customer').'</td>';
print '<td>'.dol_print_date($db->jdate($obj->datec),'day').'</td>';
print '<td align="right">'.$propalstatic->LibStatut($obj->fk_statut,5).'</td>';
print '</tr>';
@@ -274,7 +289,7 @@ if ($conf->propal->enabled && $user->rights->propale->lire)
{
$langs->load("propal");
$sql = "SELECT s.nom, s.rowid, p.rowid as propalid, p.total as total_ttc, p.total_ht, p.ref, p.fk_statut, p.datep as dp";
$sql = "SELECT s.nom as socname, s.rowid as socid, s.canvas, s.client, p.rowid as propalid, p.total as total_ttc, p.total_ht, p.ref, p.fk_statut, p.datep as dp";
$sql.= " FROM ".MAIN_DB_PREFIX."societe as s";
$sql.= ", ".MAIN_DB_PREFIX."propal as p";
if (!$user->rights->societe->client->voir && !$socid) $sql.= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc";
@@ -325,7 +340,12 @@ if ($conf->propal->enabled && $user->rights->propale->lire)
print "</td>";
print '<td align="left"><a href="fiche.php?socid='.$obj->rowid.'">'.img_object($langs->trans("ShowCompany"),"company").' '.dol_trunc($obj->nom,44).'</a></td>'."\n";
$companystatic->id=$obj->socid;
$companystatic->name=$obj->socname;
$companystatic->client=$obj->client;
$companystatic->canvas=$obj->canvas;
print '<td align="left">'.$companystatic->getNomUrl(1,'customer',44).'</td>'."\n";
print '<td align="right">';
print dol_print_date($db->jdate($obj->dp),'day').'</td>'."\n";
print '<td align="right">'.price($obj->total_ttc).'</td>';

View File

@@ -1234,13 +1234,11 @@ class Commande extends CommonObject
$sql.= ', cr.code as cond_reglement_code, cr.libelle as cond_reglement_libelle, cr.libelle_facture as cond_reglement_libelle_doc';
$sql.= ', ca.code as availability_code';
$sql.= ', dr.code as demand_reason_code';
$sql.= ', el.fk_source';
$sql.= ' FROM '.MAIN_DB_PREFIX.'commande as c';
$sql.= ' LEFT JOIN '.MAIN_DB_PREFIX.'c_payment_term as cr ON (c.fk_cond_reglement = cr.rowid)';
$sql.= ' LEFT JOIN '.MAIN_DB_PREFIX.'c_paiement as p ON (c.fk_mode_reglement = p.id)';
$sql.= ' LEFT JOIN '.MAIN_DB_PREFIX.'c_availability as ca ON (c.fk_availability = ca.rowid)';
$sql.= ' LEFT JOIN '.MAIN_DB_PREFIX.'c_input_reason as dr ON (c.fk_demand_reason = ca.rowid)';
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."element_element as el ON el.fk_target = c.rowid AND el.targettype = '".$this->element."'";
$sql.= " WHERE c.entity = ".$conf->entity;
if ($id) $sql.= " AND c.rowid=".$id;
if ($ref) $sql.= " AND c.ref='".$this->db->escape($ref)."'";
@@ -1292,7 +1290,6 @@ class Commande extends CommonObject
$this->demand_reason_code = $obj->demand_reason_code;
$this->date_livraison = $this->db->jdate($obj->date_livraison);
$this->fk_delivery_address = $obj->fk_adresse_livraison;
$this->propale_id = $obj->fk_source;
$this->extraparams = (array) json_decode($obj->extraparams, true);
@@ -1302,22 +1299,6 @@ class Commande extends CommonObject
$this->db->free();
if ($this->propale_id)
{
$sqlp = "SELECT ref";
$sqlp.= " FROM ".MAIN_DB_PREFIX."propal";
$sqlp.= " WHERE rowid = ".$this->propale_id;
$resqlprop = $this->db->query($sqlp);
if ($resqlprop)
{
$objp = $this->db->fetch_object($resqlprop);
$this->propale_ref = $objp->ref;
$this->db->free($resqlprop);
}
}
/*
* Lines
*/
@@ -2304,7 +2285,7 @@ class Commande extends CommonObject
{
dol_delete_preview($this);
if (!dol_delete_file($file))
if (! dol_delete_file($file,0,0,0,$this)) // For triggers
{
$this->error=$langs->trans("ErrorCanNotDeleteFile",$file);
$this->db->rollback();
@@ -2313,7 +2294,7 @@ class Commande extends CommonObject
}
if (file_exists($dir))
{
if (!dol_delete_dir($dir))
if (! dol_delete_dir($dir))
{
$this->error=$langs->trans("ErrorCanNotDeleteDir",$dir);
$this->db->rollback();
@@ -2363,7 +2344,8 @@ class Commande extends CommonObject
$clause = " AND";
}
$sql.= $clause." c.entity = ".$conf->entity;
$sql.= " AND c.fk_statut IN (1,2,3) AND c.facture = 0";
//$sql.= " AND c.fk_statut IN (1,2,3) AND c.facture = 0";
$sql.= " AND ((c.fk_statut IN (1,2)) OR (c.fk_statut = 3 AND c.facture = 0))"; // If status is 2 and facture=1, it must be selected
if ($user->societe_id) $sql.=" AND c.fk_soc = ".$user->societe_id;
$resql=$this->db->query($sql);
@@ -2444,7 +2426,7 @@ class Commande extends CommonObject
if ($statut==-1) return img_picto($langs->trans('StatusOrderCanceled'),'statut5').' '.$langs->trans('StatusOrderCanceledShort');
if ($statut==0) return img_picto($langs->trans('StatusOrderDraft'),'statut0').' '.$langs->trans('StatusOrderDraftShort');
if ($statut==1) return img_picto($langs->trans('StatusOrderValidated'),'statut1').' '.$langs->trans('StatusOrderValidatedShort');
if ($statut==2) return img_picto($langs->trans('StatusOrderOnProcess'),'statut3').' '.$langs->trans('StatusOrderSentShort');
if ($statut==2) return img_picto($langs->trans('StatusOrderSent'),'statut3').' '.$langs->trans('StatusOrderSentShort');
if ($statut==3 && ! $facturee) return img_picto($langs->trans('StatusOrderToBill'),'statut7').' '.$langs->trans('StatusOrderToBillShort');
if ($statut==3 && $facturee) return img_picto($langs->trans('StatusOrderProcessed'),'statut6').' '.$langs->trans('StatusOrderProcessedShort');
}
@@ -2462,7 +2444,7 @@ class Commande extends CommonObject
if ($statut==-1) return img_picto($langs->trans('StatusOrderCanceled'),'statut5').' '.$langs->trans('StatusOrderCanceled');
if ($statut==0) return img_picto($langs->trans('StatusOrderDraft'),'statut0').' '.$langs->trans('StatusOrderDraft');
if ($statut==1) return img_picto($langs->trans('StatusOrderValidated'),'statut1').' '.$langs->trans('StatusOrderValidated');
if ($statut==2) return img_picto($langs->trans('StatusOrderSentShort'),'statut3').' '.$langs->trans('StatusOrderOnProcess');
if ($statut==2) return img_picto($langs->trans('StatusOrderSentShort'),'statut3').' '.$langs->trans('StatusOrderSent');
if ($statut==3 && ! $facturee) return img_picto($langs->trans('StatusOrderToBill'),'statut7').' '.$langs->trans('StatusOrderToBill');
if ($statut==3 && $facturee) return img_picto($langs->trans('StatusOrderProcessed'),'statut6').' '.$langs->trans('StatusOrderProcessed');
}
@@ -2471,7 +2453,7 @@ class Commande extends CommonObject
if ($statut==-1) return $langs->trans('StatusOrderCanceledShort').' '.img_picto($langs->trans('StatusOrderCanceled'),'statut5');
if ($statut==0) return $langs->trans('StatusOrderDraftShort').' '.img_picto($langs->trans('StatusOrderDraft'),'statut0');
if ($statut==1) return $langs->trans('StatusOrderValidatedShort').' '.img_picto($langs->trans('StatusOrderValidated'),'statut1');
if ($statut==2) return $langs->trans('StatusOrderSentShort').' '.img_picto($langs->trans('StatusOrderOnProcess'),'statut3');
if ($statut==2) return $langs->trans('StatusOrderSentShort').' '.img_picto($langs->trans('StatusOrderSent'),'statut3');
if ($statut==3 && ! $facturee) return $langs->trans('StatusOrderToBillShort').' '.img_picto($langs->trans('StatusOrderToBill'),'statut7');
if ($statut==3 && $facturee) return $langs->trans('StatusOrderProcessedShort').' '.img_picto($langs->trans('StatusOrderProcessed'),'statut6');
}

View File

@@ -28,8 +28,7 @@ include_once DOL_DOCUMENT_ROOT . "/fourn/class/fournisseur.commande.class.php";
/**
* \class CommandeStats
* \brief Classe permettant la gestion des stats des commandes
* Class to manage order statistics
*/
class CommandeStats extends Stats
{
@@ -66,7 +65,7 @@ class CommandeStats extends Stats
$this->from = MAIN_DB_PREFIX.$object->table_element." as c";
$this->from.= ", ".MAIN_DB_PREFIX."societe as s";
$this->field='total_ht';
$this->where.= " c.fk_statut > 0";
$this->where.= " c.fk_statut > 0"; // Not draft and not cancelled
}
if ($mode == 'supplier')
{
@@ -74,7 +73,7 @@ class CommandeStats extends Stats
$this->from = MAIN_DB_PREFIX.$object->table_element." as c";
$this->from.= ", ".MAIN_DB_PREFIX."societe as s";
$this->field='total_ht';
$this->where.= " c.fk_statut > 0";
$this->where.= " c.fk_statut > 0"; // Not draft and not cancelled
}
$this->where.= " AND c.fk_soc = s.rowid AND c.entity = ".$conf->entity;
@@ -97,10 +96,10 @@ class CommandeStats extends Stats
global $conf;
global $user;
$sql = "SELECT date_format(c.date_valid,'%m') as dm, count(*) nb";
$sql = "SELECT date_format(c.date_commande,'%m') as dm, count(*) nb";
$sql.= " FROM ".$this->from;
if (!$user->rights->societe->client->voir && !$this->socid) $sql .= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc";
$sql.= " WHERE date_format(c.date_valid,'%Y') = '".$year."'";
$sql.= " WHERE date_format(c.date_commande,'%Y') = '".$year."'";
$sql.= " AND ".$this->where;
$sql.= " GROUP BY dm";
$sql.= $this->db->order('dm','DESC');
@@ -119,7 +118,7 @@ class CommandeStats extends Stats
global $conf;
global $user;
$sql = "SELECT date_format(c.date_valid,'%Y') as dm, count(*), sum(c.".$this->field.")";
$sql = "SELECT date_format(c.date_commande,'%Y') as dm, count(*), sum(c.".$this->field.")";
$sql.= " FROM ".$this->from;
if (!$user->rights->societe->client->voir && !$this->socid) $sql .= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc";
$sql.= " WHERE ".$this->where;
@@ -140,10 +139,10 @@ class CommandeStats extends Stats
global $conf;
global $user;
$sql = "SELECT date_format(c.date_valid,'%m') as dm, sum(c.".$this->field.")";
$sql = "SELECT date_format(c.date_commande,'%m') as dm, sum(c.".$this->field.")";
$sql.= " FROM ".$this->from;
if (!$user->rights->societe->client->voir && !$this->socid) $sql .= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc";
$sql.= " WHERE date_format(c.date_valid,'%Y') = '".$year."'";
$sql.= " WHERE date_format(c.date_commande,'%Y') = '".$year."'";
$sql.= " AND ".$this->where;
$sql.= " GROUP BY dm";
$sql.= $this->db->order('dm','DESC');
@@ -162,10 +161,10 @@ class CommandeStats extends Stats
global $conf;
global $user;
$sql = "SELECT date_format(c.date_valid,'%m') as dm, avg(c.".$this->field.")";
$sql = "SELECT date_format(c.date_commande,'%m') as dm, avg(c.".$this->field.")";
$sql.= " FROM ".$this->from;
if (!$user->rights->societe->client->voir && !$this->socid) $sql .= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc";
$sql.= " WHERE date_format(c.date_valid,'%Y') = '".$year."'";
$sql.= " WHERE date_format(c.date_commande,'%Y') = '".$year."'";
$sql.= " AND ".$this->where;
$sql.= " GROUP BY dm";
$sql.= $this->db->order('dm','DESC');
@@ -182,7 +181,7 @@ class CommandeStats extends Stats
{
global $user;
$sql = "SELECT date_format(c.date_valid,'%Y') as year, count(*) as nb, sum(c.".$this->field.") as total, avg(".$this->field.") as avg";
$sql = "SELECT date_format(c.date_commande,'%Y') as year, count(*) as nb, sum(c.".$this->field.") as total, avg(".$this->field.") as avg";
$sql.= " FROM ".$this->from;
if (!$user->rights->societe->client->voir && !$this->socid) $sql .= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc";
$sql.= " WHERE ".$this->where;

View File

@@ -27,6 +27,7 @@
require("../main.inc.php");
require_once(DOL_DOCUMENT_ROOT.'/core/lib/order.lib.php');
require_once(DOL_DOCUMENT_ROOT."/core/lib/files.lib.php");
require_once(DOL_DOCUMENT_ROOT."/core/lib/images.lib.php");
require_once(DOL_DOCUMENT_ROOT."/core/class/html.formfile.class.php");
require_once(DOL_DOCUMENT_ROOT ."/commande/class/commande.class.php");
@@ -77,9 +78,18 @@ if ($_POST["sendit"] && ! empty($conf->global->MAIN_UPLOAD_DOC))
if (dol_mkdir($upload_dir) >= 0)
{
$resupload=dol_move_uploaded_file($_FILES['userfile']['tmp_name'], $upload_dir . "/" . $_FILES['userfile']['name'],0,0,$_FILES['userfile']['error']);
$resupload=dol_move_uploaded_file($_FILES['userfile']['tmp_name'], $upload_dir . "/" . dol_unescapefile($_FILES['userfile']['name']),0,0,$_FILES['userfile']['error']);
if (is_numeric($resupload) && $resupload > 0)
{
if (image_format_supported($upload_dir . "/" . $_FILES['userfile']['name']) == 1)
{
// Create small thumbs for image (Ratio is near 16/9)
// Used on logon for example
$imgThumbSmall = vignette($upload_dir . "/" . $_FILES['userfile']['name'], $maxwidthsmall, $maxheightsmall, '_small', $quality, "thumbs");
// Create mini thumbs for image (Ratio is near 16/9)
// Used on menu or for setup page for example
$imgThumbMini = vignette($upload_dir . "/" . $_FILES['userfile']['name'], $maxwidthmini, $maxheightmini, '_mini', $quality, "thumbs");
}
$mesg = '<div class="ok">'.$langs->trans("FileTransferComplete").'</div>';
}
else
@@ -107,12 +117,13 @@ if ($action == 'confirm_deletefile' && $confirm == 'yes')
{
if ($object->fetch($id))
{
$langs->load("other");
$object->fetch_thirdparty();
$upload_dir = $conf->commande->dir_output . "/" . dol_sanitizeFileName($object->ref);
$file = $upload_dir . '/' . $_GET['urlfile']; // Do not use urldecode here ($_GET and $_REQUEST are already decoded by PHP).
$file = $upload_dir . '/' . GETPOST('urlfile'); // Do not use urldecode here ($_GET and $_REQUEST are already decoded by PHP).
dol_delete_file($file,0,0,0,$object);
$mesg = '<div class="ok">'.$langs->trans("FileWasRemoved").'</div>';
$mesg = '<div class="ok">'.$langs->trans("FileWasRemoved",GETPOST('urlfile')).'</div>';
}
}
@@ -166,13 +177,13 @@ if ($id > 0 || ! empty($ref))
*/
if ($action == 'delete')
{
$ret=$form->form_confirm($_SERVER["PHP_SELF"].'?id='.$id.'&urlfile='.urldecode($_GET["urlfile"]), $langs->trans('DeleteFile'), $langs->trans('ConfirmDeleteFile'), 'confirm_deletefile', '', 0, 1);
$ret=$form->form_confirm($_SERVER["PHP_SELF"].'?id='.$id.'&urlfile='.urlencode($_GET["urlfile"]), $langs->trans('DeleteFile'), $langs->trans('ConfirmDeleteFile'), 'confirm_deletefile', '', 0, 1);
if ($ret == 'html') print '<br>';
}
// Affiche formulaire upload
$formfile=new FormFile($db);
$formfile->form_attach_new_file(DOL_URL_ROOT.'/commande/document.php?id='.$object->id,'',0,0,$user->rights->commande->creer);
$formfile->form_attach_new_file(DOL_URL_ROOT.'/commande/document.php?id='.$object->id,'',0,0,$user->rights->commande->creer,50,$object);
// List of document

View File

@@ -58,12 +58,18 @@ $confirm = GETPOST('confirm');
$lineid = GETPOST('lineid');
$mesg = GETPOST('mesg');
$object = new Commande($db);
// Security check
if ($user->societe_id) $socid=$user->societe_id;
$result=restrictedArea($user,'commande',$id,'');
$object = new Commande($db);
// Load object
if ($id > 0 || ! empty($ref))
{
$ret=$object->fetch($id, $ref);
}
// Initialize technical object to manage hooks of thirdparties. Note that conf->hooks_modules contains array array
include_once(DOL_DOCUMENT_ROOT.'/core/class/hookmanager.class.php');
$hookmanager=new HookManager($db);
@@ -128,6 +134,7 @@ else if ($action == 'confirm_delete' && $confirm == 'yes')
if ($user->rights->commande->supprimer)
{
$object->fetch($id);
$object->fetch_thirdparty();
$result=$object->delete($user);
if ($result > 0)
{
@@ -464,7 +471,28 @@ else if ($action == 'setconditions' && $user->rights->commande->creer)
{
$object->fetch($id);
$result=$object->setPaymentTerms(GETPOST('cond_reglement_id','int'));
if ($result < 0) dol_print_error($db,$object->error);
if ($result < 0)
{
dol_print_error($db,$object->error);
}
else
{
if (empty($conf->global->MAIN_DISABLE_PDF_AUTOUPDATE))
{
// Define output language
$outputlangs = $langs;
$newlang=GETPOST('lang_id','alpha');
if ($conf->global->MAIN_MULTILANGS && empty($newlang)) $newlang=$object->client->default_lang;
if (! empty($newlang))
{
$outputlangs = new Translate("",$conf);
$outputlangs->setDefaultLang($newlang);
}
$ret=$object->fetch($id); // Reload to get new records
commande_pdf_create($db, $object, $object->modelpdf, $outputlangs, GETPOST('hidedetails'), GETPOST('hidedesc'), GETPOST('hideref'), $hookmanager);
}
}
}
else if ($action == 'setremisepercent' && $user->rights->commande->creer)
@@ -996,10 +1024,11 @@ else if ($action == 'remove_file')
{
require_once(DOL_DOCUMENT_ROOT."/core/lib/files.lib.php");
$langs->load("other");
$upload_dir = $conf->commande->dir_output;
$file = $upload_dir . '/' . $_GET['file'];
$file = $upload_dir . '/' . GETPOST('file');
dol_delete_file($file);
$mesg = '<div class="ok">'.$langs->trans("FileWasRemoved").'</div>';
$mesg = '<div class="ok">'.$langs->trans("FileWasRemoved",GETPOST('file')).'</div>';
}
}

View File

@@ -49,7 +49,7 @@ if ($user->societe_id > 0)
$commandestatic=new Commande($db);
$form = new Form($db);
$formfile = new FormFile($db);
$help_url="EN:Module_Customers_Orders|FR:Module_Commandes_Clients|ES:Módulo Pedidos de clientes";
$help_url="EN:Module_Customers_Orders|FR:Module_Commandes_Clients|ES:Módulo_Pedidos_de_clientes";
llxHeader("",$langs->trans("Orders"),$help_url);

View File

@@ -1,6 +1,6 @@
<?php
/* Copyright (C) 2001-2005 Rodolphe Quiedeville <rodolphe@quiedeville.org>
* Copyright (C) 2004-2011 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2004-2012 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2005 Marc Barilley / Ocebo <marc@ocebo.com>
* Copyright (C) 2005-2012 Regis Houssin <regis@dolibarr.fr>
*
@@ -108,12 +108,13 @@ if ($viewstatut <> '')
}
if ($viewstatut == -2) // To process
{
$sql .= ' AND c.fk_statut IN (1,2,3) AND c.facture = 0';
//$sql.= ' AND c.fk_statut IN (1,2,3) AND c.facture = 0';
$sql.= " AND ((c.fk_statut IN (1,2)) OR (c.fk_statut = 3 AND c.facture = 0))"; // If status is 2 and facture=1, it must be selected
}
}
if ($ordermonth > 0)
{
$sql.= " AND date_format(c.date_valid, '%Y-%m') = '".$orderyear."-".$ordermonth."'";
$sql.= " AND date_format(c.date_valid, '%Y-%m') = '".$orderyear."-".$ordermonth."'"; // TODO do not use date_format but a between
}
if ($orderyear > 0)
{
@@ -178,7 +179,7 @@ if ($resql)
print_liste_field_titre($langs->trans('RefCustomerOrder'),'liste.php','c.ref_client','','&amp;socid='.$socid.'&amp;viewstatut='.$viewstatut,'',$sortfield,$sortorder);
print_liste_field_titre($langs->trans('OrderDate'),'liste.php','c.date_commande','','&amp;socid='.$socid.'&amp;viewstatut='.$viewstatut, 'align="right"',$sortfield,$sortorder);
print_liste_field_titre($langs->trans('DeliveryDate'),'liste.php','c.date_livraison','','&amp;socid='.$socid.'&amp;viewstatut='.$viewstatut, 'align="right"',$sortfield,$sortorder);
print_liste_field_titre($langs->trans('Status'),'liste.php','c.fk_statut','','&amp;socid='.$socid.'&amp;viewstatut='.$viewstatut,'align="center"',$sortfield,$sortorder);
print_liste_field_titre($langs->trans('Status'),'liste.php','c.fk_statut','','&amp;socid='.$socid.'&amp;viewstatut='.$viewstatut,'align="right"',$sortfield,$sortorder);
print '</tr>';
// Lignes des champs de filtre
print '<form method="get" action="liste.php">';

View File

@@ -75,7 +75,7 @@ if ($action == 'confirm_delete_categ' && $confirm == "yes" && $user->rights->ban
}
}
if ($action == 'class')
if ($user->rights->banque->modifier && $action == 'class')
{
$sql = "DELETE FROM ".MAIN_DB_PREFIX."bank_class WHERE lineid = ".$rowid." AND fk_categ = ".$_POST["cat1"];
if (! $db->query($sql))
@@ -90,7 +90,7 @@ if ($action == 'class')
}
}
if ($action == "update")
if ($user->rights->banque->modifier && $action == "update")
{
$error=0;
@@ -584,8 +584,11 @@ print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
print '<input type="hidden" name="action" value="class">';
print '<input type="hidden" name="orig_account" value="'.$orig_account.'">';
print '<tr class="liste_titre"><td>'.$langs->trans("Rubriques").'</td><td colspan="2">';
print '<select class="flat" name="cat1">'.$options.'</select>&nbsp;';
print '<input type="submit" class="button" value="'.$langs->trans("Add").'"></td>';
if ($user->rights->banque->modifier)
{
print '<select class="flat" name="cat1">'.$options.'</select>&nbsp;';
print '<input type="submit" class="button" value="'.$langs->trans("Add").'"></td>';
}
print "</tr>";
print "</form>";

View File

@@ -81,6 +81,12 @@ $usehm=$conf->global->MAIN_USE_HOURMIN_IN_DATE_RANGE;
$object=new Facture($db);
// Load object
if ($id > 0 || ! empty($ref))
{
$ret=$object->fetch($id, $ref);
}
// Initialize technical object to manage hooks of thirdparties. Note that conf->hooks_modules contains array array
include_once(DOL_DOCUMENT_ROOT.'/core/class/hookmanager.class.php');
$hookmanager=new HookManager($db);
@@ -144,6 +150,7 @@ else if ($action == 'reopen' && $user->rights->facture->creer)
else if ($action == 'confirm_delete' && $confirm == 'yes' && $user->rights->facture->supprimer)
{
$result = $object->fetch($id);
$object->fetch_thirdparty();
$result = $object->delete();
if ($result > 0)
{
@@ -1112,7 +1119,7 @@ else if (($action == 'addline' || $action == 'addline_predef') && $user->rights-
unset($_POST['qty']);
unset($_POST['type']);
unset($_POST['idprod']);
unset($_POST['remmise_percent']);
unset($_POST['remise_percent']);
unset($_POST['dp_desc']);
unset($_POST['np_desc']);
unset($_POST['np_price']);
@@ -3256,7 +3263,7 @@ else
if ($userid)
{
if ($userid == -1) $sql.=' AND f.fk_user_author IS NULL';
else $sql.=' AND f.fk_user_author = '.$user->id;
else $sql.=' AND f.fk_user_author = '.$userid;
}
if ($_GET['filtre'])
{

View File

@@ -1166,6 +1166,7 @@ class Facture extends CommonObject
function delete($rowid=0, $notrigger=0)
{
global $user,$langs,$conf;
require_once(DOL_DOCUMENT_ROOT."/core/lib/files.lib.php");
if (! $rowid) $rowid=$this->id;
@@ -1236,6 +1237,34 @@ class Facture extends CommonObject
$resql=$this->db->query($sql);
if ($resql)
{
// On efface le repertoire de pdf provisoire
$ref = dol_sanitizeFileName($this->ref);
if ($conf->facture->dir_output)
{
$dir = $conf->facture->dir_output . "/" . $ref;
$file = $conf->facture->dir_output . "/" . $ref . "/" . $ref . ".pdf";
if (file_exists($file)) // We must delete all files before deleting directory
{
$ret=dol_delete_preview($this);
if (! dol_delete_file($file,0,0,0,$this)) // For triggers
{
$this->error=$langs->trans("ErrorCanNotDeleteFile",$file);
$this->db->rollback();
return 0;
}
}
if (file_exists($dir))
{
if (! dol_delete_dir_recursive($dir)) // For remove dir and meta
{
$this->error=$langs->trans("ErrorCanNotDeleteDir",$dir);
$this->db->rollback();
return 0;
}
}
}
$this->db->commit();
return 1;
}
@@ -1519,7 +1548,7 @@ class Facture extends CommonObject
$now=dol_now();
$error=0;
dol_syslog(get_class($this).'::validate force_number='.$force_number,' idwarehouse='.$idwarehouse, LOG_WARNING);
dol_syslog(get_class($this).'::validate force_number='.$force_number.', idwarehouse='.$idwarehouse, LOG_WARNING);
// Check parameters
if (! $this->brouillon)

View File

@@ -29,6 +29,7 @@ require_once(DOL_DOCUMENT_ROOT."/compta/facture/class/facture.class.php");
require_once(DOL_DOCUMENT_ROOT.'/core/class/discount.class.php');
require_once(DOL_DOCUMENT_ROOT."/core/lib/invoice.lib.php");
require_once(DOL_DOCUMENT_ROOT."/core/lib/files.lib.php");
require_once(DOL_DOCUMENT_ROOT."/core/lib/images.lib.php");
require_once(DOL_DOCUMENT_ROOT."/core/class/html.formfile.class.php");
$langs->load('propal');
@@ -79,9 +80,18 @@ if ($_POST["sendit"] && ! empty($conf->global->MAIN_UPLOAD_DOC))
if (dol_mkdir($upload_dir) >= 0)
{
$resupload=dol_move_uploaded_file($_FILES['userfile']['tmp_name'], $upload_dir . "/" . $_FILES['userfile']['name'],0,0,$_FILES['userfile']['error']);
$resupload=dol_move_uploaded_file($_FILES['userfile']['tmp_name'], $upload_dir . "/" . dol_unescapefile($_FILES['userfile']['name']),0,0,$_FILES['userfile']['error']);
if (is_numeric($resupload) && $resupload > 0)
{
if (image_format_supported($upload_dir . "/" . $_FILES['userfile']['name']) == 1)
{
// Create small thumbs for image (Ratio is near 16/9)
// Used on logon for example
$imgThumbSmall = vignette($upload_dir . "/" . $_FILES['userfile']['name'], $maxwidthsmall, $maxheightsmall, '_small', $quality, "thumbs");
// Create mini thumbs for image (Ratio is near 16/9)
// Used on menu or for setup page for example
$imgThumbMini = vignette($upload_dir . "/" . $_FILES['userfile']['name'], $maxwidthmini, $maxheightmini, '_mini', $quality, "thumbs");
}
$mesg = '<div class="ok">'.$langs->trans("FileTransferComplete").'</div>';
}
else
@@ -109,12 +119,13 @@ if ($action == 'confirm_deletefile' && $confirm == 'yes')
{
if ($object->fetch($id))
{
$langs->load("other");
$object->fetch_thirdparty();
$upload_dir = $conf->facture->dir_output . "/" . dol_sanitizeFileName($object->ref);
$file = $upload_dir . '/' . $_GET['urlfile']; // Do not use urldecode here ($_GET and $_REQUEST are already decoded by PHP).
$file = $upload_dir . '/' . GETPOST('urlfile'); // Do not use urldecode here ($_GET and $_REQUEST are already decoded by PHP).
dol_delete_file($file,0,0,0,$object);
$mesg = '<div class="ok">'.$langs->trans("FileWasRemoved").'</div>';
$mesg = '<div class="ok">'.$langs->trans("FileWasRemoved",GETPOST('urlfile')).'</div>';
}
}
@@ -184,14 +195,14 @@ if ($id > 0 || ! empty($ref))
*/
if ($action == 'delete')
{
$ret=$form->form_confirm($_SERVER["PHP_SELF"].'?facid='.$id.'&urlfile='.urldecode($_GET["urlfile"]), $langs->trans('DeleteFile'), $langs->trans('ConfirmDeleteFile'), 'confirm_deletefile', '', 0, 1);
$ret=$form->form_confirm($_SERVER["PHP_SELF"].'?facid='.$id.'&urlfile='.urlencode(GETPOST("urlfile")), $langs->trans('DeleteFile'), $langs->trans('ConfirmDeleteFile'), 'confirm_deletefile', '', 0, 1);
if ($ret == 'html') print '<br>';
}
// Affiche formulaire upload
$formfile=new FormFile($db);
$formfile->form_attach_new_file(DOL_URL_ROOT.'/compta/facture/document.php?facid='.$object->id,'',0,0,$user->rights->facture->creer);
$formfile->form_attach_new_file(DOL_URL_ROOT.'/compta/facture/document.php?facid='.$object->id,'',0,0,$user->rights->facture->creer,50,$object);
// List of document

View File

@@ -1,7 +1,7 @@
<?php
/* Copyright (C) 2002-2003 Rodolphe Quiedeville <rodolphe@quiedeville.org>
* Copyright (C) 2004-2010 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2005-2010 Regis Houssin <regis@dolibarr.fr>
* Copyright (C) 2005-2012 Regis Houssin <regis@dolibarr.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
@@ -58,7 +58,7 @@ $sortfield="f.datef";
// Create predefined invoice
if ($_POST["action"] == 'add')
if ($action == 'add')
{
$facturerec = new FactureRec($db);
$facturerec->titre = $_POST["titre"];
@@ -71,17 +71,16 @@ if ($_POST["action"] == 'add')
}
else
{
$_GET["action"] = "create";
$_GET["facid"] = $_POST["facid"];
$action = "create";
$mesg = '<div class="error">'.$facturerec->error.'</div>';
}
}
// Suppression
if ($_REQUEST["action"] == 'delete' && $user->rights->facture->supprimer)
if ($action == 'delete' && $user->rights->facture->supprimer)
{
$facrec = new FactureRec($db);
$facrec->fetch(GETPOST('facid','int'));
$facrec->fetch($facid);
$facrec->delete();
$facid = 0 ;
}
@@ -99,7 +98,7 @@ $form = new Form($db);
/*
* Create mode
*/
if ($_GET["action"] == 'create')
if ($action == 'create')
{
print_fiche_titre($langs->trans("CreateRepeatableInvoice"));
@@ -108,7 +107,7 @@ if ($_GET["action"] == 'create')
$facture = new Facture($db); // Source invoice
$product_static=new Product($db);
if ($facture->fetch($_GET["facid"]) > 0)
if ($facture->fetch($facid) > 0)
{
print '<form action="fiche-rec.php" method="post">';
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';

View File

@@ -75,7 +75,7 @@ if ($action == 'add_paiement' || ($action == 'confirm_paiement' && $confirm=='ye
if (substr($key,0,7) == 'amount_')
{
$cursorfacid = substr($key,7);
$amounts[$cursorfacid] = price2num($_POST[$key]);
$amounts[$cursorfacid] = price2num(trim($_POST[$key]));
$totalpaiement = $totalpaiement + $amounts[$cursorfacid];
$tmpfacture=new Facture($db);
$tmpfacture->fetch($cursorfacid);

View File

@@ -1,7 +1,7 @@
<?php
/* Copyright (C) 2004-2005 Rodolphe Quiedeville <rodolphe@quiedeville.org>
* Copyright (C) 2005-2010 Regis Houssin <regis@dolibarr.fr>
* Copyright (C) 2010-2011 Juanjo Menent <jmenent@2byte.es>
* Copyright (C) 2010-2012 Juanjo Menent <jmenent@2byte.es>
*
* 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
@@ -27,7 +27,7 @@ require_once(DOL_DOCUMENT_ROOT."/core/class/commonobject.class.php");
require_once(DOL_DOCUMENT_ROOT."/compta/facture/class/facture.class.php");
require_once(DOL_DOCUMENT_ROOT."/societe/class/societe.class.php");
require_once(DOL_DOCUMENT_ROOT.'/compta/paiement/class/paiement.class.php');
if ($conf->esaeb->enabled) require_once(DOL_DOCUMENT_ROOT.'/esaeb/class/esaeb19.class.php');
if ($conf->esaeb->enabled) dol_include_once('/esaeb/class/esaeb19.class.php');
/**

View File

@@ -67,7 +67,7 @@ if ($action == 'infotrans' && $user->rights->prelevement->bons->send)
{
$dir = $conf->prelevement->dir_output.'/receipts';
if (dol_move_uploaded_file($_FILES['userfile']['tmp_name'], $dir . "/" . $_FILES['userfile']['name'],1) > 0)
if (dol_move_uploaded_file($_FILES['userfile']['tmp_name'], $dir . "/" . dol_unescapefile($_FILES['userfile']['name']),1) > 0)
{
$dt = dol_mktime(12,0,0,GETPOST('remonth','int'),GETPOST('reday','int'),GETPOST('reyear','int'));

View File

@@ -73,20 +73,17 @@ $modulepart='tax';
if (GETPOST("sendit") && ! empty($conf->global->MAIN_UPLOAD_DOC))
{
require_once(DOL_DOCUMENT_ROOT."/core/lib/files.lib.php");
if (dol_mkdir($upload_dir) >= 0)
{
$resupload=dol_move_uploaded_file($_FILES['userfile']['tmp_name'], $upload_dir . "/" . $_FILES['userfile']['name'],0,0,$_FILES['userfile']['error']);
$resupload=dol_move_uploaded_file($_FILES['userfile']['tmp_name'], $upload_dir . "/" . dol_unescapefile($_FILES['userfile']['name']),0,0,$_FILES['userfile']['error']);
if (is_numeric($resupload) && $resupload > 0)
{
if (image_format_supported($upload_dir . "/" . $_FILES['userfile']['name']) == 1)
{
// Create small thumbs for company (Ratio is near 16/9)
// Create small thumbs for image (Ratio is near 16/9)
// Used on logon for example
$imgThumbSmall = vignette($upload_dir . "/" . $_FILES['userfile']['name'], $maxwidthsmall, $maxheightsmall, '_small', $quality, "thumbs");
// Create mini thumbs for company (Ratio is near 16/9)
// Create mini thumbs for image (Ratio is near 16/9)
// Used on menu or for setup page for example
$imgThumbMini = vignette($upload_dir . "/" . $_FILES['userfile']['name'], $maxwidthmini, $maxheightmini, '_mini', $quality, "thumbs");
}

View File

@@ -1,42 +0,0 @@
<?php
/* Copyright (C) 2010 Regis Houssin <regis@dolibarr.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
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/**
* \file htdocs/contact/canvas/default/dao_contact_default.class.php
* \ingroup thirdparty
* \brief Fichier de la classe des contacts par defaut
*/
/**
* \class DaoContactDefault
* \brief Classe permettant la gestion des contacts par defaut, cette classe surcharge la classe contact
*/
class DaoContactDefault extends Contact
{
/**
* Constructor
*
* @param DoliDB $DB Handler acces base de donnees
*/
function DaoContactDefault($DB)
{
$this->db = $DB;
}
}
?>

View File

@@ -22,6 +22,10 @@
<?php
print_fiche_titre($this->control->tpl['title']);
dol_htmloutput_errors((is_numeric($object->error)?'':$object->error),$object->errors);
dol_htmloutput_errors((is_numeric($GLOBALS['error'])?'':$GLOBALS['error']),$GLOBALS['errors']);
dol_htmloutput_errors($this->control->tpl['error'],$this->control->tpl['errors']);
echo $this->control->tpl['ajax_selectcountry']; ?>
@@ -40,7 +44,7 @@ echo $this->control->tpl['ajax_selectcountry']; ?>
<tr>
<td width="15%" class="fieldrequired"><?php echo $langs->trans("Lastname").' / '.$langs->trans("Label"); ?></td>
<td><input name="name" type="text" size="30" maxlength="80" value="<?php echo $this->control->tpl['name']; ?>"></td>
<td><input name="lastname" type="text" size="30" maxlength="80" value="<?php echo $this->control->tpl['name']; ?>"></td>
<td width="20%"><?php echo $langs->trans("Firstname"); ?></td>
<td width="25%"><input name="firstname" type="text" size="30" maxlength="80" value="<?php echo $this->control->tpl['firstname']; ?>"></td>
</tr>

View File

@@ -53,7 +53,7 @@ echo $this->control->tpl['ajax_selectcountry'];
<tr>
<td width="15%" class="fieldrequired"><?php echo $langs->trans("Lastname").' / '.$langs->trans("Label"); ?></td>
<td><input name="name" type="text" size="30" maxlength="80" value="<?php echo $this->control->tpl['name']; ?>"></td>
<td><input name="lastname" type="text" size="30" maxlength="80" value="<?php echo $this->control->tpl['name']; ?>"></td>
<td width="20%"><?php echo $langs->trans("Firstname"); ?></td>
<td width="25%"><input name="firstname" type="text" size="30" maxlength="80" value="<?php echo $this->control->tpl['firstname']; ?>"></td>
</tr>

View File

@@ -131,7 +131,7 @@ class Contact extends CommonObject
$sql.= "'".$this->db->idate($now)."',";
if ($this->socid > 0) $sql.= " ".$this->socid.",";
else $sql.= "null,";
$sql.= "'".$this->db->escape($this->name)."',";
$sql.= "'".$this->db->escape($this->lastname)."',";
$sql.= "'".$this->db->escape($this->firstname)."',";
$sql.= " ".($user->id > 0 ? "'".$user->id."'":"null").",";
$sql.= " ".$this->priv.",";
@@ -330,7 +330,7 @@ class Contact extends CommonObject
// Fields
if ($this->fullname && $conf->global->LDAP_CONTACT_FIELD_FULLNAME) $info[$conf->global->LDAP_CONTACT_FIELD_FULLNAME] = $this->fullname;
if ($this->name && $conf->global->LDAP_CONTACT_FIELD_NAME) $info[$conf->global->LDAP_CONTACT_FIELD_NAME] = $this->name;
if ($this->lastname && $conf->global->LDAP_CONTACT_FIELD_NAME) $info[$conf->global->LDAP_CONTACT_FIELD_NAME] = $this->lastname;
if ($this->firstname && $conf->global->LDAP_CONTACT_FIELD_FIRSTNAME) $info[$conf->global->LDAP_CONTACT_FIELD_FIRSTNAME] = $this->firstname;
if ($this->poste) $info["title"] = $this->poste;
@@ -744,6 +744,7 @@ class Contact extends CommonObject
else
{
$this->db->rollback();
dol_syslog("Error ".$this->error,LOG_ERR);
return -1;
}
}
@@ -1012,7 +1013,7 @@ class Contact extends CommonObject
// Initialise parameters
$this->id=0;
$this->specimen=1;
$this->name = 'DOLIBARR';
$this->lastname = 'DOLIBARR';
$this->firstname = 'SPECIMEN';
$this->address = '61 jump street';
$this->zip = '75000';

View File

@@ -1,6 +1,6 @@
<?php
/* Copyright (C) 2004-2005 Rodolphe Quiedeville <rodolphe@quiedeville.org>
* Copyright (C) 2004-2011 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2004-2012 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2004 Benoit Mortier <benoit.mortier@opensides.be>
* Copyright (C) 2005-2012 Regis Houssin <regis@dolibarr.fr>
* Copyright (C) 2007 Franky Van Liedekerke <franky.van.liedekerke@telenet.be>
@@ -165,7 +165,7 @@ if (empty($reshook))
$id = $object->create($user);
if ($id <= 0)
{
$error++; $errors[]=($object->error?array($object->error):$object->errors);
$error++; $errors=array_merge($errors,($object->error?array($object->error):$object->errors));
$action = 'create';
}
}
@@ -199,7 +199,7 @@ if (empty($reshook))
}
else
{
$error=$object->error; $errors[]=$object->errors;
$error=$object->error; $errors=$object->errors;
}
}
@@ -355,7 +355,7 @@ else
print_fiche_titre($title);
// Affiche les erreurs
dol_htmloutput_errors($error,$errors);
dol_htmloutput_errors(is_numeric($error)?'':$error,$errors);
if ($conf->use_javascript_ajax)
{
@@ -689,7 +689,7 @@ else
}
}
if (! empty($id) && $action != 'edit')
if (! empty($id) && $action != 'edit' && $action != 'create')
{
$objsoc = new Societe($db);

View File

@@ -32,6 +32,8 @@ $langs->load("companies");
$langs->load("ldap");
$langs->load("admin");
$action=GETPOST('action');
// Security check
$contactid = isset($_GET["id"])?$_GET["id"]:'';
if ($user->societe_id) $socid=$user->societe_id;
@@ -45,7 +47,7 @@ $contact->fetch($_GET["id"], $user);
* Actions
*/
if ($_GET["action"] == 'dolibarr2ldap')
if ($action == 'dolibarr2ldap')
{
$message="";
@@ -133,7 +135,7 @@ print '</table>';
print '</div>';
if ($message) { print $message; }
dol_htmloutput_mesg($message);
/*

View File

@@ -324,7 +324,11 @@ class Contrat extends CommonObject
$sql.= " fk_commercial_signature, fk_commercial_suivi,";
$sql.= " note as note_private, note_public, extraparams";
$sql.= " FROM ".MAIN_DB_PREFIX."contrat";
if ($ref) $sql.= " WHERE ref='".$ref."'";
if ($ref)
{
$sql.= " WHERE ref='".$ref."'";
$sql.= " AND entity IN (".getEntity('contract').")";
}
else $sql.= " WHERE rowid=".$id;
dol_syslog(get_class($this)."::fetch sql=".$sql, LOG_DEBUG);
@@ -622,13 +626,14 @@ class Contrat extends CommonObject
// Insert contract
$sql = "INSERT INTO ".MAIN_DB_PREFIX."contrat (datec, fk_soc, fk_user_author, date_contrat,";
$sql.= " fk_commercial_signature, fk_commercial_suivi, fk_projet,";
$sql.= " ref)";
$sql.= " ref, entity)";
$sql.= " VALUES (".$this->db->idate(mktime()).",".$this->socid.",".$user->id;
$sql.= ",".$this->db->idate($this->date_contrat);
$sql.= ",".($this->commercial_signature_id>0?$this->commercial_signature_id:"NULL");
$sql.= ",".($this->commercial_suivi_id>0?$this->commercial_suivi_id:"NULL");
$sql.= ",".($this->fk_projet>0?$this->fk_projet:"NULL");
$sql .= ", " . (dol_strlen($this->ref)<=0 ? "null" : "'".$this->ref."'");
$sql.= ", ".(dol_strlen($this->ref)<=0 ? "null" : "'".$this->ref."'");
$sql.= ", ".$conf->entity;
$sql.= ")";
$resql=$this->db->query($sql);
if ($resql)

View File

@@ -29,6 +29,7 @@ require ("../main.inc.php");
require_once(DOL_DOCUMENT_ROOT."/core/lib/contract.lib.php");
require_once(DOL_DOCUMENT_ROOT."/contrat/class/contrat.class.php");
require_once(DOL_DOCUMENT_ROOT."/core/lib/files.lib.php");
require_once(DOL_DOCUMENT_ROOT."/core/lib/images.lib.php");
require_once(DOL_DOCUMENT_ROOT."/core/class/html.formfile.class.php");
$langs->load("other");
@@ -69,13 +70,20 @@ $modulepart='contract';
*/
if ($_POST["sendit"] && ! empty($conf->global->MAIN_UPLOAD_DOC))
{
require_once(DOL_DOCUMENT_ROOT."/core/lib/files.lib.php");
if (dol_mkdir($upload_dir) >= 0)
{
$resupload=dol_move_uploaded_file($_FILES['userfile']['tmp_name'], $upload_dir . "/" . $_FILES['userfile']['name'],0,0,$_FILES['userfile']['error']);
$resupload=dol_move_uploaded_file($_FILES['userfile']['tmp_name'], $upload_dir . "/" . dol_unescapefile($_FILES['userfile']['name']),0,0,$_FILES['userfile']['error']);
if (is_numeric($resupload) && $resupload > 0)
{
if (image_format_supported($upload_dir . "/" . $_FILES['userfile']['name']) == 1)
{
// Create small thumbs for image (Ratio is near 16/9)
// Used on logon for example
$imgThumbSmall = vignette($upload_dir . "/" . $_FILES['userfile']['name'], $maxwidthsmall, $maxheightsmall, '_small', $quality, "thumbs");
// Create mini thumbs for image (Ratio is near 16/9)
// Used on menu or for setup page for example
$imgThumbMini = vignette($upload_dir . "/" . $_FILES['userfile']['name'], $maxwidthmini, $maxheightmini, '_mini', $quality, "thumbs");
}
$mesg = '<div class="ok">'.$langs->trans("FileTransferComplete").'</div>';
}
else
@@ -156,7 +164,7 @@ if ($contrat->id)
// Affiche formulaire upload
$formfile=new FormFile($db);
$formfile->form_attach_new_file(DOL_URL_ROOT.'/contrat/document.php?id='.$contrat->id,'',0,0,$user->rights->contrat->creer);
$formfile->form_attach_new_file(DOL_URL_ROOT.'/contrat/document.php?id='.$contrat->id,'',0,0,$user->rights->contrat->creer,50,$object);
// List of document

View File

@@ -1254,14 +1254,13 @@ else
print '<input type="hidden" name="mode" value="predefined">';
print '<input type="hidden" name="id" value="'.$object->id.'">';
print "<tr $bc[$var]>";
print "<tr ".$bc[$var].">";
print '<td colspan="3">';
// multiprix
if($conf->global->PRODUIT_MULTIPRICES)
$form->select_produits('','idprod',1,$conf->product->limit_size,$object->thirdparty->price_level);
else
$form->select_produits('','idprod',1,$conf->product->limit_size);
if (! $conf->global->PRODUIT_USE_SEARCH_TO_SELECT) print '<br>';
print '<textarea name="desc" cols="70" rows="'.ROWS_2.'"></textarea>';
print '</td>';
@@ -1270,7 +1269,7 @@ else
print '<td align="center" colspan="2" rowspan="2"><input type="submit" class="button" value="'.$langs->trans("Add").'"></td>';
print '</tr>'."\n";
print "<tr $bc[$var]>";
print "<tr ".$bc[$var].">";
print '<td colspan="8">';
print $langs->trans("DateStartPlanned").' ';
$form->select_date('',"date_start",$usehm,$usehm,1,"addline");

View File

@@ -1,7 +1,7 @@
<?php
/* Copyright (C) 2001-2004 Rodolphe Quiedeville <rodolphe@quiedeville.org>
* Copyright (C) 2004-2011 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2005-2009 Regis Houssin <regis@dolibarr.fr>
* Copyright (C) 2005-2012 Regis Houssin <regis@dolibarr.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
@@ -38,9 +38,9 @@ $statut=isset($_GET["statut"])?$_GET["statut"]:1;
// Security check
$socid=0;
$contratid = isset($_GET["id"])?$_GET["id"]:'';
$id = GETPOST('id','int');
if ($user->societe_id) $socid=$user->societe_id;
$result = restrictedArea($user, 'contrat',$contratid,'');
$result = restrictedArea($user, 'contrat',$id,'');
$staticcompany=new Societe($db);
$staticcontrat=new Contrat($db);
@@ -104,7 +104,7 @@ $sql.= ", ".MAIN_DB_PREFIX."contratdet as cd, ".MAIN_DB_PREFIX."contrat as c";
if (!$user->rights->societe->client->voir && !$socid) $sql.= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc";
$sql.= " WHERE cd.fk_contrat = c.rowid AND c.fk_soc = s.rowid";
$sql.= " AND (cd.statut != 4 OR (cd.statut = 4 AND (cd.date_fin_validite is null or cd.date_fin_validite >= '".$db->idate($now)."')))";
$sql.= " AND c.entity = ".$conf->entity;
$sql.= " AND c.entity IN (".getEntity('contract').")";
if ($user->societe_id) $sql.=' AND c.fk_soc = '.$user->societe_id;
if (!$user->rights->societe->client->voir && !$socid) $sql.= " AND s.rowid = sc.fk_soc AND sc.fk_user = " .$user->id;
$sql.= " GROUP BY cd.statut";
@@ -141,7 +141,7 @@ $sql.= ", ".MAIN_DB_PREFIX."contratdet as cd, ".MAIN_DB_PREFIX."contrat as c";
if (!$user->rights->societe->client->voir && !$socid) $sql.= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc";
$sql.= " WHERE cd.fk_contrat = c.rowid AND c.fk_soc = s.rowid";
$sql.= " AND (cd.statut = 4 AND cd.date_fin_validite < '".$db->idate($now)."')";
$sql.= " AND c.entity = ".$conf->entity;
$sql.= " AND c.entity IN (".getEntity('contract').")";
if ($user->societe_id) $sql.=' AND c.fk_soc = '.$user->societe_id;
if (!$user->rights->societe->client->voir && !$socid) $sql.= " AND s.rowid = sc.fk_soc AND sc.fk_user = " .$user->id;
$sql.= " GROUP BY cd.statut";
@@ -230,7 +230,7 @@ if ($conf->contrat->enabled && $user->rights->contrat->lire)
$sql .= " FROM ".MAIN_DB_PREFIX."contrat as c, ".MAIN_DB_PREFIX."societe as s";
if (!$user->rights->societe->client->voir && !$socid) $sql.= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc";
$sql.= " WHERE s.rowid = c.fk_soc";
$sql.= " AND c.entity = ".$conf->entity;
$sql.= " AND c.entity IN (".getEntity('contract').")";
$sql.= " AND c.statut = 0";
if (!$user->rights->societe->client->voir && !$socid) $sql.= " AND s.rowid = sc.fk_soc AND sc.fk_user = " .$user->id;
if ($socid) $sql.= " AND s.fk_soc = ".$socid;
@@ -301,7 +301,7 @@ if (!$user->rights->societe->client->voir && !$socid) $sql.= " ".MAIN_DB_PREFIX.
$sql.= " ".MAIN_DB_PREFIX."contrat as c";
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."contratdet as cd ON c.rowid = cd.fk_contrat";
$sql.= " WHERE c.fk_soc = s.rowid";
$sql.= " AND c.entity = ".$conf->entity;
$sql.= " AND c.entity IN (".getEntity('contract').")";
$sql.= " AND c.statut > 0";
if (!$user->rights->societe->client->voir && !$socid) $sql.= " AND s.rowid = sc.fk_soc AND sc.fk_user = " .$user->id;
if ($socid) $sql.= " AND s.rowid = ".$socid;
@@ -373,7 +373,7 @@ $sql.= ", ".MAIN_DB_PREFIX."societe as s";
if (!$user->rights->societe->client->voir && !$socid) $sql.= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc";
$sql.= ", ".MAIN_DB_PREFIX."contratdet as cd";
$sql.= ") LEFT JOIN ".MAIN_DB_PREFIX."product as p ON cd.fk_product = p.rowid";
$sql.= " WHERE c.entity = ".$conf->entity;
$sql.= " WHERE c.entity IN (".getEntity('contract').")";
$sql.= " AND cd.fk_contrat = c.rowid";
$sql.= " AND c.fk_soc = s.rowid";
if (!$user->rights->societe->client->voir && !$socid) $sql.= " AND s.rowid = sc.fk_soc AND sc.fk_user = " .$user->id;
@@ -451,7 +451,7 @@ $sql.= ", ".MAIN_DB_PREFIX."societe as s";
if (!$user->rights->societe->client->voir && !$socid) $sql.= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc";
$sql.= ", ".MAIN_DB_PREFIX."contratdet as cd";
$sql.= " ) LEFT JOIN ".MAIN_DB_PREFIX."product as p ON cd.fk_product = p.rowid";
$sql.= " WHERE c.entity = ".$conf->entity;
$sql.= " WHERE c.entity IN (".getEntity('contract').")";
$sql.= " AND c.statut = 1";
$sql.= " AND cd.statut = 0";
$sql.= " AND cd.fk_contrat = c.rowid";
@@ -530,7 +530,7 @@ $sql.= ", ".MAIN_DB_PREFIX."societe as s";
if (!$user->rights->societe->client->voir && !$socid) $sql.= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc";
$sql.= ", ".MAIN_DB_PREFIX."contratdet as cd";
$sql.= " ) LEFT JOIN ".MAIN_DB_PREFIX."product as p ON cd.fk_product = p.rowid";
$sql.= " WHERE c.entity = ".$conf->entity;
$sql.= " WHERE c.entity IN (".getEntity('contract').")";
$sql.= " AND c.statut = 1";
$sql.= " AND cd.statut = 4";
$sql.= " AND cd.date_fin_validite < '".$db->idate($now)."'";

View File

@@ -16,9 +16,7 @@
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
* or see http://www.gnu.org/
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/**

View File

@@ -12,15 +12,13 @@
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/**
* \file htdocs/core/ajax/ajaxdirtree.php
* \ingroup ecm
* \brief This script returns content of a directory for filetree
* \version $Id: ajaxFileTree.php,v 1.8 2011/07/06 17:03:41 eldy Exp $
*/
@@ -106,6 +104,8 @@ if( file_exists($fullpathselecteddir) )
// All dirs
foreach( $files as $file ) // $file can be '.', '..', or 'My dir' or 'My file'
{
if ($file == 'temp') continue;
$nbofsubdir=0;
$nboffilesinsubdir=0;

View File

@@ -23,7 +23,7 @@
//if (! defined('NOREQUIREUSER')) define('NOREQUIREUSER','1');
//if (! defined('NOREQUIREDB')) define('NOREQUIREDB','1');
if (! defined('NOREQUIRESOC')) define('NOREQUIRESOC','1');
//if (! defined('NOREQUIRESOC')) define('NOREQUIRESOC','1');
//if (! defined('NOREQUIRETRAN')) define('NOREQUIRETRAN','1');
if (! defined('NOCSRFCHECK')) define('NOCSRFCHECK','1');
if (! defined('NOTOKENRENEWAL')) define('NOTOKENRENEWAL','1');
@@ -43,8 +43,8 @@ error_reporting(E_ALL | E_STRICT);
//print_r($_GET);
//print 'upload_dir='.GETPOST('upload_dir');
$fk_element = GETPOST('fk_element');
$element = GETPOST('element');
$fk_element = GETPOST('fk_element','int');
$element = GETPOST('element','alpha');
/**
@@ -56,6 +56,7 @@ class UploadHandler
private $_options;
private $_fk_element;
private $_element;
private $_element_ref;
/**
@@ -64,19 +65,47 @@ class UploadHandler
* @param array $options Options array
* @param int $fk_element fk_element
* @param string $element element
* @param string $element_ref element ref
*/
function __construct($options=null,$fk_element=null,$element=null)
{
global $conf;
global $db, $conf;
global $object;
$this->_fk_element=$fk_element;
$this->_element=$element;
$pathname=$filename=$element;
if (preg_match('/^([^_]+)_([^_]+)/i',$element,$regs))
{
$pathname = $regs[1];
$filename = $regs[2];
}
// For compatibility
if ($element == 'propal') {
$pathname = 'comm/propal'; $filename = 'propal';
}
if ($element == 'commande') {
$pathname = $filename = 'commande';
}
if ($element == 'facture') {
$pathname = 'compta/facture'; $filename = 'facture';
}
dol_include_once('/'.$pathname.'/class/'.$filename.'.class.php');
$classname = ucfirst($filename);
$object = new $classname($db);
$object->fetch($fk_element);
$object->fetch_thirdparty();
$this->_options = array(
'script_url' => $_SERVER['PHP_SELF'],
'upload_dir' => $conf->$element->dir_output . '/' . $fk_element . '/',
'upload_url' => DOL_URL_ROOT.'/document.php?modulepart='.$element.'&attachment=1&file=/'.$fk_element.'/',
'upload_dir' => $conf->$element->dir_output . '/' . $object->ref . '/',
'upload_url' => DOL_URL_ROOT.'/document.php?modulepart='.$element.'&attachment=1&file=/'.$object->ref.'/',
'param_name' => 'files',
// The php.ini settings upload_max_filesize and post_max_size
// take precedence over the following max_file_size setting:
@@ -96,8 +125,8 @@ class UploadHandler
),
*/
'thumbs' => array(
'upload_dir' => $conf->$element->dir_output . '/' . $fk_element . '/thumbs/',
'upload_url' => DOL_URL_ROOT.'/document.php?modulepart='.$element.'&attachment=1&file=/'.$fk_element.'/thumbs/'
'upload_dir' => $conf->$element->dir_output . '/' . $object->ref . '/thumbs/',
'upload_url' => DOL_URL_ROOT.'/document.php?modulepart='.$element.'&attachment=1&file=/'.$object->ref.'/thumbs/'
)
)
);
@@ -251,8 +280,7 @@ class UploadHandler
FILE_APPEND
);
} else {
// FIXME problem with trigger
dol_move_uploaded_file($uploaded_file, $file_path, 1, 0, 0, 1);
dol_move_uploaded_file($uploaded_file, $file_path, 1);
}
} else {
// Non-multipart uploads (PUT method support)

View File

@@ -87,8 +87,15 @@ if (! empty($field) && ! empty($element) && ! empty($table_element) && ! empty($
}
else if (! empty($ext_element))
{
dol_include_once('/'.$ext_element.'/class/actions_'.$ext_element.'.class.php');
$classname = 'Actions'.ucfirst($ext_element);
$module = $subelement = $ext_element;
if (preg_match('/^([^_]+)_([^_]+)/i',$ext_element,$regs))
{
$module = $regs[1];
$subelement = $regs[2];
}
dol_include_once('/'.$module.'/class/actions_'.$subelement.'.class.php');
$classname = 'Actions'.ucfirst($subelement);
$object = new $classname($db);
$ret = $object->$methodname();
if ($ret > 0) echo json_encode($object->$cachename);

View File

@@ -51,6 +51,7 @@ if (! empty($field) && ! empty($element) && ! empty($table_element) && ! empty($
$field = substr($field, 8); // remove prefix val_
$type = GETPOST('type','alpha',2);
$value = ($type == 'ckeditor' ? GETPOST('value','',2) : GETPOST('value','alpha',2));
$loadmethod = GETPOST('loadmethod','alpha',2);
$savemethod = GETPOST('savemethod','alpha',2);
$savemethodname = (! empty($savemethod) ? $savemethod : 'setValueFrom');
@@ -104,9 +105,9 @@ if (! empty($field) && ! empty($element) && ! empty($table_element) && ! empty($
}
else if ($type == 'select')
{
$loadmethodname = 'load_cache_'.GETPOST('loadmethod','alpha');
$loadcachename = 'cache_'.GETPOST('loadmethod','alpha');
$loadviewname = 'view_'.GETPOST('loadmethod','alpha');
$loadmethodname = 'load_cache_'.$loadmethod;
$loadcachename = 'cache_'.$loadmethod;
$loadviewname = 'view_'.$loadmethod;
$form = new Form($db);
if (method_exists($form, $loadmethodname))
@@ -131,8 +132,15 @@ if (! empty($field) && ! empty($element) && ! empty($table_element) && ! empty($
}
else
{
dol_include_once('/'.$ext_element.'/class/actions_'.$ext_element.'.class.php');
$classname = 'Actions'.ucfirst($ext_element);
$module = $subelement = $ext_element;
if (preg_match('/^([^_]+)_([^_]+)/i',$ext_element,$regs))
{
$module = $regs[1];
$subelement = $regs[2];
}
dol_include_once('/'.$module.'/class/actions_'.$subelement.'.class.php');
$classname = 'Actions'.ucfirst($subelement);
$object = new $classname($db);
$ret = $object->$loadmethodname();
if ($ret > 0)

View File

@@ -130,7 +130,7 @@ class box_produits extends ModeleBoxes
$this->info_box_contents[$i][2] = array('td' => 'align="right"',
'text' => $price);
$this->info_box_contents[$i][3] = array('td' => 'align="center" width="20" nowrap="nowrap"',
$this->info_box_contents[$i][3] = array('td' => 'align="left" nowrap="nowrap"',
'text' => $price_base_type);
$this->info_box_contents[$i][4] = array('td' => 'align="right"',

View File

@@ -53,12 +53,25 @@ class Canvas
{
$this->db = $db;
$this->actiontype = $actiontype;
if ($this->actiontype == 'add') $this->actiontype='create';
if ($this->actiontype == 'update') $this->actiontype='edit';
if (empty($this->actiontype) || $this->actiontype == 'delete' || $this->actiontype == 'create_user') $this->actiontype='view';
$this->actiontype = $this->_cleanaction($actiontype);
}
/**
* Return action code cleaned
*
* @param string $action Action type ('create', 'view', 'edit', 'list', 'add', 'update')
* @return string Cleaned action type ('create', 'view', 'edit', 'list')
*/
private function _cleanaction($action)
{
$newaction = $action;
if ($newaction == 'add') $newaction='create';
if ($newaction == 'update') $newaction='edit';
if (empty($newaction) || $newaction == 'delete' || $newaction == 'create_user') $newaction='view';
return $newaction;
}
/**
* Initialize properties: ->targetmodule, ->canvas, ->card, ->dirmodule, ->template_dir
*
@@ -132,7 +145,7 @@ class Canvas
{
if (empty($this->template_dir)) return 0;
if (file_exists($this->template_dir.($this->card?$this->card.'_':'').$this->actiontype.'.tpl.php')) return 1;
if (file_exists($this->template_dir.($this->card?$this->card.'_':'').$this->_cleanaction($action).'.tpl.php')) return 1;
else return 0;
}
@@ -148,7 +161,7 @@ class Canvas
global $db, $conf, $langs, $user, $canvas;
global $form, $formfile;
include($this->template_dir.($this->card?$this->card.'_':'').$this->actiontype.'.tpl.php'); // Include native PHP template
include($this->template_dir.($this->card?$this->card.'_':'').$this->_cleanaction($action).'.tpl.php'); // Include native PHP template
}

View File

@@ -321,7 +321,7 @@ abstract class CommonObject
$tab=array();
$sql = "SELECT ec.rowid, ec.statut, ec.fk_socpeople as id";
$sql = "SELECT ec.rowid, ec.statut, ec.fk_socpeople as id"; // This field contains id of llx_socpeople or id of llx_user
if ($source == 'internal') $sql.=", '-1' as socid";
if ($source == 'external' || $source == 'thirdparty') $sql.=", t.fk_soc as socid";
$sql.= ", t.civilite as civility, t.name as lastname, t.firstname, t.email";
@@ -544,7 +544,7 @@ abstract class CommonObject
$this->thirdparty = $thirdparty;
// Use first price level if level not defined for third party
if ($conf->global->PRODUIT_MULTIPRICES && empty($this->thirdparty->price_level))
if (! empty($conf->global->PRODUIT_MULTIPRICES) && empty($this->thirdparty->price_level))
{
$this->client->price_level=1; // deprecated
$this->thirdparty->price_level=1;
@@ -1645,7 +1645,7 @@ abstract class CommonObject
$sourceid = (! empty($sourceid) ? $sourceid : $this->id);
$targetid = (! empty($targetid) ? $targetid : $this->id);
$sourcetype = (! empty($sourcetype) ? $sourcetype : (! empty($this->origin) ? $this->origin : $this->element));
$sourcetype = (! empty($sourcetype) ? $sourcetype : $this->element);
$targettype = (! empty($targettype) ? $targettype : $this->element);
// Links beetween objects are stored in this table
@@ -1846,8 +1846,11 @@ abstract class CommonObject
$this->db->begin();
$fieldstatus="fk_statut";
if ($elementTable == 'user') $fieldstatus="statut";
$sql = "UPDATE ".MAIN_DB_PREFIX.$elementTable;
$sql.= " SET fk_statut = ".$status;
$sql.= " SET ".$fieldstatus." = ".$status;
$sql.= " WHERE rowid=".$elementId;
dol_syslog(get_class($this)."::setStatut sql=".$sql, LOG_DEBUG);
@@ -2279,6 +2282,9 @@ abstract class CommonObject
if ($objecttype == 'member') {
$classpath = 'adherents/class'; $module='adherent'; $subelement='adherent';
}
if ($objecttype == 'cabinetmed_cons') {
$classpath = 'cabinetmed/class'; $module='cabinetmed'; $subelement='cabinetmedcons';
}
//print "objecttype=".$objecttype." module=".$module." subelement=".$subelement;
@@ -2290,15 +2296,17 @@ abstract class CommonObject
$classfile = 'fournisseur.commande'; $classname='CommandeFournisseur';
}
if ($conf->$module->enabled)
if (! empty($conf->$module->enabled))
{
$res=dol_include_once('/'.$classpath.'/'.$classfile.'.class.php');
if ($res)
{
dol_include_once('/'.$classpath.'/'.$classfile.'.class.php');
$object = new $classname($this->db);
$ret=$object->fetch($objectid);
if ($ret > 0) return $object->getNomUrl($withpicto,$option);
}
}
}
/* This is to show linked object block */

View File

@@ -414,11 +414,11 @@ class Conf
$this->bank->cheque->warning_delay=(isset($this->global->MAIN_DELAY_CHEQUES_TO_DEPOSIT)?$this->global->MAIN_DELAY_CHEQUES_TO_DEPOSIT:0)*24*60*60;
// For backward compatibility
$this->produit=$this->product;
$this->invoice=$this->facture;
$this->order=$this->commande;
$this->contract=$this->contrat;
$this->category=$this->categorie;
if (isset($this->product)) $this->produit=$this->product;
if (isset($this->facture)) $this->invoice=$this->facture;
if (isset($this->commande)) $this->order=$this->commande;
if (isset($this->contrat)) $this->contract=$this->contrat;
if (isset($this->categorie)) $this->category=$this->categorie;
// Define menu manager in setup

View File

@@ -176,7 +176,7 @@ class DolEditor
/* should be editor=CKEDITOR.replace but what if serveral editors ? */
CKEDITOR.replace(\''.$this->htmlname.'\',
{
customConfig : \''.dol_buildpath('/theme/'.$conf->theme.'/ckeditor/config.js',1).'\',
customConfig : ckeditorConfig,
toolbar: \''.$this->toolbarname.'\',
toolbarStartupExpanded: '.($this->toolbarstartexpanded ? 'true' : 'false').',
width: '.($this->width ? '\''.$this->width.'\'' : '\'\'').',
@@ -201,8 +201,8 @@ class DolEditor
{
$out.= ','."\n";
// To use filemanager with old fckeditor (GPL)
$out.= ' filebrowserBrowseUrl : \''.DOL_URL_ROOT.'/core/filemanagerdol/browser/default/browser.php?Connector='.DOL_URL_ROOT.'/core/filemanagerdol/connectors/php/connector.php\',';
$out.= ' filebrowserImageBrowseUrl : \''.DOL_URL_ROOT.'/core/filemanagerdol/browser/default/browser.php?Type=Image&Connector='.DOL_URL_ROOT.'/core/filemanagerdol/connectors/php/connector.php\',';
$out.= ' filebrowserBrowseUrl : ckeditorFilebrowserBrowseUrl,';
$out.= ' filebrowserImageBrowseUrl : ckeditorFilebrowserImageBrowseUrl,';
//$out.= ' filebrowserUploadUrl : \''.DOL_URL_ROOT.'/includes/fckeditor/editor/filemanagerdol/connectors/php/upload.php?Type=File\',';
//$out.= ' filebrowserImageUploadUrl : \''.DOL_URL_ROOT.'/includes/fckeditor/editor/filemanagerdol/connectors/php/upload.php?Type=Image\',';
$out.= "\n";

View File

@@ -31,6 +31,8 @@
class HookManager
{
var $db;
var $error;
var $errors=array();
// Context hookmanager was created for ('thirdpartycard', 'thirdpartydao', ...)
var $contextarray=array();
@@ -148,7 +150,7 @@ class HookManager
$resaction+=$actionclassinstance->$method($parameters, $object, $action, $this); // $object and $action can be changed by method ($object->id during creation for example or $action to go back to other action for example)
if ($resaction < 0 || ! empty($actionclassinstance->error) || (! empty($actionclassinstance->errors) && count($actionclassinstance->errors) > 0))
{
$this->error=$actionclassinstance->error; $this->errors=$actionclassinstance->errors;
$this->error=$actionclassinstance->error; $this->errors=array_merge($this->errors, (array) $actionclassinstance->errors);
if ($method == 'doActions')
{
if ($action=='add') $action='create'; // TODO this change must be inside the doActions

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