Resolve conflicts
This commit is contained in:
commit
e01f912f41
@ -653,6 +653,11 @@ if (preg_match('/^asc/i', $sortorder)) {
|
||||
$sortorder = "desc";
|
||||
}
|
||||
|
||||
// Warning to explain why list of record is not consistent with the other list view (missing a lot of lines)
|
||||
if ($type == 'sub') {
|
||||
print info_admin($langs->trans("WarningRecordWithoutSubledgerAreExcluded"));
|
||||
}
|
||||
|
||||
$moreforfilter = '';
|
||||
|
||||
// Accountancy account
|
||||
|
||||
@ -93,15 +93,17 @@ print '<td>'.$langs->trans("Parameter").'</td><td>'.$langs->trans("Value").'</td
|
||||
print '<td class="right"><input type="submit" class="button button-edit" '.$option.' value="'.$langs->trans("Modify").'"></td>';
|
||||
print "</tr>\n";
|
||||
|
||||
print '<tr class="oddeven"><td>'.$langs->trans("DEBUGBAR_LOGS_LINES_NUMBER").'</td>';
|
||||
print '<td colspan="2"><input type="text" class="flat" name="DEBUGBAR_LOGS_LINES_NUMBER" value="'.(empty($conf->global->DEBUGBAR_LOGS_LINES_NUMBER) ? 250 : $conf->global->DEBUGBAR_LOGS_LINES_NUMBER).'">'; // This slow seriously output
|
||||
print ' '.$langs->trans("WarningValueHigherSlowsDramaticalyOutput");
|
||||
print '<tr class="oddeven"><td class="nowrap">'.$langs->trans("DEBUGBAR_USE_LOG_FILE").'</td>';
|
||||
print '<td>';
|
||||
print $form->selectyesno('DEBUGBAR_USE_LOG_FILE', $conf->global->DEBUGBAR_USE_LOG_FILE, 1);
|
||||
print '</td><td>';
|
||||
print '<span class="opacitymedium"> '.$langs->trans("UsingLogFileShowAllRecordOfSubrequestButIsSlower").'</span>';
|
||||
print '</td></tr>';
|
||||
|
||||
print '<tr class="oddeven"><td>'.$langs->trans("DEBUGBAR_USE_LOG_FILE").'</td>';
|
||||
print '<td colspan="2">';
|
||||
print $form->selectyesno('DEBUGBAR_USE_LOG_FILE', $conf->global->DEBUGBAR_USE_LOG_FILE, 1);
|
||||
print ' '.$langs->trans("UsingLogFileShowAllRecordOfSubrequestButIsSlower");
|
||||
print '<tr class="oddeven"><td class="nowrap">'.$langs->trans("DEBUGBAR_LOGS_LINES_NUMBER").'</td>';
|
||||
print '<td><input type="text" class="flat width75" name="DEBUGBAR_LOGS_LINES_NUMBER" value="'.(empty($conf->global->DEBUGBAR_LOGS_LINES_NUMBER) ? 250 : $conf->global->DEBUGBAR_LOGS_LINES_NUMBER).'">'; // This slow seriously output
|
||||
print '</td><td>';
|
||||
print '<span class="opacitymedium">'.$langs->trans("WarningValueHigherSlowsDramaticalyOutput").'</span>';
|
||||
print '</td></tr>';
|
||||
|
||||
print '</table>';
|
||||
|
||||
@ -220,7 +220,7 @@ if ($action == 'edit') {
|
||||
foreach ($arrayofparameters as $constname => $val) {
|
||||
if ($val['enabled']==1) {
|
||||
$setupnotempty++;
|
||||
print '<tr class="oddeven"><td>aa';
|
||||
print '<tr class="oddeven"><td>';
|
||||
$tooltiphelp = (($langs->trans($constname . 'Tooltip') != $constname . 'Tooltip') ? $langs->trans($constname . 'Tooltip') : '');
|
||||
$tooltiphelp .= (($langs->trans($constname . 'Tooltip2') && $langs->trans($constname . 'Tooltip2') != $constname . 'Tooltip2') ? '<br><br>'."\n".$langs->trans($constname . 'Tooltip2') : '');
|
||||
print '<span id="helplink'.$constname.'" class="spanforparamtooltip">'.$form->textwithpicto($langs->trans($constname), $tooltiphelp, 1, 'info', '', 0, 3, 'tootips'.$constname).'</span>';
|
||||
|
||||
@ -831,6 +831,13 @@ if (empty($reshook)) {
|
||||
foreach ($object->lines as $line) {
|
||||
$result = $object->updateline($line->id, $line->subprice, $line->qty, $line->remise_percent, $vat_rate, $localtax1_rate, $localtax2_rate, $line->desc, 'HT', $line->info_bits, $line->special_code, $line->fk_parent_line, 0, $line->fk_fournprice, $line->pa_ht, $line->label, $line->product_type, $line->date_start, $line->date_end, $line->array_options, $line->fk_unit, $line->multicurrency_subprice);
|
||||
}
|
||||
} elseif ($action == 'addline' && GETPOST('submitforalllines', 'alpha') && GETPOST('remiseforalllines', 'alpha') !== '' && $usercancreate) {
|
||||
// Define vat_rate
|
||||
$remise_percent = (GETPOST('remiseforalllines') ? GETPOST('remiseforalllines') : 0);
|
||||
$remise_percent = str_replace('*', '', $remise_percent);
|
||||
foreach ($object->lines as $line) {
|
||||
$result = $object->updateline($line->id, $line->subprice, $line->qty, $remise_percent, $line->tva_tx, $line->localtax1_tx, $line->localtax2_tx, $line->desc, 'HT', $line->info_bits, $line->special_code, $line->fk_parent_line, 0, $line->fk_fournprice, $line->pa_ht, $line->label, $line->product_type, $line->date_start, $line->date_end, $line->array_options, $line->fk_unit, $line->multicurrency_subprice);
|
||||
}
|
||||
} elseif ($action == 'addline' && $usercancreate) { // Add line
|
||||
// Set if we used free entry or predefined product
|
||||
$predef = '';
|
||||
@ -1579,19 +1586,19 @@ if ($action == 'create') {
|
||||
print '<table class="border centpercent">';
|
||||
|
||||
// Reference
|
||||
print '<tr><td class="titlefieldcreate fieldrequired">'.$langs->trans('Ref').'</td><td>'.$langs->trans("Draft").'</td></tr>';
|
||||
print '<tr class="field_ref"><td class="titlefieldcreate fieldrequired">'.$langs->trans('Ref').'</td><td class="valuefieldcreate">'.$langs->trans("Draft").'</td></tr>';
|
||||
|
||||
// Ref customer
|
||||
print '<tr><td>'.$langs->trans('RefCustomer').'</td><td>';
|
||||
print '<tr class="field_ref_client"><td class="titlefieldcreate">'.$langs->trans('RefCustomer').'</td><td class="valuefieldcreate">';
|
||||
print '<input type="text" name="ref_client" value="'.GETPOST('ref_client').'"></td>';
|
||||
print '</tr>';
|
||||
|
||||
// Third party
|
||||
print '<tr>';
|
||||
print '<td class="fieldrequired">'.$langs->trans('Customer').'</td>';
|
||||
print '<tr class="field_socid">';
|
||||
print '<td class="titlefieldcreate fieldrequired">'.$langs->trans('Customer').'</td>';
|
||||
$shipping_method_id = 0;
|
||||
if ($socid > 0) {
|
||||
print '<td>';
|
||||
print '<td class="valuefieldcreate">';
|
||||
print $soc->getNomUrl(1);
|
||||
print '<input type="hidden" name="socid" value="'.$soc->id.'">';
|
||||
print '</td>';
|
||||
@ -1600,7 +1607,7 @@ if ($action == 'create') {
|
||||
}
|
||||
//$warehouse_id = $soc->warehouse_id;
|
||||
} else {
|
||||
print '<td>';
|
||||
print '<td class="valuefieldcreate">';
|
||||
print img_picto('', 'company').$form->select_company('', 'socid', '(s.client = 1 OR s.client = 2 OR s.client = 3) AND status=1', 'SelectThirdParty', 0, 0, null, 0, 'minwidth300 maxwidth500 widthcentpercentminusxx');
|
||||
// reload page to retrieve customer informations
|
||||
if (empty($conf->global->RELOAD_PAGE_ON_CUSTOMER_CHANGE_DISABLED)) {
|
||||
@ -1623,13 +1630,13 @@ if ($action == 'create') {
|
||||
|
||||
if ($socid > 0) {
|
||||
// Contacts (ask contact only if thirdparty already defined).
|
||||
print "<tr><td>".$langs->trans("DefaultContact").'</td><td>';
|
||||
print '<tr class="field_contactid"><td class="titlefieldcreate">'.$langs->trans("DefaultContact").'</td><td class="valuefieldcreate">';
|
||||
print img_picto('', 'contact');
|
||||
print $form->selectcontacts($soc->id, $contactid, 'contactid', 1, '', '', 0, 'minwidth300');
|
||||
print '</td></tr>';
|
||||
|
||||
// Third party discounts info line
|
||||
print '<tr><td>'.$langs->trans('Discounts').'</td><td>';
|
||||
print '<tr class="field_discount_info"><td class="titlefieldcreate">'.$langs->trans('Discounts').'</td><td class="valuefieldcreate">';
|
||||
|
||||
$absolute_discount = $soc->getAvailableDiscounts();
|
||||
|
||||
@ -1641,44 +1648,44 @@ if ($action == 'create') {
|
||||
}
|
||||
|
||||
// Date
|
||||
print '<tr><td class="fieldrequired">'.$langs->trans('DatePropal').'</td><td>';
|
||||
print '<tr class="field_addprop"><td class="titlefieldcreate fieldrequired">'.$langs->trans('DatePropal').'</td><td class="valuefieldcreate">';
|
||||
print $form->selectDate('', '', '', '', '', "addprop", 1, 1);
|
||||
print '</td></tr>';
|
||||
|
||||
// Validaty duration
|
||||
print '<tr><td class="fieldrequired">'.$langs->trans("ValidityDuration").'</td><td>'.img_picto('', 'clock', 'class="paddingright"').'<input name="duree_validite" class="width50" value="'.(GETPOSTISSET('duree_validite') ? GETPOST('duree_validite', 'alphanohtml') : $conf->global->PROPALE_VALIDITY_DURATION).'"> '.$langs->trans("days").'</td></tr>';
|
||||
print '<tr class="field_duree_validitee"><td class="titlefieldcreate fieldrequired">'.$langs->trans("ValidityDuration").'</td><td class="valuefieldcreate">'.img_picto('', 'clock', 'class="paddingright"').'<input name="duree_validite" class="width50" value="'.(GETPOSTISSET('duree_validite') ? GETPOST('duree_validite', 'alphanohtml') : $conf->global->PROPALE_VALIDITY_DURATION).'"> '.$langs->trans("days").'</td></tr>';
|
||||
|
||||
// Terms of payment
|
||||
print '<tr><td class="nowrap">'.$langs->trans('PaymentConditionsShort').'</td><td>';
|
||||
print '<tr class="field_cond_reglement_id"><td class="titlefieldcreate nowrap">'.$langs->trans('PaymentConditionsShort').'</td><td class="valuefieldcreate">';
|
||||
print img_picto('', 'payment', 'class="pictofixedwidth"');
|
||||
$form->select_conditions_paiements((GETPOSTISSET('cond_reglement_id') && GETPOST('cond_reglement_id') != 0) ? GETPOST('cond_reglement_id', 'int') : $soc->cond_reglement_id, 'cond_reglement_id', -1, 1);
|
||||
print '</td></tr>';
|
||||
|
||||
// Mode of payment
|
||||
print '<tr><td>'.$langs->trans('PaymentMode').'</td><td>';
|
||||
print '<tr class="field_mode_reglement_id"><td class="titlefieldcreate">'.$langs->trans('PaymentMode').'</td><td class="valuefieldcreate">';
|
||||
print img_picto('', 'bank', 'class="pictofixedwidth"');
|
||||
$form->select_types_paiements((GETPOSTISSET('mode_reglement_id') ? GETPOST('mode_reglement_id', 'int') : $soc->mode_reglement_id), 'mode_reglement_id', 'CRDT', 0, 1, 0, 0, 1, 'maxwidth200 widthcentpercentminusx');
|
||||
print '</td></tr>';
|
||||
|
||||
// Bank Account
|
||||
if (!empty($conf->global->BANK_ASK_PAYMENT_BANK_DURING_PROPOSAL) && !empty($conf->banque->enabled)) {
|
||||
print '<tr><td>'.$langs->trans('BankAccount').'</td><td>';
|
||||
print '<tr class="field_fk_account"><td class="titlefieldcreate">'.$langs->trans('BankAccount').'</td><td class="valuefieldcreate">';
|
||||
print img_picto('', 'bank_account', 'class="pictofixedwidth"').$form->select_comptes($soc->fk_account, 'fk_account', 0, '', 1, '', 0, 'maxwidth200 widthcentpercentminusx', 1);
|
||||
print '</td></tr>';
|
||||
}
|
||||
|
||||
// Source / Channel - What trigger creation
|
||||
print '<tr><td>'.$langs->trans('Source').'</td><td>';
|
||||
print '<tr class="field_demand_reason_id"><td class="titlefieldcreate">'.$langs->trans('Source').'</td><td class="valuefieldcreate">';
|
||||
print img_picto('', 'question', 'class="pictofixedwidth"');
|
||||
$form->selectInputReason('', 'demand_reason_id', "SRC_PROP", 1, 'maxwidth200 widthcentpercentminusx');
|
||||
print '</td></tr>';
|
||||
|
||||
// Delivery delay
|
||||
print '<tr class="fielddeliverydelay"><td>'.$langs->trans('AvailabilityPeriod');
|
||||
print '<tr class="field_availability_id"><td class="titlefieldcreate">'.$langs->trans('AvailabilityPeriod');
|
||||
if (!empty($conf->commande->enabled)) {
|
||||
print ' ('.$langs->trans('AfterOrder').')';
|
||||
}
|
||||
print '</td><td>';
|
||||
print '</td><td class="valuefieldcreate">';
|
||||
print img_picto('', 'clock', 'class="pictofixedwidth"');
|
||||
$form->selectAvailabilityDelay('', 'availability_id', '', 1, 'maxwidth200 widthcentpercentminusx');
|
||||
print '</td></tr>';
|
||||
@ -1688,7 +1695,7 @@ if ($action == 'create') {
|
||||
if (!empty($conf->global->SOCIETE_ASK_FOR_SHIPPING_METHOD) && !empty($soc->shipping_method_id)) {
|
||||
$shipping_method_id = $soc->shipping_method_id;
|
||||
}
|
||||
print '<tr><td>'.$langs->trans('SendingMethod').'</td><td>';
|
||||
print '<tr class="field_shipping_method_id"><td class="titlefieldcreate">'.$langs->trans('SendingMethod').'</td><td class="valuefieldcreate">';
|
||||
print img_picto('', 'object_dollyrevert', 'class="pictofixedwidth"');
|
||||
print $form->selectShippingMethod($shipping_method_id, 'shipping_method_id', '', 1, '', 0, 'maxwidth200 widthcentpercentminusx');
|
||||
print '</td></tr>';
|
||||
@ -1698,14 +1705,14 @@ if ($action == 'create') {
|
||||
if (!empty($conf->stock->enabled) && !empty($conf->global->WAREHOUSE_ASK_WAREHOUSE_DURING_PROPAL)) {
|
||||
require_once DOL_DOCUMENT_ROOT.'/product/class/html.formproduct.class.php';
|
||||
$formproduct = new FormProduct($db);
|
||||
print '<tr><td>'.$langs->trans('Warehouse').'</td><td>';
|
||||
print '<tr class="field_warehouse_id"><td class="titlefieldcreate">'.$langs->trans('Warehouse').'</td><td class="valuefieldcreate">';
|
||||
print img_picto('', 'stock', 'class="pictofixedwidth"').$formproduct->selectWarehouses($warehouse_id, 'warehouse_id', '', 1, 0, 0, '', 0, 0, array(), 'maxwidth500 widthcentpercentminusxx');
|
||||
print '</td></tr>';
|
||||
}
|
||||
|
||||
// Delivery date (or manufacturing)
|
||||
print '<tr><td>'.$langs->trans("DeliveryDate").'</td>';
|
||||
print '<td>';
|
||||
print '<tr class="field_date_livraison"><td class="titlefieldcreate">'.$langs->trans("DeliveryDate").'</td>';
|
||||
print '<td class="valuefieldcreate">';
|
||||
if (isset($conf->global->DATE_LIVRAISON_WEEK_DELAY) && is_numeric($conf->global->DATE_LIVRAISON_WEEK_DELAY)) {
|
||||
$tmpdte = time() + ((7 * $conf->global->DATE_LIVRAISON_WEEK_DELAY) * 24 * 60 * 60);
|
||||
$syear = date("Y", $tmpdte);
|
||||
@ -1720,8 +1727,8 @@ if ($action == 'create') {
|
||||
// Project
|
||||
if (!empty($conf->projet->enabled)) {
|
||||
$langs->load("projects");
|
||||
print '<tr>';
|
||||
print '<td>'.$langs->trans("Project").'</td><td>';
|
||||
print '<tr class="field_projectid">';
|
||||
print '<td class="titlefieldcreate">'.$langs->trans("Project").'</td><td class="valuefieldcreate">';
|
||||
print img_picto('', 'project', 'class="pictofixedwidth"').$formproject->select_projects(($soc->id > 0 ? $soc->id : -1), $projectid, 'projectid', 0, 0, 1, 1, 0, 0, 0, '', 1, 0, 'maxwidth500 widthcentpercentminusxx');
|
||||
print ' <a href="'.DOL_URL_ROOT.'/projet/card.php?socid='.$soc->id.'&action=create&status=1&backtopage='.urlencode($_SERVER["PHP_SELF"].'?action=create&socid='.$soc->id).'"><span class="fa fa-plus-circle valignmiddle paddingleft" title="'.$langs->trans("AddProject").'"></span></a>';
|
||||
print '</td>';
|
||||
@ -1730,17 +1737,17 @@ if ($action == 'create') {
|
||||
|
||||
// Incoterms
|
||||
if (!empty($conf->incoterm->enabled)) {
|
||||
print '<tr>';
|
||||
print '<td><label for="incoterm_id">'.$form->textwithpicto($langs->trans("IncotermLabel"), $soc->label_incoterms, 1).'</label></td>';
|
||||
print '<td class="maxwidthonsmartphone">';
|
||||
print '<tr class="field_incoterm_id">';
|
||||
print '<td class="titlefieldcreate"><label for="incoterm_id">'.$form->textwithpicto($langs->trans("IncotermLabel"), $soc->label_incoterms, 1).'</label></td>';
|
||||
print '<td class="valuefieldcreate maxwidthonsmartphone">';
|
||||
print $form->select_incoterms((!empty($soc->fk_incoterms) ? $soc->fk_incoterms : ''), (!empty($soc->location_incoterms) ? $soc->location_incoterms : ''));
|
||||
print '</td></tr>';
|
||||
}
|
||||
|
||||
// Template to use by default
|
||||
print '<tr>';
|
||||
print '<td>'.$langs->trans("DefaultModel").'</td>';
|
||||
print '<td>';
|
||||
print '<tr class="field_model">';
|
||||
print '<td class="titlefieldcreate">'.$langs->trans("DefaultModel").'</td>';
|
||||
print '<td class="valuefieldcreate">';
|
||||
print img_picto('', 'pdf', 'class="pictofixedwidth"');
|
||||
$liste = ModelePDFPropales::liste_modeles($db);
|
||||
$preselected = (!empty($conf->global->PROPALE_ADDON_PDF_ODT_DEFAULT) ? $conf->global->PROPALE_ADDON_PDF_ODT_DEFAULT : getDolGlobalString("PROPALE_ADDON_PDF"));
|
||||
@ -1749,26 +1756,26 @@ if ($action == 'create') {
|
||||
|
||||
// Multicurrency
|
||||
if (!empty($conf->multicurrency->enabled)) {
|
||||
print '<tr>';
|
||||
print '<td>'.$form->editfieldkey('Currency', 'multicurrency_code', '', $object, 0).'</td>';
|
||||
print '<td class="maxwidthonsmartphone">';
|
||||
print '<tr class="field_currency">';
|
||||
print '<td class="titlefieldcreate">'.$form->editfieldkey('Currency', 'multicurrency_code', '', $object, 0).'</td>';
|
||||
print '<td class="valuefieldcreate maxwidthonsmartphone">';
|
||||
print img_picto('', 'currency', 'class="pictofixedwidth"').$form->selectMultiCurrency($currency_code, 'multicurrency_code', 0);
|
||||
print '</td></tr>';
|
||||
}
|
||||
|
||||
// Public note
|
||||
print '<tr>';
|
||||
print '<td class="tdtop">'.$langs->trans('NotePublic').'</td>';
|
||||
print '<td valign="top">';
|
||||
print '<tr class="field_note_public">';
|
||||
print '<td class="titlefieldcreate tdtop">'.$langs->trans('NotePublic').'</td>';
|
||||
print '<td class="valuefieldcreate">';
|
||||
$note_public = $object->getDefaultCreateValueFor('note_public', (!empty($objectsrc) ? $objectsrc->note_public : null));
|
||||
$doleditor = new DolEditor('note_public', $note_public, '', 80, 'dolibarr_notes', 'In', 0, false, empty($conf->global->FCKEDITOR_ENABLE_NOTE_PUBLIC) ? 0 : 1, ROWS_3, '90%');
|
||||
print $doleditor->Create(1);
|
||||
|
||||
// Private note
|
||||
if (empty($user->socid)) {
|
||||
print '<tr>';
|
||||
print '<td class="tdtop">'.$langs->trans('NotePrivate').'</td>';
|
||||
print '<td valign="top">';
|
||||
print '<tr class="field_note_private">';
|
||||
print '<td class="titlefieldcreate tdtop">'.$langs->trans('NotePrivate').'</td>';
|
||||
print '<td class="valuefieldcreate">';
|
||||
$note_private = $object->getDefaultCreateValueFor('note_private', ((!empty($origin) && !empty($originid) && is_object($objectsrc)) ? $objectsrc->note_private : null));
|
||||
$doleditor = new DolEditor('note_private', $note_private, '', 80, 'dolibarr_notes', 'In', 0, false, empty($conf->global->FCKEDITOR_ENABLE_NOTE_PRIVATE) ? 0 : 1, ROWS_3, '90%');
|
||||
print $doleditor->Create(1);
|
||||
@ -2172,9 +2179,9 @@ if ($action == 'create') {
|
||||
print '</tr>';
|
||||
|
||||
// Payment mode
|
||||
print '<tr>';
|
||||
print '<td class="valuefield">';
|
||||
print '<table class="nobordernopadding" width="100%"><tr><td>';
|
||||
print '<tr class="field_mode_reglement_id">';
|
||||
print '<td class="titlefieldcreate">';
|
||||
print '<table class="nobordernopadding centpercent"><tr><td>';
|
||||
print $langs->trans('PaymentMode');
|
||||
print '</td>';
|
||||
if ($action != 'editmode' && $usercancreate && $caneditfield) {
|
||||
@ -2193,7 +2200,7 @@ if ($action == 'create') {
|
||||
$langs->load('deliveries');
|
||||
print '<tr><td>';
|
||||
print $form->editfieldkey($langs->trans('DeliveryDate'), 'date_livraison', $object->delivery_date, $object, $usercancreate && $caneditfield, 'datepicker');
|
||||
print '</td><td class="valuefield">';
|
||||
print '</td><td class="valuefieldedit">';
|
||||
print $form->editfieldval($langs->trans('DeliveryDate'), 'date_livraison', $object->delivery_date, $object, $usercancreate && $caneditfield, 'datepicker');
|
||||
print '</td>';
|
||||
print '</tr>';
|
||||
@ -2224,7 +2231,7 @@ if ($action == 'create') {
|
||||
// Shipping Method
|
||||
if (!empty($conf->expedition->enabled)) {
|
||||
print '<tr><td>';
|
||||
print '<table width="100%" class="nobordernopadding"><tr><td>';
|
||||
print '<table class="nobordernopadding centpercent"><tr><td>';
|
||||
print $langs->trans('SendingMethod');
|
||||
print '</td>';
|
||||
if ($action != 'editshippingmethod' && $usercancreate && $caneditfield) {
|
||||
@ -2246,7 +2253,7 @@ if ($action == 'create') {
|
||||
$langs->load('stocks');
|
||||
require_once DOL_DOCUMENT_ROOT.'/product/class/html.formproduct.class.php';
|
||||
$formproduct = new FormProduct($db);
|
||||
print '<tr><td>';
|
||||
print '<tr class="field_warehouse_id"><td class="titlefieldcreate">';
|
||||
$editenable = $usercancreate;
|
||||
print $form->editfieldkey("Warehouse", 'warehouse', '', $object, $editenable);
|
||||
print '</td><td class="valuefieldcreate">';
|
||||
@ -2261,7 +2268,7 @@ if ($action == 'create') {
|
||||
|
||||
// Origin of demand
|
||||
print '<tr><td>';
|
||||
print '<table class="nobordernopadding" width="100%"><tr><td>';
|
||||
print '<table class="nobordernopadding centpercent"><tr><td>';
|
||||
print $langs->trans('Source');
|
||||
print '</td>';
|
||||
if ($action != 'editdemandreason' && $usercancreate) {
|
||||
|
||||
@ -1043,7 +1043,7 @@ if ($resql) {
|
||||
$moreforfilter = '';
|
||||
|
||||
// If the user can view prospects other than his'
|
||||
if ($user->rights->societe->client->voir || $socid) {
|
||||
if ($user->rights->user->user->lire) {
|
||||
$langs->load("commercial");
|
||||
$moreforfilter .= '<div class="divsearchfield">';
|
||||
$tmptitle = $langs->trans('ThirdPartiesOfSaleRepresentative');
|
||||
@ -1051,9 +1051,9 @@ if ($resql) {
|
||||
$moreforfilter .= '</div>';
|
||||
}
|
||||
// If the user can view prospects other than his'
|
||||
if ($user->rights->societe->client->voir || $socid) {
|
||||
if ($user->rights->user->user->lire) {
|
||||
$moreforfilter .= '<div class="divsearchfield">';
|
||||
$tmptitle = $langs->trans('LinkedToSpecificUsers');
|
||||
$tmptitle = $langs->trans('LinkedToSpecificUsers');
|
||||
$moreforfilter .= img_picto($tmptitle, 'user', 'class="pictofixedwidth"').$form->select_dolusers($search_user, 'search_user', $tmptitle, '', 0, '', '', 0, 0, 0, '', 0, '', 'maxwidth250 widthcentpercentminusx');
|
||||
$moreforfilter .= '</div>';
|
||||
}
|
||||
@ -2097,7 +2097,7 @@ if ($resql) {
|
||||
// Note public
|
||||
if (!empty($arrayfields['p.note_public']['checked'])) {
|
||||
print '<td class="center">';
|
||||
print dol_escape_htmltag($obj->note_public);
|
||||
print dol_string_nohtmltag($obj->note_public);
|
||||
print '</td>';
|
||||
if (!$i) {
|
||||
$totalarray['nbfield']++;
|
||||
@ -2106,7 +2106,7 @@ if ($resql) {
|
||||
// Note private
|
||||
if (!empty($arrayfields['p.note_private']['checked'])) {
|
||||
print '<td class="center">';
|
||||
print dol_escape_htmltag($obj->note_private);
|
||||
print dol_string_nohtmltag($obj->note_private);
|
||||
print '</td>';
|
||||
if (!$i) {
|
||||
$totalarray['nbfield']++;
|
||||
|
||||
@ -628,6 +628,13 @@ if (empty($reshook)) {
|
||||
foreach ($object->lines as $line) {
|
||||
$result = $object->updateline($line->id, $line->desc, $line->subprice, $line->qty, $line->remise_percent, $vat_rate, $localtax1_rate, $localtax2_rate, 'HT', $line->info_bits, $line->date_start, $line->date_end, $line->product_type, $line->fk_parent_line, 0, $line->fk_fournprice, $line->pa_ht, $line->label, $line->special_code, $line->array_options, $line->fk_unit, $line->multicurrency_subprice);
|
||||
}
|
||||
} elseif ($action == 'addline' && GETPOST('submitforalllines', 'alpha') && GETPOST('remiseforalllines', 'alpha') !== '' && $usercancreate) {
|
||||
// Define remise_percent
|
||||
$remise_percent = (GETPOST('remiseforalllines') ? GETPOST('remiseforalllines') : 0);
|
||||
$remise_percent = str_replace('*', '', $remise_percent);
|
||||
foreach ($object->lines as $line) {
|
||||
$result = $object->updateline($line->id, $line->desc, $line->subprice, $line->qty, $remise_percent, $line->tva_tx, $line->localtax1_tx, $line->localtax2_tx, 'HT', $line->info_bits, $line->date_start, $line->date_end, $line->product_type, $line->fk_parent_line, 0, $line->fk_fournprice, $line->pa_ht, $line->label, $line->special_code, $line->array_options, $line->fk_unit, $line->multicurrency_subprice);
|
||||
}
|
||||
} elseif ($action == 'addline' && $usercancreate) { // Add a new line
|
||||
$langs->load('errors');
|
||||
$error = 0;
|
||||
|
||||
@ -1321,7 +1321,7 @@ if ($resql) {
|
||||
$moreforfilter = '';
|
||||
|
||||
// If the user can view prospects other than his'
|
||||
if ($user->rights->societe->client->voir || $socid) {
|
||||
if ($user->rights->user->user->lire) {
|
||||
$langs->load("commercial");
|
||||
$moreforfilter .= '<div class="divsearchfield">';
|
||||
$tmptitle = $langs->trans('ThirdPartiesOfSaleRepresentative');
|
||||
|
||||
@ -641,7 +641,7 @@ if (empty($reshook)) {
|
||||
setEventMessages($mesg, null, 'errors');
|
||||
} else {
|
||||
// Insert line
|
||||
$result = $object->addline($desc, $pu_ht, $qty, $tva_tx, $localtax1_tx, $localtax2_tx, $idprod, $remise_percent, $price_base_type, $info_bits, '', $pu_ttc, $type, - 1, $special_code, $label, $fk_unit, 0, $date_start_fill, $date_end_fill, $fournprice, $buyingprice);
|
||||
$result = $object->addline($desc, $pu_ht, $qty, $tva_tx, $localtax1_tx, $localtax2_tx, $idprod, $remise_percent, $price_base_type, $info_bits, '', $pu_ttc, $type, -1, $special_code, $label, $fk_unit, 0, $date_start_fill, $date_end_fill, $fournprice, $buyingprice);
|
||||
|
||||
if ($result > 0) {
|
||||
// Define output language and generate document
|
||||
@ -1034,21 +1034,11 @@ if ($action == 'create') {
|
||||
|
||||
// Payment mode
|
||||
print "<tr><td>".$langs->trans("PaymentMode")."</td><td>";
|
||||
print img_picto('', 'payment', 'class="pictofixedwidth"');
|
||||
print $form->select_types_paiements(GETPOSTISSET('mode_reglement_id') ? GETPOST('mode_reglement_id', 'int') : $object->mode_reglement_id, 'mode_reglement_id', '', 0, 1, 0, 0, 1, '', 1);
|
||||
//$form->form_modes_reglement($_SERVER['PHP_SELF'].'?id='.$object->id, $object->mode_reglement_id, 'mode_reglement_id', '', 1);
|
||||
print "</td></tr>";
|
||||
|
||||
// Project
|
||||
if (!empty($conf->projet->enabled) && is_object($object->thirdparty) && $object->thirdparty->id > 0) {
|
||||
$projectid = GETPOST('projectid') ?GETPOST('projectid') : $object->fk_project;
|
||||
$langs->load('projects');
|
||||
print '<tr><td>'.$langs->trans('Project').'</td><td>';
|
||||
print img_picto('', 'project');
|
||||
$numprojet = $formproject->select_projects($object->thirdparty->id, $projectid, 'projectid', 0, 0, 1, 0, 0, 0, 0, '', 0, 0, '');
|
||||
print ' <a href="'.DOL_URL_ROOT.'/projet/card.php?socid='.$object->thirdparty->id.'&action=create&status=1&backtopage='.urlencode($_SERVER["PHP_SELF"].'?action=create&socid='.$object->thirdparty->id.(!empty($id) ? '&id='.$id : '')).'">'.img_object($langs->trans("AddProject"), 'add').'</a>';
|
||||
print '</td></tr>';
|
||||
}
|
||||
|
||||
// Bank account
|
||||
if ($object->fk_account > 0) {
|
||||
print "<tr><td>".$langs->trans('BankAccount')."</td><td>";
|
||||
@ -1056,10 +1046,22 @@ if ($action == 'create') {
|
||||
print "</td></tr>";
|
||||
}
|
||||
|
||||
// Project
|
||||
if (!empty($conf->projet->enabled) && is_object($object->thirdparty) && $object->thirdparty->id > 0) {
|
||||
$projectid = GETPOST('projectid') ?GETPOST('projectid') : $object->fk_project;
|
||||
$langs->load('projects');
|
||||
print '<tr><td>'.$langs->trans('Project').'</td><td>';
|
||||
print img_picto('', 'project', 'class="pictofixedwidth"');
|
||||
$numprojet = $formproject->select_projects($object->thirdparty->id, $projectid, 'projectid', 0, 0, 1, 0, 0, 0, 0, '', 0, 0, '');
|
||||
print ' <a href="'.DOL_URL_ROOT.'/projet/card.php?socid='.$object->thirdparty->id.'&action=create&status=1&backtopage='.urlencode($_SERVER["PHP_SELF"].'?action=create&socid='.$object->thirdparty->id.(!empty($id) ? '&id='.$id : '')).'">'.img_object($langs->trans("AddProject"), 'add').'</a>';
|
||||
print '</td></tr>';
|
||||
}
|
||||
|
||||
// Model pdf
|
||||
print "<tr><td>".$langs->trans('Model')."</td><td>";
|
||||
include_once DOL_DOCUMENT_ROOT.'/core/modules/facture/modules_facture.php';
|
||||
$list = ModelePDFFactures::liste_modeles($db);
|
||||
print img_picto('', 'generic', 'class="pictofixedwidth"');
|
||||
print $form->selectarray('modelpdf', $list, $conf->global->FACTURE_ADDON_PDF);
|
||||
print "</td></tr>";
|
||||
|
||||
@ -1605,19 +1607,19 @@ if ($action == 'create') {
|
||||
|
||||
|
||||
// Lines
|
||||
print ' <form name="addproduct" id="addproduct" action="'.$_SERVER["PHP_SELF"].'?id='.$object->id.(($action != 'editline') ? '#add' : '#line_'.GETPOST('lineid', 'int')).'" method="POST">
|
||||
<input type="hidden" name="token" value="' . newToken().'">
|
||||
<input type="hidden" name="action" value="' . (($action != 'editline') ? 'addline' : 'updateline').'">
|
||||
<input type="hidden" name="mode" value="">
|
||||
<input type="hidden" name="id" value="' . $object->id.'">
|
||||
';
|
||||
print '<form name="addproduct" id="addproduct" action="'.$_SERVER["PHP_SELF"].'?id='.$object->id.(($action != 'editline') ? '#add' : '#line_'.GETPOST('lineid', 'int')).'" method="POST">';
|
||||
print '<input type="hidden" name="token" value="' . newToken().'">';
|
||||
print '<input type="hidden" name="action" value="' . (($action != 'editline') ? 'addline' : 'updateline').'">';
|
||||
print '<input type="hidden" name="mode" value="">';
|
||||
print '<input type="hidden" name="id" value="' . $object->id.'">';
|
||||
print '<input type="hidden" name="page_y" value="">';
|
||||
|
||||
if (!empty($conf->use_javascript_ajax) && $object->statut == 0) {
|
||||
include DOL_DOCUMENT_ROOT.'/core/tpl/ajaxrow.tpl.php';
|
||||
}
|
||||
|
||||
print '<div class="div-table-responsive-no-min">';
|
||||
print '<table id="tablelines" class="noborder noshadow" width="100%">';
|
||||
print '<table id="tablelines" class="noborder noshadow centpercent">';
|
||||
// Show object lines
|
||||
if (!empty($object->lines)) {
|
||||
$canchangeproduct = 1;
|
||||
|
||||
@ -987,6 +987,10 @@ if (empty($reshook)) {
|
||||
}
|
||||
$selectedLines = GETPOST('toselect', 'array');
|
||||
|
||||
if (GETPOST('type', 'int') === '') {
|
||||
setEventMessages($langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv("Type")), null, 'errors');
|
||||
}
|
||||
|
||||
$db->begin();
|
||||
|
||||
$error = 0;
|
||||
@ -1571,8 +1575,15 @@ if (empty($reshook)) {
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0
|
||||
//,$langs->trans('Deposit') //Deprecated
|
||||
0,
|
||||
'',
|
||||
0,
|
||||
100,
|
||||
0,
|
||||
null,
|
||||
0,
|
||||
'',
|
||||
1
|
||||
);
|
||||
}
|
||||
|
||||
@ -1739,7 +1750,10 @@ if (empty($reshook)) {
|
||||
$array_options,
|
||||
$lines[$i]->situation_percent,
|
||||
$lines[$i]->fk_prev_id,
|
||||
$lines[$i]->fk_unit
|
||||
$lines[$i]->fk_unit,
|
||||
0,
|
||||
'',
|
||||
1
|
||||
);
|
||||
|
||||
if ($result > 0) {
|
||||
@ -1762,6 +1776,8 @@ if (empty($reshook)) {
|
||||
}
|
||||
}
|
||||
|
||||
$object->update_price(1, 'auto', 0, $mysoc);
|
||||
|
||||
// Now we create same links to contact than the ones found on origin object
|
||||
/* Useless, already into the create
|
||||
if (! empty($conf->global->MAIN_PROPAGATE_CONTACTS_FROM_ORIGIN))
|
||||
@ -1809,9 +1825,11 @@ if (empty($reshook)) {
|
||||
$product->fetch(GETPOST('idprod'.$i, 'int'));
|
||||
$startday = dol_mktime(12, 0, 0, GETPOST('date_start'.$i.'month'), GETPOST('date_start'.$i.'day'), GETPOST('date_start'.$i.'year'));
|
||||
$endday = dol_mktime(12, 0, 0, GETPOST('date_end'.$i.'month'), GETPOST('date_end'.$i.'day'), GETPOST('date_end'.$i.'year'));
|
||||
$result = $object->addline($product->description, $product->price, price2num(GETPOST('qty'.$i), 'MS'), $product->tva_tx, $product->localtax1_tx, $product->localtax2_tx, GETPOST('idprod'.$i, 'int'), price2num(GETPOST('remise_percent'.$i), '', 2), $startday, $endday, 0, 0, '', $product->price_base_type, $product->price_ttc, $product->type, -1, 0, '', 0, 0, null, 0, '', 0, 100, '', $product->fk_unit);
|
||||
$result = $object->addline($product->description, $product->price, price2num(GETPOST('qty'.$i), 'MS'), $product->tva_tx, $product->localtax1_tx, $product->localtax2_tx, GETPOST('idprod'.$i, 'int'), price2num(GETPOST('remise_percent'.$i), '', 2), $startday, $endday, 0, 0, '', $product->price_base_type, $product->price_ttc, $product->type, -1, 0, '', 0, 0, null, 0, '', 0, 100, '', $product->fk_unit, 0, '', 1);
|
||||
}
|
||||
}
|
||||
|
||||
$object->update_price(1, 'auto', 0, $mysoc);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -1976,6 +1994,13 @@ if (empty($reshook)) {
|
||||
foreach ($object->lines as $line) {
|
||||
$result = $object->updateline($line->id, $line->desc, $line->subprice, $line->qty, $line->remise_percent, $line->date_start, $line->date_end, $vat_rate, $localtax1_rate, $localtax2_rate, 'HT', $line->info_bits, $line->product_type, $line->fk_parent_line, 0, $line->fk_fournprice, $line->pa_ht, $line->label, $line->special_code, $line->array_options, $line->situation_percent, $line->fk_unit, $line->multicurrency_subprice);
|
||||
}
|
||||
} elseif ($action == 'addline' && GETPOST('submitforalllines', 'alpha') && GETPOST('remiseforalllines', 'alpha') !== '' && $usercancreate) {
|
||||
// Define vat_rate
|
||||
$remise_percent = (GETPOST('remiseforalllines') ? GETPOST('remiseforalllines') : 0);
|
||||
$remise_percent = str_replace('*', '', $remise_percent);
|
||||
foreach ($object->lines as $line) {
|
||||
$result = $object->updateline($line->id, $line->desc, $line->subprice, $line->qty, $remise_percent, $line->date_start, $line->date_end, $line->tva_tx, $line->localtax1_tx, $line->localtax2_tx, 'HT', $line->info_bits, $line->product_type, $line->fk_parent_line, 0, $line->fk_fournprice, $line->pa_ht, $line->label, $line->special_code, $line->array_options, $line->situation_percent, $line->fk_unit, $line->multicurrency_subprice);
|
||||
}
|
||||
} elseif ($action == 'addline' && $usercancreate) { // Add a new line
|
||||
$langs->load('errors');
|
||||
$error = 0;
|
||||
@ -3162,6 +3187,9 @@ if ($action == 'create') {
|
||||
$i++;
|
||||
}
|
||||
print '</select>';
|
||||
|
||||
print ajax_combobox("fac_rec");
|
||||
|
||||
// Option to reload page to retrieve customer informations. Note, this clear other input
|
||||
if (empty($conf->global->RELOAD_PAGE_ON_TEMPLATE_CHANGE_DISABLED)) {
|
||||
print '<script type="text/javascript">
|
||||
@ -3189,7 +3217,7 @@ if ($action == 'create') {
|
||||
|
||||
// Standard invoice
|
||||
print '<div class="tagtr listofinvoicetype"><div class="tagtd listofinvoicetype">';
|
||||
$tmp = '<input type="radio" id="radio_standard" name="type" value="0"'.(GETPOST('type') == 0 ? ' checked' : '').'> ';
|
||||
$tmp = '<input type="radio" id="radio_standard" name="type" value="0"'.(GETPOST('type', 'int') ? '' : ' checked').'> ';
|
||||
$tmp = $tmp.'<label for="radio_standard" >'.$langs->trans("InvoiceStandardAsk").'</label>';
|
||||
$desc = $form->textwithpicto($tmp, $langs->transnoentities("InvoiceStandardDesc"), 1, 'help', '', 0, 3);
|
||||
print '<table class="nobordernopadding"><tr>';
|
||||
@ -3383,7 +3411,6 @@ if ($action == 'create') {
|
||||
print '</div></div>';
|
||||
}
|
||||
|
||||
|
||||
if (empty($origin)) {
|
||||
if ($socid > 0) {
|
||||
// Credit note
|
||||
@ -3520,7 +3547,6 @@ if ($action == 'create') {
|
||||
}
|
||||
|
||||
|
||||
|
||||
print '</td></tr>';
|
||||
|
||||
if ($socid > 0) {
|
||||
@ -3608,8 +3634,8 @@ if ($action == 'create') {
|
||||
|
||||
// Payment mode
|
||||
print '<tr><td>'.$langs->trans('PaymentMode').'</td><td colspan="2">';
|
||||
print img_picto('', 'bank', 'class="pictofixedwidth"');
|
||||
$form->select_types_paiements(GETPOSTISSET('mode_reglement_id') ? GETPOST('mode_reglement_id') : $mode_reglement_id, 'mode_reglement_id', 'CRDT', 0, 1, 0, 0, 1, 'maxwidth200 widthcentpercentminusx');
|
||||
print img_picto('', 'payment', 'class="pictofixedwidth"');
|
||||
print $form->select_types_paiements(GETPOSTISSET('mode_reglement_id') ? GETPOST('mode_reglement_id') : $mode_reglement_id, 'mode_reglement_id', 'CRDT', 0, 1, 0, 0, 1, 'maxwidth200 widthcentpercentminusx', 1);
|
||||
print '</td></tr>';
|
||||
|
||||
// Bank Account
|
||||
@ -3682,6 +3708,7 @@ if ($action == 'create') {
|
||||
print '<tr>';
|
||||
print '<td>'.$form->editfieldkey('Currency', 'multicurrency_code', '', $object, 0).'</td>';
|
||||
print '<td colspan="2" class="maxwidthonsmartphone">';
|
||||
print img_picto('', 'currency', 'class="pictofixedwidth"');
|
||||
print $form->selectMultiCurrency($currency_code, 'multicurrency_code');
|
||||
print '</td></tr>';
|
||||
}
|
||||
|
||||
@ -945,6 +945,13 @@ class FactureRec extends CommonInvoice
|
||||
$product_type = $product->type;
|
||||
}
|
||||
|
||||
// Rank to use
|
||||
$ranktouse = $rang;
|
||||
if ($ranktouse == -1) {
|
||||
$rangmax = $this->line_max(0);
|
||||
$ranktouse = $rangmax + 1;
|
||||
}
|
||||
|
||||
$sql = "INSERT INTO ".MAIN_DB_PREFIX."facturedet_rec (";
|
||||
$sql .= "fk_facture";
|
||||
$sql .= ", label";
|
||||
@ -1003,7 +1010,7 @@ class FactureRec extends CommonInvoice
|
||||
$sql .= ", ".($fk_fournprice > 0 ? $fk_fournprice : 'null');
|
||||
$sql .= ", ".($pa_ht ? price2num($pa_ht) : 0);
|
||||
$sql .= ", ".((int) $info_bits);
|
||||
$sql .= ", ".((int) $rang);
|
||||
$sql .= ", ".((int) $ranktouse);
|
||||
$sql .= ", ".((int) $special_code);
|
||||
$sql .= ", ".($fk_unit ? ((int) $fk_unit) : "null");
|
||||
$sql .= ", ".(int) $this->fk_multicurrency;
|
||||
|
||||
@ -519,8 +519,11 @@ class Facture extends CommonInvoice
|
||||
|
||||
// Define some dates
|
||||
$originaldatewhen = $_facrec->date_when;
|
||||
$nextdatewhen = dol_time_plus_duree($originaldatewhen, $_facrec->frequency, $_facrec->unit_frequency);
|
||||
$previousdaynextdatewhen = dol_time_plus_duree($nextdatewhen, -1, 'd');
|
||||
$nextdatewhen = null; $previousdaynextdatewhen = null;
|
||||
if ($originaldatewhen) {
|
||||
$nextdatewhen = dol_time_plus_duree($originaldatewhen, $_facrec->frequency, $_facrec->unit_frequency);
|
||||
$previousdaynextdatewhen = dol_time_plus_duree($nextdatewhen, -1, 'd');
|
||||
}
|
||||
|
||||
if (!empty($_facrec->frequency)) { // Invoice are created on same thirdparty than template when there is a recurrence, but not necessarly when there is no recurrence.
|
||||
$this->socid = $_facrec->socid;
|
||||
@ -610,9 +613,9 @@ class Facture extends CommonInvoice
|
||||
$substitutionarray['__INVOICE_YEAR__'] = dol_print_date($this->date, '%Y');
|
||||
$substitutionarray['__INVOICE_NEXT_YEAR__'] = dol_print_date(dol_time_plus_duree($this->date, 1, 'y'), '%Y');
|
||||
// Only for template invoice
|
||||
$substitutionarray['__INVOICE_DATE_NEXT_INVOICE_BEFORE_GEN__'] = dol_print_date($originaldatewhen, 'dayhour');
|
||||
$substitutionarray['__INVOICE_DATE_NEXT_INVOICE_AFTER_GEN__'] = dol_print_date($nextdatewhen, 'dayhour');
|
||||
$substitutionarray['__INVOICE_PREVIOUS_DATE_NEXT_INVOICE_AFTER_GEN__'] = dol_print_date($previousdaynextdatewhen, 'dayhour');
|
||||
$substitutionarray['__INVOICE_DATE_NEXT_INVOICE_BEFORE_GEN__'] = (isset($originaldatewhen) ? dol_print_date($originaldatewhen, 'dayhour') : '');
|
||||
$substitutionarray['__INVOICE_DATE_NEXT_INVOICE_AFTER_GEN__'] = (isset($nextdatewhen) ? dol_print_date($nextdatewhen, 'dayhour') : '');
|
||||
$substitutionarray['__INVOICE_PREVIOUS_DATE_NEXT_INVOICE_AFTER_GEN__'] = (isset($previousdaynextdatewhen) ? dol_print_date($previousdaynextdatewhen, 'dayhour') : '');
|
||||
$substitutionarray['__INVOICE_COUNTER_CURRENT__'] = $_facrec->nb_gen_done;
|
||||
$substitutionarray['__INVOICE_COUNTER_MAX__'] = $_facrec->nb_gen_max;
|
||||
|
||||
@ -854,7 +857,9 @@ class Facture extends CommonInvoice
|
||||
$newinvoiceline->situation_percent,
|
||||
$newinvoiceline->fk_prev_id,
|
||||
$newinvoiceline->fk_unit,
|
||||
$newinvoiceline->multicurrency_subprice
|
||||
$newinvoiceline->multicurrency_subprice,
|
||||
$newinvoiceline->ref_ext,
|
||||
1
|
||||
);
|
||||
|
||||
// Defined the new fk_parent_line
|
||||
@ -938,7 +943,8 @@ class Facture extends CommonInvoice
|
||||
$line->fk_prev_id,
|
||||
$line->fk_unit,
|
||||
$line->multicurrency_subprice,
|
||||
$line->ref_ext
|
||||
$line->ref_ext,
|
||||
1
|
||||
);
|
||||
if ($result < 0) {
|
||||
$this->error = $this->db->lasterror();
|
||||
@ -1035,7 +1041,9 @@ class Facture extends CommonInvoice
|
||||
$_facrec->lines[$i]->situation_percent,
|
||||
'',
|
||||
$_facrec->lines[$i]->fk_unit,
|
||||
$_facrec->lines[$i]->multicurrency_subprice
|
||||
$_facrec->lines[$i]->multicurrency_subprice,
|
||||
$_facrec->lines[$i]->ref_ext,
|
||||
1
|
||||
);
|
||||
|
||||
if ($result_insert < 0) {
|
||||
@ -1047,7 +1055,7 @@ class Facture extends CommonInvoice
|
||||
}
|
||||
|
||||
if (!$error) {
|
||||
$result = $this->update_price(1);
|
||||
$result = $this->update_price(1, 'auto', 0, $mysoc);
|
||||
if ($result > 0) {
|
||||
$action = 'create';
|
||||
|
||||
@ -3237,7 +3245,7 @@ class Facture extends CommonInvoice
|
||||
* @param string $price_base_type 'HT' or 'TTC'
|
||||
* @param double $pu_ttc Unit price with tax (> 0 even for credit note)
|
||||
* @param int $type Type of line (0=product, 1=service). Not used if fk_product is defined, the type of product is used.
|
||||
* @param int $rang Position of line
|
||||
* @param int $rang Position of line (-1 means last value + 1)
|
||||
* @param int $special_code Special code (also used by externals modules!)
|
||||
* @param string $origin Depend on global conf MAIN_CREATEFROM_KEEP_LINE_ORIGIN_INFORMATION can be 'orderdet', 'propaldet'..., else 'order','propal,'....
|
||||
* @param int $origin_id Depend on global conf MAIN_CREATEFROM_KEEP_LINE_ORIGIN_INFORMATION can be Id of origin object (aka line id), else object id
|
||||
@ -3251,6 +3259,7 @@ class Facture extends CommonInvoice
|
||||
* @param string $fk_unit Code of the unit to use. Null to use the default one
|
||||
* @param double $pu_ht_devise Unit price in foreign currency
|
||||
* @param string $ref_ext External reference of the line
|
||||
* @param int $noupdateafterinsertline No update after insert of line
|
||||
* @return int <0 if KO, Id of line if OK
|
||||
*/
|
||||
public function addline(
|
||||
@ -3283,7 +3292,8 @@ class Facture extends CommonInvoice
|
||||
$fk_prev_id = 0,
|
||||
$fk_unit = null,
|
||||
$pu_ht_devise = 0,
|
||||
$ref_ext = ''
|
||||
$ref_ext = '',
|
||||
$noupdateafterinsertline = 0
|
||||
) {
|
||||
// Deprecation warning
|
||||
if ($label) {
|
||||
@ -3492,7 +3502,9 @@ class Facture extends CommonInvoice
|
||||
}
|
||||
|
||||
// Mise a jour informations denormalisees au niveau de la facture meme
|
||||
$result = $this->update_price(1, 'auto', 0, $mysoc); // The addline method is designed to add line from user input so total calculation with update_price must be done using 'auto' mode.
|
||||
if (empty($noupdateafterinsertline)) {
|
||||
$result = $this->update_price(1, 'auto', 0, $mysoc); // The addline method is designed to add line from user input so total calculation with update_price must be done using 'auto' mode.
|
||||
}
|
||||
|
||||
if ($result > 0) {
|
||||
$this->db->commit();
|
||||
@ -5209,11 +5221,11 @@ class Facture extends CommonInvoice
|
||||
if (!empty($recipient->email)) {
|
||||
$to = $recipient->email;
|
||||
} else {
|
||||
$errormesg = "Failed to send remind to thirdparty id=".$tmpinvoice->fk_soc.". No email defined for user.";
|
||||
$errormesg = "Failed to send remind to thirdparty id=".$tmpinvoice->socid.". No email defined for user.";
|
||||
$error++;
|
||||
}
|
||||
} else {
|
||||
$errormesg = "Failed to load recipient with thirdparty id=".$tmpinvoice->fk_soc;
|
||||
$errormesg = "Failed to load recipient with thirdparty id=".$tmpinvoice->socid;
|
||||
$error++;
|
||||
}
|
||||
|
||||
|
||||
@ -1185,7 +1185,7 @@ if ($resql) {
|
||||
|
||||
// If the user can view prospects other than his'
|
||||
$moreforfilter = '';
|
||||
if ($user->rights->societe->client->voir || $socid) {
|
||||
if ($user->rights->user->user->lire) {
|
||||
$langs->load("commercial");
|
||||
$moreforfilter .= '<div class="divsearchfield">';
|
||||
$tmptitle = $langs->trans('ThirdPartiesOfSaleRepresentative');
|
||||
@ -1193,7 +1193,7 @@ if ($resql) {
|
||||
$moreforfilter .= '</div>';
|
||||
}
|
||||
// If the user can view prospects other than his'
|
||||
if ($user->rights->societe->client->voir || $socid) {
|
||||
if ($user->rights->user->user->lire) {
|
||||
$moreforfilter .= '<div class="divsearchfield">';
|
||||
$tmptitle = $langs->trans('LinkedToSpecificUsers');
|
||||
$moreforfilter .= img_picto($tmptitle, 'user', 'class="pictofixedwidth"').$form->select_dolusers($search_user, 'search_user', $tmptitle, '', 0, '', '', 0, 0, 0, '', 0, '', 'maxwidth250');
|
||||
|
||||
@ -527,9 +527,8 @@ if (!empty($conf->tax->enabled) && !empty($user->rights->tax->charges->lire)) {
|
||||
|
||||
if ($i >= $max) {
|
||||
$othernb += 1;
|
||||
$tot_ttc += $obj->amount;
|
||||
$i++;
|
||||
$total_ht += $obj->total_ht;
|
||||
$total_ttc += $obj->total_ttc;
|
||||
continue;
|
||||
}
|
||||
|
||||
|
||||
@ -550,7 +550,7 @@ if ($sall) {
|
||||
$moreforfilter = '';
|
||||
|
||||
// If the user can view prospects other than his'
|
||||
if ($user->rights->societe->client->voir || $socid) {
|
||||
if ($user->rights->user->user->lire) {
|
||||
$langs->load("commercial");
|
||||
$moreforfilter .= '<div class="divsearchfield">';
|
||||
$tmptitle = $langs->trans('ThirdPartiesOfSaleRepresentative');
|
||||
|
||||
@ -327,29 +327,51 @@ if (!$error && $massaction == 'confirm_presend') {
|
||||
// TODO Set subdir to be compatible with multi levels dir trees
|
||||
// $subdir = get_exdir($objectobj->id, 2, 0, 0, $objectobj, $objectobj->element)
|
||||
$filedir = $uploaddir.'/'.$subdir.dol_sanitizeFileName($objectobj->ref);
|
||||
$file = $filedir.'/'.$filename;
|
||||
$filepath = $filedir.'/'.$filename;
|
||||
|
||||
// For supplier invoices, we use the file provided by supplier, not the one we generate
|
||||
if ($objectobj->element == 'invoice_supplier') {
|
||||
$fileparams = dol_most_recent_file($uploaddir.'/'.get_exdir($objectobj->id, 2, 0, 0, $objectobj, $objectobj->element).$objectobj->ref, preg_quote($objectobj->ref, '/').'([^\-])+');
|
||||
$file = $fileparams['fullname'];
|
||||
$filepath = $fileparams['fullname'];
|
||||
}
|
||||
|
||||
$mime = dol_mimetype($file);
|
||||
// try to find other files generated for this object (last_main_doc)
|
||||
$filename_found = '';
|
||||
$filepath_found = '';
|
||||
$file_check_list = array();
|
||||
$file_check_list[] = array(
|
||||
'name' => $filename,
|
||||
'path' => $filepath,
|
||||
);
|
||||
if (!empty($conf->global->MAIL_MASS_ACTION_ADD_LAST_IF_MAIN_DOC_NOT_FOUND) && !empty($objectobj->last_main_doc)) {
|
||||
$file_check_list[] = array(
|
||||
'name' => basename($objectobj->last_main_doc),
|
||||
'path' => DOL_DATA_ROOT . '/' . $objectobj->last_main_doc,
|
||||
);
|
||||
}
|
||||
foreach ($file_check_list as $file_check_arr) {
|
||||
if (dol_is_file($file_check_arr['path'])) {
|
||||
$filename_found = $file_check_arr['name'];
|
||||
$filepath_found = $file_check_arr['path'];
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if (dol_is_file($file)) {
|
||||
if ($filepath_found) {
|
||||
// Create form object
|
||||
$attachedfilesThirdpartyObj[$thirdpartyid][$objectid] = array(
|
||||
'paths'=>array($file),
|
||||
'names'=>array($filename),
|
||||
'mimes'=>array($mime)
|
||||
'paths'=>array($filepath_found),
|
||||
'names'=>array($filename_found),
|
||||
'mimes'=>array(dol_mimetype($filepath_found))
|
||||
);
|
||||
} else {
|
||||
$nbignored++;
|
||||
$langs->load("errors");
|
||||
$resaction .= '<div class="error">'.$langs->trans('ErrorCantReadFile', $file).'</div><br>';
|
||||
dol_syslog('Failed to read file: '.$file, LOG_WARNING);
|
||||
continue;
|
||||
$nbignored++;
|
||||
$langs->load("errors");
|
||||
foreach ($file_check_list as $file_check_arr) {
|
||||
$resaction .= '<div class="error">'.$langs->trans('ErrorCantReadFile', $file_check_arr['path']).'</div><br>';
|
||||
dol_syslog('Failed to read file: '.$file_check_arr['path'], LOG_WARNING);
|
||||
}
|
||||
continue;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -3391,9 +3391,9 @@ abstract class CommonObject
|
||||
* Must be called at end of methods addline or updateline.
|
||||
*
|
||||
* @param int $exclspec >0 = Exclude special product (product_type=9)
|
||||
* @param string $roundingadjust 'none'=Do nothing, 'auto'=Use default method (MAIN_ROUNDOFTOTAL_NOT_TOTALOFROUND if defined, or '0'), '0'=Force mode total of rounding, '1'=Force mode rounding of total
|
||||
* @param string $roundingadjust 'none'=Do nothing, 'auto'=Use default method (MAIN_ROUNDOFTOTAL_NOT_TOTALOFROUND if defined, or '0'), '0'=Force mode Total of rounding, '1'=Force mode Rounding of total
|
||||
* @param int $nodatabaseupdate 1=Do not update database. Update only properties of object.
|
||||
* @param Societe $seller If roundingadjust is '0' or '1' or maybe 'auto', it means we recalculate total for lines before calculating total for object and for this, we need seller object.
|
||||
* @param Societe $seller If roundingadjust is '0' or '1' or maybe 'auto', it means we recalculate total for lines before calculating total for object and for this, we need seller object (used to analyze lines to check corrupted data).
|
||||
* @return int <0 if KO, >0 if OK
|
||||
*/
|
||||
public function update_price($exclspec = 0, $roundingadjust = 'none', $nodatabaseupdate = 0, $seller = null)
|
||||
@ -8008,16 +8008,22 @@ abstract class CommonObject
|
||||
|
||||
// Convert date into timestamp format (value in memory must be a timestamp)
|
||||
if (in_array($extrafields->attributes[$this->table_element]['type'][$key], array('date'))) {
|
||||
$datenotinstring = $this->array_options['options_'.$key];
|
||||
if (!is_numeric($this->array_options['options_'.$key])) { // For backward compatibility
|
||||
$datenotinstring = $this->db->jdate($datenotinstring);
|
||||
$datenotinstring = null;
|
||||
if (array_key_exists('options_'.$key, $this->array_options)) {
|
||||
$datenotinstring = $this->array_options['options_'.$key];
|
||||
if (!is_numeric($this->array_options['options_'.$key])) { // For backward compatibility
|
||||
$datenotinstring = $this->db->jdate($datenotinstring);
|
||||
}
|
||||
}
|
||||
$value = (GETPOSTISSET($keyprefix.'options_'.$key.$keysuffix)) ? dol_mktime(12, 0, 0, GETPOST($keyprefix.'options_'.$key.$keysuffix."month", 'int', 3), GETPOST($keyprefix.'options_'.$key.$keysuffix."day", 'int', 3), GETPOST($keyprefix.'options_'.$key.$keysuffix."year", 'int', 3)) : $datenotinstring;
|
||||
}
|
||||
if (in_array($extrafields->attributes[$this->table_element]['type'][$key], array('datetime'))) {
|
||||
$datenotinstring = $this->array_options['options_'.$key];
|
||||
if (!is_numeric($this->array_options['options_'.$key])) { // For backward compatibility
|
||||
$datenotinstring = $this->db->jdate($datenotinstring);
|
||||
$datenotinstring = null;
|
||||
if (array_key_exists('options_'.$key, $this->array_options)) {
|
||||
$datenotinstring = $this->array_options['options_'.$key];
|
||||
if (!is_numeric($this->array_options['options_'.$key])) { // For backward compatibility
|
||||
$datenotinstring = $this->db->jdate($datenotinstring);
|
||||
}
|
||||
}
|
||||
$value = (GETPOSTISSET($keyprefix.'options_'.$key.$keysuffix)) ? dol_mktime(GETPOST($keyprefix.'options_'.$key.$keysuffix."hour", 'int', 3), GETPOST($keyprefix.'options_'.$key.$keysuffix."min", 'int', 3), GETPOST($keyprefix.'options_'.$key.$keysuffix."sec", 'int', 3), GETPOST($keyprefix.'options_'.$key.$keysuffix."month", 'int', 3), GETPOST($keyprefix.'options_'.$key.$keysuffix."day", 'int', 3), GETPOST($keyprefix.'options_'.$key.$keysuffix."year", 'int', 3), 'tzuserrel') : $datenotinstring;
|
||||
}
|
||||
@ -8037,14 +8043,14 @@ abstract class CommonObject
|
||||
$helptoshow = $langs->trans($extrafields->attributes[$this->table_element]['help'][$key]);
|
||||
|
||||
if ($display_type == 'card') {
|
||||
$out .= '<tr '.($html_id ? 'id="'.$html_id.'" ' : '').$csstyle.' class="valuefieldcreate '.$class.$this->element.'_extras_'.$key.' trextrafields_collapse'.$extrafields_collapse_num.(!empty($this->id)?'_'.$this->id:'').'" '.$domData.' >';
|
||||
$out .= '<tr '.($html_id ? 'id="'.$html_id.'" ' : '').$csstyle.' class="field_options_'.$key.' '.$class.$this->element.'_extras_'.$key.' trextrafields_collapse'.$extrafields_collapse_num.(!empty($this->id)?'_'.$this->id:'').'" '.$domData.' >';
|
||||
if (!empty($conf->global->MAIN_VIEW_LINE_NUMBER) && ($action == 'view' || $action == 'valid' || $action == 'editline')) {
|
||||
$out .= '<td></td>';
|
||||
}
|
||||
$out .= '<td class="wordbreak';
|
||||
$out .= '<td class="titlefieldcreate wordbreak';
|
||||
} elseif ($display_type == 'line') {
|
||||
$out .= '<div '.($html_id ? 'id="'.$html_id.'" ' : '').$csstyle.' class="valuefieldlinecreate '.$class.$this->element.'_extras_'.$key.' trextrafields_collapse'.$extrafields_collapse_num.(!empty($this->id)?'_'.$this->id:'').'" '.$domData.' >';
|
||||
$out .= '<div style="display: inline-block; padding-right:4px" class="wordbreak';
|
||||
$out .= '<div '.($html_id ? 'id="'.$html_id.'" ' : '').$csstyle.' class="fieldline_options_'.$key.' '.$class.$this->element.'_extras_'.$key.' trextrafields_collapse'.$extrafields_collapse_num.(!empty($this->id)?'_'.$this->id:'').'" '.$domData.' >';
|
||||
$out .= '<div style="display: inline-block; padding-right:4px" class="titlefieldcreate wordbreak';
|
||||
}
|
||||
//$out .= "titlefield";
|
||||
//if (GETPOST('action', 'restricthtml') == 'create') $out.='create';
|
||||
@ -8077,9 +8083,9 @@ abstract class CommonObject
|
||||
$html_id = !empty($this->id) ? $this->element.'_extras_'.$key.'_'.$this->id : '';
|
||||
if ($display_type == 'card') {
|
||||
// a first td column was already output (and may be another on before if MAIN_VIEW_LINE_NUMBER set), so this td is the next one
|
||||
$out .= '<td '.($html_id ? 'id="'.$html_id.'" ' : '').' class="'.$this->element.'_extras_'.$key.'" '.($colspan ? ' colspan="'.$colspan.'"' : '').'>';
|
||||
$out .= '<td '.($html_id ? 'id="'.$html_id.'" ' : '').' class="valuefieldcreate '.$this->element.'_extras_'.$key.'" '.($colspan ? ' colspan="'.$colspan.'"' : '').'>';
|
||||
} elseif ($display_type == 'line') {
|
||||
$out .= '<div '.($html_id ? 'id="'.$html_id.'" ' : '').' style="display: inline-block" class="'.$this->element.'_extras_'.$key.'">';
|
||||
$out .= '<div '.($html_id ? 'id="'.$html_id.'" ' : '').' style="display: inline-block" class="valuefieldcreate '.$this->element.'_extras_'.$key.'">';
|
||||
}
|
||||
|
||||
switch ($mode) {
|
||||
|
||||
@ -234,7 +234,7 @@ class Form
|
||||
if (preg_match('/^(string|safehtmlstring|email)/', $typeofdata)) {
|
||||
$tmp = explode(':', $typeofdata);
|
||||
$ret .= '<input type="text" id="'.$htmlname.'" name="'.$htmlname.'" value="'.($editvalue ? $editvalue : $value).'"'.($tmp[1] ? ' size="'.$tmp[1].'"' : '').' autofocus>';
|
||||
} elseif (preg_match('/^(numeric|amount)/', $typeofdata)) {
|
||||
} elseif (preg_match('/^(numeric|amount|integer)/', $typeofdata)) {
|
||||
$tmp = explode(':', $typeofdata);
|
||||
$valuetoshow = price2num($editvalue ? $editvalue : $value);
|
||||
$ret .= '<input type="text" id="'.$htmlname.'" name="'.$htmlname.'" value="'.($valuetoshow != '' ? price($valuetoshow) : '').'"'.($tmp[1] ? ' size="'.$tmp[1].'"' : '').' autofocus>';
|
||||
@ -1587,6 +1587,8 @@ class Form
|
||||
}
|
||||
}
|
||||
print '</select>';
|
||||
print ajax_combobox('select_'.$htmlname);
|
||||
|
||||
return $qualifiedlines;
|
||||
} else {
|
||||
dol_print_error($this->db);
|
||||
@ -5633,6 +5635,7 @@ class Form
|
||||
if ($filter) {
|
||||
$newfilter .= ' AND ('.$filter.')';
|
||||
}
|
||||
// output the combo of discounts
|
||||
$nbqualifiedlines = $this->select_remises($selected, $htmlname, $newfilter, $socid, $maxvalue);
|
||||
if ($nbqualifiedlines > 0) {
|
||||
print ' <input type="submit" class="button smallpaddingimp" value="'.dol_escape_htmltag($langs->trans("UseLine")).'"';
|
||||
@ -7213,10 +7216,11 @@ class Form
|
||||
|
||||
if (!empty($conf->use_javascript_ajax) && !empty($conf->global->TICKET_USE_SEARCH_TO_SELECT)) {
|
||||
$placeholder = '';
|
||||
$urloption = '';
|
||||
|
||||
if ($selected && empty($selected_input_value)) {
|
||||
require_once DOL_DOCUMENT_ROOT.'/adherents/class/adherent.class.php';
|
||||
$adherenttmpselect = new Member($this->db);
|
||||
$adherenttmpselect = new Adherent($this->db);
|
||||
$adherenttmpselect->fetch($selected);
|
||||
$selected_input_value = $adherenttmpselect->ref;
|
||||
unset($adherenttmpselect);
|
||||
@ -7417,7 +7421,7 @@ class Form
|
||||
// Bom:bom/class/bom.class.php:0:t.status=1:ref
|
||||
// Bom:bom/class/bom.class.php:0:(t.status:=:1):ref
|
||||
$InfoFieldList = explode(":", $objectdesc, 4);
|
||||
$vartmp = $InfoFieldList[3];
|
||||
$vartmp = (empty($InfoFieldList[3]) ? '' : $InfoFieldList[3]);
|
||||
$reg = array();
|
||||
if (preg_match('/^.*:(\w*)$/', $vartmp, $reg)) {
|
||||
$InfoFieldList[4] = $reg[1]; // take the sort field
|
||||
|
||||
@ -7,7 +7,7 @@
|
||||
* Copyright (C) 2014 Marcos García <marcosgdf@gmail.com>
|
||||
* Copyright (C) 2015 Bahfir Abbes <bafbes@gmail.com>
|
||||
* Copyright (C) 2016-2017 Ferran Marcet <fmarcet@2byte.es>
|
||||
* Copyright (C) 2019-2021 Frédéric France <frederic.france@netlogic.fr>
|
||||
* Copyright (C) 2019-2022 Frédéric France <frederic.france@netlogic.fr>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
@ -986,6 +986,8 @@ class FormFile
|
||||
$out .= '<td class="right">';
|
||||
$out .= dol_print_date($file->datea, 'dayhour');
|
||||
$out .= '</td>';
|
||||
// for share link of files
|
||||
$out .= '<td></td>';
|
||||
if ($delallowed || $printer || $morepicto) {
|
||||
$out .= '<td></td>';
|
||||
}
|
||||
|
||||
@ -781,7 +781,11 @@ class FormMail extends Form
|
||||
} elseif ($this->withmaindocfile == -1) {
|
||||
$out .= '<input type="checkbox" id="addmaindocfile" name="addmaindocfile" value="1" checked="checked" />';
|
||||
}
|
||||
$out .= ' <label for="addmaindocfile">'.$langs->trans("JoinMainDoc").'.</label><br>';
|
||||
if (!empty($conf->global->MAIL_MASS_ACTION_ADD_LAST_IF_MAIN_DOC_NOT_FOUND)) {
|
||||
$out .= ' <label for="addmaindocfile">'.$langs->trans("JoinMainDocOrLastGenerated").'.</label><br>';
|
||||
} else {
|
||||
$out .= ' <label for="addmaindocfile">'.$langs->trans("JoinMainDoc").'.</label><br>';
|
||||
}
|
||||
}
|
||||
|
||||
if (is_numeric($this->withfile)) {
|
||||
@ -1257,9 +1261,9 @@ class FormMail extends Form
|
||||
* @param string $type_template Get message for model/type=$type_template, type='all' also included.
|
||||
* @param User $user Get template public or limited to this user
|
||||
* @param Translate $outputlangs Output lang object
|
||||
* @param int $id Id of template to find, or -1 for first found with position 0, or 0 for first found whatever is position (priority order depends on lang provided or not) or -2 for exact match with label (no answer if not found)
|
||||
* @param int $id Id of template to get, or -1 for first found with position 0, or 0 for first found whatever is position (priority order depends on lang provided or not) or -2 for exact match with label (no answer if not found)
|
||||
* @param int $active 1=Only active template, 0=Only disabled, -1=All
|
||||
* @param string $label Label of template
|
||||
* @param string $label Label of template to get
|
||||
* @return ModelMail|integer One instance of ModelMail or -1 if error
|
||||
*/
|
||||
public function getEMailTemplate($dbs, $type_template, $user, $outputlangs, $id = 0, $active = 1, $label = '')
|
||||
|
||||
@ -1083,12 +1083,14 @@ class FormOther
|
||||
* @param int $invert Invert
|
||||
* @param string $option Option
|
||||
* @param string $morecss More CSS
|
||||
* @param bool $addjscombo Add js combo
|
||||
* @return string
|
||||
* @deprecated
|
||||
*/
|
||||
public function select_year($selected = '', $htmlname = 'yearid', $useempty = 0, $min_year = 10, $max_year = 5, $offset = 0, $invert = 0, $option = '', $morecss = 'valignmiddle maxwidth75imp')
|
||||
public function select_year($selected = '', $htmlname = 'yearid', $useempty = 0, $min_year = 10, $max_year = 5, $offset = 0, $invert = 0, $option = '', $morecss = 'valignmiddle maxwidth75imp', $addjscombo = false)
|
||||
{
|
||||
// phpcs:enable
|
||||
print $this->selectyear($selected, $htmlname, $useempty, $min_year, $max_year, $offset, $invert, $option, $morecss);
|
||||
print $this->selectyear($selected, $htmlname, $useempty, $min_year, $max_year, $offset, $invert, $option, $morecss, $addjscombo);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@ -990,6 +990,7 @@ function document_preview(file, type, title)
|
||||
img.src = file;
|
||||
|
||||
}
|
||||
|
||||
function show_preview(mode) {
|
||||
/* console.log("mode="+mode+" file="+file+" type="+type+" width="+width+" height="+height); */
|
||||
var newElem = '<object name="objectpreview" data="'+file+'" type="'+type+'" width="'+object_width+'" height="'+object_height+'" param="noparam"></object>';
|
||||
@ -1004,6 +1005,7 @@ function document_preview(file, type, title)
|
||||
}
|
||||
|
||||
$("#dialogforpopup").html(newElem);
|
||||
|
||||
$("#dialogforpopup").dialog({
|
||||
closeOnEscape: true,
|
||||
resizable: true,
|
||||
|
||||
@ -8990,6 +8990,9 @@ function printCommonFooter($zone = 'private')
|
||||
print 'jQuery("select[name=\''.$paramkey.'\']").prop(\'required\',true);'."\n";
|
||||
print 'jQuery("select[name=\''.$paramkey.'\'] option[value=\'-1\']").prop(\'value\', \'\');'."\n";
|
||||
print 'jQuery("select[name=\''.$paramkey.'\'] option[value=\'0\']").prop(\'value\', \'\');'."\n";
|
||||
|
||||
// Add 'field required' class on closest td for all input elements : input, textarea and select
|
||||
print 'jQuery(":input[name=\'' . $paramkey . '\']").closest("tr").find("td:first").addClass("fieldrequired");' . "\n";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -64,10 +64,10 @@ function print_auguria_menu($db, $atarget, $type_user, &$tabMenu, &$menu, $noout
|
||||
// Show/Hide vertical menu. The hamburger icon for .menuhider action.
|
||||
if ($mode != 'jmobile' && $mode != 'topnb' && $usemenuhider && empty($conf->global->MAIN_OPTIMIZEFORTEXTBROWSER)) {
|
||||
$showmode = 1;
|
||||
$classname = 'class="tmenu menuhider"';
|
||||
$classname = 'class="tmenu menuhider nohover"';
|
||||
$idsel = 'menu';
|
||||
|
||||
$menu->add('#', (!empty($conf->global->THEME_TOPMENU_DISABLE_IMAGE) ? '<span class="fa fa-bars"></span>' : ''), 0, $showmode, $atarget, "xxx", '', 0, $id, $idsel, $classname);
|
||||
$menu->add('#', (getDolGlobalInt('THEME_TOPMENU_DISABLE_IMAGE') == 1 ? '<span class="fa fa-bars"></span>' : ''), 0, $showmode, $atarget, "xxx", '', 0, $id, $idsel, $classname);
|
||||
}
|
||||
|
||||
$num = count($newTabMenu);
|
||||
@ -231,22 +231,31 @@ function print_text_menu_entry_auguria($text, $showmode, $url, $id, $idsel, $cla
|
||||
{
|
||||
global $langs;
|
||||
|
||||
$classnameimg = str_replace('class="', 'class="tmenuimage ', $classname);
|
||||
$classnametxt = str_replace('class="', 'class="tmenulabel ', $classname);
|
||||
|
||||
if ($showmode == 1) {
|
||||
print '<a class="tmenuimage" tabindex="-1" href="'.$url.'"'.($atarget ? ' target="'.$atarget.'"' : '').' title="'.dol_escape_htmltag($text).'">';
|
||||
print '<div class="'.$id.' '.$idsel.' topmenuimage"><span class="'.$id.' tmenuimage" id="mainmenuspan_'.$idsel.'"></span></div>';
|
||||
print '</a>';
|
||||
print '<a '.$classname.' id="mainmenua_'.$idsel.'" href="'.$url.'"'.($atarget ? ' target="'.$atarget.'"' : '').' title="'.dol_escape_htmltag($text).'">';
|
||||
print '<span class="mainmenuaspan">';
|
||||
print $text;
|
||||
print '</span>';
|
||||
print '<a '.$classnametxt.' tabindex="-1" href="'.$url.'"'.($atarget ? ' target="'.$atarget.'"' : '').' title="'.dol_escape_htmltag($text).'">';
|
||||
print '<div class="'.$id.' '.$idsel.' topmenuimage"><span class="'.$id.' tmenuimageforpng" id="mainmenuspan_'.$idsel.'"></span></div>';
|
||||
print '</a>';
|
||||
if (empty($conf->global->THEME_TOPMENU_DISABLE_TEXT)) {
|
||||
print '<a '.$classnameimg.' id="mainmenua_'.$idsel.'" href="'.$url.'"'.($atarget ? ' target="'.$atarget.'"' : '').' title="'.dol_escape_htmltag($text).'">';
|
||||
print '<span class="mainmenuaspan">';
|
||||
print $text;
|
||||
print '</span>';
|
||||
print '</a>';
|
||||
}
|
||||
} elseif ($showmode == 2) {
|
||||
print '<div class="'.$id.' '.$idsel.' topmenuimage tmenudisabled"><span class="'.$id.'" id="mainmenuspan_'.$idsel.'"></span></div>';
|
||||
print '<a class="tmenudisabled" id="mainmenua_'.$idsel.'" href="#" title="'.dol_escape_htmltag($langs->trans("NotAllowed")).'">';
|
||||
print '<span class="mainmenuaspan">';
|
||||
print $text;
|
||||
print '</span>';
|
||||
print '</a>';
|
||||
print '<div '.$classnameimg.' title="'.dol_escape_htmltag($text.' - '.$langs->trans("NotAllowed")).'">';
|
||||
print '<div class="'.$id.' '.$idsel.' topmenuimage tmenudisabled"><span class="'.$id.' tmenuimageforpng tmenudisabled" id="mainmenuspan_'.$idsel.'"></span></div>';
|
||||
print '</div>';
|
||||
if (empty($conf->global->THEME_TOPMENU_DISABLE_TEXT)) {
|
||||
print '<span '.$classnametxt.' id="mainmenua_'.$idsel.'" href="#" title="'.dol_escape_htmltag($text.' - '.$langs->trans("NotAllowed")).'">';
|
||||
print '<span class="mainmenuaspan">';
|
||||
print $text;
|
||||
print '</span>';
|
||||
print '</span>';
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -64,10 +64,10 @@ function print_eldy_menu($db, $atarget, $type_user, &$tabMenu, &$menu, $noout =
|
||||
// Show/Hide vertical menu. The hamburger icon for .menuhider action.
|
||||
if ($mode != 'jmobile' && $mode != 'topnb' && $usemenuhider && empty($conf->global->MAIN_OPTIMIZEFORTEXTBROWSER)) {
|
||||
$showmode = 1;
|
||||
$classname = 'class="tmenu menuhider"';
|
||||
$classname = 'class="tmenu menuhider nohover"';
|
||||
$idsel = 'menu';
|
||||
|
||||
$menu->add('#', (!empty($conf->global->THEME_TOPMENU_DISABLE_IMAGE) ? '<span class="fa fa-bars"></span>' : ''), 0, $showmode, $atarget, "xxx", '', 0, $id, $idsel, $classname);
|
||||
$menu->add('#', (getDolGlobalInt('THEME_TOPMENU_DISABLE_IMAGE') == 1 ? '<span class="fa fa-bars"></span>' : ''), 0, $showmode, $atarget, "xxx", '', 0, $id, $idsel, $classname);
|
||||
}
|
||||
|
||||
$menu_arr = array();
|
||||
@ -626,26 +626,31 @@ function print_text_menu_entry($text, $showmode, $url, $id, $idsel, $classname,
|
||||
{
|
||||
global $conf, $langs;
|
||||
|
||||
$classnameimg = str_replace('class="', 'class="tmenuimage ', $classname);
|
||||
$classnametxt = str_replace('class="', 'class="tmenulabel ', $classname);
|
||||
|
||||
//$conf->global->THEME_TOPMENU_DISABLE_TEXT=1;
|
||||
if ($showmode == 1) {
|
||||
print '<a class="tmenuimage" tabindex="-1" href="'.$url.'"'.($atarget ? ' target="'.$atarget.'"' : '').' title="'.dol_escape_htmltag($text).'">';
|
||||
print '<div class="'.$id.' '.$idsel.' topmenuimage"><span class="'.$id.' tmenuimage" id="mainmenuspan_'.$idsel.'"></span></div>';
|
||||
print '<a '.$classnameimg.' tabindex="-1" href="'.$url.'"'.($atarget ? ' target="'.$atarget.'"' : '').' title="'.dol_escape_htmltag($text).'">';
|
||||
print '<div class="'.$id.' '.$idsel.' topmenuimage"><span class="'.$id.' tmenuimageforpng" id="mainmenuspan_'.$idsel.'"></span></div>';
|
||||
print '</a>';
|
||||
if (empty($conf->global->THEME_TOPMENU_DISABLE_TEXT)) {
|
||||
print '<a '.$classname.' id="mainmenua_'.$idsel.'" href="'.$url.'"'.($atarget ? ' target="'.$atarget.'"' : '').' title="'.dol_escape_htmltag($text).'">';
|
||||
print '<a '.$classnametxt.' id="mainmenua_'.$idsel.'" href="'.$url.'"'.($atarget ? ' target="'.$atarget.'"' : '').' title="'.dol_escape_htmltag($text).'">';
|
||||
print '<span class="mainmenuaspan">';
|
||||
print $text;
|
||||
print '</span>';
|
||||
print '</a>';
|
||||
}
|
||||
} elseif ($showmode == 2) {
|
||||
print '<div class="'.$id.' '.$idsel.' topmenuimage tmenudisabled"><span class="'.$id.'" id="mainmenuspan_'.$idsel.'"></span></div>';
|
||||
print '<div '.$classnameimg.' title="'.dol_escape_htmltag($text.' - '.$langs->trans("NotAllowed")).'">';
|
||||
print '<div class="'.$id.' '.$idsel.' topmenuimage tmenudisabled"><span class="'.$id.' tmenuimageforpng tmenudisabled" id="mainmenuspan_'.$idsel.'"></span></div>';
|
||||
print '</div>';
|
||||
if (empty($conf->global->THEME_TOPMENU_DISABLE_TEXT)) {
|
||||
print '<a class="tmenudisabled" id="mainmenua_'.$idsel.'" href="#" title="'.dol_escape_htmltag($langs->trans("NotAllowed")).'">';
|
||||
print '<span class="mainmenuaspan">';
|
||||
print '<span '.$classnametxt.' id="mainmenua_'.$idsel.'" href="#" title="'.dol_escape_htmltag($text.' - '.$langs->trans("NotAllowed")).'">';
|
||||
print '<span class="mainmenuaspan tmenudisabled">';
|
||||
print $text;
|
||||
print '</span>';
|
||||
print '</a>';
|
||||
print '</span>';
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -102,7 +102,7 @@ class MenuManager
|
||||
// Show/Hide vertical menu
|
||||
if ($mode != 'jmobile' && $mode != 'topnb' && $usemenuhider && empty($conf->global->MAIN_OPTIMIZEFORTEXTBROWSER)) {
|
||||
$showmode = 1;
|
||||
$classname = 'class="tmenu menuhider"';
|
||||
$classname = 'class="tmenu menuhider nohover"';
|
||||
$idsel = 'menu';
|
||||
|
||||
$this->menu->add('#', '', 0, $showmode, $atarget, "xxx", '', 0, $id, $idsel, $classname);
|
||||
@ -513,19 +513,32 @@ function print_text_menu_entry_empty($text, $showmode, $url, $id, $idsel, $class
|
||||
{
|
||||
global $conf, $langs;
|
||||
|
||||
$classnameimg = str_replace('class="', 'class="tmenuimage ', $classname);
|
||||
$classnametxt = str_replace('class="', 'class="tmenulabel ', $classname);
|
||||
|
||||
if ($showmode == 1) {
|
||||
print '<a class="tmenuimage" tabindex="-1" href="'.$url.'"'.($atarget ? ' target="'.$atarget.'"' : '').'>';
|
||||
print '<div class="'.$id.' '.$idsel.'"><span class="'.$id.' tmenuimage" id="mainmenuspan_'.$idsel.'"></span></div>';
|
||||
print '</a>';
|
||||
print '<a '.$classname.' id="mainmenua_'.$idsel.'" href="'.$url.'"'.($atarget ? ' target="'.$atarget.'"' : '').'>';
|
||||
print '<span class="mainmenuaspan">';
|
||||
print $text;
|
||||
print '</span>';
|
||||
print '<a '.$classnameimg.' tabindex="-1" href="'.$url.'"'.($atarget ? ' target="'.$atarget.'"' : '').' title="'.dol_escape_htmltag($text).'">';
|
||||
print '<div class="'.$id.' '.$idsel.' topmenuimage"><span class="'.$id.' tmenuimageforpng" id="mainmenuspan_'.$idsel.'"></span></div>';
|
||||
print '</a>';
|
||||
if (empty($conf->global->THEME_TOPMENU_DISABLE_TEXT)) {
|
||||
print '<a '.$classnametxt.' id="mainmenua_'.$idsel.'" href="'.$url.'"'.($atarget ? ' target="'.$atarget.'"' : '').'>';
|
||||
print '<span class="mainmenuaspan">';
|
||||
print $text;
|
||||
print '</span>';
|
||||
print '</a>';
|
||||
}
|
||||
}
|
||||
if ($showmode == 2) {
|
||||
print '<div class="'.$id.' '.$idsel.' tmenudisabled"><span class="'.$id.'" id="mainmenuspan_'.$idsel.'"></span></div>';
|
||||
print '<a class="tmenudisabled" id="mainmenua_'.$idsel.'" href="#" title="'.dol_escape_htmltag($langs->trans("NotAllowed")).'">';
|
||||
print '<div '.$classnameimg.' title="'.dol_escape_htmltag($text.' - '.$langs->trans("NotAllowed")).'">';
|
||||
print '<div class="'.$id.' '.$idsel.' topmenuimage tmenudisabled"><span class="'.$id.' tmenuimageforpng tmenudisabled" id="mainmenuspan_'.$idsel.'"></span></div>';
|
||||
print '</div>';
|
||||
if (empty($conf->global->THEME_TOPMENU_DISABLE_TEXT)) {
|
||||
print '<span '.$classnametxt.' id="mainmenua_'.$idsel.'" href="#" title="'.dol_escape_htmltag($text.' - '.$langs->trans("NotAllowed")).'">';
|
||||
print '<span class="mainmenuaspan">';
|
||||
print $text;
|
||||
print '</span>';
|
||||
print '</span>';
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -826,7 +826,9 @@ class DolibarrModules // Can not be abstract, because we need to instantiate it
|
||||
}
|
||||
|
||||
/**
|
||||
* Tells if module is core or external
|
||||
* Tells if module is core or external.
|
||||
* 'dolibarr' and 'dolibarr_deprecated' is core
|
||||
* 'experimental' and 'development' is core
|
||||
*
|
||||
* @return string 'core', 'external' or 'unknown'
|
||||
*/
|
||||
@ -2247,6 +2249,8 @@ class DolibarrModules // Can not be abstract, because we need to instantiate it
|
||||
$entity = $conf->entity;
|
||||
|
||||
if (is_array($this->module_parts) && !empty($this->module_parts)) {
|
||||
dol_syslog(get_class($this)."::delete_module_parts", LOG_DEBUG);
|
||||
|
||||
foreach ($this->module_parts as $key => $value) {
|
||||
// If entity is defined
|
||||
if (is_array($value) && isset($value['entity'])) {
|
||||
@ -2257,7 +2261,6 @@ class DolibarrModules // Can not be abstract, because we need to instantiate it
|
||||
$sql .= " WHERE ".$this->db->decrypt('name')." LIKE '".$this->db->escape($this->const_name)."_".strtoupper($key)."'";
|
||||
$sql .= " AND entity = ".((int) $entity);
|
||||
|
||||
dol_syslog(get_class($this)."::delete_const_".$key."", LOG_DEBUG);
|
||||
if (!$this->db->query($sql)) {
|
||||
$this->error = $this->db->lasterror();
|
||||
$err++;
|
||||
|
||||
@ -50,7 +50,7 @@ class modIntracommreport extends DolibarrModules
|
||||
$this->description = "Intracomm report management (Support for French DEB/DES format)";
|
||||
|
||||
// Possible values for version are: 'development', 'experimental', 'dolibarr' or 'dolibarr_deprecated' or version
|
||||
$this->version = 'experimental';
|
||||
$this->version = 'development';
|
||||
|
||||
$this->const_name = 'MAIN_MODULE_'.strtoupper($this->name);
|
||||
$this->picto = 'intracommreport';
|
||||
|
||||
@ -105,7 +105,24 @@ if (!empty($conf->global->PRODUCT_USE_UNITS)) {
|
||||
}
|
||||
|
||||
// Reduction short
|
||||
print '<td class="linecoldiscount right">'.$langs->trans('ReductionShort').'</td>';
|
||||
print '<td class="linecoldiscount right">';
|
||||
print $langs->trans('ReductionShort');
|
||||
|
||||
if (in_array($object->element, array('propal', 'commande', 'facture')) && $object->status == $object::STATUS_DRAFT) {
|
||||
global $mysoc;
|
||||
|
||||
if (empty($disableedit)) {
|
||||
print '<a class="reposition" href="'.$_SERVER["PHP_SELF"].'?mode=remiseforalllines&id='.$object->id.'">'.img_edit($langs->trans("UpdateForAllLines"), 0, 'class="clickvatforalllines opacitymedium paddingleft cursorpointer"').'</a>';
|
||||
}
|
||||
//print '<script>$(document).ready(function() { $(".clickremiseforalllines").click(function() { jQuery(".classremiseforalllines").toggle(); }); });</script>';
|
||||
if (GETPOST('mode', 'aZ09') == 'remiseforalllines') {
|
||||
print '<div class="remiseforalllines inline-block nowraponall">';
|
||||
print '<input class="inline-block smallpaddingimp width50 right" name="remiseforalllines" value="" placeholder="%">';
|
||||
print '<input class="inline-block button smallpaddingimp" type="submit" name="submitforalllines" value="'.$langs->trans("Update").'">';
|
||||
print '</div>';
|
||||
}
|
||||
}
|
||||
print '</td>';
|
||||
|
||||
// Fields for situation invoice
|
||||
if (isset($this->situation_cycle_ref) && $this->situation_cycle_ref) {
|
||||
|
||||
@ -73,7 +73,7 @@ class DolLogsCollector extends MessagesCollector
|
||||
{
|
||||
global $conf;
|
||||
|
||||
$uselogfile = getDolGlobalInt('DEBUGBAR_USE_LOGFILE');
|
||||
$uselogfile = getDolGlobalInt('DEBUGBAR_USE_LOG_FILE');
|
||||
|
||||
if ($uselogfile) {
|
||||
$this->getStorageLogs($this->path);
|
||||
|
||||
@ -105,7 +105,9 @@ class ConferenceOrBoothAttendee extends CommonObject
|
||||
'ref' => array('type'=>'varchar(128)', 'label'=>'Ref', 'enabled'=>'1', 'position'=>10, 'notnull'=>1, 'visible'=>2, 'index'=>1, 'comment'=>"Reference of object"),
|
||||
'fk_actioncomm' => array('type'=>'integer:ActionComm:comm/action/class/actioncomm.class.php:1', 'label'=>'ConferenceOrBooth', 'enabled'=>'1', 'position'=>55, 'notnull'=>0, 'visible'=>0, 'index'=>1, 'picto'=>'agenda'),
|
||||
'fk_project' => array('type'=>'integer:Project:projet/class/project.class.php:1', 'label'=>'Project', 'enabled'=>'1', 'position'=>20, 'notnull'=>1, 'visible'=>0, 'index'=>1, 'picto'=>'project', 'css'=>'tdoverflowmax150 maxwidth500'),
|
||||
'email' => array('type'=>'mail', 'label'=>'EmailAttendee', 'enabled'=>'1', 'position'=>30, 'notnull'=>1, 'visible'=>1, 'index'=>1, 'autofocusoncreate'=>1),
|
||||
'email' => array('type'=>'mail', 'label'=>'EmailAttendee', 'enabled'=>'1', 'position'=>30, 'notnull'=>1, 'visible'=>1, 'index'=>1, 'autofocusoncreate'=>1, 'searchall'=>1),
|
||||
'firstname' => array('type'=>'varchar(100)', 'label'=>'Firstname', 'enabled'=>'1', 'position'=>31, 'notnull'=>0, 'visible'=>1, 'index'=>1, 'searchall'=>1),
|
||||
'lastname' => array('type'=>'varchar(100)', 'label'=>'Lastname', 'enabled'=>'1', 'position'=>32, 'notnull'=>0, 'visible'=>1, 'index'=>1, 'searchall'=>1),
|
||||
'fk_soc' => array('type'=>'integer:Societe:societe/class/societe.class.php:1:status = 1 AND entity IN (__SHARED_ENTITIES__)', 'label'=>'ThirdParty', 'enabled'=>'1', 'position'=>40, 'notnull'=>-1, 'visible'=>1, 'index'=>1, 'help'=>"OrganizationEventLinkToThirdParty", 'picto'=>'company', 'css'=>'tdoverflowmax150 maxwidth500'),
|
||||
'date_subscription' => array('type'=>'datetime', 'label'=>'DateOfRegistration', 'enabled'=>'1', 'position'=>56, 'notnull'=>1, 'visible'=>1, 'showoncombobox'=>'1',),
|
||||
'fk_invoice' => array('type'=>'integer:Facture:compta/facture/class/facture.class.php', 'label'=>'Invoice', 'enabled'=>'1', 'position'=>57, 'notnull'=>0, 'visible'=>-1, 'index'=>0, 'picto'=>'bill', 'css'=>'tdoverflowmax150 maxwidth500'),
|
||||
@ -126,6 +128,8 @@ class ConferenceOrBoothAttendee extends CommonObject
|
||||
public $fk_soc;
|
||||
public $fk_actioncomm;
|
||||
public $email;
|
||||
public $firstname;
|
||||
public $lastname;
|
||||
public $date_subscription;
|
||||
public $fk_invoice;
|
||||
public $amount;
|
||||
|
||||
@ -375,46 +375,52 @@ if ($projectid > 0) {
|
||||
print '<table class="border tableforfield centpercent">';
|
||||
|
||||
// Description
|
||||
print '<td class="titlefield tdtop">'.$langs->trans("Description").'</td><td>';
|
||||
print '<tr><td class="titlefield tdtop">'.$langs->trans("Description").'</td><td class="valuefield">';
|
||||
print nl2br($project->description);
|
||||
print '</td></tr>';
|
||||
|
||||
// Categories
|
||||
if ($conf->categorie->enabled) {
|
||||
print '<tr><td class="valignmiddle">'.$langs->trans("Categories").'</td><td>';
|
||||
print '<tr><td class="titlefield valignmiddle">'.$langs->trans("Categories").'</td><td class="valuefield">';
|
||||
print $form->showCategories($project->id, Categorie::TYPE_PROJECT, 1);
|
||||
print "</td></tr>";
|
||||
}
|
||||
|
||||
print '<tr><td>';
|
||||
print '<tr><td class="titlefield">';
|
||||
$typeofdata = 'checkbox:'.($project->accept_conference_suggestions ? ' checked="checked"' : '');
|
||||
$htmltext = $langs->trans("AllowUnknownPeopleSuggestConfHelp");
|
||||
print $form->editfieldkey('AllowUnknownPeopleSuggestConf', 'accept_conference_suggestions', '', $project, $permissiontoadd, $typeofdata, '', 0, 0, 'projectid', $htmltext);
|
||||
print '</td><td>';
|
||||
print '</td><td class="valuefield">';
|
||||
print $form->editfieldval('AllowUnknownPeopleSuggestConf', 'accept_conference_suggestions', '1', $project, $permissiontoadd, $typeofdata, '', 0, 0, '', 0, '', 'projectid');
|
||||
print "</td></tr>";
|
||||
|
||||
print '<tr><td>';
|
||||
print '<tr><td class="titlefield">';
|
||||
$typeofdata = 'checkbox:'.($project->accept_booth_suggestions ? ' checked="checked"' : '');
|
||||
$htmltext = $langs->trans("AllowUnknownPeopleSuggestBoothHelp");
|
||||
print $form->editfieldkey('AllowUnknownPeopleSuggestBooth', 'accept_booth_suggestions', '', $project, $permissiontoadd, $typeofdata, '', 0, 0, 'projectid', $htmltext);
|
||||
print '</td><td>';
|
||||
print '</td><td class="valuefield">';
|
||||
print $form->editfieldval('AllowUnknownPeopleSuggestBooth', 'accept_booth_suggestions', '1', $project, $permissiontoadd, $typeofdata, '', 0, 0, '', 0, '', 'projectid');
|
||||
print "</td></tr>";
|
||||
|
||||
print '<tr><td>';
|
||||
print '<tr><td class="titlefield">';
|
||||
print $form->editfieldkey($form->textwithpicto($langs->trans('PriceOfBooth'), $langs->trans("PriceOfBoothHelp")), 'price_booth', '', $project, $permissiontoadd, 'amount', '', 0, 0, 'projectid');
|
||||
print '</td><td>';
|
||||
print '</td><td class="valuefield">';
|
||||
print $form->editfieldval($form->textwithpicto($langs->trans('PriceOfBooth'), $langs->trans("PriceOfBoothHelp")), 'price_booth', $project->price_booth, $project, $permissiontoadd, 'amount', '', 0, 0, '', 0, '', 'projectid');
|
||||
print "</td></tr>";
|
||||
|
||||
print '<tr><td>';
|
||||
print '<tr><td class="titlefield">';
|
||||
print $form->editfieldkey($form->textwithpicto($langs->trans('PriceOfRegistration'), $langs->trans("PriceOfRegistrationHelp")), 'price_registration', '', $project, $permissiontoadd, 'amount', '', 0, 0, 'projectid');
|
||||
print '</td><td>';
|
||||
print '</td><td class="valuefield">';
|
||||
print $form->editfieldval($form->textwithpicto($langs->trans('PriceOfRegistration'), $langs->trans("PriceOfRegistrationHelp")), 'price_registration', $project->price_registration, $project, $permissiontoadd, 'amount', '', 0, 0, '', 0, '', 'projectid');
|
||||
print "</td></tr>";
|
||||
|
||||
print '<tr><td valign="middle">'.$langs->trans("EventOrganizationICSLink").'</td><td>';
|
||||
print '<tr><td class="titlefield">';
|
||||
print $form->editfieldkey($form->textwithpicto($langs->trans('MaxNbOfAttendees'), ''), 'max_attendees', '', $project, $permissiontoadd, 'integer:3', '', 0, 0, 'projectid');
|
||||
print '</td><td class="valuefield">';
|
||||
print $form->editfieldval($form->textwithpicto($langs->trans('MaxNbOfAttendees'), ''), 'max_attendees', $project->max_attendees, $project, $permissiontoadd, 'integer:3', '', 0, 0, '', 0, '', 'projectid');
|
||||
print "</td></tr>";
|
||||
|
||||
print '<tr><td class="titlefield valignmiddle">'.$langs->trans("EventOrganizationICSLink").'</td><td class="valuefield">';
|
||||
// Define $urlwithroot
|
||||
$urlwithouturlroot = preg_replace('/'.preg_quote(DOL_URL_ROOT, '/').'$/i', '', trim($dolibarr_main_url_root));
|
||||
$urlwithroot = $urlwithouturlroot.DOL_URL_ROOT;
|
||||
@ -427,11 +433,11 @@ if ($projectid > 0) {
|
||||
print "</td></tr>";
|
||||
|
||||
// Link to the submit vote/register page
|
||||
print '<tr><td>';
|
||||
print '<tr><td class="titlefield">';
|
||||
//print '<span class="opacitymedium">';
|
||||
print $form->textwithpicto($langs->trans("SuggestOrVoteForConfOrBooth"), $langs->trans("EvntOrgRegistrationHelpMessage"));
|
||||
//print '</span>';
|
||||
print '</td><td>';
|
||||
print '</td><td class="valuefield">';
|
||||
$linksuggest = $dolibarr_main_url_root.'/public/project/index.php?id='.((int) $project->id);
|
||||
$encodedsecurekey = dol_hash(getDolGlobalString('EVENTORGANIZATION_SECUREKEY').'conferenceorbooth'.((int) $project->id), 'md5');
|
||||
$linksuggest .= '&securekey='.urlencode($encodedsecurekey);
|
||||
@ -444,11 +450,11 @@ if ($projectid > 0) {
|
||||
print '</td></tr>';
|
||||
|
||||
// Link to the subscribe
|
||||
print '<tr><td>';
|
||||
print '<tr><td class="titlefield">';
|
||||
//print '<span class="opacitymedium">';
|
||||
print $langs->trans("PublicAttendeeSubscriptionGlobalPage");
|
||||
//print '</span>';
|
||||
print '</td><td>';
|
||||
print '</td><td class="valuefield">';
|
||||
$link_subscription = $dolibarr_main_url_root.'/public/eventorganization/attendee_new.php?id='.((int) $project->id).'&type=global';
|
||||
$encodedsecurekey = dol_hash(getDolGlobalString('EVENTORGANIZATION_SECUREKEY').'conferenceorbooth'.((int) $project->id), 'md5');
|
||||
$link_subscription .= '&securekey='.urlencode($encodedsecurekey);
|
||||
|
||||
@ -560,11 +560,11 @@ if ($sall) {
|
||||
$moreforfilter = '';
|
||||
|
||||
// If the user can view prospects other than his'
|
||||
if ($user->rights->societe->client->voir || $socid) {
|
||||
if ($user->rights->user->user->lire) {
|
||||
$langs->load("commercial");
|
||||
$moreforfilter .= '<div class="divsearchfield">';
|
||||
$tmptitle = $langs->trans('ThirdPartiesOfSaleRepresentative');
|
||||
$moreforfilter .= img_picto($tmptitle, 'user');
|
||||
$moreforfilter .= img_picto($tmptitle, 'user', 'class="pictofixedwidth"');
|
||||
$moreforfilter .= $formother->select_salesrepresentatives($search_sale, 'search_sale', $user, 0, $tmptitle, 'maxwidth200');
|
||||
$moreforfilter .= '</div>';
|
||||
}
|
||||
@ -572,7 +572,7 @@ if ($user->rights->societe->client->voir || $socid) {
|
||||
if ($user->rights->user->user->lire) {
|
||||
$moreforfilter .= '<div class="divsearchfield">';
|
||||
$tmptitle = $langs->trans('LinkedToSpecificUsers');
|
||||
$moreforfilter .= img_picto($tmptitle, 'user');
|
||||
$moreforfilter .= img_picto($tmptitle, 'user', 'class="pictofixedwidth"');
|
||||
$moreforfilter .= $form->select_dolusers($search_user, 'search_user', $tmptitle, '', 0, '', '', 0, 0, 0, '', 0, '', 'maxwidth200');
|
||||
$moreforfilter .= '</div>';
|
||||
}
|
||||
|
||||
@ -1195,7 +1195,7 @@ if ($resql) {
|
||||
$moreforfilter = '';
|
||||
|
||||
// If the user can view prospects other than his'
|
||||
if ($user->rights->societe->client->voir || $socid) {
|
||||
if ($user->rights->user->user->lire) {
|
||||
$langs->load("commercial");
|
||||
$moreforfilter .= '<div class="divsearchfield">';
|
||||
$tmptitle = $langs->trans('ThirdPartiesOfSaleRepresentative');
|
||||
|
||||
@ -877,15 +877,15 @@ if ($resql) {
|
||||
|
||||
// If the user can view prospects other than his'
|
||||
$moreforfilter = '';
|
||||
if ($user->rights->societe->client->voir || $socid) {
|
||||
if ($user->rights->user->user->lire) {
|
||||
$langs->load("commercial");
|
||||
$moreforfilter .= '<div class="divsearchfield">';
|
||||
$tmptitle = $langs->trans('ThirdPartiesOfSaleRepresentative');
|
||||
$moreforfilter .= img_picto($tmptitle, 'company', 'class="pictofixedwidth"').$formother->select_salesrepresentatives($search_sale, 'search_sale', $user, 0, $tmptitle, 'maxwidth200');
|
||||
$moreforfilter .= img_picto($tmptitle, 'user', 'class="pictofixedwidth"').$formother->select_salesrepresentatives($search_sale, 'search_sale', $user, 0, $tmptitle, 'maxwidth200');
|
||||
$moreforfilter .= '</div>';
|
||||
}
|
||||
// If the user can view prospects other than his'
|
||||
if ($user->rights->societe->client->voir || $socid) {
|
||||
if ($user->rights->user->user->lire) {
|
||||
$moreforfilter .= '<div class="divsearchfield">';
|
||||
$tmptitle = $langs->trans('LinkedToSpecificUsers');
|
||||
$moreforfilter .= img_picto($tmptitle, 'user', 'class="pictofixedwidth"').$form->select_dolusers($search_user, 'search_user', $tmptitle, '', 0, '', '', 0, 0, 0, '', 0, '', 'maxwidth200');
|
||||
|
||||
@ -340,5 +340,10 @@ ALTER TABLE llx_partnership ADD COLUMN url_to_check varchar(255);
|
||||
ALTER TABLE llx_c_partnership_type ADD COLUMN keyword varchar(128);
|
||||
|
||||
|
||||
ALTER TABLE llx_eventorganization_conferenceorboothattendee ADD COLUMN firstname varchar(100);
|
||||
ALTER TABLE llx_eventorganization_conferenceorboothattendee ADD COLUMN lastname varchar(100);
|
||||
|
||||
|
||||
|
||||
ALTER TABLE llx_takepos_floor_tables ADD UNIQUE(entity,label);
|
||||
ALTER TABLE llx_inventory ADD COLUMN fk_categories_product VARCHAR(255) DEFAULT NULL AFTER fk_product;
|
||||
|
||||
@ -23,6 +23,8 @@ CREATE TABLE llx_eventorganization_conferenceorboothattendee(
|
||||
fk_project integer NOT NULL,
|
||||
fk_invoice integer NULL,
|
||||
email varchar(100),
|
||||
firstname varchar(100),
|
||||
lastname varchar(100),
|
||||
date_subscription datetime,
|
||||
amount double DEFAULT NULL,
|
||||
note_public text,
|
||||
|
||||
@ -0,0 +1,27 @@
|
||||
-- Copyright (C) ---Put here your own copyright and developer email---
|
||||
--
|
||||
-- This program is free software: you can redistribute it and/or modify
|
||||
-- it under the terms of the GNU General Public License as published by
|
||||
-- the Free Software Foundation, either version 3 of the License, or
|
||||
-- (at your option) any later version.
|
||||
--
|
||||
-- This program is distributed in the hope that it will be useful,
|
||||
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
-- GNU General Public License for more details.
|
||||
--
|
||||
-- You should have received a copy of the GNU General Public License
|
||||
-- along with this program. If not, see https://www.gnu.org/licenses/.
|
||||
|
||||
|
||||
-- BEGIN MODULEBUILDER INDEXES
|
||||
ALTER TABLE llx_webhook_target ADD INDEX idx_webhook_target_rowid (rowid);
|
||||
ALTER TABLE llx_webhook_target ADD INDEX idx_webhook_target_ref (ref);
|
||||
ALTER TABLE llx_webhook_target ADD CONSTRAINT llx_webhook_target_fk_user_creat FOREIGN KEY (fk_user_creat) REFERENCES llx_user(rowid);
|
||||
ALTER TABLE llx_webhook_target ADD INDEX idx_webhook_target_status (status);
|
||||
-- END MODULEBUILDER INDEXES
|
||||
|
||||
--ALTER TABLE llx_webhook_target ADD UNIQUE INDEX uk_webhook_target_fieldxy(fieldx, fieldy);
|
||||
|
||||
--ALTER TABLE llx_webhook_target ADD CONSTRAINT llx_webhook_target_fk_field FOREIGN KEY (fk_field) REFERENCES llx_webhook_myotherobject(rowid);
|
||||
|
||||
34
htdocs/install/mysql/tables/llx_webhook_target-webhook.sql
Normal file
34
htdocs/install/mysql/tables/llx_webhook_target-webhook.sql
Normal file
@ -0,0 +1,34 @@
|
||||
-- Copyright (C) ---Put here your own copyright and developer email---
|
||||
--
|
||||
-- This program is free software: you can redistribute it and/or modify
|
||||
-- it under the terms of the GNU General Public License as published by
|
||||
-- the Free Software Foundation, either version 3 of the License, or
|
||||
-- (at your option) any later version.
|
||||
--
|
||||
-- This program is distributed in the hope that it will be useful,
|
||||
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
-- GNU General Public License for more details.
|
||||
--
|
||||
-- You should have received a copy of the GNU General Public License
|
||||
-- along with this program. If not, see https://www.gnu.org/licenses/.
|
||||
|
||||
|
||||
CREATE TABLE llx_webhook_target(
|
||||
-- BEGIN MODULEBUILDER FIELDS
|
||||
rowid integer AUTO_INCREMENT PRIMARY KEY NOT NULL,
|
||||
ref varchar(128) NOT NULL,
|
||||
label varchar(255),
|
||||
description text,
|
||||
note_public text,
|
||||
note_private text,
|
||||
date_creation datetime NOT NULL,
|
||||
tms timestamp DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||
fk_user_creat integer NOT NULL,
|
||||
fk_user_modif integer,
|
||||
import_key varchar(14),
|
||||
status integer DEFAULT 0 NOT NULL,
|
||||
url varchar(255) NOT NULL,
|
||||
trigger_codes text NOT NULL
|
||||
-- END MODULEBUILDER FIELDS
|
||||
) ENGINE=innodb;
|
||||
@ -23,7 +23,8 @@
|
||||
*/
|
||||
|
||||
|
||||
/** Terms
|
||||
/**
|
||||
* Terms
|
||||
*
|
||||
* DEB = Declaration d'Exchanges de Biens (FR) = Declaration of Exchange of Goods (EN)
|
||||
* DES = Déclaration Européenne de Services (FR) = European Declaration of Services (EN)
|
||||
@ -32,7 +33,6 @@
|
||||
*
|
||||
*/
|
||||
|
||||
|
||||
require '../main.inc.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/class/html.formother.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/functions.lib.php';
|
||||
@ -40,6 +40,7 @@ require_once DOL_DOCUMENT_ROOT.'/intracommreport/class/intracommreport.class.php
|
||||
|
||||
$langs->loadLangs(array("intracommreport"));
|
||||
|
||||
$id = GETPOST('id', 'int');
|
||||
$action = GETPOST('action');
|
||||
$exporttype = GETPOSTISSET('exporttype') ? GETPOST('exporttype', 'alphanohtml') : 'deb'; // DEB or DES
|
||||
$year = GETPOSTINT('year');
|
||||
@ -65,9 +66,13 @@ $formother = new FormOther($db);
|
||||
// Initialize technical object to manage hooks. Note that conf->hooks_modules contains array
|
||||
$hookmanager->initHooks(array('intracommcard', 'globalcard'));
|
||||
|
||||
$error = 0;
|
||||
|
||||
|
||||
/*
|
||||
* Actions
|
||||
*/
|
||||
|
||||
$parameters = array('id' => $id);
|
||||
// Note that $action and $object may have been modified by some hooks
|
||||
$reshook = $hookmanager->executeHooks('doActions', $parameters, $object, $action);
|
||||
@ -132,6 +137,7 @@ if ($action == 'add' && $user->rights->intracommreport->write) {
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* View
|
||||
*/
|
||||
@ -151,7 +157,7 @@ if ($action == 'create') {
|
||||
print '<table class="border" width="100%">';
|
||||
|
||||
// Label
|
||||
print '<tr><td class="titlefieldcreate">'.$langs->trans("Label").'</td><td><input type="text" class="minwidth200" name="label" autofocus="autofocus"></td></tr>';
|
||||
print '<tr><td class="titlefieldcreate fieldrequired">'.$langs->trans("Label").'</td><td><input type="text" class="minwidth200" name="label" autofocus="autofocus"></td></tr>';
|
||||
|
||||
// Declaration
|
||||
print '<tr><td class="fieldrequired">'.$langs->trans("Declaration")."</td><td>\n";
|
||||
@ -164,8 +170,8 @@ if ($action == 'create') {
|
||||
print $langs->trans("AnalysisPeriod");
|
||||
print '</td>';
|
||||
print '<td>';
|
||||
print $formother->select_month($month ? date('M') : $month, 'month', 0, 1, 'widthauto valignmiddle ');
|
||||
print $formother->select_year($year ? date('Y') : $year, 'year', 0, 3, 3);
|
||||
print $formother->select_month($month ? date('M') : $month, 'month', 0, 1, 'widthauto valignmiddle ', true);
|
||||
print $formother->selectyear($year ? date('Y') : $year, 'year', 0, 3, 3, 0, 0, '', '', true);
|
||||
print '</td>';
|
||||
print '</tr>';
|
||||
|
||||
|
||||
@ -278,10 +278,10 @@ DescVentilExpenseReportMore=If you setup accounting account on type of expense r
|
||||
DescVentilDoneExpenseReport=Consult here the list of the lines of expenses reports and their fees accounting account
|
||||
|
||||
Closure=Annual closure
|
||||
DescClosure=Consult here the number of movements by month who are not validated & fiscal years already open
|
||||
OverviewOfMovementsNotValidated=Step 1/ Overview of movements not validated. (Necessary to close a fiscal year)
|
||||
AllMovementsWereRecordedAsValidated=All movements were recorded as validated
|
||||
NotAllMovementsCouldBeRecordedAsValidated=Not all movements could be recorded as validated
|
||||
DescClosure=Consult here the number of movements by month who are not yet validated & locked
|
||||
OverviewOfMovementsNotValidated=Overview of movements not validated and locked
|
||||
AllMovementsWereRecordedAsValidated=All movements were recorded as validated and locked
|
||||
NotAllMovementsCouldBeRecordedAsValidated=Not all movements could be recorded as validated and locked
|
||||
ValidateMovements=Validate and lock record...
|
||||
DescValidateMovements=Any modification or deletion of writing, lettering and deletes will be prohibited. All entries for an exercise must be validated otherwise closing will not be possible
|
||||
|
||||
|
||||
@ -2249,3 +2249,6 @@ ExportUseLowMemoryMode=Use a low memory mode
|
||||
ExportUseLowMemoryModeHelp=Use the low memory mode to execute the exec of the dump (compression is done through a pipe instead of into the PHP memory). This method does not allow to check that file is completed and error message can't be reported if it fails.
|
||||
ShowQuickAddLink=Show a button to quickly add an element in top right menu
|
||||
HashForPing=Hash used for ping
|
||||
ReadOnlyMode=Is instance in "Read Only" mode
|
||||
DEBUGBAR_USE_LOG_FILE=Use the <b>dolibarr.log</b> file to trap Logs
|
||||
UsingLogFileShowAllRecordOfSubrequestButIsSlower=Use the dolibarr.log file to trap Logs instead of live memory catching. It allows to catch all logs instead of only log of current process (so including the one of ajax subrequests pages) but will make your instance very very slow. Not recommended.
|
||||
|
||||
@ -165,4 +165,5 @@ EmailAttendee=Attendee email
|
||||
EmailCompanyForInvoice=Company email (for invoice, if different of attendee email)
|
||||
ErrorSeveralCompaniesWithEmailContactUs=Several companies with this email has been found so we can't validate automaticaly your registration. Please contact us at %s for a manual validation
|
||||
ErrorSeveralCompaniesWithNameContactUs=Several companies with this name has been found so we can't validate automaticaly your registration. Please contact us at %s for a manual validation
|
||||
NoPublicActionsAllowedForThisEvent=No public actions are open to public for this event
|
||||
NoPublicActionsAllowedForThisEvent=No public actions are open to public for this event
|
||||
MaxNbOfAttendees=Max number of attendees
|
||||
|
||||
@ -621,6 +621,7 @@ MonthVeryShort11=N
|
||||
MonthVeryShort12=D
|
||||
AttachedFiles=Attached files and documents
|
||||
JoinMainDoc=Join main document
|
||||
JoinMainDocOrLastGenerated=Send the main document or the last generated one if not found
|
||||
DateFormatYYYYMM=YYYY-MM
|
||||
DateFormatYYYYMMDD=YYYY-MM-DD
|
||||
DateFormatYYYYMMDDHHMM=YYYY-MM-DD HH:SS
|
||||
@ -1172,4 +1173,4 @@ AddLineOnPosition=Add line on position (at the end if empty)
|
||||
ConfirmAllocateCommercial=Assign sales representative confirmation
|
||||
ConfirmAllocateCommercialQuestion=Are you sure you want to assign the %s selected record(s)?
|
||||
CommercialsAffected=Sales representatives affected
|
||||
CommercialAffected=Sales representative affected
|
||||
CommercialAffected=Sales representative affected
|
||||
|
||||
@ -620,6 +620,7 @@ MonthVeryShort11=N
|
||||
MonthVeryShort12=D
|
||||
AttachedFiles=Fichiers et documents joints
|
||||
JoinMainDoc=Joindre le document principal
|
||||
JoinMainDocOrLastGenerated=Joindre le document principal ou le dernier généré s'il n'a pas été trouvé
|
||||
DateFormatYYYYMM=YYYY-MM
|
||||
DateFormatYYYYMMDD=YYYY-MM-DD
|
||||
DateFormatYYYYMMDDHHMM=YYYY-MM-DD HH:SS
|
||||
|
||||
@ -150,6 +150,11 @@ class Project extends CommonObject
|
||||
*/
|
||||
public $price_booth;
|
||||
|
||||
/**
|
||||
* @var float Max attendees
|
||||
*/
|
||||
public $max_attendees;
|
||||
|
||||
public $statuts_short;
|
||||
public $statuts_long;
|
||||
|
||||
@ -248,6 +253,7 @@ class Project extends CommonObject
|
||||
'accept_booth_suggestions' =>array('type'=>'integer', 'label'=>'AllowUnknownPeopleSuggestBooth', 'enabled'=>1, 'visible'=>-1, 'position'=>147),
|
||||
'price_registration' =>array('type'=>'double(24,8)', 'label'=>'PriceOfRegistration', 'enabled'=>1, 'visible'=>-1, 'position'=>148),
|
||||
'price_booth' =>array('type'=>'double(24,8)', 'label'=>'PriceOfBooth', 'enabled'=>1, 'visible'=>-1, 'position'=>149),
|
||||
'max_attendees' =>array('type'=>'integer', 'label'=>'MaxNbOfAttendees', 'enabled'=>1, 'visible'=>-1, 'position'=>150),
|
||||
'datec' =>array('type'=>'datetime', 'label'=>'DateCreationShort', 'enabled'=>1, 'visible'=>-2, 'position'=>200),
|
||||
'tms' =>array('type'=>'timestamp', 'label'=>'DateModificationShort', 'enabled'=>1, 'visible'=>-2, 'notnull'=>1, 'position'=>205),
|
||||
'fk_user_creat' =>array('type'=>'integer', 'label'=>'UserCreation', 'enabled'=>1, 'visible'=>0, 'notnull'=>1, 'position'=>210),
|
||||
@ -372,6 +378,7 @@ class Project extends CommonObject
|
||||
$sql .= ", accept_booth_suggestions";
|
||||
$sql .= ", price_registration";
|
||||
$sql .= ", price_booth";
|
||||
$sql .= ", max_attendees";
|
||||
$sql .= ", email_msgid";
|
||||
$sql .= ", note_private";
|
||||
$sql .= ", note_public";
|
||||
@ -399,6 +406,7 @@ class Project extends CommonObject
|
||||
$sql .= ", ".($this->accept_booth_suggestions ? 1 : 0);
|
||||
$sql .= ", ".(strcmp($this->price_registration, '') ? price2num($this->price_registration) : 'null');
|
||||
$sql .= ", ".(strcmp($this->price_booth, '') ? price2num($this->price_booth) : 'null');
|
||||
$sql .= ", ".(strcmp($this->max_attendees, '') ? ((int) $this->max_attendees) : 'null');
|
||||
$sql .= ", ".($this->email_msgid ? "'".$this->db->escape($this->email_msgid)."'" : 'null');
|
||||
$sql .= ", ".($this->note_private ? "'".$this->db->escape($this->note_private)."'" : 'null');
|
||||
$sql .= ", ".($this->note_public ? "'".$this->db->escape($this->note_public)."'" : 'null');
|
||||
@ -509,6 +517,7 @@ class Project extends CommonObject
|
||||
$sql .= ", accept_booth_suggestions = ".($this->accept_booth_suggestions ? 1 : 0);
|
||||
$sql .= ", price_registration = ".(strcmp($this->price_registration, '') ? price2num($this->price_registration) : "null");
|
||||
$sql .= ", price_booth = ".(strcmp($this->price_booth, '') ? price2num($this->price_booth) : "null");
|
||||
$sql .= ", max_attendees = ".(strcmp($this->max_attendees, '') ? price2num($this->max_attendees) : "null");
|
||||
$sql .= ", entity = ".((int) $this->entity);
|
||||
$sql .= " WHERE rowid = ".((int) $this->id);
|
||||
|
||||
@ -595,7 +604,7 @@ class Project extends CommonObject
|
||||
$sql = "SELECT rowid, entity, ref, title, description, public, datec, opp_amount, budget_amount,";
|
||||
$sql .= " tms, dateo, datee, date_close, fk_soc, fk_user_creat, fk_user_modif, fk_user_close, fk_statut as status, fk_opp_status, opp_percent,";
|
||||
$sql .= " note_private, note_public, model_pdf, usage_opportunity, usage_task, usage_bill_time, usage_organize_event, email_msgid,";
|
||||
$sql .= " accept_conference_suggestions, accept_booth_suggestions, price_registration, price_booth";
|
||||
$sql .= " accept_conference_suggestions, accept_booth_suggestions, price_registration, price_booth, max_attendees";
|
||||
$sql .= " FROM ".MAIN_DB_PREFIX."projet";
|
||||
if (!empty($id)) {
|
||||
$sql .= " WHERE rowid = ".((int) $id);
|
||||
@ -653,6 +662,7 @@ class Project extends CommonObject
|
||||
$this->accept_booth_suggestions = (int) $obj->accept_booth_suggestions;
|
||||
$this->price_registration = $obj->price_registration;
|
||||
$this->price_booth = $obj->price_booth;
|
||||
$this->max_attendees = $obj->max_attendees;
|
||||
$this->email_msgid = $obj->email_msgid;
|
||||
|
||||
$this->db->free($resql);
|
||||
|
||||
@ -830,7 +830,7 @@ $moreforfilter .= img_picto($tmptitle, 'user', 'class="pictofixedwidth"').$form-
|
||||
$moreforfilter .= '</div>';
|
||||
|
||||
// If the user can view thirdparties other than his'
|
||||
if ($user->rights->societe->client->voir || $socid) {
|
||||
if ($user->rights->user->user->lire) {
|
||||
$langs->load("commercial");
|
||||
$moreforfilter .= '<div class="divsearchfield">';
|
||||
$tmptitle = $langs->trans('ThirdPartiesOfSaleRepresentative');
|
||||
|
||||
@ -1271,17 +1271,21 @@ if ($ispaymentok) {
|
||||
// Get email content from template
|
||||
$arraydefaultmessage = null;
|
||||
|
||||
$labeltouse = $conf->global->EVENTORGANIZATION_TEMPLATE_EMAIL_AFT_SUBS_EVENT;
|
||||
$idoftemplatetouse = $conf->global->EVENTORGANIZATION_TEMPLATE_EMAIL_AFT_SUBS_EVENT; // Email to send for Event organization registration
|
||||
|
||||
if (!empty($labeltouse)) {
|
||||
$arraydefaultmessage = $formmail->getEMailTemplate($db, 'conferenceorbooth', $user, $outputlangs, $labeltouse, 1, '');
|
||||
if (!empty($idoftemplatetouse)) {
|
||||
$arraydefaultmessage = $formmail->getEMailTemplate($db, 'conferenceorbooth', $user, $outputlangs, $idoftemplatetouse, 1, '');
|
||||
}
|
||||
|
||||
if (!empty($labeltouse) && is_object($arraydefaultmessage) && $arraydefaultmessage->id > 0) {
|
||||
if (!empty($idoftemplatetouse) && is_object($arraydefaultmessage) && $arraydefaultmessage->id > 0) {
|
||||
$subject = $arraydefaultmessage->topic;
|
||||
$msg = $arraydefaultmessage->content;
|
||||
} else {
|
||||
$subject = '['.$object->ref.' - '.$outputlangs->trans("NewRegistration").']';
|
||||
$msg = $outputlangs->trans("OrganizationEventPaymentOfRegistrationWasReceived");
|
||||
}
|
||||
|
||||
|
||||
$substitutionarray = getCommonSubstitutionArray($outputlangs, 0, null, $thirdparty);
|
||||
complete_substitutions_array($substitutionarray, $outputlangs, $object);
|
||||
|
||||
@ -1300,7 +1304,7 @@ if ($ispaymentok) {
|
||||
if ($result) {
|
||||
dol_syslog("EMail sent to ".$sendto, LOG_DEBUG, 0, '_payment');
|
||||
} else {
|
||||
dol_syslog("Failed to send EMail to ".$sendto, LOG_ERR, 0, '_payment');
|
||||
dol_syslog("Failed to send EMail to ".$sendto.' - '.$mailfile->error, LOG_ERR, 0, '_payment');
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -1456,14 +1460,18 @@ if ($ispaymentok) {
|
||||
// Get email content from template
|
||||
$arraydefaultmessage = null;
|
||||
|
||||
$labeltouse = $conf->global->EVENTORGANIZATION_TEMPLATE_EMAIL_AFT_SUBS_EVENT;
|
||||
if (!empty($labeltouse)) {
|
||||
$arraydefaultmessage = $formmail->getEMailTemplate($db, 'conferenceorbooth', $user, $outputlangs, $labeltouse, 1, '');
|
||||
$idoftemplatetouse = $conf->global->EVENTORGANIZATION_TEMPLATE_EMAIL_AFT_SUBS_BOOTH; // Email sent after registration for a Booth
|
||||
|
||||
if (!empty($idoftemplatetouse)) {
|
||||
$arraydefaultmessage = $formmail->getEMailTemplate($db, 'conferenceorbooth', $user, $outputlangs, $idoftemplatetouse, 1, '');
|
||||
}
|
||||
|
||||
if (!empty($labeltouse) && is_object($arraydefaultmessage) && $arraydefaultmessage->id > 0) {
|
||||
if (!empty($idoftemplatetouse) && is_object($arraydefaultmessage) && $arraydefaultmessage->id > 0) {
|
||||
$subject = $arraydefaultmessage->topic;
|
||||
$msg = $arraydefaultmessage->content;
|
||||
} else {
|
||||
$subject = '['.$booth->ref.' - '.$outputlangs->trans("NewRegistration").']';
|
||||
$msg = $outputlangs->trans("OrganizationEventPaymentOfBoothWasReceived");
|
||||
}
|
||||
|
||||
$substitutionarray = getCommonSubstitutionArray($outputlangs, 0, null, $thirdparty);
|
||||
|
||||
@ -199,7 +199,7 @@ if (is_array($results)) {
|
||||
$text .= ' - <strong>'.$mysoc->name.'</strong>';
|
||||
$text .= ' - <span class="nowraponall"><span class="fa fa-calendar secondary"></span> '.dol_print_date($object->date_creation).'</span>';
|
||||
$text .= '</td></tr>'."\n";
|
||||
$text .= '<tr><td class="textpublicpayment"><h1>'.$object->label.'</h1></td></tr>'."\n";
|
||||
$text .= '<tr><td class="textpublicpayment"><h1 class="paddingleft paddingright">'.$object->label.'</h1></td></tr>'."\n";
|
||||
}
|
||||
print $text;
|
||||
|
||||
|
||||
@ -250,7 +250,7 @@ if (empty($text)) {
|
||||
$text .= ' - <strong>'.$mysoc->name.'</strong>';
|
||||
$text .= ' - <span class="nowraponall"><span class="fa fa-calendar secondary"></span> '.dol_print_date($object->date_creation).'</span>';
|
||||
$text .= '</td></tr>'."\n";
|
||||
$text .= '<tr><td class="textpublicpayment"><h1>'.$object->label.'</h1><br></td></tr>'."\n";
|
||||
$text .= '<tr><td class="textpublicpayment"><h1 class="paddingleft paddingright">'.$object->label.'</h1><br></td></tr>'."\n";
|
||||
}
|
||||
print $text;
|
||||
|
||||
|
||||
@ -264,7 +264,7 @@ if (empty($reshook) && $action == 'create_ticket' && GETPOST('save', 'alpha')) {
|
||||
$infos_new_ticket .= $langs->transnoentities('TicketNewEmailBodyInfosTrackUrl').'<br><br>';
|
||||
|
||||
$message .= $infos_new_ticket;
|
||||
$message .= getDolGlobalString('TICKET_MESSAGE_MAIL_SIGNATURE') ? getDolGlobalString('TICKET_MESSAGE_MAIL_SIGNATURE') : $langs->transnoentities('TicketMessageMailSignatureText', $mysoc->name);
|
||||
$message .= getDolGlobalString('TICKET_MESSAGE_MAIL_SIGNATURE', $langs->transnoentities('TicketMessageMailSignatureText', $mysoc->name));
|
||||
|
||||
$sendto = GETPOST('email', 'alpha');
|
||||
|
||||
|
||||
@ -125,11 +125,10 @@ $search_array_options = $extrafields->getOptionalsFromPost($object->table_elemen
|
||||
|
||||
// Default sort order (if not yet defined by previous GETPOST)
|
||||
if (!$sortfield) {
|
||||
reset($object->fields); // Reset is required to avoid key() to return null.
|
||||
$sortfield = "t.".key($object->fields); // Set here default search field. By default 1st field in definition.
|
||||
$sortfield = "t.ref";
|
||||
}
|
||||
if (!$sortorder) {
|
||||
$sortorder = "ASC";
|
||||
$sortorder = "DESC";
|
||||
}
|
||||
|
||||
// Initialize array of search criterias
|
||||
|
||||
@ -620,7 +620,7 @@ if ($resql) {
|
||||
$moreforfilter = '';
|
||||
|
||||
// If the user can view prospects other than his'
|
||||
if ($user->rights->societe->client->voir || $socid) {
|
||||
if ($user->rights->user->user->lire) {
|
||||
$langs->load("commercial");
|
||||
$moreforfilter .= '<div class="divsearchfield">';
|
||||
$tmptitle = $langs->trans('ThirdPartiesOfSaleRepresentative');
|
||||
@ -628,7 +628,7 @@ if ($resql) {
|
||||
$moreforfilter .= '</div>';
|
||||
}
|
||||
// If the user can view prospects other than his'
|
||||
if ($user->rights->societe->client->voir || $socid) {
|
||||
if ($user->rights->user->user->lire) {
|
||||
$moreforfilter .= '<div class="divsearchfield">';
|
||||
$tmptitle = $langs->trans('LinkedToSpecificUsers');
|
||||
$moreforfilter .= img_picto($tmptitle, 'user', 'class="pictofixedwidth"').$form->select_dolusers($search_user, 'search_user', $tmptitle, '', 0, '', '', 0, 0, 0, '', 0, '', 'maxwidth250 widthcentpercentminusx');
|
||||
|
||||
@ -361,6 +361,13 @@ function LoadProducts(position, issubcat) {
|
||||
$("#prodiv"+ishow).attr("class","wrapper2");
|
||||
$("#prowatermark"+ishow).hide();
|
||||
ishow++; //Next product to show after print data product
|
||||
<?php
|
||||
// Add js from hooks
|
||||
$parameters=array();
|
||||
$parameters['caller'] = 'loadProducts';
|
||||
$hookmanager->executeHooks('completeJSProductDisplay', $parameters);
|
||||
print $hookmanager->resPrint;
|
||||
?>
|
||||
}
|
||||
//console.log("Hide the prowatermark for ishow="+ishow);
|
||||
idata++; //Next data everytime
|
||||
@ -627,6 +634,15 @@ function Search2(keyCodeForEnter, moreorless) {
|
||||
}
|
||||
$("#prodiv" + i).data("rowid", data[i]['rowid']);
|
||||
$("#prodiv" + i).data("iscat", 0);
|
||||
|
||||
<?php
|
||||
// Add js from hooks
|
||||
$parameters=array();
|
||||
$parameters['caller'] = 'search2';
|
||||
$hookmanager->executeHooks('completeJSProductDisplay', $parameters);
|
||||
print $hookmanager->resPrint;
|
||||
?>
|
||||
|
||||
nbsearchresults++;
|
||||
}
|
||||
}).always(function (data) {
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@ -197,7 +197,7 @@ button.dropdown-item.global-search-item {
|
||||
}
|
||||
|
||||
div#topmenu-global-search-dropdown, div#topmenu-bookmark-dropdown, div#topmenu-quickadd-dropdown {
|
||||
<?php if (empty($conf->global->THEME_TOPMENU_DISABLE_IMAGE)) { ?>
|
||||
<?php if (!getDolGlobalInt('THEME_TOPMENU_DISABLE_IMAGE')) { ?>
|
||||
line-height: 46px;
|
||||
<?php } ?>
|
||||
}
|
||||
@ -236,26 +236,28 @@ a.top-menu-dropdown-link {
|
||||
clear: both;
|
||||
}
|
||||
|
||||
.dropdown-menu > .bookmark-footer{
|
||||
.dropdown-menu > .bookmark-footer {
|
||||
border-top: 1px solid #f0f0f0;
|
||||
background-color: #f9f9f9;
|
||||
padding: 10px;
|
||||
text-align: start;
|
||||
}
|
||||
|
||||
|
||||
.dropdown-menu > .user-body, .dropdown-body{
|
||||
.dropdown-menu > .user-body, .dropdown-body {
|
||||
padding: 15px;
|
||||
border-bottom: 1px solid #f4f4f4;
|
||||
border-top: 1px solid #dddddd;
|
||||
white-space: normal;
|
||||
}
|
||||
|
||||
.dropdown-menu > .bookmark-body, .dropdown-body{
|
||||
.dropdown-menu > .bookmark-body, .dropdown-body {
|
||||
overflow-y: auto;
|
||||
max-height: 60vh ; /* fallback for browsers without support for calc() */
|
||||
max-height: calc(90vh - 110px) ;
|
||||
white-space: normal;
|
||||
}
|
||||
#topmenu-quickadd-dropdown .dropdown-menu > .bookmark-body, #topmenu-quickadd-dropdown .dropdown-body,
|
||||
#topmenu-bookmark-dropdown .dropdown-menu > .bookmark-body, #topmenu-bookmark-dropdown .dropdown-body{
|
||||
max-height: 60vh ; /* fallback for browsers without support for calc() */
|
||||
max-height: calc(90vh - 200px) ;
|
||||
@ -287,7 +289,7 @@ a.top-menu-dropdown-link {
|
||||
|
||||
#topmenuloginmoreinfo-btn, #topmenulogincompanyinfo-btn {
|
||||
display: block;
|
||||
text-align: right;
|
||||
text-align: start;
|
||||
color:#666;
|
||||
cursor: pointer;
|
||||
}
|
||||
@ -298,6 +300,10 @@ a.top-menu-dropdown-link {
|
||||
font-size: 0.95em;
|
||||
}
|
||||
|
||||
a.dropdown-item {
|
||||
text-align: start;
|
||||
}
|
||||
|
||||
.button-top-menu-dropdown {
|
||||
display: inline-block;
|
||||
padding: 6px 12px;
|
||||
|
||||
@ -1956,6 +1956,7 @@ div.blockvmenulogo
|
||||
object-fit: contain;
|
||||
width: inherit;
|
||||
height: inherit;
|
||||
image-rendering: -webkit-optimize-contrast;
|
||||
}
|
||||
#mainmenutd_companylogo::after, #mainmenutd_menu::after {
|
||||
content: unset !important;
|
||||
@ -2587,8 +2588,7 @@ button.ui-button.ui-corner-all.ui-widget:focus {
|
||||
/* For mainmenu, we always load the img */
|
||||
|
||||
div.mainmenu.menu {
|
||||
background-image: url(<?php echo dol_buildpath($path.'/theme/'.$theme.'/img/menus/menu.png', 1) ?>);
|
||||
<?php print $disableimages ? '' : 'top: 7px'; ?>
|
||||
<?php print $disableimages ? '' : 'top: 10px'; ?>
|
||||
}
|
||||
#mainmenutd_menu a.tmenuimage {
|
||||
display: unset;
|
||||
@ -2602,6 +2602,38 @@ a.tmenuimage:hover{
|
||||
}
|
||||
|
||||
|
||||
/* To show text of top menu on hover only (THEME_TOPMENU_DISABLE_IMAGE == 2) */
|
||||
|
||||
<?php if (in_array(getDolGlobalInt('THEME_TOPMENU_DISABLE_IMAGE'), array(2, 3, 4))) { ?>
|
||||
.tmenulabel:not(.menuhider), .tmenulabel:not(.menuhider):before {
|
||||
display: none;
|
||||
}
|
||||
a.tmenuimage:not(.menuhider), a.tmenuimage:not(.menuhider):before,
|
||||
div.tmenuimage:not(.menuhider), div.tmenuimage:not(.menuhider):before,
|
||||
span.tmenuimage:not(.menuhider), span.tmenuimage:not(.menuhider):before {
|
||||
font-size: 1.3em;
|
||||
margin-top: 10px !important;
|
||||
}
|
||||
<?php } ?>
|
||||
<?php if (getDolGlobalInt('THEME_TOPMENU_DISABLE_IMAGE') == 2) { ?>
|
||||
.tmenudiv:hover .tmenulabel:not(.menuhider), .tmenudiv:hover .tmenulabel:not(.menuhider):before {
|
||||
display: initial !important;
|
||||
}
|
||||
.tmenudiv:hover .tmenuimage:not(.menuhider), .tmenudiv:hover .tmenuimage:not(.menuhider):before {
|
||||
font-size: 1.1em !important;
|
||||
margin-top: 0px !important;
|
||||
}
|
||||
<?php } ?>
|
||||
<?php if (getDolGlobalInt('THEME_TOPMENU_DISABLE_IMAGE') == 3) { ?>
|
||||
li.tmenu:hover .tmenulabel:not(.menuhider), li.tmenu:hover .tmenulabel:not(.menuhider):before {
|
||||
display: initial !important;
|
||||
}
|
||||
li.tmenu:hover .tmenuimage:not(.menuhider), li.tmenu:hover .tmenuimage:not(.menuhider):before {
|
||||
font-size: 1.1em !important;
|
||||
margin-top: 0px !important;
|
||||
}
|
||||
<?php } ?>
|
||||
|
||||
|
||||
|
||||
/* Do not load menu img for other if hidden to save bandwidth */
|
||||
|
||||
@ -276,7 +276,7 @@ $heightmenu = 50; /* height of top menu, part with image */
|
||||
$heightmenu2 = 49; /* height of top menu, part with login */
|
||||
$disableimages = 0;
|
||||
$maxwidthloginblock = 180;
|
||||
if (!empty($conf->global->THEME_TOPMENU_DISABLE_IMAGE)) {
|
||||
if (getDolGlobalInt('THEME_TOPMENU_DISABLE_IMAGE') == 1) {
|
||||
$disableimages = 1; $maxwidthloginblock = $maxwidthloginblock + 50; $minwidthtmenu = 0;
|
||||
}
|
||||
|
||||
|
||||
@ -26,12 +26,12 @@ button.dropdown-item.global-search-item {
|
||||
}
|
||||
div#topmenu-quickadd-dropdown {
|
||||
position: fixed;
|
||||
right: 65px;
|
||||
<?php echo $right; ?>: 65px;
|
||||
top: 0px;
|
||||
}
|
||||
div#topmenu-bookmark-dropdown {
|
||||
position: fixed;
|
||||
right: 20px;
|
||||
<?php echo $right; ?>: 20px;
|
||||
top: 0px;
|
||||
}
|
||||
|
||||
@ -201,7 +201,7 @@ button.dropdown-item.global-search-item {
|
||||
}
|
||||
|
||||
div#topmenu-global-search-dropdown, div#topmenu-quickadd-dropdown, div#topmenu-bookmark-dropdown {
|
||||
line-height: 46px;
|
||||
line-height: <?php echo (getDolGlobalInt('THEME_TOPMENU_DISABLE_IMAGE') == 1 ? '35' : '46' ); ?>px;
|
||||
}
|
||||
a.top-menu-dropdown-link {
|
||||
padding: 8px;
|
||||
@ -221,7 +221,7 @@ a.top-menu-dropdown-link {
|
||||
}
|
||||
|
||||
.dropdown-menu > .user-header{
|
||||
background: rgb(<?php echo $colorbackhmenu1 ?>);
|
||||
background: rgb(--colorbackhmenu1);
|
||||
}
|
||||
|
||||
|
||||
@ -244,6 +244,7 @@ a.top-menu-dropdown-link {
|
||||
border-top: 1px solid #f0f0f0;
|
||||
background-color: #f9f9f9;
|
||||
padding: 10px;
|
||||
text-align: start;
|
||||
}
|
||||
|
||||
|
||||
@ -293,7 +294,7 @@ a.top-menu-dropdown-link {
|
||||
|
||||
#topmenuloginmoreinfo-btn, #topmenulogincompanyinfo-btn {
|
||||
display: block;
|
||||
text-align: right;
|
||||
text-align: start;
|
||||
color:#666;
|
||||
cursor: pointer;
|
||||
}
|
||||
@ -304,6 +305,10 @@ a.top-menu-dropdown-link {
|
||||
font-size: 0.95em;
|
||||
}
|
||||
|
||||
a.dropdown-item {
|
||||
text-align: start;
|
||||
}
|
||||
|
||||
.button-top-menu-dropdown {
|
||||
display: inline-block;
|
||||
padding: 6px 12px;
|
||||
|
||||
@ -2438,7 +2438,7 @@ $heightmenu = 48; /* height of top menu, part with image */
|
||||
$heightmenu2 = 48; /* height of top menu, ârt with login */
|
||||
$disableimages = 0;
|
||||
$maxwidthloginblock = 110;
|
||||
if (!empty($conf->global->THEME_TOPMENU_DISABLE_IMAGE)) {
|
||||
if (getDolGlobalInt('THEME_TOPMENU_DISABLE_IMAGE') == 1) {
|
||||
$heightmenu = 30; $disableimages = 1; $maxwidthloginblock = 180; $minwidthtmenu = 0;
|
||||
}
|
||||
?>
|
||||
@ -2623,98 +2623,21 @@ a.tmenuimage:focus, .mainmenu.topmenuimage:focus {
|
||||
outline: none;
|
||||
}
|
||||
|
||||
/* Do not load menu img if hidden to save bandwidth */
|
||||
<?php if (empty($dol_hide_topmenu)) { ?>
|
||||
<?php if (!defined('DISABLE_FONT_AWSOME')) { ?>
|
||||
<?php include dol_buildpath($path.'/theme/'.$theme.'/main_menu_fa_icons.inc.php', 0); ?>
|
||||
<?php } ?>
|
||||
|
||||
div.mainmenu.home{
|
||||
background-image: url(<?php echo dol_buildpath($path.'/theme/'.$theme.'/img/menus/home.png', 1) ?>);
|
||||
background-position-x: center;
|
||||
}
|
||||
|
||||
div.mainmenu.billing {
|
||||
background-image: url(<?php echo dol_buildpath($path.'/theme/'.$theme.'/img/menus/money.png', 1) ?>);
|
||||
}
|
||||
|
||||
div.mainmenu.accountancy {
|
||||
background-image: url(<?php echo dol_buildpath($path.'/theme/'.$theme.'/img/menus/money.png', 1) ?>);
|
||||
}
|
||||
|
||||
div.mainmenu.agenda {
|
||||
background-image: url(<?php echo dol_buildpath($path.'/theme/'.$theme.'/img/menus/agenda.png', 1) ?>);
|
||||
}
|
||||
|
||||
div.mainmenu.bank {
|
||||
background-image: url(<?php echo dol_buildpath($path.'/theme/'.$theme.'/img/menus/bank.png', 1) ?>);
|
||||
}
|
||||
|
||||
div.mainmenu.cashdesk {
|
||||
background-image: url(<?php echo dol_buildpath($path.'/theme/'.$theme.'/img/menus/pointofsale.png', 1) ?>);
|
||||
}
|
||||
|
||||
div.mainmenu.takepos {
|
||||
background-image: url(<?php echo dol_buildpath($path.'/theme/'.$theme.'/img/menus/pointofsale.png', 1) ?>);
|
||||
}
|
||||
|
||||
div.mainmenu.companies {
|
||||
background-image: url(<?php echo dol_buildpath($path.'/theme/'.$theme.'/img/menus/company.png', 1) ?>);
|
||||
}
|
||||
|
||||
div.mainmenu.commercial {
|
||||
background-image: url(<?php echo dol_buildpath($path.'/theme/'.$theme.'/img/menus/commercial.png', 1) ?>);
|
||||
}
|
||||
|
||||
div.mainmenu.ecm {
|
||||
background-image: url(<?php echo dol_buildpath($path.'/theme/'.$theme.'/img/menus/ecm.png', 1) ?>);
|
||||
}
|
||||
|
||||
div.mainmenu.externalsite {
|
||||
background-image: url(<?php echo dol_buildpath($path.'/theme/'.$theme.'/img/menus/externalsite.png', 1) ?>);
|
||||
}
|
||||
|
||||
div.mainmenu.ftp {
|
||||
background-image: url(<?php echo dol_buildpath($path.'/theme/'.$theme.'/img/menus/tools.png', 1) ?>);
|
||||
}
|
||||
|
||||
div.mainmenu.hrm {
|
||||
background-image: url(<?php echo dol_buildpath($path.'/theme/'.$theme.'/img/menus/holiday.png', 1) ?>);
|
||||
}
|
||||
|
||||
div.mainmenu.members {
|
||||
background-image: url(<?php echo dol_buildpath($path.'/theme/'.$theme.'/img/menus/members.png', 1) ?>);
|
||||
}
|
||||
|
||||
div.mainmenu.menu {
|
||||
background-image: url(<?php echo dol_buildpath($path.'/theme/'.$theme.'/img/menus/menu.png', 1) ?>);
|
||||
top: 10px;
|
||||
left: 1px;
|
||||
}
|
||||
|
||||
div.mainmenu.products {
|
||||
background-image: url(<?php echo dol_buildpath($path.'/theme/'.$theme.'/img/menus/products.png', 1) ?>);
|
||||
}
|
||||
|
||||
div.mainmenu.mrp {
|
||||
background-image: url(<?php echo dol_buildpath($path.'/theme/'.$theme.'/img/menus/products.png', 1) ?>);
|
||||
}
|
||||
|
||||
div.mainmenu.project {
|
||||
background-image: url(<?php echo dol_buildpath($path.'/theme/'.$theme.'/img/menus/project.png', 1) ?>);
|
||||
}
|
||||
|
||||
div.mainmenu.ticket {
|
||||
background-image: url(<?php echo dol_buildpath($path.'/theme/'.$theme.'/img/menus/ticket.png', 1) ?>);
|
||||
}
|
||||
|
||||
div.mainmenu.tools {
|
||||
background-image: url(<?php echo dol_buildpath($path.'/theme/'.$theme.'/img/menus/tools.png', 1) ?>);
|
||||
}
|
||||
|
||||
div.mainmenu.website {
|
||||
background-image: url(<?php echo dol_buildpath($path.'/theme/'.$theme.'/img/menus/externalsite.png', 1) ?>);
|
||||
}
|
||||
/* Do not load menu img if hidden to save bandwidth */
|
||||
<?php if (empty($dol_hide_topmenu)) { ?>
|
||||
<?php include dol_buildpath($path.'/theme/'.$theme.'/main_menu_fa_icons.inc.php', 0); ?>
|
||||
|
||||
<?php
|
||||
// Add here more div for other menu entries. moduletomainmenu=array('module name'=>'name of class for div')
|
||||
@ -3162,6 +3085,7 @@ div.blockvmenulogo
|
||||
object-fit: contain;
|
||||
width: inherit;
|
||||
height: inherit;
|
||||
image-rendering: -webkit-optimize-contrast;
|
||||
}
|
||||
#mainmenutd_companylogo::after {
|
||||
content: unset;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user