Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop
This commit is contained in:
commit
bbe5e398a5
@ -265,6 +265,11 @@ if (empty($reshook))
|
||||
$langs->load("errors");
|
||||
setEventMessages($langs->trans("ErrorFieldRequired", $langs->transnoentities("Firstname")), null, 'errors');
|
||||
}
|
||||
if ($morphy == 'mor' && empty($societe)) {
|
||||
$error++;
|
||||
$langs->load("errors");
|
||||
setEventMessages($langs->trans("ErrorFieldRequired", $langs->transnoentities("Company")), null, 'errors');
|
||||
}
|
||||
// Test si le login existe deja
|
||||
if (empty($conf->global->ADHERENT_LOGIN_NOT_REQUIRED))
|
||||
{
|
||||
@ -514,6 +519,11 @@ if (empty($reshook))
|
||||
setEventMessages($langs->trans("ErrorFieldRequired", $langs->transnoentities("Password")), null, 'errors');
|
||||
}
|
||||
}
|
||||
if ($morphy == 'mor' && empty($societe)) {
|
||||
$error++;
|
||||
$langs->load("errors");
|
||||
setEventMessages($langs->trans("ErrorFieldRequired", $langs->transnoentities("Company")), null, 'errors');
|
||||
}
|
||||
if ($morphy != 'mor' && empty($lastname)) {
|
||||
$error++;
|
||||
$langs->load("errors");
|
||||
|
||||
@ -356,8 +356,8 @@ PaymentTypeCB=Credit card
|
||||
PaymentTypeShortCB=Credit card
|
||||
PaymentTypeCHQ=Check
|
||||
PaymentTypeShortCHQ=Check
|
||||
PaymentTypeTIP=Interbank Payment
|
||||
PaymentTypeShortTIP=Interbank Payment
|
||||
PaymentTypeTIP=TIP (Documents against Payment)
|
||||
PaymentTypeShortTIP=TIP Payment
|
||||
PaymentTypeVAD=On line payment
|
||||
PaymentTypeShortVAD=On line payment
|
||||
PaymentTypeTRA=Bank draft
|
||||
|
||||
@ -176,7 +176,6 @@ Upload=Send file
|
||||
ToLink=Link
|
||||
Select=Select
|
||||
Choose=Choose
|
||||
ChooseLangage=Please choose your language
|
||||
Resize=Resize
|
||||
Recenter=Recenter
|
||||
Author=Author
|
||||
|
||||
@ -1121,7 +1121,7 @@ else
|
||||
else if ($object->id > 0)
|
||||
{
|
||||
// Fiche en mode edition
|
||||
if ($action == 'edit' && ($user->rights->produit->creer || $user->rights->service->creer))
|
||||
if ($action == 'edit' && ((($object->type == Product::TYPE_PRODUCT && $user->rights->produit->creer) || ($object->type == Product::TYPE_SERVICE && $user->rights->service->creer))))
|
||||
{
|
||||
//WYSIWYG Editor
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/class/doleditor.class.php';
|
||||
@ -1733,7 +1733,8 @@ if (empty($reshook))
|
||||
{
|
||||
if ($action == '' || $action == 'view')
|
||||
{
|
||||
if ($user->rights->produit->creer || $user->rights->service->creer)
|
||||
if (($object->type == Product::TYPE_PRODUCT && $user->rights->produit->creer ) ||
|
||||
($object->type == Product::TYPE_SERVICE && $user->rights->service->creer))
|
||||
{
|
||||
if (! isset($object->no_button_edit) || $object->no_button_edit <> 1) print '<div class="inline-block divButAction"><a class="butAction" href="'.$_SERVER["PHP_SELF"].'?action=edit&id='.$object->id.'">'.$langs->trans("Modify").'</a></div>';
|
||||
|
||||
|
||||
@ -241,7 +241,7 @@ $form = new Form($db);
|
||||
|
||||
$title = $langs->trans('Status');
|
||||
|
||||
$sql = 'SELECT p.rowid, p.ref, p.label, p.price,';
|
||||
$sql = 'SELECT p.rowid, p.ref, p.label,p.description, p.price,';
|
||||
$sql.= ' p.price_ttc, p.price_base_type,p.fk_product_type,';
|
||||
$sql.= ' p.tms as datem, p.duration, p.tobuy,';
|
||||
$sql.= ' p.desiredstock, p.seuil_stock_alerte as alertstock,';
|
||||
@ -490,7 +490,7 @@ while ($i < ($limit ? min($num, $limit) : $num))
|
||||
// Multilangs
|
||||
if (! empty($conf->global->MAIN_MULTILANGS))
|
||||
{
|
||||
$sql = 'SELECT label';
|
||||
$sql = 'SELECT label,description';
|
||||
$sql .= ' FROM ' . MAIN_DB_PREFIX . 'product_lang';
|
||||
$sql .= ' WHERE fk_product = ' . $objp->rowid;
|
||||
$sql .= ' AND lang = "' . $langs->getDefaultLang() . '"';
|
||||
@ -500,6 +500,7 @@ while ($i < ($limit ? min($num, $limit) : $num))
|
||||
if ($resqlm)
|
||||
{
|
||||
$objtp = $db->fetch_object($resqlm);
|
||||
if (!empty($objtp->description)) $objp->description = $objtp->description;
|
||||
if (!empty($objtp->label)) $objp->label = $objtp->label;
|
||||
}
|
||||
}
|
||||
@ -557,7 +558,7 @@ while ($i < ($limit ? min($num, $limit) : $num))
|
||||
|
||||
print '<td class="nowrap">'.$prod->getNomUrl(1, '').'</td>';
|
||||
|
||||
print '<td>' . $objp->label . '<input type="hidden" name="desc' . $i . '" value="' . $objp->label . '" ></td>';
|
||||
print '<td>' . $objp->label . '<input type="hidden" name="desc' . $i . '" value="' . $objp->description . '" ></td>';
|
||||
|
||||
if (!empty($conf->service->enabled) && $type == 1)
|
||||
{
|
||||
|
||||
Loading…
Reference in New Issue
Block a user