mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2026-03-07 10:56:50 +01:00
Compare commits
53 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
f4109abe56 | ||
|
|
baa1359021 | ||
|
|
4646cf8417 | ||
|
|
d165a8a557 | ||
|
|
c723aec696 | ||
|
|
f23d590749 | ||
|
|
a3d5c0b30b | ||
|
|
f4278b2c6f | ||
|
|
a7afc55fde | ||
|
|
c449bcf9f4 | ||
|
|
dea8c0cf0e | ||
|
|
ba9f70dc92 | ||
|
|
015c9859cc | ||
|
|
e3a0d9fda4 | ||
|
|
9b54dcf4af | ||
|
|
be2957816a | ||
|
|
2070883cfd | ||
|
|
14de760244 | ||
|
|
0eb3c9e68d | ||
|
|
35eb6853fd | ||
|
|
6ba163880a | ||
|
|
e049222877 | ||
|
|
c428e079e3 | ||
|
|
418f0c2e30 | ||
|
|
500bd9c1f2 | ||
|
|
7a8e0ace2e | ||
|
|
3a15740c73 | ||
|
|
7bb2713bd9 | ||
|
|
96205a6a09 | ||
|
|
1650d96091 | ||
|
|
a0b7852d65 | ||
|
|
cf0ab8d300 | ||
|
|
641333e2ce | ||
|
|
9c0cdee7c6 | ||
|
|
6b73193846 | ||
|
|
9940db94d9 | ||
|
|
0e566ac49f | ||
|
|
1f09296717 | ||
|
|
d072d1fc0a | ||
|
|
17857b271c | ||
|
|
fc19612af0 | ||
|
|
a4e077a0f7 | ||
|
|
749b45a16d | ||
|
|
fffbf75d33 | ||
|
|
293b5a0778 | ||
|
|
61c935b827 | ||
|
|
5077058df5 | ||
|
|
603e1ff877 | ||
|
|
eb778141d6 | ||
|
|
e0e77b203c | ||
|
|
c5b4d149b5 | ||
|
|
ba8ab407fe | ||
|
|
eaee0a952d |
@@ -635,10 +635,8 @@ if ($nboftargetok) {
|
||||
. $BUILD . '"' . "\n";
|
||||
$ret =
|
||||
`git tag -a -f -m "$MAJOR.$MINOR.$BUILD" "$MAJOR.$MINOR.$BUILD"`;
|
||||
print 'Run git push '
|
||||
. $GITREMOTENAME
|
||||
. ' -f "$MAJOR.$MINOR.$BUILD"' . "\n";
|
||||
$ret = `git push $GITREMOTENAME -f -"$MAJOR.$MINOR.$BUILD"`;
|
||||
print "Run git push $GITREMOTENAME -f '$MAJOR.$MINOR.$BUILD'\n";
|
||||
$ret = `git push $GITREMOTENAME -f "$MAJOR.$MINOR.$BUILD"`;
|
||||
|
||||
#$ret=`git push -f origin "$MAJOR.$MINOR.$BUILD"`;
|
||||
}
|
||||
|
||||
@@ -97,7 +97,7 @@
|
||||
$sql .= " AND cs.periode >= '".$db->idate($search_date_limit_start)."'";
|
||||
$sql .= " OR (cs.periode IS NULL AND cs.date_ech between '".$db->idate(dol_get_first_day($year))."' AND '".$db->idate(dol_get_last_day($year))."')";
|
||||
$sql .= " SET reponses = '".$db->escape($nouveauchoix)."'";
|
||||
$sql .= " cs.rowid, cs.libelle, cs.fk_type as type, cs.periode as period, cs.date_ech, cs.amount as total,";
|
||||
$sql .= " cs.rowid, cs.libelle as label, cs.fk_type as type, cs.periode as period, cs.date_ech, cs.amount as total,";
|
||||
$sql.= " ".MAIN_DB_PREFIX."notify_def as nd,";
|
||||
$sql.= " AND nd.fk_action = ad.rowid";
|
||||
$sql.= " WHERE u.rowid = nd.fk_user";
|
||||
|
||||
@@ -1651,7 +1651,9 @@ if ($action == 'create') {
|
||||
print '<table class="border centpercent nobottom">';
|
||||
|
||||
// Assigned to user
|
||||
print '<tr><td class="nowrap titlefieldcreate"><span>'.$langs->trans("ActionAffectedTo").'</span></td><td>';
|
||||
print '<tr><td class="nowrap titlefieldcreate"><span>';
|
||||
print $langs->trans("AssignedTo");
|
||||
print '</span></td><td>';
|
||||
$listofuserid = [];
|
||||
$listofcontactid = [];
|
||||
$listofotherid = [];
|
||||
@@ -1850,7 +1852,7 @@ if ($action == 'create') {
|
||||
print '</select>';
|
||||
print ajax_combobox('taskid');
|
||||
} else {
|
||||
print $formproject->selectTasks((!empty($societe->id) ? $societe->id : -1), $tid, 'taskid', 32, 0, '1', 1, 0, 0, 'maxwidth500 widthcentpercentminusxx', (string) $projectsListId, 'all', null, 1);
|
||||
print $formproject->selectTasks((!empty($societe->id) ? $societe->id : -1), $tid, 'taskid', 64, 0, '1', 1, 0, 0, 'maxwidth500 widthcentpercentminusxx', (string) $projectsListId, 'all', null, 1);
|
||||
}
|
||||
print '</td></tr>';
|
||||
}
|
||||
@@ -2021,7 +2023,7 @@ if ($action == 'create') {
|
||||
|
||||
print dol_get_fiche_end();
|
||||
|
||||
print $form->buttonsSaveCancel("Add");
|
||||
print $form->buttonsSaveCancel("Create");
|
||||
|
||||
print "</form>";
|
||||
}
|
||||
@@ -2418,7 +2420,7 @@ if ($id > 0 && $action != 'create') {
|
||||
</script>
|
||||
<?php
|
||||
|
||||
print $formproject->selectTasks((!empty($societe->id) ? $societe->id : -1), $object->elementid, 'fk_element', 24, 0, '', 1, 0, 0, 'maxwidth500', (string) $object->fk_project, 'all', null, 1);
|
||||
print $formproject->selectTasks((!empty($societe->id) ? $societe->id : -1), $object->elementid, 'fk_element', 64, 0, '', 1, 0, 0, 'maxwidth500', (string) $object->fk_project, 'all', null, 1);
|
||||
print '<input type="hidden" name="elementtype" value="'.$object->elementtype.'">';
|
||||
|
||||
print '</td>';
|
||||
@@ -2451,7 +2453,7 @@ if ($id > 0 && $action != 'create') {
|
||||
$tid = GETPOSTINT("taskid");
|
||||
}
|
||||
|
||||
print $formproject->selectTasks((!empty($societe->id) ? $societe->id : -1), $tid, 'taskid', 24, 0, '1', 1, 0, 0, 'maxwidth500 widthcentpercentminusxx', (string) $projectsListId, 'all', null, 1);
|
||||
print $formproject->selectTasks((!empty($societe->id) ? $societe->id : -1), $tid, 'taskid', 64, 0, '1', 1, 0, 0, 'maxwidth500 widthcentpercentminusxx', (string) $projectsListId, 'all', null, 1);
|
||||
|
||||
print '</td>';
|
||||
} else {
|
||||
|
||||
@@ -457,7 +457,7 @@ class ActionComm extends CommonObject
|
||||
"recurid" => array("type" => "varchar(128)", "label" => "Recurid", "enabled" => "1", 'position' => 195, 'notnull' => 0, "visible" => "0",),
|
||||
"recurrule" => array("type" => "varchar(128)", "label" => "Recurrule", "enabled" => "1", 'position' => 200, 'notnull' => 0, "visible" => "0",),
|
||||
"recurdateend" => array("type" => "datetime", "label" => "Recurdateend", "enabled" => "1", 'position' => 205, 'notnull' => 0, "visible" => "0",),
|
||||
"import_key" => array("type" => "varchar(14)", "label" => "ImportId", "enabled" => "1", 'position' => 900, 'notnull' => 0, "visible" => "0",),
|
||||
"import_key" => array("type" => "varchar(14)", "label" => "ImportId", "enabled" => "1", 'position' => 900, 'notnull' => 0, "visible" => "-1",),
|
||||
"extraparams" => array("type" => "varchar(255)", "label" => "Extraparams", "enabled" => "1", 'position' => 215, 'notnull' => 0, "visible" => "0",),
|
||||
"calling_duration" => array("type" => "integer", "label" => "Callingduration", "enabled" => "1", 'position' => 220, 'notnull' => 0, "visible" => "0",),
|
||||
"visibility" => array("type" => "varchar(12)", "label" => "Visibility", "enabled" => "1", 'position' => 225, 'notnull' => 0, "visible" => "0",),
|
||||
@@ -1986,7 +1986,7 @@ class ActionComm extends CommonObject
|
||||
/**
|
||||
* Return label of type of event
|
||||
*
|
||||
* @param int $mode 0=Mode short, 1=Mode long
|
||||
* @param int $mode 0=Mode short, 1=Mode long, 2=Mode very long
|
||||
* @return string HTML String
|
||||
*/
|
||||
public function getTypeLabel($mode = 0)
|
||||
@@ -2021,6 +2021,11 @@ class ActionComm extends CommonObject
|
||||
if ($this->type == 'systemauto' && $mode == 1) {
|
||||
$labeltype .= ' ('.$langs->trans("auto").')';
|
||||
}
|
||||
if ($this->type == 'systemauto' && $mode == 2) {
|
||||
$labeltype = $langs->trans("AutoActions").($this->type_code == 'AC_OTH_AUTO' ? '' : ': '.$labeltype);
|
||||
} elseif ($this->type != 'systemauto' && $mode == 2) {
|
||||
$labeltype = $langs->trans("ManualActions").($this->type_code == 'AC_OTH' ? '' : ': '.$labeltype);
|
||||
}
|
||||
|
||||
|
||||
return $labeltype;
|
||||
|
||||
@@ -101,17 +101,22 @@ class CActionComm
|
||||
/**
|
||||
* Load action type from database
|
||||
*
|
||||
* @param int|string $id id or code of action type to read
|
||||
* @param int|string $id Id or code of action type to read
|
||||
* @param string $code Code
|
||||
* @return int 1=ok, 0=not found, -1=error
|
||||
*/
|
||||
public function fetch($id)
|
||||
public function fetch($id, $code = '')
|
||||
{
|
||||
$sql = "SELECT id, code, type, libelle as label, color, active, picto";
|
||||
$sql .= " FROM ".MAIN_DB_PREFIX."c_actioncomm";
|
||||
if (is_numeric($id)) {
|
||||
$sql .= " WHERE id=".(int) $id;
|
||||
if (!empty($id)) {
|
||||
if (is_numeric($id)) {
|
||||
$sql .= " WHERE id = ".(int) $id;
|
||||
} else { // For backward compatibility
|
||||
$sql .= " WHERE code = '".$this->db->escape($id)."'";
|
||||
}
|
||||
} else {
|
||||
$sql .= " WHERE code='".$this->db->escape($id)."'";
|
||||
$sql .= " WHERE code = '".$this->db->escape($code)."'";
|
||||
}
|
||||
|
||||
dol_syslog(get_class($this)."::fetch", LOG_DEBUG);
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
* Copyright (C) 2017 Open-DSI <support@open-dsi.fr>
|
||||
* Copyright (C) 2021-2025 Frédéric France <frederic.france@free.fr>
|
||||
* Copyright (C) 2024-2025 MDW <mdeweerd@users.noreply.github.com>
|
||||
* Copyright (C) 2026 Anthony Berton <anthony.berton@bb2a.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
|
||||
@@ -460,6 +461,9 @@ if ($mode == 'show_day' || $mode == 'show_week' || $mode == 'show_month') {
|
||||
if ($search_categ_cus != 0) {
|
||||
$param .= '&search_categ_cus='.urlencode((string) ($search_categ_cus));
|
||||
}
|
||||
if ($check_holiday) {
|
||||
$param .= '&check_holiday=1';
|
||||
}
|
||||
|
||||
// Show navigation bar
|
||||
$nav = '';
|
||||
@@ -629,7 +633,7 @@ if (!empty($conf->use_javascript_ajax)) { // If javascript on
|
||||
$s .= '<script type="text/javascript">'."\n";
|
||||
$s .= 'jQuery(document).ready(function () {'."\n";
|
||||
$s .= 'jQuery(".check_birthday").click(function() { console.log("Toggle class .family_birthday"); jQuery(".family_birthday").toggle(); });'."\n";
|
||||
$s .= 'jQuery(".check_holiday").click(function() { console.log("Toggle class .family_holiday"); jQuery(".family_holiday").toggle(); });'."\n";
|
||||
$s .= 'jQuery(".check_holiday").click(function() { console.log("Toggle class .family_holiday"); jQuery(".family_holiday").toggle(); jQuery(this).closest("form").submit(); });'."\n";
|
||||
if (isModEnabled("bookcal") && !empty($bookcalcalendars["calendars"])) {
|
||||
foreach ($bookcalcalendars["calendars"] as $key => $value) {
|
||||
$s .= 'jQuery(".check_bookcal_calendar_'.$value['id'].'").click(function() { console.log("Toggle Bookcal Calendar '.$value['id'].'"); jQuery(".family_bookcal_calendar_'.$value['id'].'").toggle(); });'."\n";
|
||||
@@ -1173,9 +1177,14 @@ if ($user->hasRight("holiday", "read")) {
|
||||
$sql .= " AND x.date_debut <= '".$db->idate(dol_get_last_day($year, $month))."'";
|
||||
$sql .= " AND x.date_fin >= '".$db->idate(dol_get_first_day($year, $month))."'";
|
||||
}
|
||||
if (!$user->hasRight('holiday', 'readall')) {
|
||||
if (!$user->hasRight('holiday', 'readall') || $filtert == '-3') {
|
||||
// Restrict on users of current user and his children
|
||||
$sql .= " AND x.fk_user IN(".$db->sanitize(implode(", ", $user->getAllChildIds(1))).") ";
|
||||
}
|
||||
if ($filtert > 0) {
|
||||
// Restrict on user
|
||||
$sql .= " AND x.fk_user = ".((int) $filtert);
|
||||
}
|
||||
|
||||
$resql = $db->query($sql);
|
||||
if ($resql) {
|
||||
|
||||
@@ -67,6 +67,7 @@ $disabledefaultvalues = GETPOSTINT('disabledefaultvalues');
|
||||
$resourceid = GETPOSTINT("search_resourceid") ? GETPOSTINT("search_resourceid") : GETPOSTINT("resourceid");
|
||||
$pid = GETPOSTINT("search_projectid", 3) ? GETPOSTINT("search_projectid", 3) : GETPOSTINT("projectid", 3);
|
||||
$search_status = (GETPOST("search_status", 'aZ09') != '') ? GETPOST("search_status", 'aZ09') : GETPOST("status", 'aZ09');
|
||||
$search_import_key = GETPOST("search_import_key");
|
||||
$type = GETPOST('search_type', 'alphanohtml') ? GETPOST('search_type', 'alphanohtml') : GETPOST('type', 'alphanohtml');
|
||||
$year = GETPOSTINT("year");
|
||||
$month = GETPOSTINT("month");
|
||||
@@ -255,6 +256,7 @@ if (GETPOST('button_removefilter_x', 'alpha') || GETPOST('button_removefilter.x'
|
||||
$dateend_dtend = '';
|
||||
$actioncode = '';
|
||||
$search_status = '';
|
||||
$search_import_key = '';
|
||||
$pid = '';
|
||||
$socid = '';
|
||||
$resourceid = '';
|
||||
@@ -352,6 +354,9 @@ if ($resourceid > 0) {
|
||||
if ($search_status != '') {
|
||||
$param .= "&search_status=".urlencode($search_status);
|
||||
}
|
||||
if ($search_import_key != '') {
|
||||
$param .= "&search_import_key=".urlencode($search_import_key);
|
||||
}
|
||||
if ($filter) {
|
||||
$param .= "&search_filter=".urlencode((string) $filter);
|
||||
}
|
||||
@@ -452,7 +457,7 @@ $sql .= " a.datep as dp, a.id, a.code, a.label, a.note, a.datep2 as dp2, a.fulld
|
||||
$sql .= " a.fk_user_author, a.fk_user_action,";
|
||||
$sql .= " a.fk_contact, a.note, a.percent as percent,";
|
||||
$sql .= " a.fk_element, a.elementtype, a.datec, a.tms as datem,";
|
||||
$sql .= " a.recurid, a.recurrule, a.recurdateend,";
|
||||
$sql .= " a.recurid, a.recurrule, a.recurdateend, a.import_key,";
|
||||
$sql .= " c.code as type_code, c.libelle as type_label, c.color as type_color, c.type as type_type, c.picto as type_picto,";
|
||||
$sql .= " s.nom as societe, s.rowid as socid, s.client, s.email as socemail";
|
||||
//$sql .= " sp.lastname, sp.firstname, sp.email, sp.phone, sp.address, sp.phone as phone_pro, sp.phone_mobile, sp.phone_perso, sp.fk_pays as country_id";
|
||||
@@ -572,6 +577,9 @@ if ($search_status == 'done' || $search_status == '100') {
|
||||
if ($search_status == 'todo') {
|
||||
$sql .= " AND (a.percent >= 0 AND a.percent < 100)";
|
||||
}
|
||||
if ($search_import_key) {
|
||||
$sql .= natural_search("a.import_key", $search_import_key);
|
||||
}
|
||||
if ($search_id) {
|
||||
$sql .= natural_search("a.id", $search_id, 1);
|
||||
}
|
||||
@@ -725,10 +733,6 @@ if ($showbirthday) {
|
||||
}
|
||||
print $nav;
|
||||
|
||||
//print dol_get_fiche_head($head, $tabactive, $langs->trans('Agenda'), 0, 'action');
|
||||
//print_actions_filter($form, $canedit, $search_status, $year, $month, $day, $showbirthday, '', $filtert, '', $pid, $socid, $action, -1, $actioncode, $usergroup, '', $resourceid);
|
||||
//print dol_get_fiche_end();
|
||||
|
||||
|
||||
$s = $newtitle;
|
||||
|
||||
@@ -821,7 +825,7 @@ if ($massactionbutton) {
|
||||
$i = 0;
|
||||
|
||||
print '<div class="liste_titre liste_titre_bydiv centpercent">';
|
||||
print_actions_filter($form, $canedit, $search_status, $year, $month, $day, $showbirthday, '', $filtert, '', $pid, $socid, $action, -1, $actioncode, $usergroup, '', $resourceid, $search_categ_cus);
|
||||
print_actions_filter($form, $canedit, $search_status, $year, $month, $day, $showbirthday, '', $filtert, '', $pid, $socid, $action, -1, $actioncode, $usergroup, '', $resourceid, $search_categ_cus, $search_import_key);
|
||||
print '</div>';
|
||||
|
||||
$moreforfilter = 1;
|
||||
@@ -896,6 +900,10 @@ if (!empty($arrayfields['a.datec']['checked'])) {
|
||||
if (!empty($arrayfields['a.tms']['checked'])) {
|
||||
print '<td class="liste_titre"></td>';
|
||||
}
|
||||
if (!empty($arrayfields['a.import_key']['checked'])) {
|
||||
print '<td class="liste_titre center"><input type="text" class="maxwidth75" name="search_import_key" value="'.$search_import_key.'"></td>';
|
||||
print '</td>';
|
||||
}
|
||||
if (!empty($arrayfields['a.percent']['checked'])) {
|
||||
print '<td class="liste_titre center parentonrightofpage">';
|
||||
$formactions->form_select_status_action('formaction', $search_status, 1, 'search_status', 1, 2, 'search_status width100 onrightofpage');
|
||||
@@ -976,6 +984,11 @@ if (!empty($arrayfields['a.tms']['checked'])) {
|
||||
print_liste_field_titre($arrayfields['a.tms']['label'], $_SERVER["PHP_SELF"], "a.tms,a.id", "", $param, '', $sortfield, $sortorder, 'center ');
|
||||
$totalarray['nbfield']++;
|
||||
}
|
||||
// Import ID
|
||||
if (!empty($arrayfields['a.import_key']['checked'])) {
|
||||
print_liste_field_titre("ImportId", $_SERVER["PHP_SELF"], "a.import_key", "", $param, '', $sortfield, $sortorder, 'center ');
|
||||
$totalarray['nbfield']++;
|
||||
}
|
||||
// Status
|
||||
if (!empty($arrayfields['a.percent']['checked'])) {
|
||||
print_liste_field_titre("Status", $_SERVER["PHP_SELF"], "a.percent", "", $param, '', $sortfield, $sortorder, 'center ');
|
||||
@@ -1297,16 +1310,20 @@ while ($i < $imaxinloop) {
|
||||
// Date creation
|
||||
if (!empty($arrayfields['a.datec']['checked'])) {
|
||||
// Status/Percent
|
||||
print '<td align="center" class="nowrap">'.dol_print_date($db->jdate($obj->datec), 'dayhour', 'tzuserrel').'</td>';
|
||||
print '<td class="center nowrap">'.dol_print_date($db->jdate($obj->datec), 'dayhour', 'tzuserrel').'</td>';
|
||||
}
|
||||
// Date update
|
||||
if (!empty($arrayfields['a.tms']['checked'])) {
|
||||
print '<td align="center" class="nowrap">'.dol_print_date($db->jdate($obj->datem), 'dayhour', 'tzuserrel').'</td>';
|
||||
print '<td class="center nowrap">'.dol_print_date($db->jdate($obj->datem), 'dayhour', 'tzuserrel').'</td>';
|
||||
}
|
||||
// Import key
|
||||
if (!empty($arrayfields['a.import_key']['checked'])) {
|
||||
print '<td class="center nowrap">'.dolPrintHTML($obj->import_key).'</td>';
|
||||
}
|
||||
// Status/Percent
|
||||
if (!empty($arrayfields['a.percent']['checked'])) {
|
||||
// Status/Percent
|
||||
$datep = $db->jdate($obj->dp);
|
||||
print '<td align="center" class="nowrap">'.$actionstatic->LibStatut($obj->percent, 5, 0, $datep).'</td>';
|
||||
print '<td class="center nowrap">'.$actionstatic->LibStatut($obj->percent, 5, 0, $datep).'</td>';
|
||||
}
|
||||
// Action column
|
||||
if (!getDolGlobalString('MAIN_CHECKBOX_LEFT_COLUMN')) {
|
||||
|
||||
@@ -955,7 +955,7 @@ if ($object->id > 0) {
|
||||
}
|
||||
}
|
||||
$relativepath = dol_sanitizeFileName($objp->ref).'/'.dol_sanitizeFileName($objp->ref).'.pdf';
|
||||
print $formfile->showPreview($file_list, $propal_static->element, $relativepath, 0);
|
||||
print $formfile->showPreview($file_list, $propal_static->element, $relativepath, 0, 'entity=' . $objp->entity);
|
||||
}
|
||||
print '</td><td class="tdoverflowmax125">';
|
||||
if ($propal_static->fk_project > 0) {
|
||||
@@ -1076,7 +1076,7 @@ if ($object->id > 0) {
|
||||
}
|
||||
}
|
||||
$relativepath = dol_sanitizeFileName($objp->ref).'/'.dol_sanitizeFileName($objp->ref).'.pdf';
|
||||
print $formfile->showPreview($file_list, $commande_static->element, $relativepath, 0, $param);
|
||||
print $formfile->showPreview($file_list, $commande_static->element, $relativepath, 0, 'entity=' . $objp->entity);
|
||||
}
|
||||
print '</td><td class="tdoverflowmax125">';
|
||||
if ($commande_static->fk_project > 0) {
|
||||
@@ -1109,6 +1109,8 @@ if ($object->id > 0) {
|
||||
* Latest shipments
|
||||
*/
|
||||
if (isModEnabled("shipping") && $user->hasRight('expedition', 'lire')) {
|
||||
$param = 'entity=' . ((int) $objp->entity);
|
||||
|
||||
$sql = 'SELECT e.rowid as id';
|
||||
$sql .= ', e.ref, e.entity, e.fk_projet';
|
||||
$sql .= ', e.date_creation';
|
||||
@@ -1177,7 +1179,8 @@ if ($object->id > 0) {
|
||||
}
|
||||
}
|
||||
$relativepath = dol_sanitizeFileName($objp->ref).'/'.dol_sanitizeFileName($objp->ref).'.pdf';
|
||||
print $formfile->showPreview($file_list, $sendingstatic->table_element, $relativepath, 0, $param);
|
||||
|
||||
print $formfile->showPreview($file_list, $sendingstatic->element, $relativepath, 0, $param);
|
||||
}
|
||||
print '</td><td class="tdoverflowmax125">';
|
||||
if ($sendingstatic->fk_project > 0) {
|
||||
@@ -1291,7 +1294,7 @@ if ($object->id > 0) {
|
||||
}
|
||||
}
|
||||
$relativepath = dol_sanitizeFileName($objp->ref).'/'.dol_sanitizeFileName($objp->ref).'.pdf';
|
||||
print $formfile->showPreview($file_list, $contrat->element, $relativepath, 0);
|
||||
print $formfile->showPreview($file_list, $contrat->element, $relativepath, 0, 'entity=' . $objp->entity);
|
||||
}
|
||||
}
|
||||
// $filename = dol_sanitizeFileName($objp->ref);
|
||||
@@ -1392,7 +1395,7 @@ if ($object->id > 0) {
|
||||
}
|
||||
}
|
||||
$relativepath = dol_sanitizeFileName($objp->ref).'/'.dol_sanitizeFileName($objp->ref).'.pdf';
|
||||
print $formfile->showPreview($file_list, $fichinter_static->element, $relativepath, 0);
|
||||
print $formfile->showPreview($file_list, $fichinter_static->element, $relativepath, 0, 'entity=' . $objp->entity);
|
||||
}
|
||||
print '</td><td class="tdoverflowmax125">';
|
||||
if ($fichinter_static->fk_project > 0) {
|
||||
@@ -1623,7 +1626,7 @@ if ($object->id > 0) {
|
||||
}
|
||||
}
|
||||
$relativepath = dol_sanitizeFileName($objp->ref).'/'.dol_sanitizeFileName($objp->ref).'.pdf';
|
||||
print $formfile->showPreview($file_list, $facturestatic->element, $relativepath, 0);
|
||||
print $formfile->showPreview($file_list, $facturestatic->element, $relativepath, 0, 'entity=' . $objp->entity);
|
||||
}
|
||||
print '</td><td class="tdoverflowmax125">';
|
||||
if ($facturestatic->fk_project > 0) {
|
||||
|
||||
@@ -1071,7 +1071,6 @@ if ($action == 'create') { // aaa
|
||||
// Ref customer
|
||||
$morehtmlref .= $form->editfieldkey("", 'title', $object->title, $object, $user->hasRight('mailing', 'creer'), 'string', '', 0, 1);
|
||||
$morehtmlref .= $form->editfieldval("", 'title', $object->title, $object, $user->hasRight('mailing', 'creer'), 'string', '', null, null, '', 1);
|
||||
$morehtmlref .= '</div>';
|
||||
|
||||
$morehtmlstatus = '';
|
||||
$nbtry = $nbok = 0;
|
||||
@@ -1106,6 +1105,7 @@ if ($action == 'create') { // aaa
|
||||
}
|
||||
}
|
||||
}
|
||||
$morehtmlref .= '</div>';
|
||||
|
||||
dol_banner_tab($object, 'id', $linkback, 1, 'rowid', 'ref', $morehtmlref, '', 0, '', $morehtmlstatus);
|
||||
|
||||
|
||||
@@ -28,6 +28,13 @@
|
||||
|
||||
// Load Dolibarr environment
|
||||
require '../../main.inc.php';
|
||||
/**
|
||||
* @var Conf $conf
|
||||
* @var DoliDB $db
|
||||
* @var HookManager $hookmanager
|
||||
* @var Translate $langs
|
||||
* @var User $user
|
||||
*/
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/modules/mailings/modules_mailings.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/comm/mailing/class/mailing.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/class/html.formmailing.class.php';
|
||||
@@ -36,20 +43,12 @@ require_once DOL_DOCUMENT_ROOT.'/core/class/CMailFile.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/functions2.lib.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/ajax.lib.php';
|
||||
|
||||
|
||||
/**
|
||||
* @var Conf $conf
|
||||
* @var DoliDB $db
|
||||
* @var HookManager $hookmanager
|
||||
* @var Translate $langs
|
||||
* @var User $user
|
||||
*/
|
||||
|
||||
// Load translation files required by the page
|
||||
$langs->loadLangs(array("mails", "admin"));
|
||||
|
||||
$action = GETPOST('action', 'aZ09');
|
||||
$toselect = GETPOST('toselect', 'array:int'); // Array of ids of elements selected into a list
|
||||
$contextpage = GETPOST('contextpage', 'aZ');
|
||||
$massaction = GETPOST('massaction', 'alpha'); // The bulk action (combo box choice into lists)
|
||||
$mode = GETPOST('mode', 'aZ'); // The display mode ('list', 'kanban', 'hierarchy', 'calendar', 'gantt', ...)
|
||||
|
||||
@@ -778,7 +777,8 @@ if ($object->fetch($id) >= 0) {
|
||||
if ($object->status == $object::STATUS_DRAFT) {
|
||||
$morehtmlcenter = '<span class="opacitymedium hideonsmartphone">'.$langs->trans("ToClearAllRecipientsClickHere").'</span> <a href="'.$_SERVER["PHP_SELF"].'?clearlist=1&id='.$object->id.'" class="button reposition smallpaddingimp">'.$langs->trans("TargetsReset").'</a>';
|
||||
}
|
||||
$morehtmlcenter .= ' <a class="reposition" href="'.$_SERVER["PHP_SELF"].'?action=exportcsv&token='.newToken().'&exportcsv=1&id='.$object->id.'">'.img_picto('', 'download', 'class="pictofixedwidth"').$langs->trans("Download").'</a>';
|
||||
|
||||
$morehtmlright = '<a class="reposition marginrightonly" href="'.$_SERVER["PHP_SELF"].'?action=exportcsv&token='.newToken().'&exportcsv=1&id='.$object->id.'">'.img_picto('', 'download', 'class="pictofixedwidth"').$langs->trans("Download").'</a> ';
|
||||
|
||||
print '</form>';
|
||||
|
||||
@@ -793,7 +793,7 @@ if ($object->fetch($id) >= 0) {
|
||||
print '<input type="hidden" name="page_y" value="">';
|
||||
|
||||
// @phan-suppress-next-line PhanPluginSuspiciousParamOrder
|
||||
print_barre_liste($langs->trans("MailSelectedRecipients"), $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, $morehtmlcenter, $num, $nbtotalofrecords, 'generic', 0, $newcardbutton, '', $limit, 0, 0, 1);
|
||||
print_barre_liste($langs->trans("MailSelectedRecipients"), $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, $morehtmlcenter, $num, $nbtotalofrecords, 'generic', 0, $newcardbutton, '', $limit, 0, 0, 1, $morehtmlright);
|
||||
|
||||
if ($massaction == 'reset_target') {
|
||||
// Confirm reset
|
||||
|
||||
@@ -1367,7 +1367,7 @@ if (empty($reshook)) {
|
||||
// If a price per customer exist
|
||||
$pricebycustomerexist = false;
|
||||
$result = $prodcustprice->fetchAll('', '', 0, 0, $filter);
|
||||
if ($result) {
|
||||
if ($result >= 0) {
|
||||
// If there is some prices specific to the customer
|
||||
if (count($prodcustprice->lines) > 0) {
|
||||
$date_now = (int) floor(dol_now() / 86400) * 86400; // date without hours
|
||||
@@ -1391,9 +1391,11 @@ if (empty($reshook)) {
|
||||
}
|
||||
}
|
||||
}
|
||||
} else {
|
||||
setEventMessages($prodcustprice->error, $prodcustprice->errors, 'errors');
|
||||
}
|
||||
|
||||
if (!$pricebycustomerexist && $object->thirdparty->price_level) { // If price per segment
|
||||
if (!$pricebycustomerexist && !empty($object->thirdparty->price_level)) { // If price per segment
|
||||
$pu_ht = $prod->multiprices[$object->thirdparty->price_level];
|
||||
$pu_ttc = $prod->multiprices_ttc[$object->thirdparty->price_level];
|
||||
$price_min = $prod->multiprices_min[$object->thirdparty->price_level];
|
||||
@@ -1408,7 +1410,7 @@ if (empty($reshook)) {
|
||||
}
|
||||
}
|
||||
}
|
||||
} elseif (getDolGlobalString('PRODUIT_MULTIPRICES') && $object->thirdparty->price_level) { // If price per segment
|
||||
} elseif (getDolGlobalString('PRODUIT_MULTIPRICES') && !empty($object->thirdparty->price_level)) { // If price per segment
|
||||
$pu_ht = $prod->multiprices[$object->thirdparty->price_level];
|
||||
$pu_ttc = $prod->multiprices_ttc[$object->thirdparty->price_level];
|
||||
$price_min = $prod->multiprices_min[$object->thirdparty->price_level];
|
||||
@@ -1431,7 +1433,7 @@ if (empty($reshook)) {
|
||||
$filter = array('t.fk_product' => (string) $prod->id, 't.fk_soc' => (string) $object->thirdparty->id);
|
||||
|
||||
$result = $prodcustprice->fetchAll('', '', 0, 0, $filter);
|
||||
if ($result) {
|
||||
if ($result >= 0) {
|
||||
// If there is some prices specific to the customer
|
||||
if (count($prodcustprice->lines) > 0) {
|
||||
$date_now = (int) floor(dol_now() / 86400) * 86400; // date without hours
|
||||
@@ -1454,6 +1456,8 @@ if (empty($reshook)) {
|
||||
}
|
||||
}
|
||||
}
|
||||
} else {
|
||||
setEventMessages($prodcustprice->error, $prodcustprice->errors, 'errors');
|
||||
}
|
||||
} elseif (getDolGlobalString('PRODUIT_CUSTOMER_PRICES_BY_QTY')) {
|
||||
// If price per quantity
|
||||
@@ -1499,26 +1503,32 @@ if (empty($reshook)) {
|
||||
}
|
||||
}
|
||||
|
||||
$tmpvat = price2num(preg_replace('/\s*\(.*\)/', '', $tva_tx));
|
||||
$tmpprodvat = price2num(preg_replace('/\s*\(.*\)/', '', (string) $prod->tva_tx));
|
||||
$tmpvat = (float) price2num(preg_replace('/\s*\(.*\)/', '', $tva_tx));
|
||||
$tmpprodvat = (float) price2num(preg_replace('/\s*\(.*\)/', '', (string) $prod->tva_tx));
|
||||
|
||||
// Set unit price to use
|
||||
if (!empty($price_ht) || (string) $price_ht === '0') {
|
||||
$pu_ht = price2num($price_ht, 'MU');
|
||||
$pu_ttc = price2num((float) $pu_ht * (1 + ((float) $tmpvat / 100)), 'MU');
|
||||
$pu_ht = (float) price2num($price_ht, 'MU');
|
||||
$pu_ttc = (float) price2num((float) $pu_ht * (1 + ((float) $tmpvat / 100)), 'MU');
|
||||
} elseif (!empty($price_ht_devise) || (string) $price_ht_devise === '0') {
|
||||
$pu_ht_devise = price2num($price_ht_devise, 'MU');
|
||||
$pu_ttc_devise = (float) price2num((float) $pu_ht_devise * (1 + ((float) $tmpvat / 100)), 'MU');
|
||||
$pu_ht = '';
|
||||
$pu_ttc = '';
|
||||
} elseif (!empty($price_ttc) || (string) $price_ttc === '0') {
|
||||
$pu_ttc = price2num($price_ttc, 'MU');
|
||||
$pu_ht = price2num((float) $pu_ttc / (1 + ((float) $tmpvat / 100)), 'MU');
|
||||
$pu_ttc = (float) price2num($price_ttc, 'MU');
|
||||
$pu_ht = (float) price2num((float) $pu_ttc / (1 + ((float) $tmpvat / 100)), 'MU');
|
||||
} elseif (!empty($price_ttc_devise) || (string) $price_ttc_devise === '0') {
|
||||
$pu_ttc_devise = (float) price2num($price_ttc_devise, 'MU');
|
||||
$pu_ht_devise = (float) price2num((float) $pu_ttc_devise / (1 + ((float) $tmpvat / 100)), 'MU');
|
||||
$pu_ht = '';
|
||||
$pu_ttc = '';
|
||||
} elseif ($tmpvat != $tmpprodvat) {
|
||||
// Is this still used ?
|
||||
if ($price_base_type != 'HT') {
|
||||
$pu_ht = price2num((float) $pu_ttc / (1 + ((float) $tmpvat / 100)), 'MU');
|
||||
$pu_ht = (float) price2num((float) $pu_ttc / (1 + ((float) $tmpvat / 100)), 'MU');
|
||||
} else {
|
||||
$pu_ttc = price2num((float) $pu_ht * (1 + ((float) $tmpvat / 100)), 'MU');
|
||||
$pu_ttc = (float) price2num((float) $pu_ht * (1 + ((float) $tmpvat / 100)), 'MU');
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1600,10 +1610,10 @@ if (empty($reshook)) {
|
||||
$pu_ht = price2num($price_ht, 'MU');
|
||||
$pu_ttc = price2num($price_ttc, 'MU');
|
||||
$tva_npr = (preg_match('/\*/', $tva_tx) ? 1 : 0);
|
||||
$tva_tx = str_replace('*', '', $tva_tx);
|
||||
if (empty($tva_tx)) {
|
||||
$tva_npr = 0;
|
||||
}
|
||||
$tva_tx = str_replace('*', '', $tva_tx);
|
||||
$label = (GETPOST('product_label') ? GETPOST('product_label') : '');
|
||||
$desc = $line_desc;
|
||||
$type = GETPOST('type');
|
||||
@@ -1660,13 +1670,15 @@ if (empty($reshook)) {
|
||||
//var_dump(price2num($price_min)); var_dump(price2num($pu_ht)); var_dump($remise_percent);
|
||||
//var_dump(price2num($price_min_ttc)); var_dump(price2num($pu_ttc)); var_dump($remise_percent);exit;
|
||||
|
||||
//$desc = dol_htmlcleanlastbr($desc);
|
||||
|
||||
// Check price is not lower than minimum
|
||||
if ($usermustrespectpricemin) {
|
||||
if ($pu_equivalent && $price_min && (((float) price2num($pu_equivalent) * (1 - $remise_percent / 100)) < price2num($price_min)) && $price_base_type == 'HT') {
|
||||
if ($pu_equivalent && $price_min && (((float) price2num($pu_equivalent) * (1 - $remise_percent / 100)) < (float) price2num($price_min)) && $price_base_type == 'HT') {
|
||||
$mesg = $langs->trans("CantBeLessThanMinPrice", price(price2num($price_min, 'MU'), 0, $langs, 0, 0, -1, $conf->currency));
|
||||
setEventMessages($mesg, null, 'errors');
|
||||
$error++;
|
||||
} elseif ($pu_equivalent_ttc && $price_min_ttc && (((float) price2num($pu_equivalent_ttc) * (1 - $remise_percent / 100)) < price2num($price_min_ttc)) && $price_base_type == 'TTC') {
|
||||
} elseif ($pu_equivalent_ttc && $price_min_ttc && (((float) price2num($pu_equivalent_ttc) * (1 - $remise_percent / 100)) < (float) price2num($price_min_ttc)) && $price_base_type == 'TTC') {
|
||||
$mesg = $langs->trans("CantBeLessThanMinPriceInclTax", price(price2num($price_min_ttc, 'MU'), 0, $langs, 0, 0, -1, $conf->currency));
|
||||
setEventMessages($mesg, null, 'errors');
|
||||
$error++;
|
||||
@@ -1675,12 +1687,12 @@ if (empty($reshook)) {
|
||||
|
||||
if (!$error) {
|
||||
// Insert line
|
||||
$result = $object->addline($desc, $pu_ht, (float) $qty, $tva_tx, $localtax1_tx, $localtax2_tx, $idprod, $remise_percent, $price_base_type, $pu_ttc, $info_bits, $type, min($rank, count($object->lines) + 1), 0, GETPOSTINT('fk_parent_line'), (int) $fournprice, $buyingprice, $label, $date_start, $date_end, $array_options, $fk_unit, '', 0, $pu_ht_devise);
|
||||
$result = $object->addline($desc, $pu_ht, (float) $qty, $tva_tx, $localtax1_tx, $localtax2_tx, $idprod, $remise_percent, $price_base_type, $pu_ttc, $info_bits, $type, min($rank, count($object->lines) + 1), 0, GETPOSTINT('fk_parent_line'), (int) $fournprice, $buyingprice, $label, $date_start, $date_end, $array_options, $fk_unit, '', 0, (float) $pu_ht_devise);
|
||||
|
||||
if ($result > 0) {
|
||||
$db->commit();
|
||||
|
||||
$ret = $object->fetch($id); // Reload to get new records
|
||||
$ret = $object->fetch($object->id); // Reload to get new records
|
||||
if ($ret > 0) {
|
||||
$object->fetch_thirdparty();
|
||||
}
|
||||
@@ -1688,9 +1700,12 @@ if (empty($reshook)) {
|
||||
if (!getDolGlobalString('MAIN_DISABLE_PDF_AUTOUPDATE')) {
|
||||
// Define output language
|
||||
$outputlangs = $langs;
|
||||
if (getDolGlobalInt('MAIN_MULTILANGS')) {
|
||||
$newlang = GETPOST('lang_id', 'alpha');
|
||||
if (getDolGlobalInt('MAIN_MULTILANGS') && empty($newlang)) {
|
||||
$newlang = $object->thirdparty->default_lang;
|
||||
}
|
||||
if (!empty($newlang)) {
|
||||
$outputlangs = new Translate("", $conf);
|
||||
$newlang = (GETPOST('lang_id', 'aZ09') ? GETPOST('lang_id', 'aZ09') : $object->thirdparty->default_lang);
|
||||
$outputlangs->setDefaultLang($newlang);
|
||||
}
|
||||
$object->generateDocument($object->model_pdf, $outputlangs, $hidedetails, $hidedesc, $hideref);
|
||||
@@ -1879,7 +1894,7 @@ if (empty($reshook)) {
|
||||
setEventMessages($object->error, $object->errors, 'errors');
|
||||
}
|
||||
} elseif ($action == 'updateline' && $usercancreate && GETPOST('save')) {
|
||||
// Update a line within proposal
|
||||
// Update a line
|
||||
|
||||
// Clean parameters
|
||||
$description = dol_htmlcleanlastbr(GETPOST('product_desc', 'restricthtml'));
|
||||
@@ -1891,7 +1906,7 @@ if (empty($reshook)) {
|
||||
}
|
||||
|
||||
// Define vat_rate
|
||||
$vat_rate = (GETPOST('tva_tx') ? GETPOST('tva_tx') : 0);
|
||||
$vat_rate = (GETPOST('tva_tx') ? GETPOST('tva_tx', 'alpha') : 0);
|
||||
$vat_rate = str_replace('*', '', $vat_rate);
|
||||
$localtax1_rate = get_localtax($vat_rate, 1, $object->thirdparty, $mysoc);
|
||||
$localtax2_rate = get_localtax($vat_rate, 2, $object->thirdparty, $mysoc);
|
||||
@@ -2738,7 +2753,7 @@ if ($action == 'create') {
|
||||
$formquestion[] = array('type' => 'date', 'name' => 'date_delivery', 'label' => $langs->trans("DeliveryDate"), 'value' => $object->delivery_date);
|
||||
}
|
||||
// Incomplete payment. We ask if reason = discount or other
|
||||
$formconfirm = $form->formconfirm(dolBuildUrl($_SERVER["PHP_SELF"], ['id' => $object->id]), $langs->trans('ToClone'), $langs->trans('ConfirmClonePropal', $object->ref), 'confirm_clone', $formquestion, 'yes', 1, 250, 600);
|
||||
$formconfirm = $form->formconfirm(dolBuildUrl($_SERVER["PHP_SELF"], ['id' => $object->id]), $langs->trans('ToClone'), $langs->trans('ConfirmClonePropal', $object->ref), 'confirm_clone', $formquestion, 'yes', 1, 0, 600);
|
||||
}
|
||||
|
||||
// Subtotal line form
|
||||
|
||||
@@ -159,7 +159,7 @@ $usercanclose = ((!getDolGlobalString('MAIN_USE_ADVANCED_PERMS') && !empt
|
||||
$usercanvalidate = ((!getDolGlobalString('MAIN_USE_ADVANCED_PERMS') && $usercancreate) || (getDolGlobalString('MAIN_USE_ADVANCED_PERMS') && $user->hasRight('commande', 'order_advance', 'validate')));
|
||||
$usercancancel = ((!getDolGlobalString('MAIN_USE_ADVANCED_PERMS') && $usercancreate) || (getDolGlobalString('MAIN_USE_ADVANCED_PERMS') && $user->hasRight('commande', 'order_advance', 'annuler')));
|
||||
$usercansend = (!getDolGlobalString('MAIN_USE_ADVANCED_PERMS') || $user->hasRight('commande', 'order_advance', 'send'));
|
||||
$usercangeneretedoc = (!getDolGlobalString('MAIN_USE_ADVANCED_PERMS') || $user->hasRight('commande', 'order_advance', 'generetedoc'));
|
||||
$usercangeneratedoc = (!getDolGlobalString('MAIN_USE_ADVANCED_PERMS') || $user->hasRight('commande', 'order_advance', 'generetedoc'));
|
||||
|
||||
$usermustrespectpricemin = ((getDolGlobalString('MAIN_USE_ADVANCED_PERMS') && !$user->hasRight('produit', 'ignore_price_min_advance')) || !getDolGlobalString('MAIN_USE_ADVANCED_PERMS'));
|
||||
$usercancreatepurchaseorder = ($user->hasRight('fournisseur', 'commande', 'creer') || $user->hasRight('supplier_order', 'creer'));
|
||||
@@ -966,10 +966,6 @@ if (empty($reshook)) {
|
||||
$price_ht_devise = '';
|
||||
$price_ttc = '';
|
||||
$price_ttc_devise = '';
|
||||
$pu_ht = '';
|
||||
$pu_ttc = '';
|
||||
$pu_ht_devise = '';
|
||||
$pu_ttc_devise = '';
|
||||
|
||||
if (GETPOST('price_ht') !== '') {
|
||||
$price_ht = price2num(GETPOST('price_ht'), 'MU', 2);
|
||||
@@ -1061,13 +1057,20 @@ if (empty($reshook)) {
|
||||
}
|
||||
|
||||
if (!$error && (!empty($line_desc) || (!empty($idprod) && $idprod > 0))) {
|
||||
$pu_ht = 0;
|
||||
$pu_ttc = 0;
|
||||
$pu_ht_devise = 0;
|
||||
$pu_ttc_devise = 0;
|
||||
$price_min = 0;
|
||||
$price_min_ttc = 0;
|
||||
$tva_npr = 0;
|
||||
$price_base_type = (GETPOST('price_base_type', 'alpha') ? GETPOST('price_base_type', 'alpha') : 'HT');
|
||||
|
||||
// Clean parameters
|
||||
$date_start = dol_mktime(GETPOSTINT('date_start' . $predef . 'hour'), GETPOSTINT('date_start' . $predef . 'min'), GETPOSTINT('date_start' . $predef . 'sec'), GETPOSTINT('date_start' . $predef . 'month'), GETPOSTINT('date_start' . $predef . 'day'), GETPOSTINT('date_start' . $predef . 'year'));
|
||||
$date_end = dol_mktime(GETPOSTINT('date_end' . $predef . 'hour'), GETPOSTINT('date_end' . $predef . 'min'), GETPOSTINT('date_end' . $predef . 'sec'), GETPOSTINT('date_end' . $predef . 'month'), GETPOSTINT('date_end' . $predef . 'day'), GETPOSTINT('date_end' . $predef . 'year'));
|
||||
$price_base_type = (GETPOST('price_base_type', 'alpha') ? GETPOST('price_base_type', 'alpha') : 'HT');
|
||||
|
||||
$price_min = $price_min_ttc = 0;
|
||||
$tva_npr = 0;
|
||||
$db->begin();
|
||||
|
||||
// Ecrase $pu par celui du produit
|
||||
// Ecrase $desc par celui du produit
|
||||
@@ -1085,6 +1088,7 @@ if (empty($reshook)) {
|
||||
$tva_npr = 0;
|
||||
}*/
|
||||
|
||||
// Price unique per product
|
||||
$pu_ht = $prod->price;
|
||||
$pu_ttc = $prod->price_ttc;
|
||||
$price_min = $prod->price_min;
|
||||
@@ -1103,6 +1107,7 @@ if (empty($reshook)) {
|
||||
$pricebycustomerexist = false;
|
||||
$result = $prodcustprice->fetchAll('', '', 0, 0, $filter);
|
||||
if ($result >= 0) {
|
||||
// If there is some prices specific to the customer
|
||||
if (count($prodcustprice->lines) > 0) {
|
||||
$date_now = (int) floor(dol_now() / 86400) * 86400; // date without hours
|
||||
foreach ($prodcustprice->lines as $k => $custprice_line) {
|
||||
@@ -1113,14 +1118,14 @@ if (empty($reshook)) {
|
||||
$price_min = price($custprice_line->price_min);
|
||||
$price_min_ttc = price($custprice_line->price_min_ttc);
|
||||
$price_base_type = $custprice_line->price_base_type;
|
||||
$tva_tx = $custprice_line->tva_tx;
|
||||
/*$tva_tx = $custprice_line->tva_tx;
|
||||
if ($custprice_line->default_vat_code && !preg_match('/\(.*\)/', (string) $tva_tx)) {
|
||||
$tva_tx .= ' (' . $custprice_line->default_vat_code . ')';
|
||||
}
|
||||
$tva_npr = $custprice_line->recuperableonly;
|
||||
if (empty($tva_tx)) {
|
||||
$tva_npr = 0;
|
||||
}
|
||||
}*/
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -1129,7 +1134,7 @@ if (empty($reshook)) {
|
||||
setEventMessages($prodcustprice->error, $prodcustprice->errors, 'errors');
|
||||
}
|
||||
|
||||
if (!$pricebycustomerexist && !empty($object->thirdparty->price_level)) { //// If price per segment
|
||||
if (!$pricebycustomerexist && !empty($object->thirdparty->price_level)) { // If price per segment
|
||||
$pu_ht = $prod->multiprices[$object->thirdparty->price_level];
|
||||
$pu_ttc = $prod->multiprices_ttc[$object->thirdparty->price_level];
|
||||
$price_min = $prod->multiprices_min[$object->thirdparty->price_level];
|
||||
@@ -1144,9 +1149,7 @@ if (empty($reshook)) {
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
// If price per segment
|
||||
if (getDolGlobalString('PRODUIT_MULTIPRICES') && !empty($object->thirdparty->price_level)) {
|
||||
} elseif (getDolGlobalString('PRODUIT_MULTIPRICES') && !empty($object->thirdparty->price_level)) { // If price per segment
|
||||
$pu_ht = $prod->multiprices[$object->thirdparty->price_level];
|
||||
$pu_ttc = $prod->multiprices_ttc[$object->thirdparty->price_level];
|
||||
$price_min = $prod->multiprices_min[$object->thirdparty->price_level];
|
||||
@@ -1170,6 +1173,7 @@ if (empty($reshook)) {
|
||||
|
||||
$result = $prodcustprice->fetchAll('', '', 0, 0, $filter);
|
||||
if ($result >= 0) {
|
||||
// If there is some prices specific to the customer
|
||||
if (count($prodcustprice->lines) > 0) {
|
||||
$date_now = (int) floor(dol_now() / 86400) * 86400; // date without hours
|
||||
foreach ($prodcustprice->lines as $k => $custprice_line) {
|
||||
@@ -1179,14 +1183,14 @@ if (empty($reshook)) {
|
||||
$price_min = price($custprice_line->price_min);
|
||||
$price_min_ttc = price($custprice_line->price_min_ttc);
|
||||
$price_base_type = $custprice_line->price_base_type;
|
||||
$tva_tx = $custprice_line->tva_tx;
|
||||
/*$tva_tx = $custprice_line->tva_tx;
|
||||
if ($custprice_line->default_vat_code && !preg_match('/\(.*\)/', $tva_tx)) {
|
||||
$tva_tx .= ' (' . $custprice_line->default_vat_code . ')';
|
||||
}
|
||||
$tva_npr = $custprice_line->recuperableonly;
|
||||
if (empty($tva_tx)) {
|
||||
$tva_npr = 0;
|
||||
}
|
||||
}*/
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -1241,18 +1245,28 @@ if (empty($reshook)) {
|
||||
$tmpprodvat = (float) price2num(preg_replace('/\s*\(.*\)/', '', (string) $prod->tva_tx));
|
||||
|
||||
// Set unit price to use
|
||||
if (!empty($price_ht) || $price_ht === '0') {
|
||||
if (!empty($price_ht) || (string) $price_ht === '0') {
|
||||
$pu_ht = (float) price2num($price_ht, 'MU');
|
||||
$pu_ttc = (float) price2num((float) $pu_ht * (1 + ($tmpvat / 100)), 'MU');
|
||||
} elseif (!empty($price_ttc) || $price_ttc === '0') {
|
||||
$pu_ttc = (float) price2num((float) $pu_ht * (1 + ((float) $tmpvat / 100)), 'MU');
|
||||
} elseif (!empty($price_ht_devise) || (string) $price_ht_devise === '0') {
|
||||
$pu_ht_devise = price2num($price_ht_devise, 'MU');
|
||||
$pu_ttc_devise = (float) price2num((float) $pu_ht_devise * (1 + ((float) $tmpvat / 100)), 'MU');
|
||||
$pu_ht = '';
|
||||
$pu_ttc = '';
|
||||
} elseif (!empty($price_ttc) || (string) $price_ttc === '0') {
|
||||
$pu_ttc = (float) price2num($price_ttc, 'MU');
|
||||
$pu_ht = (float) price2num((float) $pu_ttc / (1 + ($tmpvat / 100)), 'MU');
|
||||
$pu_ht = (float) price2num((float) $pu_ttc / (1 + ((float) $tmpvat / 100)), 'MU');
|
||||
} elseif (!empty($price_ttc_devise) || (string) $price_ttc_devise === '0') {
|
||||
$pu_ttc_devise = (float) price2num($price_ttc_devise, 'MU');
|
||||
$pu_ht_devise = (float) price2num((float) $pu_ttc_devise / (1 + ((float) $tmpvat / 100)), 'MU');
|
||||
$pu_ht = '';
|
||||
$pu_ttc = '';
|
||||
} elseif ($tmpvat != $tmpprodvat) {
|
||||
// Is this still used ?
|
||||
if ($price_base_type != 'HT') {
|
||||
$pu_ht = (float) price2num($pu_ttc / (1 + ($tmpvat / 100)), 'MU');
|
||||
$pu_ht = (float) price2num((float) $pu_ttc / (1 + ((float) $tmpvat / 100)), 'MU');
|
||||
} else {
|
||||
$pu_ttc = (float) price2num($pu_ht * (1 + ($tmpvat / 100)), 'MU');
|
||||
$pu_ttc = (float) price2num((float) $pu_ht * (1 + ((float) $tmpvat / 100)), 'MU');
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1356,12 +1370,12 @@ if (empty($reshook)) {
|
||||
}
|
||||
|
||||
// Local Taxes
|
||||
$localtax1_tx = get_localtax($tva_tx, 1, $object->thirdparty);
|
||||
$localtax2_tx = get_localtax($tva_tx, 2, $object->thirdparty);
|
||||
$localtax1_tx = get_localtax($tva_tx, 1, $object->thirdparty, $mysoc, $tva_npr);
|
||||
$localtax2_tx = get_localtax($tva_tx, 2, $object->thirdparty, $mysoc, $tva_npr);
|
||||
|
||||
// Margin
|
||||
$fournprice = (int) (GETPOST('fournprice' . $predef) ? GETPOSTINT('fournprice' . $predef) : 0); // This can be id of supplier price, or 'pmpprice' or 'costprice', or 'inputprice', we force to keep ID only
|
||||
$buyingprice = price2num(GETPOST('buying_price' . $predef) != '' ? GETPOST('buying_price' . $predef) : ''); // If buying_price is '0', we must keep this value
|
||||
$fournprice = (int) (GETPOST('fournprice'.$predef) ? GETPOST('fournprice'.$predef) : 0); // This can be id of supplier price, or 'pmpprice' or 'costprice', or 'inputprice', we force to keep ID only
|
||||
$buyingprice = price2num((GETPOST('buying_price'.$predef) != '' ? GETPOST('buying_price'.$predef) : ''), '', 2); // If buying_price is '0', we must keep this value
|
||||
|
||||
// Prepare a price equivalent for minimum price check
|
||||
$pu_equivalent = $pu_ht;
|
||||
@@ -1378,7 +1392,7 @@ if (empty($reshook)) {
|
||||
$pu_equivalent_ttc = (float) $pu_ttc_devise / (float) $currency_tx;
|
||||
}
|
||||
|
||||
// TODO $pu_equivalent or $pu_equivalent_ttc must be calculated from the one defined
|
||||
// TODO $pu_equivalent or $pu_equivalent_ttc must be calculated from the one not null taking into account all taxes
|
||||
/*
|
||||
if ($pu_equivalent) {
|
||||
$tmp = calcul_price_total(1, $pu_equivalent, 0, $tva_tx, -1, -1, 0, 'HT', $info_bits, $type);
|
||||
@@ -1389,6 +1403,9 @@ if (empty($reshook)) {
|
||||
}
|
||||
*/
|
||||
|
||||
//var_dump(price2num($price_min)); var_dump(price2num($pu_ht)); var_dump($remise_percent);
|
||||
//var_dump(price2num($price_min_ttc)); var_dump(price2num($pu_ttc)); var_dump($remise_percent);exit;
|
||||
|
||||
$desc = dol_htmlcleanlastbr($desc);
|
||||
|
||||
// Check price is not lower than minimum
|
||||
@@ -1409,8 +1426,12 @@ if (empty($reshook)) {
|
||||
$result = $object->addline($desc, $pu_ht, (float) $qty, $tva_tx, $localtax1_tx, $localtax2_tx, $idprod, $remise_percent, $info_bits, 0, $price_base_type, $pu_ttc, $date_start, $date_end, $type, min($rank, count($object->lines) + 1), 0, GETPOSTINT('fk_parent_line'), (int) $fournprice, $buyingprice, $label, $array_options, $fk_unit, '', 0, (float) $pu_ht_devise);
|
||||
|
||||
if ($result > 0) {
|
||||
$db->commit();
|
||||
|
||||
$ret = $object->fetch($object->id); // Reload to get new records
|
||||
$object->fetch_thirdparty();
|
||||
if ($ret > 0) {
|
||||
$object->fetch_thirdparty();
|
||||
}
|
||||
|
||||
if (!getDolGlobalString('MAIN_DISABLE_PDF_AUTOUPDATE')) {
|
||||
// Define output language
|
||||
@@ -1460,6 +1481,8 @@ if (empty($reshook)) {
|
||||
unset($_POST['date_endmonth']);
|
||||
unset($_POST['date_endyear']);
|
||||
} else {
|
||||
$db->rollback();
|
||||
|
||||
setEventMessages($object->error, $object->errors, 'errors');
|
||||
}
|
||||
}
|
||||
@@ -1551,6 +1574,7 @@ if (empty($reshook)) {
|
||||
}
|
||||
} elseif ($action == 'updateline' && $usercancreate && GETPOST('save')) {
|
||||
// Update a line
|
||||
|
||||
// Clean parameters
|
||||
$date_start = '';
|
||||
$date_end = '';
|
||||
@@ -1619,15 +1643,15 @@ if (empty($reshook)) {
|
||||
}
|
||||
|
||||
// Define special_code for special lines
|
||||
$special_code = GETPOST('special_code');
|
||||
$special_code = GETPOSTINT('special_code');
|
||||
if (!GETPOST('qty')) {
|
||||
$special_code = 3;
|
||||
}
|
||||
|
||||
$remise_percent = GETPOST('remise_percent') != '' ? price2num(GETPOST('remise_percent'), '', 2) : 0;
|
||||
|
||||
$price_base_type = 'HT';
|
||||
$pu = $pu_ht;
|
||||
$price_base_type = 'HT';
|
||||
if (empty($pu) && !empty($pu_ttc)) {
|
||||
$pu = $pu_ttc;
|
||||
$price_base_type = 'TTC';
|
||||
@@ -1654,12 +1678,12 @@ if (empty($reshook)) {
|
||||
|
||||
// Check price is not lower than minimum
|
||||
if ($usermustrespectpricemin) {
|
||||
if ($pu_equivalent && $price_min && (((float) price2num($pu_equivalent) * (1 - $remise_percent / 100)) < (float) price2num($price_min)) && $price_base_type == 'HT') {
|
||||
if ($pu_equivalent && $price_min && (((float) price2num($pu_equivalent) * (1 - (float) $remise_percent / 100)) < (float) price2num($price_min)) && $price_base_type == 'HT') {
|
||||
$mesg = $langs->trans("CantBeLessThanMinPrice", price(price2num($price_min, 'MU'), 0, $langs, 0, 0, -1, $conf->currency));
|
||||
setEventMessages($mesg, null, 'errors');
|
||||
$error++;
|
||||
$action = 'editline';
|
||||
} elseif ($pu_equivalent_ttc && $price_min_ttc && (((float) price2num($pu_equivalent_ttc) * (1 - $remise_percent / 100)) < (float) price2num($price_min_ttc)) && $price_base_type == 'TTC') {
|
||||
} elseif ($pu_equivalent_ttc && $price_min_ttc && (((float) price2num($pu_equivalent_ttc) * (1 - (float) $remise_percent / 100)) < (float) price2num($price_min_ttc)) && $price_base_type == 'TTC') {
|
||||
$mesg = $langs->trans("CantBeLessThanMinPriceInclTax", price(price2num($price_min_ttc, 'MU'), 0, $langs, 0, 0, -1, $conf->currency));
|
||||
setEventMessages($mesg, null, 'errors');
|
||||
$error++;
|
||||
@@ -1694,6 +1718,8 @@ if (empty($reshook)) {
|
||||
}
|
||||
|
||||
if (!$error) {
|
||||
$db->begin();
|
||||
|
||||
if (!$user->hasRight('margins', 'creer')) {
|
||||
foreach ($object->lines as &$line) {
|
||||
if ($line->id == GETPOSTINT('lineid')) {
|
||||
@@ -1704,9 +1730,13 @@ if (empty($reshook)) {
|
||||
}
|
||||
}
|
||||
|
||||
$qty = price2num(GETPOST('qty', 'alpha'), 'MS');
|
||||
|
||||
$result = $object->updateline(GETPOSTINT('lineid'), $description, (float) $pu, (float) $qty, $remise_percent, $vat_rate, $localtax1_rate, $localtax2_rate, $price_base_type, $info_bits, $date_start, $date_end, $type, GETPOSTINT('fk_parent_line'), 0, (int) $fournprice, $buyingprice, $label, $special_code, $array_options, GETPOSTINT('units'), (float) $pu_ht_devise);
|
||||
|
||||
if ($result >= 0) {
|
||||
$db->commit();
|
||||
|
||||
if (!getDolGlobalString('MAIN_DISABLE_PDF_AUTOUPDATE')) {
|
||||
// Define output language
|
||||
$outputlangs = $langs;
|
||||
@@ -1753,6 +1783,8 @@ if (empty($reshook)) {
|
||||
unset($_POST['date_endmonth']);
|
||||
unset($_POST['date_endyear']);
|
||||
} else {
|
||||
$db->rollback();
|
||||
|
||||
setEventMessages($object->error, $object->errors, 'errors');
|
||||
}
|
||||
}
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
* Copyright (C) 2021 Gauthier VERDOL <gauthier.verdol@atm-consulting.fr>
|
||||
* Copyright (C) 2024-2025 MDW <mdeweerd@users.noreply.github.com>
|
||||
* Copyright (C) 2024-2025 Frédéric France <frederic.france@free.fr>
|
||||
* Copyright (C) 2026 Nick Fragoulis
|
||||
*
|
||||
* 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
|
||||
@@ -145,8 +146,8 @@ print '<span class="opacitymedium">'.$langs->trans("DescTaxAndDividendsArea").'<
|
||||
print "<br>";
|
||||
|
||||
if (isModEnabled('tax') && $user->hasRight('tax', 'charges', 'lire')) {
|
||||
$sql = "SELECT c.id, c.libelle as label,";
|
||||
$sql .= " cs.rowid, cs.libelle, cs.fk_type as type, cs.periode as period, cs.date_ech, cs.amount as total,";
|
||||
$sql = "SELECT c.id, c.libelle as type_label,";
|
||||
$sql .= " cs.rowid, cs.libelle as label, cs.fk_type as type, cs.periode as period, cs.date_ech, cs.amount as total,";
|
||||
$sql .= " pc.rowid as pid, pc.datep, pc.amount as totalpaid, pc.num_paiement as num_payment, pc.fk_bank,";
|
||||
$sql .= " pct.code as payment_code,";
|
||||
$sql .= " ba.rowid as bid, ba.ref as bref, ba.number as bnumber, ba.account_number, ba.fk_accountancy_journal, ba.label as blabel";
|
||||
@@ -160,7 +161,7 @@ if (isModEnabled('tax') && $user->hasRight('tax', 'charges', 'lire')) {
|
||||
$sql .= " AND cs.entity IN (".getEntity("tax").")";
|
||||
if ($year > 0) {
|
||||
$sql .= " AND (";
|
||||
// If period defined, we use it as dat criteria, if not we use date echeance,
|
||||
// If period defined, we use it as date criteria, if not we use date echeance,
|
||||
// so we are compatible when period is not mandatory
|
||||
$sql .= " (cs.periode IS NOT NULL AND cs.periode between '".$db->idate(dol_get_first_day($year))."' AND '".$db->idate(dol_get_last_day($year))."')";
|
||||
$sql .= " OR (cs.periode IS NULL AND cs.date_ech between '".$db->idate(dol_get_first_day($year))."' AND '".$db->idate(dol_get_last_day($year))."')";
|
||||
@@ -184,8 +185,8 @@ if (isModEnabled('tax') && $user->hasRight('tax', 'charges', 'lire')) {
|
||||
print '<table class="noborder centpercent">';
|
||||
print '<tr class="liste_titre">';
|
||||
print_liste_field_titre("PeriodEndDate", $_SERVER["PHP_SELF"], "cs.date_ech", "", $param, 'width="120"', $sortfield, $sortorder, 'nowraponall ');
|
||||
print_liste_field_titre("Label", $_SERVER["PHP_SELF"], "c.libelle", "", $param, '', $sortfield, $sortorder);
|
||||
print_liste_field_titre("Type", $_SERVER["PHP_SELF"], "cs.fk_type", "", $param, '', $sortfield, $sortorder);
|
||||
print_liste_field_titre("Label", $_SERVER["PHP_SELF"], "cs.libelle", "", $param, '', $sortfield, $sortorder);
|
||||
print_liste_field_titre("Type", $_SERVER["PHP_SELF"], "c.libelle", "", $param, '', $sortfield, $sortorder);
|
||||
print_liste_field_titre("ExpectedToPay", $_SERVER["PHP_SELF"], "cs.amount", "", $param, 'class="right"', $sortfield, $sortorder);
|
||||
print_liste_field_titre("RefPayment", $_SERVER["PHP_SELF"], "pc.rowid", "", $param, '', $sortfield, $sortorder);
|
||||
print_liste_field_titre("DatePayment", $_SERVER["PHP_SELF"], "pc.datep", "", $param, 'align="center"', $sortfield, $sortorder);
|
||||
@@ -221,7 +222,7 @@ if (isModEnabled('tax') && $user->hasRight('tax', 'charges', 'lire')) {
|
||||
print $socialcontrib->getNomUrl(1, '20');
|
||||
print '</td>';
|
||||
// Type
|
||||
print '<td class="tdoverflowmax200"><a href="'.DOL_URL_ROOT.'/compta/sociales/list.php?filtre=cs.fk_type:'.$obj->type.'">'.$obj->label.'</a></td>';
|
||||
print '<td class="tdoverflowmax200"><a href="'.DOL_URL_ROOT.'/compta/sociales/list.php?filtre=cs.fk_type:'.$obj->type.'">'.$obj->type_label.'</a></td>';
|
||||
// Expected to pay
|
||||
print '<td class="right"><span class="amount">'.price($obj->total).'</span></td>';
|
||||
// Ref payment
|
||||
@@ -275,7 +276,7 @@ if (isModEnabled('tax') && $user->hasRight('tax', 'charges', 'lire')) {
|
||||
|
||||
print '<td colspan="3" class="liste_total">'.$langs->trans("Total").'</td>';
|
||||
|
||||
// Total here has no sens because we can have several time the same line
|
||||
// Total here makes no sense because we can have the same line several times.
|
||||
//print '<td class="liste_total right">'.price($total).'</td>';
|
||||
print '<td class="liste_total right"></td>';
|
||||
|
||||
@@ -306,7 +307,7 @@ if (isModEnabled('tax') && $user->hasRight('tax', 'charges', 'lire')) {
|
||||
$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."c_paiement as pct ON ptva.fk_typepaiement = pct.id";
|
||||
$sql .= " WHERE pv.entity IN (".getEntity("tax").")";
|
||||
if ($year > 0) {
|
||||
// If period defined, we use it as dat criteria, if not we use date echeance,
|
||||
// If period defined, we use it as date criteria, if not we use date echeance,
|
||||
// so we are compatible when period is not mandatory
|
||||
$sql .= " AND pv.datev between '".$db->idate(dol_get_first_day($year, 1, false))."' AND '".$db->idate(dol_get_last_day($year, 12, false))."'";
|
||||
}
|
||||
@@ -410,7 +411,7 @@ if (isModEnabled('tax') && $user->hasRight('tax', 'charges', 'lire')) {
|
||||
|
||||
print '<td class="liste_total" colspan="2">'.$langs->trans("Total").'</td>';
|
||||
|
||||
// Total here has no sens because we can have several time the same line
|
||||
// Total here makes no sense because we can have the same line several times.
|
||||
//print '<td class="right">'.price($totaltopay).'</td>';
|
||||
print '<td class="liste_total"> </td>';
|
||||
|
||||
@@ -461,7 +462,7 @@ while ($j < $numlt) {
|
||||
$sql .= " FROM ".MAIN_DB_PREFIX."localtax as pv";
|
||||
$sql .= " WHERE pv.entity = ".$conf->entity." AND localtaxtype = ".((int) $j);
|
||||
if ($year > 0) {
|
||||
// If period defined, we use it as dat criteria, if not we use date echeance,
|
||||
// If period defined, we use it as date criteria, if not we use date echeance,
|
||||
// so we are compatible when period is not mandatory
|
||||
$sql .= " AND pv.datev between '".$db->idate(dol_get_first_day($year, 1, false))."' AND '".$db->idate(dol_get_last_day($year, 12, false))."'";
|
||||
}
|
||||
|
||||
@@ -56,7 +56,7 @@ require_once DOL_DOCUMENT_ROOT.'/core/class/extrafields.class.php';
|
||||
// Load translation files required by the page
|
||||
$langs->loadLangs(array('bills', 'companies', 'compta', 'admin', 'other', 'products', 'banks'));
|
||||
|
||||
$action = GETPOST('action', 'alpha');
|
||||
$action = GETPOST('action', 'aZ09');
|
||||
$massaction = GETPOST('massaction', 'alpha');
|
||||
$show_files = GETPOSTINT('show_files');
|
||||
$confirm = GETPOST('confirm', 'alpha');
|
||||
@@ -1634,7 +1634,7 @@ if ($action == 'create') {
|
||||
}
|
||||
|
||||
// Author
|
||||
print '<tr><td class="titlefield">'.$langs->trans("Author").'</td><td>';
|
||||
print '<tr><td class="titlefieldmiddle">'.$langs->trans("Author").'</td><td>';
|
||||
print $author->getNomUrl(-1);
|
||||
print "</td></tr>";
|
||||
|
||||
@@ -2192,13 +2192,14 @@ if ($action == 'create') {
|
||||
|
||||
$MAXEVENT = 10;
|
||||
|
||||
//$morehtmlcenter = dolGetButtonTitle($langs->trans('SeeAll'), '', 'fa fa-bars imgforviewmode', dol_buildpath('/mymodule/myobject_agenda.php', 1).'?id='.$object->id);
|
||||
$morehtmlcenter = '';
|
||||
$morehtmlcenter = '<div class="nowraponall">';
|
||||
//$morehtmlcenter .= dolGetButtonTitle($langs->trans('FullConversation'), '', 'fa fa-comments imgforviewmode', DOL_URL_ROOT.'/compta/facture/messaging.php?id='.$object->id);
|
||||
$morehtmlcenter .= dolGetButtonTitle($langs->trans('FullList'), '', 'fa fa-bars imgforviewmode', DOL_URL_ROOT.'/compta/facture/agenda-rec.php?id='.$object->id);
|
||||
$morehtmlcenter .= '</div>';
|
||||
|
||||
// List of actions on element
|
||||
include_once DOL_DOCUMENT_ROOT.'/core/class/html.formactions.class.php';
|
||||
$formactions = new FormActions($db);
|
||||
$morehtmlcenter = '';
|
||||
$somethingshown = $formactions->showactions($object, $object->element, (is_object($object->thirdparty) ? $object->thirdparty->id : 0), 1, '', $MAXEVENT, '', $morehtmlcenter);
|
||||
|
||||
print '</div>';
|
||||
|
||||
@@ -41,7 +41,7 @@
|
||||
* \brief Page to create/see an invoice
|
||||
*/
|
||||
|
||||
// Libraries
|
||||
// Load Dolibarr environment
|
||||
require '../../main.inc.php';
|
||||
/**
|
||||
* @var Conf $conf
|
||||
@@ -91,14 +91,15 @@ if (isModEnabled('margin')) {
|
||||
}
|
||||
|
||||
// General $Variables
|
||||
$id = (GETPOSTINT('id') ? GETPOSTINT('id') : GETPOSTINT('facid')); // For backward compatibility
|
||||
$ref = GETPOST('ref', 'alpha');
|
||||
$socid = GETPOSTINT('socid');
|
||||
$action = GETPOST('action', 'aZ09');
|
||||
$confirm = GETPOST('confirm', 'alpha');
|
||||
$cancel = GETPOST('cancel', 'alpha');
|
||||
$backtopage = GETPOST('backtopage', 'alpha'); // if not set, a default page will be used
|
||||
$backtopageforcancel = GETPOST('backtopageforcancel', 'alpha'); // if not set, $backtopage will be used
|
||||
|
||||
$id = (GETPOSTINT('id') ? GETPOSTINT('id') : GETPOSTINT('facid')); // For backward compatibility
|
||||
$ref = GETPOST('ref', 'alpha');
|
||||
$socid = GETPOSTINT('socid');
|
||||
$lineid = GETPOSTINT('lineid');
|
||||
$origin = GETPOST('origin', 'alpha');
|
||||
$originid = (GETPOSTINT('originid') ? GETPOSTINT('originid') : GETPOSTINT('origin_id')); // For backward compatibility
|
||||
@@ -2634,11 +2635,17 @@ if (empty($reshook)) {
|
||||
$pu_ttc = price2num((float) $pu_ht * (1 + ($tmpvat / 100)), 'MU');
|
||||
} elseif (!empty($price_ht_devise) || $price_ht_devise === '0') {
|
||||
$pu_ht_devise = price2num($price_ht_devise, 'MU');
|
||||
$pu_ttc_devise = (float) price2num((float) $pu_ht_devise * (1 + ((float) $tmpvat / 100)), 'MU');
|
||||
$pu_ht = '';
|
||||
$pu_ttc = '';
|
||||
} elseif (!empty($price_ttc) || $price_ttc === '0') {
|
||||
$pu_ttc = price2num($price_ttc, 'MU');
|
||||
$pu_ht = price2num((float) $pu_ttc / (1 + ($tmpvat / 100)), 'MU');
|
||||
} elseif (!empty($price_ttc_devise) || (string) $price_ttc_devise === '0') {
|
||||
$pu_ttc_devise = (float) price2num($price_ttc_devise, 'MU');
|
||||
$pu_ht_devise = (float) price2num((float) $pu_ttc_devise / (1 + ((float) $tmpvat / 100)), 'MU');
|
||||
$pu_ht = '';
|
||||
$pu_ttc = '';
|
||||
} elseif ($tmpvat != $tmpprodvat) {
|
||||
// Is this still used ?
|
||||
if ($price_base_type != 'HT') {
|
||||
|
||||
@@ -672,8 +672,8 @@ class ChargeSociales extends CommonObject
|
||||
if (isset($this->paye)) {
|
||||
$label .= ' '.$this->getLibStatut(5);
|
||||
}
|
||||
if (!empty($this->ref)) {
|
||||
$label .= '<br><b>'.$langs->trans('Ref').':</b> '.$this->ref;
|
||||
if (!empty($this->id)) {
|
||||
$label .= '<br><b>'.$langs->trans('Ref').':</b> '.$this->id;
|
||||
}
|
||||
if (!empty($this->label)) {
|
||||
$label .= '<br><b>'.$langs->trans('Label').':</b> '.$this->label;
|
||||
|
||||
@@ -58,7 +58,7 @@ if (!empty($permissioncreate) && empty($permissiontoadd)) {
|
||||
}
|
||||
|
||||
// Build doc
|
||||
if ($action == 'builddoc' && ($permissiontoadd || !empty($usercangeneretedoc))) {
|
||||
if ($action == 'builddoc' && ($permissiontoadd || !empty($usercangeneratedoc))) {
|
||||
if (is_numeric(GETPOST('model', 'alpha'))) {
|
||||
setEventMessages($langs->trans("ErrorFieldRequired", $langs->transnoentities("Model")), null, 'errors');
|
||||
} else {
|
||||
|
||||
@@ -145,8 +145,8 @@ class CLeadStatus extends CommonDict
|
||||
if ($id) {
|
||||
$sql_where[] = " t.rowid = ".((int) $id);
|
||||
}
|
||||
if ($code >= 0) {
|
||||
$sql_where[] = " t.code = ".((int) $code);
|
||||
if ($code) {
|
||||
$sql_where[] = " t.code = '".$this->db->escape($code)."'";
|
||||
}
|
||||
if (count($sql_where) > 0) {
|
||||
$sql .= ' WHERE '.implode(' AND ', $sql_where);
|
||||
|
||||
@@ -1357,6 +1357,12 @@ class Conf extends stdClass
|
||||
$this->global->MAIN_DISALLOW_UNSECURED_SELECT_INTO_EXTRAFIELDS_FILTER = 0; // TODO Move this into 1 by default
|
||||
}
|
||||
|
||||
if (getDolGlobalString('PRODUIT_MULTIPRICES') || getDolGlobalString('PRODUIT_CUSTOMER_PRICES_BY_QTY_MULTIPRICES') || getDolGlobalString('PRODUIT_CUSTOMER_PRICES_AND_MULTIPRICES')) {
|
||||
// In on of this customer price modes, option PRODUCT_USE_CUSTOMER_PACKAGING is not implemented/supported, so we disable it
|
||||
$this->global->PRODUCT_USE_CUSTOMER_PACKAGING = 0;
|
||||
}
|
||||
|
||||
|
||||
// For backward compatibility
|
||||
if (!empty($this->global->LDAP_SYNCHRO_ACTIVE)) {
|
||||
if ($this->global->LDAP_SYNCHRO_ACTIVE == 'dolibarr2ldap') {
|
||||
|
||||
@@ -2667,7 +2667,8 @@ class Form
|
||||
$out .= '})</script>';
|
||||
$out .= img_picto('', 'user', 'class="pictofixedwidth"');
|
||||
$out .= $this->select_dolusers('', $htmlname, $show_empty, $exclude, $disabled, $include, $enableonly, $force_entity, $maxlength, $showstatus, $morefilter, 0, '', 'minwidth200');
|
||||
$out .= ' <input type="submit" disabled class="button valignmiddle smallpaddingimp reposition" id="' . $action . 'assignedtouser" name="' . $action . 'assignedtouser" value="' . dol_escape_htmltag($langs->trans("Add")) . '">';
|
||||
$out .= ' <button type="submit" disabled class="button valignmiddle smallpaddingimp reposition butActionAdd" id="' . $action . 'assignedtouser" name="' . $action . 'assignedtouser" value="' . dol_escape_htmltag($langs->trans("Add")) . '">';
|
||||
$out .= $langs->trans("Add").'</button>';
|
||||
$out .= '</div>';
|
||||
//$out .= '<br>';
|
||||
}
|
||||
@@ -2769,7 +2770,9 @@ class Form
|
||||
}
|
||||
$out .= $formresources->select_resource_list(0, $htmlname, '', 1, 1, 0, $events, '', 2, 0, 'minwidth200');
|
||||
//$out .= $this->select_dolusers('', $htmlname, $show_empty, $exclude, $disabled, $include, $enableonly, $force_entity, $maxlength, $showstatus, $morefilter);
|
||||
$out .= ' <input type="submit" disabled class="button valignmiddle smallpaddingimp reposition" id="' . $action . 'assignedtoresource" name="' . $action . 'assignedtoresource" value="' . dol_escape_htmltag($langs->trans("Add")) . '">';
|
||||
$out .= ' <button type="submit" disabled class="button valignmiddle smallpaddingimp reposition butActionAdd" id="' . $action . 'assignedtoresource" name="' . $action . 'assignedtoresource" value="' . dol_escape_htmltag($langs->trans("Add")) . '">';
|
||||
$out .= $langs->trans("Add");
|
||||
$out .= '</button>';
|
||||
$out .= '<br>';
|
||||
}
|
||||
|
||||
@@ -6979,7 +6982,7 @@ class Form
|
||||
global $conf, $langs;
|
||||
|
||||
if ($htmlname != "none") {
|
||||
print '<form method="post" action="' . $page . '">';
|
||||
print '<form method="post" action="' . $page . '" class="inline-block">';
|
||||
print '<input type="hidden" name="action" value="setabsolutediscount">';
|
||||
print '<input type="hidden" name="token" value="' . newToken() . '">';
|
||||
print '<div class="inline-block">';
|
||||
@@ -11086,21 +11089,22 @@ class Form
|
||||
/**
|
||||
* Return HTML code to output a photo
|
||||
*
|
||||
* @param string $modulepart Key to define module concerned ('societe', 'userphoto', 'memberphoto')
|
||||
* @param Societe|Adherent|Contact|User|CommonObject $object Object containing data to retrieve file name
|
||||
* @param int $width Width of photo
|
||||
* @param int $height Height of photo (auto if 0)
|
||||
* @param int<0,1> $caneditfield Add edit fields
|
||||
* @param string $cssclass CSS name to use on img for photo
|
||||
* @param string $imagesize 'mini', 'small' or '' (original)
|
||||
* @param int<0,1> $addlinktofullsize Add link to fullsize image
|
||||
* @param int<0,1> $cache 1=Accept to use image in cache
|
||||
* @param ''|'user'|'environment' $forcecapture '', 'user' (user-facing camera) or 'environment' ('outward-facing camera'). Force the parameter capture on HTML input file element to ask a smartphone to allow to open camera to take photo. Auto if ''.
|
||||
* @param int<0,1> $noexternsourceoverwrite No overwrite image with extern source (like 'gravatar' or other module)
|
||||
* @return string HTML code to output photo
|
||||
* @param string $modulepart Key to define module concerned ('societe', 'userphoto', 'memberphoto')
|
||||
* @param Societe|Adherent|Contact|User|CommonObject $object Object containing data to retrieve file name
|
||||
* @param int $width Width of photo
|
||||
* @param int $height Height of photo (auto if 0)
|
||||
* @param int<0,1> $caneditfield Add edit fields
|
||||
* @param string $cssclass CSS name to use on img for photo
|
||||
* @param string $imagesize 'mini', 'small' or '' (original)
|
||||
* @param int<0,1> $addlinktofullsize Add link to fullsize image
|
||||
* @param int<0,1> $cache 1=Accept to use image in cache
|
||||
* @param ''|'user'|'environment' $forcecapture '', 'user' (user-facing camera) or 'environment' ('outward-facing camera'). Force the parameter capture on HTML input file element to ask a smartphone to allow to open camera to take photo. Auto if ''.
|
||||
* @param int<0,1> $noexternsourceoverwrite No overwrite image with extern source (like 'gravatar' or other module)
|
||||
* @param int<0,1> $usesharelinkifavailable Use 1 to use the share=key link if available. This is slower.
|
||||
* @return string HTML code to output photo
|
||||
* @see getImagePublicURLOfObject()
|
||||
*/
|
||||
public static function showphoto($modulepart, $object, $width = 100, $height = 0, $caneditfield = 0, $cssclass = 'photowithmargin', $imagesize = '', $addlinktofullsize = 1, $cache = 0, $forcecapture = '', $noexternsourceoverwrite = 0)
|
||||
public static function showphoto($modulepart, $object, $width = 100, $height = 0, $caneditfield = 0, $cssclass = 'photowithmargin', $imagesize = '', $addlinktofullsize = 1, $cache = 0, $forcecapture = '', $noexternsourceoverwrite = 0, $usesharelinkifavailable = 0)
|
||||
{
|
||||
global $conf, $db, $langs;
|
||||
|
||||
@@ -11207,10 +11211,6 @@ class Form
|
||||
$ret = '';
|
||||
|
||||
if ($dir) {
|
||||
require_once DOL_DOCUMENT_ROOT . '/ecm/class/ecmfiles.class.php';
|
||||
$ecmfiles = new EcmFiles($db);
|
||||
$relativefile = str_replace(DOL_DATA_ROOT .'/', '', $dir.'/'.$originalfile);
|
||||
$ecmfiles->fetch(0, '', $relativefile);
|
||||
if ($file && file_exists($dir . "/" . $file)) {
|
||||
if ($addlinktofullsize) {
|
||||
$urladvanced = getAdvancedPreviewUrl($modulepart, $originalfile, 0, '&entity=' . $entity);
|
||||
@@ -11220,8 +11220,21 @@ class Form
|
||||
$ret .= '<a href="' . DOL_URL_ROOT . '/viewimage.php?modulepart=' . $modulepart . '&entity=' . $entity . '&file=' . urlencode($originalfile) . '&cache=' . $cache . '">';
|
||||
}
|
||||
}
|
||||
if (!empty($ecmfiles->share)) {
|
||||
$ret .= '<img alt="" class="photo' . $modulepart . ($cssclass ? ' ' . $cssclass : '') . ' photologo' . (preg_replace('/[^a-z]/i', '_', $file)) . '" ' . ($width ? ' width="' . $width . '"' : '') . ($height ? ' height="' . $height . '"' : '') . ' src="' . DOL_URL_ROOT . '/viewimage.php?hashp=' . urlencode($ecmfiles->share) . '&cache=' . $cache . '">';
|
||||
|
||||
$sharekey = '';
|
||||
if ($usesharelinkifavailable) {
|
||||
// $dir is a full path '/home/.../dolibarr_documents/module'
|
||||
$relativefileforecm = preg_replace('/^'.preg_quote(DOL_DATA_ROOT.'/', '/').'/', '', $dir.'/'.$originalfile);
|
||||
// $relativefileforecme = 'module/...'
|
||||
require_once DOL_DOCUMENT_ROOT . '/ecm/class/ecmfiles.class.php';
|
||||
$ecmfiles = new EcmFiles($db);
|
||||
$ecmfiles->fetch(0, '', $relativefileforecm);
|
||||
|
||||
$sharekey = (string) $ecmfiles->share;
|
||||
}
|
||||
|
||||
if (!empty($sharekey)) {
|
||||
$ret .= '<img alt="" class="photo' . $modulepart . ($cssclass ? ' ' . $cssclass : '') . ' photologo' . (preg_replace('/[^a-z]/i', '_', $file)) . '" ' . ($width ? ' width="' . $width . '"' : '') . ($height ? ' height="' . $height . '"' : '') . ' src="' . DOL_URL_ROOT . '/viewimage.php?hashp=' . urlencode($sharekey) . '&cache=' . urlencode((string) $cache) . '">';
|
||||
} else {
|
||||
$ret .= '<img alt="" class="photo' . $modulepart . ($cssclass ? ' ' . $cssclass : '') . ' photologo' . (preg_replace('/[^a-z]/i', '_', $file)) . '" ' . ($width ? ' width="' . $width . '"' : '') . ($height ? ' height="' . $height . '"' : '') . ' src="' . DOL_URL_ROOT . '/viewimage.php?modulepart=' . $modulepart . '&entity=' . $entity . '&file=' . urlencode($file) . '&cache=' . $cache . '">';
|
||||
}
|
||||
|
||||
@@ -276,7 +276,7 @@ class FormActions
|
||||
print getTitleFieldOfList('Ref', 0, $_SERVER["PHP_SELF"], '', (string) $page, $param, '', $sortfield, $sortorder, '', 1);
|
||||
print getTitleFieldOfList('Date', 0, $_SERVER["PHP_SELF"], 'a.datep', (string) $page, $param, '', $sortfield, $sortorder, 'center ', 1);
|
||||
print getTitleFieldOfList('By', 0, $_SERVER["PHP_SELF"], '', (string) $page, $param, '', $sortfield, $sortorder, '', 1);
|
||||
print getTitleFieldOfList('Type', 0, $_SERVER["PHP_SELF"], '', (string) $page, $param, '', $sortfield, $sortorder, '', 1);
|
||||
print getTitleFieldOfList('Type', 0, $_SERVER["PHP_SELF"], '', (string) $page, $param, '', $sortfield, $sortorder, 'center ', 1);
|
||||
print getTitleFieldOfList('Title', 0, $_SERVER["PHP_SELF"], '', (string) $page, $param, '', $sortfield, $sortorder, '', 1);
|
||||
print getTitleFieldOfList('', 0, $_SERVER["PHP_SELF"], '', (string) $page, $param, '', $sortfield, $sortorder, 'right ', 1);
|
||||
print '</tr>';
|
||||
@@ -298,41 +298,43 @@ class FormActions
|
||||
|
||||
// Date
|
||||
print '<td class="center nowraponall nopaddingtopimp nopaddingbottomimp">';
|
||||
$tmpa = dol_getdate($actioncomm->datep);
|
||||
if ($actioncomm->datef) { // There is also a end date
|
||||
$tmpa = dol_getdate($actioncomm->datep);
|
||||
$tmpb = dol_getdate($actioncomm->datef);
|
||||
if ($tmpa['mday'] == $tmpb['mday'] && $tmpa['mon'] == $tmpb['mon'] && $tmpa['year'] == $tmpb['year']) {
|
||||
// The same day
|
||||
print '<div class="center inline-block dateheight">';
|
||||
if ($tmpa['hours'] != $tmpb['hours'] || $tmpa['minutes'] != $tmpb['minutes']) {
|
||||
print dol_print_date($actioncomm->datep, 'dayreduceformat', 'tzuserrel');
|
||||
print '<br><span class="small opacitymedium">';
|
||||
print dol_print_date($actioncomm->datep, 'hourreduceformat', 'tzuserrel');
|
||||
print '-'.dol_print_date($actioncomm->datef, 'hourreduceformat', 'tzuserrel');
|
||||
print '</span>';
|
||||
} else {
|
||||
print dol_print_date($actioncomm->datep, 'dayreduceformat', 'tzuserrel');
|
||||
print '<br><span class="small opacitymedium">';
|
||||
print dol_print_date($actioncomm->datep, 'hourreduceformat', 'tzuserrel');
|
||||
print '</span>';
|
||||
}
|
||||
print '</div>';
|
||||
} else {
|
||||
$tmpb = $tmpa;
|
||||
}
|
||||
if ($tmpa['mday'] == $tmpb['mday'] && $tmpa['mon'] == $tmpb['mon'] && $tmpa['year'] == $tmpb['year']) {
|
||||
// The same day
|
||||
print '<div class="center inline-block dateheight">';
|
||||
if ($tmpa['hours'] != $tmpb['hours'] || $tmpa['minutes'] != $tmpb['minutes']) {
|
||||
print dol_print_date($actioncomm->datep, 'dayreduceformat', 'tzuserrel');
|
||||
print '<br><span class="small opacitymedium">';
|
||||
print dol_print_date($actioncomm->datep, 'hourreduceformat', 'tzuserrel');
|
||||
print '-'.dol_print_date($actioncomm->datef, 'hourreduceformat', 'tzuserrel');
|
||||
print '</span>';
|
||||
} else {
|
||||
// Not the same day
|
||||
print '<div class="center inline-block">';
|
||||
print dol_print_date($actioncomm->datep, 'dayreduceformat', 'tzuserrel');
|
||||
print '<br><span class="small opacitymedium">';
|
||||
print dol_print_date($actioncomm->datep, 'hourreduceformat', 'tzuserrel');
|
||||
print '</span>';
|
||||
print '</div>';
|
||||
print ' ';
|
||||
print '<div class="center inline-block">';
|
||||
print dol_print_date($actioncomm->datef, 'dayreduceformat', 'tzuserrel');
|
||||
print '<br><span class="small opacitymedium">';
|
||||
print dol_print_date($actioncomm->datef, 'hourreduceformat', 'tzuserrel');
|
||||
print '</span>';
|
||||
print '</div>';
|
||||
}
|
||||
print '</div>';
|
||||
} else {
|
||||
// Not the same day
|
||||
print '<div class="center inline-block">';
|
||||
print dol_print_date($actioncomm->datep, 'dayreduceformat', 'tzuserrel');
|
||||
print '<br><span class="small opacitymedium">';
|
||||
print dol_print_date($actioncomm->datep, 'hourreduceformat', 'tzuserrel');
|
||||
print '</span>';
|
||||
print '</div>';
|
||||
print ' ';
|
||||
print '<div class="center inline-block">';
|
||||
print dol_print_date($actioncomm->datef, 'dayreduceformat', 'tzuserrel');
|
||||
print '<br><span class="small opacitymedium">';
|
||||
print dol_print_date($actioncomm->datef, 'hourreduceformat', 'tzuserrel');
|
||||
print '</span>';
|
||||
print '</div>';
|
||||
}
|
||||
print '</td>';
|
||||
|
||||
@@ -357,10 +359,11 @@ class FormActions
|
||||
//$actionstatic->type_code = 'AC_OTHER_AUTO'
|
||||
|
||||
// Type
|
||||
$labeltype = $actioncomm->getTypeLabel(0);
|
||||
print '<td class="tdoverflowmax100" title="'.dol_escape_htmltag($labeltype).'">';
|
||||
print $actioncomm->getTypePicto();
|
||||
print $labeltype;
|
||||
$labeltypelong = $actioncomm->getTypeLabel(2);
|
||||
print '<td class="tdoverflowmax100 center" title="'.dolPrintHTML($labeltypelong).'">';
|
||||
print $actioncomm->getTypePicto('valignmiddle');
|
||||
//$labeltype = $actioncomm->getTypeLabel(0);
|
||||
//print $labeltype;
|
||||
print '</td>';
|
||||
|
||||
// Label / Title
|
||||
|
||||
@@ -668,7 +668,10 @@ class Notify
|
||||
$application = (preg_match('/^\+/', $applicationcustom) ? $application : '').$applicationcustom;
|
||||
}
|
||||
|
||||
$from = getDolGlobalString('NOTIFICATION_EMAIL_FROM', getDolGlobalString('MAIN_MAIL_EMAIL_FROM'));
|
||||
$from = getDolGlobalString('NOTIFICATION_EMAIL_FROM');
|
||||
if (empty($from)) {
|
||||
$from = getDolGlobalString('MAIN_MAIL_EMAIL_FROM');
|
||||
}
|
||||
|
||||
$object_type = '';
|
||||
$link = '';
|
||||
|
||||
@@ -1195,7 +1195,13 @@ class Translate
|
||||
$obj = $db->fetch_object($resql);
|
||||
if ($obj) {
|
||||
// If a translation exists, we use it lese we use the default label
|
||||
$this->cache_currencies[$obj->code_iso]['label'] = ($obj->code_iso && $this->trans("Currency" . $obj->code_iso) != "Currency" . $obj->code_iso ? $this->trans("Currency" . $obj->code_iso) : ($obj->label != '-' ? $obj->label : ''));
|
||||
if ($obj->code_iso && !empty($this->tab_translate["Currency" . $obj->code_iso])) { // Test on tab_translate is faster (possible because we knowhere the "dict" language file has been previously loaded).
|
||||
$tmplabel = $this->trans("Currency" . $obj->code_iso);
|
||||
} else {
|
||||
$tmplabel = ($obj->label != '-' ? $obj->label : '');
|
||||
}
|
||||
|
||||
$this->cache_currencies[$obj->code_iso]['label'] = $tmplabel;
|
||||
$this->cache_currencies[$obj->code_iso]['unicode'] = (array) json_decode((empty($obj->unicode) ? '' : $obj->unicode), true); // @phan-suppress-current-line PhanTypeMismatchProperty
|
||||
$label[$obj->code_iso] = $this->cache_currencies[$obj->code_iso]['label'];
|
||||
}
|
||||
|
||||
@@ -48,6 +48,7 @@
|
||||
* @param ''|'systemauto'|'system' $excludetype A type to exclude ('systemauto', 'system', '')
|
||||
* @param int $resourceid Preselected value of resource for filter on resource
|
||||
* @param int $search_categ_cus Tag id
|
||||
* @param string $search_import_key Import IDfilter
|
||||
* @return void
|
||||
*/
|
||||
function print_actions_filter(
|
||||
@@ -69,7 +70,8 @@ function print_actions_filter(
|
||||
$usergroupid = 0,
|
||||
$excludetype = '',
|
||||
$resourceid = 0,
|
||||
$search_categ_cus = 0
|
||||
$search_categ_cus = 0,
|
||||
$search_import_key = ''
|
||||
) {
|
||||
global $user, $langs, $db, $hookmanager;
|
||||
global $massaction;
|
||||
|
||||
@@ -2419,43 +2419,45 @@ function show_actions_done($conf, $langs, $db, $filterobj, $objcon = null, $nopr
|
||||
|
||||
// Date
|
||||
$out .= '<td class="center nowraponall nopaddingtopimp nopaddingbottomimp">';
|
||||
if ($histo[$key]['dateend']) { // There is also a end date
|
||||
$tmpa = dol_getdate($histo[$key]['datestart']);
|
||||
$tmpa = dol_getdate($histo[$key]['datestart']);
|
||||
if (!empty($histo[$key]['dateend'])) {
|
||||
$tmpb = dol_getdate($histo[$key]['dateend']);
|
||||
if ($tmpa['mday'] == $tmpb['mday'] && $tmpa['mon'] == $tmpb['mon'] && $tmpa['year'] == $tmpb['year']) {
|
||||
// The same day
|
||||
if ($tmpa['hours'] != $tmpb['hours'] || $tmpa['minutes'] != $tmpb['minutes']) {
|
||||
$out .= '<div class="center inline-block lineheightsmall">';
|
||||
$out .= dol_print_date($histo[$key]['datestart'], 'dayreduceformat', 'tzuserrel');
|
||||
$out .= '<br><span class="opacitymedium hourspan">';
|
||||
$out .= dol_print_date($histo[$key]['datestart'], 'hourreduceformat', 'tzuserrel');
|
||||
$out .= '-'.dol_print_date($histo[$key]['dateend'], 'hourreduceformat', 'tzuserrel');
|
||||
$out .= '</span>';
|
||||
$out .= '</div>';
|
||||
} else {
|
||||
$out .= '<div class="center inline-block lineheightsmall">';
|
||||
$out .= dol_print_date($histo[$key]['datestart'], 'dayreduceformat', 'tzuserrel');
|
||||
$out .= '<br><span class="opacitymedium hourspan">';
|
||||
$out .= dol_print_date($histo[$key]['datestart'], 'hourreduceformat', 'tzuserrel');
|
||||
$out .= '</span>';
|
||||
$out .= '</div>';
|
||||
}
|
||||
} else {
|
||||
$tmpb = $tmpa;
|
||||
}
|
||||
if ($tmpa['mday'] == $tmpb['mday'] && $tmpa['mon'] == $tmpb['mon'] && $tmpa['year'] == $tmpb['year']) {
|
||||
// The same day
|
||||
if ($tmpa['hours'] != $tmpb['hours'] || $tmpa['minutes'] != $tmpb['minutes']) {
|
||||
$out .= '<div class="center inline-block lineheightsmall">';
|
||||
$out .= dol_print_date($histo[$key]['datestart'], 'dayreduceformat', 'tzuserrel');
|
||||
$out .= '<br><span class="opacitymedium hourspan">';
|
||||
$out .= dol_print_date($histo[$key]['datestart'], 'hourreduceformat', 'tzuserrel');
|
||||
$out .= '-'.dol_print_date($histo[$key]['dateend'], 'hourreduceformat', 'tzuserrel');
|
||||
$out .= '</span>';
|
||||
$out .= '</div>';
|
||||
} else {
|
||||
// Not the same day
|
||||
$out .= '<div class="center inline-block lineheightsmall">';
|
||||
$out .= dol_print_date($histo[$key]['datestart'], 'dayreduceformat', 'tzuserrel');
|
||||
$out .= '<br><span class="opacitymedium hourspan">';
|
||||
$out .= dol_print_date($histo[$key]['datestart'], 'hourreduceformat', 'tzuserrel');
|
||||
$out .= '</span>';
|
||||
$out .= '</div>';
|
||||
$out .= ' - ';
|
||||
$out .= '<div class="center inline-block lineheightsmall">';
|
||||
$out .= dol_print_date($histo[$key]['dateend'], 'dayreduceformat', 'tzuserrel');
|
||||
$out .= '<br><span class="opacitymedium hourspan">';
|
||||
$out .= dol_print_date($histo[$key]['dateend'], 'hourreduceformat', 'tzuserrel');
|
||||
$out .= '</span>';
|
||||
$out .= '</div>';
|
||||
$out .= '<div class="center inline-block lineheightsmall">';
|
||||
$out .= dol_print_date($histo[$key]['datestart'], 'dayreduceformat', 'tzuserrel');
|
||||
$out .= '<br><span class="opacitymedium hourspan">';
|
||||
$out .= dol_print_date($histo[$key]['datestart'], 'hourreduceformat', 'tzuserrel');
|
||||
$out .= '</span>';
|
||||
$out .= '</div>';
|
||||
}
|
||||
} else {
|
||||
// Not the same day
|
||||
$out .= '<div class="center inline-block lineheightsmall">';
|
||||
$out .= dol_print_date($histo[$key]['datestart'], 'dayreduceformat', 'tzuserrel');
|
||||
$out .= '<br><span class="opacitymedium hourspan">';
|
||||
$out .= dol_print_date($histo[$key]['datestart'], 'hourreduceformat', 'tzuserrel');
|
||||
$out .= '</span>';
|
||||
$out .= '</div>';
|
||||
$out .= ' - ';
|
||||
$out .= '<div class="center inline-block lineheightsmall">';
|
||||
$out .= dol_print_date($histo[$key]['dateend'], 'dayreduceformat', 'tzuserrel');
|
||||
$out .= '<br><span class="opacitymedium hourspan">';
|
||||
$out .= dol_print_date($histo[$key]['dateend'], 'hourreduceformat', 'tzuserrel');
|
||||
$out .= '</span>';
|
||||
$out .= '</div>';
|
||||
}
|
||||
// Add the late warning
|
||||
$late = 0;
|
||||
@@ -2798,7 +2800,7 @@ function addOtherFilterSQL(&$sql, $donetodo, $now, $filters)
|
||||
if (is_array($filters) && !empty($filters['search_rowid'])) {
|
||||
$sql .= natural_search('a.id', $filters['search_rowid'], 1);
|
||||
}
|
||||
if (is_array($filters) && !empty($filters['search_filtert'])) {
|
||||
if (is_array($filters) && !empty($filters['search_filtert']) && ((int) $filters['search_filtert']) != -1) {
|
||||
$sql .= natural_search('a.fk_user_action', $filters['search_filtert'], 1);
|
||||
}
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
* Copyright (C) 2021 Gauthier VERDOL <gauthier.verdol@atm-consulting.fr>
|
||||
* Copyright (C) 2022 Anthony Berton <anthony.berton@bb2a.fr>
|
||||
* Copyright (C) 2022 Ferran Marcet <fmarcet@2byte.es>
|
||||
* Copyright (C) 2022-2025 Charlene Benke <charlene@patas-monkey.com>
|
||||
* Copyright (C) 2022-2026 Charlene Benke <charlene@patas-monkey.com>
|
||||
* Copyright (C) 2024-2025 MDW <mdeweerd@users.noreply.github.com>
|
||||
* Copyright (C) 2023-2024 Joachim Kueter <git-jk@bloxera.com>
|
||||
* Copyright (C) 2024 Lenin Rivas <lenin.rivas777@gmail.com>
|
||||
@@ -3864,7 +3864,7 @@ function dol_strftime($fmt, $ts = false, $is_gmt = false)
|
||||
* 'tzuserrel' => output string is for user TZ (current browser TZ with dst or not, depending on date position)
|
||||
* @param ?Translate $outputlangs Object lang that contains language for text translation.
|
||||
* @param boolean $encodetooutput Use true to convert/encode string into the HTML rendering pagecode (false=keep UTF8 by default)
|
||||
* @param int $decorate Use 1 to apply a HTML css style to decorate the date
|
||||
* @param int|string $decorate Use 1 or a css to apply a HTML css style to decorate the date
|
||||
* @return string Formatted date or '' if time is null
|
||||
*
|
||||
* @see dol_mktime(), dol_stringtotime(), dol_getdate(), selectDate()
|
||||
@@ -4113,8 +4113,8 @@ function dol_print_date($time, $format = '', $tzoutput = 'auto', $outputlangs =
|
||||
}
|
||||
|
||||
if ($decorate) {
|
||||
$ret = preg_replace('/(\d\d:\d\d [AP]M)$/', '<span class="opacitymedium">\1</span>', $ret);
|
||||
$ret = preg_replace('/(\d\d:\d\d)$/', '<span class="opacitymedium">\1</span>', $ret);
|
||||
$ret = preg_replace('/(\d\d:\d\d [AP]M)$/', '<span class="'.($decorate === 1 ? 'opacitymedium' : $decorate).'">\1</span>', $ret);
|
||||
$ret = preg_replace('/(\d\d:\d\d)$/', '<span class="'.($decorate === 1 ? 'opacitymedium' : $decorate).'">\1</span>', $ret);
|
||||
}
|
||||
|
||||
return $ret;
|
||||
@@ -14894,7 +14894,7 @@ function getElementProperties($elementType)
|
||||
$module = 'facture';
|
||||
$table_element = 'facturedet';
|
||||
$parent_element = 'facture';
|
||||
} elseif ($elementType == 'facturerec') {
|
||||
} elseif ($elementType == 'facturerec'|| $elementType == 'facture_rec') {
|
||||
$classpath = 'compta/facture/class';
|
||||
$classfile = 'facture-rec';
|
||||
$module = 'facture';
|
||||
@@ -16387,7 +16387,7 @@ function show_actions_messaging($conf, $langs, $db, $filterobj, $objcon = null,
|
||||
'datestart' => $db->jdate($obj->dp),
|
||||
'dateend' => $db->jdate($obj->dp2),
|
||||
'note' => $obj->label,
|
||||
'message' => dol_htmlentitiesbr($obj->message),
|
||||
'message' => $obj->message,
|
||||
'percent' => $obj->percent,
|
||||
|
||||
'userid' => $obj->user_id,
|
||||
@@ -16417,7 +16417,7 @@ function show_actions_messaging($conf, $langs, $db, $filterobj, $objcon = null,
|
||||
'datestart' => $db->jdate($obj->dp),
|
||||
'dateend' => $db->jdate($obj->dp2),
|
||||
'note' => $obj->label,
|
||||
'message' => dol_htmlentitiesbr($obj->message),
|
||||
'message' => $obj->message,
|
||||
'percent' => $obj->percent,
|
||||
'acode' => $obj->acode,
|
||||
|
||||
@@ -16629,16 +16629,23 @@ function show_actions_messaging($conf, $langs, $db, $filterobj, $objcon = null,
|
||||
$out .= '</span>';
|
||||
|
||||
// Date
|
||||
$out .= '<span class="time"><i class="fa fa-clock-o valignmiddle"></i> <span class="valignmiddle">';
|
||||
$out .= '<span class="time"><i class="fa fa-clock valignmiddle"></i> ';
|
||||
$out .= '<span class="valignmiddle marginrightonly">';
|
||||
$out .= dol_print_date($histo[$key]['datestart'], 'day', 'tzuserrel');
|
||||
$out .= ' '.dol_print_date($histo[$key]['datestart'], 'hour', 'tzuserrel', null, false, 1);
|
||||
//$out .= '</span>';
|
||||
//$out .= '<span class="valignmiddle">'.
|
||||
$out .= ' '.dol_print_date($histo[$key]['datestart'], 'hour', 'tzuserrel', null, false, 'opacitymedium');
|
||||
//$out .= '</span>';
|
||||
if ($histo[$key]['dateend'] && $histo[$key]['dateend'] != $histo[$key]['datestart']) {
|
||||
$tmpa = dol_getdate($histo[$key]['datestart'], true);
|
||||
$tmpb = dol_getdate($histo[$key]['dateend'], true);
|
||||
if ($tmpa['mday'] == $tmpb['mday'] && $tmpa['mon'] == $tmpb['mon'] && $tmpa['year'] == $tmpb['year']) {
|
||||
$out .= '-' . dol_print_date($histo[$key]['dateend'], 'hour', 'tzuserrel', null, false, 1);
|
||||
$out .= ' - ' . dol_print_date($histo[$key]['dateend'], 'hour', 'tzuserrel', null, false, 1);
|
||||
} else {
|
||||
$out .= '-' . dol_print_date($histo[$key]['dateend'], 'dayhour', 'tzuserrel', null, false, 1);
|
||||
$out .= ' - ' . dol_print_date($histo[$key]['dateend'], 'day', 'tzuserrel');
|
||||
//$out .= '<span class="valignmiddle marginrightonly">';
|
||||
$out .= ' '.dol_print_date($histo[$key]['dateend'], 'hour', 'tzuserrel', null, false, 'opacitymedium');
|
||||
//$out .= '</span>';
|
||||
}
|
||||
}
|
||||
$late = 0;
|
||||
@@ -16749,20 +16756,21 @@ function show_actions_messaging($conf, $langs, $db, $filterobj, $objcon = null,
|
||||
) {
|
||||
$out .= '<div class="timeline-body wordbreak small">';
|
||||
$truncateLines = getDolGlobalInt('MAIN_TRUNCATE_TIMELINE_MESSAGE', 3);
|
||||
$truncatedText = dolGetFirstLineOfText($histo[$key]['message'], $truncateLines);
|
||||
if ($truncateLines > 0 && strlen($histo[$key]['message']) > strlen($truncatedText)) {
|
||||
$newmess = dol_htmlentitiesbr($histo[$key]['message']);
|
||||
$truncatedText = dolGetFirstLineOfText($newmess, $truncateLines);
|
||||
if ($truncateLines > 0 && strlen($newmess) > strlen($truncatedText)) {
|
||||
$out .= '<div class="readmore-block --closed" >';
|
||||
$out .= ' <div class="readmore-block__excerpt">';
|
||||
$out .= dolPrintHTML($truncatedText);
|
||||
$out .= ' <br><a class="read-more-link" data-read-more-action="open" href="' . DOL_MAIN_URL_ROOT . '/comm/action/card.php?id=' . $actionstatic->id . '&backtopage=' . urlencode($_SERVER["PHP_SELF"] . '?' . $param) . '" >' . $langs->trans("ReadMore") . ' <span class="fa fa-chevron-right" aria-hidden="true"></span></a>';
|
||||
$out .= ' </div>';
|
||||
$out .= ' <div class="readmore-block__full-text" >';
|
||||
$out .= dolPrintHTML($histo[$key]['message']);
|
||||
$out .= dolPrintHTML($newmess);
|
||||
$out .= ' <a class="read-less-link" data-read-more-action="close" href="#" ><span class="fa fa-chevron-up" aria-hidden="true"></span> ' . $langs->trans("ReadLess") . '</a>';
|
||||
$out .= ' </div>';
|
||||
$out .= '</div>';
|
||||
} else {
|
||||
$out .= dolPrintHTML($histo[$key]['message']);
|
||||
$out .= dolPrintHTML($newmess);
|
||||
}
|
||||
|
||||
$out .= '</div>';
|
||||
|
||||
@@ -584,7 +584,14 @@ class modAgenda extends DolibarrModules
|
||||
'class' => 'CActionComm',
|
||||
'method' => 'fetch',
|
||||
'dict' => 'DictionaryActions'
|
||||
)
|
||||
),
|
||||
'ac.fk_project' => array(
|
||||
'rule' => 'fetchidfromref',
|
||||
'file' => '/projet/class/project.class.php',
|
||||
'class' => 'Project',
|
||||
'method' => 'fetch',
|
||||
'element' => 'Project'
|
||||
),
|
||||
);
|
||||
|
||||
// Import Event Extra Fields
|
||||
|
||||
@@ -316,9 +316,13 @@ class modProjet extends DolibarrModules
|
||||
}
|
||||
}
|
||||
// End add extra fields
|
||||
$this->import_fieldshidden_array[$r] = array('t.fk_user_creat'=>'user->id', 'extra.fk_object'=>'lastrowid-'.MAIN_DB_PREFIX.'projet'); // aliastable.field => ('user->id' or 'lastrowid-'.tableparent)
|
||||
$this->import_fieldshidden_array[$r] = array('t.fk_user_creat'=>'user->id', 't.fk_user_modif'=>'user->id', 'extra.fk_object'=>'lastrowid-'.MAIN_DB_PREFIX.'projet'); // aliastable.field => ('user->id' or 'lastrowid-'.tableparent)
|
||||
$this->import_convertvalue_array[$r] = array(
|
||||
't.ref' => array('rule' => 'getrefifauto', 'class' => getDolGlobalString('PROJECT_ADDON', 'mod_project_simple'), 'path' => "/core/modules/project/".getDolGlobalString('PROJECT_ADDON', 'mod_project_simple').'.php'),
|
||||
't.ref' => array(
|
||||
'rule' => 'getrefifauto',
|
||||
'class' => getDolGlobalString('PROJECT_ADDON', 'mod_project_simple'),
|
||||
'path' => "/core/modules/project/".getDolGlobalString('PROJECT_ADDON', 'mod_project_simple').'.php'
|
||||
),
|
||||
't.fk_soc' => array(
|
||||
'rule' => 'fetchidfromref',
|
||||
'file' => '/societe/class/societe.class.php',
|
||||
@@ -326,6 +330,13 @@ class modProjet extends DolibarrModules
|
||||
'method' => 'fetch',
|
||||
'element' => 'ThirdParty'
|
||||
),
|
||||
't.fk_opp_status' => array(
|
||||
'rule' => 'fetchidfromcodeid',
|
||||
'file' => '/core/class/cleadstatus.class.php',
|
||||
'class' => 'CLeadStatus',
|
||||
'method' => 'fetch',
|
||||
'dict' => 'DictionaryOpportunityStatus'
|
||||
),
|
||||
);
|
||||
//$this->import_convertvalue_array[$r]=array('s.fk_soc'=>array('rule'=>'lastrowid',table='t');
|
||||
$this->import_regex_array[$r] = array('t.dateo'=>'^[0-9][0-9][0-9][0-9]-[0-9][0-9]-[0-9][0-9]$', 't.datee'=>'^[0-9][0-9][0-9][0-9]-[0-9][0-9]-[0-9][0-9]$', 't.datec'=>'^[0-9][0-9][0-9][0-9]-[0-9][0-9]-[0-9][0-9]( [0-9][0-9]:[0-9][0-9]:[0-9][0-9])?$');
|
||||
|
||||
@@ -764,6 +764,7 @@ if (!empty($usemargins) && $user->hasRight('margins', 'creer')) {
|
||||
jQuery("#price_ttc").val('');
|
||||
jQuery("#multicurrency_subprice").val('');
|
||||
jQuery("#multicurrency_price_ht").val('');
|
||||
jQuery("#multicurrency_price_ttc").val('');
|
||||
}
|
||||
});
|
||||
|
||||
@@ -773,6 +774,7 @@ if (!empty($usemargins) && $user->hasRight('margins', 'creer')) {
|
||||
jQuery("#price_ht").val('');
|
||||
jQuery("#multicurrency_subprice").val('');
|
||||
jQuery("#multicurrency_price_ht").val('');
|
||||
jQuery("#multicurrency_price_ttc").val('');
|
||||
}
|
||||
});
|
||||
jQuery("#multicurrency_subprice").keyup(function(event) {
|
||||
@@ -780,6 +782,7 @@ if (!empty($usemargins) && $user->hasRight('margins', 'creer')) {
|
||||
if (event.which != 9 && (event.which < 37 || event.which > 40) && jQuery("#multicurrency_subprice").val() != '') {
|
||||
jQuery("#price_ht").val('');
|
||||
jQuery("#price_ttc").val('');
|
||||
jQuery("#multicurrency_price_ttc").val('');
|
||||
}
|
||||
});
|
||||
jQuery("#multicurrency_price_ht").keyup(function(event) {
|
||||
@@ -787,6 +790,15 @@ if (!empty($usemargins) && $user->hasRight('margins', 'creer')) {
|
||||
if (event.which != 9 && (event.which < 37 || event.which > 40) && jQuery("#multicurrency_price_ht").val() != '') {
|
||||
jQuery("#price_ht").val('');
|
||||
jQuery("#price_ttc").val('');
|
||||
jQuery("#multicurrency_price_ttc").val('');
|
||||
}
|
||||
});
|
||||
jQuery("#multicurrency_price_ttc").keyup(function(event) {
|
||||
// console.log(event.which); // discard event tag and arrows
|
||||
if (event.which != 9 && (event.which < 37 || event.which > 40) && jQuery("#multicurrency_price_ttc").val() != '') {
|
||||
jQuery("#price_ht").val('');
|
||||
jQuery("#price_ttc").val('');
|
||||
jQuery("#multicurrency_price_ht").val('');
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
@@ -554,7 +554,7 @@ print '<td class="liste_titre"> </td>';
|
||||
print '<td class="liste_titre">';
|
||||
print '<input type="text" class="flat width75" name="search_label" value="'.$search_label.'">';
|
||||
print '</td>';
|
||||
//print '<td class="liste_titre"> </td>';
|
||||
print '<td class="liste_titre"> </td>';
|
||||
print '<td class="liste_titre"><input type="text" class="width50" name="search_module_name" value="'.$search_module_name.'"></td>';
|
||||
print '<td class="liste_titre"> </td>';
|
||||
print '<td class="liste_titre"> </td>';
|
||||
@@ -591,7 +591,7 @@ if (getDolGlobalString('MAIN_CHECKBOX_LEFT_COLUMN')) {
|
||||
}
|
||||
print_liste_field_titre("Ref", $_SERVER["PHP_SELF"], "t.rowid", "", $param, '', $sortfield, $sortorder);
|
||||
print_liste_field_titre("CronLabel", $_SERVER["PHP_SELF"], "t.label", "", $param, '', $sortfield, $sortorder);
|
||||
//print_liste_field_titre("Priority", $_SERVER["PHP_SELF"], "t.priority", "", $param, '', $sortfield, $sortorder);
|
||||
print_liste_field_titre("Priority", $_SERVER["PHP_SELF"], "t.priority", "", $param, '', $sortfield, $sortorder);
|
||||
print_liste_field_titre("CronModule", $_SERVER["PHP_SELF"], "t.module_name", "", $param, '', $sortfield, $sortorder);
|
||||
print_liste_field_titre("", '', '', "", $param, '', $sortfield, $sortorder, 'tdoverflowmax50 ');
|
||||
print_liste_field_titre("CronFrequency", '', "", "", $param, '', $sortfield, $sortorder);
|
||||
@@ -695,9 +695,9 @@ if ($num > 0) {
|
||||
}
|
||||
|
||||
// Priority
|
||||
/*print '<td class="right">';
|
||||
print '<td class="right">';
|
||||
print dol_escape_htmltag($object->priority);
|
||||
print '</td>';*/
|
||||
print '</td>';
|
||||
|
||||
// Module
|
||||
print '<td>';
|
||||
|
||||
@@ -352,7 +352,7 @@ class DataPolicyCron
|
||||
'__DELAY__' => (string) $delay,
|
||||
'__NOW__' => "'" . $this->db->idate(dol_now()) . "'"
|
||||
);
|
||||
$sql = str_replace(array_keys($sqlPlaceholders), array_values($sqlPlaceholders), $policy['sql_template']);
|
||||
$sql = str_replace(array_keys($sqlPlaceholders), array_values($sqlPlaceholders), $policy['sql_template'.($action == 'delete' ? '_delete' : '')]);
|
||||
|
||||
$resql = $this->db->query($sql);
|
||||
|
||||
|
||||
@@ -1240,6 +1240,7 @@ if ($step == 4 && $datatoimport) {
|
||||
|
||||
$labelhtml = $label.' '.$form->textwithpicto('', $htmltext, 1, 'help', '', 1);
|
||||
|
||||
|
||||
$selectforline .= '<option value="'.$tmpcode.'"';
|
||||
if ($modetoautofillmapping == 'orderoftargets') {
|
||||
// The mode where we fill the preselected value of combo one by one in order of available targets fields in the declaration in descriptor file.
|
||||
|
||||
@@ -319,11 +319,14 @@ ALTER TABLE llx_oauth_token ADD COLUMN tokenstring_refresh text NULL AFTER token
|
||||
ALTER TABLE llx_oauth_token ADD COLUMN expire_at datetime NULL AFTER lastaccess;
|
||||
|
||||
ALTER TABLE llx_blockedlog ADD COLUMN linktoref text;
|
||||
ALTER TABLE llx_blockedlog DROP FOREIGN KEY fk_linktoref;
|
||||
ALTER TABLE llx_blockedlog MODIFY COLUMN linktoref text;
|
||||
ALTER TABLE llx_blockedlog ADD COLUMN linktype varchar(16);
|
||||
ALTER TABLE llx_blockedlog ADD COLUMN module_source varchar(32) DEFAULT '' AFTER action;
|
||||
ALTER TABLE llx_blockedlog ADD COLUMN amounts_taxexcl double(24,8) DEFAULT NULL AFTER amounts;
|
||||
|
||||
-- VMYSQL4.3 ALTER TABLE llx_blockedlog ADD INDEX idx_linktoref (linktoref(255));
|
||||
|
||||
|
||||
-- Incoterms 2025 and specific terms
|
||||
-- DAT is replaced by DPU - but not deactivating for existing installations
|
||||
@@ -371,6 +374,8 @@ ALTER TABLE llx_blockedlog ADD INDEX idx_entity_action (entity,action);
|
||||
ALTER TABLE llx_blockedlog DROP COLUMN signature_line;
|
||||
ALTER TABLE llx_blockedlog ADD COLUMN actionrefisunique varchar(16) DEFAULT NULL;
|
||||
|
||||
ALTER TABLE llx_blockedlog ADD INDEX idx_ref_object (ref_object);
|
||||
|
||||
ALTER TABLE llx_accounting_bookkeeping ADD COLUMN matching_general tinyint DEFAULT 0 NOT NULL AFTER multicurrency_code;
|
||||
ALTER TABLE llx_accounting_bookkeeping_tmp ADD COLUMN matching_general tinyint DEFAULT 0 NOT NULL AFTER multicurrency_code;
|
||||
|
||||
@@ -394,11 +399,6 @@ CREATE TABLE llx_expensereport_det_extrafields
|
||||
) ENGINE=innodb;
|
||||
|
||||
|
||||
ALTER TABLE llx_blockedlog ADD INDEX idx_ref_object (ref_object);
|
||||
ALTER TABLE llx_blockedlog DROP FOREIGN KEY fk_linktoref;
|
||||
-- VMYSQL4.3 ALTER TABLE llx_blockedlog ADD INDEX idx_linktoref (linktoref(255));
|
||||
|
||||
|
||||
ALTER TABLE llx_fichinterdet ADD COLUMN special_code integer DEFAULT 0 AFTER fk_parent_line;
|
||||
ALTER TABLE llx_fichinterdet ADD COLUMN product_type integer DEFAULT 0 AFTER special_code;
|
||||
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
|
||||
ALTER TABLE llx_blockedlog ADD INDEX idx_entity_action_certified (entity,action);
|
||||
ALTER TABLE llx_blockedlog ADD INDEX idx_ref_object (ref_object);
|
||||
ALTER TABLE llx_blockedlog ADD INDEX idx_linktoref (linktoref);
|
||||
-- VMYSQL4.3 ALTER TABLE llx_blockedlog ADD INDEX idx_linktoref (linktoref(255));
|
||||
ALTER TABLE llx_blockedlog ADD INDEX signature (signature);
|
||||
|
||||
-- For debug fields
|
||||
|
||||
@@ -42,7 +42,7 @@ create table llx_facture
|
||||
date_valid date, -- date validation
|
||||
tms timestamp DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, -- last modification date
|
||||
date_closing datetime, -- date de cloture
|
||||
paye smallint DEFAULT 0 NOT NULL,
|
||||
paye smallint DEFAULT 0 NOT NULL, -- 1 if invoice is payed completely. Deprecated. Use instead statut = 2 and close_code is null or = ''
|
||||
|
||||
remise_percent real DEFAULT 0, -- remise relative
|
||||
remise_absolue real DEFAULT 0, -- remise absolue
|
||||
@@ -59,7 +59,7 @@ create table llx_facture
|
||||
total_ht double(24,8) DEFAULT 0, -- amount total ht apres remise totale
|
||||
total_ttc double(24,8) DEFAULT 0, -- amount total ttc apres remise totale
|
||||
|
||||
fk_statut smallint DEFAULT 0 NOT NULL,
|
||||
fk_statut smallint DEFAULT 0 NOT NULL, -- 2 means closed, but it may be closed payed partially if close_code has a code value.
|
||||
|
||||
fk_user_author integer, -- user making creation
|
||||
fk_user_modif integer, -- user making last change
|
||||
|
||||
@@ -1368,6 +1368,7 @@ MAIN_MAX_DECIMALS_SHOWN=Max. decimals for prices <b>shown on screen</b>. Add an
|
||||
MAIN_ROUNDING_RULE_TOT=Step of rounding range (for countries where rounding is done on something other than base 10. For example, put 0.05 if rounding is done by 0.05 steps)
|
||||
UnitPriceOfProduct=Net unit price of a product
|
||||
TotalPriceAfterRounding=Total price (excl/vat/incl tax) after rounding
|
||||
NotSupportedWithRuleForCustomerPrice=Not supported with the selected rule for customer prices
|
||||
ParameterActiveForNextInputOnly=Parameter effective for next input only
|
||||
NoEventOrNoAuditSetup=No security event has been logged. This is normal if Audit has not been enabled in the "Setup - Security - Events" page.
|
||||
NoEventFoundWithCriteria=No security event has been found for this search criteria.
|
||||
|
||||
@@ -29,6 +29,7 @@ ViewWeek=Week view
|
||||
ViewPerUser=Per user view
|
||||
ViewPerType=Per type view
|
||||
AutoActions= Automatic filling
|
||||
ManualActions=Created manually by a user
|
||||
AgendaAutoActionDesc= Here you may define events which you want Dolibarr to create automatically in Agenda. If nothing is checked, only manual actions will be included in logs and displayed in Agenda. Automatic tracking of business actions done on objects (validation, status change) will not be saved.
|
||||
AgendaSetupOtherDesc= This page provides options to allow the export of your Dolibarr events into an external calendar (Thunderbird, Google Calendar etc...)
|
||||
AgendaExtSitesDesc=This page allows to declare external sources of calendars to see their events into Dolibarr agenda.
|
||||
|
||||
@@ -71,7 +71,6 @@ EnableBarOrRestaurantFeatures=Enable features for Bar or Restaurant
|
||||
ConfirmDeletionOfThisPOSSale=Do your confirm the deletion of this current sale ?
|
||||
ConfirmDiscardOfThisPOSSale=Do you want to discard this current sale ?
|
||||
NoClientErrorMessage=Please select a customer first
|
||||
History=History
|
||||
ValidateAndClose=Validate and close
|
||||
Terminal=Terminal
|
||||
NumberOfTerminals=Number of Terminals
|
||||
|
||||
@@ -1413,3 +1413,6 @@ Why=Why
|
||||
since=since
|
||||
SignatureID=Signature
|
||||
except=except
|
||||
DUPLICATA=DUPLICATA
|
||||
ErrorFailedTriggerCall=Failed to call trigger
|
||||
History=History
|
||||
|
||||
@@ -350,7 +350,7 @@ PackagingForThisProduct=Round quantities up to a multiple
|
||||
PackagingForThisProductDesc=When adding/updating a line in a documents, the quantity is adjusted to match the nearest higher multiple of the value defined on product.
|
||||
UseProductCustomerPackaging=Use the "%s" feature to round the quantities to some given multiples (for Sales)
|
||||
PackagingForThisProductSell=Packaging of quantities (sale)
|
||||
QtyRecalculatedWithPackaging=The quantity of the line were recalculated according to supplier packaging
|
||||
QtyRecalculatedWithPackaging=The quantity of the line were recalculated according to packaging rule on multiples for quantities
|
||||
|
||||
#Attributes
|
||||
Attributes=Attributes
|
||||
|
||||
@@ -5,7 +5,6 @@ SupplierInvoices=Vendor invoices
|
||||
ShowSupplierInvoice=Show Vendor Invoice
|
||||
NewSupplier=New vendor
|
||||
NewSupplierInvoice = New vendor invoice
|
||||
History=History
|
||||
ListOfSuppliers=List of vendors
|
||||
ShowSupplier=Show vendor
|
||||
BuyingPriceMin=Best buying price
|
||||
|
||||
@@ -29,6 +29,7 @@ ViewWeek=Vue semaine
|
||||
ViewPerUser=Vue par utilisateur
|
||||
ViewPerType=Vue par type
|
||||
AutoActions= Alimentation automatique
|
||||
ManualActions=Créé manuellement par l'utilisateur
|
||||
AgendaAutoActionDesc= Définissez ici les événements pour lesquels Dolibarr créera automatiquement une entrée dans l'agenda. Si aucun n'est coché, seules les actions manuelles seront affichées dans l'agenda. Les événements sur les objets (validation, changement de statut, modification) ne seront pas enregistrées.
|
||||
AgendaSetupOtherDesc= Cette page permet de configurer quelques options permettant d'exporter une vue de votre agenda Dolibarr vers un calendrier externe (thunderbird, google calendar, ...)
|
||||
AgendaExtSitesDesc=Cette page permet d'ajouter des sources de calendriers externes pour les visualiser au sein de l'agenda Dolibarr.
|
||||
|
||||
@@ -79,7 +79,7 @@ FieldsTarget=Champs cibles
|
||||
FieldTarget=Champ cible
|
||||
FieldSource=Champ source
|
||||
NbOfSourceLines=Nombre de lignes du fichier source
|
||||
NowClickToTestTheImport=Vérifiez que le format fichier (délimiteurs de chaînes de caractères et) de votre fichier correspond aux options affichées et. Vous avez omis la ligne d'en-tête, sinon ces éléments seront signalés comme des erreurs lors de la simulation suivante. <br> Cliquez sur « <b><span Cliquez sur le bouton %s pour simuler le processus d'importation. Aucune donnée ne sera modifiée dans votre base de données.
|
||||
NowClickToTestTheImport=Vérifiez que le format fichier (délimiteurs de chaînes de caractères et) de votre fichier correspond aux options affichées et. Vous avez omis la ligne d'en-tête, sinon ces éléments seront signalés comme des erreurs lors de la simulation suivante. <br> Cliquez sur le bouton "%s" pour simuler le processus d'importation. Aucune donnée ne sera modifiée dans votre base de données.
|
||||
RunSimulateImportFile=Lancer la simulation d'import
|
||||
FieldNeedSource=Ce champ en base requiert obligatoirement une donnée source
|
||||
SomeMandatoryFieldHaveNoSource=Certains champs obligatoires n'ont pas de champ source issus du fichier
|
||||
|
||||
@@ -648,7 +648,11 @@ if (isModEnabled("order") || isModEnabled("invoice")) {
|
||||
print '<tr class="oddeven">';
|
||||
print '<td>'.$form->textwithpicto($langs->trans("UseProductCustomerPackaging", $langs->transnoentities("PackagingForThisProduct")), $langs->trans("PackagingForThisProductDesc")).'</td>';
|
||||
print '<td class="right">';
|
||||
print ajax_constantonoff("PRODUCT_USE_CUSTOMER_PACKAGING", array(), $conf->entity, 0, 0, 0, 0);
|
||||
if (getDolGlobalString('PRODUIT_MULTIPRICES') || getDolGlobalString('PRODUIT_CUSTOMER_PRICES_BY_QTY_MULTIPRICES') || getDolGlobalString('PRODUIT_CUSTOMER_PRICES_AND_MULTIPRICES')) {
|
||||
print '<span class="opacitymedium">'.$langs->trans("NotSupportedWithRuleForCustomerPrice").'</span>';
|
||||
} else {
|
||||
print ajax_constantonoff("PRODUCT_USE_CUSTOMER_PACKAGING", array(), $conf->entity, 0, 0, 0, 0);
|
||||
}
|
||||
print '</td>';
|
||||
print '</tr>';
|
||||
}
|
||||
|
||||
@@ -165,6 +165,17 @@ if (getDolGlobalString('PRODUCT_DISABLE_EATBY')) {
|
||||
unset($arrayfields['pl.eatby']);
|
||||
}
|
||||
|
||||
if (!getDolGlobalString('STOCK_SUPPORT_SERVICES')) {
|
||||
$usercanreadsupplierprice = getDolGlobalString('MAIN_USE_ADVANCED_PERMS') ? $user->hasRight('product', 'product_advance', 'read_supplier_prices') : $user->hasRight('product', 'lire');
|
||||
} elseif (getDolGlobalString('MAIN_USE_ADVANCED_PERMS')) {
|
||||
$usercanreadsupplierprice = $user->hasRight('product', 'product_advance', 'read_supplier_prices') || $user->hasRight('product', 'service_advance', 'read_supplier_prices');
|
||||
} else {
|
||||
$usercanreadsupplierprice = $user->hasRight('product', 'lire') || $user->hasRight('service', 'lire');
|
||||
}
|
||||
|
||||
if (!$usercanreadsupplierprice) {
|
||||
unset($arrayfields['m.price']);
|
||||
}
|
||||
|
||||
$tmpwarehouse = new Entrepot($db);
|
||||
if ($id > 0 || !empty($ref)) {
|
||||
@@ -172,6 +183,10 @@ if ($id > 0 || !empty($ref)) {
|
||||
$id = $tmpwarehouse->id;
|
||||
}
|
||||
|
||||
$socid = 0;
|
||||
if ($user->socid > 0) {
|
||||
$socid = $user->socid;
|
||||
}
|
||||
|
||||
// Security check
|
||||
//$result=restrictedArea($user, 'stock', $id, 'entrepot&stock');
|
||||
@@ -944,9 +959,11 @@ if ($warehouse->id > 0) {
|
||||
print '<table class="border centpercent tableforfield">';
|
||||
|
||||
// Value
|
||||
print '<tr><td class="titlefield">'.$langs->trans("EstimatedStockValueShort").'</td><td>';
|
||||
print price((empty($calcproducts['value']) ? '0' : price2num($calcproducts['value'], 'MT')), 0, $langs, 0, -1, -1, $conf->currency);
|
||||
print "</td></tr>";
|
||||
if ($usercanreadsupplierprice) {
|
||||
print '<tr><td class="titlefield">'.$langs->trans("EstimatedStockValueShort").'</td><td>';
|
||||
print price((empty($calcproducts['value']) ? '0' : price2num($calcproducts['value'], 'MT')), 0, $langs, 0, -1, -1, $conf->currency);
|
||||
print "</td></tr>";
|
||||
}
|
||||
|
||||
// Last movement
|
||||
$sql = "SELECT MAX(m.datem) as datem";
|
||||
@@ -1628,12 +1645,13 @@ while ($i < $imaxinloop) {
|
||||
}
|
||||
// Price
|
||||
if (!empty($arrayfields['m.price']['checked'])) {
|
||||
$usercancreadsupplierprice = getDolGlobalString('MAIN_USE_ADVANCED_PERMS') ? $user->hasRight('product', 'product_advance', 'read_supplier_prices') : $user->hasRight('product', 'lire');
|
||||
// Product and service differentiation, if we have permissions for only one of them
|
||||
$displayprice = getDolGlobalString('MAIN_USE_ADVANCED_PERMS') ? $user->hasRight('product', 'product_advance', 'read_supplier_prices') : $user->hasRight('product', 'lire');
|
||||
if ($productstatic->isService()) {
|
||||
$usercancreadsupplierprice = getDolGlobalString('MAIN_USE_ADVANCED_PERMS') ? $user->hasRight('service', 'service_advance', 'read_supplier_prices') : $user->hasRight('service', 'lire');
|
||||
$displayprice = getDolGlobalString('MAIN_USE_ADVANCED_PERMS') ? $user->hasRight('service', 'service_advance', 'read_supplier_prices') : $user->hasRight('service', 'lire');
|
||||
}
|
||||
print '<td class="right">';
|
||||
if ($obj->price != 0 && $usercancreadsupplierprice) {
|
||||
if ($obj->price != 0 && $displayprice) {
|
||||
print price($obj->price);
|
||||
}
|
||||
print '</td>';
|
||||
@@ -1691,7 +1709,7 @@ print '</div>'."\n";
|
||||
print '</form>'."\n";
|
||||
|
||||
// Add number of product when there is a filter on period
|
||||
if (count($arrayofuniqueproduct) == 1 && !empty($year) && is_numeric($year)) {
|
||||
if (count($arrayofuniqueproduct) == 1 && !empty($search_date_startyear) && is_numeric($search_date_startyear)) {
|
||||
print "<br>";
|
||||
|
||||
$productidselected = 0;
|
||||
@@ -1699,8 +1717,8 @@ if (count($arrayofuniqueproduct) == 1 && !empty($year) && is_numeric($year)) {
|
||||
$productidselected = $key;
|
||||
$productlabelselected = $val;
|
||||
}
|
||||
$datebefore = dol_get_first_day($year ? $year : (int) dol_print_date(time(), "%Y"), $month ? $month : 1, true);
|
||||
$dateafter = dol_get_last_day($year ? $year : (int) dol_print_date(time(), "%Y"), $month ? $month : 12, true);
|
||||
$datebefore = dol_get_first_day($search_date_startyear ? $search_date_startyear : dol_print_date(time(), "%Y"), $search_date_startmonth ? $search_date_startmonth : 1, true);
|
||||
$dateafter = dol_get_last_day($search_date_endyear ? $search_date_endyear : dol_print_date(time(), "%Y"), $search_date_endmonth ? $search_date_endmonth : 12, true);
|
||||
$balancebefore = $object->calculateBalanceForProductBefore($productidselected, $datebefore);
|
||||
$balanceafter = $object->calculateBalanceForProductBefore($productidselected, $dateafter);
|
||||
|
||||
|
||||
@@ -1137,7 +1137,7 @@ if ($showstockdetails) {
|
||||
print '<td class="right">'.$stock_real.($stock_real < 0 ? ' '.img_warning() : '').'</td>';
|
||||
|
||||
// PMP
|
||||
print '<td class="right nowraponall">'.(price2num($object->pmp) ? price2num($object->pmp, 'MU') : '').'</td>';
|
||||
print '<td class="right nowraponall">'.($usercancreadsupplierprice ? (price2num($object->pmp) ? price2num($object->pmp, 'MU') : '') : '').'</td>';
|
||||
|
||||
// Value purchase
|
||||
if ($usercancreadsupplierprice) {
|
||||
|
||||
@@ -46,7 +46,6 @@ if (!defined('NOREQUIREHTML')) {
|
||||
|
||||
// Load Dolibarr environment
|
||||
require '../../main.inc.php';
|
||||
|
||||
/**
|
||||
* @var Conf $conf
|
||||
* @var DoliDB $db
|
||||
@@ -63,6 +62,7 @@ $discard_closed = GETPOSTINT('discardclosed');
|
||||
// Security check
|
||||
restrictedArea($user, 'projet', 0, 'projet&project');
|
||||
|
||||
|
||||
/*
|
||||
* View
|
||||
*/
|
||||
@@ -94,7 +94,7 @@ if ($mode == 'gettasks') {
|
||||
top_httphead();
|
||||
|
||||
$formproject = new FormProjets($db);
|
||||
$formproject->selectTasks((!empty($socid) ? $socid : -1), 0, 'taskid', 24, 1, '1', 1, 0, 0, 'maxwidth500', (string) GETPOSTINT('projectid'), '');
|
||||
$formproject->selectTasks((!empty($socid) ? $socid : -1), 0, 'taskid', 64, 1, '1', 1, 0, 0, 'maxwidth500', (string) GETPOSTINT('projectid'), '');
|
||||
|
||||
$db->close();
|
||||
|
||||
|
||||
@@ -31,6 +31,13 @@
|
||||
|
||||
// Load Dolibarr environment
|
||||
require '../main.inc.php';
|
||||
/**
|
||||
* @var Conf $conf
|
||||
* @var DoliDB $db
|
||||
* @var HookManager $hookmanager
|
||||
* @var Translate $langs
|
||||
* @var User $user
|
||||
*/
|
||||
require_once DOL_DOCUMENT_ROOT.'/projet/class/project.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/projet/class/task.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/project.lib.php';
|
||||
@@ -41,14 +48,6 @@ require_once DOL_DOCUMENT_ROOT.'/core/modules/project/modules_project.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/class/extrafields.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/categories/class/categorie.class.php';
|
||||
|
||||
/**
|
||||
* @var Conf $conf
|
||||
* @var DoliDB $db
|
||||
* @var HookManager $hookmanager
|
||||
* @var Translate $langs
|
||||
* @var User $user
|
||||
*/
|
||||
|
||||
// Load translation files required by the page
|
||||
$langsLoad = array('projects', 'companies');
|
||||
if (isModEnabled('eventorganization')) {
|
||||
|
||||
@@ -1209,11 +1209,14 @@ if ($search_opp_amount != '') {
|
||||
if ($search_budget_amount != '') {
|
||||
$param .= '&search_budget_amount='.urlencode($search_budget_amount);
|
||||
}
|
||||
if ($search_usage_opportunity != '') {
|
||||
$param .= '&search_usage_opportunity='.urlencode($search_usage_opportunity);
|
||||
}
|
||||
if ($search_usage_task != '') {
|
||||
$param .= '&search_usage_task='.urlencode($search_usage_task);
|
||||
}
|
||||
if ($search_usage_bill_time != '') {
|
||||
$param .= '&search_usage_opportunity='.urlencode($search_usage_bill_time);
|
||||
$param .= '&search_usage_bill_time='.urlencode($search_usage_bill_time);
|
||||
}
|
||||
if ($search_usage_event_organization != '') {
|
||||
$param .= '&search_usage_event_organization='.urlencode($search_usage_event_organization);
|
||||
|
||||
@@ -1828,6 +1828,7 @@ if ($source == 'member' || $source == 'membersubscription') {
|
||||
$pp = 0;
|
||||
include_once DOL_DOCUMENT_ROOT.'/partnership/class/partnership.class.php';
|
||||
$partnership = new Partnership($db);
|
||||
// @phan-suppress-next-line PhanPluginSuspiciousParamPosition
|
||||
$result = $partnership->fetch(0, null, null, $member->thirdparty->id);
|
||||
if ($result > 0) {
|
||||
$pp = 1;
|
||||
|
||||
@@ -4866,7 +4866,7 @@ class Societe extends CommonObject
|
||||
$this->idprof10 = getDolGlobalString('MAIN_INFO_PROFID10');
|
||||
$this->tva_intra = getDolGlobalString('MAIN_INFO_TVAINTRA'); // VAT number, not necessarily INTRA.
|
||||
$this->managers = getDolGlobalString('MAIN_INFO_SOCIETE_MANAGERS');
|
||||
$this->capital = is_numeric(getDolGlobalString('MAIN_INFO_CAPITAL')) ? (float) price2num(getDolGlobalString('MAIN_INFO_CAPITAL')) : null;
|
||||
$this->capital = is_numeric(price2num(getDolGlobalString('MAIN_INFO_CAPITAL'))) ? (float) price2num(getDolGlobalString('MAIN_INFO_CAPITAL')) : null;
|
||||
$this->forme_juridique_code = getDolGlobalInt('MAIN_INFO_SOCIETE_FORME_JURIDIQUE');
|
||||
$this->email = getDolGlobalString('MAIN_INFO_SOCIETE_MAIL');
|
||||
$this->default_lang = getDolGlobalString('MAIN_LANG_DEFAULT', 'auto');
|
||||
|
||||
@@ -816,7 +816,7 @@ input.pageplusone {
|
||||
select:invalid, select.--error {
|
||||
color: gray;
|
||||
}
|
||||
input:disabled, textarea:disabled, select[disabled='disabled']
|
||||
input:disabled:not(.colorthumb), textarea:disabled, select[disabled='disabled']
|
||||
{
|
||||
/* background: var(--inputbackgroundcolordisabled); */
|
||||
/* color: var(--inputcolordisabled); */
|
||||
@@ -884,6 +884,12 @@ input#onlinepaymenturl, input#directdownloadlink {
|
||||
padding: 20px 0px 20px 0px;
|
||||
border-radius: 8px;
|
||||
}
|
||||
.formborder {
|
||||
border: solid 2px #444;
|
||||
padding: 20px;
|
||||
border-radius: 8px;
|
||||
background-color: #fffff4;
|
||||
}
|
||||
|
||||
div#moretabsList, div#moretabsListaction {
|
||||
z-index: 5;
|
||||
@@ -3837,6 +3843,9 @@ img.userphotopublicvcard {
|
||||
img.userphoto[alt="Gravatar avatar"], img.photouserphoto.dropdown-user-image[alt="Gravatar avatar"] {
|
||||
background: #fff;
|
||||
}
|
||||
img.gravatar.photouserphoto {
|
||||
filter: grayscale(50%);
|
||||
}
|
||||
form[name="addtime"] img.userphoto, form[name="addtime"] img.userphotosmall {
|
||||
border: 1px solid #444;
|
||||
}
|
||||
@@ -4228,7 +4237,7 @@ div.popuptab {
|
||||
/* ============================================================================== */
|
||||
|
||||
div.tabsAction {
|
||||
margin: 20px 0em 30px 0em;
|
||||
margin: 20px 0em 40px 0em;
|
||||
padding: 0em 0em;
|
||||
text-align: right;
|
||||
}
|
||||
@@ -5359,6 +5368,8 @@ ul.noborder li:nth-child(even):not(.liste_titre) {
|
||||
|
||||
.clearbothonsmartphone {
|
||||
clear: both;
|
||||
}
|
||||
.clearbothonsmartphone:not(.hideonsmartphone) {
|
||||
display: block !important;
|
||||
}
|
||||
|
||||
@@ -6755,8 +6766,14 @@ span.jPicker {
|
||||
border-collapse: collapse;
|
||||
border: none;
|
||||
}
|
||||
.jPicker tr.Hex td.Text input {
|
||||
width: 60px !important;
|
||||
}
|
||||
.jPicker td.Text input {
|
||||
width: 35px !important;
|
||||
min-width: 40px;
|
||||
padding: 8px;
|
||||
border: 1px solid #bbb !important;
|
||||
border-radius: 4px;
|
||||
}
|
||||
|
||||
A.color, A.color:active, A.color:visited {
|
||||
|
||||
@@ -75,7 +75,7 @@ $fontsizesmaller = '0.75em';
|
||||
$topMenuFontSize = '1.1em';
|
||||
$toolTipBgColor = 'rgba(255, 255, 255, 0.96)';
|
||||
$toolTipFontColor = '#333';
|
||||
$butactionbg = '136, 96, 170';
|
||||
$butactionbg = '116, 96, 170';
|
||||
$textbutaction = '255, 255, 255';
|
||||
|
||||
// text color
|
||||
|
||||
@@ -981,7 +981,7 @@ input.pageplusone {
|
||||
select:invalid, select.--error {
|
||||
color: gray;
|
||||
}
|
||||
input:disabled, textarea:disabled, select[disabled='disabled']
|
||||
input:disabled:not(.colorthumb), textarea:disabled, select[disabled='disabled']
|
||||
{
|
||||
background: var(--inputbackgroundcolordisabled);
|
||||
color: var(--inputcolordisabled);
|
||||
@@ -1049,6 +1049,12 @@ input#onlinepaymenturl, input#directdownloadlink {
|
||||
padding: 20px 0px 20px 0px;
|
||||
border-radius: 8px;
|
||||
}
|
||||
.formborder {
|
||||
border: solid 2px #444;
|
||||
padding: 20px;
|
||||
border-radius: 8px;
|
||||
background-color: #fffff4;
|
||||
}
|
||||
|
||||
div#moretabsList, div#moretabsListaction {
|
||||
z-index: 5;
|
||||
@@ -3894,6 +3900,9 @@ img.userphotosmall { /* size for user photo in lists */
|
||||
img.userphoto[alt="Gravatar avatar"], img.photouserphoto.dropdown-user-image[alt="Gravatar avatar"] {
|
||||
background: #fff;
|
||||
}
|
||||
img.gravatar.photouserphoto {
|
||||
filter: grayscale(50%);
|
||||
}
|
||||
img.userphotopublicvcard {
|
||||
width: 60px;
|
||||
height: 60px;
|
||||
@@ -5360,6 +5369,8 @@ ul.noborder li:nth-child(even):not(.liste_titre) {
|
||||
|
||||
.clearbothonsmartphone {
|
||||
clear: both;
|
||||
}
|
||||
.clearbothonsmartphone:not(.hideonsmartphone) {
|
||||
display: block !important;
|
||||
}
|
||||
|
||||
@@ -6644,8 +6655,14 @@ span.jPicker {
|
||||
border-collapse: collapse;
|
||||
border: none;
|
||||
}
|
||||
.jPicker tr.Hex td.Text input {
|
||||
width: 60px !important;
|
||||
}
|
||||
.jPicker td.Text input {
|
||||
width: 35px !important;
|
||||
min-width: 40px;
|
||||
padding: 8px;
|
||||
border: 1px solid #bbb !important;
|
||||
border-radius: 4px;
|
||||
}
|
||||
|
||||
A.color, A.color:active, A.color:visited {
|
||||
|
||||
Reference in New Issue
Block a user