mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2025-12-06 01:28:19 +01:00
Merge branch '3.5' of https://github.com/Dolibarr/dolibarr.git into 3.5
Conflicts: htdocs/core/modules/commande/doc/pdf_einstein.modules.php
This commit is contained in:
@@ -32,6 +32,7 @@ Fix: Signature was not added for email sent from thirdparty page.
|
||||
Fix: Action event SHIPPING_VALIDATE is not implemented
|
||||
Fix: The customer code was set to uppercase when using numbering module leopard. We
|
||||
must keep data safe of any change.
|
||||
Fix: Loading actions extrafields fails.
|
||||
|
||||
***** ChangeLog for 3.5 compared to 3.4.* *****
|
||||
For users:
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
* Copyright (C) 2004-2013 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2005 Simon TOSSER <simon@kornog-computing.com>
|
||||
* Copyright (C) 2005-2012 Regis Houssin <regis.houssin@capnetworks.com>
|
||||
* Copyright (C) 2010 Juanjo Menent <jmenent@2byte.es>
|
||||
* Copyright (C) 2010-2013 Juanjo Menent <jmenent@2byte.es>
|
||||
* Copyright (C) 2013 Florian Henry <florian.henry@open-concept.pro>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
@@ -863,7 +863,7 @@ if ($id > 0)
|
||||
$reshook=$hookmanager->executeHooks('formObjectOptions',$parameters,$act,$action); // Note that $action and $object may have been modified by hook
|
||||
if (empty($reshook) && ! empty($extrafields->attribute_label))
|
||||
{
|
||||
print $actioncomm->showOptionals($extrafields,'edit');
|
||||
print $act->showOptionals($extrafields,'edit');
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -2364,7 +2364,7 @@ class Form
|
||||
*
|
||||
* @param string $selected Id account pre-selected
|
||||
* @param string $htmlname Name of select zone
|
||||
* @param int $statut Status of searched accounts (0=open, 1=closed)
|
||||
* @param int $statut Status of searched accounts (0=open, 1=closed, 2=both)
|
||||
* @param string $filtre To filter list
|
||||
* @param int $useempty 1=Add an empty value in list, 2=Add an empty value in list only if there is more than 2 entries.
|
||||
* @param string $moreattrib To add more attribute on select
|
||||
@@ -2376,10 +2376,10 @@ class Form
|
||||
|
||||
$langs->load("admin");
|
||||
|
||||
$sql = "SELECT rowid, label, bank";
|
||||
$sql = "SELECT rowid, label, bank, clos as status";
|
||||
$sql.= " FROM ".MAIN_DB_PREFIX."bank_account";
|
||||
$sql.= " WHERE clos = '".$statut."'";
|
||||
$sql.= " AND entity IN (".getEntity('bank_account', 1).")";
|
||||
$sql.= " WHERE entity IN (".getEntity('bank_account', 1).")";
|
||||
if ($statut != 2) $sql.= " AND clos = '".$statut."'";
|
||||
if ($filtre) $sql.=" AND ".$filtre;
|
||||
$sql.= " ORDER BY label";
|
||||
|
||||
@@ -2409,6 +2409,7 @@ class Form
|
||||
print '<option value="'.$obj->rowid.'">';
|
||||
}
|
||||
print $obj->label;
|
||||
if ($statut == 2 && $obj->status == 1) print ' ('.$langs->trans("Closed").')';
|
||||
print '</option>';
|
||||
$i++;
|
||||
}
|
||||
|
||||
@@ -547,15 +547,12 @@ class Menubase
|
||||
$tmpcond=$menu['enabled'];
|
||||
if ($leftmenu == 'all') $tmpcond=preg_replace('/\$leftmenu\s*==\s*["\'a-zA-Z_]+/','1==1',$tmpcond); // Force part of condition to true
|
||||
$enabled = verifCond($tmpcond);
|
||||
if ($conf->use_javascript_ajax && ! empty($conf->global->MAIN_MENU_USE_JQUERY_ACCORDION) && preg_match('/^\$leftmenu/',$menu['enabled'])) $enabled=1;
|
||||
//print "verifCond rowid=".$menu['rowid']." ".$tmpcond.":".$enabled."<br>\n";
|
||||
//if ($conf->use_javascript_ajax && ! empty($conf->global->MAIN_MENU_USE_JQUERY_ACCORDION) && empty($conf->dol_use_jmobile) && preg_match('/^\$leftmenu/',$menu['enabled'])) $enabled=1;
|
||||
}
|
||||
|
||||
// Define $title
|
||||
if ($enabled)
|
||||
{
|
||||
//$tmp3=dol_microtime_float();
|
||||
//print '>>> 2 '.($tmp3 - $tmp1).'<br>';
|
||||
$title = $langs->trans($menu['titre']);
|
||||
if ($title == $menu['titre']) // Translation not found
|
||||
{
|
||||
|
||||
@@ -609,6 +609,37 @@ class pdf_einstein extends ModelePDFCommandes
|
||||
$posy=$pdf->GetY()+1;
|
||||
}*/
|
||||
|
||||
// Show shipping date
|
||||
if ($object->date_livraison)
|
||||
{
|
||||
$outputlangs->load("sendings");
|
||||
$pdf->SetFont('','B', $default_font_size - 2);
|
||||
$pdf->SetXY($this->marge_gauche, $posy);
|
||||
$titre = $outputlangs->transnoentities("DateDeliveryPlanned").':';
|
||||
$pdf->MultiCell(80, 4, $titre, 0, 'L');
|
||||
$pdf->SetFont('','', $default_font_size - 2);
|
||||
$pdf->SetXY($posxval, $posy);
|
||||
$dlp=dol_print_date($object->date_livraison,"daytext",false,$outputlangs,true);
|
||||
$pdf->MultiCell(80, 4, $dlp, 0, 'L');
|
||||
|
||||
$posy=$pdf->GetY()+1;
|
||||
}
|
||||
elseif ($object->availability_code || $object->availability) // Show availability conditions
|
||||
{
|
||||
$pdf->SetFont('','B', $default_font_size - 2);
|
||||
$pdf->SetXY($this->marge_gauche, $posy);
|
||||
$titre = $outputlangs->transnoentities("AvailabilityPeriod").':';
|
||||
$pdf->MultiCell(80, 4, $titre, 0, 'L');
|
||||
$pdf->SetTextColor(0,0,0);
|
||||
$pdf->SetFont('','', $default_font_size - 2);
|
||||
$pdf->SetXY($posxval, $posy);
|
||||
$lib_availability=$outputlangs->transnoentities("AvailabilityType".$object->availability_code)!=('AvailabilityType'.$object->availability_code)?$outputlangs->transnoentities("AvailabilityType".$object->availability_code):$outputlangs->convToOutputCharset($object->availability);
|
||||
$lib_availability=str_replace('\n',"\n",$lib_availability);
|
||||
$pdf->MultiCell(80, 4, $lib_availability, 0, 'L');
|
||||
|
||||
$posy=$pdf->GetY()+1;
|
||||
}
|
||||
|
||||
// Show payment mode
|
||||
if ($object->mode_reglement_code
|
||||
&& $object->mode_reglement_code != 'CHQ'
|
||||
|
||||
@@ -261,7 +261,7 @@ if (! empty($conf->file->main_force_https))
|
||||
}
|
||||
|
||||
|
||||
// Loading of additional presentation includes
|
||||
// Loading of additional presentation includes
|
||||
if (! defined('NOREQUIREHTML')) require_once DOL_DOCUMENT_ROOT .'/core/class/html.form.class.php'; // Need 660ko memory (800ko in 2.2)
|
||||
if (! defined('NOREQUIREAJAX') && $conf->use_javascript_ajax) require_once DOL_DOCUMENT_ROOT.'/core/lib/ajax.lib.php'; // Need 22ko memory
|
||||
|
||||
@@ -1084,7 +1084,7 @@ function top_htmlhead($head, $title='', $disablejs=0, $disablehead=0, $arrayofjs
|
||||
print '<script type="text/javascript" src="'.DOL_URL_ROOT.'/includes/jquery/plugins/tablednd/jquery.tablednd.0.6.min.js'.($ext?'?'.$ext:'').'"></script>'."\n";
|
||||
print '<script type="text/javascript" src="'.DOL_URL_ROOT.'/includes/jquery/plugins/tiptip/jquery.tipTip.min.js'.($ext?'?'.$ext:'').'"></script>'."\n";
|
||||
// jQuery Layout
|
||||
if (! empty($conf->global->MAIN_MENU_USE_JQUERY_LAYOUT) || defined('REQUIRE_JQUERY_LAYOUT'))
|
||||
if (empty($conf->dol_use_jmobile) && ! empty($conf->global->MAIN_MENU_USE_JQUERY_LAYOUT) || defined('REQUIRE_JQUERY_LAYOUT'))
|
||||
{
|
||||
print '<script type="text/javascript" src="'.DOL_URL_ROOT.'/includes/jquery/plugins/layout/jquery.layout-latest.js'.($ext?'?'.$ext:'').'"></script>'."\n";
|
||||
}
|
||||
@@ -1293,7 +1293,7 @@ function top_menu($head, $title='', $target='', $disablejs=0, $disablehead=0, $a
|
||||
|
||||
if ($conf->use_javascript_ajax)
|
||||
{
|
||||
if (! empty($conf->global->MAIN_MENU_USE_JQUERY_LAYOUT))
|
||||
if (empty($conf->dol_use_jmobile) && ! empty($conf->global->MAIN_MENU_USE_JQUERY_LAYOUT))
|
||||
{
|
||||
print '<script type="text/javascript">
|
||||
jQuery(document).ready(function () {
|
||||
@@ -1347,7 +1347,8 @@ function top_menu($head, $title='', $target='', $disablejs=0, $disablehead=0, $a
|
||||
</script>';
|
||||
}
|
||||
|
||||
if (! empty($conf->global->MAIN_MENU_USE_JQUERY_ACCORDION))
|
||||
/* This make menu bugged
|
||||
if ($conf->use_javascript_ajax && ! empty($conf->global->MAIN_MENU_USE_JQUERY_ACCORDION) && empty($conf->dol_use_jmobile))
|
||||
{
|
||||
print "\n".'<script type="text/javascript">
|
||||
jQuery(document).ready(function () {
|
||||
@@ -1360,7 +1361,7 @@ function top_menu($head, $title='', $target='', $disablejs=0, $disablehead=0, $a
|
||||
});
|
||||
});
|
||||
</script>';
|
||||
}
|
||||
} */
|
||||
|
||||
// Wrapper to show tooltips
|
||||
print "\n".'<script type="text/javascript">
|
||||
@@ -1377,7 +1378,7 @@ function top_menu($head, $title='', $target='', $disablejs=0, $disablehead=0, $a
|
||||
*/
|
||||
print "\n".'<!-- Start top horizontal -->'."\n";
|
||||
|
||||
if (! empty($conf->use_javascript_ajax) && ! empty($conf->global->MAIN_MENU_USE_JQUERY_LAYOUT)) print '<div class="ui-layout-north"> <!-- Begin top layout -->'."\n";
|
||||
if (empty($conf->dol_use_jmobile) && ! empty($conf->use_javascript_ajax) && ! empty($conf->global->MAIN_MENU_USE_JQUERY_LAYOUT)) print '<div class="ui-layout-north"> <!-- Begin top layout -->'."\n";
|
||||
|
||||
if (empty($conf->dol_hide_topmenu))
|
||||
{
|
||||
@@ -1496,11 +1497,11 @@ function top_menu($head, $title='', $target='', $disablejs=0, $disablehead=0, $a
|
||||
unset($form);
|
||||
}
|
||||
|
||||
if (! empty($conf->use_javascript_ajax) && ! empty($conf->global->MAIN_MENU_USE_JQUERY_LAYOUT)) print "</div><!-- End top layout -->\n";
|
||||
if (empty($conf->dol_use_jmobile) && ! empty($conf->use_javascript_ajax) && ! empty($conf->global->MAIN_MENU_USE_JQUERY_LAYOUT)) print "</div><!-- End top layout -->\n";
|
||||
print '<div style="clear: both;"></div>';
|
||||
print "<!-- End top horizontal menu -->\n\n";
|
||||
|
||||
if (empty($conf->dol_hide_leftmenu) && (empty($conf->use_javascript_ajax) || empty($conf->global->MAIN_MENU_USE_JQUERY_LAYOUT))) print '<div id="id-container">';
|
||||
if (empty($conf->dol_hide_leftmenu) && (empty($conf->use_javascript_ajax) || ! empty($conf->dol_use_jmobile) || empty($conf->global->MAIN_MENU_USE_JQUERY_LAYOUT))) print '<div id="id-container">';
|
||||
}
|
||||
|
||||
|
||||
@@ -1530,7 +1531,7 @@ function left_menu($menu_array_before, $helppagename='', $moresearchform='', $me
|
||||
// Instantiate hooks of thirdparty module
|
||||
$hookmanager->initHooks(array('searchform','leftblock'));
|
||||
|
||||
if (! empty($conf->use_javascript_ajax) && ! empty($conf->global->MAIN_MENU_USE_JQUERY_LAYOUT)) print "\n".'<div class="ui-layout-west"> <!-- Begin left layout -->'."\n";
|
||||
if (empty($conf->dol_use_jmobile) && ! empty($conf->use_javascript_ajax) && ! empty($conf->global->MAIN_MENU_USE_JQUERY_LAYOUT)) print "\n".'<div class="ui-layout-west"> <!-- Begin left layout -->'."\n";
|
||||
else print '<div id="id-left">';
|
||||
|
||||
print "\n";
|
||||
@@ -1708,8 +1709,7 @@ function left_menu($menu_array_before, $helppagename='', $moresearchform='', $me
|
||||
$leftblock=$hookmanager->executeHooks('printLeftBlock',$parameters); // Note that $action and $object may have been modified by some hooks
|
||||
print $leftblock;
|
||||
|
||||
if (! empty($conf->use_javascript_ajax) && ! empty($conf->global->MAIN_MENU_USE_JQUERY_LAYOUT)) print '</div> <!-- End left layout -->'."\n";
|
||||
//XXX else print '</td>';
|
||||
if (empty($conf->dol_use_jmobile) && ! empty($conf->use_javascript_ajax) && ! empty($conf->global->MAIN_MENU_USE_JQUERY_LAYOUT)) print '</div> <!-- End left layout -->'."\n";
|
||||
else print '</div>'; // End div id="id-left"
|
||||
}
|
||||
|
||||
@@ -1731,12 +1731,10 @@ function main_area($title='')
|
||||
{
|
||||
global $conf, $langs;
|
||||
|
||||
if (! empty($conf->use_javascript_ajax) && ! empty($conf->global->MAIN_MENU_USE_JQUERY_LAYOUT))
|
||||
if (empty($conf->dol_use_jmobile) && ! empty($conf->use_javascript_ajax) && ! empty($conf->global->MAIN_MENU_USE_JQUERY_LAYOUT))
|
||||
{
|
||||
print '<div id="mainContent"><div class="ui-layout-center"> <!-- begin main layout -->'."\n";
|
||||
//print '<table width="100%" class="notopnoleftnoright" summary="centermenutable" id="undertopmenu"><tr>';
|
||||
}
|
||||
//XXX print '<td valign="top">'."\n";
|
||||
if (empty($conf->dol_hide_leftmenu)) print '<div id="id-right">';
|
||||
|
||||
print "\n";
|
||||
@@ -1864,8 +1862,7 @@ if (! function_exists("llxFooter"))
|
||||
print '</div> <!-- end div class="fiche" -->'."\n";
|
||||
if (! empty($conf->dol_use_jmobile)) print '</div>'; // end data-role="page"
|
||||
|
||||
//XXX print "\n".'</td></tr></table> <!-- end right area -->'."\n";
|
||||
if (! empty($conf->use_javascript_ajax) && ! empty($conf->global->MAIN_MENU_USE_JQUERY_LAYOUT)) print '</div></div> <!-- end main layout -->'."\n";
|
||||
if (empty($conf->dol_use_jmobile) && ! empty($conf->use_javascript_ajax) && ! empty($conf->global->MAIN_MENU_USE_JQUERY_LAYOUT)) print '</div></div> <!-- end main layout -->'."\n";
|
||||
if (empty($conf->dol_hide_leftmenu)) print '</div>'; // End div id-right
|
||||
|
||||
print "\n";
|
||||
|
||||
@@ -1345,7 +1345,7 @@ div.divButAction { margin-bottom: 1.4em; }
|
||||
|
||||
.butActionRefused {
|
||||
background: #FFe7ec;
|
||||
color: #666;
|
||||
color: #aaa !important;
|
||||
}
|
||||
|
||||
<?php if (! empty($conf->global->MAIN_BUTTON_HIDE_UNAUTHORIZED)) { ?>
|
||||
@@ -1602,6 +1602,7 @@ tr.pair td.nohover {
|
||||
-webkit-box-shadow: 4px 4px 4px #DDD;
|
||||
box-shadow: 4px 4px 4px #DDD;
|
||||
margin-bottom: 8px !important;*/
|
||||
background: #FFFFFF;
|
||||
border: 1px solid #AAA;
|
||||
text-align: center;
|
||||
border-radius: 5px;
|
||||
|
||||
Reference in New Issue
Block a user