Debug module ticket
This commit is contained in:
parent
9b7ec2dbc8
commit
8bf8beb898
@ -375,6 +375,20 @@ if ($mode == 'other') {
|
|||||||
print '<td class="titlefieldmiddle"></td>';
|
print '<td class="titlefieldmiddle"></td>';
|
||||||
print '</tr>';
|
print '</tr>';
|
||||||
|
|
||||||
|
// Show Quick Add link
|
||||||
|
print '<tr class="oddeven"><td>' . $langs->trans("ShowQuickAddLink") . '</td><td>';
|
||||||
|
print ajax_constantonoff("MAIN_USE_TOP_MENU_QUICKADD_DROPDOWN", array(), $conf->entity, 0, 0, 1, 0, 0, 0, '', 'other');
|
||||||
|
print '</td>';
|
||||||
|
print '</tr>';
|
||||||
|
|
||||||
|
// Hide wiki link on login page
|
||||||
|
$pictohelp = '<span class="fa fa-question-circle"></span>';
|
||||||
|
print '<tr class="oddeven"><td>' . str_replace('{picto}', $pictohelp, $langs->trans("DisableLinkToHelp", '{picto}')) . '</td><td>';
|
||||||
|
print ajax_constantonoff("MAIN_HELP_DISABLELINK", array(), $conf->entity, 0, 0, 1, 0, 0, 0, '', 'other');
|
||||||
|
//print $form->selectyesno('MAIN_HELP_DISABLELINK', isset($conf->global->MAIN_HELP_DISABLELINK) ? $conf->global->MAIN_HELP_DISABLELINK : 0, 1);
|
||||||
|
print '</td>';
|
||||||
|
print '</tr>';
|
||||||
|
|
||||||
// Max size of lists
|
// Max size of lists
|
||||||
print '<tr class="oddeven"><td>' . $langs->trans("DefaultMaxSizeList") . '</td><td><input class="flat" name="main_size_liste_limit" size="4" value="' . $conf->global->MAIN_SIZE_LISTE_LIMIT . '"></td>';
|
print '<tr class="oddeven"><td>' . $langs->trans("DefaultMaxSizeList") . '</td><td><input class="flat" name="main_size_liste_limit" size="4" value="' . $conf->global->MAIN_SIZE_LISTE_LIMIT . '"></td>';
|
||||||
print '</tr>';
|
print '</tr>';
|
||||||
@ -439,12 +453,6 @@ if ($mode == 'other') {
|
|||||||
print '</tr>';
|
print '</tr>';
|
||||||
*/
|
*/
|
||||||
|
|
||||||
// Show Quick Add link
|
|
||||||
print '<tr class="oddeven"><td>' . $langs->trans("ShowQuickAddLink") . '</td><td>';
|
|
||||||
print ajax_constantonoff("MAIN_USE_TOP_MENU_QUICKADD_DROPDOWN", array(), $conf->entity, 0, 0, 1, 0, 0, 0, '', 'other');
|
|
||||||
print '</td>';
|
|
||||||
print '</tr>';
|
|
||||||
|
|
||||||
// Show bugtrack link
|
// Show bugtrack link
|
||||||
print '<tr class="oddeven"><td>';
|
print '<tr class="oddeven"><td>';
|
||||||
print $form->textwithpicto($langs->trans("ShowBugTrackLink", $langs->transnoentitiesnoconv("FindBug")), $langs->trans("ShowBugTrackLinkDesc"));
|
print $form->textwithpicto($langs->trans("ShowBugTrackLink", $langs->transnoentitiesnoconv("FindBug")), $langs->trans("ShowBugTrackLinkDesc"));
|
||||||
@ -453,14 +461,6 @@ if ($mode == 'other') {
|
|||||||
print '</td>';
|
print '</td>';
|
||||||
print '</tr>';
|
print '</tr>';
|
||||||
|
|
||||||
// Hide wiki link on login page
|
|
||||||
$pictohelp = '<span class="fa fa-question-circle"></span>';
|
|
||||||
print '<tr class="oddeven"><td>' . str_replace('{picto}', $pictohelp, $langs->trans("DisableLinkToHelp", '{picto}')) . '</td><td>';
|
|
||||||
print ajax_constantonoff("MAIN_HELP_DISABLELINK", array(), $conf->entity, 0, 0, 1, 0, 0, 0, '', 'other');
|
|
||||||
//print $form->selectyesno('MAIN_HELP_DISABLELINK', isset($conf->global->MAIN_HELP_DISABLELINK) ? $conf->global->MAIN_HELP_DISABLELINK : 0, 1);
|
|
||||||
print '</td>';
|
|
||||||
print '</tr>';
|
|
||||||
|
|
||||||
// Disable javascript and ajax
|
// Disable javascript and ajax
|
||||||
print '<tr class="oddeven"><td>' . $form->textwithpicto($langs->trans("DisableJavascript"), $langs->trans("DisableJavascriptNote")) . '</td><td>';
|
print '<tr class="oddeven"><td>' . $form->textwithpicto($langs->trans("DisableJavascript"), $langs->trans("DisableJavascriptNote")) . '</td><td>';
|
||||||
print ajax_constantonoff("MAIN_DISABLE_JAVASCRIPT", array(), $conf->entity, 0, 0, 1, 0, 0, 0, '', 'other');
|
print ajax_constantonoff("MAIN_DISABLE_JAVASCRIPT", array(), $conf->entity, 0, 0, 1, 0, 0, 0, '', 'other');
|
||||||
|
|||||||
@ -101,7 +101,7 @@ if ($action == 'setTICKET_ENABLE_PUBLIC_INTERFACE') {
|
|||||||
}
|
}
|
||||||
|
|
||||||
$text_home = GETPOST('TICKET_PUBLIC_TEXT_HOME', 'restricthtml');
|
$text_home = GETPOST('TICKET_PUBLIC_TEXT_HOME', 'restricthtml');
|
||||||
if (!empty($text_home)) {
|
if (GETPOSTISSET('TICKET_PUBLIC_TEXT_HOME')) {
|
||||||
$res = dolibarr_set_const($db, 'TICKET_PUBLIC_TEXT_HOME', $text_home, 'chaine', 0, '', $conf->entity);
|
$res = dolibarr_set_const($db, 'TICKET_PUBLIC_TEXT_HOME', $text_home, 'chaine', 0, '', $conf->entity);
|
||||||
} else {
|
} else {
|
||||||
$res = dolibarr_set_const($db, 'TICKET_PUBLIC_TEXT_HOME', $langs->trans('TicketPublicInterfaceTextHome'), 'chaine', 0, '', $conf->entity);
|
$res = dolibarr_set_const($db, 'TICKET_PUBLIC_TEXT_HOME', $langs->trans('TicketPublicInterfaceTextHome'), 'chaine', 0, '', $conf->entity);
|
||||||
@ -371,8 +371,8 @@ if (!empty($conf->global->TICKET_ENABLE_PUBLIC_INTERFACE)) {
|
|||||||
print $form->textwithpicto('', $langs->trans("TicketPublicInterfaceTopicHelp"), 1, 'help');
|
print $form->textwithpicto('', $langs->trans("TicketPublicInterfaceTopicHelp"), 1, 'help');
|
||||||
print '</td></tr>';
|
print '</td></tr>';
|
||||||
|
|
||||||
// Texte d'accueil homepage
|
// Text on home page
|
||||||
$public_text_home = $conf->global->TICKET_PUBLIC_TEXT_HOME ? $conf->global->TICKET_PUBLIC_TEXT_HOME : $langs->trans('TicketPublicInterfaceTextHome');
|
$public_text_home = getDolGlobalString('TICKET_PUBLIC_TEXT_HOME', '<span class="opacitymedium">'.$langs->trans("TicketPublicDesc").'</span>');
|
||||||
print '<tr><td>'.$langs->trans("TicketPublicInterfaceTextHomeLabelAdmin").'</label>';
|
print '<tr><td>'.$langs->trans("TicketPublicInterfaceTextHomeLabelAdmin").'</label>';
|
||||||
print '</td><td>';
|
print '</td><td>';
|
||||||
require_once DOL_DOCUMENT_ROOT.'/core/class/doleditor.class.php';
|
require_once DOL_DOCUMENT_ROOT.'/core/class/doleditor.class.php';
|
||||||
@ -383,7 +383,7 @@ if (!empty($conf->global->TICKET_ENABLE_PUBLIC_INTERFACE)) {
|
|||||||
print $form->textwithpicto('', $langs->trans("TicketPublicInterfaceTextHomeHelpAdmin"), 1, 'help');
|
print $form->textwithpicto('', $langs->trans("TicketPublicInterfaceTextHomeHelpAdmin"), 1, 'help');
|
||||||
print '</td></tr>';
|
print '</td></tr>';
|
||||||
|
|
||||||
// Texte d'aide à la saisie du message
|
// Text to help to enter a ticket
|
||||||
$public_text_help_message = $conf->global->TICKET_PUBLIC_TEXT_HELP_MESSAGE ? $conf->global->TICKET_PUBLIC_TEXT_HELP_MESSAGE : $langs->trans('TicketPublicPleaseBeAccuratelyDescribe');
|
$public_text_help_message = $conf->global->TICKET_PUBLIC_TEXT_HELP_MESSAGE ? $conf->global->TICKET_PUBLIC_TEXT_HELP_MESSAGE : $langs->trans('TicketPublicPleaseBeAccuratelyDescribe');
|
||||||
print '<tr><td>'.$langs->trans("TicketPublicInterfaceTextHelpMessageLabelAdmin").'</label>';
|
print '<tr><td>'.$langs->trans("TicketPublicInterfaceTextHelpMessageLabelAdmin").'</label>';
|
||||||
print '</td><td>';
|
print '</td><td>';
|
||||||
|
|||||||
@ -315,7 +315,7 @@ class FormTicket
|
|||||||
|
|
||||||
// Type
|
// Type
|
||||||
print '<tr><td class="titlefield"><span class="fieldrequired"><label for="selecttype_code">'.$langs->trans("TicketTypeRequest").'</span></label></td><td>';
|
print '<tr><td class="titlefield"><span class="fieldrequired"><label for="selecttype_code">'.$langs->trans("TicketTypeRequest").'</span></label></td><td>';
|
||||||
$this->selectTypesTickets((GETPOST('type_code', 'alpha') ? GETPOST('type_code', 'alpha') : $this->type_code), 'type_code', '', 2, 0, 0, 0, 'minwidth200');
|
$this->selectTypesTickets((GETPOST('type_code', 'alpha') ? GETPOST('type_code', 'alpha') : $this->type_code), 'type_code', '', 2, 1, 0, 0, 'minwidth200');
|
||||||
print '</td></tr>';
|
print '</td></tr>';
|
||||||
|
|
||||||
// Group
|
// Group
|
||||||
@ -328,7 +328,7 @@ class FormTicket
|
|||||||
print '</td></tr>';
|
print '</td></tr>';
|
||||||
|
|
||||||
// Severity
|
// Severity
|
||||||
print '<tr><td><span class="fieldrequired"><label for="selectseverity_code">'.$langs->trans("TicketSeverity").'</span></label></td><td>';
|
print '<tr><td><span class=""><label for="selectseverity_code">'.$langs->trans("TicketSeverity").'</span></label></td><td>';
|
||||||
$this->selectSeveritiesTickets((GETPOST('severity_code') ? GETPOST('severity_code') : $this->severity_code), 'severity_code', '', 2, 0);
|
$this->selectSeveritiesTickets((GETPOST('severity_code') ? GETPOST('severity_code') : $this->severity_code), 'severity_code', '', 2, 0);
|
||||||
print '</td></tr>';
|
print '</td></tr>';
|
||||||
|
|
||||||
@ -643,7 +643,7 @@ class FormTicket
|
|||||||
print dol_get_fiche_end();
|
print dol_get_fiche_end();
|
||||||
}
|
}
|
||||||
|
|
||||||
print '<br>';
|
print '<br><br>';
|
||||||
|
|
||||||
print $form->buttonsSaveCancel(((isset($this->withreadid) && $this->withreadid > 0) ? "SendResponse" : "CreateTicket"), ($this->withcancel ? "Cancel" : ""));
|
print $form->buttonsSaveCancel(((isset($this->withreadid) && $this->withreadid > 0) ? "SendResponse" : "CreateTicket"), ($this->withcancel ? "Cancel" : ""));
|
||||||
|
|
||||||
|
|||||||
@ -451,7 +451,7 @@ if ($step == 1 || !$datatoexport) {
|
|||||||
print $label;
|
print $label;
|
||||||
print '</td><td class="right">';
|
print '</td><td class="right">';
|
||||||
if ($objexport->array_export_perms[$key]) {
|
if ($objexport->array_export_perms[$key]) {
|
||||||
print '<a href="'.DOL_URL_ROOT.'/exports/export.php?step=2&module_position='.$objexport->array_export_module[$key]->module_position.'&datatoexport='.$objexport->array_export_code[$key].'">'.img_picto($langs->trans("NewExport"), 'next', 'class="fa-15x"').'</a>';
|
print '<a href="'.DOL_URL_ROOT.'/exports/export.php?step=2&module_position='.$objexport->array_export_module[$key]->module_position.'&datatoexport='.$objexport->array_export_code[$key].'">'.img_picto($langs->trans("NewExport"), 'next', 'class="fa-15"').'</a>';
|
||||||
} else {
|
} else {
|
||||||
print '<span class="opacitymedium">'.$langs->trans("NotEnoughPermissions").'</span>';
|
print '<span class="opacitymedium">'.$langs->trans("NotEnoughPermissions").'</span>';
|
||||||
}
|
}
|
||||||
|
|||||||
@ -394,7 +394,7 @@ if ($step == 1 || !$datatoimport) {
|
|||||||
print $objimport->array_import_label[$key];
|
print $objimport->array_import_label[$key];
|
||||||
print '</td><td style="text-align: right">';
|
print '</td><td style="text-align: right">';
|
||||||
if ($objimport->array_import_perms[$key]) {
|
if ($objimport->array_import_perms[$key]) {
|
||||||
print '<a href="'.DOL_URL_ROOT.'/imports/import.php?step=2&datatoimport='.$objimport->array_import_code[$key].$param.'">'.img_picto($langs->trans("NewImport"), 'next', 'class="fa-15x"').'</a>';
|
print '<a href="'.DOL_URL_ROOT.'/imports/import.php?step=2&datatoimport='.$objimport->array_import_code[$key].$param.'">'.img_picto($langs->trans("NewImport"), 'next', 'class="fa-15"').'</a>';
|
||||||
} else {
|
} else {
|
||||||
print $langs->trans("NotEnoughPermissions");
|
print $langs->trans("NotEnoughPermissions");
|
||||||
}
|
}
|
||||||
@ -499,7 +499,7 @@ if ($step == 2 && $datatoimport) {
|
|||||||
print '</td>';
|
print '</td>';
|
||||||
// Action button
|
// Action button
|
||||||
print '<td style="text-align:right">';
|
print '<td style="text-align:right">';
|
||||||
print '<a href="'.DOL_URL_ROOT.'/imports/import.php?step=3&format='.$key.$param.'">'.img_picto($langs->trans("SelectFormat"), 'next', 'class="fa-15x"').'</a>';
|
print '<a href="'.DOL_URL_ROOT.'/imports/import.php?step=3&format='.$key.$param.'">'.img_picto($langs->trans("SelectFormat"), 'next', 'class="fa-15"').'</a>';
|
||||||
print '</td>';
|
print '</td>';
|
||||||
print '</tr>';
|
print '</tr>';
|
||||||
}
|
}
|
||||||
@ -727,7 +727,7 @@ if ($step == 3 && $datatoimport) {
|
|||||||
print '">'.img_delete().'</a></td>';
|
print '">'.img_delete().'</a></td>';
|
||||||
// Action button
|
// Action button
|
||||||
print '<td style="text-align:right">';
|
print '<td style="text-align:right">';
|
||||||
print '<a href="'.$_SERVER['PHP_SELF'].'?step=4'.$param.'&filetoimport='.urlencode($relativepath).'">'.img_picto($langs->trans("NewImport"), 'next', 'class="fa-15x"').'</a>';
|
print '<a href="'.$_SERVER['PHP_SELF'].'?step=4'.$param.'&filetoimport='.urlencode($relativepath).'">'.img_picto($langs->trans("NewImport"), 'next', 'class="fa-15"').'</a>';
|
||||||
print '</td>';
|
print '</td>';
|
||||||
print '</tr>';
|
print '</tr>';
|
||||||
}
|
}
|
||||||
|
|||||||
@ -296,7 +296,7 @@ TicketNewEmailBodyInfosTrackUrlCustomer=You can view the progress of the ticket
|
|||||||
TicketCloseEmailBodyInfosTrackUrlCustomer=You can consult the history of this ticket by clicking the following link
|
TicketCloseEmailBodyInfosTrackUrlCustomer=You can consult the history of this ticket by clicking the following link
|
||||||
TicketEmailPleaseDoNotReplyToThisEmail=Please do not reply directly to this email! Use the link to reply into the interface.
|
TicketEmailPleaseDoNotReplyToThisEmail=Please do not reply directly to this email! Use the link to reply into the interface.
|
||||||
TicketPublicInfoCreateTicket=This form allows you to record a support ticket in our management system.
|
TicketPublicInfoCreateTicket=This form allows you to record a support ticket in our management system.
|
||||||
TicketPublicPleaseBeAccuratelyDescribe=Please accurately describe the problem. Provide the most information possible to allow us to correctly identify your request.
|
TicketPublicPleaseBeAccuratelyDescribe=Please accurately describe your question. Provide the most information possible to allow us to correctly identify your request.
|
||||||
TicketPublicMsgViewLogIn=Please enter ticket tracking ID
|
TicketPublicMsgViewLogIn=Please enter ticket tracking ID
|
||||||
TicketTrackId=Public Tracking ID
|
TicketTrackId=Public Tracking ID
|
||||||
OneOfTicketTrackId=One of your tracking ID
|
OneOfTicketTrackId=One of your tracking ID
|
||||||
|
|||||||
@ -1153,6 +1153,11 @@ if (!defined('NOLOGIN')) {
|
|||||||
$conf->theme = $user->conf->MAIN_THEME;
|
$conf->theme = $user->conf->MAIN_THEME;
|
||||||
$conf->css = "/theme/".$conf->theme."/style.css.php";
|
$conf->css = "/theme/".$conf->theme."/style.css.php";
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
// We may have NOLOGIN set, but NOREQUIREUSER not
|
||||||
|
if (!empty($user) && method_exists($user, 'loadDefaultValues')) {
|
||||||
|
$user->loadDefaultValues(); // Load default values for everybody (works even if $user->id = 0
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -22,9 +22,10 @@
|
|||||||
* \brief Display public form to add new ticket
|
* \brief Display public form to add new ticket
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
/* We need object $user->default_values
|
||||||
if (!defined('NOREQUIREUSER')) {
|
if (!defined('NOREQUIREUSER')) {
|
||||||
define('NOREQUIREUSER', '1');
|
define('NOREQUIREUSER', '1');
|
||||||
}
|
}*/
|
||||||
if (!defined('NOTOKENRENEWAL')) {
|
if (!defined('NOTOKENRENEWAL')) {
|
||||||
define('NOTOKENRENEWAL', '1');
|
define('NOTOKENRENEWAL', '1');
|
||||||
}
|
}
|
||||||
@ -37,9 +38,6 @@ if (!defined('NOREQUIREHTML')) {
|
|||||||
if (!defined('NOLOGIN')) {
|
if (!defined('NOLOGIN')) {
|
||||||
define("NOLOGIN", 1); // This means this output page does not require to be logged.
|
define("NOLOGIN", 1); // This means this output page does not require to be logged.
|
||||||
}
|
}
|
||||||
if (!defined('NOCSRFCHECK')) {
|
|
||||||
define("NOCSRFCHECK", 1); // We accept to go on this page from external web site.
|
|
||||||
}
|
|
||||||
if (!defined('NOIPCHECK')) {
|
if (!defined('NOIPCHECK')) {
|
||||||
define('NOIPCHECK', '1'); // Do not check IP defined into conf $dolibarr_main_restrict_ip
|
define('NOIPCHECK', '1'); // Do not check IP defined into conf $dolibarr_main_restrict_ip
|
||||||
}
|
}
|
||||||
@ -73,6 +71,9 @@ $id = GETPOST('id', 'int');
|
|||||||
$msg_id = GETPOST('msg_id', 'int');
|
$msg_id = GETPOST('msg_id', 'int');
|
||||||
|
|
||||||
$action = GETPOST('action', 'aZ09');
|
$action = GETPOST('action', 'aZ09');
|
||||||
|
$cancel = GETPOST('cancel', 'aZ09');
|
||||||
|
|
||||||
|
$backtopage = '';
|
||||||
|
|
||||||
// Initialize technical object to manage hooks of page. Note that conf->hooks_modules contains array of hook context
|
// Initialize technical object to manage hooks of page. Note that conf->hooks_modules contains array of hook context
|
||||||
$hookmanager->initHooks(array('publicnewticketcard', 'globalcard'));
|
$hookmanager->initHooks(array('publicnewticketcard', 'globalcard'));
|
||||||
@ -105,298 +106,265 @@ if ($reshook < 0) {
|
|||||||
setEventMessages($hookmanager->error, $hookmanager->errors, 'errors');
|
setEventMessages($hookmanager->error, $hookmanager->errors, 'errors');
|
||||||
}
|
}
|
||||||
// Add file in email form
|
// Add file in email form
|
||||||
if (empty($reshook) && GETPOST('addfile', 'alpha') && !GETPOST('save', 'alpha')) {
|
if (empty($reshook)) {
|
||||||
////$res = $object->fetch('','',GETPOST('track_id'));
|
if ($cancel) {
|
||||||
////if($res > 0)
|
$backtopage = DOL_URL_ROOT.'/public/ticket/index.php';
|
||||||
////{
|
|
||||||
include_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php';
|
|
||||||
|
|
||||||
// Set tmp directory TODO Use a dedicated directory for temp mails files
|
header("Location: ".$backtopage);
|
||||||
$vardir = $conf->ticket->dir_output;
|
exit;
|
||||||
$upload_dir_tmp = $vardir.'/temp/'.session_id();
|
|
||||||
if (!dol_is_dir($upload_dir_tmp)) {
|
|
||||||
dol_mkdir($upload_dir_tmp);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
dol_add_file_process($upload_dir_tmp, 0, 0, 'addedfile', '', null, '', 0);
|
if (GETPOST('addfile', 'alpha') && !GETPOST('save', 'alpha')) {
|
||||||
$action = 'create_ticket';
|
////$res = $object->fetch('','',GETPOST('track_id'));
|
||||||
////}
|
////if($res > 0)
|
||||||
}
|
////{
|
||||||
|
include_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php';
|
||||||
|
|
||||||
// Remove file
|
// Set tmp directory TODO Use a dedicated directory for temp mails files
|
||||||
if (empty($reshook) && GETPOST('removedfile', 'alpha') && !GETPOST('save', 'alpha')) {
|
$vardir = $conf->ticket->dir_output;
|
||||||
include_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php';
|
$upload_dir_tmp = $vardir.'/temp/'.session_id();
|
||||||
|
if (!dol_is_dir($upload_dir_tmp)) {
|
||||||
|
dol_mkdir($upload_dir_tmp);
|
||||||
|
}
|
||||||
|
|
||||||
// Set tmp directory
|
dol_add_file_process($upload_dir_tmp, 0, 0, 'addedfile', '', null, '', 0);
|
||||||
$vardir = $conf->ticket->dir_output.'/';
|
$action = 'create_ticket';
|
||||||
$upload_dir_tmp = $vardir.'/temp/'.session_id();
|
////}
|
||||||
|
}
|
||||||
|
|
||||||
// TODO Delete only files that was uploaded from email form
|
// Remove file
|
||||||
dol_remove_file_process(GETPOST('removedfile'), 0, 0);
|
if (GETPOST('removedfile', 'alpha') && !GETPOST('save', 'alpha')) {
|
||||||
$action = 'create_ticket';
|
include_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php';
|
||||||
}
|
|
||||||
|
|
||||||
if (empty($reshook) && $action == 'create_ticket' && GETPOST('save', 'alpha')) {
|
// Set tmp directory
|
||||||
$error = 0;
|
$vardir = $conf->ticket->dir_output.'/';
|
||||||
$origin_email = GETPOST('email', 'alpha');
|
$upload_dir_tmp = $vardir.'/temp/'.session_id();
|
||||||
if (empty($origin_email)) {
|
|
||||||
$error++;
|
|
||||||
array_push($object->errors, $langs->trans("ErrorFieldRequired", $langs->transnoentities("Email")));
|
|
||||||
$action = '';
|
|
||||||
} else {
|
|
||||||
// Search company saved with email
|
|
||||||
$searched_companies = $object->searchSocidByEmail($origin_email, '0');
|
|
||||||
|
|
||||||
// Chercher un contact existant avec cette adresse email
|
// TODO Delete only files that was uploaded from email form
|
||||||
// Le premier contact trouvé est utilisé pour déterminer le contact suivi
|
dol_remove_file_process(GETPOST('removedfile'), 0, 0);
|
||||||
$contacts = $object->searchContactByEmail($origin_email);
|
$action = 'create_ticket';
|
||||||
|
}
|
||||||
|
|
||||||
// Option to require email exists to create ticket
|
if ($action == 'create_ticket' && GETPOST('save', 'alpha')) {
|
||||||
if (!empty($conf->global->TICKET_EMAIL_MUST_EXISTS) && !$contacts[0]->socid) {
|
$error = 0;
|
||||||
|
$origin_email = GETPOST('email', 'alpha');
|
||||||
|
if (empty($origin_email)) {
|
||||||
$error++;
|
$error++;
|
||||||
array_push($object->errors, $langs->trans("ErrorEmailMustExistToCreateTicket"));
|
array_push($object->errors, $langs->trans("ErrorFieldRequired", $langs->transnoentities("Email")));
|
||||||
$action = '';
|
$action = '';
|
||||||
}
|
} else {
|
||||||
}
|
// Search company saved with email
|
||||||
|
$searched_companies = $object->searchSocidByEmail($origin_email, '0');
|
||||||
|
|
||||||
$contact_lastname = '';
|
// Chercher un contact existant avec cette adresse email
|
||||||
$contact_firstname = '';
|
// Le premier contact trouvé est utilisé pour déterminer le contact suivi
|
||||||
$company_name = '';
|
$contacts = $object->searchContactByEmail($origin_email);
|
||||||
$contact_phone = '';
|
|
||||||
if ($with_contact) {
|
|
||||||
// set linked contact to add in form
|
|
||||||
if (is_array($contacts) && count($contacts) == 1) {
|
|
||||||
$with_contact = current($contacts);
|
|
||||||
}
|
|
||||||
|
|
||||||
// check mandatory fields on contact
|
// Option to require email exists to create ticket
|
||||||
$contact_lastname = trim(GETPOST('contact_lastname', 'alphanohtml'));
|
if (!empty($conf->global->TICKET_EMAIL_MUST_EXISTS) && !$contacts[0]->socid) {
|
||||||
$contact_firstname = trim(GETPOST('contact_firstname', 'alphanohtml'));
|
|
||||||
$company_name = trim(GETPOST('company_name', 'alphanohtml'));
|
|
||||||
$contact_phone = trim(GETPOST('contact_phone', 'alphanohtml'));
|
|
||||||
if (!($with_contact->id > 0)) {
|
|
||||||
// check lastname
|
|
||||||
if (empty($contact_lastname)) {
|
|
||||||
$error++;
|
$error++;
|
||||||
array_push($object->errors, $langs->trans('ErrorFieldRequired', $langs->transnoentities('Lastname')));
|
array_push($object->errors, $langs->trans("ErrorEmailMustExistToCreateTicket"));
|
||||||
$action = '';
|
|
||||||
}
|
|
||||||
// check firstname
|
|
||||||
if (empty($contact_firstname)) {
|
|
||||||
$error++;
|
|
||||||
array_push($object->errors, $langs->trans('ErrorFieldRequired', $langs->transnoentities('Firstname')));
|
|
||||||
$action = '';
|
$action = '';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
if (!GETPOST("subject", "restricthtml")) {
|
$contact_lastname = '';
|
||||||
$error++;
|
$contact_firstname = '';
|
||||||
array_push($object->errors, $langs->trans("ErrorFieldRequired", $langs->transnoentities("Subject")));
|
$company_name = '';
|
||||||
$action = '';
|
$contact_phone = '';
|
||||||
}
|
if ($with_contact) {
|
||||||
if (!GETPOST("message", "restricthtml")) {
|
// set linked contact to add in form
|
||||||
$error++;
|
if (is_array($contacts) && count($contacts) == 1) {
|
||||||
array_push($object->errors, $langs->trans("ErrorFieldRequired", $langs->transnoentities("Message")));
|
$with_contact = current($contacts);
|
||||||
$action = '';
|
}
|
||||||
}
|
|
||||||
|
|
||||||
// Check email address
|
// check mandatory fields on contact
|
||||||
if (!empty($origin_email) && !isValidEmail($origin_email)) {
|
$contact_lastname = trim(GETPOST('contact_lastname', 'alphanohtml'));
|
||||||
$error++;
|
$contact_firstname = trim(GETPOST('contact_firstname', 'alphanohtml'));
|
||||||
array_push($object->errors, $langs->trans("ErrorBadEmailAddress", $langs->transnoentities("email")));
|
$company_name = trim(GETPOST('company_name', 'alphanohtml'));
|
||||||
$action = '';
|
$contact_phone = trim(GETPOST('contact_phone', 'alphanohtml'));
|
||||||
}
|
if (!($with_contact->id > 0)) {
|
||||||
|
// check lastname
|
||||||
|
if (empty($contact_lastname)) {
|
||||||
|
$error++;
|
||||||
|
array_push($object->errors, $langs->trans('ErrorFieldRequired', $langs->transnoentities('Lastname')));
|
||||||
|
$action = '';
|
||||||
|
}
|
||||||
|
// check firstname
|
||||||
|
if (empty($contact_firstname)) {
|
||||||
|
$error++;
|
||||||
|
array_push($object->errors, $langs->trans('ErrorFieldRequired', $langs->transnoentities('Firstname')));
|
||||||
|
$action = '';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Check Captcha code if is enabled
|
if (!GETPOST("subject", "restricthtml")) {
|
||||||
if (!empty($conf->global->MAIN_SECURITY_ENABLECAPTCHA) || !empty($conf->global->MAIN_SECURITY_ENABLECAPTCHA_TICKET)) {
|
|
||||||
$sessionkey = 'dol_antispam_value';
|
|
||||||
$ok = (array_key_exists($sessionkey, $_SESSION) === true && (strtolower($_SESSION[$sessionkey]) === strtolower(GETPOST('code', 'restricthtml'))));
|
|
||||||
if (!$ok) {
|
|
||||||
$error++;
|
$error++;
|
||||||
array_push($object->errors, $langs->trans("ErrorBadValueForCode"));
|
array_push($object->errors, $langs->trans("ErrorFieldRequired", $langs->transnoentities("Subject")));
|
||||||
$action = '';
|
$action = '';
|
||||||
}
|
}
|
||||||
}
|
if (!GETPOST("message", "restricthtml")) {
|
||||||
|
$error++;
|
||||||
if (!$error) {
|
array_push($object->errors, $langs->trans("ErrorFieldRequired", $langs->transnoentities("Message")));
|
||||||
$object->db->begin();
|
$action = '';
|
||||||
|
|
||||||
$object->track_id = generate_random_id(16);
|
|
||||||
|
|
||||||
$object->subject = GETPOST("subject", "restricthtml");
|
|
||||||
$object->message = GETPOST("message", "restricthtml");
|
|
||||||
$object->origin_email = $origin_email;
|
|
||||||
|
|
||||||
$object->type_code = GETPOST("type_code", 'aZ09');
|
|
||||||
$object->category_code = GETPOST("category_code", 'aZ09');
|
|
||||||
$object->severity_code = GETPOST("severity_code", 'aZ09');
|
|
||||||
|
|
||||||
if (!is_object($user)) {
|
|
||||||
$user = new User($db);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// create third-party with contact
|
// Check email address
|
||||||
$usertoassign = 0;
|
if (!empty($origin_email) && !isValidEmail($origin_email)) {
|
||||||
if ($with_contact && !($with_contact->id > 0)) {
|
$error++;
|
||||||
$company = new Societe($db);
|
array_push($object->errors, $langs->trans("ErrorBadEmailAddress", $langs->transnoentities("email")));
|
||||||
if (!empty($company_name)) {
|
$action = '';
|
||||||
$company->name = $company_name;
|
}
|
||||||
} else {
|
|
||||||
$company->particulier = 1;
|
// Check Captcha code if is enabled
|
||||||
$company->name = dolGetFirstLastname($contact_firstname, $contact_lastname);
|
if (!empty($conf->global->MAIN_SECURITY_ENABLECAPTCHA) || !empty($conf->global->MAIN_SECURITY_ENABLECAPTCHA_TICKET)) {
|
||||||
}
|
$sessionkey = 'dol_antispam_value';
|
||||||
$result = $company->create($user);
|
$ok = (array_key_exists($sessionkey, $_SESSION) === true && (strtolower($_SESSION[$sessionkey]) === strtolower(GETPOST('code', 'restricthtml'))));
|
||||||
if ($result < 0) {
|
if (!$ok) {
|
||||||
$error++;
|
$error++;
|
||||||
$errors = ($company->error ? array($company->error) : $company->errors);
|
array_push($object->errors, $langs->trans("ErrorBadValueForCode"));
|
||||||
array_push($object->errors, $errors);
|
$action = '';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!$error) {
|
||||||
|
$object->db->begin();
|
||||||
|
|
||||||
|
$object->track_id = generate_random_id(16);
|
||||||
|
|
||||||
|
$object->subject = GETPOST("subject", "restricthtml");
|
||||||
|
$object->message = GETPOST("message", "restricthtml");
|
||||||
|
$object->origin_email = $origin_email;
|
||||||
|
|
||||||
|
$object->type_code = GETPOST("type_code", 'aZ09');
|
||||||
|
$object->category_code = GETPOST("category_code", 'aZ09');
|
||||||
|
$object->severity_code = GETPOST("severity_code", 'aZ09');
|
||||||
|
|
||||||
|
if (!is_object($user)) {
|
||||||
|
$user = new User($db);
|
||||||
|
}
|
||||||
|
|
||||||
|
// create third-party with contact
|
||||||
|
$usertoassign = 0;
|
||||||
|
if ($with_contact && !($with_contact->id > 0)) {
|
||||||
|
$company = new Societe($db);
|
||||||
|
if (!empty($company_name)) {
|
||||||
|
$company->name = $company_name;
|
||||||
|
} else {
|
||||||
|
$company->particulier = 1;
|
||||||
|
$company->name = dolGetFirstLastname($contact_firstname, $contact_lastname);
|
||||||
|
}
|
||||||
|
$result = $company->create($user);
|
||||||
|
if ($result < 0) {
|
||||||
|
$error++;
|
||||||
|
$errors = ($company->error ? array($company->error) : $company->errors);
|
||||||
|
array_push($object->errors, $errors);
|
||||||
|
$action = 'create_ticket';
|
||||||
|
}
|
||||||
|
|
||||||
|
// create contact and link to this new company
|
||||||
|
if (!$error) {
|
||||||
|
$with_contact->email = $origin_email;
|
||||||
|
$with_contact->lastname = $contact_lastname;
|
||||||
|
$with_contact->firstname = $contact_firstname;
|
||||||
|
$with_contact->socid = $company->id;
|
||||||
|
$with_contact->phone_pro = $contact_phone;
|
||||||
|
$result = $with_contact->create($user);
|
||||||
|
if ($result < 0) {
|
||||||
|
$error++;
|
||||||
|
$errors = ($with_contact->error ? array($with_contact->error) : $with_contact->errors);
|
||||||
|
array_push($object->errors, $errors);
|
||||||
|
$action = 'create_ticket';
|
||||||
|
} else {
|
||||||
|
$contacts = array($with_contact);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (is_array($searched_companies)) {
|
||||||
|
$object->fk_soc = $searched_companies[0]->id;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (is_array($contacts) and count($contacts) > 0) {
|
||||||
|
$object->fk_soc = $contacts[0]->socid;
|
||||||
|
$usertoassign = $contacts[0]->id;
|
||||||
|
}
|
||||||
|
|
||||||
|
$ret = $extrafields->setOptionalsFromPost(null, $object);
|
||||||
|
|
||||||
|
// Generate new ref
|
||||||
|
$object->ref = $object->getDefaultRef();
|
||||||
|
|
||||||
|
$object->context['disableticketemail'] = 1; // Disable emails sent by ticket trigger when creation is done from this page, emails are already sent later
|
||||||
|
|
||||||
|
$id = $object->create($user);
|
||||||
|
if ($id <= 0) {
|
||||||
|
$error++;
|
||||||
|
$errors = ($object->error ? array($object->error) : $object->errors);
|
||||||
|
array_push($object->errors, $object->error ? array($object->error) : $object->errors);
|
||||||
$action = 'create_ticket';
|
$action = 'create_ticket';
|
||||||
}
|
}
|
||||||
|
|
||||||
// create contact and link to this new company
|
if (!$error && $id > 0) {
|
||||||
|
if ($usertoassign > 0) {
|
||||||
|
$object->add_contact($usertoassign, "SUPPORTCLI", 'external', 0);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (!$error) {
|
if (!$error) {
|
||||||
$with_contact->email = $origin_email;
|
$object->db->commit();
|
||||||
$with_contact->lastname = $contact_lastname;
|
$action = "infos_success";
|
||||||
$with_contact->firstname = $contact_firstname;
|
} else {
|
||||||
$with_contact->socid = $company->id;
|
$object->db->rollback();
|
||||||
$with_contact->phone_pro = $contact_phone;
|
setEventMessages($object->error, $object->errors, 'errors');
|
||||||
$result = $with_contact->create($user);
|
$action = 'create_ticket';
|
||||||
if ($result < 0) {
|
|
||||||
$error++;
|
|
||||||
$errors = ($with_contact->error ? array($with_contact->error) : $with_contact->errors);
|
|
||||||
array_push($object->errors, $errors);
|
|
||||||
$action = 'create_ticket';
|
|
||||||
} else {
|
|
||||||
$contacts = array($with_contact);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
if (is_array($searched_companies)) {
|
if (!$error) {
|
||||||
$object->fk_soc = $searched_companies[0]->id;
|
$res = $object->fetch($id);
|
||||||
}
|
if ($res) {
|
||||||
|
// Create form object
|
||||||
|
include_once DOL_DOCUMENT_ROOT.'/core/class/html.formmail.class.php';
|
||||||
|
include_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php';
|
||||||
|
$formmail = new FormMail($db);
|
||||||
|
|
||||||
if (is_array($contacts) and count($contacts) > 0) {
|
// Init to avoid errors
|
||||||
$object->fk_soc = $contacts[0]->socid;
|
$filepath = array();
|
||||||
$usertoassign = $contacts[0]->id;
|
$filename = array();
|
||||||
}
|
$mimetype = array();
|
||||||
|
|
||||||
$ret = $extrafields->setOptionalsFromPost(null, $object);
|
$attachedfiles = $formmail->get_attached_files();
|
||||||
|
$filepath = $attachedfiles['paths'];
|
||||||
|
$filename = $attachedfiles['names'];
|
||||||
|
$mimetype = $attachedfiles['mimes'];
|
||||||
|
|
||||||
// Generate new ref
|
// Send email to customer
|
||||||
$object->ref = $object->getDefaultRef();
|
|
||||||
|
|
||||||
$object->context['disableticketemail'] = 1; // Disable emails sent by ticket trigger when creation is done from this page, emails are already sent later
|
$subject = '['.$conf->global->MAIN_INFO_SOCIETE_NOM.'] '.$langs->transnoentities('TicketNewEmailSubject', $object->ref, $object->track_id);
|
||||||
|
$message = ($conf->global->TICKET_MESSAGE_MAIL_NEW ? $conf->global->TICKET_MESSAGE_MAIL_NEW : $langs->transnoentities('TicketNewEmailBody')).'<br><br>';
|
||||||
|
$message .= $langs->transnoentities('TicketNewEmailBodyInfosTicket').'<br>';
|
||||||
|
|
||||||
$id = $object->create($user);
|
$url_public_ticket = ($conf->global->TICKET_URL_PUBLIC_INTERFACE ? $conf->global->TICKET_URL_PUBLIC_INTERFACE.'/view.php' : dol_buildpath('/public/ticket/view.php', 2)).'?track_id='.$object->track_id;
|
||||||
if ($id <= 0) {
|
$infos_new_ticket = $langs->transnoentities('TicketNewEmailBodyInfosTrackId', '<a href="'.$url_public_ticket.'" rel="nofollow noopener">'.$object->track_id.'</a>').'<br>';
|
||||||
$error++;
|
$infos_new_ticket .= $langs->transnoentities('TicketNewEmailBodyInfosTrackUrl').'<br><br>';
|
||||||
$errors = ($object->error ? array($object->error) : $object->errors);
|
|
||||||
array_push($object->errors, $object->error ? array($object->error) : $object->errors);
|
|
||||||
$action = 'create_ticket';
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!$error && $id > 0) {
|
$message .= $infos_new_ticket;
|
||||||
if ($usertoassign > 0) {
|
$message .= getDolGlobalString('TICKET_MESSAGE_MAIL_SIGNATURE', $langs->transnoentities('TicketMessageMailSignatureText', $mysoc->name));
|
||||||
$object->add_contact($usertoassign, "SUPPORTCLI", 'external', 0);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!$error) {
|
$sendto = GETPOST('email', 'alpha');
|
||||||
$object->db->commit();
|
|
||||||
$action = "infos_success";
|
|
||||||
} else {
|
|
||||||
$object->db->rollback();
|
|
||||||
setEventMessages($object->error, $object->errors, 'errors');
|
|
||||||
$action = 'create_ticket';
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!$error) {
|
$from = $conf->global->MAIN_INFO_SOCIETE_NOM.' <'.getDolGlobalString('TICKET_NOTIFICATION_EMAIL_FROM').'>';
|
||||||
$res = $object->fetch($id);
|
|
||||||
if ($res) {
|
|
||||||
// Create form object
|
|
||||||
include_once DOL_DOCUMENT_ROOT.'/core/class/html.formmail.class.php';
|
|
||||||
include_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php';
|
|
||||||
$formmail = new FormMail($db);
|
|
||||||
|
|
||||||
// Init to avoid errors
|
|
||||||
$filepath = array();
|
|
||||||
$filename = array();
|
|
||||||
$mimetype = array();
|
|
||||||
|
|
||||||
$attachedfiles = $formmail->get_attached_files();
|
|
||||||
$filepath = $attachedfiles['paths'];
|
|
||||||
$filename = $attachedfiles['names'];
|
|
||||||
$mimetype = $attachedfiles['mimes'];
|
|
||||||
|
|
||||||
// Send email to customer
|
|
||||||
|
|
||||||
$subject = '['.$conf->global->MAIN_INFO_SOCIETE_NOM.'] '.$langs->transnoentities('TicketNewEmailSubject', $object->ref, $object->track_id);
|
|
||||||
$message = ($conf->global->TICKET_MESSAGE_MAIL_NEW ? $conf->global->TICKET_MESSAGE_MAIL_NEW : $langs->transnoentities('TicketNewEmailBody')).'<br><br>';
|
|
||||||
$message .= $langs->transnoentities('TicketNewEmailBodyInfosTicket').'<br>';
|
|
||||||
|
|
||||||
$url_public_ticket = ($conf->global->TICKET_URL_PUBLIC_INTERFACE ? $conf->global->TICKET_URL_PUBLIC_INTERFACE.'/view.php' : dol_buildpath('/public/ticket/view.php', 2)).'?track_id='.$object->track_id;
|
|
||||||
$infos_new_ticket = $langs->transnoentities('TicketNewEmailBodyInfosTrackId', '<a href="'.$url_public_ticket.'" rel="nofollow noopener">'.$object->track_id.'</a>').'<br>';
|
|
||||||
$infos_new_ticket .= $langs->transnoentities('TicketNewEmailBodyInfosTrackUrl').'<br><br>';
|
|
||||||
|
|
||||||
$message .= $infos_new_ticket;
|
|
||||||
$message .= getDolGlobalString('TICKET_MESSAGE_MAIL_SIGNATURE', $langs->transnoentities('TicketMessageMailSignatureText', $mysoc->name));
|
|
||||||
|
|
||||||
$sendto = GETPOST('email', 'alpha');
|
|
||||||
|
|
||||||
$from = $conf->global->MAIN_INFO_SOCIETE_NOM.' <'.getDolGlobalString('TICKET_NOTIFICATION_EMAIL_FROM').'>';
|
|
||||||
$replyto = $from;
|
|
||||||
$sendtocc = '';
|
|
||||||
$deliveryreceipt = 0;
|
|
||||||
|
|
||||||
if (!empty($conf->global->TICKET_DISABLE_MAIL_AUTOCOPY_TO)) {
|
|
||||||
$old_MAIN_MAIL_AUTOCOPY_TO = $conf->global->MAIN_MAIL_AUTOCOPY_TO;
|
|
||||||
$conf->global->MAIN_MAIL_AUTOCOPY_TO = '';
|
|
||||||
}
|
|
||||||
include_once DOL_DOCUMENT_ROOT.'/core/class/CMailFile.class.php';
|
|
||||||
$mailfile = new CMailFile($subject, $sendto, $from, $message, $filepath, $mimetype, $filename, $sendtocc, '', $deliveryreceipt, -1, '', '', 'tic'.$object->id, '', 'ticket');
|
|
||||||
if ($mailfile->error || $mailfile->errors) {
|
|
||||||
setEventMessages($mailfile->error, $mailfile->errors, 'errors');
|
|
||||||
} else {
|
|
||||||
$result = $mailfile->sendfile();
|
|
||||||
}
|
|
||||||
if (!empty($conf->global->TICKET_DISABLE_MAIL_AUTOCOPY_TO)) {
|
|
||||||
$conf->global->MAIN_MAIL_AUTOCOPY_TO = $old_MAIN_MAIL_AUTOCOPY_TO;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Send email to TICKET_NOTIFICATION_EMAIL_TO
|
|
||||||
$sendto = $conf->global->TICKET_NOTIFICATION_EMAIL_TO;
|
|
||||||
if ($sendto) {
|
|
||||||
$subject = '['.$conf->global->MAIN_INFO_SOCIETE_NOM.'] '.$langs->transnoentities('TicketNewEmailSubjectAdmin', $object->ref, $object->track_id);
|
|
||||||
$message_admin = $langs->transnoentities('TicketNewEmailBodyAdmin', $object->track_id).'<br><br>';
|
|
||||||
$message_admin .= '<ul><li>'.$langs->trans('Title').' : '.$object->subject.'</li>';
|
|
||||||
$message_admin .= '<li>'.$langs->trans('Type').' : '.$object->type_label.'</li>';
|
|
||||||
$message_admin .= '<li>'.$langs->trans('Category').' : '.$object->category_label.'</li>';
|
|
||||||
$message_admin .= '<li>'.$langs->trans('Severity').' : '.$object->severity_label.'</li>';
|
|
||||||
$message_admin .= '<li>'.$langs->trans('From').' : '.$object->origin_email.'</li>';
|
|
||||||
// Extrafields
|
|
||||||
$extrafields->fetch_name_optionals_label($object->table_element);
|
|
||||||
if (is_array($object->array_options) && count($object->array_options) > 0) {
|
|
||||||
foreach ($object->array_options as $key => $value) {
|
|
||||||
$key = substr($key, 8); // remove "options_"
|
|
||||||
$message_admin .= '<li>'.$langs->trans($extrafields->attributes[$object->table_element]['label'][$key]).' : '.$extrafields->showOutputField($key, $value, '', $object->table_element).'</li>';
|
|
||||||
}
|
|
||||||
}
|
|
||||||
$message_admin .= '</ul>';
|
|
||||||
|
|
||||||
$message_admin .= '<p>'.$langs->trans('Message').' : <br>'.$object->message.'</p>';
|
|
||||||
$message_admin .= '<p><a href="'.dol_buildpath('/ticket/card.php', 2).'?track_id='.$object->track_id.'" rel="nofollow noopener">'.$langs->trans('SeeThisTicketIntomanagementInterface').'</a></p>';
|
|
||||||
|
|
||||||
$from = $conf->global->MAIN_INFO_SOCIETE_NOM.' <'.$conf->global->TICKET_NOTIFICATION_EMAIL_FROM.'>';
|
|
||||||
$replyto = $from;
|
$replyto = $from;
|
||||||
|
$sendtocc = '';
|
||||||
|
$deliveryreceipt = 0;
|
||||||
|
|
||||||
if (!empty($conf->global->TICKET_DISABLE_MAIL_AUTOCOPY_TO)) {
|
if (!empty($conf->global->TICKET_DISABLE_MAIL_AUTOCOPY_TO)) {
|
||||||
$old_MAIN_MAIL_AUTOCOPY_TO = $conf->global->MAIN_MAIL_AUTOCOPY_TO;
|
$old_MAIN_MAIL_AUTOCOPY_TO = $conf->global->MAIN_MAIL_AUTOCOPY_TO;
|
||||||
$conf->global->MAIN_MAIL_AUTOCOPY_TO = '';
|
$conf->global->MAIN_MAIL_AUTOCOPY_TO = '';
|
||||||
}
|
}
|
||||||
include_once DOL_DOCUMENT_ROOT.'/core/class/CMailFile.class.php';
|
include_once DOL_DOCUMENT_ROOT.'/core/class/CMailFile.class.php';
|
||||||
$mailfile = new CMailFile($subject, $sendto, $from, $message_admin, $filepath, $mimetype, $filename, $sendtocc, '', $deliveryreceipt, -1, '', '', 'tic'.$object->id, '', 'ticket');
|
$mailfile = new CMailFile($subject, $sendto, $from, $message, $filepath, $mimetype, $filename, $sendtocc, '', $deliveryreceipt, -1, '', '', 'tic'.$object->id, '', 'ticket');
|
||||||
if ($mailfile->error || $mailfile->errors) {
|
if ($mailfile->error || $mailfile->errors) {
|
||||||
setEventMessages($mailfile->error, $mailfile->errors, 'errors');
|
setEventMessages($mailfile->error, $mailfile->errors, 'errors');
|
||||||
} else {
|
} else {
|
||||||
@ -405,36 +373,77 @@ if (empty($reshook) && $action == 'create_ticket' && GETPOST('save', 'alpha')) {
|
|||||||
if (!empty($conf->global->TICKET_DISABLE_MAIL_AUTOCOPY_TO)) {
|
if (!empty($conf->global->TICKET_DISABLE_MAIL_AUTOCOPY_TO)) {
|
||||||
$conf->global->MAIN_MAIL_AUTOCOPY_TO = $old_MAIN_MAIL_AUTOCOPY_TO;
|
$conf->global->MAIN_MAIL_AUTOCOPY_TO = $old_MAIN_MAIL_AUTOCOPY_TO;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Send email to TICKET_NOTIFICATION_EMAIL_TO
|
||||||
|
$sendto = $conf->global->TICKET_NOTIFICATION_EMAIL_TO;
|
||||||
|
if ($sendto) {
|
||||||
|
$subject = '['.$conf->global->MAIN_INFO_SOCIETE_NOM.'] '.$langs->transnoentities('TicketNewEmailSubjectAdmin', $object->ref, $object->track_id);
|
||||||
|
$message_admin = $langs->transnoentities('TicketNewEmailBodyAdmin', $object->track_id).'<br><br>';
|
||||||
|
$message_admin .= '<ul><li>'.$langs->trans('Title').' : '.$object->subject.'</li>';
|
||||||
|
$message_admin .= '<li>'.$langs->trans('Type').' : '.$object->type_label.'</li>';
|
||||||
|
$message_admin .= '<li>'.$langs->trans('Category').' : '.$object->category_label.'</li>';
|
||||||
|
$message_admin .= '<li>'.$langs->trans('Severity').' : '.$object->severity_label.'</li>';
|
||||||
|
$message_admin .= '<li>'.$langs->trans('From').' : '.$object->origin_email.'</li>';
|
||||||
|
// Extrafields
|
||||||
|
$extrafields->fetch_name_optionals_label($object->table_element);
|
||||||
|
if (is_array($object->array_options) && count($object->array_options) > 0) {
|
||||||
|
foreach ($object->array_options as $key => $value) {
|
||||||
|
$key = substr($key, 8); // remove "options_"
|
||||||
|
$message_admin .= '<li>'.$langs->trans($extrafields->attributes[$object->table_element]['label'][$key]).' : '.$extrafields->showOutputField($key, $value, '', $object->table_element).'</li>';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
$message_admin .= '</ul>';
|
||||||
|
|
||||||
|
$message_admin .= '<p>'.$langs->trans('Message').' : <br>'.$object->message.'</p>';
|
||||||
|
$message_admin .= '<p><a href="'.dol_buildpath('/ticket/card.php', 2).'?track_id='.$object->track_id.'" rel="nofollow noopener">'.$langs->trans('SeeThisTicketIntomanagementInterface').'</a></p>';
|
||||||
|
|
||||||
|
$from = $conf->global->MAIN_INFO_SOCIETE_NOM.' <'.$conf->global->TICKET_NOTIFICATION_EMAIL_FROM.'>';
|
||||||
|
$replyto = $from;
|
||||||
|
|
||||||
|
if (!empty($conf->global->TICKET_DISABLE_MAIL_AUTOCOPY_TO)) {
|
||||||
|
$old_MAIN_MAIL_AUTOCOPY_TO = $conf->global->MAIN_MAIL_AUTOCOPY_TO;
|
||||||
|
$conf->global->MAIN_MAIL_AUTOCOPY_TO = '';
|
||||||
|
}
|
||||||
|
include_once DOL_DOCUMENT_ROOT.'/core/class/CMailFile.class.php';
|
||||||
|
$mailfile = new CMailFile($subject, $sendto, $from, $message_admin, $filepath, $mimetype, $filename, $sendtocc, '', $deliveryreceipt, -1, '', '', 'tic'.$object->id, '', 'ticket');
|
||||||
|
if ($mailfile->error || $mailfile->errors) {
|
||||||
|
setEventMessages($mailfile->error, $mailfile->errors, 'errors');
|
||||||
|
} else {
|
||||||
|
$result = $mailfile->sendfile();
|
||||||
|
}
|
||||||
|
if (!empty($conf->global->TICKET_DISABLE_MAIL_AUTOCOPY_TO)) {
|
||||||
|
$conf->global->MAIN_MAIL_AUTOCOPY_TO = $old_MAIN_MAIL_AUTOCOPY_TO;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
// Copy files into ticket directory
|
// Copy files into ticket directory
|
||||||
$destdir = $conf->ticket->dir_output.'/'.$object->ref;
|
$destdir = $conf->ticket->dir_output.'/'.$object->ref;
|
||||||
if (!dol_is_dir($destdir)) {
|
if (!dol_is_dir($destdir)) {
|
||||||
dol_mkdir($destdir);
|
dol_mkdir($destdir);
|
||||||
}
|
}
|
||||||
foreach ($filename as $i => $val) {
|
foreach ($filename as $i => $val) {
|
||||||
dol_move($filepath[$i], $destdir.'/'.$filename[$i], 0, 1);
|
dol_move($filepath[$i], $destdir.'/'.$filename[$i], 0, 1);
|
||||||
$formmail->remove_attached_files($i);
|
$formmail->remove_attached_files($i);
|
||||||
}
|
}
|
||||||
|
|
||||||
//setEventMessages($langs->trans('YourTicketSuccessfullySaved'), null, 'mesgs');
|
//setEventMessages($langs->trans('YourTicketSuccessfullySaved'), null, 'mesgs');
|
||||||
|
|
||||||
// Make a redirect to avoid to have ticket submitted twice if we make back
|
// Make a redirect to avoid to have ticket submitted twice if we make back
|
||||||
$messagetoshow = $langs->trans('MesgInfosPublicTicketCreatedWithTrackId', '{s1}', '{s2}');
|
$messagetoshow = $langs->trans('MesgInfosPublicTicketCreatedWithTrackId', '{s1}', '{s2}');
|
||||||
$messagetoshow = str_replace(array('{s1}', '{s2}'), array('<strong>'.$object->track_id.'</strong>', '<strong>'.$object->ref.'</strong>'), $messagetoshow);
|
$messagetoshow = str_replace(array('{s1}', '{s2}'), array('<strong>'.$object->track_id.'</strong>', '<strong>'.$object->ref.'</strong>'), $messagetoshow);
|
||||||
setEventMessages($messagetoshow, null, 'warnings');
|
setEventMessages($messagetoshow, null, 'warnings');
|
||||||
setEventMessages($langs->trans('PleaseRememberThisId'), null, 'warnings');
|
setEventMessages($langs->trans('PleaseRememberThisId'), null, 'warnings');
|
||||||
header("Location: index.php".(!empty($entity) && !empty($conf->multicompany->enabled)?'?entity='.$entity:''));
|
header("Location: index.php".(!empty($entity) && !empty($conf->multicompany->enabled)?'?entity='.$entity:''));
|
||||||
exit;
|
exit;
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
setEventMessages($object->error, $object->errors, 'errors');
|
||||||
}
|
}
|
||||||
} else {
|
|
||||||
setEventMessages($object->error, $object->errors, 'errors');
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* View
|
* View
|
||||||
*/
|
*/
|
||||||
@ -466,6 +475,7 @@ if ($action != "infos_success") {
|
|||||||
$formticket->ispublic = 1;
|
$formticket->ispublic = 1;
|
||||||
$formticket->withfile = 2;
|
$formticket->withfile = 2;
|
||||||
$formticket->action = 'create_ticket';
|
$formticket->action = 'create_ticket';
|
||||||
|
$formticket->withcancel = 1;
|
||||||
|
|
||||||
$formticket->param = array('returnurl' => $_SERVER['PHP_SELF'].($conf->entity > 1 ? '?entity='.$conf->entity : ''));
|
$formticket->param = array('returnurl' => $_SERVER['PHP_SELF'].($conf->entity > 1 ? '?entity='.$conf->entity : ''));
|
||||||
|
|
||||||
@ -478,7 +488,7 @@ if ($action != "infos_success") {
|
|||||||
print $langs->trans("ErrorModuleSetupNotComplete", $langs->transnoentities("Ticket"));
|
print $langs->trans("ErrorModuleSetupNotComplete", $langs->transnoentities("Ticket"));
|
||||||
print '</div>';
|
print '</div>';
|
||||||
} else {
|
} else {
|
||||||
print '<div class="info marginleftonly marginrightonly">'.$langs->trans('TicketPublicInfoCreateTicket').'</div>';
|
//print '<div class="info marginleftonly marginrightonly">'.$langs->trans('TicketPublicInfoCreateTicket').'</div>';
|
||||||
$formticket->showForm(0, 'edit', 1, $with_contact);
|
$formticket->showForm(0, 'edit', 1, $with_contact);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -22,9 +22,6 @@
|
|||||||
* \brief Public page to add and manage ticket
|
* \brief Public page to add and manage ticket
|
||||||
*/
|
*/
|
||||||
|
|
||||||
if (!defined('NOCSRFCHECK')) {
|
|
||||||
define('NOCSRFCHECK', '1');
|
|
||||||
}
|
|
||||||
if (!defined('NOREQUIREMENU')) {
|
if (!defined('NOREQUIREMENU')) {
|
||||||
define('NOREQUIREMENU', '1');
|
define('NOREQUIREMENU', '1');
|
||||||
}
|
}
|
||||||
@ -82,11 +79,12 @@ $arrayofcss = array('/ticket/css/styles.css.php');
|
|||||||
llxHeaderTicket($langs->trans("Tickets"), "", 0, 0, $arrayofjs, $arrayofcss);
|
llxHeaderTicket($langs->trans("Tickets"), "", 0, 0, $arrayofjs, $arrayofcss);
|
||||||
|
|
||||||
print '<div class="ticketpublicarea">';
|
print '<div class="ticketpublicarea">';
|
||||||
print '<p style="text-align: center">'.($conf->global->TICKET_PUBLIC_TEXT_HOME ? $conf->global->TICKET_PUBLIC_TEXT_HOME : $langs->trans("TicketPublicDesc")).'</p>';
|
print '<p style="text-align: center">'.(!empty($conf->global->TICKET_PUBLIC_TEXT_HOME) ? $conf->global->TICKET_PUBLIC_TEXT_HOME : '<span class="opacitymedium">'.$langs->trans("TicketPublicDesc")).'</span></p>';
|
||||||
|
print '<br>';
|
||||||
print '<div class="ticketform">';
|
print '<div class="ticketform">';
|
||||||
print '<a href="create_ticket.php'.(!empty($entity) && !empty($conf->multicompany->enabled)?'?entity='.$entity:'').'" rel="nofollow noopener" class="butAction marginbottomonly"><div class="index_create bigrounded"><span class="fa fa-15x fa-plus-circle valignmiddle btnTitle-icon"></span><br>'.dol_escape_htmltag($langs->trans("CreateTicket")).'</div></a>';
|
print '<a href="create_ticket.php?action=create'.(!empty($entity) && !empty($conf->multicompany->enabled)?'&entity='.$entity:'').'" rel="nofollow noopener" class="butAction marginbottomonly"><div class="index_create bigrounded"><span class="fa fa-15 fa-plus-circle valignmiddle btnTitle-icon"></span><br>'.dol_escape_htmltag($langs->trans("CreateTicket")).'</div></a>';
|
||||||
print '<a href="list.php'.(!empty($entity) && !empty($conf->multicompany->enabled)?'?entity='.$entity:'').'" rel="nofollow noopener" class="butAction marginbottomonly"><div class="index_display bigrounded"><span class="fa fa-15x fa-list-alt valignmiddle btnTitle-icon"></span><br>'.dol_escape_htmltag($langs->trans("ViewMyTicketList")).'</div></a>';
|
print '<a href="list.php'.(!empty($entity) && !empty($conf->multicompany->enabled)?'?entity='.$entity:'').'" rel="nofollow noopener" class="butAction marginbottomonly"><div class="index_display bigrounded"><span class="fa fa-15 fa-list-alt valignmiddle btnTitle-icon"></span><br>'.dol_escape_htmltag($langs->trans("ViewMyTicketList")).'</div></a>';
|
||||||
print '<a href="view.php'.(!empty($entity) && !empty($conf->multicompany->enabled)?'?entity='.$entity:'').'" rel="nofollow noopener" class="butAction marginbottomonly"><div class="index_display bigrounded">'.img_picto('', 'ticket', 'class="fa-15x"').'<br>'.dol_escape_htmltag($langs->trans("ShowTicketWithTrackId")).'</div></a>';
|
print '<a href="view.php'.(!empty($entity) && !empty($conf->multicompany->enabled)?'?entity='.$entity:'').'" rel="nofollow noopener" class="butAction marginbottomonly"><div class="index_display bigrounded">'.img_picto('', 'ticket', 'class="fa-15"').'<br>'.dol_escape_htmltag($langs->trans("ShowTicketWithTrackId")).'</div></a>';
|
||||||
print '<div style="clear:both;"></div>';
|
print '<div style="clear:both;"></div>';
|
||||||
print '</div>';
|
print '</div>';
|
||||||
print '</div>';
|
print '</div>';
|
||||||
|
|||||||
@ -21,10 +21,6 @@
|
|||||||
* \brief Public file to list tickets
|
* \brief Public file to list tickets
|
||||||
*/
|
*/
|
||||||
|
|
||||||
if (!defined('NOCSRFCHECK')) {
|
|
||||||
define('NOCSRFCHECK', '1');
|
|
||||||
}
|
|
||||||
// Do not check anti CSRF attack test
|
|
||||||
if (!defined('NOREQUIREMENU')) {
|
if (!defined('NOREQUIREMENU')) {
|
||||||
define('NOREQUIREMENU', '1');
|
define('NOREQUIREMENU', '1');
|
||||||
}
|
}
|
||||||
@ -60,8 +56,10 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/payments.lib.php';
|
|||||||
$langs->loadLangs(array("companies", "other", "ticket"));
|
$langs->loadLangs(array("companies", "other", "ticket"));
|
||||||
|
|
||||||
// Get parameters
|
// Get parameters
|
||||||
$track_id = GETPOST('track_id', 'alpha');
|
|
||||||
$action = GETPOST('action', 'aZ09');
|
$action = GETPOST('action', 'aZ09');
|
||||||
|
$cancel = GETPOST('cancel', 'aZ09');
|
||||||
|
|
||||||
|
$track_id = GETPOST('track_id', 'alpha');
|
||||||
$email = strtolower(GETPOST('email', 'alpha'));
|
$email = strtolower(GETPOST('email', 'alpha'));
|
||||||
|
|
||||||
if (GETPOST('btn_view_ticket_list')) {
|
if (GETPOST('btn_view_ticket_list')) {
|
||||||
@ -90,6 +88,13 @@ if (empty($conf->ticket->enabled)) {
|
|||||||
* Actions
|
* Actions
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
if ($cancel) {
|
||||||
|
$backtopage = DOL_URL_ROOT.'/public/ticket/index.php';
|
||||||
|
|
||||||
|
header("Location: ".$backtopage);
|
||||||
|
exit;
|
||||||
|
}
|
||||||
|
|
||||||
if ($action == "view_ticketlist") {
|
if ($action == "view_ticketlist") {
|
||||||
$error = 0;
|
$error = 0;
|
||||||
$display_ticket_list = false;
|
$display_ticket_list = false;
|
||||||
@ -185,9 +190,10 @@ $arrayofcss = array('/ticket/css/styles.css.php');
|
|||||||
llxHeaderTicket($langs->trans("Tickets"), "", 0, 0, $arrayofjs, $arrayofcss);
|
llxHeaderTicket($langs->trans("Tickets"), "", 0, 0, $arrayofjs, $arrayofcss);
|
||||||
|
|
||||||
|
|
||||||
print '<div class="ticketpublicarealist">';
|
|
||||||
|
|
||||||
if ($action == "view_ticketlist") {
|
if ($action == "view_ticketlist") {
|
||||||
|
print '<div class="ticketpublicarealist">';
|
||||||
|
|
||||||
print '<br>';
|
print '<br>';
|
||||||
if ($display_ticket_list) {
|
if ($display_ticket_list) {
|
||||||
// Filters
|
// Filters
|
||||||
@ -708,8 +714,12 @@ if ($action == "view_ticketlist") {
|
|||||||
} else {
|
} else {
|
||||||
print '<div class="error">Not Allowed<br><a href="'.$_SERVER['PHP_SELF'].'?track_id='.$object->track_id.'">'.$langs->trans('Back').'</a></div>';
|
print '<div class="error">Not Allowed<br><a href="'.$_SERVER['PHP_SELF'].'?track_id='.$object->track_id.'">'.$langs->trans('Back').'</a></div>';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
print '</div>';
|
||||||
} else {
|
} else {
|
||||||
print '<p class="center">'.$langs->trans("TicketPublicMsgViewLogIn").'</p>';
|
print '<div class="ticketpublicarea">';
|
||||||
|
|
||||||
|
print '<p class="center opacitymedium">'.$langs->trans("TicketPublicMsgViewLogIn").'</p>';
|
||||||
print '<br>';
|
print '<br>';
|
||||||
|
|
||||||
print '<div id="form_view_ticket">';
|
print '<div id="form_view_ticket">';
|
||||||
@ -728,13 +738,15 @@ if ($action == "view_ticketlist") {
|
|||||||
|
|
||||||
print '<p style="text-align: center; margin-top: 1.5em;">';
|
print '<p style="text-align: center; margin-top: 1.5em;">';
|
||||||
print '<input type="submit" class="button" name="btn_view_ticket_list" value="'.$langs->trans('ViewMyTicketList').'" />';
|
print '<input type="submit" class="button" name="btn_view_ticket_list" value="'.$langs->trans('ViewMyTicketList').'" />';
|
||||||
|
print ' ';
|
||||||
|
print '<input type="submit" class="button button-cancel" name="cancel" value="'.$langs->trans("Cancel").'">';
|
||||||
print "</p>\n";
|
print "</p>\n";
|
||||||
|
|
||||||
print "</form>\n";
|
print "</form>\n";
|
||||||
print "</div>\n";
|
print "</div>\n";
|
||||||
}
|
|
||||||
|
|
||||||
print "</div>";
|
print "</div>";
|
||||||
|
}
|
||||||
|
|
||||||
// End of page
|
// End of page
|
||||||
htmlPrintOnlinePaymentFooter($mysoc, $langs, 0, $suffix, $object);
|
htmlPrintOnlinePaymentFooter($mysoc, $langs, 0, $suffix, $object);
|
||||||
|
|||||||
@ -22,10 +22,6 @@
|
|||||||
* \brief Public file to show one ticket
|
* \brief Public file to show one ticket
|
||||||
*/
|
*/
|
||||||
|
|
||||||
if (!defined('NOCSRFCHECK')) {
|
|
||||||
define('NOCSRFCHECK', '1');
|
|
||||||
}
|
|
||||||
// Do not check anti CSRF attack test
|
|
||||||
if (!defined('NOREQUIREMENU')) {
|
if (!defined('NOREQUIREMENU')) {
|
||||||
define('NOREQUIREMENU', '1');
|
define('NOREQUIREMENU', '1');
|
||||||
}
|
}
|
||||||
@ -61,9 +57,10 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/payments.lib.php';
|
|||||||
$langs->loadLangs(array("companies", "other", "ticket"));
|
$langs->loadLangs(array("companies", "other", "ticket"));
|
||||||
|
|
||||||
// Get parameters
|
// Get parameters
|
||||||
$track_id = GETPOST('track_id', 'alpha');
|
|
||||||
$cancel = GETPOST('cancel', 'alpha');
|
|
||||||
$action = GETPOST('action', 'aZ09');
|
$action = GETPOST('action', 'aZ09');
|
||||||
|
$cancel = GETPOST('cancel', 'aZ09');
|
||||||
|
|
||||||
|
$track_id = GETPOST('track_id', 'alpha');
|
||||||
$email = GETPOST('email', 'email');
|
$email = GETPOST('email', 'email');
|
||||||
|
|
||||||
if (GETPOST('btn_view_ticket')) {
|
if (GETPOST('btn_view_ticket')) {
|
||||||
@ -85,6 +82,8 @@ if (empty($conf->ticket->enabled)) {
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
if ($cancel) {
|
if ($cancel) {
|
||||||
|
$backtopage = DOL_URL_ROOT.'/public/ticket/index.php';
|
||||||
|
|
||||||
if (!empty($backtopage)) {
|
if (!empty($backtopage)) {
|
||||||
header("Location: ".$backtopage);
|
header("Location: ".$backtopage);
|
||||||
exit;
|
exit;
|
||||||
@ -406,6 +405,8 @@ if ($action == "view_ticket" || $action == "presend" || $action == "close" || $a
|
|||||||
|
|
||||||
print '<p style="text-align: center; margin-top: 1.5em;">';
|
print '<p style="text-align: center; margin-top: 1.5em;">';
|
||||||
print '<input type="submit" class="button" name="btn_view_ticket" value="'.$langs->trans('ViewTicket').'" />';
|
print '<input type="submit" class="button" name="btn_view_ticket" value="'.$langs->trans('ViewTicket').'" />';
|
||||||
|
print ' ';
|
||||||
|
print '<input type="submit" class="button button-cancel" name="cancel" value="'.$langs->trans("Cancel").'">';
|
||||||
print "</p>\n";
|
print "</p>\n";
|
||||||
|
|
||||||
print "</form>\n";
|
print "</form>\n";
|
||||||
|
|||||||
@ -18,10 +18,6 @@
|
|||||||
/* font-size: <?php echo $topMenuFontSize; ?>; */
|
/* font-size: <?php echo $topMenuFontSize; ?>; */
|
||||||
}
|
}
|
||||||
|
|
||||||
.fa-15x {
|
|
||||||
font-size: 1.5em;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.mainmenu.menu {
|
div.mainmenu.menu {
|
||||||
background-image: none;
|
background-image: none;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -18,10 +18,6 @@
|
|||||||
color: var(--colortextbackhmenu);
|
color: var(--colortextbackhmenu);
|
||||||
}
|
}
|
||||||
|
|
||||||
.fa-15x {
|
|
||||||
font-size: 1.5em;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.mainmenu.menu {
|
div.mainmenu.menu {
|
||||||
background-image: none;
|
background-image: none;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -316,7 +316,9 @@ class User extends CommonObject
|
|||||||
* @var stdClass To store personal config
|
* @var stdClass To store personal config
|
||||||
*/
|
*/
|
||||||
public $conf;
|
public $conf;
|
||||||
public $default_values; // To store default values for user
|
|
||||||
|
public $default_values; // To store default values for user. Loaded by loadDefaultValues().
|
||||||
|
|
||||||
public $lastsearch_values_tmp; // To store current search criterias for user
|
public $lastsearch_values_tmp; // To store current search criterias for user
|
||||||
public $lastsearch_values; // To store last saved search criterias for user
|
public $lastsearch_values; // To store last saved search criterias for user
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user