mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2026-01-04 16:12:39 +01:00
Merge branch '17.0' of git@github.com:Dolibarr/dolibarr.git into develop
This commit is contained in:
@@ -3067,8 +3067,8 @@ if ($action == 'create') {
|
||||
$remise_absolue = (!empty($expesrc->remise_absolue) ? $expesrc->remise_absolue : (!empty($soc->remise_absolue) ? $soc->remise_absolue : 0));
|
||||
|
||||
if (isModEnabled('multicurrency')) {
|
||||
$currency_code = (!empty($expesrc->currency_code) ? $expesrc->currency_code : (!empty($soc->currency_code) ? $soc->currency_code : $objectsrc->multicurrency_code));
|
||||
$currency_tx = (!empty($expesrc->currency_tx) ? $expesrc->currency_tx : (!empty($soc->currency_tx) ? $soc->currency_tx : $objectsrc->currency_tx));
|
||||
$currency_code = (!empty($expesrc->multicurrency_code) ? $expesrc->multicurrency_code : (!empty($soc->multicurrency_code) ? $soc->multicurrency_code : $objectsrc->multicurrency_code));
|
||||
$currency_tx = (!empty($expesrc->multicurrency_tx) ? $expesrc->multicurrency_tx : (!empty($soc->multicurrency_tx) ? $soc->multicurrency_tx : $objectsrc->multicurrency_tx));
|
||||
}
|
||||
|
||||
//Replicate extrafields
|
||||
@@ -4678,16 +4678,16 @@ if ($action == 'create') {
|
||||
if ($displayWarranty) {
|
||||
// Retained Warranty
|
||||
print '<tr class="retained-warranty-lines" ><td>';
|
||||
print '<table id="retained-warranty-table" class="nobordernopadding" width="100%"><tr><td>';
|
||||
print '<table id="retained-warranty-table" class="nobordernopadding centpercent"><tr><td>';
|
||||
print $langs->trans('RetainedWarranty');
|
||||
print '</td>';
|
||||
if ($action != 'editretainedwarranty' && $user->rights->facture->creer) {
|
||||
if ($action != 'editretainedwarranty' && $user->rights->facture->creer && $object->statut == Facture::STATUS_DRAFT) {
|
||||
print '<td align="right"><a class="editfielda" href="'.$_SERVER["PHP_SELF"].'?action=editretainedwarranty&token='.newToken().'&facid='.$object->id.'">'.img_edit($langs->trans('setretainedwarranty'), 1).'</a></td>';
|
||||
}
|
||||
|
||||
print '</tr></table>';
|
||||
print '</td><td>';
|
||||
if ($action == 'editretainedwarranty') {
|
||||
if ($action == 'editretainedwarranty' && $object->statut == Facture::STATUS_DRAFT) {
|
||||
print '<form id="retained-warranty-form" method="POST" action="'.$_SERVER['PHP_SELF'].'?facid='.$object->id.'">';
|
||||
print '<input type="hidden" name="action" value="setretainedwarranty">';
|
||||
print '<input type="hidden" name="token" value="'.newToken().'">';
|
||||
@@ -4704,7 +4704,7 @@ if ($action == 'create') {
|
||||
print '<table id="retained-warranty-cond-reglement-table" class="nobordernopadding" width="100%"><tr><td>';
|
||||
print $langs->trans('PaymentConditionsShortRetainedWarranty');
|
||||
print '</td>';
|
||||
if ($action != 'editretainedwarrantypaymentterms' && $user->rights->facture->creer) {
|
||||
if ($action != 'editretainedwarrantypaymentterms' && $user->rights->facture->creer && $object->statut == Facture::STATUS_DRAFT) {
|
||||
print '<td align="right"><a class="editfielda" href="'.$_SERVER["PHP_SELF"].'?action=editretainedwarrantypaymentterms&token='.newToken().'&facid='.$object->id.'">'.img_edit($langs->trans('setPaymentConditionsShortRetainedWarranty'), 1).'</a></td>';
|
||||
}
|
||||
|
||||
@@ -4715,7 +4715,7 @@ if ($action == 'create') {
|
||||
$defaultDate = $object->date;
|
||||
}
|
||||
|
||||
if ($action == 'editretainedwarrantypaymentterms') {
|
||||
if ($action == 'editretainedwarrantypaymentterms' && $object->statut == Facture::STATUS_DRAFT) {
|
||||
//date('Y-m-d',$object->date_lim_reglement)
|
||||
print '<form method="POST" action="'.$_SERVER['PHP_SELF'].'?facid='.$object->id.'">';
|
||||
print '<input type="hidden" name="action" value="setretainedwarrantyconditions">';
|
||||
@@ -4739,7 +4739,7 @@ if ($action == 'create') {
|
||||
print '<table id="retained-warranty-date-limit-table" class="nobordernopadding" width="100%"><tr><td>';
|
||||
print $langs->trans('RetainedWarrantyDateLimit');
|
||||
print '</td>';
|
||||
if ($action != 'editretainedwarrantydatelimit' && $user->rights->facture->creer) {
|
||||
if ($action != 'editretainedwarrantydatelimit' && $user->rights->facture->creer && $object->statut == Facture::STATUS_DRAFT) {
|
||||
print '<td align="right"><a class="editfielda" href="'.$_SERVER["PHP_SELF"].'?action=editretainedwarrantydatelimit&token='.newToken().'&facid='.$object->id.'">'.img_edit($langs->trans('setretainedwarrantyDateLimit'), 1).'</a></td>';
|
||||
}
|
||||
|
||||
@@ -4750,7 +4750,7 @@ if ($action == 'create') {
|
||||
$defaultDate = $object->date;
|
||||
}
|
||||
|
||||
if ($action == 'editretainedwarrantydatelimit') {
|
||||
if ($action == 'editretainedwarrantydatelimit' && $object->statut == Facture::STATUS_DRAFT) {
|
||||
//date('Y-m-d',$object->date_lim_reglement)
|
||||
print '<form method="POST" action="'.$_SERVER['PHP_SELF'].'?facid='.$object->id.'">';
|
||||
print '<input type="hidden" name="action" value="setretainedwarrantydatelimit">';
|
||||
|
||||
Reference in New Issue
Block a user