EVVA E-Montage Johannes.xml 4.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150
  1. <testset xmlns="http://cpee.org/ns/properties/2.0">
  2. <dataelements>
  3. <station>2</station>
  4. <productcode>Te.st.1</productcode>
  5. <tablets>{"1":"emontagea","2":"emontageb","3":"emontagec","8":"emontaged"}</tablets>
  6. <finished>false</finished>
  7. </dataelements>
  8. <handlerwrapper>DefaultHandlerWrapper</handlerwrapper>
  9. <endpoints>
  10. <put>https-put://centurio.work/wiz/</put>
  11. <get>https://centurio.work/customers/evva/was/server/</get>
  12. <path>https://centurio.work/customers/evva/was/server/</path>
  13. </endpoints>
  14. <description>
  15. <description xmlns="http://cpee.org/ns/description/1.0">
  16. <call id="a1" endpoint="get">
  17. <parameters>
  18. <label>Get Images</label>
  19. <method>:get</method>
  20. <arguments/>
  21. <stream>
  22. <sensors/>
  23. <aggregators/>
  24. <costs/>
  25. </stream>
  26. </parameters>
  27. <code>
  28. <prepare>endpoints.get = File.join(endpoints.path,data.station.to_s,"search/imagesWIZ?pattern=" + data.productcode.gsub(/\//,'_'))</prepare>
  29. <finalize output="result">data.num = 1
  30. data.images = result</finalize>
  31. <update output="result"/>
  32. <rescue output="result"/>
  33. </code>
  34. <annotations>
  35. <_timing>
  36. <_timing_wait/>
  37. <_timing_threshold/>
  38. <_timing_min/>
  39. <_timing_max/>
  40. <_timing_avg/>
  41. </_timing>
  42. <_notes>
  43. <_notes_general/>
  44. </_notes>
  45. </annotations>
  46. </call>
  47. <loop mode="pre_test" condition="!data.finished">
  48. <call id="a3" endpoint="get">
  49. <parameters>
  50. <label>Get Images2</label>
  51. <method>:get</method>
  52. <arguments/>
  53. <stream>
  54. <sensors/>
  55. <aggregators/>
  56. <costs/>
  57. </stream>
  58. </parameters>
  59. <code>
  60. <prepare>endpoints.get = File.join(endpoints.path,data.station.to_s,"search/imagesWIZ?pattern=" + data.productcode.gsub(/\//,'_'))</prepare>
  61. <finalize output="result">data.images = result</finalize>
  62. <update output="result"/>
  63. <rescue output="result"/>
  64. </code>
  65. <annotations>
  66. <_timing>
  67. <_timing_wait/>
  68. <_timing_threshold/>
  69. <_timing_min/>
  70. <_timing_max/>
  71. <_timing_avg/>
  72. </_timing>
  73. <_notes>
  74. <_notes_general/>
  75. </_notes>
  76. </annotations>
  77. </call>
  78. <_probability>
  79. <_probability_min/>
  80. <_probability_max/>
  81. <_probability_avg/>
  82. </_probability>
  83. <call id="a2" endpoint="put">
  84. <parameters>
  85. <label>Set Image</label>
  86. <method>:put</method>
  87. <arguments>
  88. <num>!data.num</num>
  89. <total>!data.images.length</total>
  90. <style_url>https://centurio.work/customers/evva/wiz/style.css</style_url>
  91. <image_url>!File.join(endpoints.get,data.station.to_s,"search/imagesWIZ",(data.num-1).to_s, "?pattern=" + data.productcode.gsub(/\//,'_') + "&amp;*ProductCode=" + data.productcode.gsub(/\//,'_'))</image_url>
  92. <errors_url>!File.join(endpoints.get,data.station.to_s,"search/errorsWIZ","?pattern=" + data.productcode.gsub(/\//,'_') + "&amp;*ProductCode=" + data.productcode.gsub(/\//,'_'))</errors_url>
  93. </arguments>
  94. <stream>
  95. <sensors/>
  96. <aggregators/>
  97. <costs/>
  98. </stream>
  99. </parameters>
  100. <code>
  101. <prepare>endpoints.put = File.join(endpoints.put,"Johannes" + '/')</prepare>
  102. <finalize output="result">case result['operation']
  103. when 'next'
  104. data.num += 1
  105. when 'prev'
  106. data.num -= 1
  107. when 'jump'
  108. if result['target'].to_i == -1
  109. data.num = data.images.length
  110. else
  111. data.num = result['target'].to_i
  112. end
  113. when 'error'
  114. data.reason = result['reason']
  115. data.finished = true
  116. when 'finish'
  117. data.finished = true
  118. end</finalize>
  119. <update output="result"/>
  120. <rescue output="result"/>
  121. </code>
  122. <annotations>
  123. <_timing>
  124. <_timing_wait/>
  125. <_timing_threshold/>
  126. <_timing_min/>
  127. <_timing_max/>
  128. <_timing_avg/>
  129. </_timing>
  130. <_notes>
  131. <_notes_general/>
  132. </_notes>
  133. </annotations>
  134. </call>
  135. </loop>
  136. </description>
  137. </description>
  138. <transformation>
  139. <description type="copy"/>
  140. <dataelements type="none"/>
  141. <endpoints type="none"/>
  142. </transformation>
  143. <attributes>
  144. <info>EVVA E-Montage UI</info>
  145. <modeltype>CPEE</modeltype>
  146. <theme>preset</theme>
  147. <customer>pilotfabrik</customer>
  148. <status>development</status>
  149. </attributes>
  150. </testset>