editWorkflow.smarty
2.84 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
<h2>Workflow: {$oWorkflow->getName()|escape}</h2>
<form action="{$smarty.server.PHP_SELF}" method="POST">
<fieldset>
<legend>Edit workflow properties</legend>
<input type="hidden" name="action" value="saveWorkflow" />
<input type="hidden" name="fWorkflowId" value="{$oWorkflow->getId()}" />
{foreach item=oWidget from=$edit_fields}
{$oWidget->render()}
{/foreach}
<div class="form_actions">
<input type="submit" name="submit" value="Update workflow properties" />
</div>
</fieldset>
</form>
<h3>States</h3>
<p class="descriptiveText"><strong>FIXME</strong> insert intelligent help.</p>
<form action="{$smarty.server.PHP_SELF}" method="POST">
<fieldset>
<legend>Create a new state</legend>
<input type="hidden" name="action" value="newState" />
<input type="hidden" name="fWorkflowId" value="{$oWorkflow->getId()}" />
{foreach item=oWidget from=$add_state_fields}
{$oWidget->render()}
{/foreach}
<div class="form_actions">
<input type="submit" name="submit" value="Create state" />
</div>
</fieldset>
</form>
{if $aStates}
<h4>Existing states</h4>
<p class="descriptiveText">Select a state to update its properties.</p>
<ul>
{foreach from=$aStates item=oState}
<li><a
href="?action=editState&fWorkflowId={$oWorkflow->getId()}&fStateId={$oState->getId()}"
title="State {$oState->getId()}">{$oState->getName()|escape}</a></li>
{/foreach}
</ul>
{/if}
<h3>Transitions</h3>
<p class="descriptiveText"><strong>FIXME</strong> insert intelligent help.</p>
<form action="{$smarty.server.PHP_SELF}" method="POST">
<fieldset>
<legend>Create a new transition</legend>
<input type="hidden" name="action" value="newTransition" />
<input type="hidden" name="fWorkflowId" value="{$oWorkflow->getId()}" />
{foreach item=oWidget from=$add_transition_fields}
{$oWidget->render()}
{/foreach}
<div class="form_actions">
<input type="submit" name="submit" value="Create transition" />
</div>
</fieldset>
</form>
{if $aTransitions}
<h3>Existing transitions</h3>
<ul>
{foreach from=$aTransitions item=oTransition}
<li><a
href="?action=editTransition&fWorkflowId={$oWorkflow->getId()}&fTransitionId={$oTransition->getId()}"
title="Transition {$oTransition->getId()}">{$oTransition->getName()|escape}</a></li>
{/foreach}
</ul>
{/if}
<form action="{$smarty.server.PHP_SELF}" method="POST">
<fieldset>
<legend>Actions controlled</legend>
<p class="descriptiveText"><strong>FIXME</strong> be helpful</p>
<input type="hidden" name="action" value="setWorkflowActions" />
<input type="hidden" name="fWorkflowId" value="{$oWorkflow->getId()}" />
<ul>
{entity_checkboxes name="fActions" entities=$aActions idmethod="getName" method="getDisplayName" assign="aCheckboxes" selected="$aActionsSelected"}
{foreach from=$aCheckboxes item=sCheckbox}
<li>{$sCheckbox}</li>
{/foreach}
</ul>
<div class="form_actions">
<input type="submit" name="submit" value="Set controlled actions" />
</div>
</fieldset>
</form>