|
124 | 124 | } |
125 | 125 |
|
126 | 126 | // Opzioni aggiuntive per gli Interventi |
127 | | - elseif ($final_module->getTranslation('title') == 'Attività') { |
| 127 | + elseif ($final_module->name == 'Interventi') { |
128 | 128 | echo ' |
129 | 129 | <div class="col-md-6"> |
130 | 130 | {[ "type": "select", "label": "'.tr('Stato').'", "name": "id_stato_intervento", "required": 1, "values": "query=SELECT `in_statiintervento`.`id`, `in_statiintervento_lang`.`title` as `descrizione`, `colore` AS _bgcolor_ FROM `in_statiintervento` LEFT JOIN `in_statiintervento_lang` ON (`in_statiintervento`.`id` = `in_statiintervento_lang`.`id_record` AND `in_statiintervento_lang`.`id_lang` = '.prepare(Models\Locale::getDefault()->id).') WHERE `deleted_at` IS NULL AND `is_bloccato` = 0 ORDER BY `title`" ]} |
|
136 | 136 | } |
137 | 137 |
|
138 | 138 | // Opzioni aggiuntive per i Contratti |
139 | | - elseif ($final_module->getTranslation('title') == 'Contratti') { |
| 139 | + elseif ($final_module->name == 'Contratti') { |
140 | 140 | $stato_predefinito = StatoContratto::where('name', 'Bozza')->first()->id; |
141 | 141 |
|
142 | 142 | echo ' |
|
146 | 146 | } |
147 | 147 |
|
148 | 148 | // Opzioni aggiuntive per i DDT |
149 | | - elseif (in_array($final_module->getTranslation('title'), ['Ddt in uscita', 'Ddt in entrata'])) { |
| 149 | + elseif (in_array($final_module->name, ['Ddt in uscita', 'Ddt in entrata'])) { |
150 | 150 | $stato_predefinito = Stato::where('name', 'Bozza')->first()->id; |
151 | 151 |
|
152 | 152 | echo ' |
|
160 | 160 | } |
161 | 161 |
|
162 | 162 | // Opzioni aggiuntive per gli Ordini |
163 | | - elseif (in_array($final_module->getTranslation('title'), ['Ordini cliente', 'Ordini fornitore'])) { |
| 163 | + elseif (in_array($final_module->name, ['Ordini cliente', 'Ordini fornitore'])) { |
164 | 164 | $stato_predefinito = StatoOrdine::where('name', 'Bozza')->first()->id; |
165 | 165 |
|
166 | 166 | echo ' |
|
190 | 190 | } |
191 | 191 |
|
192 | 192 | // Conto, rivalsa INPS, ritenuta d'acconto e ritenuta previdenziale |
193 | | -if (in_array($final_module->getTranslation('title'), ['Fatture di vendita', 'Fatture di acquisto']) && !in_array($original_module->getTranslation('title'), ['Fatture di vendita', 'Fatture di acquisto'])) { |
| 193 | +if (in_array($final_module->name, ['Fatture di vendita', 'Fatture di acquisto']) && !in_array($original_module->name, ['Fatture di vendita', 'Fatture di acquisto'])) { |
194 | 194 | $id_rivalsa_inps = setting('Cassa previdenziale predefinita'); |
195 | 195 | if ($dir == 'uscita') { |
196 | 196 | $id_ritenuta_acconto = $documento->anagrafica->id_ritenuta_acconto_acquisti; |
|
337 | 337 | <tbody id="righe_documento_importato">'; |
338 | 338 |
|
339 | 339 | foreach ($righe as $i => $riga) { |
340 | | - if ($final_module->getTranslation('title') == 'Ordini fornitore') { |
| 340 | + if ($final_module->name == 'Ordini fornitore') { |
341 | 341 | $qta_rimanente = $riga['qta']; |
342 | 342 | } else { |
343 | 343 | $qta_rimanente = $riga['qta_rimanente']; |
344 | 344 | } |
345 | 345 |
|
346 | 346 | $attr = 'checked="checked"'; |
347 | | - if ($original_module->getTranslation('title') == 'Preventivi') { |
| 347 | + if ($original_module->name == 'Preventivi') { |
348 | 348 | if (empty($riga['confermato']) && $riga['is_descrizione'] == 0) { |
349 | 349 | $attr = ''; |
350 | 350 | } |
|
0 commit comments