From 175d4b734161a2c95a16048fb48a59e13320249d Mon Sep 17 00:00:00 2001 From: Jose Gonzalez Date: Thu, 9 Feb 2023 16:13:30 +0100 Subject: [PATCH] Fixes in Event view and other fixes --- .../godmode/events/event_responses.editor.php | 76 +++++--- .../godmode/events/event_responses.list.php | 97 ++++++---- .../godmode/events/event_responses.php | 38 ++-- pandora_console/godmode/events/events.php | 55 ++++-- pandora_console/images/edit_columns@svg.svg | 10 + .../images/exit_fullscreen@svg.svg | 9 + .../{delete-v2@svg.svg => fail@svg.svg} | 0 pandora_console/images/filters@svg.svg | 9 + pandora_console/images/fullscreen@svg.svg | 9 + pandora_console/images/rrs@svg.svg | 9 + pandora_console/images/sound_console@svg.svg | 9 + pandora_console/include/ajax/events.php | 34 ++-- pandora_console/include/functions_events.php | 74 ++++--- pandora_console/include/functions_modules.php | 12 +- pandora_console/include/functions_ui.php | 14 +- pandora_console/include/styles/events.css | 26 +++ .../include/styles/js/jquery-ui_custom.css | 2 +- pandora_console/include/styles/pandora.css | 29 ++- pandora_console/operation/events/events.php | 182 +++++++++--------- 19 files changed, 445 insertions(+), 249 deletions(-) create mode 100644 pandora_console/images/edit_columns@svg.svg create mode 100644 pandora_console/images/exit_fullscreen@svg.svg rename pandora_console/images/{delete-v2@svg.svg => fail@svg.svg} (100%) create mode 100644 pandora_console/images/filters@svg.svg create mode 100644 pandora_console/images/fullscreen@svg.svg create mode 100644 pandora_console/images/rrs@svg.svg create mode 100644 pandora_console/images/sound_console@svg.svg diff --git a/pandora_console/godmode/events/event_responses.editor.php b/pandora_console/godmode/events/event_responses.editor.php index 1c02545ccd..1e85796740 100644 --- a/pandora_console/godmode/events/event_responses.editor.php +++ b/pandora_console/godmode/events/event_responses.editor.php @@ -1,16 +1,32 @@ 0) { } $table = new stdClass(); -$table->width = '100%'; +$table->styleTable = 'margin: 10px 10px 0'; $table->class = 'databox filters'; if (is_metaconsole()) { @@ -211,23 +227,29 @@ $data[1] = html_print_checkbox_switch( $table->data[6] = $data; -if ($event_response_id == 0) { - echo '
'; - html_print_table($table); - echo '
'; - - html_print_submit_button(__('Create'), 'create_response_button', false, ['class' => 'sub next']); - echo '
'; - echo '
'; +if ((int) $event_response_id === 0) { + $actionUrl = 'index.php?sec=geventos&sec2=godmode/events/events§ion=responses&mode=list&action=create_response&pure='.$config['pure']; + $buttonCaption = __('Create'); + $buttonName = 'create_response_button'; } else { - echo '
'; - html_print_table($table); - echo '
'; - - html_print_submit_button(__('Update'), 'update_response_button', false, ['class' => 'sub next']); - echo '
'; - echo '
'; + $actionUrl = 'index.php?sec=geventos&sec2=godmode/events/events§ion=responses&mode=list&action=update_response&pure='.$config['pure']; + $buttonCaption = __('Update'); + $buttonName = 'update_response_button'; } + +echo '
'; +html_print_table($table); +html_print_action_buttons( + html_print_submit_button( + $buttonCaption, + $buttonName, + false, + ['icon' => 'wand'], + true + ), + [ 'type' => 'form_action'] +); +echo '
'; ?>