diff --git a/htdocs/comm/mailing/advtargetemailing.php b/htdocs/comm/mailing/advtargetemailing.php index 81c29f687ce..e0a3e5cea79 100644 --- a/htdocs/comm/mailing/advtargetemailing.php +++ b/htdocs/comm/mailing/advtargetemailing.php @@ -22,6 +22,8 @@ * \brief Page to define emailing targets */ +if (! defined('NOSTYLECHECK')) define('NOSTYLECHECK','1'); + require '../../main.inc.php'; require_once DOL_DOCUMENT_ROOT . '/comm/mailing/class/mailing.class.php'; @@ -404,14 +406,8 @@ if ($_POST["button_removefilter"]) { * View */ -$extrajs = array ( - '/includes/jquery/plugins/multiselect/js/ui.multiselect.js' -); -$extracss = array ( - '/includes/jquery/plugins/multiselect/css/ui.multiselect.css', -); -llxHeader('', $langs->trans("MailAdvTargetRecipients"), '', '', '', '', $extrajs, $extracss); +llxHeader('', $langs->trans("MailAdvTargetRecipients")); print ''; - $return .= ''; - - if ($showempty) - $return .= ''; - - // Find if keys is in selected array value - if (is_array($selected_array) && count($selected_array)>0) { - $intersect_array = array_intersect_key($options_array, array_flip($selected_array)); - } else { - $intersect_array=array(); - } - - if (count($options_array) > 0) { - foreach ($options_array as $keyoption => $valoption) { - // If key is in intersect table then it have to e selected - $selected = ''; - if (count ( $intersect_array ) > 0) { - if (array_key_exists ( $keyoption, $intersect_array )) { - $selected = ' selected="selected"'; - } - } - $return .= '' . $valoption . ''; - } - } - - $return .= ''; - + $form=new Form($this->db); + $return = $form->multiselectarray($htmlname, $options_array, $selected_array,0,0,'',0,295); return $return; } @@ -448,7 +407,7 @@ class FormAdvTargetEmailing extends Form dol_print_error($this->db); } - return $this->advMultiselectarray ( $htmlname, $options_array, $selected_array ); + return $this->advMultiselectarray( $htmlname, $options_array, $selected_array ); } /** diff --git a/htdocs/install/mysql/migration/5.0.0-6.0.0.sql b/htdocs/install/mysql/migration/5.0.0-6.0.0.sql index 8e4785ab4d9..5836cb740dc 100644 --- a/htdocs/install/mysql/migration/5.0.0-6.0.0.sql +++ b/htdocs/install/mysql/migration/5.0.0-6.0.0.sql @@ -534,3 +534,5 @@ ALTER TABLE llx_blockedlog_authority ADD INDEX signature (signature); UPDATE llx_bank SET label= '(SupplierInvoicePayment)' WHERE label= 'Règlement fournisseur'; UPDATE llx_bank SET label= '(CustomerInvoicePayment)' WHERE label= 'Règlement client'; + +ALTER TABLE llx_mailing_cibles MODIFY COLUMN source_url varchar(1000); \ No newline at end of file diff --git a/htdocs/install/mysql/tables/llx_mailing_cibles.sql b/htdocs/install/mysql/tables/llx_mailing_cibles.sql index f3031069220..eec4a655da2 100644 --- a/htdocs/install/mysql/tables/llx_mailing_cibles.sql +++ b/htdocs/install/mysql/tables/llx_mailing_cibles.sql @@ -30,7 +30,7 @@ create table llx_mailing_cibles other varchar(255) NULL, tag varchar(128) NULL, statut smallint NOT NULL DEFAULT 0, -- -1 = error, 0 = not sent, ... - source_url varchar(160), + source_url varchar(1000), source_id integer, source_type varchar(16), date_envoi datetime,