2
0
forked from Wavyzz/dolibarr

Merge branch '3.4' of git@github.com:Dolibarr/dolibarr.git into 3.4

This commit is contained in:
Laurent Destailleur
2014-01-15 09:10:30 +01:00
32 changed files with 1287 additions and 1225 deletions

121
ChangeLog
View File

@@ -2,56 +2,66 @@
English Dolibarr ChangeLog
--------------------------------------------------------------
***** ChangeLog for 3.4.3 compared to 3.4.2 *****
Fix: Warning into bank conciliation feature.
Fix: Bad get of localtaxes into contracts add lines.
Fix: Add a limit into list to avoid browser to hang when database is too large.
***** ChangeLog for 3.4.2 compared to 3.4.1 *****
Fix: field's problem into company's page (RIB)
Fix: Document cerfa doesn't contained firstname & lastname from donator
Fix: field's problem into company's page (RIB).
Fix: Document cerfa doesn't contained firstname & lastname from donator.
Fix: Bad rounding on margin calculations and display.
Fix: Option drop table into backup was broken.
Fix: [ bug #1105 ] Searching Boxes other search option
Fix: wrong buy price update
Fix: [ bug #1142 ] Set paiement on invoice (PGSql)
Fix: [ bug #1145 ] Agenda button list type do not display
Fix: [ bug #1148 ] Product consomation : supplier order bad status
Fix: [ bug #1159 ] Commercial search "other" give p.note do not exists
Fix: [ bug #1174 ] Product translated description not good into PDF
Fix: [ bug #1163 ] SQL Error when searching for supplier orders
Fix: [ bug #1162 ] Translaction for morning and afternoon
Fix: [ bug #1161 ] Search on product label
Fix: [ bug #1105 ] Searching Boxes other search option.
Fix: wrong buy price update.
Fix: [ bug #1142 ] Set paiement on invoice (PGSql).
Fix: [ bug #1145 ] Agenda button list type do not display.
Fix: [ bug #1148 ] Product consomation : supplier order bad status.
Fix: [ bug #1159 ] Commercial search "other" give p.note do not exists.
Fix: [ bug #1174 ] Product translated description not good into PDF.
Fix: [ bug #1163 ] SQL Error when searching for supplier orders.
Fix: [ bug #1162 ] Translaction for morning and afternoon.
Fix: [ bug #1161 ] Search on product label.
Fix: [ bug #1075 ] POS module doesn't decrement stock of products in delayed payment mode.
Fix: [ bug #1171 ] Documents lost in interventions after validating
Fix: fix unsubscribe URL into mailing when sending manually (not by script)
Fix: [ bug #1182 ] ODT company_country tag is htmlencoded
Fix: [ bug #1196 ] Product barcode search does not expect 13th digit on EAN13 type
Fix: [ bug #1202 ] Wrong amount in deposit % invoice from proposal
Fix: [ bug #1171 ] Documents lost in interventions after validating.
Fix: fix unsubscribe URL into mailing when sending manually (not by script).
Fix: [ bug #1182 ] ODT company_country tag is htmlencoded.
Fix: [ bug #1196 ] Product barcode search does not expect 13th digit on EAN13 type.
Fix: [ bug #1202 ] Wrong amount in deposit % invoice from proposal.
Fix: Removed analytics tags into doc page.
Fix: Call Image on this instead of pdf.
Fix: Missing parameter for photo.
Fix: Bad SQL request for turnover report.
***** ChangeLog for 3.4.1 compared to 3.4.0 *****
Fix: Display buying price on line edit when no supplier price is defined
Fix: Retrieving of margin info when invoice created automatically from order
Fix: Reordering supplier products in list by supplier or supplier ref was crashing
Fix: [ bug #1029 ] Tulip numbering mask
Fix: Supplier invoice and supplier order are not displayed into object link into agenda event card
Fix: [ bug #1033 ] SUPPLIER REF disappeared
Fix: update extrafield do not display immediatly after update
Fix: Fix bug with canvas thirdparty
Fix: [ bug #1037 ] Consumption> Supplier invoices related
Fix: User group name do not display in card (view or edit mode)
Fix: Link "Show all supplier invoice" on suplier card not working
Fix: [ bug #1039 ] Pre-defined invoices conversion
Fix: If only service module is activated, it's impossible to delete service
Fix: [ bug #1043 ] Bad interventions ref numbering
Fix: Mailing module : if an email is already in destinaires list all other email from selector was not inserted
Fix: Localtaxes balance not showing
Fix: Intervention box links to contracts id
Fix: Compatiblity with multicompany module
Fix: Edit propal line was losing product supplier price id
Fix: Delete linked element to supplier invoice when deleted
Fix: [ bug #1061 ] Bad info shipped products
Fix: [ bug #1062 ] Documents lost in propals and contracts validating
Fix: Supplier price displayed on document lines and margin infos didnt take discount
Fix: sorting on qty did not work in supplier product list
Fix: there was no escaping on filter fields in supplier product list
Fix: bugs on margin reports and better margin calculation on credit notes
Qual: Add travis-ci integration
Fix: Display buying price on line edit when no supplier price is defined.
Fix: Retrieving of margin info when invoice created automatically from order.
Fix: Reordering supplier products in list by supplier or supplier ref was crashing.
Fix: [ bug #1029 ] Tulip numbering mask.
Fix: Supplier invoice and supplier order are not displayed into object link into agenda event card.
Fix: [ bug #1033 ] SUPPLIER REF disappeared.
Fix: update extrafield do not display immediatly after update.
Fix: Fix bug with canvas thirdparty.
Fix: [ bug #1037 ] Consumption> Supplier invoices related.
Fix: User group name do not display in card (view or edit mode).
Fix: Link "Show all supplier invoice" on suplier card not working.
Fix: [ bug #1039 ] Pre-defined invoices conversion.
Fix: If only service module is activated, it's impossible to delete service.
Fix: [ bug #1043 ] Bad interventions ref numbering.
Fix: Mailing module : if an email is already in destinaires list all other email from selector was not inserted.
Fix: Localtaxes balance not showing.
Fix: Intervention box links to contracts id.
Fix: Compatiblity with multicompany module.
Fix: Edit propal line was losing product supplier price id.
Fix: Delete linked element to supplier invoice when deleted.
Fix: [ bug #1061 ] Bad info shipped products.
Fix: [ bug #1062 ] Documents lost in propals and contracts validating.
Fix: Supplier price displayed on document lines and margin infos didnt take discount.
Fix: sorting on qty did not work in supplier product list.
Fix: there was no escaping on filter fields in supplier product list.
Fix: bugs on margin reports and better margin calculation on credit notes.
Qual: Add travis-ci integration.
***** ChangeLog for 3.4 compared to 3.3.* *****
For users:
@@ -149,6 +159,13 @@ backport commit 384e3812eb73a15adafb472cacfb93397a54459b to fix W3C/edit contrac
***** ChangeLog for 3.3.5 compared to 3.3.4 *****
- Fix: Change to make debian package ok despite removal of ckeditor.
- Fix: jcrop file to match debian rules
- Fix: Add missing country UK.
- Fix: Minor fix into package.
- Fix: Add missing label on project field.
***** ChangeLog for 3.3.4 compared to 3.3.3 *****
- Fix: [ bug #1001 ] Social Contribution : State not correct
- Fix: Better management of pdf generation when tcpdf is not available.
@@ -319,7 +336,6 @@ Dolibarr license has also been updated from GPLv2+ to GPLv3+.
***** ChangeLog for 3.2.3 compared to 3.2.2 *****
- Fix: Some permission into agenda module.
- Fix: Generation of PDF was not using correct font for some languages.
- Fix some translations.
@@ -473,7 +489,6 @@ WARNING: To reduce technic debt, all functions dolibarr_xxx were renamed int dol
***** ChangeLog for 3.1.3 compared to 3.1.2 *****
Fix: PgSQL - property must be set if success
Fix: Provide a solution for backup when mysqldump is not available
Fix: Bug #460 - Wrong entity assignment when creating a warehouse
@@ -482,7 +497,6 @@ Fix: bug #405 - Late icon always displayed on comm/propal.php
***** 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
@@ -495,7 +509,6 @@ Fix: bug #405 - Late icon always displayed on comm/propal.php
***** ChangeLog for 3.1.1 compared to 3.1.0 *****
- New: Add option FACTURE_DEPOSITS_ARE_JUST_PAYMENTS. With this option added,
credit notes are not removed from total amount of invoice but are just
payments used to reducs remain to pay.
@@ -617,7 +630,6 @@ For translators:
***** ChangeLog for 3.0 compared to 2.9.* *****
For users:
- New: Can edit date of cheque receipts.
- New: Add Sales journal and Purchase journal report.
@@ -713,7 +725,6 @@ For developers:
***** ChangeLog for 2.9 compared to 2.8.* *****
For users:
- New: POS module allow to choose which warehouse to use.
- New: Support "Department/State" field on company setup, contact,
@@ -831,7 +842,6 @@ For users:
***** ChangeLog for 2.8 compared to 2.7.* *****
For users:
- New: Support note on trips module
- New: Can link contacts to projects
@@ -882,7 +892,6 @@ For developers:
***** ChangeLog for 2.7.1 compared to 2.7 *****
For users:
- Fix: Bad decimal management for it_IT and fr_BE languages.
- Fix: A third party created from a member is created as a
@@ -895,7 +904,6 @@ For users:
***** ChangeLog for 2.7 compared to 2.6.* *****
For users:
- New: Add a print icon to show a page to print without menus.
- New: Can add a free text on bank cheque receipts.
@@ -994,7 +1002,6 @@ For developers:
***** ChangeLog for 2.6 compared to 2.5.* *****
For users:
- New: Add filter on status in emailing selector for Dolibarr users.
- New: Can add bookmarks on all pages.
@@ -1077,7 +1084,6 @@ For developers:
***** ChangeLog for 2.5 compared to 2.4.* *****
For users:
- Sessions timeout can be configured to overwrite PHP setup.
- Can filter on date in services list.
@@ -1141,7 +1147,6 @@ For developers:
***** ChangeLog for 2.4 compared to 2.2.* *****
For users:
- Add a calendar module (module agenda) with ical/vcal/rss export.
- Look enhancement in graphics (thanks artichow).
@@ -1196,7 +1201,6 @@ For developers:
***** ChangeLog for 2.2 compared to 2.1.* *****
- Add more statistics on main page.
- Add option to add message on login page.
- Management of categories for third parties.
@@ -1230,7 +1234,6 @@ For developers:
***** ChangeLog for 2.1 compared to 2.0.* *****
- Added a better installer.
- Support user and groups permissions.
- Translation in english and support for several languages.
@@ -1295,12 +1298,10 @@ For developers:
***** ChangeLog for 2.0.1 compared to 2.0 *****
Minor bug fixes
***** ChangeLog for 2.0 compared to 1.0.* *****
ChangeLog file size is so important, that it is not included inside Dolibarr
package. You can find it at www.dolibarr.org

View File

@@ -7,10 +7,27 @@ All sub-directories of "build" directory contains files required to build
automatically Dolibarr packages.
There are several tools:
- To build full Dolibarr packages, launch the script
> Edit version in makepack-dolibarr.pl file.
> Launch command perl makepack-dolibarr.pl
Note: Prerequisites to build tgz, debian, rpm package
> apt-get install tar dpkg dpatch p7zip-full rpm zip
Note: Prerequisites to build autoexe DoliWamp package:
> Install InnoSetup
For example by running isetup-5.3.9.exe (http://www.jrsoftware.org)
> Install WampServer into "C:\Program Files\Wamp"
For example by running wampserver2.2e-php5.4.3-httpd-2.4.2-mysql5.5.24-x64.exe (http://www.wampserver.com)
> Install WampServer addon to have versions: Apache2.2.11, Mysql5.0.45, Php5.3.0
For example by running WampServer2-APACHE2211.exe (http://www.wampserver.com)
For example by running WampServer2-MYSQL5045.exe (http://www.wampserver.com)
For example by running WampServer2-PHP530.exe (http://www.wampserver.com)
> To build from Windows (running from makepack-dolibarr.pl script is however
recommanded), open file build/exe/doliwamp.iss and click on button "Compile".
The .exe file will be build into directory build.
- To build a translaction package, launch the script
> perl makepack-dolibarrlang.pl
@@ -20,17 +37,6 @@ There are several tools:
- To build a package for a module, launch the script
> perl makepack-dolibarrmodule.pl
- To build an autoexe DoliWamp package:
> Install InnoSetup (http://www.jrsoftware.org)
> Install WampServer into "C:\Program Files\Wamp" (http://www.wampserver.com)
> Install WampServer addon to have versions:
Apache2.2.6, Mysql5.0.45, Php5.2.5
> Modify file build/exe/doliwamp.iss to change variable SourceDir
with value of Dolibarr repository.
> Modify AppVerName and OutputBaseFilename.
> Launch innosetup, open file build/exe/doliwamp.iss and click on
button "Compile". The .exe file will be build into directory build.
- To build developper documentation, launch the script
> perl dolybarr-doxygen-build.pl
@@ -43,24 +49,33 @@ generated packages will not contains this "build" directory.
We can find in "build", following sub-directories:
* deb:
* aps:
To build APS package.
* debian:
To build Debian package.
* rpm:
To build Redhat or Mandrake package.
* dmg:
To build Mac OS package (not ready yet).
* tgz:
To build a tgz package.
* doap:
To build Doap descriptor to promote/describe Dolibarr releases.
* doxygen:
Dir with config file to build doxygen documentation.
* exe:
To build exe package for Windows that distribute Dolibarr sources or
to build the complete DoliWamp package.
* tgz:
To build a zip package.
* launchpad:
Doc file to explain how to use launchpad.
* doap:
To build Doap descriptor to promote/describe Dolibarr releases.
* live:
Doc file to explain how to create a demo live CD.
* obs:
Doc file to explain how to push release onto OBS.
* pad:
To build a PAD file descriptor to promote/describe Dolibarr releases.
@@ -68,5 +83,14 @@ To build a PAD file descriptor to promote/describe Dolibarr releases.
* patch:
Script file to generate a patch file to distribute a Dolibarr mod.
* dmg:
To build dmg DoliMamp package for Mac OS X
* perl:
Tool to install dolibarr when using virtualmin pro
* rpm:
To build Redhat, Opensuse or Mandriva package.
* tgz:
To build a tgz package.
* zip:
To build a zip package.

View File

@@ -3,7 +3,7 @@ dolibarr (3.4.2) unstable; urgency=low
[ Laurent Destailleur (eldy) ]
* Maintenance release.
-- Laurent Destailleur (eldy) <eldy@users.sourceforge.net> Mon, 22 Apr 2013 12:00:00 +0100
-- Laurent Destailleur (eldy) <eldy@users.sourceforge.net> Mon, 30 Dec 2013 12:00:00 +0100
dolibarr (3.4.1) unstable; urgency=low

View File

@@ -20,12 +20,12 @@ AppName=DoliWamp
AppVerName=DoliWamp-3.4.2
; 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.4.2
; Define full path from wich all relative path are defined
; ----- End of change
;OutputManifestFile=build\doliwampbuild.log
; Define full path from which all relative path are defined
; You must modify this to put here your dolibarr root directory
;SourceDir=Z:\home\ldestailleur\git\dolibarrxxx
SourceDir=..\..\..
; ----- End of change
;OutputManifestFile=build\doliwampbuild.log
AppId=doliwamp
AppPublisher=NLTechno
AppPublisherURL=http://www.nltechno.com
@@ -51,7 +51,6 @@ CreateUninstallRegKey=yes
OutputDir=build
ShowLanguageDialog=auto
ShowUndisplayableLanguages=no
;LanguageDetectionMethod=none
LanguageDetectionMethod=uilanguage
;SignedUninstaller=yes
@@ -109,7 +108,7 @@ Source: "C:\Program Files\Wamp\bin\mysql\mysql5.0.45\*.*"; DestDir: "{app}\bin\m
; Mysql data files (does not overwrite if exists)
Source: "build\exe\doliwamp\mysql\*.*"; DestDir: "{app}\bin\mysql\data\mysql"; Flags: onlyifdoesntexist ignoreversion recursesubdirs; Excludes: ".gitignore,.project,CVS\*,Thumbs.db"
; Dolibarr
Source: "htdocs\*.*"; DestDir: "{app}\www\dolibarr\htdocs"; Flags: ignoreversion recursesubdirs; Excludes: ".gitignore,.project,CVS\*,Thumbs.db,custom\*,custom2\*,documents\*,includes\ckeditor\_source\*,includes\savant\*,includes\phpmailer\*,jquery\plugins\template\*,PHPExcel\Shared\PDF\*,PHPExcel\Shared\PCLZip\*,tcpdf\fonts\dejavu-fonts-ttf-2.33\*,tcpdf\fonts\freefont-20100919\*,tcpdf\fonts\utils\*,*\conf.php,*\conf.php.mysql,*\conf.php.old,*\conf.php.postgres,*\conf.php.sav,*\install.forced.php"
Source: "htdocs\*.*"; DestDir: "{app}\www\dolibarr\htdocs"; Flags: ignoreversion recursesubdirs; Excludes: ".gitignore,.project,CVS\*,Thumbs.db,custom\*,custom2\*,documents\*,includes\ckeditor\_source\*,includes\savant\*,includes\phpmailer\*,jquery\plugins\template\*,nltechno*,PHPExcel\Shared\PDF\*,PHPExcel\Shared\PCLZip\*,tcpdf\fonts\dejavu-fonts-ttf-2.33\*,tcpdf\fonts\freefont-20100919\*,tcpdf\fonts\utils\*,*\conf.php,*\conf.php.mysql,*\conf.php.old,*\conf.php.postgres,*\conf.php.sav,*\install.forced.php"
Source: "dev\*.*"; DestDir: "{app}\www\dolibarr\dev"; Flags: ignoreversion recursesubdirs; Excludes: ".gitignore,.project,CVS\*,Thumbs.db,dbmodel\*,fpdf\*,initdata\*,iso-normes\*,licence\*,phpcheckstyle\*,phpunit\*,samples\*,test\*,uml\*,xdebug\*"
Source: "doc\*.*"; DestDir: "{app}\www\dolibarr\doc"; Flags: ignoreversion recursesubdirs; Excludes: ".gitignore,.project,CVS\*,Thumbs.db,wiki\*,plaquette\*,dev\*,images\dolibarr_screenshot2.png,images\dolibarr_screenshot3.png,images\dolibarr_screenshot4.png,images\dolibarr_screenshot5.png,images\dolibarr_screenshot6.png,images\dolibarr_screenshot7.png,images\dolibarr_screenshot8.png,images\dolibarr_screenshot9.png,images\dolibarr_screenshot10.png,images\dolibarr_screenshot11.png,images\dolibarr_screenshot12.png"
Source: "scripts\*.*"; DestDir: "{app}\www\dolibarr\scripts"; Flags: ignoreversion recursesubdirs; Excludes: ".gitignore,.project,CVS\*,Thumbs.db,product\materiel.net.php,product\import-product.php"
@@ -134,6 +133,7 @@ Source: "COPYRIGHT"; DestDir: "{app}"; Flags: ignoreversion;
[Icons]
Name: "{group}\Dolibarr ERP-CRM"; Filename: "{app}\rundoliwamp.bat"; WorkingDir: "{app}"; IconFilename: {app}\www\dolibarr\doc\images\dolibarr.ico
Name: "{group}\Tools\Help center"; Filename: "{app}\rundolihelp.bat"; WorkingDir: "{app}"; IconFilename: {app}\www\dolibarr\doc\images\dolihelp.ico
Name: "{group}\Tools\Host your ERP-CRM in the Cloud"; Filename: "http://wiki.dolibarr.org/index.php/Cloud_Solutions"; WorkingDir: "{app}"; IconFilename: {app}\www\dolibarr\doc\images\dolihelp.ico
Name: "{group}\Tools\Start DoliWamp server"; Filename: "{app}\startdoliwamp.bat"; WorkingDir: "{app}"; IconFilename: {app}\www\dolibarr\doc\images\doliwampon.ico
Name: "{group}\Tools\Stop DoliWamp server"; Filename: "{app}\stopdoliwamp.bat"; WorkingDir: "{app}"; IconFilename: {app}\www\dolibarr\doc\images\doliwampoff.ico
Name: "{group}\Tools\Admin DoliWamp server"; Filename: "{app}\rundoliadmin.bat"; WorkingDir: "{app}"; IconFilename: {app}\www\dolibarr\doc\images\doliadmin.ico
@@ -1017,6 +1017,3 @@ Type: filesandordirs; Name: "{app}\www\dolibarr"
[UninstallRun]
Filename: "{app}\uninstall_services.bat"; Flags: runhidden

View File

@@ -23,7 +23,7 @@ $RPMSUBVERSION="auto"; # auto use value found into BUILD
"RPM_FEDORA"=>"rpmbuild",
"RPM_MANDRIVA"=>"rpmbuild",
"RPM_OPENSUSE"=>"rpmbuild",
"DEB"=>"dpkg",
"DEB"=>"dpkg dpatch",
"APS"=>"zip",
"EXEDOLIWAMP"=>"ISCC.exe"
);
@@ -217,7 +217,7 @@ foreach my $target (keys %CHOOSEDTARGET) {
last;
} else {
# Pas erreur ou erreur autre que programme absent
print " Found ".$REQUIREMENTTARGET{$target}."\n";
print " Found ".$req."\n";
}
}
}

View File

@@ -35,9 +35,9 @@
<Program_Info>
<Program_Name>Dolibarr</Program_Name>
<Program_Version>3.4</Program_Version>
<Program_Release_Month>07</Program_Release_Month>
<Program_Release_Day>07</Program_Release_Day>
<Program_Release_Year>2013</Program_Release_Year>
<Program_Release_Month>01</Program_Release_Month>
<Program_Release_Day>01</Program_Release_Day>
<Program_Release_Year>2014</Program_Release_Year>
<Program_Cost_Dollars />
<Program_Cost_Other_Code />
<Program_Cost_Other />

View File

@@ -35,9 +35,9 @@
<Program_Info>
<Program_Name>DoliWamp</Program_Name>
<Program_Version>3.4</Program_Version>
<Program_Release_Month>07</Program_Release_Month>
<Program_Release_Day>07</Program_Release_Day>
<Program_Release_Year>2013</Program_Release_Year>
<Program_Release_Month>01</Program_Release_Month>
<Program_Release_Day>01</Program_Release_Day>
<Program_Release_Year>2014</Program_Release_Year>
<Program_Cost_Dollars />
<Program_Cost_Other_Code />
<Program_Cost_Other />

View File

@@ -330,5 +330,5 @@ fi
# version x.y.z-0.1.a for alpha, x.y.z-0.2.b for beta, x.y.z-0.3 for release
%changelog
* Sun Feb 17 2013 Laurent Destailleur 3.4.2-0.3
* Mon Dec 30 2013 Laurent Destailleur 3.4.2-0.3
- Initial version (#723326)

View File

@@ -558,5 +558,5 @@ fi
# version x.y.z-0.1.a for alpha, x.y.z-0.2.b for beta, x.y.z-0.3 for release
%changelog
* Sun Feb 17 2013 Laurent Destailleur 3.4.2-0.3
* Mon Dec 30 2013 Laurent Destailleur 3.4.2-0.3
- Initial version (#723326)

View File

@@ -335,5 +335,5 @@ fi
# version x.y.z-0.1.a for alpha, x.y.z-0.2.b for beta, x.y.z-0.3 for release
%changelog
* Sun Feb 17 2013 Laurent Destailleur 3.4.2-0.3
* Mon Dec 30 2013 Laurent Destailleur 3.4.2-0.3
- Initial version (#723326)

View File

@@ -345,5 +345,5 @@ fi
# version x.y.z-0.1.a for alpha, x.y.z-0.2.b for beta, x.y.z-0.3 for release
%changelog
* Sun Feb 17 2013 Laurent Destailleur 3.4.2-0.3
* Mon Dec 30 2013 Laurent Destailleur 3.4.2-0.3
- Initial version (#723326)

View File

@@ -48,3 +48,8 @@ with
//var OpenWindow=window.open(pRef, "newwin", "height="+vHeight+",width="+vWidth);
window.location.href=pRef
* Replace hard coded string with i18n["String"];
JCROP:
------
* Remove analytics tag into file index.html

View File

@@ -152,7 +152,8 @@ foreach ($modulesdir as $dir)
$const_name = 'MAIN_MODULE_'.strtoupper(preg_replace('/^mod/i','',get_class($objMod)));
if ($objMod->version == 'development' && (empty($conf->global->$const_name) && ($conf->global->MAIN_FEATURES_LEVEL < 2))) $modulequalified=0;
if ($objMod->version == 'experimental' && (empty($conf->global->$const_name) && ($conf->global->MAIN_FEATURES_LEVEL < 1))) $modulequalified=0;
//if ($mode == 'expdev' && ($objMod->version != 'experimental' && $objMod->version != 'development')) $modulequalified=0;
// We discard modules according to property disabled
if (! empty($objMod->hidden)) $modulequalified=false;
// Define array $categ with categ with at least one qualified module
if ($modulequalified)

View File

@@ -473,8 +473,10 @@ if (! empty($conf->propal->enabled) && $user->rights->propal->lire)
$var=true;
print '<table class="noborder" width="100%">';
print '<tr class="liste_titre"><td colspan="5">'.$langs->trans("ProposalsOpened").'</td></tr>';
while ($i < $num)
print '<tr class="liste_titre"><td colspan="5">'.$langs->trans("ProposalsOpened").' <a href="'.DOL_URL_ROOT.'/comm/propal/list.php?viewstatut=1">('.$num.')</td></tr>';
$nbofloop=min($num, (empty($conf->global->MAIN_MAXLIST_OVERLOAD)?1000:$conf->global->MAIN_MAXLIST_OVERLOAD));
while ($i < $nbofloop)
{
$obj = $db->fetch_object($result);
$var=!$var;
@@ -511,7 +513,12 @@ if (! empty($conf->propal->enabled) && $user->rights->propal->lire)
$i++;
$total += $obj->total_ttc;
}
if ($total>0) {
if ($num > $nbofloop)
{
print '<tr class="liste_total"><td colspan="5">'.$langs->trans("XMoreLines", ($num - $nbofloop))."</td></tr>";
}
else if ($total>0)
{
print '<tr class="liste_total"><td colspan="3">'.$langs->trans("Total")."</td><td align=\"right\">".price($total)."</td><td>&nbsp;</td></tr>";
}
print "</table><br>";

View File

@@ -313,8 +313,10 @@ if (! empty($conf->propal->enabled) && $user->rights->propale->lire)
$var=true;
print '<table class="noborder" width="100%">';
print '<tr class="liste_titre"><td colspan="5">'.$langs->trans("ProposalsOpened").' <a href="'.DOL_URL_ROOT.'/comm/propal.php?viewstatut=1">('.$num.')</a></td></tr>';
while ($i < $num)
print '<tr class="liste_titre"><td colspan="5">'.$langs->trans("ProposalsOpened").' <a href="'.DOL_URL_ROOT.'/comm/propal/list.php?viewstatut=1">('.$num.')</a></td></tr>';
$nbofloop=min($num, (empty($conf->global->MAIN_MAXLIST_OVERLOAD)?1000:$conf->global->MAIN_MAXLIST_OVERLOAD));
while ($i < $nbofloop)
{
$obj = $db->fetch_object($result);
$var=!$var;
@@ -356,7 +358,12 @@ if (! empty($conf->propal->enabled) && $user->rights->propale->lire)
$i++;
$total += $obj->total_ttc;
}
if ($total>0) {
if ($num > $nbofloop)
{
print '<tr class="liste_total"><td colspan="5">'.$langs->trans("XMoreLines", ($num - $nbofloop))."</td></tr>";
}
else if ($total>0)
{
print '<tr class="liste_total"><td colspan="3">'.$langs->trans("Total")."</td><td align=\"right\">".price($total)."</td><td>&nbsp;</td></tr>";
}
print "</table><br>";

View File

@@ -1159,7 +1159,7 @@ class AccountLine extends CommonObject
$this->db->begin();
// Delete urls
$result=$this->delete_urls();
$result=$this->delete_urls($user);
if ($result < 0)
{
$nbko++;
@@ -1296,7 +1296,7 @@ class AccountLine extends CommonObject
// No error check. Can fail if category already affected
}
$bankline->rappro=1;
$this->rappro=1;
$this->db->commit();
return 1;

View File

@@ -1,5 +1,6 @@
<?php
/* Copyright (C) 2013 Antoine Iauch <aiauch@gpcsolutions.fr>
* Copyright (C) 2013 Laurent Destailleur <eldy@users.sourceforge.net>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -171,23 +172,21 @@ report_header($nom,$nomlink,$period,$periodlink,$description,$builddate,$exportl
// SQL request
$catotal=0;
if ($modecompta == 'CREANCES-DETTES') {
if ($modecompta == 'CREANCES-DETTES')
{
$sql = "SELECT DISTINCT p.rowid as rowid, p.ref as ref, p.label as label,";
$sql.= " sum(DISTINCT l.total_ht) as amount, sum(DISTINCT l.total_ttc) as amount_ttc";
$sql.= " FROM ".MAIN_DB_PREFIX."product as p";
$sql.= " JOIN ".MAIN_DB_PREFIX."facturedet as l";
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."facture as f ON l.fk_facture = f.rowid";
if ($selected_cat === -2) {
$sql.=" LEFT OUTER JOIN ".MAIN_DB_PREFIX."categorie_product as cp ON p.rowid = cp.fk_product";
$sql.= " sum(l.total_ht) as amount, sum(l.total_ttc) as amount_ttc";
$sql.= " FROM ".MAIN_DB_PREFIX."facture as f, ".MAIN_DB_PREFIX."facturedet as l, ".MAIN_DB_PREFIX."product as p";
if ($selected_cat === -2) // Without any category
{
$sql.= " LEFT OUTER JOIN ".MAIN_DB_PREFIX."categorie_product as cp ON p.rowid = cp.fk_product";
}
if ($selected_cat && $selected_cat !== -2) {
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."categorie as c ON c.rowid = " . $selected_cat;
if ($subcat) {
$sql.=" OR c.fk_parent = " . $selected_cat;
}
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."categorie_product as cp ON cp.fk_categorie = c.rowid";
else if ($selected_cat) // Into a specific category
{
$sql.= ", ".MAIN_DB_PREFIX."categorie as c, ".MAIN_DB_PREFIX."categorie_product as cp";
}
$sql.= " WHERE l.fk_product = p.rowid";
$sql.= " AND l.fk_facture = f.rowid";
$sql.= " AND f.fk_statut in (1,2)";
if (! empty($conf->global->FACTURE_DEPOSITS_ARE_JUST_PAYMENTS)) {
$sql.= " AND f.type IN (0,1,2)";
@@ -197,16 +196,21 @@ if ($modecompta == 'CREANCES-DETTES') {
if ($date_start && $date_end) {
$sql.= " AND f.datef >= '".$db->idate($date_start)."' AND f.datef <= '".$db->idate($date_end)."'";
}
if ($selected_cat === -2) {
if ($selected_cat === -2) // Without any category
{
$sql.=" AND cp.fk_product is null";
}
if ($selected_cat && $selected_cat !== -2) {
$sql.= " AND cp.fk_product = p.rowid";
else if ($selected_cat) { // Into a specific category
$sql.= " AND (c.rowid = ".$selected_cat;
if ($subcat) $sql.=" OR c.fk_parent = " . $selected_cat;
$sql.= ")";
$sql.= " AND cp.fk_categorie = c.rowid AND cp.fk_product = p.rowid";
}
$sql.= " AND f.entity = ".$conf->entity;
$sql.= " GROUP BY p.rowid ";
$sql.= "ORDER BY p.ref ";
$sql.= " GROUP BY p.rowid";
$sql.= " ORDER BY p.ref";
dol_syslog("cabyprodserv sql=".$sql);
$result = $db->query($sql);
if ($result) {
$num = $db->num_rows($result);
@@ -381,7 +385,10 @@ if ($modecompta == 'CREANCES-DETTES') {
print '</form>';
} else {
// $modecompta != 'CREANCES-DETTES'
// TODO: better message
// TODO: better message, for example:
// "Calculation of part of each product for accountancy in this mode is not possible. When a partial payment (for example 5 euros) is done on an
// invoice with 2 product (product A for 10 euros and product B for 20 euros), what is part of paiment for product A and part of paiment for product B ?
// Because there is no way to know this, this report is not relevant.
print '<div class="warning">' . $langs->trans("WarningNotRelevant") . '</div>';
}

View File

@@ -1,6 +1,6 @@
<?php
/* Copyright (C) 2001-2003 Rodolphe Quiedeville <rodolphe@quiedeville.org>
* Copyright (C) 2004-2011 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2004-2013 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2005-2009 Regis Houssin <regis.houssin@capnetworks.com>
* Copyright (C) 2007 Franky Van Liedekerke <franky.van.liedekerke@telenet.be>
* Copyright (C) 2013 Antoine Iauch <aiauch@gpcsolutions.fr>
@@ -177,18 +177,15 @@ report_header($nom,$nomlink,$period,$periodlink,$description,$builddate,$exportl
$catotal=0;
if ($modecompta == 'CREANCES-DETTES') {
$sql = "SELECT DISTINCT s.rowid as socid, s.nom as name,";
$sql.= " sum(DISTINCT f.total) as amount, sum(DISTINCT f.total_ttc) as amount_ttc";
$sql.= " FROM ".MAIN_DB_PREFIX."societe as s";
$sql.= " JOIN ".MAIN_DB_PREFIX."facture as f";
if ($selected_cat === -2) {
$sql.= " sum(f.total) as amount, sum(f.total_ttc) as amount_ttc";
$sql.= " FROM ".MAIN_DB_PREFIX."facture as f, ".MAIN_DB_PREFIX."societe as s";
if ($selected_cat === -2) // Without any category
{
$sql.= " LEFT OUTER JOIN ".MAIN_DB_PREFIX."categorie_societe as cs ON s.rowid = cs.fk_societe";
}
if ($selected_cat && $selected_cat !== -2) {
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."categorie as c ON c.rowid = ".$selected_cat;
if ($subcat) {
$sql.=" OR c.fk_parent = " . $selected_cat;
}
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."categorie_societe as cs ON cs.fk_categorie = c.rowid";
else if ($selected_cat) // Into a specific category
{
$sql.= ", ".MAIN_DB_PREFIX."categorie as c, ".MAIN_DB_PREFIX."categorie_societe as cs";
}
$sql.= " WHERE f.fk_statut in (1,2)";
if (! empty($conf->global->FACTURE_DEPOSITS_ARE_JUST_PAYMENTS)) {
@@ -200,34 +197,57 @@ if ($modecompta == 'CREANCES-DETTES') {
if ($date_start && $date_end) {
$sql.= " AND f.datef >= '".$db->idate($date_start)."' AND f.datef <= '".$db->idate($date_end)."'";
}
if ($selected_cat === -2) {
if ($selected_cat === -2) // Without any category
{
$sql.=" AND cs.fk_societe is null";
}
if ($selected_cat && $selected_cat !== -2) {
$sql.= " AND cs.fk_societe = s.rowid";
else if ($selected_cat) { // Into a specific category
$sql.= " AND (c.rowid = ".$selected_cat;
if ($subcat) $sql.=" OR c.fk_parent = " . $selected_cat;
$sql.= ")";
$sql.= " AND cs.fk_categorie = c.rowid AND cs.fk_societe = s.rowid";
}
} else {
} else {
/*
* Liste des paiements (les anciens paiements ne sont pas vus par cette requete car, sur les
* vieilles versions, ils n'etaient pas lies via paiement_facture. On les ajoute plus loin)
*/
$sql = "SELECT s.rowid as socid, s.nom as name, sum(pf.amount) as amount_ttc";
$sql .= " FROM ".MAIN_DB_PREFIX."societe as s";
$sql.= ", ".MAIN_DB_PREFIX."facture as f";
$sql.= " FROM ".MAIN_DB_PREFIX."facture as f";
$sql.= ", ".MAIN_DB_PREFIX."paiement_facture as pf";
$sql.= ", ".MAIN_DB_PREFIX."paiement as p";
$sql .= " WHERE p.rowid = pf.fk_paiement";
$sql.= ", ".MAIN_DB_PREFIX."societe as s";
if ($selected_cat === -2) // Without any category
{
$sql.= " LEFT OUTER JOIN ".MAIN_DB_PREFIX."categorie_societe as cs ON s.rowid = cs.fk_societe";
}
else if ($selected_cat) // Into a specific category
{
$sql.= ", ".MAIN_DB_PREFIX."categorie as c, ".MAIN_DB_PREFIX."categorie_societe as cs";
}
$sql.= " WHERE p.rowid = pf.fk_paiement";
$sql.= " AND pf.fk_facture = f.rowid";
$sql.= " AND f.fk_soc = s.rowid";
if ($date_start && $date_end) {
$sql.= " AND p.datep >= '".$db->idate($date_start)."' AND p.datep <= '".$db->idate($date_end)."'";
}
if ($selected_cat === -2) // Without any category
{
$sql.=" AND cs.fk_societe is null";
}
else if ($selected_cat) { // Into a specific category
$sql.= " AND (c.rowid = ".$selected_cat;
if ($subcat) $sql.=" OR c.fk_parent = " . $selected_cat;
$sql.= ")";
$sql.= " AND cs.fk_categorie = c.rowid AND cs.fk_societe = s.rowid";
}
}
$sql.= " AND f.entity = ".$conf->entity;
if ($socid) $sql.= " AND f.fk_soc = ".$socid;
$sql.= " GROUP BY s.rowid, s.nom";
$sql.= " ORDER BY s.rowid";
dol_syslog("casoc sql=".$sql);
$result = $db->query($sql);
if ($result) {
$num = $db->num_rows($result);
@@ -248,7 +268,7 @@ if ($result) {
// On ajoute les paiements anciennes version, non lies par paiement_facture
if ($modecompta != 'CREANCES-DETTES') {
$sql = "SELECT '0' as socid, 'Autres' as name, sum(DISTINCT p.amount) as amount_ttc";
$sql = "SELECT '0' as socid, 'Autres' as name, sum(p.amount) as amount_ttc";
$sql.= " FROM ".MAIN_DB_PREFIX."bank as b";
$sql.= ", ".MAIN_DB_PREFIX."bank_account as ba";
$sql.= ", ".MAIN_DB_PREFIX."paiement as p";

View File

@@ -3,7 +3,7 @@
* Copyright (C) 2004-2012 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2005-2012 Regis Houssin <regis.houssin@capnetworks.com>
* Copyright (C) 2006 Andre Cianfarani <acianfa@free.fr>
* Copyright (C) 2010-2012 Juanjo Menent <jmenent@2byte.es>
* Copyright (C) 2010-2013 Juanjo Menent <jmenent@2byte.es>
* Copyright (C) 2013 Christophe Battarel <christophe.battarel@altairis.fr>
* Copyright (C) 2013 Florian Henry <florian.henry@open-concept.pro>
*
@@ -444,8 +444,8 @@ else if ($action == 'addline' && $user->rights->contrat->creer)
$desc=GETPOST('dp_desc');
}
$localtax1_tx=get_localtax($tva_tx,1,$object->societe);
$localtax2_tx=get_localtax($tva_tx,2,$object->societe);
$localtax1_tx=get_localtax($tva_tx,1,$object->thirdparty);
$localtax2_tx=get_localtax($tva_tx,2,$object->thirdparty);
// ajout prix achat
$fk_fournprice = $_POST['fournprice'];

View File

@@ -557,7 +557,13 @@ function listOfSessions()
global $conf;
$arrayofSessions = array();
$sessPath = ini_get("session.save_path").'/';
// session.save_path can be returned empty so we set a default location and work from there
$sessPath = '/tmp';
$iniPath = ini_get("session.save_path");
if ($iniPath) {
$sessPath = $iniPath;
}
$sessPath .= '/'; // We need the trailing slash
dol_syslog('admin.lib:listOfSessions sessPath='.$sessPath);
$dh = @opendir(dol_osencode($sessPath));

View File

@@ -70,9 +70,9 @@ insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, left
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->societe->enabled', __HANDLER__, 'left', 600__+MAX_llx_menu__, 'companies', 'contacts', 2__+MAX_llx_menu__, '/contact/list.php?leftmenu=contacts', 'ContactsAddresses', 0, 'companies', '$user->rights->societe->lire', '', 2, 1, __ENTITY__);
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->societe->enabled', __HANDLER__, 'left', 601__+MAX_llx_menu__, 'companies', '', 600__+MAX_llx_menu__, '/contact/fiche.php?leftmenu=contacts&amp;action=create', 'NewContactAddress', 1, 'companies', '$user->rights->societe->creer', '', 2, 0, __ENTITY__);
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->societe->enabled', __HANDLER__, 'left', 602__+MAX_llx_menu__, 'companies', '', 600__+MAX_llx_menu__, '/contact/list.php?leftmenu=contacts', 'List', 1, 'companies', '$user->rights->societe->lire', '', 2, 1, __ENTITY__);
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->societe->enabled', __HANDLER__, 'left', 604__+MAX_llx_menu__, 'companies', '', 602__+MAX_llx_menu__, '/contact/list.php?leftmenu=contacts&amp;type=p', 'Prospects', 2, 'companies', '$user->rights->societe->contact->lire', '', 2, 1, __ENTITY__);
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->societe->enabled', __HANDLER__, 'left', 605__+MAX_llx_menu__, 'companies', '', 602__+MAX_llx_menu__, '/contact/list.php?leftmenu=contacts&amp;type=c', 'Customers', 2, 'companies', '$user->rights->societe->contact->lire', '', 2, 2, __ENTITY__);
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->societe->enabled && $conf->fournisseur->enabled', __HANDLER__, 'left', 606__+MAX_llx_menu__, 'companies', '', 602__+MAX_llx_menu__, '/contact/list.php?leftmenu=contacts&amp;type=f', 'Suppliers', 2, 'companies', '$user->rights->societe->contact->lire', '', 2, 3, __ENTITY__);
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->societe->enabled', __HANDLER__, 'left', 604__+MAX_llx_menu__, 'companies', '', 602__+MAX_llx_menu__, '/contact/list.php?leftmenu=contacts&amp;type=p', 'ThirdPartyProspects', 2, 'companies', '$user->rights->societe->contact->lire', '', 2, 1, __ENTITY__);
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->societe->enabled', __HANDLER__, 'left', 605__+MAX_llx_menu__, 'companies', '', 602__+MAX_llx_menu__, '/contact/list.php?leftmenu=contacts&amp;type=c', 'ThirdPartyCustomers', 2, 'companies', '$user->rights->societe->contact->lire', '', 2, 2, __ENTITY__);
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->societe->enabled && $conf->fournisseur->enabled', __HANDLER__, 'left', 606__+MAX_llx_menu__, 'companies', '', 602__+MAX_llx_menu__, '/contact/list.php?leftmenu=contacts&amp;type=f', 'ThirdPartySuppliers', 2, 'companies', '$user->rights->societe->contact->lire', '', 2, 3, __ENTITY__);
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->societe->enabled', __HANDLER__, 'left', 607__+MAX_llx_menu__, 'companies', '', 602__+MAX_llx_menu__, '/contact/list.php?leftmenu=contacts&amp;type=o', 'Others', 2, 'companies', '$user->rights->societe->contact->lire', '', 2, 4, __ENTITY__);
-- Third parties - Category customer
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->societe->enabled && $conf->categorie->enabled', __HANDLER__, 'left', 650__+MAX_llx_menu__, 'companies', 'cat', 2__+MAX_llx_menu__, '/categories/index.php?leftmenu=cat&amp;type=1', 'SuppliersCategoriesShort', 0, 'categories', '$user->rights->categorie->lire', '', 2, 3, __ENTITY__);

View File

@@ -195,8 +195,8 @@ class pdf_standard
// Center
if ($textright=='') // Only a left part
{
if ($textleft == '%LOGO%' && $logo) $this->Image($logo,$_PosX+2,$_PosY+3+$this->_Line_Height,20);
else if ($textleft == '%PHOTO%' && $photo) $this->Image($photo,$_PosX+2,$_PosY+3+$this->_Line_Height,20);
if ($textleft == '%LOGO%' && $logo) $pdf->Image($logo,$_PosX+2,$_PosY+3+$this->_Line_Height,20);
else if ($textleft == '%PHOTO%' && $photo) $pdf->Image($photo,$_PosX+2,$_PosY+3+$this->_Line_Height,20);
else
{
$pdf->SetXY($_PosX+3, $_PosY+3+$this->_Line_Height);
@@ -230,8 +230,8 @@ class pdf_standard
}
else // Only a right part
{
if ($textright == '%LOGO%' && $logo) $this->Image($logo,$_PosX+$this->_Width-21,$_PosY+1,20);
else if ($textright == '%PHOTO%' && $photo) $this->Image($photo,$_PosX+$this->_Width-21,$_PosY+1,20);
if ($textright == '%LOGO%' && $logo) $pdf->Image($logo,$_PosX+$this->_Width-21,$_PosY+1,20);
else if ($textright == '%PHOTO%' && $photo) $pdf->Image($photo,$_PosX+$this->_Width-21,$_PosY+1,20);
else
{
$pdf->SetXY($_PosX+2, $_PosY+3+$this->_Line_Height);

View File

@@ -23,15 +23,15 @@
/**
* \defgroup agenda Module agenda
* \brief Module pour gerer l'agenda et actions
* \brief Module to manage agenda and events
* \file htdocs/core/modules/modAgenda.class.php
* \ingroup agenda
* \brief Fichier de description et activation du module agenda
* \brief File of class to describe and enable/disable module Agenda
*/
include_once DOL_DOCUMENT_ROOT .'/core/modules/DolibarrModules.class.php';
/**
* Classe de description et activation du module Adherent
* Class to describe and enable/disable module Agenda
*/
class modAgenda extends DolibarrModules
{

View File

@@ -62,6 +62,8 @@ class modFckeditor extends DolibarrModules
$this->config_page_url = array("fckeditor.php");
// Dependances
global $dolibarr_js_CKEDITOR;
$this->hidden = ($dolibarr_js_CKEDITOR == 'disabled'?1:0); // A condition to disable module (used for native debian packages)
$this->depends = array();
$this->requiredby = array();

View File

@@ -120,9 +120,10 @@ class pdf_standardlabel
* @param string $footer Footer
* @param Translate $outputlangs Output langs
* @param string $textright Text right
* @param string $photo Photo (full path to image file used as replacement for key %PHOTOS% into left, right, header or footer text)
* @return void
*/
function Add_PDF_card(&$pdf,$textleft,$header,$footer,$outputlangs,$textright='')
function Add_PDF_card(&$pdf,$textleft,$header,$footer,$outputlangs,$textright='',$photo='')
{
global $mysoc,$conf,$langs;
@@ -148,8 +149,6 @@ class pdf_standardlabel
$logo=$conf->mycompany->dir_output.'/logos/'.$mysoc->logo;
}
}
// Define photo
$photo='';
// Define background image
$backgroundimage='';
@@ -184,8 +183,8 @@ class pdf_standardlabel
// Middle
if ($textright=='') // Only a left part
{
if ($textleft == '%LOGO%' && $logo) $this->Image($logo,$_PosX+2,$_PosY+3+$this->_Line_Height,20);
else if ($textleft == '%PHOTO%' && $photo) $this->Image($photo,$_PosX+2,$_PosY+3+$this->_Line_Height,20);
if ($textleft == '%LOGO%' && $logo) $pdf->Image($logo,$_PosX+2,$_PosY+3+$this->_Line_Height,20);
else if ($textleft == '%PHOTO%' && $photo) $pdf->Image($photo,$_PosX+2,$_PosY+3+$this->_Line_Height,20);
else
{
$pdf->SetXY($_PosX+3, $_PosY+3+$this->_Line_Height);
@@ -218,8 +217,8 @@ class pdf_standardlabel
}
else // Only a right part
{
if ($textright == '%LOGO%' && $logo) $this->Image($logo,$_PosX+$this->_Width-21,$_PosY+1,20);
else if ($textright == '%PHOTO%' && $photo) $this->Image($photo,$_PosX+$this->_Width-21,$_PosY+1,20);
if ($textright == '%LOGO%' && $logo) $pdf->Image($logo,$_PosX+$this->_Width-21,$_PosY+1,20);
else if ($textright == '%PHOTO%' && $photo) $pdf->Image($photo,$_PosX+$this->_Width-21,$_PosY+1,20);
else
{
$pdf->SetXY($_PosX+2, $_PosY+3+$this->_Line_Height);
@@ -394,13 +393,13 @@ class pdf_standardlabel
/**
* Function to build PDF on disk, then output on HTTP strem.
*
* @param array $arrayofmembers Array of members informations
* @param array $arrayofrecords Array of record informations (array('textleft'=>,'textheader'=>, ..., 'id'=>,'photo'=>)
* @param Translate $outputlangs Lang object for output language
* @param string $srctemplatepath Full path of source filename for generator using a template file
* @param string $outputdir Output directory
* @return int 1=OK, 0=KO
*/
function write_file($arrayofmembers,$outputlangs,$srctemplatepath,$outputdir='')
function write_file($arrayofrecords,$outputlangs,$srctemplatepath,$outputdir='')
{
global $user,$conf,$langs,$mysoc,$_Avery_Labels;
@@ -468,10 +467,10 @@ class pdf_standardlabel
// Add each record
foreach($arrayofmembers as $val)
foreach($arrayofrecords as $val)
{
// imprime le texte specifique sur la carte
$this->Add_PDF_card($pdf,$val['textleft'],$val['textheader'],$val['textfooter'],$langs,$val['textright'],$val['id'],$val['photo']);
$this->Add_PDF_card($pdf,$val['textleft'],$val['textheader'],$val['textfooter'],$langs,$val['textright'],$val['photo']);
}
//$pdf->SetXY(10, 295);

View File

@@ -63,13 +63,13 @@ class ModelePDFLabels
* Create a document onto disk accordign to template module
*
* @param DoliDB $db Database handler
* @param array $arrayofmembers Array of members
* @param array $arrayofrecords Array of records
* @param string $modele Force le modele a utiliser ('' to not force)
* @param Translate $outputlangs Objet lang a utiliser pour traduction
* @param string $outputdir Output directory
* @return int <0 if KO, >0 if OK
*/
function members_label_pdf_create($db, $arrayofmembers, $modele, $outputlangs, $outputdir='')
function members_label_pdf_create($db, $arrayofrecords, $modele, $outputlangs, $outputdir='')
{
global $conf,$langs;
$langs->load("members");
@@ -141,7 +141,7 @@ function members_label_pdf_create($db, $arrayofmembers, $modele, $outputlangs, $
// We save charset_output to restore it because write_file can change it if needed for
// output format that does not support UTF8.
$sav_charset_output=$outputlangs->charset_output;
if ($obj->write_file($arrayofmembers, $outputlangs, $srctemplatepath, $outputdir) > 0)
if ($obj->write_file($arrayofrecords, $outputlangs, $srctemplatepath, $outputdir) > 0)
{
$outputlangs->charset_output=$sav_charset_output;
return 1;

0
htdocs/filefunc.inc.php Normal file → Executable file
View File

View File

@@ -46,20 +46,5 @@
</div>
<!-- Below here for internal analysis {{{ -->
<script type="text/javascript">
var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
</script>
<script type="text/javascript">
var pageTracker = _gat._getTracker("UA-5176876-1");
pageTracker._trackPageview();
</script>
<!-- }}} -->
</body>
</html>

View File

@@ -88,13 +88,13 @@ insert into llx_c_tva(rowid,fk_pays,taux,recuperableonly,note,active) values (80
insert into llx_c_tva(rowid,fk_pays,taux,recuperableonly,note,active) values (802,80, '0','0','VAT Rate 0',1);
-- FRANCE (id country=1)
insert into llx_c_tva(rowid,fk_pays,taux,recuperableonly,note,active) values ( 11, 1,'19.6','0','VAT standard rate (France hors DOM-TOM)',1);
insert into llx_c_tva(rowid,fk_pays,taux,recuperableonly,note,active) values ( 11, 1,'20','0','VAT standard rate (France hors DOM-TOM)',1);
insert into llx_c_tva(rowid,fk_pays,taux,recuperableonly,note,active) values ( 12, 1, '8.5','0','VAT standard rate (DOM sauf Guyane et Saint-Martin)',0);
insert into llx_c_tva(rowid,fk_pays,taux,recuperableonly,note,active) values ( 13, 1, '8.5','1','VAT standard rate (DOM sauf Guyane et Saint-Martin), non perçu par le vendeur mais récupérable par acheteur',0);
insert into llx_c_tva(rowid,fk_pays,taux,recuperableonly,note,active) values ( 14, 1, '5.5','0','VAT reduced rate (France hors DOM-TOM)',1);
insert into llx_c_tva(rowid,fk_pays,taux,recuperableonly,note,active) values ( 15, 1, '0','0','VAT Rate 0 ou non applicable',1);
insert into llx_c_tva(rowid,fk_pays,taux,recuperableonly,note,active) values ( 16, 1, '2.1','0','VAT super-reduced rate',1);
insert into llx_c_tva(rowid,fk_pays,taux,recuperableonly,note,active) values ( 17, 1, '7','0','VAT reduced rate',1);
insert into llx_c_tva(rowid,fk_pays,taux,recuperableonly,note,active) values ( 17, 1, '10','0','VAT reduced rate',1);
-- GERMANY (id country=5)
insert into llx_c_tva(rowid,fk_pays,taux,recuperableonly,note,active) values ( 51, 5, '19.0','0','allgemeine Ust.',1);

View File

@@ -659,6 +659,7 @@ from=from
toward=toward
Access=Access
SetDemandReason=Set source
XMoreLines=%s line(s) hidden
# Week day
Monday=Monday

View File

@@ -657,6 +657,7 @@ from=de
toward=vers
Access=Accès
SetDemandReason=Définir l'origine
XMoreLines=%s ligne(s) non affichée(s)
# Week day
Monday=Lundi

View File

@@ -27,7 +27,6 @@ require_once DOL_DOCUMENT_ROOT.'/core/class/commonobject.class.php';
/**
* Class to manage tasks
* Initialy built by build_class_from_table on 2008-09-10 12:41
*/
class Task extends CommonObject
{