From d679562344572c26306089ab1353e960aa4c0082 Mon Sep 17 00:00:00 2001 From: Jim Mason Date: Fri, 4 Oct 2024 19:10:10 +0100 Subject: [PATCH] improved efficiency in edit track; finessed formatting --- ui/templates/default/list/editItem.html | 26 ++++++++++++------------- ui/templates/default/list/editor.html | 8 ++++---- 2 files changed, 17 insertions(+), 17 deletions(-) diff --git a/ui/templates/default/list/editItem.html b/ui/templates/default/list/editItem.html index 0dfe4450..0ff8ba32 100644 --- a/ui/templates/default/list/editItem.html +++ b/ui/templates/default/list/editItem.html @@ -3,22 +3,22 @@ {% block banner %}
 Editing highlighted item
-{% if entry.getType() == constant('TYPE_SET_SEPARATOR', entry) %} -{% set type='set-separator' %} -{% elseif entry.getType() == constant('TYPE_COMMENT', entry) %} -{% set type='comment-entry' %} +{% set type = entry.getType() %} +{% if type is constant('TYPE_SPIN', entry) %} + {%~ set etype = 'manual-entry' %} + {%~ set album = entry.asArray() %} + {%~ for field in ['tag', 'artist', 'album', 'label', 'title'] %} + + {%~ endfor %} +{% elseif type is constant('TYPE_COMMENT', entry) %} + {%~ set etype = 'comment-entry' %} -{% elseif entry.getType() == constant('TYPE_LOG_EVENT', entry) %} -{% set type=NME_PREFIX ~ entry.getLogEventType() %} +{% elseif type is constant('TYPE_LOG_EVENT', entry) %} + {%~ set etype = NME_PREFIX ~ entry.getLogEventType() %} {% else %} -{% set type='manual-entry' %} -{% set album = entry.asArray() %} -{% for field in ['tag', 'artist', 'album', 'label', 'title'] %} - -{% endfor %} + {%~ set etype = 'set-separator' %} {% endif %} - - + {% endblock %} diff --git a/ui/templates/default/list/editor.html b/ui/templates/default/list/editor.html index 3ca2bbc8..692b51bf 100644 --- a/ui/templates/default/list/editor.html +++ b/ui/templates/default/list/editor.html @@ -4,13 +4,13 @@ {% set djName = playlist.airname ?? "None" %} {% set djLink = djId ? "" ~ djName | e ~ "" : djName | e %} -
{{ showDateTime }} +
{{ showDateTime }} {%- if not editMode and app.session.isAuth('v') -%}  
" {%- endif -%}  
- + {% endblock %} {#--------------------------------------------------------------------------#} {% block entry %} {% set isLiveShow = not editTrack and isLive %} -
+
{#~ TZO is server equivalent of javascript Date.getTimezoneOffset() #}