From b8ec86671a889a004fc5d438dfe730f4ba093211 Mon Sep 17 00:00:00 2001 From: Tim Fry Date: Sat, 23 Nov 2024 00:54:08 -0400 Subject: [PATCH] remove commented code and update detail data --- app/phrases/phrase_edit.php | 72 +++---------------------------------- 1 file changed, 5 insertions(+), 67 deletions(-) diff --git a/app/phrases/phrase_edit.php b/app/phrases/phrase_edit.php index e6e3eb1332..d6e3435d62 100644 --- a/app/phrases/phrase_edit.php +++ b/app/phrases/phrase_edit.php @@ -97,7 +97,7 @@ //process the changes from the http post if (count($_POST) > 0 && empty($_POST["persistformvar"])) { - + //get the uuid if ($action == "update") { $phrase_uuid = $_POST["phrase_uuid"]; @@ -506,7 +506,7 @@ echo " ".$text['description-language']."\n"; echo "\n"; echo "\n"; - + //structure row echo ""; echo "".$text['label-structure'].""; echo ""; @@ -520,62 +520,14 @@ echo " " . ($text['label-order'] ?? 'Order') . "\n"; echo " ".$text['label-action']."\n"; echo " ".($text['label-recording'] ?? 'Recording')."\n"; -/* -// echo " ".$text['label-order']."\n"; -// if (!empty($phrase_details)) { -// echo " \n"; -// echo " ".$text['label-delete']."\n"; -// echo " \n"; -// echo " \n"; -// } -//*/ echo " \n"; echo " \n"; echo "\n"; -/* -// if (!empty($phrase_details)) { -// foreach($phrase_details as $x => $field) { -// //clean up output for display -// if ($field['phrase_detail_function'] == 'play-file' && substr($field['phrase_detail_data'], 0, 21) == '${lua streamfile.lua ') { -// $phrase_detail_function = $text['label-play']; -// $phrase_detail_data = str_replace('${lua streamfile.lua ', '', $field['phrase_detail_data']); -// $phrase_detail_data = str_replace('}', '', $phrase_detail_data); -// } -// else if ($field['phrase_detail_function'] == 'execute' && substr($field['phrase_detail_data'], 0, 6) == 'sleep(') { -// $phrase_detail_function = $text['label-pause']; -// $phrase_detail_data = str_replace('sleep(', '', $field['phrase_detail_data']); -// $phrase_detail_data = str_replace(')', '', $phrase_detail_data); -// $phrase_detail_data = ($phrase_detail_data / 1000).'s'; // seconds -// } -// else if ($field['phrase_detail_function'] == 'play-file') { -// $phrase_detail_function = $text['label-play']; -// $phrase_detail_data = str_replace($_SESSION['switch']['recordings']['dir'].'/'.$_SESSION['domain_name'].'/', '', $field['phrase_detail_data']); -// } -// else { -// $phrase_detail_function = $field['phrase_detail_function']; -// $phrase_detail_data = $field['phrase_detail_data']; -// } -// echo "\n"; -// echo " ".escape($phrase_detail_function)." \n"; -// echo " ".escape($phrase_detail_data)." \n"; -// echo " ".$field['phrase_detail_order']." \n"; -// echo " "; -// if (is_uuid($field['phrase_detail_uuid'])) { -// echo " \n"; -// echo " \n"; -// } -// echo " \n"; -// echo "\n"; -// } -// } -// unset($phrase_details, $field); -//*/ - //draggable row echo "\n"; echo "
"; echo " \n"; - echo " \n"; echo " \n"; echo " \n"; if (if_group("superadmin")) { @@ -584,23 +536,11 @@ echo " \n"; echo " \n"; echo " \n"; -// echo " "; - echo " "; + echo " "; if (if_group("superadmin")) { - echo " \n"; + echo " \n"; } - //echo " \n"; echo " \n"; -/* -// echo " \n"; -// echo " \n"; -// echo " \n"; -// */ echo " \n"; echo ""; echo ""; @@ -690,5 +630,3 @@ //include the footer require_once "resources/footer.php"; - -?>