workflows: include disabled handle (for layout) on readonly workflows (#58027)
This commit is contained in:
parent
8bb6391359
commit
759df9acfc
|
@ -1262,7 +1262,7 @@ class GlobalActionPage(WorkflowStatusPage):
|
|||
r += htmltext('<p>%s</p>') % _('There are not yet any items in this action.')
|
||||
else:
|
||||
if self.workflow.is_readonly():
|
||||
r += htmltext('<ul id="items-list" class="biglist">')
|
||||
r += htmltext('<ul id="items-list" class="biglist readonly">')
|
||||
else:
|
||||
r += htmltext('<p class="items">')
|
||||
r += _('Use drag and drop with the handles to reorder items.')
|
||||
|
@ -1286,10 +1286,12 @@ class GlobalActionPage(WorkflowStatusPage):
|
|||
r += htmltext('</ul>')
|
||||
r += htmltext('</div>') # bo-block
|
||||
|
||||
sortable = 'sortable readonly' if self.workflow.is_readonly() else 'sortable'
|
||||
r += htmltext('<div class="bo-block">')
|
||||
r += htmltext('<h2>%s</h2>') % _('Triggers')
|
||||
r += htmltext(
|
||||
'<ul id="items-list" class="biglist sortable" data-order-function="update_triggers_order">'
|
||||
r += (
|
||||
htmltext('<ul id="items-list" class="biglist %s" data-order-function="update_triggers_order">')
|
||||
% sortable
|
||||
)
|
||||
for trigger in self.action.triggers:
|
||||
r += htmltext('<li class="biglistitem" id="trigId_%s">') % trigger.id
|
||||
|
|
|
@ -50,6 +50,11 @@ ul.biglist span.handle,
|
|||
text-align: left;
|
||||
}
|
||||
|
||||
ul.biglist.readonly span.handle {
|
||||
opacity: 0.5;
|
||||
cursor: not-allowed;
|
||||
}
|
||||
|
||||
ul.biglist li,
|
||||
li.biglistitem {
|
||||
list-style-type: none;
|
||||
|
|
|
@ -23,7 +23,7 @@
|
|||
{% spaceless %}
|
||||
<div class="bo-block">
|
||||
{% if workflow.is_readonly %}
|
||||
<ul id="items-list" class="biglist">
|
||||
<ul id="items-list" class="biglist sortable readonly">
|
||||
{% else %}
|
||||
<p class="hint">{% trans "Use drag and drop with the handles to reorder items." %}</p>
|
||||
<ul id="items-list" class="biglist sortable">
|
||||
|
|
Loading…
Reference in New Issue