Merge branch '12.0' of git@github.com:Dolibarr/dolibarr.git into develop
Conflicts: htdocs/compta/resultat/index.php htdocs/product/admin/product.php htdocs/projet/tasks/list.php
This commit is contained in:
commit
5ea47f3ade
36
ChangeLog
36
ChangeLog
@ -14,6 +14,42 @@ Following changes may create regressions for some external modules, but were nec
|
||||
|
||||
|
||||
|
||||
***** ChangeLog for 12.0.1 compared to 12.0.0 *****
|
||||
FIX: reposition was broken if url end with #anchor
|
||||
FIX: $_POST must be GETPOST
|
||||
FIX: 10.0 - fatal with postgreSQL
|
||||
FIX: #14109
|
||||
FIX: #14112
|
||||
FIX: #14142
|
||||
FIX: all extrafields cleared after update of one of them
|
||||
FIX: Avoid warning when creating a module with already existing files
|
||||
FIX: change selected fields on company card
|
||||
FIX: Correct ModuleBuilder left menu
|
||||
FIX: create a deposit with amount using comma didn't work
|
||||
FIX: CSS
|
||||
FIX: Entry from stripe intent were reported into SEPA payments
|
||||
FIX: Filter on status, closing opening status
|
||||
FIX: html lost on html extrafield
|
||||
FIX: Label of popup on thirdparty
|
||||
FIX: missing possibility to change entity when propal cloning
|
||||
FIX: missing setup of extrafields for MO
|
||||
FIX: Missing the tooltip when creating bank account
|
||||
FIX: Missing token
|
||||
FIX: non numeric value on comm/card.php
|
||||
FIX: SQL Problem in customer invoice list
|
||||
FIX: SQL Problem in social contribution list
|
||||
FIX: SQL Problem in supplier invoice list
|
||||
FIX: SQL syntax error when editing extrafields
|
||||
FIX: Sql type
|
||||
FIX: takepos 12 hook
|
||||
FIX: Update form erased extrafields that were hidden
|
||||
FIX: Update of extrafields date
|
||||
FIX: Update of extrafiels on draft object
|
||||
FIX: upload documents into manual ECM was reported a permission error
|
||||
FIX: Use of office365 TLS with SMTPs method.
|
||||
FIX: wrong origin
|
||||
FIX: Permission error during import
|
||||
|
||||
***** ChangeLog for 12.0.0 compared to 11.0.0 *****
|
||||
For users:
|
||||
|
||||
|
||||
@ -111,6 +111,7 @@ $parameters = array('socid' => $socid);
|
||||
$reshook = $hookmanager->executeHooks('doActions', $parameters, $object, $action); // Note that $action and $object may have been modified by some hooks
|
||||
if ($reshook < 0) setEventMessages($hookmanager->error, $hookmanager->errors, 'errors');
|
||||
|
||||
|
||||
/*
|
||||
* Actions
|
||||
*/
|
||||
@ -310,7 +311,7 @@ if (empty($reshook) && $action == 'add')
|
||||
if (GETPOST("doneby") > 0) $object->userdoneid = GETPOST("doneby", "int");
|
||||
}
|
||||
|
||||
$object->note_private = trim(GETPOST("note"));
|
||||
$object->note_private = trim(GETPOST("note", "none"));
|
||||
|
||||
if (isset($_POST["contactid"])) $object->contact = $contact;
|
||||
|
||||
@ -451,7 +452,7 @@ if (empty($reshook) && $action == 'update')
|
||||
$object->contact_id = key($object->socpeopleassigned);
|
||||
}
|
||||
$object->fk_project = GETPOST("projectid", 'int');
|
||||
$object->note_private = GETPOST("note", "none");
|
||||
$object->note_private = trim(GETPOST("note", "none"));
|
||||
$object->fk_element = GETPOST("fk_element", "int");
|
||||
$object->elementtype = GETPOST("elementtype", "alphanohtml");
|
||||
|
||||
@ -1028,14 +1029,13 @@ if ($action == 'create')
|
||||
// Project
|
||||
if (!empty($conf->projet->enabled))
|
||||
{
|
||||
// Projet associe
|
||||
$langs->load("projects");
|
||||
|
||||
$projectid = GETPOST('projectid', 'int');
|
||||
|
||||
print '<tr><td class="titlefieldcreate">'.$langs->trans("Project").'</td><td id="project-input-container" >';
|
||||
|
||||
$numproject = $formproject->select_projects((!empty($societe->id) ? $societe->id : -1), $projectid, 'projectid', 0, 0, 1, 1);
|
||||
$numproject = $formproject->select_projects((!empty($societe->id) ? $societe->id : -1), $projectid, 'projectid', 0, 0, 1, 1, 0, 0, 0, '', 0, 0, 'maxwidth500');
|
||||
|
||||
print ' <a href="'.DOL_URL_ROOT.'/projet/card.php?socid='.$societe->id.'&action=create"><span class="fa fa-plus-circle valignmiddle paddingleft" title="'.$langs->trans("AddProject").'"></span></a>';
|
||||
$urloption = '?action=create&donotclearsession=1';
|
||||
@ -1090,7 +1090,7 @@ if ($action == 'create')
|
||||
// Description
|
||||
print '<tr><td class="tdtop">'.$langs->trans("Description").'</td><td>';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/class/doleditor.class.php';
|
||||
$doleditor = new DolEditor('note', (GETPOST('note', 'none') ?GETPOST('note', 'none') : $object->note_private), '', 180, 'dolibarr_notes', 'In', true, true, $conf->fckeditor->enabled, ROWS_4, '90%');
|
||||
$doleditor = new DolEditor('note', (GETPOST('note', 'none') ? GETPOST('note', 'none') : $object->note_private), '', 180, 'dolibarr_notes', 'In', true, true, $conf->fckeditor->enabled, ROWS_4, '90%');
|
||||
$doleditor->Create();
|
||||
print '</td></tr>';
|
||||
|
||||
|
||||
@ -59,9 +59,9 @@ if (GETPOST('action', 'aZ09') == 'setremise')
|
||||
$discount_type = GETPOST('discount_type', 'int');
|
||||
|
||||
if (!empty($discount_type)) {
|
||||
$result = $object->set_remise_supplier(price2num(GETPOST("remise")), GETPOST("note"), $user);
|
||||
$result = $object->set_remise_supplier(price2num(GETPOST("remise")), GETPOST("note", "alphanohtml"), $user);
|
||||
} else {
|
||||
$result = $object->set_remise_client(price2num(GETPOST("remise")), GETPOST("note"), $user);
|
||||
$result = $object->set_remise_client(price2num(GETPOST("remise")), GETPOST("note", "alphanohtml"), $user);
|
||||
}
|
||||
|
||||
if ($result > 0)
|
||||
@ -183,7 +183,7 @@ if ($socid > 0)
|
||||
|
||||
// Motif/Note
|
||||
print '<tr><td class="fieldrequired">';
|
||||
print $langs->trans("NoteReason").'</td><td><input type="text" size="60" name="note" value="'.dol_escape_htmltag(GETPOST("note")).'"></td></tr>';
|
||||
print $langs->trans("NoteReason").'</td><td><input type="text" size="60" name="note" value="'.dol_escape_htmltag(GETPOST("note", "alphanohtml")).'"></td></tr>';
|
||||
|
||||
print "</table>";
|
||||
|
||||
|
||||
@ -178,7 +178,7 @@ if ($result)
|
||||
print '<input type="hidden" name="sortfield" value="'.$sortfield.'">';
|
||||
print '<input type="hidden" name="sortorder" value="'.$sortorder.'">';
|
||||
|
||||
print_barre_liste($langs->trans("VariousPayments"), $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, '', $num, $totalnboflines, 'object_payment', 0, $newcardbutton, '', $limit, 0, 0, 1);
|
||||
print_barre_liste($langs->trans("MenuVariousPayment"), $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, '', $num, $totalnboflines, 'object_payment', 0, $newcardbutton, '', $limit, 0, 0, 1);
|
||||
|
||||
print '<div class="div-table-responsive">';
|
||||
print '<table class="tagtable liste'.($moreforfilter ? " listwithfilterbefore" : "").'">'."\n";
|
||||
|
||||
@ -451,6 +451,7 @@ while ($j < $numlt)
|
||||
|
||||
|
||||
// Payment Salary
|
||||
/*
|
||||
if (!empty($conf->salaries->enabled) && !empty($user->rights->salaries->read))
|
||||
{
|
||||
if (!$mode || $mode != 'sconly')
|
||||
@ -558,6 +559,7 @@ if (!empty($conf->salaries->enabled) && !empty($user->rights->salaries->read))
|
||||
}
|
||||
}
|
||||
}
|
||||
*/
|
||||
|
||||
print '</form>';
|
||||
|
||||
|
||||
@ -1333,7 +1333,7 @@ class FactureRec extends CommonInvoice
|
||||
|
||||
$result = '';
|
||||
|
||||
$label = '<u>'.$langs->trans("ShowInvoice").'</u>';
|
||||
$label = '<u>'.$langs->trans("RepeatableInvoice").'</u>';
|
||||
if (!empty($this->ref)) {
|
||||
$label .= '<br><b>'.$langs->trans('Ref').':</b> '.$this->ref;
|
||||
}
|
||||
|
||||
@ -486,7 +486,7 @@ if (!empty($conf->tax->enabled) && ($modecompta == 'CREANCES-DETTES' || $modecom
|
||||
}
|
||||
|
||||
/*
|
||||
* Charges sociales non deductibles
|
||||
* Social contributions
|
||||
*/
|
||||
|
||||
$subtotal_ht = 0;
|
||||
@ -499,7 +499,6 @@ if (!empty($conf->tax->enabled) && ($modecompta == 'CREANCES-DETTES' || $modecom
|
||||
$sql .= " FROM ".MAIN_DB_PREFIX."c_chargesociales as c";
|
||||
$sql .= ", ".MAIN_DB_PREFIX."chargesociales as cs";
|
||||
$sql .= " WHERE cs.fk_type = c.id";
|
||||
$sql .= " AND c.deductible = 0";
|
||||
if (!empty($date_start) && !empty($date_end))
|
||||
$sql .= " AND cs.date_ech >= '".$db->idate($date_start)."' AND cs.date_ech <= '".$db->idate($date_end)."'";
|
||||
} elseif ($modecompta == "RECETTES-DEPENSES")
|
||||
@ -510,7 +509,6 @@ if (!empty($conf->tax->enabled) && ($modecompta == 'CREANCES-DETTES' || $modecom
|
||||
$sql .= ", ".MAIN_DB_PREFIX."paiementcharge as p";
|
||||
$sql .= " WHERE p.fk_charge = cs.rowid";
|
||||
$sql .= " AND cs.fk_type = c.id";
|
||||
$sql .= " AND c.deductible = 0";
|
||||
if (!empty($date_start) && !empty($date_end))
|
||||
$sql .= " AND p.datep >= '".$db->idate($date_start)."' AND p.datep <= '".$db->idate($date_end)."'";
|
||||
}
|
||||
@ -518,67 +516,7 @@ if (!empty($conf->tax->enabled) && ($modecompta == 'CREANCES-DETTES' || $modecom
|
||||
$sql .= " AND cs.entity = ".$conf->entity;
|
||||
$sql .= " GROUP BY c.libelle, dm";
|
||||
|
||||
dol_syslog("get social contributions deductible=0 ", LOG_DEBUG);
|
||||
$result = $db->query($sql);
|
||||
if ($result) {
|
||||
$num = $db->num_rows($result);
|
||||
$i = 0;
|
||||
if ($num) {
|
||||
while ($i < $num) {
|
||||
$obj = $db->fetch_object($result);
|
||||
|
||||
if (!isset($decaiss[$obj->dm])) $decaiss[$obj->dm] = 0;
|
||||
$decaiss[$obj->dm] += $obj->amount;
|
||||
|
||||
if (!isset($decaiss_ttc[$obj->dm])) $decaiss_ttc[$obj->dm] = 0;
|
||||
$decaiss_ttc[$obj->dm] += $obj->amount;
|
||||
|
||||
$i++;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
dol_print_error($db);
|
||||
}
|
||||
} elseif ($modecompta == "BOOKKEEPING")
|
||||
{
|
||||
// Nothing from this table
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* Charges sociales deductibles
|
||||
*/
|
||||
|
||||
$subtotal_ht = 0;
|
||||
$subtotal_ttc = 0;
|
||||
if (!empty($conf->tax->enabled) && ($modecompta == 'CREANCES-DETTES' || $modecompta == "RECETTES-DEPENSES"))
|
||||
{
|
||||
if ($modecompta == 'CREANCES-DETTES')
|
||||
{
|
||||
$sql = "SELECT c.libelle as nom, date_format(cs.date_ech,'%Y-%m') as dm, sum(cs.amount) as amount";
|
||||
$sql .= " FROM ".MAIN_DB_PREFIX."c_chargesociales as c";
|
||||
$sql .= ", ".MAIN_DB_PREFIX."chargesociales as cs";
|
||||
$sql .= " WHERE cs.fk_type = c.id";
|
||||
$sql .= " AND c.deductible = 1";
|
||||
if (!empty($date_start) && !empty($date_end))
|
||||
$sql .= " AND cs.date_ech >= '".$db->idate($date_start)."' AND cs.date_ech <= '".$db->idate($date_end)."'";
|
||||
} elseif ($modecompta == "RECETTES-DEPENSES")
|
||||
{
|
||||
$sql = "SELECT c.libelle as nom, date_format(p.datep,'%Y-%m') as dm, sum(p.amount) as amount";
|
||||
$sql .= " FROM ".MAIN_DB_PREFIX."c_chargesociales as c";
|
||||
$sql .= ", ".MAIN_DB_PREFIX."chargesociales as cs";
|
||||
$sql .= ", ".MAIN_DB_PREFIX."paiementcharge as p";
|
||||
$sql .= " WHERE p.fk_charge = cs.rowid";
|
||||
$sql .= " AND cs.fk_type = c.id";
|
||||
$sql .= " AND c.deductible = 1";
|
||||
if (!empty($date_start) && !empty($date_end))
|
||||
$sql .= " AND p.datep >= '".$db->idate($date_start)."' AND p.datep <= '".$db->idate($date_end)."'";
|
||||
}
|
||||
|
||||
$sql .= " AND cs.entity = ".$conf->entity;
|
||||
$sql .= " GROUP BY c.libelle, dm";
|
||||
|
||||
dol_syslog("get social contributions paid deductible=1", LOG_DEBUG);
|
||||
dol_syslog("get social contributions", LOG_DEBUG);
|
||||
$result = $db->query($sql);
|
||||
if ($result) {
|
||||
$num = $db->num_rows($result);
|
||||
@ -713,7 +651,7 @@ if (!empty($conf->expensereport->enabled) && ($modecompta == 'CREANCES-DETTES' |
|
||||
|
||||
|
||||
/*
|
||||
* Donation get dunning paiement
|
||||
* Donation get dunning payments
|
||||
*/
|
||||
|
||||
if (!empty($conf->don->enabled) && ($modecompta == 'CREANCES-DETTES' || $modecompta == "RECETTES-DEPENSES"))
|
||||
|
||||
@ -143,7 +143,7 @@ class box_services_contracts extends ModeleBoxes
|
||||
$thirdpartytmp->code_compta_fournisseur = $objp->code_compta_fournisseur;
|
||||
|
||||
$dateline = $this->db->jdate($objp->date_line);
|
||||
if ($contractstatic->statut == Contrat::STATUS_VALIDATED && $objp->statut == ContratLigne::STATUS_OPEN && ($dateline + $conf->contrat->services->expires->warning_delay) < $now) $late = img_warning($langs->trans("Late"));
|
||||
if ($contractstatic->statut == Contrat::STATUS_VALIDATED && $objp->statut == ContratLigne::STATUS_OPEN && !empty($dateline) && ($dateline + $conf->contrat->services->expires->warning_delay) < $now) $late = img_warning($langs->trans("Late"));
|
||||
|
||||
// Multilangs
|
||||
if (!empty($conf->global->MAIN_MULTILANGS) && $objp->product_id > 0) // if option multilang is on
|
||||
|
||||
@ -61,7 +61,7 @@ function ajax_autocompleter($selected, $htmlname, $url, $urloption = '', $minLen
|
||||
$script .= '<script>'."\n";
|
||||
$script .= '$(document).ready(function() {
|
||||
var autoselect = '.$autoselect.';
|
||||
var options = '.json_encode($ajaxoptions).';
|
||||
var options = '.json_encode($ajaxoptions).'; /* Option of actions to do after keyup, or after select */
|
||||
|
||||
/* Remove selected id as soon as we type or delete a char (it means old selection is wrong). Use keyup/down instead of change to avoid loosing the product id. This is needed only for select of predefined product */
|
||||
$("input#search_'.$htmlname.'").keydown(function(e) {
|
||||
@ -131,7 +131,9 @@ function ajax_autocompleter($selected, $htmlname, $url, $urloption = '', $minLen
|
||||
textarea[key] = item[value];
|
||||
});
|
||||
}
|
||||
return { label: label, value: item.value, id: item.key, update: update, textarea: textarea, disabled: item.disabled }
|
||||
return { label: label, value: item.value, id: item.key, disabled: item.disabled,
|
||||
update: update, textarea: textarea,
|
||||
pbq: item.pbq, type: item.type, qty: item.qty, discount: item.discount, pricebasetype: item.pricebasetype, price_ht: item.price_ht, price_ttc: item.price_ttc }
|
||||
}));
|
||||
}
|
||||
else console.error("Error: Ajax url '.$url.($urloption ? '?'.$urloption : '').' has returned an empty page. Should be an empty json array.");
|
||||
@ -142,6 +144,14 @@ function ajax_autocompleter($selected, $htmlname, $url, $urloption = '', $minLen
|
||||
select: function( event, ui ) { // Function ran once new value has been selected into javascript combo
|
||||
console.log("Call change on input '.$htmlname.' because of select definition of autocomplete select call on input#search_'.$htmlname.'");
|
||||
console.log("Selected id = "+ui.item.id+" - If this value is null, it means you select a record with key that is null so selection is not effective");
|
||||
|
||||
//console.log(ui.item);
|
||||
$("#'.$htmlname.'").attr("data-pbq", ui.item.pbq);
|
||||
$("#'.$htmlname.'").attr("data-pbqup", ui.item.price_ht);
|
||||
$("#'.$htmlname.'").attr("data-pbqbase", ui.item.pricebasetype);
|
||||
$("#'.$htmlname.'").attr("data-pbqqty", ui.item.qty);
|
||||
$("#'.$htmlname.'").attr("data-pbqpercent", ui.item.discount);
|
||||
|
||||
$("#'.$htmlname.'").val(ui.item.id).trigger("change"); // Select new value
|
||||
// Disable an element
|
||||
if (options.option_disabled) {
|
||||
|
||||
@ -222,27 +222,32 @@ insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, left
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->don->enabled && $leftmenu=="donations"', __HANDLER__, 'left', 2002__+MAX_llx_menu__, 'billing', '', 2000__+MAX_llx_menu__, '/don/list.php?mainmenu=billing&leftmenu=donations', 'List', 1, 'donations', '$user->rights->don->lire', '', 2, 1, __ENTITY__);
|
||||
-- insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->don->enabled && $leftmenu=="donations"', __HANDLER__, 'left', 2003__+MAX_llx_menu__, 'billing', '', 2000__+MAX_llx_menu__, '/don/stats/index.php?mainmenu=billing&leftmenu=donations', 'Statistics', 1, 'donations', '$user->rights->don->lire', '', 2, 2, __ENTITY__);
|
||||
-- Special expenses
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->tax->enabled || $conf->salaries->enabled || $conf->loan->enabled || $conf->banque->enabled', __HANDLER__, 'left', 2200__+MAX_llx_menu__, 'billing', 'tax', 6__+MAX_llx_menu__, '/compta/charges/index.php?mainmenu=billing&leftmenu=tax', 'MenuSpecialExpenses', 0, 'compta', '(! empty($conf->tax->enabled) && $user->rights->tax->charges->lire) || (! empty($conf->salaries->enabled) && ! empty($user->rights->salaries->read)) || (! empty($conf->loan->enabled) && $user->rights->loan->read) || (! empty($conf->banque->enabled) && $user->rights->banque->lire)', '', 0, 6, __ENTITY__);
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->salaries->enabled', __HANDLER__, 'left', 2210__+MAX_llx_menu__, 'billing', 'tax_sal', 2200__+MAX_llx_menu__, '/salaries/list.php?mainmenu=billing&leftmenu=tax_salary', 'Salaries', 1, 'salaries', '$user->rights->salaries->read', '', 0, 1, __ENTITY__);
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->salaries->enabled && $leftmenu=="tax_salary"', __HANDLER__, 'left', 2211__+MAX_llx_menu__, 'billing', '', 2210__+MAX_llx_menu__, '/salaries/card.php?mainmenu=billing&leftmenu=tax_salary&action=create', 'NewPayment', 2, 'companies', '$user->rights->salaries->write', '', 0, 2, __ENTITY__);
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->salaries->enabled && $leftmenu=="tax_salary"', __HANDLER__, 'left', 2212__+MAX_llx_menu__, 'billing', '', 2210__+MAX_llx_menu__, '/salaries/list.php?mainmenu=billing&leftmenu=tax_salary', 'Payments', 2, 'companies', '$user->rights->salaries->read', '', 0, 3, __ENTITY__);
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->salaries->enabled && $leftmenu=="tax_salary"', __HANDLER__, 'left', 2213__+MAX_llx_menu__, 'billing', '', 2210__+MAX_llx_menu__, '/salaries/stats/index.php?mainmenu=billing&leftmenu=tax_salary', 'Statistics', 2, 'companies', '$user->rights->salaries->read', '', 0, 4, __ENTITY__);
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->loan->enabled', __HANDLER__, 'left', 2220__+MAX_llx_menu__, 'billing', 'tax_loan', 2200__+MAX_llx_menu__, '/loan/list.php?mainmenu=billing&leftmenu=tax_loan', 'Loans', 1, 'loan', '$user->rights->loan->read', '', 0, 1, __ENTITY__);
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->loan->enabled && $leftmenu=="tax_loan"', __HANDLER__, 'left', 2221__+MAX_llx_menu__, 'billing', '', 2220__+MAX_llx_menu__, '/loan/card.php?mainmenu=billing&leftmenu=tax_loan&action=create', 'NewLoan', 2, 'loan', '$user->rights->loan->write', '', 0, 2, __ENTITY__);
|
||||
--insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->loan->enabled && $leftmenu=="tax_loan"', __HANDLER__, 'left', 2222__+MAX_llx_menu__, 'billing', '', 2220__+MAX_llx_menu__, '/loan/payment/list.php?mainmenu=billing&leftmenu=tax_loan', 'Payments', 2, 'companies', '$user->rights->loan->read', '', 0, 3, __ENTITY__);
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->loan->enabled && $leftmenu=="tax_loan" && ! empty($conf->global->LOAN_SHOW_CALCULATOR)', __HANDLER__, 'left', 2223__+MAX_llx_menu__, 'billing', '', 2220__+MAX_llx_menu__, '/loan/calc.php?mainmenu=billing&leftmenu=tax_loan', 'Calculator', 2, 'companies', '$user->rights->loan->calc', '', 0, 4, __ENTITY__);
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->tax->enabled || $conf->salaries->enabled || $conf->loan->enabled || $conf->banque->enabled', __HANDLER__, 'left', 2200__+MAX_llx_menu__, 'billing', 'tax', 6__+MAX_llx_menu__, '/compta/charges/index.php?mainmenu=billing&leftmenu=tax', 'MenuTaxesAndSpecialExpenses', 0, 'compta', '(! empty($conf->tax->enabled) && $user->rights->tax->charges->lire) || (! empty($conf->salaries->enabled) && ! empty($user->rights->salaries->read)) || (! empty($conf->loan->enabled) && $user->rights->loan->read) || (! empty($conf->banque->enabled) && $user->rights->banque->lire)', '', 0, 6, __ENTITY__);
|
||||
-- Social contributions
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->tax->enabled', __HANDLER__, 'left', 2250__+MAX_llx_menu__, 'billing', 'tax_social', 2200__+MAX_llx_menu__, '/compta/sociales/list.php?mainmenu=billing&leftmenu=tax_social', 'SocialContributions', 1, '', '$user->rights->tax->charges->lire', '', 0, 1, __ENTITY__);
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->tax->enabled && $leftmenu=="tax_social"', __HANDLER__, 'left', 2251__+MAX_llx_menu__, 'billing', '', 2250__+MAX_llx_menu__, '/compta/sociales/card.php?mainmenu=billing&leftmenu=tax_social&action=create', 'MenuNewSocialContribution', 2, '', '$user->rights->tax->charges->creer', '', 0, 2, __ENTITY__);
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->tax->enabled && $leftmenu=="tax_social"', __HANDLER__, 'left', 2252__+MAX_llx_menu__, 'billing', '', 2250__+MAX_llx_menu__, '/compta/sociales/payments.php?mainmenu=billing&leftmenu=tax_social&mode=sconly', 'Payments', 2, '', '$user->rights->tax->charges->lire', '', 0, 3, __ENTITY__);
|
||||
-- VAT
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->tax->enabled && empty($conf->global->TAX_DISABLE_VAT_MENUS)', __HANDLER__, 'left', 2300__+MAX_llx_menu__, 'billing', 'tax_vat', 2200__+MAX_llx_menu__, '/compta/tva/list.php?mainmenu=billing&leftmenu=tax_vat', 'VAT', 1, 'companies', '$user->rights->tax->charges->lire', '', 0, 7, __ENTITY__);
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->tax->enabled && empty($conf->global->TAX_DISABLE_VAT_MENUS) && $leftmenu=="tax_vat"', __HANDLER__, 'left', 2301__+MAX_llx_menu__, 'billing', '', 2300__+MAX_llx_menu__, '/compta/tva/card.php?mainmenu=billing&leftmenu=tax_vat&action=create', 'New', 2, 'companies', '$user->rights->tax->charges->creer', '', 0, 0, __ENTITY__);
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->tax->enabled && empty($conf->global->TAX_DISABLE_VAT_MENUS) && $leftmenu=="tax_vat"', __HANDLER__, 'left', 2302__+MAX_llx_menu__, 'billing', '', 2300__+MAX_llx_menu__, '/compta/tva/list.php?mainmenu=billing&leftmenu=tax_vat', 'List', 2, 'companies', '$user->rights->tax->charges->lire', '', 0, 1, __ENTITY__);
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->tax->enabled && empty($conf->global->TAX_DISABLE_VAT_MENUS) && $leftmenu=="tax_vat"', __HANDLER__, 'left', 2303__+MAX_llx_menu__, 'billing', '', 2300__+MAX_llx_menu__, '/compta/tva/index.php?mainmenu=billing&leftmenu=tax_vat', 'ReportByMonth', 2, 'companies', '$user->rights->tax->charges->lire', '', 0, 2, __ENTITY__);
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->tax->enabled && empty($conf->global->TAX_DISABLE_VAT_MENUS) && $leftmenu=="tax_vat"', __HANDLER__, 'left', 2304__+MAX_llx_menu__, 'billing', '', 2300__+MAX_llx_menu__, '/compta/tva/clients.php?mainmenu=billing&leftmenu=tax_vat', 'ReportByCustomers', 2, 'companies', '$user->rights->tax->charges->lire', '', 0, 3, __ENTITY__);
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->tax->enabled && empty($conf->global->TAX_DISABLE_VAT_MENUS) && $leftmenu=="tax_vat"', __HANDLER__, 'left', 2305__+MAX_llx_menu__, 'billing', '', 2300__+MAX_llx_menu__, '/compta/tva/quadri_detail.php?mainmenu=billing&leftmenu=tax_vat', 'ReportByQuarter', 2, 'companies', '$user->rights->tax->charges->lire', '', 0, 4, __ENTITY__);
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->banque->enabled && empty($conf->global->BANK_USE_OLD_VARIOUS_PAYMENT)', __HANDLER__, 'left', 2350__+MAX_llx_menu__, 'billing', 'tax_various', 2200__+MAX_llx_menu__, '/compta/bank/various_payment/list.php?mainmenu=billing&leftmenu=tax_various', 'MenuVariousPayment', 1, 'banks', '$user->rights->banque->lire', '', 0, 1, __ENTITY__);
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->banque->enabled && $leftmenu=="tax_various"', __HANDLER__, 'left', 2351__+MAX_llx_menu__, 'billing', '', 2350__+MAX_llx_menu__, '/compta/bank/various_payment/card.php?mainmenu=billing&leftmenu=tax_various&action=create', 'New', 2, 'various_payment', '$user->rights->banque->modifier', '', 0, 2, __ENTITY__);
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->banque->enabled && $leftmenu=="tax_various"', __HANDLER__, 'left', 2352__+MAX_llx_menu__, 'billing', '', 2350__+MAX_llx_menu__, '/compta/bank/various_payment/list.php?mainmenu=billing&leftmenu=tax_various', 'List', 2, 'various_payment', '$user->rights->banque->lire', '', 0, 3, __ENTITY__);
|
||||
-- Salary
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->salaries->enabled', __HANDLER__, 'left', 2210__+MAX_llx_menu__, 'billing', 'tax_sal', 6__+MAX_llx_menu__, '/salaries/list.php?mainmenu=billing&leftmenu=tax_salary', 'Salaries', 0, 'salaries', '$user->rights->salaries->read', '', 0, 10, __ENTITY__);
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->salaries->enabled && $leftmenu=="tax_salary"', __HANDLER__, 'left', 2211__+MAX_llx_menu__, 'billing', '', 2210__+MAX_llx_menu__, '/salaries/card.php?mainmenu=billing&leftmenu=tax_salary&action=create', 'NewPayment', 1, 'companies', '$user->rights->salaries->write', '', 0, 2, __ENTITY__);
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->salaries->enabled && $leftmenu=="tax_salary"', __HANDLER__, 'left', 2212__+MAX_llx_menu__, 'billing', '', 2210__+MAX_llx_menu__, '/salaries/list.php?mainmenu=billing&leftmenu=tax_salary', 'Payments', 1, 'companies', '$user->rights->salaries->read', '', 0, 3, __ENTITY__);
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->salaries->enabled && $leftmenu=="tax_salary"', __HANDLER__, 'left', 2213__+MAX_llx_menu__, 'billing', '', 2210__+MAX_llx_menu__, '/salaries/stats/index.php?mainmenu=billing&leftmenu=tax_salary', 'Statistics', 1, 'companies', '$user->rights->salaries->read', '', 0, 4, __ENTITY__);
|
||||
-- Loan
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->loan->enabled', __HANDLER__, 'left', 2220__+MAX_llx_menu__, 'billing', 'tax_loan', 6__+MAX_llx_menu__, '/loan/list.php?mainmenu=billing&leftmenu=tax_loan', 'Loans', 0, 'loan', '$user->rights->loan->read', '', 0, 20, __ENTITY__);
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->loan->enabled && $leftmenu=="tax_loan"', __HANDLER__, 'left', 2221__+MAX_llx_menu__, 'billing', '', 2220__+MAX_llx_menu__, '/loan/card.php?mainmenu=billing&leftmenu=tax_loan&action=create', 'NewLoan', 1, 'loan', '$user->rights->loan->write', '', 0, 2, __ENTITY__);
|
||||
--insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->loan->enabled && $leftmenu=="tax_loan"', __HANDLER__, 'left', 2222__+MAX_llx_menu__, 'billing', '', 2220__+MAX_llx_menu__, '/loan/payment/list.php?mainmenu=billing&leftmenu=tax_loan', 'Payments', 1, 'companies', '$user->rights->loan->read', '', 0, 3, __ENTITY__);
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->loan->enabled && $leftmenu=="tax_loan" && ! empty($conf->global->LOAN_SHOW_CALCULATOR)', __HANDLER__, 'left', 2223__+MAX_llx_menu__, 'billing', '', 2220__+MAX_llx_menu__, '/loan/calc.php?mainmenu=billing&leftmenu=tax_loan', 'Calculator', 1, 'companies', '$user->rights->loan->calc', '', 0, 4, __ENTITY__);
|
||||
-- Various payments
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->banque->enabled && empty($conf->global->BANK_USE_OLD_VARIOUS_PAYMENT)', __HANDLER__, 'left', 2350__+MAX_llx_menu__, 'billing', 'tax_various', 6__+MAX_llx_menu__, '/compta/bank/various_payment/list.php?mainmenu=billing&leftmenu=tax_various', 'MenuVariousPayment', 0, 'banks', '$user->rights->banque->lire', '', 0, 30, __ENTITY__);
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->banque->enabled && $leftmenu=="tax_various"', __HANDLER__, 'left', 2351__+MAX_llx_menu__, 'billing', '', 2350__+MAX_llx_menu__, '/compta/bank/various_payment/card.php?mainmenu=billing&leftmenu=tax_various&action=create', 'New', 1, 'various_payment', '$user->rights->banque->modifier', '', 0, 2, __ENTITY__);
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->banque->enabled && $leftmenu=="tax_various"', __HANDLER__, 'left', 2352__+MAX_llx_menu__, 'billing', '', 2350__+MAX_llx_menu__, '/compta/bank/various_payment/list.php?mainmenu=billing&leftmenu=tax_various', 'List', 1, 'various_payment', '$user->rights->banque->lire', '', 0, 3, __ENTITY__);
|
||||
-- Accounting (Double entries)
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->accounting->enabled', __HANDLER__, 'left', 2400__+MAX_llx_menu__, 'accountancy', 'accountancy', 9__+MAX_llx_menu__, '/accountancy/index.php?mainmenu=accountancy&leftmenu=accountancy', 'MenuAccountancy', 0, 'main', '! empty($conf->accounting->enabled) || $user->rights->accounting->bind->write || $user->rights->accounting->bind->write || $user->rights->compta->resultat->lire', '', 0, 7, __ENTITY__);
|
||||
-- Setup
|
||||
|
||||
@ -1092,7 +1092,7 @@ function print_left_eldy_menu($db, $menu_array_before, $menu_array_after, &$tabM
|
||||
global $mysoc;
|
||||
|
||||
$permtoshowmenu = ((!empty($conf->tax->enabled) && $user->rights->tax->charges->lire) || (!empty($conf->salaries->enabled) && !empty($user->rights->salaries->read)) || (!empty($conf->loan->enabled) && $user->rights->loan->read) || (!empty($conf->banque->enabled) && $user->rights->banque->lire));
|
||||
$newmenu->add("/compta/charges/index.php?leftmenu=tax&mainmenu=billing", $langs->trans("MenuSpecialExpenses"), 0, $permtoshowmenu, '', $mainmenu, 'tax');
|
||||
$newmenu->add("/compta/charges/index.php?leftmenu=tax&mainmenu=billing", $langs->trans("MenuTaxesAndSpecialExpenses"), 0, $permtoshowmenu, '', $mainmenu, 'tax');
|
||||
|
||||
// Social contributions
|
||||
if (!empty($conf->tax->enabled))
|
||||
@ -1147,11 +1147,11 @@ function print_left_eldy_menu($db, $menu_array_before, $menu_array_after, &$tabM
|
||||
if (!empty($conf->salaries->enabled))
|
||||
{
|
||||
$langs->load("salaries");
|
||||
$newmenu->add("/salaries/list.php?leftmenu=tax_salary&mainmenu=billing", $langs->trans("Salaries"), 1, $user->rights->salaries->read, '', $mainmenu, 'tax_salary');
|
||||
$newmenu->add("/salaries/list.php?leftmenu=tax_salary&mainmenu=billing", $langs->trans("Salaries"), 0, $user->rights->salaries->read, '', $mainmenu, 'tax_salary');
|
||||
if ($usemenuhider || empty($leftmenu) || preg_match('/^tax_salary/i', $leftmenu)) {
|
||||
$newmenu->add("/salaries/card.php?leftmenu=tax_salary&action=create", $langs->trans("NewPayment"), 2, $user->rights->salaries->write);
|
||||
$newmenu->add("/salaries/list.php?leftmenu=tax_salary", $langs->trans("Payments"), 2, $user->rights->salaries->read);
|
||||
$newmenu->add("/salaries/stats/index.php?leftmenu=tax_salary", $langs->trans("Statistics"), 2, $user->rights->salaries->read);
|
||||
$newmenu->add("/salaries/card.php?leftmenu=tax_salary&action=create", $langs->trans("NewPayment"), 1, $user->rights->salaries->write);
|
||||
$newmenu->add("/salaries/list.php?leftmenu=tax_salary", $langs->trans("Payments"), 1, $user->rights->salaries->read);
|
||||
$newmenu->add("/salaries/stats/index.php?leftmenu=tax_salary", $langs->trans("Statistics"), 1, $user->rights->salaries->read);
|
||||
}
|
||||
}
|
||||
|
||||
@ -1159,9 +1159,9 @@ function print_left_eldy_menu($db, $menu_array_before, $menu_array_after, &$tabM
|
||||
if (!empty($conf->loan->enabled))
|
||||
{
|
||||
$langs->load("loan");
|
||||
$newmenu->add("/loan/list.php?leftmenu=tax_loan&mainmenu=billing", $langs->trans("Loans"), 1, $user->rights->loan->read, '', $mainmenu, 'tax_loan');
|
||||
$newmenu->add("/loan/list.php?leftmenu=tax_loan&mainmenu=billing", $langs->trans("Loans"), 0, $user->rights->loan->read, '', $mainmenu, 'tax_loan');
|
||||
if ($usemenuhider || empty($leftmenu) || preg_match('/^tax_loan/i', $leftmenu)) {
|
||||
$newmenu->add("/loan/card.php?leftmenu=tax_loan&action=create", $langs->trans("NewLoan"), 2, $user->rights->loan->write);
|
||||
$newmenu->add("/loan/card.php?leftmenu=tax_loan&action=create", $langs->trans("NewLoan"), 1, $user->rights->loan->write);
|
||||
//$newmenu->add("/loan/payment/list.php?leftmenu=tax_loan",$langs->trans("Payments"),2,$user->rights->loan->read);
|
||||
}
|
||||
}
|
||||
@ -1170,10 +1170,10 @@ function print_left_eldy_menu($db, $menu_array_before, $menu_array_after, &$tabM
|
||||
if (!empty($conf->banque->enabled) && empty($conf->global->BANK_USE_OLD_VARIOUS_PAYMENT))
|
||||
{
|
||||
$langs->load("banks");
|
||||
$newmenu->add("/compta/bank/various_payment/list.php?leftmenu=tax_various&mainmenu=billing", $langs->trans("MenuVariousPayment"), 1, $user->rights->banque->lire, '', $mainmenu, 'tax_various');
|
||||
$newmenu->add("/compta/bank/various_payment/list.php?leftmenu=tax_various&mainmenu=billing", $langs->trans("MenuVariousPayment"), 0, $user->rights->banque->lire, '', $mainmenu, 'tax_various');
|
||||
if ($usemenuhider || empty($leftmenu) || preg_match('/^tax_various/i', $leftmenu)) {
|
||||
$newmenu->add("/compta/bank/various_payment/card.php?leftmenu=tax_various&action=create", $langs->trans("New"), 2, $user->rights->banque->modifier);
|
||||
$newmenu->add("/compta/bank/various_payment/list.php?leftmenu=tax_various", $langs->trans("List"), 2, $user->rights->banque->lire);
|
||||
$newmenu->add("/compta/bank/various_payment/card.php?leftmenu=tax_various&action=create", $langs->trans("New"), 1, $user->rights->banque->modifier);
|
||||
$newmenu->add("/compta/bank/various_payment/list.php?leftmenu=tax_various", $langs->trans("List"), 1, $user->rights->banque->lire);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -610,13 +610,16 @@ if (!empty($usemargins) && $user->rights->margins->creer)
|
||||
if (empty($conf->global->MAIN_DISABLE_EDIT_PREDEF_PRICEHT) && empty($senderissupplier))
|
||||
{
|
||||
?>
|
||||
var pbq = parseInt($('option:selected', this).attr('data-pbq'));
|
||||
var pbq = parseInt($('option:selected', this).attr('data-pbq')); /* If product was selected with a HTML select */
|
||||
if (isNaN(pbq)) { pbq = jQuery('#idprod').attr('data-pbq'); } /* If product was selected with a HTML input with autocomplete */
|
||||
//console.log(pbq);
|
||||
|
||||
if ((jQuery('#idprod').val() > 0 || jQuery('#idprodfournprice').val()) && ! isNaN(pbq) && pbq > 0)
|
||||
{
|
||||
console.log("We are in a price per qty context, we do not call ajax/product");
|
||||
console.log("We are in a price per qty context, we do not call ajax/product, init of fields is done few lines later");
|
||||
} else {
|
||||
<?php if (!empty($conf->global->PRODUIT_CUSTOMER_PRICES_BY_QTY) || !empty($conf->global->PRODUIT_CUSTOMER_PRICES_BY_QTY_MULTIPRICES)) { ?>
|
||||
if (isNaN(pbq)) { console.log("We use experimental option PRODUIT_CUSTOMER_PRICES_BY_QTY or PRODUIT_CUSTOMER_PRICES_BY_QTY but we are not yet able to get the id of pbq from product combo list, so load of price may be 0 if product has differet prices"); }
|
||||
if (isNaN(pbq)) { console.log("We use experimental option PRODUIT_CUSTOMER_PRICES_BY_QTY or PRODUIT_CUSTOMER_PRICES_BY_QTY but we could not get the id of pbq from product combo list, so load of price may be 0 if product has differet prices"); }
|
||||
<?php } ?>
|
||||
// Get the HT price for the product and display it
|
||||
console.log("Load unit price without tax and set it into #price_ht for product id="+$(this).val()+" socid=<?php print $object->socid; ?>");
|
||||
@ -739,11 +742,16 @@ if (!empty($usemargins) && $user->rights->margins->creer)
|
||||
?>
|
||||
|
||||
/* To process customer price per quantity (CUSTOMER_PRICE_PER_QTY works only if combo product is not an ajax after x key pressed) */
|
||||
var pbq = parseInt($('option:selected', this).attr('data-pbq'));
|
||||
var pbq = parseInt($('option:selected', this).attr('data-pbq')); // When select is done from HTML select
|
||||
if (isNaN(pbq)) { pbq = jQuery('#idprod').attr('data-pbq'); } // When select is done from HTML input with autocomplete
|
||||
var pbqup = parseFloat($('option:selected', this).attr('data-pbqup'));
|
||||
if (isNaN(pbqup)) { pbqup = jQuery('#idprod').attr('data-pbqup'); }
|
||||
var pbqbase = $('option:selected', this).attr('data-pbqbase');
|
||||
if (isNaN(pbqbase)) { pbqbase = jQuery('#idprod').attr('data-pbqbase'); }
|
||||
var pbqqty = parseFloat($('option:selected', this).attr('data-pbqqty'));
|
||||
if (isNaN(pbqqty)) { pbqqty = jQuery('#idprod').attr('data-pbqqty'); }
|
||||
var pbqpercent = parseFloat($('option:selected', this).attr('data-pbqpercent'));
|
||||
if (isNaN(pbqpercent)) { pbqpercent = jQuery('#idprod').attr('data-pbqpercent'); }
|
||||
|
||||
if ((jQuery('#idprod').val() > 0 || jQuery('#idprodfournprice').val()) && ! isNaN(pbq) && pbq > 0)
|
||||
{
|
||||
|
||||
@ -332,7 +332,7 @@ class CommandeFournisseur extends CommonOrder
|
||||
$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."c_paiement as p ON c.fk_mode_reglement = p.id";
|
||||
$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."c_input_method as cm ON cm.rowid = c.fk_input_method";
|
||||
$sql .= ' LEFT JOIN '.MAIN_DB_PREFIX.'c_incoterms as i ON c.fk_incoterms = i.rowid';
|
||||
$sql .= " WHERE c.entity = ".$conf->entity;
|
||||
$sql .= " WHERE c.entity IN (".getEntity('supplier_order').")";
|
||||
if ($ref) $sql .= " AND c.ref='".$this->db->escape($ref)."'";
|
||||
else $sql .= " AND c.rowid=".$id;
|
||||
|
||||
@ -891,6 +891,7 @@ class CommandeFournisseur extends CommonOrder
|
||||
|
||||
$sql = 'UPDATE '.MAIN_DB_PREFIX.'commande_fournisseur SET billed = 1';
|
||||
$sql .= ' WHERE rowid = '.$this->id.' AND fk_statut > '.self::STATUS_DRAFT;
|
||||
|
||||
if ($this->db->query($sql))
|
||||
{
|
||||
if (!$error)
|
||||
|
||||
@ -703,6 +703,7 @@ MenuECM=Documents
|
||||
MenuAWStats=AWStats
|
||||
MenuMembers=Members
|
||||
MenuAgendaGoogle=Google agenda
|
||||
MenuTaxesAndSpecialExpenses=Taxes | Special expenses
|
||||
ThisLimitIsDefinedInSetup=Dolibarr limit (Menu home-setup-security): %s Kb, PHP limit: %s Kb
|
||||
NoFileFound=No documents saved in this directory
|
||||
CurrentUserLanguage=Current language
|
||||
|
||||
@ -178,6 +178,7 @@ TypeContact_project_task_internal_TASKCONTRIBUTOR=Contributor
|
||||
TypeContact_project_task_external_TASKCONTRIBUTOR=Contributor
|
||||
SelectElement=Select element
|
||||
AddElement=Link to element
|
||||
LinkToElementShort=Link to
|
||||
# Documents models
|
||||
DocumentModelBeluga=Project document template for linked objects overview
|
||||
DocumentModelBaleine=Project document template for tasks
|
||||
|
||||
@ -124,10 +124,10 @@ DateActionEnd=Date de fin
|
||||
AgendaUrlOptions1=Vous pouvez aussi ajouter les paramètres suivants pour filtrer les réponses :
|
||||
AgendaUrlOptions3=<b>logina=%s</b> pour limiter l'export aux actions dont l'utilisateur <b>%s</b> est propriétaire.
|
||||
AgendaUrlOptionsNotAdmin=<b>logina=!%s</b> pour limiter l'export aux actions non assignées à l'utilisateur <b>%s</b>.
|
||||
AgendaUrlOptions4=<b>logint=%s</b>pour limiter l'export aux actions assignées à l'utilisateur <b>%s</b> (propriétaire et autres).
|
||||
AgendaUrlOptions4=<b>logint=%s</b> pour limiter l'export aux actions assignées à l'utilisateur <b>%s</b> (propriétaire et autres).
|
||||
AgendaUrlOptionsProject=<b>project=__PROJECT_ID__</b> pour restreindre aux événements associés au projet <b>__PROJECT_ID__</b>.
|
||||
AgendaUrlOptionsNotAutoEvent=<b> notactiontype=systemauto </b> pour exclure les événements automatiques.
|
||||
AgendaUrlOptionsIncludeHolidays= <b> includeholidays = 1 </b> pour inclure les événements de type congé.
|
||||
AgendaUrlOptionsNotAutoEvent=<b>notactiontype=systemauto</b> pour exclure les événements automatiques.
|
||||
AgendaUrlOptionsIncludeHolidays=<b>includeholidays=1</b> pour inclure les événements de type congé.
|
||||
AgendaShowBirthdayEvents=Afficher les anniversaires de contacts
|
||||
AgendaHideBirthdayEvents=Masquer les anniversaires de contacts
|
||||
Busy=Occupé
|
||||
|
||||
@ -380,7 +380,7 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea
|
||||
print '<div class="fichecenter">';
|
||||
print '<div class="fichehalfleft">';
|
||||
print '<div class="underbanner clearboth"></div>';
|
||||
print '<table class="border centpercent">'."\n";
|
||||
print '<table class="border centpercent tableforfield">'."\n";
|
||||
|
||||
// Common attributes
|
||||
//$keyforbreak='fieldkeytoswitchonsecondcolumn'; // We change column just before this field
|
||||
|
||||
@ -755,7 +755,7 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea
|
||||
|
||||
print '<tr>';
|
||||
print '<td>'.$tmpproduct->getNomUrl(1).'</td>';
|
||||
print '<td class="right">';
|
||||
print '<td class="right nowraponall">';
|
||||
$help = '';
|
||||
if ($line->qty_frozen) $help .= ($help ? '<br>' : '').'<strong>'.$langs->trans("QuantityFrozen").'</strong>: '.yn(1).' ('.$langs->trans("QuantityConsumedInvariable").')';
|
||||
if ($line->disable_stock_change) $help .= ($help ? '<br>' : '').'<strong>'.$langs->trans("DisableStockChange").'</strong>: '.yn(1).' ('.(($tmpproduct->type == Product::TYPE_SERVICE && empty($conf->global->STOCK_SUPPORTS_SERVICES)) ? $langs->trans("NoStockChangeOnServices") : $langs->trans("DisableStockChangeHelp")).')';
|
||||
@ -804,7 +804,7 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea
|
||||
print '</td>';
|
||||
print '<td></td>';
|
||||
print '<td class="right">'.$line2['qty'].'</td>';
|
||||
print '<td>';
|
||||
print '<td class="tdoverflowmax150">';
|
||||
if ($line2['fk_warehouse'] > 0) {
|
||||
$result = $tmpwarehouse->fetch($line2['fk_warehouse']);
|
||||
if ($result > 0) print $tmpwarehouse->getNomUrl(1);
|
||||
@ -917,7 +917,7 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea
|
||||
print '<tr>';
|
||||
print '<td>'.$tmpproduct->getNomUrl(1).'</td>';
|
||||
print '<td class="right">'.$line->qty.'</td>';
|
||||
print '<td class="right">';
|
||||
print '<td class="right nowraponall">';
|
||||
if ($alreadyproduced) {
|
||||
print '<script>';
|
||||
print 'jQuery(document).ready(function() {
|
||||
@ -953,7 +953,7 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea
|
||||
print '</td>';
|
||||
print '<td></td>';
|
||||
print '<td class="right">'.$line2['qty'].'</td>';
|
||||
print '<td>';
|
||||
print '<td class="tdoverflowmax150">';
|
||||
if ($line2['fk_warehouse'] > 0) {
|
||||
$result = $tmpwarehouse->fetch($line2['fk_warehouse']);
|
||||
if ($result > 0) print $tmpwarehouse->getNomUrl(1);
|
||||
|
||||
@ -528,6 +528,7 @@ print load_fiche_titre($langs->trans("ProductOtherConf"), '', '');
|
||||
print '<form method="POST" action="'.$_SERVER['PHP_SELF'].'">';
|
||||
print '<input type="hidden" name="token" value="'.newToken().'">';
|
||||
print '<input type="hidden" name="action" value="other">';
|
||||
print '<input type="hidden" name="page_y" value="">';
|
||||
|
||||
print '<table class="noborder centpercent">';
|
||||
print '<tr class="liste_titre">';
|
||||
@ -742,7 +743,9 @@ if (!empty($conf->global->PRODUCT_CANVAS_ABILITY))
|
||||
|
||||
print '</table>';
|
||||
|
||||
print '<div class="center"><input type="submit" class="button" value="'.$langs->trans("Modify").'"></div>';
|
||||
print '<div class="center">';
|
||||
print '<input type="submit" class="button reposition" value="'.$langs->trans("Modify").'">';
|
||||
print '</div>';
|
||||
|
||||
print '</form>';
|
||||
|
||||
|
||||
@ -450,7 +450,13 @@ if (empty($reshook))
|
||||
$sql .= $priceid.','.$price.','.$unitPrice.','.$quantity.','.$remise_percent.','.$remise.')';
|
||||
|
||||
$result = $db->query($sql);
|
||||
if (!$result) dol_print_error($db);
|
||||
if (!$result) {
|
||||
if ($db->lasterrno() == 'DB_ERROR_RECORD_ALREADY_EXISTS') {
|
||||
setEventMessages($langs->trans("DuplicateRecord"), null, 'errors');
|
||||
} else {
|
||||
dol_print_error($db);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -886,13 +892,14 @@ if (!empty($conf->global->PRODUIT_MULTIPRICES) || !empty($conf->global->PRODUIT_
|
||||
{
|
||||
if ($action == 'edit_price_by_qty' && $rowid == $prices['rowid'] && ($user->rights->produit->creer || $user->rights->service->creer)) {
|
||||
print '<form action="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'" method="POST">';
|
||||
print '<input type="hidden" name="token" value="'.newToken().'">';
|
||||
print '<input type="hidden" name="action" value="update_price_by_qty">';
|
||||
print '<input type="hidden" name="priceid" value="'.$object->prices_by_qty_id[$i].'">';
|
||||
print '<input type="hidden" value="'.$prices['rowid'].'" name="rowid">';
|
||||
print '<tr class="'.($ii % 2 == 0 ? 'pair' : 'impair').'">';
|
||||
print '<td><input size="5" type="text" value="'.$prices['quantity'].'" name="quantity"></td>';
|
||||
print '<td class="right" colspan="2"><input size="10" type="text" value="'.price2num($prices['price'], 'MU').'" name="price"> '.$object->price_base_type.'</td>';
|
||||
print '<td class="right"><input size="5" type="text" value="'.$prices['remise_percent'].'" name="remise_percent"> %</td>';
|
||||
print '<td class="right nowraponall"><input size="5" type="text" value="'.$prices['remise_percent'].'" name="remise_percent"> %</td>';
|
||||
print '<td class="center"><input type="submit" value="'.$langs->trans("Modify").'" class="button"></td>';
|
||||
print '</tr>';
|
||||
print '</form>';
|
||||
@ -904,9 +911,9 @@ if (!empty($conf->global->PRODUIT_MULTIPRICES) || !empty($conf->global->PRODUIT_
|
||||
print '<td class="right">'.price($prices['remise_percent']).' %</td>';
|
||||
print '<td class="center">';
|
||||
if (($user->rights->produit->creer || $user->rights->service->creer)) {
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'&action=edit_price_by_qty&rowid='.$prices["rowid"].'">';
|
||||
print '<a class="editfielda marginleftonly marginrightonly" href="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'&action=edit_price_by_qty&rowid='.$prices["rowid"].'">';
|
||||
print img_edit().'</a>';
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'&action=delete_price_by_qty&rowid='.$prices["rowid"].'">';
|
||||
print '<a class="marginleftonly marginrightonly" href="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'&action=delete_price_by_qty&rowid='.$prices["rowid"].'">';
|
||||
print img_delete().'</a>';
|
||||
} else {
|
||||
print ' ';
|
||||
@ -917,6 +924,7 @@ if (!empty($conf->global->PRODUIT_MULTIPRICES) || !empty($conf->global->PRODUIT_
|
||||
}
|
||||
if ($action != 'edit_price_by_qty' && ($user->rights->produit->creer || $user->rights->service->creer)) {
|
||||
print '<form action="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'" method="POST">';
|
||||
print '<input type="hidden" name="token" value="'.newToken().'">';
|
||||
print '<input type="hidden" name="action" value="update_price_by_qty">';
|
||||
print '<input type="hidden" name="priceid" value="'.$object->prices_by_qty_id[$i].'">'; // id in product_price
|
||||
print '<input type="hidden" value="0" name="rowid">'; // id in product_price
|
||||
@ -924,17 +932,17 @@ if (!empty($conf->global->PRODUIT_MULTIPRICES) || !empty($conf->global->PRODUIT_
|
||||
print '<td><input size="5" type="text" value="1" name="quantity"></td>';
|
||||
print '<td class="right" class="nowrap"><input size="10" type="text" value="0" name="price"> '.$object->price_base_type.'</td>';
|
||||
print '<td class="right"> </td>';
|
||||
print '<td class="right" class="nowrap"><input size="5" type="text" value="0" name="remise_percent"> %</td>';
|
||||
print '<td class="right" class="nowraponall"><input size="5" type="text" value="0" name="remise_percent"> %</td>';
|
||||
print '<td class="center"><input type="submit" value="'.$langs->trans("Add").'" class="button"></td>';
|
||||
print '</tr>';
|
||||
print '</form>';
|
||||
}
|
||||
|
||||
print '</table>';
|
||||
print '<a href="'.$_SERVER['PHP_SELF'].'?id='.$object->id.'&action=disable_price_by_qty&level='.$i.'">('.$langs->trans("DisablePriceByQty").')</a>';
|
||||
print '<a class="editfielda marginleftonly marginrightonly" href="'.$_SERVER['PHP_SELF'].'?id='.$object->id.'&action=disable_price_by_qty&level='.$i.'">('.$langs->trans("DisablePriceByQty").')</a>';
|
||||
} else {
|
||||
print $langs->trans("No");
|
||||
print ' <a href="'.$_SERVER['PHP_SELF'].'?id='.$object->id.'&action=activate_price_by_qty&level='.$i.'">('.$langs->trans("Activate").')</a>';
|
||||
print ' <a class="marginleftonly marginrightonly" href="'.$_SERVER['PHP_SELF'].'?id='.$object->id.'&action=activate_price_by_qty&level='.$i.'">('.$langs->trans("Activate").')</a>';
|
||||
}
|
||||
print '</td></tr>';
|
||||
}
|
||||
@ -1002,6 +1010,7 @@ if (!empty($conf->global->PRODUIT_MULTIPRICES) || !empty($conf->global->PRODUIT_
|
||||
if ($action != 'edit_price_by_qty')
|
||||
{
|
||||
print '<form action="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'" method="POST">'; // FIXME a form into a table is not allowed
|
||||
print '<input type="hidden" name="token" value="'.newToken().'">';
|
||||
print '<input type="hidden" name="action" value="update_price_by_qty">';
|
||||
print '<input type="hidden" name="priceid" value="'.$object->prices_by_qty_id[0].'">'; // id in product_price
|
||||
print '<input type="hidden" value="0" name="rowid">'; // id in product_price_by_qty
|
||||
@ -1013,7 +1022,7 @@ if (!empty($conf->global->PRODUIT_MULTIPRICES) || !empty($conf->global->PRODUIT_
|
||||
//print $object->price_base_type;
|
||||
print '</td>';
|
||||
print '<td class="right"> </td>';
|
||||
print '<td class="right"><input type="text" class="width50 right" value="0" name="remise_percent"> %</td>';
|
||||
print '<td class="right nowraponall"><input type="text" class="width50 right" value="0" name="remise_percent"> %</td>';
|
||||
print '<td class="center"><input type="submit" value="'.$langs->trans("Add").'" class="button"></td>';
|
||||
print '</tr>';
|
||||
|
||||
@ -1024,6 +1033,7 @@ if (!empty($conf->global->PRODUIT_MULTIPRICES) || !empty($conf->global->PRODUIT_
|
||||
if ($action == 'edit_price_by_qty' && $rowid == $prices['rowid'] && ($user->rights->produit->creer || $user->rights->service->creer))
|
||||
{
|
||||
print '<form action="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'" method="POST">';
|
||||
print '<input type="hidden" name="token" value="'.newToken().'">';
|
||||
print '<input type="hidden" name="action" value="update_price_by_qty">';
|
||||
print '<input type="hidden" name="priceid" value="'.$object->prices_by_qty_id[0].'">'; // id in product_price
|
||||
print '<input type="hidden" value="'.$prices['rowid'].'" name="rowid">'; // id in product_price_by_qty
|
||||
@ -1035,7 +1045,7 @@ if (!empty($conf->global->PRODUIT_MULTIPRICES) || !empty($conf->global->PRODUIT_
|
||||
print $prices['price_base_type'];
|
||||
print '</td>';
|
||||
print '<td class="right"> </td>';
|
||||
print '<td class="right"><input class="width50 right" type="text" value="'.$prices['remise_percent'].'" name="remise_percent"> %</td>';
|
||||
print '<td class="right nowraponall"><input class="width50 right" type="text" value="'.$prices['remise_percent'].'" name="remise_percent"> %</td>';
|
||||
print '<td class="center"><input type="submit" value="'.$langs->trans("Modify").'" class="button"></td>';
|
||||
print '</tr>';
|
||||
print '</form>';
|
||||
@ -1052,9 +1062,9 @@ if (!empty($conf->global->PRODUIT_MULTIPRICES) || !empty($conf->global->PRODUIT_
|
||||
print '<td class="center">';
|
||||
if (($user->rights->produit->creer || $user->rights->service->creer))
|
||||
{
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'&action=edit_price_by_qty&rowid='.$prices["rowid"].'">';
|
||||
print '<a class="editfielda marginleftonly marginrightonly" href="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'&action=edit_price_by_qty&rowid='.$prices["rowid"].'">';
|
||||
print img_edit().'</a>';
|
||||
print '<a href="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'&action=delete_price_by_qty&rowid='.$prices["rowid"].'">';
|
||||
print '<a class="marginleftonly marginrightonly" href="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'&action=delete_price_by_qty&rowid='.$prices["rowid"].'">';
|
||||
print img_delete().'</a>';
|
||||
} else {
|
||||
print ' ';
|
||||
@ -1837,6 +1847,7 @@ if (!empty($conf->global->PRODUIT_CUSTOMER_PRICES))
|
||||
if (count($prodcustprice->lines) > 0)
|
||||
{
|
||||
print '<form action="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'" method="POST">';
|
||||
print '<input type="hidden" name="token" value="'.newToken().'">';
|
||||
print '<input type="hidden" name="id" value="'.$object->id.'">';
|
||||
|
||||
print '<table class="noborder centpercent">';
|
||||
@ -1951,6 +1962,7 @@ if (!empty($conf->global->PRODUIT_CUSTOMER_PRICES))
|
||||
print_barre_liste($langs->trans('PriceByCustomer'), $page, $_SERVER ['PHP_SELF'], $option, $sortfield, $sortorder, '', count($prodcustprice->lines), $nbtotalofrecords, 'title_accountancy.png');
|
||||
|
||||
print '<form action="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'" method="POST">';
|
||||
print '<input type="hidden" name="token" value="'.newToken().'">';
|
||||
print '<input type="hidden" name="id" value="'.$object->id.'">';
|
||||
|
||||
print '<table class="noborder centpercent">';
|
||||
|
||||
@ -591,7 +591,7 @@ if (!$showdatefilter)
|
||||
{
|
||||
print '<div class="center centpercent">';
|
||||
print '<form action="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'" method="post">';
|
||||
print '<input type="hidden" name="token" value="'.$_SESSION["newtoken"].'">';
|
||||
print '<input type="hidden" name="token" value="'.newToken().'">';
|
||||
print '<input type="hidden" name="tablename" value="'.$tablename.'">';
|
||||
print '<input type="hidden" name="action" value="view">';
|
||||
print '<table class="center"><tr>';
|
||||
@ -876,7 +876,7 @@ foreach ($listofreferent as $key => $value)
|
||||
|
||||
if (empty($conf->global->PROJECT_LINK_ON_OVERWIEW_DISABLED) && $idtofilterthirdparty && !in_array($tablename, $exclude_select_element))
|
||||
{
|
||||
$selectList = $formproject->select_element($tablename, $idtofilterthirdparty, 'minwidth300', -2, !empty($project_field) ? $project_field : 'fk_projet');
|
||||
$selectList = $formproject->select_element($tablename, $idtofilterthirdparty, 'minwidth300 minwidth75imp', -2, !empty($project_field) ? $project_field : 'fk_projet');
|
||||
if ($selectList < 0)
|
||||
{
|
||||
setEventMessages($formproject->error, $formproject->errors, 'errors');
|
||||
@ -885,14 +885,14 @@ foreach ($listofreferent as $key => $value)
|
||||
// Define form with the combo list of elements to link
|
||||
$addform .= '<div class="inline-block valignmiddle">';
|
||||
$addform .= '<form action="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'" method="post">';
|
||||
$addform .= '<input type="hidden" name="token" value="'.$_SESSION["newtoken"].'">';
|
||||
$addform .= '<input type="hidden" name="token" value="'.newToken().'">';
|
||||
$addform .= '<input type="hidden" name="tablename" value="'.$tablename.'">';
|
||||
$addform .= '<input type="hidden" name="action" value="addelement">';
|
||||
$addform .= '<input type="hidden" name="datesrfc" value="'.dol_print_date($dates, 'dayhourrfc').'">';
|
||||
$addform .= '<input type="hidden" name="dateerfc" value="'.dol_print_date($datee, 'dayhourrfc').'">';
|
||||
$addform .= '<table><tr><td>'.$langs->trans("SelectElement").'</td>';
|
||||
$addform .= '<table><tr><td><span class="hideonsmartphone opacitymedium">'.$langs->trans("SelectElement").'</span></td>';
|
||||
$addform .= '<td>'.$selectList.'</td>';
|
||||
$addform .= '<td><input type="submit" class="button" value="'.dol_escape_htmltag($langs->trans("AddElement")).'"></td>';
|
||||
$addform .= '<td><input type="submit" class="button" value="'.dol_escape_htmltag($langs->trans("LinkToElementShort")).'"></td>';
|
||||
$addform .= '</tr></table>';
|
||||
$addform .= '</form>';
|
||||
$addform .= '</div>';
|
||||
@ -901,9 +901,9 @@ foreach ($listofreferent as $key => $value)
|
||||
if (empty($conf->global->PROJECT_CREATE_ON_OVERVIEW_DISABLED) && $urlnew)
|
||||
{
|
||||
$addform .= '<div class="inline-block valignmiddle">';
|
||||
if ($testnew) $addform .= '<a class="buttonxxx" href="'.$urlnew.'"><span class="valignmiddle text-plus-circle">'.($buttonnew ? $langs->trans($buttonnew) : $langs->trans("Create")).'</span><span class="fa fa-plus-circle valignmiddle paddingleft"></span></a>';
|
||||
if ($testnew) $addform .= '<a class="buttonxxx" href="'.$urlnew.'"><span class="valignmiddle text-plus-circle hideonsmartphone">'.($buttonnew ? $langs->trans($buttonnew) : $langs->trans("Create")).'</span><span class="fa fa-plus-circle valignmiddle paddingleft"></span></a>';
|
||||
elseif (empty($conf->global->MAIN_BUTTON_HIDE_UNAUTHORIZED)) {
|
||||
$addform .= '<a class="buttonxxx buttonRefused" disabled="disabled" href="#"><span class="valignmiddle text-plus-circle">'.($buttonnew ? $langs->trans($buttonnew) : $langs->trans("Create")).'</span><span class="fa fa-plus-circle valignmiddle paddingleft"></span></a>';
|
||||
$addform .= '<a class="buttonxxx buttonRefused" disabled="disabled" href="#"><span class="valignmiddle text-plus-circle hideonsmartphone">'.($buttonnew ? $langs->trans($buttonnew) : $langs->trans("Create")).'</span><span class="fa fa-plus-circle valignmiddle paddingleft"></span></a>';
|
||||
}
|
||||
$addform .= '<div>';
|
||||
}
|
||||
@ -911,6 +911,7 @@ foreach ($listofreferent as $key => $value)
|
||||
print load_fiche_titre($langs->trans($title), $addform, '');
|
||||
|
||||
print "\n".'<!-- Table for tablename = '.$tablename.' -->'."\n";
|
||||
print '<div class="div-table-responsive">';
|
||||
print '<table class="noborder centpercent">';
|
||||
|
||||
print '<tr class="liste_titre">';
|
||||
@ -1027,7 +1028,7 @@ foreach ($listofreferent as $key => $value)
|
||||
print "</td>\n";
|
||||
|
||||
// Ref
|
||||
print '<td class="left nowrap">';
|
||||
print '<td class="left nowraponall">';
|
||||
if ($tablename == 'expensereport_det')
|
||||
{
|
||||
print $expensereport->getNomUrl(1);
|
||||
@ -1334,6 +1335,7 @@ foreach ($listofreferent as $key => $value)
|
||||
}
|
||||
}
|
||||
print "</table>";
|
||||
print '</div>';
|
||||
print "<br>\n";
|
||||
}
|
||||
}
|
||||
|
||||
@ -62,6 +62,7 @@ $search_task_ref_parent = GETPOST('search_task_ref_parent');
|
||||
$search_project_user = GETPOST('search_project_user');
|
||||
$search_task_user = GETPOST('search_task_user');
|
||||
$search_task_progress = GETPOST('search_task_progress');
|
||||
$search_societe = GETPOST('search_societe');
|
||||
|
||||
$mine = $_REQUEST['mode'] == 'mine' ? 1 : 0;
|
||||
if ($mine) { $search_task_user = $user->id; $mine = 0; }
|
||||
|
||||
@ -2208,7 +2208,7 @@ if (preg_match('/^dopayment/', $action)) // If we choosed/click on the payment
|
||||
var hiddenInput2 = document.createElement('input');
|
||||
hiddenInput2.setAttribute('type', 'hidden');
|
||||
hiddenInput2.setAttribute('name', 'token');
|
||||
hiddenInput2.setAttribute('value', '<?php echo $_SESSION["newtoken"]; ?>');
|
||||
hiddenInput2.setAttribute('value', '<?php echo newToken(); ?>');
|
||||
form.appendChild(hiddenInput2);
|
||||
|
||||
// Submit the form
|
||||
@ -2232,7 +2232,7 @@ if (preg_match('/^dopayment/', $action)) // If we choosed/click on the payment
|
||||
var hiddenInput2 = document.createElement('input');
|
||||
hiddenInput2.setAttribute('type', 'hidden');
|
||||
hiddenInput2.setAttribute('name', 'token');
|
||||
hiddenInput2.setAttribute('value', '<?php echo $_SESSION["newtoken"]; ?>');
|
||||
hiddenInput2.setAttribute('value', '<?php echo newToken(); ?>');
|
||||
form.appendChild(hiddenInput2);
|
||||
|
||||
// Submit the form
|
||||
|
||||
@ -4432,7 +4432,7 @@ table.cal_month td:last-child { border-right: 0px; }
|
||||
.cal_today_peruser_impair { background: #F8F8F0; }
|
||||
.peruser_busy { }
|
||||
.peruser_notbusy { opacity: 0.5; }
|
||||
table.cal_event { border: none; border-collapse: collapse; margin-bottom: 1px; min-height: 20px; }
|
||||
table.cal_event { border: none; border-collapse: collapse; margin-bottom: 1px; min-height: 20px; filter: saturate(0.8); }
|
||||
table.cal_event td { border: none; padding-<?php print $left; ?>: 2px; padding-<?php print $right; ?>: 2px; padding-top: 0px; padding-bottom: 0px; }
|
||||
table.cal_event td.cal_event { padding: 4px 4px !important; }
|
||||
table.cal_event td.cal_event_right { padding: 4px 4px !important; }
|
||||
@ -4443,6 +4443,7 @@ table.cal_event td.cal_event_right { padding: 4px 4px !important; }
|
||||
.cal_event_busy a:hover { color: #111111; font-weight: normal !important; color:rgba(255,255,255,.75); }
|
||||
.cal_event_busy { }
|
||||
.cal_peruserviewname { max-width: 140px; height: 22px; }
|
||||
table.cal_month tr td table.nobordernopadding tr td { padding: 0 2px 0 2px; }
|
||||
|
||||
.calendarviewcontainertr { height: 100px; }
|
||||
|
||||
|
||||
@ -59,8 +59,8 @@ $colorbacktabcard1 = '255,255,255'; // card
|
||||
$colorbacktabactive = '234,234,234';
|
||||
$colorbacklineimpair1 = '255,255,255'; // line impair
|
||||
$colorbacklineimpair2 = '255,255,255'; // line impair
|
||||
$colorbacklinepair1 = '251,251,251'; // line pair
|
||||
$colorbacklinepair2 = '251,251,251'; // line pair
|
||||
$colorbacklinepair1 = '250,250,250'; // line pair
|
||||
$colorbacklinepair2 = '250,250,250'; // line pair
|
||||
$colorbacklinepairhover = '230,237,244'; // line hover
|
||||
$colorbacklinepairchecked = '230,237,244'; // line checked
|
||||
$colorbacklinebreak = '248,247,244'; // line break
|
||||
|
||||
Loading…
Reference in New Issue
Block a user