Merge pull request #10268 from hregis/develop_upgrade
FIX remove old unused and deprecated function "getStaticMember"
This commit is contained in:
commit
422e18ee8e
@ -57,7 +57,7 @@ llxHeader('', $langs->trans($page_name));
|
||||
// Subheader
|
||||
$linkback = '<a href="' . DOL_URL_ROOT . '/admin/modules.php">'
|
||||
. $langs->trans("BackToModuleList") . '</a>';
|
||||
print_fiche_titre($langs->trans($page_name), $linkback);
|
||||
print load_fiche_titre($langs->trans($page_name), $linkback);
|
||||
|
||||
// Configuration header
|
||||
|
||||
|
||||
@ -253,7 +253,7 @@ dol_fiche_end();
|
||||
* Projects Numbering model
|
||||
*/
|
||||
|
||||
print_titre($langs->trans("TicketNumberingModules"));
|
||||
print load_fiche_titre($langs->trans("TicketNumberingModules"));
|
||||
|
||||
print '<table class="noborder" width="100%">';
|
||||
print '<tr class="liste_titre">';
|
||||
@ -353,7 +353,7 @@ if (!$conf->use_javascript_ajax) {
|
||||
print '<input type="hidden" name="token" value="' . $_SESSION['newtoken'] . '">';
|
||||
print '<input type="hidden" name="action" value="setvarother">';
|
||||
}
|
||||
print_titre($langs->trans("TicketParamPublicInterface"));
|
||||
print load_fiche_titre($langs->trans("TicketParamPublicInterface"));
|
||||
|
||||
print '<table class="noborder" width="100%">';
|
||||
|
||||
@ -422,7 +422,7 @@ print '</tr>';
|
||||
|
||||
print '</table><br>';
|
||||
|
||||
print_titre($langs->trans("TicketParams"));
|
||||
print load_fiche_titre($langs->trans("TicketParams"));
|
||||
print '<table class="noborder" width="100%">';
|
||||
|
||||
// Activate email notifications
|
||||
@ -515,7 +515,7 @@ if (!$conf->use_javascript_ajax) {
|
||||
}
|
||||
|
||||
// Admin var of module
|
||||
print_titre($langs->trans("TicketParamMail"));
|
||||
print load_fiche_titre($langs->trans("TicketParamMail"));
|
||||
|
||||
print '<table class="noborder" width="100%">';
|
||||
|
||||
|
||||
@ -92,7 +92,7 @@ if ($action != 'create' && $action != 'edit') {
|
||||
|
||||
if ($action == 'create') {
|
||||
print "<br>";
|
||||
print_titre($langs->trans('NewAttribute'));
|
||||
print load_fiche_titre($langs->trans('NewAttribute'));
|
||||
|
||||
include DOL_DOCUMENT_ROOT . '/core/tpl/admin_extrafields_add.tpl.php';
|
||||
}
|
||||
@ -104,7 +104,7 @@ if ($action == 'create') {
|
||||
/* ************************************************************************** */
|
||||
if ($action == 'edit' && !empty($attrname)) {
|
||||
print "<br>";
|
||||
print_titre($langs->trans("FieldEdition", $attrname));
|
||||
print load_fiche_titre($langs->trans("FieldEdition", $attrname));
|
||||
|
||||
include DOL_DOCUMENT_ROOT . '/core/tpl/admin_extrafields_edit.tpl.php';
|
||||
}
|
||||
|
||||
@ -463,7 +463,7 @@ if (! empty($conf->salaries->enabled) && ! empty($user->rights->salaries->read))
|
||||
|
||||
print "<br>";
|
||||
|
||||
print_fiche_titre( $langs->trans("SalariesPayments").($year?' ('.$langs->trans("Year").' '.$year.')':''), '', '');
|
||||
print load_fiche_titre( $langs->trans("SalariesPayments").($year?' ('.$langs->trans("Year").' '.$year.')':''), '', '');
|
||||
|
||||
$sql = "SELECT s.rowid, s.amount, s.label, s.datep as datep, s.datev as datev, s.datesp, s.dateep, s.salary, s.fk_bank, u.salary as current_salary,";
|
||||
$sql.= " pct.code as payment_code,";
|
||||
|
||||
@ -405,7 +405,7 @@ if (! empty($conf->salaries->enabled) && ! empty($user->rights->salaries->read))
|
||||
|
||||
print "<br>";
|
||||
|
||||
print_fiche_titre($langs->trans("SalariesPayments").($year?' ('.$langs->trans("Year").' '.$year.')':''), '', '');
|
||||
print load_fiche_titre($langs->trans("SalariesPayments").($year?' ('.$langs->trans("Year").' '.$year.')':''), '', '');
|
||||
|
||||
$sql = "SELECT s.rowid, s.amount, s.label, s.datep as datep, s.datev as datev, s.datesp, s.dateep, s.salary, u.salary as current_salary";
|
||||
$sql.= " FROM ".MAIN_DB_PREFIX."payment_salary as s, ".MAIN_DB_PREFIX."user as u";
|
||||
|
||||
@ -682,7 +682,7 @@ else
|
||||
// Jabber
|
||||
if (! empty($conf->global->SOCIALNETWORKS_JABBER))
|
||||
{
|
||||
print '<tr><td><label for="skype">'.fieldLabel('Jabber','jabberid').'</label></td>';
|
||||
print '<tr><td><label for="skype">'.$form->editfieldkey('Jabber','jabberid', '', $object, 0).'</label></td>';
|
||||
print '<td colspan="3"><input type="text" name="jabberid" id="jabberid" class="minwidth100" maxlength="80" value="'.dol_escape_htmltag(GETPOSTISSET("jabberid")?GETPOST("jabberid",'alpha'):$object->jabberid).'"></td></tr>';
|
||||
}
|
||||
// Skype
|
||||
@ -968,7 +968,7 @@ else
|
||||
// Jabber ID
|
||||
if (! empty($conf->global->SOCIALNETWORKS_JABBER))
|
||||
{
|
||||
print '<tr><td><label for="jabberid">'.fieldLabel('Jabber','jabberid').'</label></td>';
|
||||
print '<tr><td><label for="jabberid">'.$form->editfieldkey('Jabber','jabberid', '', $object, 0).'</label></td>';
|
||||
print '<td><input type="text" name="jabberid" id="jabberid" class="minwidth100" maxlength="80" value="'.dol_escape_htmltag(GETPOSTISSET("jabberid")?GETPOST("jabberid",'alpha'):$object->jabberid).'"></td></tr>';
|
||||
}
|
||||
// Skype
|
||||
|
||||
@ -39,48 +39,6 @@
|
||||
include_once DOL_DOCUMENT_ROOT .'/core/lib/json.lib.php';
|
||||
|
||||
|
||||
/**
|
||||
* Function to return value of a static property when class
|
||||
* name is dynamically defined (not hard coded).
|
||||
* This is because $myclass::$myvar works from PHP 5.3.0+ only
|
||||
*
|
||||
* @param string $class Class name
|
||||
* @param string $member Name of property
|
||||
* @return mixed Return value of static property
|
||||
* @deprecated Dolibarr now requires 5.3.0+, use $class::$property syntax
|
||||
* @see https://php.net/manual/language.oop5.static.php
|
||||
*/
|
||||
function getStaticMember($class, $member)
|
||||
{
|
||||
dol_syslog(__FUNCTION__ . " is deprecated", LOG_WARNING);
|
||||
|
||||
// This part is deprecated. Uncomment if for php 5.2.*, and comment next isset class::member
|
||||
/*if (version_compare(phpversion(), '5.3.0', '<'))
|
||||
{
|
||||
if (is_object($class)) $class = get_class($class);
|
||||
$classObj = new ReflectionClass($class);
|
||||
$result = null;
|
||||
|
||||
$found=0;
|
||||
foreach($classObj->getStaticProperties() as $prop => $value)
|
||||
{
|
||||
if ($prop == $member)
|
||||
{
|
||||
$result = $value;
|
||||
$found++;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if ($found) return $result;
|
||||
}*/
|
||||
|
||||
if (isset($class::$member)) return $class::$member;
|
||||
dol_print_error('','Try to get a static member "'.$member.'" in class "'.$class.'" that does not exists or is not static.');
|
||||
return null;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Return a DoliDB instance (database handler).
|
||||
*
|
||||
|
||||
@ -47,7 +47,7 @@ print '<script type="text/javascript" language="javascript">
|
||||
</script>';
|
||||
|
||||
|
||||
print_fiche_titre($langs->trans("AdvTgtTitle"));
|
||||
print load_fiche_titre($langs->trans("AdvTgtTitle"));
|
||||
|
||||
print '<div class="tabBar">' . "\n";
|
||||
print '<form name="find_customer" id="find_customer" action="' . $_SERVER['PHP_SELF'] . '?id=' . $id . '" method="POST">' . "\n";
|
||||
@ -520,7 +520,7 @@ print '<script type="text/javascript" language="javascript">
|
||||
|
||||
print '<form action="' . $_SERVER['PHP_SELF'] . '?action=clear&id=' . $object->id . '" method="POST">';
|
||||
print '<input type="hidden" name="token" value="' . $_SESSION['newtoken'] . '">';
|
||||
print_titre($langs->trans("ToClearAllRecipientsClickHere"));
|
||||
print load_fiche_titre($langs->trans("ToClearAllRecipientsClickHere"));
|
||||
print '<table class="noborder" width="100%">';
|
||||
print '<tr class="liste_titre">';
|
||||
print '<td class="liste_titre" align="right"><input type="submit" class="button" value="' . $langs->trans("TargetsReset") . '"></td>';
|
||||
|
||||
@ -54,7 +54,7 @@ $listhalfday=array('morning'=>$langs->trans("Morning"),"afternoon"=>$langs->tran
|
||||
|
||||
llxHeader('', $langs->trans('CPTitreMenu'));
|
||||
|
||||
print_fiche_titre($langs->trans('MenuReportMonth'));
|
||||
print load_fiche_titre($langs->trans('MenuReportMonth'));
|
||||
|
||||
$html = new Form($db);
|
||||
$formother = new FormOther($db);
|
||||
|
||||
@ -143,7 +143,7 @@ $title = $langs->trans("Margins");
|
||||
|
||||
llxHeader('', $title);
|
||||
|
||||
// print_fiche_titre($text);
|
||||
// print load_fiche_titre($text);
|
||||
|
||||
$param='';
|
||||
if (! empty($contextpage) && $contextpage != $_SERVER["PHP_SELF"]) $param.='&contextpage='.$contextpage;
|
||||
|
||||
@ -949,7 +949,7 @@ if (! $variants) {
|
||||
|
||||
if (!empty($conf->global->STOCK_ALLOW_ADD_LIMIT_STOCK_BY_WAREHOUSE)) {
|
||||
print '<br><br>';
|
||||
print_titre($langs->trans('AddNewProductStockWarehouse'));
|
||||
print load_fiche_titre($langs->trans('AddNewProductStockWarehouse'));
|
||||
|
||||
if (!empty($user->rights->produit->creer)) {
|
||||
print '<form action="' . $_SERVER["PHP_SELF"] . '" method="POST">';
|
||||
|
||||
@ -1212,7 +1212,7 @@ class ActionsTicket
|
||||
$this->viewTicketOriginalMessage($user, $action);
|
||||
|
||||
if (is_array($this->dao->cache_msgs_ticket) && count($this->dao->cache_msgs_ticket) > 0) {
|
||||
print_titre($langs->trans('TicketMailExchanges'));
|
||||
print load_fiche_titre($langs->trans('TicketMailExchanges'));
|
||||
|
||||
print '<table class="border" style="width:100%;">';
|
||||
|
||||
|
||||
@ -32,7 +32,7 @@ $langs = $GLOBALS['langs'];
|
||||
$langs->load('ticket');
|
||||
$linkedObjectBlock = $GLOBALS['linkedObjectBlock'];
|
||||
echo '<br>';
|
||||
print_titre($langs->trans('RelatedTickets'));
|
||||
print load_fiche_titre($langs->trans('RelatedTickets'));
|
||||
?>
|
||||
<table class="noborder" width="100%">
|
||||
<tr class="liste_titre">
|
||||
|
||||
@ -408,7 +408,7 @@ if (! empty($id) || ! empty($ref))
|
||||
} else {
|
||||
$title = $langs->trans('EditProductCombination');
|
||||
}
|
||||
print_fiche_titre($title);
|
||||
print load_fiche_titre($title);
|
||||
|
||||
if ($action == 'add') {
|
||||
$prodattr_all = $prodattr->fetchAll();
|
||||
|
||||
Loading…
Reference in New Issue
Block a user