Fix minori

This commit is contained in:
Luca 2018-11-02 17:49:11 +01:00
parent f51e0802b1
commit 46ddf6958a
3 changed files with 44 additions and 36 deletions

View File

@ -94,37 +94,41 @@ if (!$cliente) {
</div> </div>
<div class="row"> <div class="row">
<div class="col-md-4">
<div class="col-md-<?php echo (empty($record['indirizzo2'])) ? '6' : '4'; ?>">
{[ "type": "text", "label": "<?php echo tr('Indirizzo'); ?>", "name": "indirizzo", "value": "$indirizzo$" ]} {[ "type": "text", "label": "<?php echo tr('Indirizzo'); ?>", "name": "indirizzo", "value": "$indirizzo$" ]}
</div> </div>
<div class="col-md-4"> <div class="col-md-2<?php echo (empty($record['indirizzo2'])) ? ' hide' : ''; ?>">
{[ "type": "text", "label": "<?php echo tr('Indirizzo2'); ?>", "name": "indirizzo2", "value": "$indirizzo2$" ]} {[ "type": "text", "label": "<?php echo tr('Indirizzo2'); ?>", "name": "indirizzo2", "value": "$indirizzo2$" ]}
</div> </div>
<div class="col-md-2">
{[ "type": "text", "label": "<?php echo tr('C.A.P.'); ?>", "name": "cap", "maxlength": 5, "class": "text-center", "value": "$cap$" ]}
</div>
<div class="col-md-4"> <div class="col-md-4">
{[ "type": "text", "label": "<?php echo tr('Città'); ?>", "name": "citta", "class": "text-center", "value": "$citta$" ]} {[ "type": "text", "label": "<?php echo tr('Città'); ?>", "name": "citta", "class": "text-center", "value": "$citta$" ]}
</div> </div>
</div> </div>
<div class="row"> <div class="row">
<div class="col-md-2">
{[ "type": "select", "label": "<?php echo tr('Nazione'); ?>", "name": "id_nazione", "values": "query=SELECT id AS id, nome AS descrizione FROM an_nazioni ORDER BY nome ASC", "value": "$id_nazione$" ]}
</div>
<div class="col-md-4">
{[ "type": "select", "label": "<?php echo tr('Zona'); ?>", "name": "idzona", "values": "query=SELECT id, CONCAT_WS( ' - ', nome, descrizione) AS descrizione FROM an_zone ORDER BY descrizione ASC", "value": "$idzona$", "placeholder": "<?php echo tr('Nessuna zona'); ?>", "icon-after": "add|<?php echo Modules::get('Zone')['id']; ?>" ]}
</div>
<div class="col-md-2">
{[ "type": "text", "label": "<?php echo tr('C.A.P.'); ?>", "name": "cap", "maxlength": 5, "class": "text-center", "value": "$cap$" ]}
</div>
<div class="col-md-2"> <div class="col-md-3">
{[ "type": "text", "label": "<?php echo tr('Provincia'); ?>", "name": "provincia", "maxlength": 2, "class": "text-center", "value": "$provincia$" ]} {[ "type": "text", "label": "<?php echo tr('Provincia'); ?>", "name": "provincia", "maxlength": 2, "class": "text-center", "value": "$provincia$" ]}
</div> </div>
<div class="col-md-2"> <div class="col-md-3">
{[ "type": "select", "label": "<?php echo tr('Nazione'); ?>", "name": "id_nazione", "values": "query=SELECT id AS id, nome AS descrizione FROM an_nazioni ORDER BY nome ASC", "value": "$id_nazione$" ]}
</div>
<div class="col-md-3">
{[ "type": "select", "label": "<?php echo tr('Zona'); ?>", "name": "idzona", "values": "query=SELECT id, CONCAT_WS( ' - ', nome, descrizione) AS descrizione FROM an_zone ORDER BY descrizione ASC", "value": "$idzona$", "placeholder": "<?php echo tr('Nessuna zona'); ?>", "icon-after": "add|<?php echo Modules::get('Zone')['id']; ?>" ]}
</div>
<div class="col-md-3">
{[ "type": "number", "label": "<?php echo tr('Distanza'); ?>", "name": "km", "decimals":"1", "class": "text-center", "value": "$km$", "icon-after": "Km" ]} {[ "type": "number", "label": "<?php echo tr('Distanza'); ?>", "name": "km", "decimals":"1", "class": "text-center", "value": "$km$", "icon-after": "Km" ]}
</div> </div>
</div> </div>

View File

@ -21,7 +21,7 @@ include_once __DIR__.'/../../core.php';
</div> </div>
<div class="col-md-4"> <div class="col-md-4">
{[ "type": "select", "label": "<?php echo tr('Modulo'); ?>", "name": "module", "required": 1, "values": "query=SELECT id, name AS descrizione FROM zz_modules WHERE ( enabled = 1 AND options != 'custom' ) OR id = <?php echo $record['id_module']; ?> ORDER BY name ASC", "value": "$id_module$", "extra": "<?php echo ($record['predefined']) ? 'readonly' : ''; ?>" ]} {[ "type": "select", "label": "<?php echo tr('Modulo'); ?>", "name": "module", "required": 1, "values": "query=SELECT id, name AS descrizione FROM zz_modules WHERE ( enabled = 1 AND options != 'custom' ) OR id = <?php echo $record['id_module']; ?> ORDER BY name ASC", "value": "<?php echo $record['id_module']; ?>", "extra": "<?php echo ($record['predefined']) ? 'readonly' : ''; ?>" ]}
</div> </div>
<div class="col-md-4"> <div class="col-md-4">

View File

@ -35,18 +35,20 @@ echo '
echo ' echo '
<td colspan=2> <td colspan=2>
'.tr('P.Iva').': <b>'.strtoupper($c_piva).'</b> '.tr('P.Iva').': <b>'.strtoupper($c_piva).'</b>
</td> </td>';
</tr>';
} else { } else {
echo ' echo '
<td colspan=2> <td colspan=2>
'.tr('C.F.').': <b>'.strtoupper($c_codicefiscale).'</b> '.tr('C.F.').': <b>'.strtoupper($c_codicefiscale).'</b>
</td> </td>';
</tr>';
} }
// riga 2 echo '</tr>';
echo '
//Indirizzo
if (!empty($c_indirizzo) or !empty($c_cap) or !empty($c_citta) or !empty($c_provincia)) {
echo '
<tr> <tr>
<td colspan="4"> <td colspan="4">
'.((!empty($c_indirizzo)) ? tr('Via').': <b>'.$c_indirizzo.'</b>' : '').' '.((!empty($c_indirizzo)) ? tr('Via').': <b>'.$c_indirizzo.'</b>' : '').'
@ -56,13 +58,15 @@ echo '
</td> </td>
</tr>'; </tr>';
}
echo ' echo '
<tr> <tr>
<td colspan="4"> <td colspan="4">
'.tr('Telefono').': <b>'.$c_telefono.'</b>'; '.tr('Telefono').': <b>'.$c_telefono.'</b>';
if (!empty($c_cellulare)) { if (!empty($c_cellulare)) {
echo' - '.tr('Cellulare').': <b>'.$c_cellulare.'</b>'; echo' - '.tr('Cellulare').': <b>'.$c_cellulare.'</b>';
} }
echo ' echo '
</td> </td>
</tr>'; </tr>';