NEW add alert before change thirdparty in takepos

With some prices rules, change thirdparty should only done before add products to draft invoice.
We can't block it but display an alert can be done for users
This commit is contained in:
ptibogxiv 2020-10-18 15:36:04 +02:00 committed by GitHub
parent ef182bed07
commit e1a7de32e1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -610,6 +610,10 @@ if (!empty($type))
if ($type == 'f') $label = 'NewSupplier';
}
if ($contextpage = 'poslist' && ( !empty($conf->global->PRODUIT_MULTIPRICES) || !empty($conf->global->PRODUIT_CUSTOMER_PRICES) || !empty($conf->global->PRODUIT_CUSTOMER_PRICES_BY_QTY_MULTIPRICES))) {
print get_htmloutput_mesg(img_warning('default') . ' ' . $langs->trans("BecarefullChangeThirdpartyBeforeAddProductToInvoice"), '', 'warning', 1);
}
// Show the new button only when this page is not opend from the Extended POS (pop-up window)
// but allow it too, when a user has the rights to create a new customer
if ($contextpage != 'poslist')