- {[ "type": "select", "label": "'.tr('Provenienza cliente').'", "name": "id_provenienza", "ajax-source": "provenienze", "value": "$id_provenienza$", "icon-after": "add|'.Module::where('name', 'Provenienze')->first()->id.'" ]}
+ {[ "type": "select", "label": "'.tr('Provenienza').'", "name": "id_provenienza", "ajax-source": "provenienze", "value": "$id_provenienza$", "icon-after": "add|'.Module::where('name', 'Provenienze')->first()->id.'" ]}
@@ -517,7 +517,7 @@ if ($is_cliente or $is_fornitore or $is_tecnico) {
- {[ "type": "select", "label": "'.tr('Banca predefinita per accrediti').'", "name": "idbanca_vendite", "ajax-source": "banche", "select-options": '.json_encode(['id_anagrafica' => $anagrafica_azienda->id]).', "value": "$idbanca_vendite$", "help": "'.tr("Banca predefinita dell'Azienda su cui accreditare i pagamenti").'" ]}
+ {[ "type": "select", "label": "'.tr('Banca predefinita azienda per accrediti').'", "name": "idbanca_vendite", "ajax-source": "banche", "select-options": '.json_encode(['id_anagrafica' => $anagrafica_azienda->id]).', "value": "$idbanca_vendite$", "help": "'.tr("Banca predefinita dell'Azienda su cui accreditare i pagamenti").'" ]}
@@ -588,7 +588,7 @@ if ($is_cliente or $is_fornitore or $is_tecnico) {
- {[ "type": "select", "label": "'.tr('Banca predefinita per addebiti').'", "name": "idbanca_acquisti", "ajax-source": "banche", "select-options": '.json_encode(['id_anagrafica' => $anagrafica_azienda->id]).', "value": "$idbanca_acquisti$", "help": "'.tr("Banca predefinita dell'Azienda da cui addebitare i pagamenti").'" ]}
+ {[ "type": "select", "label": "'.tr('Banca predefinita azienda per addebiti').'", "name": "idbanca_acquisti", "ajax-source": "banche", "select-options": '.json_encode(['id_anagrafica' => $anagrafica_azienda->id]).', "value": "$idbanca_acquisti$", "help": "'.tr("Banca predefinita dell'Azienda da cui addebitare i pagamenti").'" ]}
diff --git a/modules/segmenti/add.php b/modules/segmenti/add.php
index c5d02e931..025826238 100755
--- a/modules/segmenti/add.php
+++ b/modules/segmenti/add.php
@@ -35,7 +35,7 @@ include_once __DIR__.'/../../core.php';
- {[ "type": "checkbox", "label": "", "help": "", "name": "is_sezionale_add", "value": "$is_sezionale$" ]}
+ {[ "type": "checkbox", "label": "", "help": "", "name": "is_sezionale_add", "value": "$is_sezionale$", "values": "Sezionale,Segmento" ]}
{[ "type": "select", "label": "", "name": "module", "required": 1, "values": "query=SELECT `zz_modules`.`id`, IF(`title`!='', `title`, `title`) AS descrizione FROM `zz_modules` LEFT JOIN `zz_modules_lang` ON (`zz_modules`.`id` = `zz_modules_lang`.`id_record` AND `zz_modules_lang`.`id_lang` = id); ?>) WHERE `enabled` = 1 AND `options` != 'custom' ORDER BY `title` ASC", "value": "" ]}
diff --git a/modules/segmenti/ajax/select.php b/modules/segmenti/ajax/select.php
index a57bc9430..30a34804e 100644
--- a/modules/segmenti/ajax/select.php
+++ b/modules/segmenti/ajax/select.php
@@ -33,7 +33,7 @@ switch ($resource) {
$predefined_addebito = Segmento::where('predefined_addebito', 1)->where('id_module', $id_module)->first();
if (isset($id_module)) {
- $query = 'SELECT `zz_segments`.`id`, `zz_segments_lang`.`title` AS descrizione FROM `zz_segments` LEFT JOIN `zz_segments_lang` ON (`zz_segments`.`id` = `zz_segments_lang`.`id_record` AND `zz_segments_lang`.`id_lang` = '.prepare(Models\Locale::getDefault()->id).') INNER JOIN `zz_group_segment` ON `zz_segments`.`id` = `zz_group_segment`.`id_segment` |where| ORDER BY `title` ASC';
+ $query = 'SELECT `zz_segments`.`id`, CONCAT(`zz_segments_lang`.`title`, " ", IF(`zz_segments`.`is_sezionale` = 1, "(Sezionale)", "(Segmento)")) AS descrizione FROM `zz_segments` LEFT JOIN `zz_segments_lang` ON (`zz_segments`.`id` = `zz_segments_lang`.`id_record` AND `zz_segments_lang`.`id_lang` = '.prepare(Models\Locale::getDefault()->id).') INNER JOIN `zz_group_segment` ON `zz_segments`.`id` = `zz_group_segment`.`id_segment` |where| ORDER BY `title` ASC';
$where[] = '`zz_segments`.`id_module` = '.prepare($id_module);
$where[] = '`zz_group_segment`.`id_gruppo` = '.prepare($user->idgruppo);
diff --git a/modules/segmenti/edit.php b/modules/segmenti/edit.php
index cb56e4f58..0d8e9c12e 100755
--- a/modules/segmenti/edit.php
+++ b/modules/segmenti/edit.php
@@ -47,7 +47,7 @@ use Models\Module;
- {[ "type": "checkbox", "label": "", "help": "", "name": "is_sezionale", "value": "$is_sezionale$", "extra": "readonly" ]}
+ {[ "type": "checkbox", "label": "", "help": "", "name": "is_sezionale", "value": "$is_sezionale$", "extra": "readonly", "values": "Sezionale,Segmento" ]}