Update agenda.php
$langs->load("companies") was twice
This commit is contained in:
parent
e5937ef742
commit
95bb6e5ea1
@ -35,12 +35,12 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/resource.lib.php';
|
|||||||
require_once DOL_DOCUMENT_ROOT.'/resource/class/dolresource.class.php';
|
require_once DOL_DOCUMENT_ROOT.'/resource/class/dolresource.class.php';
|
||||||
|
|
||||||
// Load translation files required by the page
|
// Load translation files required by the page
|
||||||
$langs->load("companies");
|
$langs->load('companies');
|
||||||
|
|
||||||
// Get parameters
|
// Get parameters
|
||||||
$id = GETPOST('id', 'int');
|
$id = GETPOST('id', 'int');
|
||||||
$ref = GETPOST('ref', 'alpha');
|
$ref = GETPOST('ref', 'alpha');
|
||||||
$action = GETPOST('action', 'aZ09');
|
$action = GETPOST('action', 'aZ09');
|
||||||
$cancel = GETPOST('cancel', 'aZ09');
|
$cancel = GETPOST('cancel', 'aZ09');
|
||||||
$backtopage = GETPOST('backtopage', 'alpha');
|
$backtopage = GETPOST('backtopage', 'alpha');
|
||||||
|
|
||||||
@ -52,6 +52,7 @@ if (GETPOST('actioncode', 'array')) {
|
|||||||
} else {
|
} else {
|
||||||
$actioncode = GETPOST("actioncode", "alpha", 3) ?GETPOST("actioncode", "alpha", 3) : (GETPOST("actioncode") == '0' ? '0' : (empty($conf->global->AGENDA_DEFAULT_FILTER_TYPE_FOR_OBJECT) ? '' : $conf->global->AGENDA_DEFAULT_FILTER_TYPE_FOR_OBJECT));
|
$actioncode = GETPOST("actioncode", "alpha", 3) ?GETPOST("actioncode", "alpha", 3) : (GETPOST("actioncode") == '0' ? '0' : (empty($conf->global->AGENDA_DEFAULT_FILTER_TYPE_FOR_OBJECT) ? '' : $conf->global->AGENDA_DEFAULT_FILTER_TYPE_FOR_OBJECT));
|
||||||
}
|
}
|
||||||
|
|
||||||
$search_agenda_label = GETPOST('search_agenda_label');
|
$search_agenda_label = GETPOST('search_agenda_label');
|
||||||
|
|
||||||
$limit = GETPOST('limit', 'int') ?GETPOST('limit', 'int') : $conf->liste_limit;
|
$limit = GETPOST('limit', 'int') ?GETPOST('limit', 'int') : $conf->liste_limit;
|
||||||
@ -72,7 +73,7 @@ if (!$sortorder) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Initialize technical objects
|
// Initialize technical objects
|
||||||
//$object=new MyObject($db);
|
|
||||||
$extrafields = new ExtraFields($db);
|
$extrafields = new ExtraFields($db);
|
||||||
$hookmanager->initHooks(array('agendaresource'));
|
$hookmanager->initHooks(array('agendaresource'));
|
||||||
|
|
||||||
@ -94,7 +95,7 @@ if (!$user->rights->resource->read) {
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
$parameters = array('id'=>$id);
|
$parameters = array('id'=>$id);
|
||||||
$reshook = $hookmanager->executeHooks('doActions', $parameters, $object, $action); // Note that $action and $object may have been modified by some hooks
|
$reshook = $hookmanager->executeHooks('doActions', $parameters, $object, $action); // Note that $action and $object may have been modified by some hooks
|
||||||
if ($reshook < 0) {
|
if ($reshook < 0) {
|
||||||
setEventMessages($hookmanager->error, $hookmanager->errors, 'errors');
|
setEventMessages($hookmanager->error, $hookmanager->errors, 'errors');
|
||||||
}
|
}
|
||||||
@ -126,7 +127,6 @@ if ($object->id > 0) {
|
|||||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/company.lib.php';
|
require_once DOL_DOCUMENT_ROOT.'/core/lib/company.lib.php';
|
||||||
require_once DOL_DOCUMENT_ROOT.'/product/class/product.class.php';
|
require_once DOL_DOCUMENT_ROOT.'/product/class/product.class.php';
|
||||||
|
|
||||||
$langs->load("companies");
|
|
||||||
$picto = 'resource';
|
$picto = 'resource';
|
||||||
|
|
||||||
$title = $langs->trans("Agenda");
|
$title = $langs->trans("Agenda");
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user