';
print '| ';
print img_picto('', $elementPicto, 'class="pictofixedwidth"');
@@ -384,6 +398,7 @@ foreach ($listofnotifiedevents as $notifiedevent) {
print ' | '.$notifiedevent['code'].' | ';
print ''.$label.' | ';
print '';
+ $inputfieldalreadyshown = 0;
// Notification with threshold
foreach ($conf->global as $key => $val) {
if ($val == '' || !preg_match('/^NOTIFICATION_FIXEDEMAIL_'.$notifiedevent['code'].'_THRESHOLD_HIGHER_(.*)/', $key, $reg)) {
@@ -407,24 +422,35 @@ foreach ($listofnotifiedevents as $notifiedevent) {
}
print $form->textwithpicto($s, $langs->trans("YouCanUseCommaSeparatorForSeveralRecipients").' '.$langs->trans("YouCanAlsoUseSupervisorKeyword"), 1, 'help', '', 0, 2);
print ' ';
+
+ $inputfieldalreadyshown++;
}
// New entry input fields
- $s = ''; // Do not use type="email" here, we must be able to enter a list of email with , separator.
- print $form->textwithpicto($s, $langs->trans("YouCanUseCommaSeparatorForSeveralRecipients").' '.$langs->trans("YouCanAlsoUseSupervisorKeyword"), 1, 'help', '', 0, 2);
+ if (empty($inputfieldalreadyshown) || !$codehasnotrigger) {
+ $s = ''; // Do not use type="email" here, we must be able to enter a list of email with , separator.
+ print $form->textwithpicto($s, $langs->trans("YouCanUseCommaSeparatorForSeveralRecipients").' '.$langs->trans("YouCanAlsoUseSupervisorKeyword"), 1, 'help', '', 0, 2);
+ }
print ' | ';
print '';
// Notification with threshold
+ $inputfieldalreadyshown = 0;
foreach ($conf->global as $key => $val) {
if ($val == '' || !preg_match('/^NOTIFICATION_FIXEDEMAIL_'.$notifiedevent['code'].'_THRESHOLD_HIGHER_(.*)/', $key, $reg)) {
continue;
}
- print $langs->trans("AmountHT").' >= ';
- print ' ';
+ if (!$codehasnotrigger) {
+ print $langs->trans($labelfortrigger).' >= ';
+ print ' ';
+
+ $inputfieldalreadyshown++;
+ }
}
// New entry input fields
- print $langs->trans("AmountHT").' >= ';
+ if (!$codehasnotrigger) {
+ print $langs->trans($labelfortrigger).' >= ';
+ }
print ' | ';
print '';
@@ -437,7 +463,7 @@ print '';
print ' ';
-print '';
+print '';
print '';
diff --git a/htdocs/contrat/services_list.php b/htdocs/contrat/services_list.php
index 8368bffbab2..5a93f3fde33 100644
--- a/htdocs/contrat/services_list.php
+++ b/htdocs/contrat/services_list.php
@@ -35,6 +35,8 @@ require_once DOL_DOCUMENT_ROOT."/societe/class/societe.class.php";
// Load translation files required by the page
$langs->loadLangs(array('products', 'contracts', 'companies'));
+$optioncss = GETPOST('optioncss', 'aZ09');
+
$limit = GETPOST('limit', 'int') ?GETPOST('limit', 'int') : $conf->liste_limit;
$sortfield = GETPOST("sortfield", 'alpha');
$sortorder = GETPOST("sortorder", 'alpha');
@@ -58,7 +60,6 @@ $search_name = GETPOST("search_name", 'alpha');
$search_contract = GETPOST("search_contract", 'alpha');
$search_service = GETPOST("search_service", 'alpha');
$search_status = GETPOST("search_status", 'alpha');
-$statut = GETPOST('statut', 'int') ?GETPOST('statut', 'int') : 1;
$search_product_category = GETPOST('search_product_category', 'int');
$socid = GETPOST('socid', 'int');
$contextpage = GETPOST('contextpage', 'aZ') ?GETPOST('contextpage', 'aZ') : 'contractservicelist'.$mode;
@@ -412,16 +413,16 @@ if (!empty($filter_op2) && $filter_op2 != -1) {
if (!empty($filter_opcloture) && $filter_opcloture != -1) {
$param .= '&filter_opcloture='.urlencode($filter_opcloture);
}
-if ($filter_dateouvertureprevue != '') {
+if ($filter_dateouvertureprevue_start != '') {
$param .= '&opouvertureprevueday='.$opouvertureprevueday.'&opouvertureprevuemonth='.$opouvertureprevuemonth.'&opouvertureprevueyear='.$opouvertureprevueyear;
}
-if ($filter_date1 != '') {
+if ($filter_date1_start != '') {
$param .= '&op1day='.$op1day.'&op1month='.$op1month.'&op1year='.$op1year;
}
-if ($filter_date2 != '') {
+if ($filter_date2_start != '') {
$param .= '&op2day='.$op2day.'&op2month='.$op2month.'&op2year='.$op2year;
}
-if ($filter_datecloture != '') {
+if ($filter_datecloture_start != '') {
$param .= '&opclotureday='.$op2day.'&opcloturemonth='.$op2month.'&opclotureyear='.$op2year;
}
if ($optioncss != '') {
diff --git a/htdocs/core/class/notify.class.php b/htdocs/core/class/notify.class.php
index 2e0a71460ba..bb37293354e 100644
--- a/htdocs/core/class/notify.class.php
+++ b/htdocs/core/class/notify.class.php
@@ -515,7 +515,7 @@ class Notify
case 'SHIPPING_VALIDATE':
$link = ''.$newref.'';
$dir_output = $conf->expedition->dir_output."/sending/".get_exdir(0, 0, 0, 1, $object, 'shipment');
- $object_type = 'expedition';
+ $object_type = 'shipping';
$labeltouse = $conf->global->SHIPPING_VALIDATE_TEMPLATE;
$mesg = $outputlangs->transnoentitiesnoconv("EMailTextExpeditionValidated", $link);
break;
diff --git a/htdocs/core/lib/admin.lib.php b/htdocs/core/lib/admin.lib.php
index 683b92fb8d9..ef5b3eab061 100644
--- a/htdocs/core/lib/admin.lib.php
+++ b/htdocs/core/lib/admin.lib.php
@@ -1528,10 +1528,11 @@ function complete_elementList_with_modules(&$elementList)
* @param array $tableau Array of constants array('key'=>array('type'=>type, 'label'=>label)
* where type can be 'string', 'text', 'textarea', 'html', 'yesno', 'emailtemplate:xxx', ...
* @param int $strictw3c 0=Include form into table (deprecated), 1=Form is outside table to respect W3C (deprecated), 2=No form nor button at all, 3=No form nor button at all and each field has a unique name (form is output by caller, recommended)
- * @param string $helptext Help
+ * @param string $helptext Tooltip help to use for the column name of values
+ * @param string $text Text to use for the column name of values
* @return void
*/
-function form_constantes($tableau, $strictw3c = 0, $helptext = '')
+function form_constantes($tableau, $strictw3c = 0, $helptext = '', $text = 'Value')
{
global $db, $langs, $conf, $user;
global $_Avery_Labels;
@@ -1552,7 +1553,7 @@ function form_constantes($tableau, $strictw3c = 0, $helptext = '')
print ' |
| '.$userstatic->getNomUrl(1);
if ($obj->type == 'email') {
if (isValidEmail($obj->email)) {
diff --git a/htdocs/viewimage.php b/htdocs/viewimage.php
index e01bad39d77..9c584f5b8bb 100644
--- a/htdocs/viewimage.php
+++ b/htdocs/viewimage.php
@@ -282,10 +282,14 @@ if (preg_match('/\.\./', $fullpath_original_file) || preg_match('/[<>|]/', $full
if ($modulepart == 'barcode') {
- $generator = GETPOST("generator", "alpha");
- $code = GETPOST("code", 'none'); // This can be rich content (qrcode, datamatrix, ...)
- $encoding = GETPOST("encoding", "alpha");
- $readable = GETPOST("readable", 'alpha') ?GETPOST("readable", "alpha") : "Y";
+ $generator = GETPOST("generator", "aZ09");
+ $encoding = GETPOST("encoding", "aZ09");
+ $readable = GETPOST("readable", 'aZ09') ? GETPOST("readable", "aZ09") : "Y";
+ if (in_array($encoding, array('EAN8', 'EAN13'))) {
+ $code = GETPOST("code", 'alphanohtml');
+ } else {
+ $code = GETPOST("code", 'none'); // This can be rich content (qrcode, datamatrix, ...)
+ }
if (empty($generator) || empty($encoding)) {
print 'Error: Parameter "generator" or "encoding" not defined';
|