Fix input for progress not shown on lines in edit mode

This commit is contained in:
Sylvain Legrand 2023-02-01 22:42:41 +01:00
parent e67eac97e7
commit eaf125e028

View File

@ -70,7 +70,7 @@ if (!empty($inputalsopricewithtax)) {
if (in_array($object->element, array('propal', 'supplier_proposal', 'facture', 'facturerec', 'invoice', 'commande', 'order', 'order_supplier', 'invoice_supplier', 'invoice_supplier_rec'))) { if (in_array($object->element, array('propal', 'supplier_proposal', 'facture', 'facturerec', 'invoice', 'commande', 'order', 'order_supplier', 'invoice_supplier', 'invoice_supplier_rec'))) {
$colspan++; // With this, there is a column move button $colspan++; // With this, there is a column move button
} }
if (isModEnabled("multicurrency") && $this->multicurrency_code != $conf->currency) { if (isModEnabled("multicurrency") && $object->multicurrency_code != $conf->currency) {
$colspan += 2; $colspan += 2;
} }
if (isModEnabled('asset') && $object->element == 'invoice_supplier') { if (isModEnabled('asset') && $object->element == 'invoice_supplier') {
@ -218,7 +218,7 @@ $coldisplay++;
} }
print '></td>'; print '></td>';
if (isModEnabled("multicurrency") && $this->multicurrency_code != $conf->currency) { if (isModEnabled("multicurrency") && $object->multicurrency_code != $conf->currency) {
$coldisplay++; $coldisplay++;
print '<td class="right"><input rel="'.$object->multicurrency_tx.'" type="text" class="flat right" size="5" id="multicurrency_subprice" name="multicurrency_subprice" value="'.(GETPOSTISSET('multicurrency_subprice') ? GETPOST('multicurrency_subprice', 'alpha') : price($line->multicurrency_subprice)).'" /></td>'; print '<td class="right"><input rel="'.$object->multicurrency_tx.'" type="text" class="flat right" size="5" id="multicurrency_subprice" name="multicurrency_subprice" value="'.(GETPOSTISSET('multicurrency_subprice') ? GETPOST('multicurrency_subprice', 'alpha') : price($line->multicurrency_subprice)).'" /></td>';
} }
@ -286,7 +286,7 @@ $coldisplay++;
<?php <?php
// Progession for situation invoices // Progession for situation invoices
if ($this->situation_cycle_ref) { if ($object->situation_cycle_ref) {
$coldisplay++; $coldisplay++;
print '<td class="nowrap right linecolcycleref"><input class="right" type="text" size="1" value="'.(GETPOSTISSET('progress') ? GETPOST('progress') : $line->situation_percent).'" name="progress">%</td>'; print '<td class="nowrap right linecolcycleref"><input class="right" type="text" size="1" value="'.(GETPOSTISSET('progress') ? GETPOST('progress') : $line->situation_percent).'" name="progress">%</td>';
$coldisplay++; $coldisplay++;
@ -490,7 +490,7 @@ jQuery(document).ready(function()
} }
}); });
<?php if (in_array($this->table_element_line, array('propaldet', 'commandedet', 'facturedet'))) { ?> <?php if (in_array($object->table_element_line, array('propaldet', 'commandedet', 'facturedet'))) { ?>
$("#date_start, #date_end").focusout(function() { $("#date_start, #date_end").focusout(function() {
if ( $(this).val() == '' && !$(this).hasClass('inputmandatory') ) { if ( $(this).val() == '' && !$(this).hasClass('inputmandatory') ) {
$(this).addClass('inputmandatory'); $(this).addClass('inputmandatory');