equal
deleted
inserted
replaced
11 |
11 |
12 Additional arguments are unordered options: |
12 Additional arguments are unordered options: |
13 |
13 |
14 - Absolute: force page jump to be not relative even if first path is of type HMI_NODE |
14 - Absolute: force page jump to be not relative even if first path is of type HMI_NODE |
15 |
15 |
16 - name=value: Notify jump by setting variable with path having same name assigned |
16 - name=value: Notify PLC about jump by setting variable with path having same name assigned |
17 |
17 |
18 "active"+"inactive" labeled elements can be provided and reflect current |
18 "active"+"inactive" labeled elements can be provided and reflect current |
19 page being shown. |
19 page being shown. |
20 |
20 |
21 Exemples: |
21 Exemples: |
32 |
32 |
33 Forced absolute jump: |
33 Forced absolute jump: |
34 |
34 |
35 HMI:Jump:AbsolutePage:Absolute@/PUMP9 |
35 HMI:Jump:AbsolutePage:Absolute@/PUMP9 |
36 HMI:Jump:AbsolutePage:Absolute:notify=1@notify=/PUMP9 |
36 HMI:Jump:AbsolutePage:Absolute:notify=1@notify=/PUMP9 |
|
37 |
|
38 Jump with feedback |
|
39 |
|
40 HMI:Jump:AbsolutePage:notify=1@notify=.did_jump |
37 |
41 |
38 || |
42 || |
39 |
43 |
40 shortdesc > Jump to given page |
44 shortdesc > Jump to given page |
41 |
45 |
61 if(that.enable_state) { |
65 if(that.enable_state) { |
62 const index = |
66 const index = |
63 (that.is_relative && that.indexes.length > 0) ? |
67 (that.is_relative && that.indexes.length > 0) ? |
64 that.indexes[0] + that.offset : undefined; |
68 that.indexes[0] + that.offset : undefined; |
65 fading_page_switch(name, index); |
69 fading_page_switch(name, index); |
|
70 that.notify(); |
66 } |
71 } |
67 } |
72 } |
68 } |
73 } |
69 |
74 |
70 notify_page_change(page_name, index) { |
75 notify_page_change(page_name, index) { |
104 otherwise > false |
109 otherwise > false |
105 } |
110 } |
106 > ;\n |
111 > ;\n |
107 | }, |
112 | }, |
108 |
113 |
|
114 | notify: function() { |
|
115 const "paths","path"; |
|
116 foreach "arg[position()>1 and contains(@value,'=')]"{ |
|
117 const "name","substring-before(@value,'=')"; |
|
118 const "value","substring-after(@value,'=')"; |
|
119 const "index" foreach "$paths" if "@assign = $name" value "position()-1"; |
|
120 | // «@value» |
|
121 | this.apply_hmi_value(«$index», «$value»); |
|
122 } |
|
123 | }, |
109 } |
124 } |
110 |
125 |
111 widget_page("Jump"){ |
126 widget_page("Jump"){ |
112 param "page_desc"; |
127 param "page_desc"; |
113 /* jump is considered relative jump if first path points to HMI_NODE |
128 /* jump is considered relative jump if first path points to HMI_NODE |