'index.php?sec=ITSM&sec2=operation/ITSM/itsm',
'label' => __('ITSM'),
],
[
'link' => 'index.php?sec=ITSM&sec2=operation/ITSM/itsm&operation=list',
'label' => __('ITSM Tickets'),
],
[
'link' => 'index.php?sec=ITSM&sec2=operation/ITSM/itsm&operation=edit',
'label' => __('Edit'),
],
]
);
if (empty($error) === false) {
ui_print_error_message($error);
}
if (empty($successfullyMsg) === false) {
ui_print_success_message($successfullyMsg);
}
// Main table.
$table = new stdClass();
$table->width = '100%';
$table->id = 'edit-ticket-itms';
$table->class = 'databox filter-table-adv';
$table->data = [];
$table->colspan[0][0] = 2;
$table->colspan[2][0] = 3;
$table->colspan[5][0] = 3;
$table->colspan[6][0] = 3;
$table->data[0][0] = html_print_label_input_block(
__('Title'),
html_print_input_text(
'title',
($incidence['title'] ?? ''),
__('Name'),
30,
100,
true,
false,
true,
'',
'w100p'
)
);
$ITSM_logo = 'images/pandoraITSM_logo_gray.png';
if ($config['style'] === 'pandora_black' && is_metaconsole() === false) {
$ITSM_logo = 'images/pandoraITSM_logo.png';
}
$table->data[0][2] = '
'.html_print_image(
$ITSM_logo,
true,
['style' => 'width: -webkit-fill-available;'],
false
).'
';
$table->data[1][0] = html_print_label_input_block(
__('Type'),
html_print_select(
$objectTypes,
'idIncidenceType',
($incidence['idIncidenceType'] ?? ''),
'',
__('Select'),
0,
true,
false,
true,
'',
false,
'width: 100%;'
)
);
$table->data[1][1] = html_print_label_input_block(
__('Group'),
html_print_select(
$groups,
'idGroup',
($incidence['idGroup'] ?? ''),
'',
'',
0,
true,
false,
true,
'',
false,
'width: 100%;'
)
);
$table->data[1][2] = html_print_label_input_block(
__('Priority'),
html_print_select(
$priorities,
'priority',
($incidence['priority'] ?? 0),
'',
'',
1,
true,
false,
true,
'',
false,
'width: 100%;'
)
);
$table->data[2][0] = 'WIP...
';
$table->data[3][0] = html_print_label_input_block(
__('Status'),
html_print_select(
$status,
'status',
($incidence['status'] ?? 0),
'',
'',
1,
true,
false,
true,
'',
false,
'width: 100%;'
)
);
$table->data[3][1] = html_print_label_input_block(
__('Creator').ui_print_help_tip(
__('This field corresponds to the ITSM user specified in ITSM setup'),
true
),
html_print_input_text(
'idCreator',
'',
'',
0,
100,
true,
true,
false,
'',
'w100p'
)
);
$table->data[3][2] = html_print_label_input_block(
__('Owner').ui_print_help_tip(__('Type at least two characters to search the user.'), true),
html_print_autocomplete_users_from_pandora_itsm(
'owner',
($incidence['owner'] ?? ''),
true,
0,
false,
true,
'w100p',
)
);
$table->data[4][0] = ''.html_print_label_input_block(
__('Resolution'),
html_print_select(
$resolutions,
'resolution',
($incidence['resolution'] ?? 0),
'',
__('None'),
null,
true,
false,
true,
'',
false,
'width: 100%;'
).'
'
);
$table->data[5][0] = html_print_label_input_block(
__('Description').$help_macros,
html_print_textarea(
'description',
3,
20,
($incidence['description'] ?? ''),
'',
true
)
);
$formName = 'create_itsm_incident_form';
$classForm = 'max_floating_element_size';
$enctype = 'multipart/form-data';
echo '';
ui_require_javascript_file('tinymce', 'vendor/tinymce/tinymce/');
?>