UIE031010.xrw 14 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <?xml-stylesheet href="../../css/body.css" type="text/css" ?>
  3. <xhtml:html xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://www.w3.org/2002/01/xforms" xmlns:ev="http://www.w3.org/2001/xml-events">
  4. <xhtml:head>
  5. <xhtml:title>
  6. <![CDATA[进程管理 >> 充当管理 >> 充当订单对象选定]]>
  7. </xhtml:title>
  8. <model id="model1">
  9. <instance id="instance1">
  10. <root xmlns="">
  11. <initData>
  12. <searchInfo>
  13. <LG_CD>A01001,A01004,A01007,B01001</LG_CD>
  14. </searchInfo>
  15. </initData>
  16. <codeData>
  17. <ORD_SEQ/>
  18. </codeData>
  19. <formData>
  20. <searchInfo>
  21. <PRODNM_CD/>
  22. <CUST_CD/>
  23. <STL_GRD/>
  24. <ORD_NO/>
  25. <ORD_SEQ/>
  26. <RCVORD_CLF/>
  27. <DEL_FR_DATE/>
  28. <DEL_TO_DATE/>
  29. <ORD_USEAGE_CD/>
  30. <SPEC_ABBSYM/>
  31. <ORD_THK_MIN>0</ORD_THK_MIN>
  32. <ORD_THK_MAX>999.999</ORD_THK_MAX>
  33. <ORD_WTH_MIN>0</ORD_WTH_MIN>
  34. <ORD_WTH_MAX>99999.9</ORD_WTH_MAX>
  35. </searchInfo>
  36. </formData>
  37. <gridData>
  38. </gridData>
  39. </root>
  40. </instance>
  41. <script type="javascript" ev:event="xforms-ready">
  42. <![CDATA[
  43. if (window.parent == null) Init();
  44. ]]>
  45. </script>
  46. </model>
  47. <script type="javascript" src="../../js/boaCommon.js"/>
  48. <script type="javascript" src="../../js/boaMsg.js"/>
  49. <script type="javascript" src="../../js/mesCommon.js">
  50. <![CDATA[
  51. submitID = "UIE031010-service";
  52. function Init(node) {
  53. InitParams(node);
  54. exec("/root/initData/searchInfo", "", "", "/root/codeData/ListResult_0_VO",
  55. "/root/codeData/ListResult_1_VO", "/root/codeData/ListResult_2_VO");
  56. model.setValue("/root/formData/searchInfo/DEL_FR_DATE", commFirstDay());
  57. model.setValue("/root/formData/searchInfo/DEL_TO_DATE", commCurDate());
  58. pageInit();
  59. model.duplicate("/root/formData/searchInfo", "/root/initData/rcvInfo/REG_ID");
  60. }
  61. function pageInit() {
  62. model.removenode("/root/reqData");
  63. model.removenode("/root/resData");
  64. model.refresh();
  65. var datagrid = datagrid1;
  66. datagrid.rebuild();
  67. commGridInit(datagrid);
  68. var rows = (datagrid.rows < 30) ? datagrid.rows : 30;
  69. for (var i = datagrid.fixedRows + 1; i < 30; i += 2)
  70. datagrid.rowStyle(i, "data", "background-color") = "#F7F9F9";
  71. isReadOnly(datagrid, "CUST_CD,PRODNM_CD,ORD_USEAGE_CD");
  72. colStyle(datagrid, "CHK,DESIGN_SLAB_THK,DESIGN_SLAB_WTH,REP_CONF_WGT");
  73. }
  74. function find() {
  75. exec("/root/formData/searchInfo", "", "find", "/root/gridData/ListResult_0_VO");
  76. var datagrid = datagrid1;
  77. var rows = datagrid.rows;
  78. var colChk = datagrid.colRef("CHK");
  79. for (var i=datagrid.fixedRows; i<rows; i++)
  80. datagrid.valueMatrix(i, colChk) = "false";
  81. pageInit();
  82. }
  83. function save() {
  84. exec("/root/formData/searchInfo", datagrid1, "save", "/root/gridData/ListResult_0_VO");
  85. pageInit();
  86. }
  87. function remove() {
  88. var datagrid = datagrid1;
  89. if (datagrid.fixedRows == datagrid.rows) {
  90. alert("网格中没有记录!!!");
  91. return;
  92. }
  93. if(commComfirmBox("确定要删除选定行,同时取消对未选定行的删除吗?", "删除确认") == '0') return;
  94. commDelRow(datagrid, "CHK", "", "CUST_CD,PRODNM_CD,ORD_USEAGE_CD", "CHK,DESIGN_SLAB_THK,DESIGN_SLAB_WTH,REP_CONF_WGT");
  95. // 数据网格, 选取项, 删除后可变项, 撤消删除后的只读项, 撤消删除后的须变更单元格颜色的项目
  96. }
  97. ]]>
  98. </script>
  99. </xhtml:head>
  100. <xhtml:body overflow="hidden" pagewidth="980" pageheight="620" style="font-family:宋体; ">
  101. <group id="group1" overflow="hidden" ref="/root/formData/searchInfo" style="left:0px; top:0px; width:980px; height:80px; ">
  102. <line id="line2" style="x1:0px; y1:73px; x2:980px; y2:73px; "/>
  103. <caption id="caption101" class="cell" style="left:0px; top:5px; width:90px; height:20px; ">产品</caption>
  104. <select1 id="combo101" ref="PRODNM_CD" appearance="minimal" style="left:92px; top:5px; width:127px; height:20px; ">
  105. <choices>
  106. <itemset nodeset="/root/codeData/ListResult_0_VO/ListResult_0_Row[LG_CD='A01004' or LG_CD = 'A']">
  107. <label ref="SM_CFNM"/>
  108. <value ref="SM_CD"/>
  109. </itemset>
  110. </choices>
  111. </select1>
  112. <caption id="caption102" class="cell" style="left:229px; top:5px; width:90px; height:20px; ">客户</caption>
  113. <select1 id="combo102" ref="CUST_CD" appearance="minimal" style="left:321px; top:5px; width:127px; height:20px; ">
  114. <choices>
  115. <itemset nodeset="/root/codeData/ListResult_1_VO/ListResult_1_Row">
  116. <label ref="CUST_NM"/>
  117. <value ref="CUST_CD"/>
  118. </itemset>
  119. </choices>
  120. </select1>
  121. <caption id="caption103" class="cell" style="left:458px; top:5px; width:90px; height:20px; ">钢号</caption>
  122. <select1 id="combo103" ref="STL_GRD" appearance="minimal" editmode="search" style="left:550px; top:5px; width:202px; height:20px; ">
  123. <choices>
  124. <itemset nodeset="/root/codeData/ListResult_2_VO/ListResult_2_Row">
  125. <label ref="STL_GRD"/>
  126. <value ref="STL_GRD"/>
  127. </itemset>
  128. </choices>
  129. </select1>
  130. <caption id="caption104" class="cell" style="left:0px; top:27px; width:90px; height:20px; ">合同号</caption>
  131. <input id="input1041" ref="ORD_NO" maxlength="12" style="left:92px; top:27px; width:80px; height:20px; ">
  132. <script type="javascript" ev:event="xforms-value-changed">
  133. <![CDATA[
  134. model.setValue("/root/formData/searchInfo/ORD_SEQ", "");
  135. // if (model.getValue("/root/formData/searchInfo/ORD_NO").length == 12) {
  136. exec("/root/formData/searchInfo/ORD_NO", "", "seq", "/root/codeData/ORD_SEQ/ListResult_0_VO");
  137. model.removenode("/root/reqData");
  138. model.removenode("/root/resData");
  139. // } else {
  140. // model.removenode("/root/codeData/ORD_SEQ/ListResult_0_VO");
  141. // }
  142. model.refresh();
  143. ]]>
  144. </script>
  145. </input>
  146. <select1 id="combo1042" ref="ORD_SEQ" appearance="minimal" style="left:174px; top:27px; width:45px; height:20px; ">
  147. <choices>
  148. <itemset nodeset="/root/codeData/ORD_SEQ/ListResult_0_VO/ListResult_0_Row">
  149. <label ref="ORD_SEQ"/>
  150. <value ref="ORD_SEQ"/>
  151. </itemset>
  152. </choices>
  153. </select1>
  154. <caption id="caption105" class="cell" style="left:229px; top:27px; width:90px; height:20px; ">订货区分</caption>
  155. <select1 id="combo105" ref="RCVORD_CLF" appearance="minimal" style="left:321px; top:27px; width:127px; height:20px; ">
  156. <choices>
  157. <itemset nodeset="/root/codeData/ListResult_0_VO/ListResult_0_Row[LG_CD='A01001' or LG_CD = 'A']">
  158. <label ref="SM_CFNM"/>
  159. <value ref="SM_CD"/>
  160. </itemset>
  161. </choices>
  162. </select1>
  163. <caption id="caption106" class="cell" style="left:458px; top:27px; width:90px; height:20px; ">交货日期</caption>
  164. <input id="input1061" ref="DEL_FR_DATE" inputtype="date" style="left:550px; top:27px; width:100px; height:20px; "/>
  165. <input id="input1062" ref="DEL_TO_DATE" inputtype="date" style="left:652px; top:27px; width:100px; height:20px; "/>
  166. <caption id="caption107" class="cell" style="left:762px; top:27px; width:90px; height:20px; ">订单用途</caption>
  167. <select1 id="combo107" ref="ORD_USEAGE_CD" appearance="minimal" style="left:854px; top:27px; width:110px; height:20px; ">
  168. <choices>
  169. <itemset nodeset="/root/codeData/ListResult_0_VO/ListResult_0_Row[LG_CD='A01007' or LG_CD = 'A']">
  170. <label ref="SM_CFNM"/>
  171. <value ref="SM_CD"/>
  172. </itemset>
  173. </choices>
  174. </select1>
  175. <caption id="caption108" class="cell" style="left:458px; top:49px; width:90px; height:20px; ">标准号</caption>
  176. <select1 id="combo108" ref="SPEC_ABBSYM" appearance="minimal" style="left:550px; top:49px; width:202px; height:20px; ">
  177. <choices>
  178. <itemset nodeset="/root/codeData/ListResult_0_VO/ListResult_0_Row[LG_CD='B01001' or LG_CD = 'A']">
  179. <label ref="SM_CFNM"/>
  180. <value ref="SM_CD"/>
  181. </itemset>
  182. </choices>
  183. </select1>
  184. <caption id="caption109" class="cell" style="left:0px; top:49px; width:90px; height:20px; ">厚度</caption>
  185. <input id="input1091" ref="ORD_THK_MIN" maxlength="6" format="#,###.#" style="left:92px; top:49px; width:62px; height:20px; text-align:right; "/>
  186. <input id="input1092" ref="ORD_THK_MAX" maxlength="6" format="#,###.#" style="left:156px; top:49px; width:63px; height:20px; text-align:right; "/>
  187. <caption id="caption110" class="cell" style="left:229px; top:49px; width:90px; height:20px; ">宽度</caption>
  188. <input id="input1101" ref="ORD_WTH_MIN" maxlength="6" format="#,###.#" style="left:321px; top:49px; width:62px; height:20px; text-align:right; "/>
  189. <input id="input1102" ref="ORD_WTH_MAX" maxlength="6" format="#,###.#" style="left:385px; top:49px; width:63px; height:20px; text-align:right; "/>
  190. <button id="button1" class="sw" style="left:880px; top:5px; width:100px; height:20px; ">
  191. <caption>充当对象订单选择</caption>
  192. <script type="javascript" ev:event="onclick">
  193. <![CDATA[
  194. // NIE031010
  195. exec("/root/formData/searchInfo", "", "select", "/root/gridData/ListResult_0_VO");
  196. if (model.getValue("/root/gridData/ListResult_0_VO/ListResult_0_Row/Allowed") == "False")
  197. alert("JOB管理中对订单充当作了限制,不允许操作!");
  198. else pageInit();
  199. ]]>
  200. </script>
  201. </button>
  202. </group>
  203. <datagrid id="datagrid1" nodeset="/root/gridData/ListResult_0_VO/ListResult_0_Row" backcoloralternate="#F7F9F9" caption="删除选取^合同号^订单号^客户^产品^钢号^标准号^订单用途^是否进保温坑^是否全部取样^订单厚度^订单宽度^订单长度^订单内径^订单外径^订单单重下限^订单单重上限^紧急材^交货期结束^设计板坯厚度^设计板坯宽度^订单重量^交付允许误差最小^交付允许误差最大^充当对象重量^充当确定重量^充当重量^充当余量重量" colsep="^" colwidth="35, 80, 35, 150, 40, 150, 150, 100, 45, 45, 80, 80, 80, 80, 80, 85, 85, 35, 100, 85, 85, 80, 80, 80, 85, 85, 80, 85" explorerbar="sortshow" extendlastcol="false" frozencols="3" mergecellsfixedrows="bycolrec" rowheader="select" rowheight="45" rowsep="|" style="left:0px; top:78px; width:980px; height:542px; ">
  204. <col key="false" ref="CHK" type="checkbox"/>
  205. <col ref="ORD_NO"/>
  206. <col ref="ORD_SEQ"/>
  207. <col key="false" ref="CUST_CD" type="combo" style="text-align:left; ">
  208. <choices>
  209. <itemset nodeset="/root/codeData/ListResult_1_VO/ListResult_1_Row">
  210. <label ref="CUST_NM"/>
  211. <value ref="CUST_CD"/>
  212. </itemset>
  213. </choices>
  214. </col>
  215. <col key="false" ref="PRODNM_CD" type="combo">
  216. <choices>
  217. <itemset nodeset="/root/codeData/ListResult_0_VO/ListResult_0_Row[LG_CD='A01004']">
  218. <label ref="SM_CFNM"/>
  219. <value ref="SM_CD"/>
  220. </itemset>
  221. </choices>
  222. </col>
  223. <col key="false" ref="STL_GRD" style="text-align:left; "/>
  224. <col key="false" ref="SPEC_ABBSYM" style="text-align:left; "/>
  225. <col key="false" ref="ORD_USEAGE_CD" type="combo" style="text-align:left; ">
  226. <choices>
  227. <itemset nodeset="/root/codeData/ListResult_0_VO/ListResult_0_Row[LG_CD='A01007']">
  228. <label ref="SM_CFNM"/>
  229. <value ref="SM_CD"/>
  230. </itemset>
  231. </choices>
  232. </col>
  233. <col key="false" ref="KEEPWARM_YN"/>
  234. <col key="false" ref="EACHLOT_YN"/>
  235. <col key="false" ref="ORD_THK" format="#,###.#" style="text-align:right; "/>
  236. <col key="false" ref="ORD_WTH" format="#,###.#" style="text-align:right; "/>
  237. <col key="false" ref="ORD_LEN" visibility="hidden" format="#,###.#" style="text-align:right; "/>
  238. <col key="false" ref="ORD_INDIA" visibility="hidden" format="#,###.#" style="text-align:right; "/>
  239. <col key="false" ref="ORD_OUTDIA" visibility="hidden" format="#,###.#" style="text-align:right; "/>
  240. <col key="false" ref="ORD_WGT_MIN" format="#,###.#" style="text-align:right; "/>
  241. <col key="false" ref="ORD_WGT_MAX" format="#,###.#" style="text-align:right; "/>
  242. <col key="false" ref="EMGMTR_NMG_CLF"/>
  243. <col key="false" ref="DEL_TO_DATE" format="yyyy-mm-dd"/>
  244. <col ref="DESIGN_SLAB_THK" type="input" visibility="hidden" format="#,###.#" style="text-align:right; "/>
  245. <col ref="DESIGN_SLAB_WTH" type="input" visibility="hidden" format="#,###.#" style="text-align:right; "/>
  246. <col key="false" ref="ORD_WGT" format="#,###.#" style="text-align:right; "/>
  247. <col key="false" ref="WGT_ACVAL_MIN" format="#,###.#" style="text-align:right; "/>
  248. <col key="false" ref="WGT_ACVAL_MAX" format="#,###.#" style="text-align:right; "/>
  249. <col key="false" ref="REP_TOT_WGT" format="#,###.#" style="text-align:right; "/>
  250. <col ref="REP_CONF_WGT" type="input" format="#,###.#" style="text-align:right; "/>
  251. <col key="false" ref="REP_WGT" format="#,###.#" style="text-align:right; "/>
  252. <col ref="REP_REM_WGT" format="(-)#,###.#" style="text-align:right; "/>
  253. <script type="javascript" ev:event="xforms-value-changed">
  254. <![CDATA[
  255. var datagrid = datagrid1;
  256. var colRef = datagrid.colRef("REP_CONF_WGT");
  257. if (datagrid.col != colRef) return;
  258. var row = datagrid.row;
  259. var REP_TOT_WGT = Number(datagrid.valueMatrix(row, datagrid.colRef("REP_TOT_WGT")));
  260. var value = Number(datagrid.valueMatrix(row, colRef));
  261. if (value > REP_TOT_WGT) {
  262. alert("充当确定重量不能大于充当对象重量!");
  263. datagrid.valueMatrix(row, colRef) = REP_TOT_WGT;
  264. } else {
  265. datagrid.valueMatrix(row, datagrid.colRef("REP_REM_WGT")) =
  266. value - Number(datagrid.valueMatrix(row, datagrid.colRef("REP_WGT")));
  267. }
  268. ]]>
  269. </script>
  270. <script type="javascript" ev:event="onentercell">
  271. <![CDATA[
  272. event.pTarget.editCell();
  273. ]]>
  274. </script>
  275. <script type="javascript" ev:event="ondblclick">
  276. <![CDATA[
  277. var datagrid = datagrid1;
  278. window.clipboardData = datagrid.valueMatrix(datagrid.row, datagrid.col);
  279. ]]>
  280. </script>
  281. </datagrid>
  282. </xhtml:body>
  283. </xhtml:html>