From ed88a4c398b981e9f6bce8b06f4888c6245b828d Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Mon, 14 Dec 2015 21:38:04 +0100 Subject: [PATCH 1/5] Fix css --- htdocs/index.php | 20 +++++++++++--------- htdocs/theme/eldy/style.css.php | 15 ++++++++++++--- htdocs/theme/md/style.css.php | 13 +++++++++++++ 3 files changed, 36 insertions(+), 12 deletions(-) diff --git a/htdocs/index.php b/htdocs/index.php index 94445337720..8bc704520ca 100644 --- a/htdocs/index.php +++ b/htdocs/index.php @@ -287,12 +287,10 @@ if (empty($user->societe_id)) $var=!$var; if (!empty($langfile[$key])) $langs->load($langfile[$key]); $text=$langs->trans($titres[$key]); - print ''; + print ''; print '
'; print img_object("",$icons[$key]).' '.$text.'
'; - //print '
'; - //print ''; - print $board->nb[$val]; + print ''.$board->nb[$val].''; print '
'; print ''; } @@ -454,13 +452,17 @@ foreach($valid_dashboardlines as $board) { $var=!$var; print ''.$board->img.''.$board->label.''; - print ''.$board->nbtodo.''; + print ''.$board->nbtodo.''; print ''; - print ''; - print $board->nbtodolate; - print ''; + //if ($board->nbtodolate > 0) + //{ + print ''; + print $board->nbtodolate; + print ''; + //} + print ''; print ''; - if ($board->nbtodolate > 0) print img_picto($langs->trans("NActionsLate",$board->nbtodolate),"warning"); + if ($board->nbtodolate > 0) print img_picto($langs->trans("NActionsLate",$board->nbtodolate).' (>'.ceil($board->warning_delay).' '.$langs->trans("days").')',"warning"); else print ' '; print ''; print ''; diff --git a/htdocs/theme/eldy/style.css.php b/htdocs/theme/eldy/style.css.php index a83f3430bc4..d17cd7aec1f 100644 --- a/htdocs/theme/eldy/style.css.php +++ b/htdocs/theme/eldy/style.css.php @@ -2323,8 +2323,6 @@ div.pagination li.paginationafterarrows { { background: rgb() !important; - - /* background: rgba(0, 0, 0, 0.05) !important; */ } @@ -2524,9 +2522,20 @@ div.tabBar .noborder { border-radius: 4px; } .boxstats:hover { + + background: rgb() !important; + background-color: #; + +} +span.boxstatsindicator { + font-size: 110%; + font-weight: bold; +} +span.dashboardlineindicator, span.dashboardlineindicatorlate { + font-size: 120%; + font-weight: bold; } - .boxtable { -moz-box-shadow: 3px 3px 4px #DDD; -webkit-box-shadow: 3px 3px 4px #DDD; diff --git a/htdocs/theme/md/style.css.php b/htdocs/theme/md/style.css.php index ad4237dc769..453365f3908 100644 --- a/htdocs/theme/md/style.css.php +++ b/htdocs/theme/md/style.css.php @@ -2349,9 +2349,22 @@ div.tabBar .noborder { border: 1px solid #AAA; text-align: center; border-radius: 2px; + min-height: 38px; } .boxstats:hover { + + background: rgb() !important; + background-color: #; + +} +span.boxstatsindicator { + font-size: 110%; + font-weight: bold; +} +span.dashboardlineindicator, span.dashboardlineindicatorlate { + font-size: 120%; + font-weight: bold; } .boxtable { From 750443040acbf4110bbbdc8d661dcf753b465156 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Tue, 15 Dec 2015 09:29:21 +0100 Subject: [PATCH 2/5] Enhance ruleset.xml description --- dev/codesniffer/ruleset.dtd | 1 + 1 file changed, 1 insertion(+) diff --git a/dev/codesniffer/ruleset.dtd b/dev/codesniffer/ruleset.dtd index e307d564e12..276626a3a16 100644 --- a/dev/codesniffer/ruleset.dtd +++ b/dev/codesniffer/ruleset.dtd @@ -3,6 +3,7 @@ + From 40269c3c70e89d3bbf2483e73710f4b7db9568c0 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Tue, 15 Dec 2015 09:32:09 +0100 Subject: [PATCH 3/5] Fix Remove syntax warnings --- htdocs/core/class/dolreceiptprinter.class.php | 10 +++++++--- htdocs/core/js/lib_head.js.php | 2 +- htdocs/core/modules/dons/html_cerfafr.html | 2 +- htdocs/public/test/test_arrays.php | 10 ++++------ htdocs/public/test/test_forms.php | 4 ++-- 5 files changed, 15 insertions(+), 13 deletions(-) diff --git a/htdocs/core/class/dolreceiptprinter.class.php b/htdocs/core/class/dolreceiptprinter.class.php index 5bee14b74d4..90bf948e215 100644 --- a/htdocs/core/class/dolreceiptprinter.class.php +++ b/htdocs/core/class/dolreceiptprinter.class.php @@ -80,7 +80,7 @@ * Print customer points * Print number of points for this order * - * Conditional code at line start (if…then Print) + * Conditional code at line start (if�then Print) * Print the line IF a customer is affected to the order * Print the line IF a vendor is affected to the order * Print the line IF Happy Hour @@ -520,8 +520,12 @@ class dolReceiptPrinter extends Escpos $ret = $this->InitPrinter($printerid); if ($ret>0) { setEventMessages($this->error, $this->errors, 'errors'); - } else { - for ($line=0; $line < count($vals); $line++) { + } + else + { + $nboflines = count($vals); + for ($line=0; $line < $nboflines; $line++) + { switch ($vals[$line]['tag']) { case 'DOL_ALIGN_CENTER': $this->printer->setJustification(Escpos::JUSTIFY_CENTER); diff --git a/htdocs/core/js/lib_head.js.php b/htdocs/core/js/lib_head.js.php index 15a25bf10ed..b843f83e1d0 100644 --- a/htdocs/core/js/lib_head.js.php +++ b/htdocs/core/js/lib_head.js.php @@ -940,7 +940,7 @@ function confirmConstantAction(action, url, code, input, box, entity, yesButton, function copyToClipboard(text,text2) { text = text.replace(/
/g,"\n"); - var newElem = "

"+text2; + var newElem = '

'+text2; $("#dialog").html(newElem); $("#dialog").dialog(); $("#coords").select(); diff --git a/htdocs/core/modules/dons/html_cerfafr.html b/htdocs/core/modules/dons/html_cerfafr.html index ea9dbee01e3..df6f58af77d 100644 --- a/htdocs/core/modules/dons/html_cerfafr.html +++ b/htdocs/core/modules/dons/html_cerfafr.html @@ -151,8 +151,8 @@ (1) ou n'indiquez que les renseignements concernant l'organisme
(2) dons effectués par les entreprises - +
diff --git a/htdocs/public/test/test_arrays.php b/htdocs/public/test/test_arrays.php index 2801ebb8855..ac4d9eb3c54 100644 --- a/htdocs/public/test/test_arrays.php +++ b/htdocs/public/test/test_arrays.php @@ -65,8 +65,8 @@ else

This page is a sample of page using tables. It is designed to make test with
-- css (add parameter &theme=newtheme to test another theme or edit css of current theme)
-- jmobile (add parameter ">dol_use_jmobile=1&dol_optimize_smallscreen=1 to enable view with jmobile)
+- css (add parameter &theme=newtheme to test another theme or edit css of current theme)
+- jmobile (add parameter ">dol_use_jmobile=1&dol_optimize_smallscreen=1 to enable view with jmobile)
- no javascript / usage for bind people (add parameter ">nojs=1 to force disable javascript)
- dataTables
- tablednd
@@ -181,8 +181,8 @@ if (! empty($moreforfilter)) print ''; } -print '

'; ?> +
" id="tablelines3"> trans('title1'),0,$_SERVER["PHP_SELF"],'aaa','','','align="left"',$sortfield,$sortorder); ?> trans('title2'),0,$_SERVER["PHP_SELF"],'bbb','','','align="right"',$sortfield,$sortorder); ?> @@ -190,9 +190,7 @@ print '
-'; -?> +
getNomUrl(1); ?>b1c1
a2b2c2

diff --git a/htdocs/public/test/test_forms.php b/htdocs/public/test/test_forms.php index 7fec8e895b6..a697b371438 100644 --- a/htdocs/public/test/test_forms.php +++ b/htdocs/public/test/test_forms.php @@ -16,8 +16,8 @@ llxHeader();

This page is a sample of page using Dolibarr HTML widget methods. It is designed to make test with
-- css (add parameter &theme=newtheme to test another theme or edit css of current theme)
-- jmobile (add parameter ">dol_use_jmobile=1&dol_optimize_smallscreen=1 to enable view with jmobile)
+- css (add parameter &theme=newtheme to test another theme or edit css of current theme)
+- jmobile (add parameter ">dol_use_jmobile=1&dol_optimize_smallscreen=1 to enable view with jmobile)
- no javascript / usage for bind people (add parameter ">nojs=1 to force disable javascript)


From af85ade7ff7deecce52f933c8d30561a9860bc48 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Tue, 15 Dec 2015 10:24:31 +0100 Subject: [PATCH 4/5] Minor css fix --- htdocs/theme/eldy/style.css.php | 1 - htdocs/theme/md/style.css.php | 1 - 2 files changed, 2 deletions(-) diff --git a/htdocs/theme/eldy/style.css.php b/htdocs/theme/eldy/style.css.php index d17cd7aec1f..54aa64a8cbe 100644 --- a/htdocs/theme/eldy/style.css.php +++ b/htdocs/theme/eldy/style.css.php @@ -3361,7 +3361,6 @@ ul.filedirelem li { } ul.ecmjqft { - font-size: 11px; line-height: 16px; padding: 0px; margin: 0px; diff --git a/htdocs/theme/md/style.css.php b/htdocs/theme/md/style.css.php index 453365f3908..76d5e8147ac 100644 --- a/htdocs/theme/md/style.css.php +++ b/htdocs/theme/md/style.css.php @@ -3202,7 +3202,6 @@ ui-layout-north { } ul.ecmjqft { - font-size: 11px; line-height: 16px; padding: 0px; margin: 0px; From 90dbfc487049ff8b53efb186bcb0084fd8836f2e Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Tue, 15 Dec 2015 15:52:20 +0100 Subject: [PATCH 5/5] Fix: to avoid confusion between amount of payment and amount distributed on invoice when a payment is done for several invoices, export of payment can export both fields. --- htdocs/core/modules/modFacture.class.php | 6 +++--- htdocs/langs/en_US/bills.lang | 3 +++ 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/htdocs/core/modules/modFacture.class.php b/htdocs/core/modules/modFacture.class.php index 807a2673849..72437d80b90 100644 --- a/htdocs/core/modules/modFacture.class.php +++ b/htdocs/core/modules/modFacture.class.php @@ -242,10 +242,10 @@ class modFacture extends DolibarrModules $this->export_label[$r]='CustomersInvoicesAndPayments'; // Translation key (used only if key ExportDataset_xxx_z not found) $this->export_icon[$r]='bill'; $this->export_permission[$r]=array(array("facture","facture","export")); - $this->export_fields_array[$r]=array('s.rowid'=>"IdCompany",'s.nom'=>'CompanyName','s.address'=>'Address','s.zip'=>'Zip','s.town'=>'Town','c.code'=>'CountryCode','s.phone'=>'Phone','s.siren'=>'ProfId1','s.siret'=>'ProfId2','s.ape'=>'ProfId3','s.idprof4'=>'ProfId4','s.code_compta'=>'CustomerAccountancyCode','s.code_compta_fournisseur'=>'SupplierAccountancyCode','s.tva_intra'=>'VATIntra','f.rowid'=>"InvoiceId",'f.facnumber'=>"InvoiceRef",'f.datec'=>"InvoiceDateCreation",'f.datef'=>"DateInvoice",'f.date_lim_reglement'=>"DateDue",'f.total'=>"TotalHT",'f.total_ttc'=>"TotalTTC",'f.tva'=>"TotalVAT",'f.paye'=>"InvoicePaid",'f.fk_statut'=>'InvoiceStatus','f.note_private'=>"NotePrivate",'f.note_public'=>"NotePublic",'f.fk_user_author'=>'CreatedById','uc.login'=>'CreatedByLogin','f.fk_user_valid'=>'ValidatedById','uv.login'=>'ValidatedByLogin','p.rowid'=>'PaymentId','pf.amount'=>'AmountPayment','p.datep'=>'DatePayment','p.num_paiement'=>'PaymentNumber','pt.code'=>'PaymentMode','p.fk_bank'=>'IdTransaction'); + $this->export_fields_array[$r]=array('s.rowid'=>"IdCompany",'s.nom'=>'CompanyName','s.address'=>'Address','s.zip'=>'Zip','s.town'=>'Town','c.code'=>'CountryCode','s.phone'=>'Phone','s.siren'=>'ProfId1','s.siret'=>'ProfId2','s.ape'=>'ProfId3','s.idprof4'=>'ProfId4','s.code_compta'=>'CustomerAccountancyCode','s.code_compta_fournisseur'=>'SupplierAccountancyCode','s.tva_intra'=>'VATIntra','f.rowid'=>"InvoiceId",'f.facnumber'=>"InvoiceRef",'f.datec'=>"InvoiceDateCreation",'f.datef'=>"DateInvoice",'f.date_lim_reglement'=>"DateDue",'f.total'=>"TotalHT",'f.total_ttc'=>"TotalTTC",'f.tva'=>"TotalVAT",'f.paye'=>"InvoicePaid",'f.fk_statut'=>'InvoiceStatus','f.note_private'=>"NotePrivate",'f.note_public'=>"NotePublic",'f.fk_user_author'=>'CreatedById','uc.login'=>'CreatedByLogin','f.fk_user_valid'=>'ValidatedById','uv.login'=>'ValidatedByLogin','p.rowid'=>'PaymentId','p.ref'=>'PaymentRef','p.amount'=>'AmountPayment','pf.amount'=>'AmountPaymentDistributedOnInvoice','p.datep'=>'DatePayment','p.num_paiement'=>'PaymentNumber','pt.code'=>'PaymentMode','p.note'=>'PaymentNote','p.fk_bank'=>'IdTransaction'); //$this->export_TypeFields_array[$r]=array('s.rowid'=>"List:societe:nom",'s.nom'=>'Text','s.address'=>'Text','s.zip'=>'Text','s.town'=>'Text','c.code'=>'Text','s.phone'=>'Text','s.siren'=>'Text','s.siret'=>'Text','s.ape'=>'Text','s.idprof4'=>'Text','s.code_compta'=>'Text','s.code_compta_fournisseur'=>'Text','s.tva_intra'=>'Text','f.rowid'=>"List:facture:facnumber",'f.facnumber'=>"Text",'f.datec'=>"Date",'f.datef'=>"Date",'f.date_lim_reglement'=>"Date",'f.total'=>"Numeric",'f.total_ttc'=>"Numeric",'f.tva'=>"Numeric",'f.paye'=>"Boolean",'f.fk_statut'=>'Status','f.note_private'=>"Text",'f.note_public'=>"Text",'pf.amount'=>'Numeric','p.datep'=>'Date','p.num_paiement'=>'Numeric','p.fk_bank'=>'Numeric'); - $this->export_TypeFields_array[$r]=array('s.nom'=>'Text','s.address'=>'Text','s.zip'=>'Text','s.town'=>'Text','c.code'=>'Text','s.phone'=>'Text','s.siren'=>'Text','s.siret'=>'Text','s.ape'=>'Text','s.idprof4'=>'Text','s.code_compta'=>'Text','s.code_compta_fournisseur'=>'Text','s.tva_intra'=>'Text','f.rowid'=>"List:facture:facnumber",'f.facnumber'=>"Text",'f.datec'=>"Date",'f.datef'=>"Date",'f.date_lim_reglement'=>"Date",'f.total'=>"Numeric",'f.total_ttc'=>"Numeric",'f.tva'=>"Numeric",'f.paye'=>"Boolean",'f.fk_statut'=>'Status','f.note_private'=>"Text",'f.note_public'=>"Text",'pf.amount'=>'Numeric','p.datep'=>'Date','p.num_paiement'=>'Numeric','p.fk_bank'=>'Numeric'); - $this->export_entities_array[$r]=array('s.rowid'=>"company",'s.nom'=>'company','s.address'=>'company','s.zip'=>'company','s.town'=>'company','c.code'=>'company','s.phone'=>'company','s.siren'=>'company','s.siret'=>'company','s.ape'=>'company','s.idprof4'=>'company','s.code_compta'=>'company','s.code_compta_fournisseur'=>'company','s.tva_intra'=>'company','f.rowid'=>"invoice",'f.facnumber'=>"invoice",'f.datec'=>"invoice",'f.datef'=>"invoice",'f.date_lim_reglement'=>"invoice",'f.total'=>"invoice",'f.total_ttc'=>"invoice",'f.tva'=>"invoice",'f.paye'=>"invoice",'f.fk_statut'=>'invoice','f.note_private'=>"invoice",'f.note_public'=>"invoice",'p.rowid'=>'payment','pf.amount'=>'payment','p.datep'=>'payment','p.num_paiement'=>'payment','pt.code'=>'payment','p.fk_bank'=>'payment','f.fk_user_author'=>'user','uc.login'=>'user','f.fk_user_valid'=>'user','uv.login'=>'user'); + $this->export_TypeFields_array[$r]=array('s.nom'=>'Text','s.address'=>'Text','s.zip'=>'Text','s.town'=>'Text','c.code'=>'Text','s.phone'=>'Text','s.siren'=>'Text','s.siret'=>'Text','s.ape'=>'Text','s.idprof4'=>'Text','s.code_compta'=>'Text','s.code_compta_fournisseur'=>'Text','s.tva_intra'=>'Text','f.rowid'=>"List:facture:facnumber",'f.facnumber'=>"Text",'f.datec'=>"Date",'f.datef'=>"Date",'f.date_lim_reglement'=>"Date",'f.total'=>"Numeric",'f.total_ttc'=>"Numeric",'f.tva'=>"Numeric",'f.paye'=>"Boolean",'f.fk_statut'=>'Status','f.note_private'=>"Text",'f.note_public'=>"Text",'pf.amount'=>'Numeric','p.datep'=>'Date','p.num_paiement'=>'Numeric','p.fk_bank'=>'Numeric','p.note'=>'Text'); + $this->export_entities_array[$r]=array('s.rowid'=>"company",'s.nom'=>'company','s.address'=>'company','s.zip'=>'company','s.town'=>'company','c.code'=>'company','s.phone'=>'company','s.siren'=>'company','s.siret'=>'company','s.ape'=>'company','s.idprof4'=>'company','s.code_compta'=>'company','s.code_compta_fournisseur'=>'company','s.tva_intra'=>'company','f.rowid'=>"invoice",'f.facnumber'=>"invoice",'f.datec'=>"invoice",'f.datef'=>"invoice",'f.date_lim_reglement'=>"invoice",'f.total'=>"invoice",'f.total_ttc'=>"invoice",'f.tva'=>"invoice",'f.paye'=>"invoice",'f.fk_statut'=>'invoice','f.note_private'=>"invoice",'f.note_public'=>"invoice",'p.rowid'=>'payment','p.ref'=>'payment','p.amount'=>'payment','pf.amount'=>'payment','p.datep'=>'payment','p.num_paiement'=>'payment','pt.code'=>'payment','p.fk_bank'=>'payment','p.note'=>'payment','f.fk_user_author'=>'user','uc.login'=>'user','f.fk_user_valid'=>'user','uv.login'=>'user'); $this->export_dependencies_array[$r]=array('payment'=>'p.rowid'); // To add unique key if we ask a field of a child to avoid the DISTINCT to discard them // Add extra fields $sql="SELECT name, label, type, param FROM ".MAIN_DB_PREFIX."extrafields WHERE elementtype = 'facture'"; diff --git a/htdocs/langs/en_US/bills.lang b/htdocs/langs/en_US/bills.lang index db2b9ea4b62..20f6fe0619c 100644 --- a/htdocs/langs/en_US/bills.lang +++ b/htdocs/langs/en_US/bills.lang @@ -269,6 +269,7 @@ HelpAbandonBadCustomer=This amount has been abandoned (customer said to be a bad HelpAbandonOther=This amount has been abandoned since it was an error (wrong customer or invoice replaced by an other for example) IdSocialContribution=Social/fiscal tax payment id PaymentId=Payment id +PaymentRef=Payment ref. InvoiceId=Invoice id InvoiceRef=Invoice ref. InvoiceDateCreation=Invoice creation date @@ -296,6 +297,8 @@ RelatedSupplierInvoices=Related supplier invoices LatestRelatedBill=Latest related invoice WarningBillExist=Warning, one or more invoice already exist MergingPDFTool=Merging PDF tool +AmountPaymentDistributedOnInvoice=Payment amount distributed on invoice +PaymentNote=Payment note # PaymentConditions PaymentConditionShortRECEP=Immediate