Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop
This commit is contained in:
commit
b419e923c7
@ -85,12 +85,14 @@ if (! empty($conf->global->MAIN_SEARCH_FORM_ON_HOME_AREAS)) // This is usele
|
||||
{
|
||||
print '<form method="post" action="'.DOL_URL_ROOT.'/contrat/list.php">';
|
||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
||||
|
||||
print '<div class="div-table-responsive-no-min">';
|
||||
print '<table class="noborder nohover centpercent">';
|
||||
print '<tr class="liste_titre"><td colspan="3">'.$langs->trans("Search").'</td></tr>';
|
||||
print '<tr class="oddeven">';
|
||||
print '<td class="nowrap">'.$langs->trans("Contract").':</td><td><input type="text" class="flat" name="sall" size="18"></td>';
|
||||
print '<td><input type="submit" value="'.$langs->trans("Search").'" class="button"></td></tr>';
|
||||
print "</table></form>\n";
|
||||
print "</table></div></form>\n";
|
||||
print "<br>";
|
||||
}
|
||||
}
|
||||
@ -183,7 +185,7 @@ else
|
||||
dol_print_error($db);
|
||||
}
|
||||
|
||||
|
||||
print '<div class="div-table-responsive-no-min">';
|
||||
print '<table class="noborder nohover centpercent">';
|
||||
print '<tr class="liste_titre"><th colspan="2">'.$langs->trans("Statistics").' - '.$langs->trans("Services").'</th></tr>'."\n";
|
||||
$listofstatus=array(0,4,4,5); $bool=false;
|
||||
@ -232,7 +234,7 @@ foreach($listofstatus as $status)
|
||||
//if ($totalinprocess != $total)
|
||||
//print '<tr class="liste_total"><td>'.$langs->trans("Total").' ('.$langs->trans("ServicesRunning").')</td><td class="right">'.$totalinprocess.'</td></tr>';
|
||||
print '<tr class="liste_total"><td>'.$langs->trans("Total").'</td><td class="right">'.$total.'</td></tr>';
|
||||
print "</table><br>";
|
||||
print "</table></div><br>";
|
||||
|
||||
|
||||
// Draft contracts
|
||||
@ -255,6 +257,7 @@ if (! empty($conf->contrat->enabled) && $user->rights->contrat->lire)
|
||||
{
|
||||
$num = $db->num_rows($resql);
|
||||
|
||||
print '<div class="div-table-responsive-no-min">';
|
||||
print '<table class="noborder centpercent">';
|
||||
print '<tr class="liste_titre">';
|
||||
print '<th colspan="3">'.$langs->trans("DraftContracts").($num?' <span class="badge">'.$num.'</span>':'').'</th></tr>';
|
||||
@ -290,7 +293,7 @@ if (! empty($conf->contrat->enabled) && $user->rights->contrat->lire)
|
||||
{
|
||||
print '<tr class="oddeven"><td colspan="3" class="opacitymedium">'.$langs->trans("NoContracts").'</td></tr>';
|
||||
}
|
||||
print "</table><br>";
|
||||
print "</table></div><br>";
|
||||
$db->free($resql);
|
||||
}
|
||||
else
|
||||
@ -333,6 +336,7 @@ if ($result)
|
||||
$num = $db->num_rows($result);
|
||||
$i = 0;
|
||||
|
||||
print '<div class="div-table-responsive-no-min">';
|
||||
print '<table class="noborder centpercent">';
|
||||
|
||||
print '<tr class="liste_titre"><th colspan="2">'.$langs->trans("LastContracts", 5).'</th>';
|
||||
@ -368,7 +372,7 @@ if ($result)
|
||||
}
|
||||
$db->free($result);
|
||||
|
||||
print "</table>";
|
||||
print "</table></div>";
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -400,6 +404,7 @@ if ($resql)
|
||||
$num = $db->num_rows($resql);
|
||||
$i = 0;
|
||||
|
||||
print '<div class="div-table-responsive-no-min">';
|
||||
print '<table class="noborder centpercent">';
|
||||
|
||||
print '<tr class="liste_titre"><th colspan="4">'.$langs->trans("LastModifiedServices", $max).'</th>';
|
||||
@ -446,7 +451,7 @@ if ($resql)
|
||||
}
|
||||
$db->free();
|
||||
|
||||
print "</table>";
|
||||
print "</table></div>";
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -479,6 +484,7 @@ if ($resql)
|
||||
$num = $db->num_rows($resql);
|
||||
$i = 0;
|
||||
|
||||
print '<div class="div-table-responsive-no-min">';
|
||||
print '<table class="noborder centpercent">';
|
||||
|
||||
print '<tr class="liste_titre"><th colspan="4">'.$langs->trans("NotActivatedServices").' <a href="'.DOL_URL_ROOT.'/contrat/services_list.php?mode=0"><span class="badge">'.$num.'</span></a></th>';
|
||||
@ -524,7 +530,7 @@ if ($resql)
|
||||
}
|
||||
$db->free();
|
||||
|
||||
print "</table>";
|
||||
print "</table></div>";
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -558,6 +564,7 @@ if ($resql)
|
||||
$num = $db->num_rows($resql);
|
||||
$i = 0;
|
||||
|
||||
print '<div class="div-table-responsive-no-min">';
|
||||
print '<table class="noborder centpercent">';
|
||||
|
||||
print '<tr class="liste_titre"><th colspan="4">'.$langs->trans("ListOfExpiredServices").' <a href="'.DOL_URL_ROOT.'/contrat/services_list.php?mode=4&filter=expired"><span class="badge">'.$num.'</span></a></th>';
|
||||
@ -603,7 +610,7 @@ if ($resql)
|
||||
}
|
||||
$db->free();
|
||||
|
||||
print "</table>";
|
||||
print "</table></div>";
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
@ -164,7 +164,8 @@ $max=10;
|
||||
|
||||
$langs->load("boxes");
|
||||
|
||||
$sql = "SELECT u.rowid as uid, u.lastname, u.firstname, u.login, u.statut, u.photo, d.rowid, d.ref, d.date_debut as dated, d.date_fin as datef, d.date_create as dm, d.total_ht, d.total_ttc, d.fk_statut as fk_status";
|
||||
$sql = "SELECT u.rowid as uid, u.lastname, u.firstname, u.login, u.statut, u.photo, u.email, u.admin";
|
||||
$sql.= ", d.rowid, d.ref, d.date_debut as dated, d.date_fin as datef, d.date_create as dm, d.total_ht, d.total_ttc, d.fk_statut as fk_status";
|
||||
$sql.= " FROM ".MAIN_DB_PREFIX."expensereport as d, ".MAIN_DB_PREFIX."user as u";
|
||||
if (!$user->rights->societe->client->voir && !$user->socid) $sql.= ", ".MAIN_DB_PREFIX."societe as s, ".MAIN_DB_PREFIX."societe_commerciaux as sc";
|
||||
$sql.= " WHERE u.rowid = d.fk_user_author";
|
||||
@ -211,6 +212,8 @@ if ($result)
|
||||
$expensereportstatic->id=$obj->rowid;
|
||||
$expensereportstatic->ref=$obj->ref;
|
||||
$userstatic->id=$obj->uid;
|
||||
$userstatic->admin = $obj->admin;
|
||||
$userstatic->email = $obj->email;
|
||||
$userstatic->lastname=$obj->lastname;
|
||||
$userstatic->firstname=$obj->firstname;
|
||||
$userstatic->login=$obj->login;
|
||||
|
||||
@ -63,11 +63,12 @@ if (! empty($conf->global->MAIN_SEARCH_FORM_ON_HOME_AREAS)) // This is usele
|
||||
{
|
||||
print '<form method="post" action="list.php">';
|
||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
||||
print '<div class="div-table-responsive-no-min">';
|
||||
print '<table class="noborder nohover centpercent">';
|
||||
print '<tr class="liste_titre"><td colspan="3">'.$langs->trans("Search").'</td></tr>';
|
||||
print '<tr class="oddeven"><td>';
|
||||
print $langs->trans("SupplierOrder").':</td><td><input type="text" class="flat" name="search_all" size="18"></td><td><input type="submit" value="'.$langs->trans("Search").'" class="button"></td></tr>';
|
||||
print "</table></form><br>\n";
|
||||
print "</table></div></form><br>\n";
|
||||
}
|
||||
|
||||
|
||||
@ -114,6 +115,7 @@ if ($resql)
|
||||
}
|
||||
$db->free($resql);
|
||||
|
||||
print '<div class="div-table-responsive-no-min">';
|
||||
print '<table class="noborder nohover centpercent">';
|
||||
print '<tr class="liste_titre"><th colspan="2">'.$langs->trans("Statistics").' - '.$langs->trans("SuppliersOrders").'</th></tr>';
|
||||
print "</tr>\n";
|
||||
@ -148,7 +150,7 @@ if ($resql)
|
||||
//print '<tr class="liste_total"><td>'.$langs->trans("Total").' ('.$langs->trans("SuppliersOrdersRunning").')</td><td class="right">'.$totalinprocess.'</td></tr>';
|
||||
print '<tr class="liste_total"><td>'.$langs->trans("Total").'</td><td class="right">'.$total.'</td></tr>';
|
||||
|
||||
print "</table><br>";
|
||||
print "</table></div><br>";
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -178,6 +180,7 @@ if ($resql)
|
||||
$num = $db->num_rows($resql);
|
||||
$i = 0;
|
||||
|
||||
print '<div class="div-table-responsive-no-min">';
|
||||
print '<table class="liste centpercent">';
|
||||
|
||||
print '<tr class="liste_titre"><th>'.$langs->trans("Status").'</th>';
|
||||
@ -195,7 +198,7 @@ if ($resql)
|
||||
print "</tr>\n";
|
||||
$i++;
|
||||
}
|
||||
print "</table><br>";
|
||||
print "</table></div><br>";
|
||||
$db->free($resql);
|
||||
}
|
||||
else
|
||||
@ -223,6 +226,7 @@ if (! empty($conf->fournisseur->enabled))
|
||||
$resql=$db->query($sql);
|
||||
if ($resql)
|
||||
{
|
||||
print '<div class="div-table-responsive-no-min">';
|
||||
print '<table class="noborder centpercent">';
|
||||
print '<tr class="liste_titre">';
|
||||
print '<th colspan="2">'.$langs->trans("DraftOrders").'</th></tr>';
|
||||
@ -242,7 +246,7 @@ if (! empty($conf->fournisseur->enabled))
|
||||
$i++;
|
||||
}
|
||||
}
|
||||
print "</table><br>";
|
||||
print "</table></div><br>";
|
||||
}
|
||||
}
|
||||
|
||||
@ -268,6 +272,7 @@ if ($resql)
|
||||
$num = $db->num_rows($resql);
|
||||
$i = 0;
|
||||
|
||||
print '<div class="div-table-responsive-no-min">';
|
||||
print '<table class="liste centpercent">';
|
||||
print '<tr class="liste_titre"><th>'.$langs->trans("UserWithApproveOrderGrant").'</th>';
|
||||
print "</tr>\n";
|
||||
@ -287,7 +292,7 @@ if ($resql)
|
||||
print "</tr>\n";
|
||||
$i++;
|
||||
}
|
||||
print "</table><br>";
|
||||
print "</table></div><br>";
|
||||
$db->free($resql);
|
||||
}
|
||||
else
|
||||
@ -319,6 +324,7 @@ $sql.= $db->plimit($max, 0);
|
||||
$resql=$db->query($sql);
|
||||
if ($resql)
|
||||
{
|
||||
print '<div class="div-table-responsive-no-min">';
|
||||
print '<table class="noborder centpercent">';
|
||||
print '<tr class="liste_titre">';
|
||||
print '<th colspan="4">'.$langs->trans("LastModifiedOrders", $max).'</th></tr>';
|
||||
@ -362,7 +368,7 @@ if ($resql)
|
||||
$i++;
|
||||
}
|
||||
}
|
||||
print "</table><br>";
|
||||
print "</table></div><br>";
|
||||
}
|
||||
else dol_print_error($db);
|
||||
|
||||
@ -387,6 +393,7 @@ if ($resql)
|
||||
{
|
||||
$num = $db->num_rows($resql);
|
||||
|
||||
print '<div class="div-table-responsive-no-min">';
|
||||
print '<table class="noborder centpercent">';
|
||||
print '<tr class="liste_titre">';
|
||||
print '<th colspan="3">'.$langs->trans("OrdersToProcess").' <a href="'.DOL_URL_ROOT.'/commande/list.php?viewstatut=1">('.$num.')</a></th></tr>';
|
||||
@ -431,7 +438,7 @@ $i++;
|
||||
}
|
||||
}
|
||||
|
||||
print "</table><br>";
|
||||
print "</table></div><br>";
|
||||
}
|
||||
*/
|
||||
|
||||
|
||||
@ -265,12 +265,16 @@ $sql.= " cp.detail_refuse,";
|
||||
|
||||
$sql.= " uu.lastname as user_lastname,";
|
||||
$sql.= " uu.firstname as user_firstname,";
|
||||
$sql.= " uu.admin as user_admin,";
|
||||
$sql.= " uu.email as user_email,";
|
||||
$sql.= " uu.login as user_login,";
|
||||
$sql.= " uu.statut as user_statut,";
|
||||
$sql.= " uu.photo as user_photo,";
|
||||
|
||||
$sql.= " ua.lastname as validator_lastname,";
|
||||
$sql.= " ua.firstname as validator_firstname,";
|
||||
$sql.= " ua.admin as validator_admin,";
|
||||
$sql.= " ua.email as validator_email,";
|
||||
$sql.= " ua.login as validator_login,";
|
||||
$sql.= " ua.statut as validator_statut,";
|
||||
$sql.= " ua.photo as validator_photo";
|
||||
@ -663,6 +667,8 @@ if ($resql)
|
||||
$userstatic->id=$obj->fk_user;
|
||||
$userstatic->lastname=$obj->user_lastname;
|
||||
$userstatic->firstname=$obj->user_firstname;
|
||||
$userstatic->admin = $obj->user_admin;
|
||||
$userstatic->email = $obj->user_email;
|
||||
$userstatic->login=$obj->user_login;
|
||||
$userstatic->statut=$obj->user_statut;
|
||||
$userstatic->photo=$obj->user_photo;
|
||||
@ -671,6 +677,8 @@ if ($resql)
|
||||
$approbatorstatic->id=$obj->fk_validator;
|
||||
$approbatorstatic->lastname=$obj->validator_lastname;
|
||||
$approbatorstatic->firstname=$obj->validator_firstname;
|
||||
$approbatorstatic->admin = $obj->validator_admin;
|
||||
$approbatorstatic->email = $obj->validator_email;
|
||||
$approbatorstatic->login=$obj->validator_login;
|
||||
$approbatorstatic->statut=$obj->validator_statut;
|
||||
$approbatorstatic->photo=$obj->validator_photo;
|
||||
|
||||
@ -420,6 +420,14 @@ create table llx_c_shipment_package_type
|
||||
entity integer DEFAULT 1 NOT NULL -- Multi company id
|
||||
)ENGINE=innodb;
|
||||
|
||||
CREATE TABLE llx_product_fournisseur_price_extrafields (
|
||||
rowid integer AUTO_INCREMENT PRIMARY KEY,
|
||||
tms timestamp,
|
||||
fk_object integer NOT NULL,
|
||||
import_key varchar(14) -- import key
|
||||
) ENGINE=innodb;
|
||||
|
||||
ALTER TABLE llx_product_fournisseur_price_extrafields ADD INDEX idx_product_fournisseur_price_extrafields (fk_object);
|
||||
|
||||
CREATE TABLE llx_mrp_mo(
|
||||
-- BEGIN MODULEBUILDER FIELDS
|
||||
|
||||
@ -104,6 +104,14 @@ TICKET_MODIFYInDolibarr=Ticket %s modified
|
||||
TICKET_ASSIGNEDInDolibarr=Ticket %s assigned
|
||||
TICKET_CLOSEInDolibarr=Ticket %s closed
|
||||
TICKET_DELETEInDolibarr=Ticket %s deleted
|
||||
BOM_VALIDATEInDolibarr=BOM validated
|
||||
BOM_UNVALIDATEInDolibarr=BOM unvalidated
|
||||
BOM_CLOSEInDolibarr=BOM disabled
|
||||
BOM_REOPENInDolibarr=BOM reopen
|
||||
BOM_DELETEInDolibarr=BOM deleted
|
||||
MO_VALIDATEInDolibarr=MO validated
|
||||
MO_PRODUCEDInDolibarr=MO produced
|
||||
MO_DELETEInDolibarr=MO deleted
|
||||
##### End agenda events #####
|
||||
AgendaModelModule=Document templates for event
|
||||
DateActionStart=Start date
|
||||
|
||||
@ -228,6 +228,7 @@ TicketNotNotifyTiersAtCreate=Not notify company at create
|
||||
Unread=Unread
|
||||
TicketNotCreatedFromPublicInterface=Not available. Ticket was not created from public interface.
|
||||
PublicInterfaceNotEnabled=Public interface was not enabled
|
||||
ErrorTicketRefRequired=Ticket reference name is required
|
||||
|
||||
#
|
||||
# Logs
|
||||
|
||||
@ -768,17 +768,19 @@ SCRIPT;
|
||||
$extralabels=$extrafields->attributes["product_fournisseur_price"]['label'];
|
||||
// Extrafields
|
||||
$resql = $db->query("SELECT * FROM " . MAIN_DB_PREFIX . "product_fournisseur_price_extrafields WHERE fk_object = " . $rowid);
|
||||
if ($db->num_rows($resql) != 1) {
|
||||
foreach ($extralabels as $key => $value) {
|
||||
if (! empty($extrafields->attributes["product_fournisseur_price"]['list'][$key]) && ($extrafields->attributes["product_fournisseur_price"]['list'][$key] == 1 || $extrafields->attributes["product_fournisseur_price"]['list'][$key] == 3 || ($action == "update_price" && $extrafields->attributes["product_fournisseur_price"]['list'][$key] == 4))) {
|
||||
print '<tr><td' . ($extrafields->attributes["product_fournisseur_price"]['required'][$key] ? ' class="fieldrequired"' : '') . '>' . $langs->trans($value) . '</td><td>' . $extrafields->showInputField($key, '', '', '', '', '', 0, 'product_fournisseur_price') . '</td></tr>';
|
||||
if (!empty($extralabels)) {
|
||||
if ($db->num_rows($resql) != 1) {
|
||||
foreach ($extralabels as $key => $value) {
|
||||
if (! empty($extrafields->attributes["product_fournisseur_price"]['list'][$key]) && ($extrafields->attributes["product_fournisseur_price"]['list'][$key] == 1 || $extrafields->attributes["product_fournisseur_price"]['list'][$key] == 3 || ($action == "update_price" && $extrafields->attributes["product_fournisseur_price"]['list'][$key] == 4))) {
|
||||
print '<tr><td' . ($extrafields->attributes["product_fournisseur_price"]['required'][$key] ? ' class="fieldrequired"' : '') . '>' . $langs->trans($value) . '</td><td>' . $extrafields->showInputField($key, '', '', '', '', '', 0, 'product_fournisseur_price') . '</td></tr>';
|
||||
}
|
||||
}
|
||||
}
|
||||
} else {
|
||||
$resql = $db->fetch_object($resql);
|
||||
foreach ($extralabels as $key => $value) {
|
||||
if (! empty($extrafields->attributes["product_fournisseur_price"]['list'][$key]) && ($extrafields->attributes["product_fournisseur_price"]['list'][$key] == 1 || $extrafields->attributes["product_fournisseur_price"]['list'][$key] == 3 || ($action == "update_price" && $extrafields->attributes["product_fournisseur_price"]['list'][$key] == 4))) {
|
||||
print '<tr><td' . ($extrafields->attributes["product_fournisseur_price"]['required'][$key] ? ' class="fieldrequired"' : '') . '>' . $langs->trans($value) . '</td><td>' . $extrafields->showInputField($key, $resql->{$key}, '', '', '', '', 0, 'product_fournisseur_price') . '</td></tr>';
|
||||
} else {
|
||||
$resql = $db->fetch_object($resql);
|
||||
foreach ($extralabels as $key => $value) {
|
||||
if (! empty($extrafields->attributes["product_fournisseur_price"]['list'][$key]) && ($extrafields->attributes["product_fournisseur_price"]['list'][$key] == 1 || $extrafields->attributes["product_fournisseur_price"]['list'][$key] == 3 || ($action == "update_price" && $extrafields->attributes["product_fournisseur_price"]['list'][$key] == 4))) {
|
||||
print '<tr><td' . ($extrafields->attributes["product_fournisseur_price"]['required'][$key] ? ' class="fieldrequired"' : '') . '>' . $langs->trans($value) . '</td><td>' . $extrafields->showInputField($key, $resql->{$key}, '', '', '', '', 0, 'product_fournisseur_price') . '</td></tr>';
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -874,10 +876,12 @@ SCRIPT;
|
||||
// fetch optionals attributes and labels
|
||||
$extrafields->fetch_name_optionals_label("product_fournisseur_price");
|
||||
$extralabels=$extrafields->attributes["product_fournisseur_price"]['label'];
|
||||
foreach ($extralabels as $key => $value) {
|
||||
// Show field if not hidden
|
||||
if (! empty($extrafields->attributes["product_fournisseur_price"]['list'][$key]) && $extrafields->attributes["product_fournisseur_price"]['list'][$key] != 3) {
|
||||
print_liste_field_titre($value, $_SERVER["PHP_SELF"], '', '', $param, '', $sortfield, $sortorder, 'right ');
|
||||
if (!empty($extralabels)) {
|
||||
foreach ($extralabels as $key => $value) {
|
||||
// Show field if not hidden
|
||||
if (! empty($extrafields->attributes["product_fournisseur_price"]['list'][$key]) && $extrafields->attributes["product_fournisseur_price"]['list'][$key] != 3) {
|
||||
print_liste_field_titre($value, $_SERVER["PHP_SELF"], '', '', $param, '', $sortfield, $sortorder, 'right ');
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -1004,17 +1008,19 @@ SCRIPT;
|
||||
|
||||
// Extrafields
|
||||
$resql = $db->query("SELECT * FROM " . MAIN_DB_PREFIX . "product_fournisseur_price_extrafields WHERE fk_object = " . $productfourn->product_fourn_price_id);
|
||||
if ($db->num_rows($resql) != 1) {
|
||||
foreach ($extralabels as $key => $value) {
|
||||
if (! empty($extrafields->attributes["product_fournisseur_price"]['list'][$key]) && $extrafields->attributes["product_fournisseur_price"]['list'][$key] != 3) {
|
||||
print "<td></td>";
|
||||
if (! empty($extralabels)) {
|
||||
if ($db->num_rows($resql) != 1) {
|
||||
foreach ($extralabels as $key => $value) {
|
||||
if (! empty($extrafields->attributes["product_fournisseur_price"]['list'][$key]) && $extrafields->attributes["product_fournisseur_price"]['list'][$key] != 3) {
|
||||
print "<td></td>";
|
||||
}
|
||||
}
|
||||
}
|
||||
} else {
|
||||
$resql = $db->fetch_object($resql);
|
||||
foreach ($extralabels as $key => $value) {
|
||||
if (! empty($extrafields->attributes["product_fournisseur_price"]['list'][$key]) && $extrafields->attributes["product_fournisseur_price"]['list'][$key] != 3) {
|
||||
print '<td align="right">' . $extrafields->showOutputField($key, $resql->{$key}) . "</td>";
|
||||
} else {
|
||||
$resql = $db->fetch_object($resql);
|
||||
foreach ($extralabels as $key => $value) {
|
||||
if (! empty($extrafields->attributes["product_fournisseur_price"]['list'][$key]) && $extrafields->attributes["product_fournisseur_price"]['list'][$key] != 3) {
|
||||
print '<td align="right">' . $extrafields->showOutputField($key, $resql->{$key}) . "</td>";
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -396,16 +396,11 @@ class Inventory extends CommonObject
|
||||
// phpcs:enable
|
||||
global $langs;
|
||||
|
||||
if (empty($this->labelStatus))
|
||||
{
|
||||
global $langs;
|
||||
//$langs->load("mrp");
|
||||
$this->labelStatus[self::STATUS_DRAFT] = $langs->trans('Draft');
|
||||
$this->labelStatus[self::STATUS_VALIDATED] = $langs->trans('Enabled');
|
||||
$this->labelStatus[self::STATUS_CANCELED] = $langs->trans('Canceled');
|
||||
}
|
||||
$labelStatus[self::STATUS_DRAFT] = $langs->trans('Draft');
|
||||
$labelStatus[self::STATUS_VALIDATED] = $langs->trans('Enabled');
|
||||
$labelStatus[self::STATUS_CANCELED] = $langs->trans('Canceled');
|
||||
|
||||
return dolGetStatus($this->labelStatus[$status], $this->labelStatus[$status], '', 'status'.$status, $mode);
|
||||
return dolGetStatus($labelStatus[$status], $labelStatus[$status], '', 'status'.$status, $mode);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@ -84,7 +84,7 @@ $extrafields = new ExtraFields($db);
|
||||
|
||||
// fetch optionals attributes and labels
|
||||
$extrafields->fetch_name_optionals_label($object->table_element);
|
||||
$search_array_options=$extrafields->getOptionalsFromPost(null, '', 'search_');
|
||||
$search_array_options = (array) $extrafields->getOptionalsFromPost($object->table_element, '', 'search_');
|
||||
|
||||
// List of fields to search into when doing a "search in all"
|
||||
$fieldstosearchall = array(
|
||||
|
||||
@ -306,7 +306,7 @@ class Ticket extends CommonObject
|
||||
}
|
||||
|
||||
if (empty($this->ref)) {
|
||||
$this->errors[] = 'ErrorBadRef';
|
||||
$this->errors[] = 'ErrorTicketRefRequired';
|
||||
dol_syslog(get_class($this) . "::create error -1 ref null", LOG_ERR);
|
||||
$result = -1;
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user