UID010010.xrw 17 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382
  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>Untitle</xhtml:title>
  6. <model id="model1">
  7. <instance id="instance1">
  8. <root xmlns="">
  9. <formData>
  10. <searchInfo/>
  11. <DEVLMT_FR/>
  12. <DEVLMT_TO/>
  13. <PLAN_WGT_FR/>
  14. <PLAN_WGT_TO/>
  15. <DEVLMT_ALL_YN/>
  16. <PLAN_WGT_ALL_YN/>
  17. <PRO_LINE/>
  18. <ETSTDH_SEQ/>
  19. <clear_YN>yes</clear_YN>
  20. </formData>
  21. <reqData/>
  22. <resData/>
  23. <gridData1>
  24. <EmpListResult_VO>
  25. </EmpListResult_VO>
  26. <sendInfo/>
  27. </gridData1>
  28. <gridData2>
  29. <EmpListResult_VO>
  30. </EmpListResult_VO>
  31. </gridData2>
  32. <REC_CNT_SUM/>
  33. <ORD_CNT_SUM/>
  34. <ORD_WGT_SUM/>
  35. </root>
  36. </instance>
  37. <script type="javascript" ev:event="xforms-ready">
  38. <![CDATA[
  39. datagrid1.fixedcellcheckbox(0,datagrid1.colRef("CHK"))=true;
  40. datagrid1.colStatus(0)=false;
  41. datagrid2.fixedcellcheckbox(0,datagrid2.colRef("CHK2"))=true;
  42. datagrid2.colStatus(0)=false;
  43. //caption3.visible = false;
  44. //combo1.visible = false;
  45. model.refresh();
  46. ]]>
  47. </script>
  48. <script type="javascript">
  49. <![CDATA[
  50. //1、获取用户登录信息,只能在页面初始化函数中调用
  51. function InitParams(node)
  52. {
  53. if (typeof node == "undefined" && typeof node != "object") return;
  54. model.removenode("/root/initData/rcvInfo");
  55. model.makeNode("/root/initData/rcvInfo");
  56. var nodeList = node.childNodes;
  57. for (var i = 0; i < nodeList.length; i++)
  58. model.instances(0).selectSingleNode("/root/initData/rcvInfo").appendChild(nodeList.item(i));
  59. }
  60. //2. 页面初始化函数(必须)
  61. function Init(node)
  62. {
  63. InitParams(node); // 用于设置节点:/root/initData/rcvInfo,获取用户登录信息
  64. // 在程序中会重建该节点,最好不要重名
  65. // 函数 InitParams 在 mesCommon.js 中,仅在需要使用登录用户信息时调用
  66. //...
  67. //model.setValue("/root/formData/DEVLMT_FR", commFirstDay());
  68. //model.setValue("/root/formData/DEVLMT_TO", commCurDate());
  69. pageInit();
  70. }
  71. function findCondition()
  72. {
  73. /*----------------初始化查询条件开始---------------------------------------- */
  74. /*commSubmit("UID010010-service","findCondition","glueAction.do"); */
  75. /*----------------初始化查询条件结束---------------------------------------- */
  76. /*----------------初始化设计对象表开始---------------------------------------- */
  77. //var wthGrp = model.getValue("/root/resData/EmpListResult_VO/EmpListResult_Row/COIL_WTH_GAP");
  78. //initDatagrid2(wthGrp);
  79. /*----------------初始化设计对象表开始---------------------------------------- */
  80. /*----------------厂内牌号组初始化开始---------------------------------------- */
  81. model.removenode("/root/reqData");
  82. commSubmit("UID010010-service","findSltedStlGrd","glueAction.do");
  83. errorMessage();
  84. //model.instances
  85. model.copyNode("/root/gridData1/EmpListResult_VO","/root/resData/EmpListResult_VO");
  86. if(model.getValue("/root/resData/EmpListResult0_VO/EmpListResult0_Row/DEVLMT_ALL_YN") == "Y")
  87. {
  88. model.setValue("/root/formData/DEVLMT_ALL_YN",model.getValue("/root/resData/EmpListResult0_VO/EmpListResult0_Row/DEVLMT_ALL_YN"));
  89. input1.disabled = true;
  90. input2.disabled = true;
  91. }
  92. if(model.getValue("/root/resData/EmpListResult0_VO/EmpListResult0_Row/PLAN_WGT_ALL_YN") == "Y")
  93. {
  94. model.setValue("/root/formData/PLAN_WGT_ALL_YN",model.getValue("/root/resData/EmpListResult0_VO/EmpListResult0_Row/PLAN_WGT_ALL_YN"));
  95. input3.disabled = true;
  96. input4.disabled = true;
  97. }
  98. model.setValue("/root/formData/DEVLMT_FR",model.getValue("/root/resData/EmpListResult0_VO/EmpListResult0_Row/DEVLMT_FR"));
  99. model.setValue("/root/formData/DEVLMT_TO",model.getValue("/root/resData/EmpListResult0_VO/EmpListResult0_Row/DEVLMT_TO"));
  100. model.setValue("/root/formData/PLAN_WGT_FR",model.getValue("/root/resData/EmpListResult0_VO/EmpListResult0_Row/PLAN_WGT_FR"));
  101. model.setValue("/root/formData/PLAN_WGT_TO",model.getValue("/root/resData/EmpListResult0_VO/EmpListResult0_Row/PLAN_WGT_TO"));
  102. //model.setValue("/root/formData/COIL_WTH_GAP",model.getValue("/root/resData/EmpListResult0_VO/EmpListResult0_Row/COIL_WTH_GAP"));
  103. model.setValue("/root/formData/ETSTDH_SEQ",model.getValue("/root/resData/EmpListResult0_VO/EmpListResult0_Row/ETSTDH_SEQ"));
  104. /*----------------厂内牌号组初始化结束---------------------------------------- */
  105. model.refresh();
  106. }
  107. function initDatagrid2()
  108. {
  109. model.removenode("/root/reqData");
  110. var devlmtAllYn = model.getValue("/root/formData/DEVLMT_ALL_YN");
  111. var planWgtAllYn = model.getValue("/root/formData/PLAN_WGT_ALL_YN");
  112. //判断选择全部条件的情况
  113. if(devlmtAllYn == "Y")
  114. {
  115. model.makeValue("/root/reqData/DEVLMT_FR","00000000");
  116. model.makeValue("/root/reqData/DEVLMT_TO","99999999");
  117. }
  118. else
  119. {
  120. model.makeValue("/root/reqData/DEVLMT_FR",model.getValue("/root/formData/DEVLMT_FR"));
  121. model.makeValue("/root/reqData/DEVLMT_TO",model.getValue("/root/formData/DEVLMT_TO"));
  122. }
  123. if(planWgtAllYn == "Y")
  124. {
  125. model.makeValue("/root/reqData/PLAN_WGT_FR","0");
  126. model.makeValue("/root/reqData/PLAN_WGT_TO","999999999");
  127. }
  128. else
  129. {
  130. model.makeValue("/root/reqData/PLAN_WGT_FR",model.getValue("/root/formData/PLAN_WGT_FR"));
  131. model.makeValue("/root/reqData/PLAN_WGT_TO",model.getValue("/root/formData/PLAN_WGT_TO"));
  132. }
  133. model.makeValue("/root/reqData/PRO_LINE",model.getValue("/root/formData/PRO_LINE"));//产线
  134. //model.makeValue("/root/reqData/ETSTDH_SEQ",model.getValue("/root/formData/ETSTDH_SEQ"));
  135. commSubmit("UID010010-service","findOrderByCoilWth","glueAction.do");
  136. errorMessage();
  137. var count = model.getXPathValue("count(/root/resData/EmpListResult_VO/EmpListResult_Row)");
  138. for(var i = 1; i <= count; i++)
  139. {
  140. var F_VAL = model.getValue("/root/resData/EmpListResult_VO/EmpListResult_Row["+i+"]/F_VAL");
  141. var T_VAL = model.getValue("/root/resData/EmpListResult_VO/EmpListResult_Row["+i+"]/T_VAL");
  142. var VAL = F_VAL +"~"+ T_VAL;
  143. model.makeValue("/root/resData/EmpListResult_VO/EmpListResult_Row["+i+"]/VAL",VAL)
  144. }
  145. model.copyNode("/root/gridData2/EmpListResult_VO","/root/resData/EmpListResult_VO");
  146. model.setValue("/root/REC_CNT_SUM",model.getXPathValue("sum(/root/gridData2/EmpListResult_VO/EmpListResult_Row/REC_CNT)"));
  147. model.setValue("/root/ORD_CNT_SUM",model.getXPathValue("sum(/root/gridData2/EmpListResult_VO/EmpListResult_Row/ORD_CNT)"));
  148. model.setValue("/root/ORD_WGT_SUM",model.getXPathValue("sum(/root/gridData2/EmpListResult_VO/EmpListResult_Row/ORD_WGT)"));
  149. model.refresh();
  150. }
  151. function pageInit()
  152. {
  153. model.removenode("/root/reqData");
  154. model.removenode("/root/resData");
  155. model.refresh();
  156. }
  157. //3、页面标题
  158. function setTitle()
  159. {
  160. return "工序计划 >> 板坯设计 >> 设计对象订单选定标准/提取"; // 如:return "进程管理 >> 订单进程现况查询";
  161. }
  162. function find()
  163. {
  164. }
  165. ]]>
  166. </script>
  167. </model>
  168. <script type="javascript" src="../../js/boaMsg.js"/>
  169. <script type="javascript" src="../../js/boaCommon.js"/>
  170. <script type="javascript" src="../../js/dCommon.js"/>
  171. </xhtml:head>
  172. <xhtml:body guideline="2,620;1,980;1,470;1,571;1,671;1,771;">
  173. <line id="line3" style="x1:0px; y1:30px; x2:980px; y2:30px; "/>
  174. <line id="line1" style="x1:0px; y1:0px; x2:980px; y2:0px; "/>
  175. <caption id="caption1" class="cell" style="left:0px; top:5px; width:90px; height:20px; ">交货期</caption>
  176. <caption id="caption11" style="left:203px; top:8px; width:20px; height:15px; ">~</caption>
  177. <input id="input1" ref="/root/formData/DEVLMT_TO" editable="false" inputtype="date" style="left:218px; top:5px; width:110px; height:20px; "/>
  178. <input id="input2" ref="/root/formData/DEVLMT_FR" editable="false" inputtype="date" style="left:92px; top:5px; width:110px; height:20px; "/>
  179. <caption id="caption2" style="left:203px; top:40px; width:20px; height:15px; ">~</caption>
  180. <input id="input3" ref="/root/formData/PLAN_WGT_FR" format="999999999" style="left:92px; top:35px; width:108px; height:20px; border-color:#000000; "/>
  181. <input id="input4" ref="/root/formData/PLAN_WGT_TO" format="999999999" style="left:218px; top:35px; width:110px; height:20px; "/>
  182. <caption id="caption8" class="cell" style="left:0px; top:35px; width:90px; height:20px; text-align:center; border-color:#000000; border-style:solid; ">待设计量</caption>
  183. <select id="checkbox1" ref="/root/formData/DEVLMT_ALL_YN" class="cell" overflow="visible" appearance="full" style="left:330px; top:5px; width:50px; height:20px; text-align:center; background-color:#e4ecf5; border-color:#000000; border-style:solid; ">
  184. <choices>
  185. <item>
  186. <label>全部</label>
  187. <value>Y</value>
  188. </item>
  189. </choices>
  190. <script type="javascript" ev:event="xforms-value-changed">
  191. <![CDATA[
  192. if(model.getValue("/root/formData/DEVLMT_ALL_YN") == "Y")
  193. {
  194. input1.disabled = true;
  195. input2.disabled = true;
  196. }
  197. else
  198. {
  199. input1.disabled = false;
  200. input2.disabled = false;
  201. }
  202. ]]>
  203. </script>
  204. </select>
  205. <select id="checkbox2" ref="/root/formData/PLAN_WGT_ALL_YN" class="cell" overflow="visible" appearance="full" style="left:330px; top:35px; width:50px; height:20px; text-align:center; background-color:#e4ecf5; border-color:#000000; border-style:solid; ">
  206. <choices>
  207. <item>
  208. <label>全部</label>
  209. <value>Y</value>
  210. </item>
  211. </choices>
  212. <script type="javascript" ev:event="xforms-value-changed">
  213. <![CDATA[
  214. if(model.getValue("/root/formData/PLAN_WGT_ALL_YN") == "Y")
  215. {
  216. input3.disabled = true;
  217. input4.disabled = true;
  218. }
  219. else
  220. {
  221. input3.disabled = false;
  222. input4.disabled = false;
  223. }
  224. ]]>
  225. </script>
  226. </select>
  227. <caption id="caption3" class="cell" style="left:390px; top:35px; width:60px; height:20px; text-align:center; border-color:#000000; border-style:solid; ">产线</caption>
  228. <select1 id="combo1" ref="/root/formData/PRO_LINE" appearance="minimal" style="left:452px; top:35px; width:103px; height:20px; ">
  229. <choices>
  230. <item>
  231. <label>全部</label>
  232. <value/>
  233. </item>
  234. <item>
  235. <label>热轧</label>
  236. <value>R</value>
  237. </item>
  238. <item>
  239. <label>酸轧</label>
  240. <value>C</value>
  241. </item>
  242. <item>
  243. <label>连退</label>
  244. <value>L</value>
  245. </item>
  246. </choices>
  247. </select1>
  248. <datagrid id="datagrid1" nodeset="/root/gridData1/EmpListResult_VO/EmpListResult_Row" backcoloralternate="#f7f9f9" caption="选择^厂内牌号组^厂内牌号组|选择^组代码^组名称" colsep="^" colwidth="60, 125, 113, 100" defaultrows="30" extendlastcol="false" mergecellsfixedrows="bycolrec" rowsep="|" style="left:0px; top:65px; width:300px; height:555px; ">
  249. <col ref="CHK" type="checkbox"/>
  250. <col ref="SLTED_STL_GRP" style="text-align:left; padding-left:2; "/>
  251. <col ref="SM_CFNM" style="text-align:left; padding-left:2; "/>
  252. <col ref="RN" visibility="hidden"/>
  253. </datagrid>
  254. <datagrid id="datagrid2" nodeset="/root/gridData2/EmpListResult_VO/EmpListResult_Row" backcoloralternate="#f7f9f9" caption="选择^钢卷宽度^设计对象^设计对象^设计对象^交货期^交货期|选择^钢卷宽度^订单数^订单块数^订单量^最早^最晚" colsep="^" colwidth="60, 106, 100, 100, 100, 106, 102, 100" defaultrows="30" mergecellsfixedrows="bycolrec" rowsep="|" style="left:305px; top:65px; width:675px; height:535px; ">
  255. <col ref="CHK2" type="checkbox"/>
  256. <col ref="VAL"/>
  257. <col ref="REC_CNT" format="#,###" style="text-align:right; padding-right:2; "/>
  258. <col ref="ORD_CNT" format="#,###" style="text-align:right; padding-right:2; "/>
  259. <col ref="ORD_WGT" format="#,###" style="text-align:right; padding-right:2; "/>
  260. <col ref="F_DATE" format="yyyy-mm-dd"/>
  261. <col ref="T_DATE" format="yyyy-mm-dd"/>
  262. <col ref="F_VAL" visibility="hidden"/>
  263. <col ref="T_VAL" visibility="hidden"/>
  264. <col ref="MIN_WGT" visibility="hidden"/>
  265. <col ref="MAX_WGT" visibility="hidden"/>
  266. </datagrid>
  267. <line id="line2" style="x1:0px; y1:60px; x2:980px; y2:60px; "/>
  268. <button id="button15" style="left:685px; top:5px; width:70px; height:20px; text-align:right; background-image:../../images/create.gif; ">
  269. <caption>条件查询</caption>
  270. <script type="javascript" ev:event="onclick">
  271. <![CDATA[
  272. findCondition();
  273. ]]>
  274. </script>
  275. </button>
  276. <button id="button5" style="left:835px; top:5px; width:70px; height:20px; text-align:right; background-image:../../images/create.gif; ">
  277. <caption>对象查询</caption>
  278. <script type="javascript" ev:event="onclick">
  279. <![CDATA[
  280. initDatagrid2();
  281. ]]>
  282. </script>
  283. </button>
  284. <button id="button6" style="left:760px; top:5px; width:70px; height:20px; text-align:right; background-image:../../images/create.gif; ">
  285. <caption>条件保存</caption>
  286. <script type="javascript" ev:event="onclick">
  287. <![CDATA[
  288. //条件保存
  289. var count = model.getXPathValue("count(/root/gridData1/EmpListResult_VO/EmpListResult_Row)");
  290. for(var i = 1; i <= count; i++)
  291. {
  292. var CHK = model.getValue("/root/gridData1/EmpListResult_VO/EmpListResult_Row["+i+"]/CHK");
  293. if(CHK == "true")
  294. {
  295. model.makeNode("/root/gridData1/sendInfo");
  296. model.duplicate("/root/gridData1/sendInfo","/root/gridData1/EmpListResult_VO/EmpListResult_Row["+i+"]");
  297. }
  298. }
  299. commSendReq("/root/gridData1/sendInfo");
  300. model.makeValue("/root/reqData/COIL_WTH_GAP",model.getValue("/root/formData/COIL_WTH_GAP"));//钢卷宽度间隔
  301. model.makeValue("/root/reqData/DEVLMT_FR",model.getValue("/root/formData/DEVLMT_FR"));
  302. model.makeValue("/root/reqData/DEVLMT_TO",model.getValue("/root/formData/DEVLMT_TO"));
  303. model.makeValue("/root/reqData/PLAN_WGT_FR",model.getValue("/root/formData/PLAN_WGT_FR"));
  304. model.makeValue("/root/reqData/PLAN_WGT_TO",model.getValue("/root/formData/PLAN_WGT_TO"));
  305. model.makeValue("/root/reqData/DEVLMT_ALL_YN",model.getValue("/root/formData/DEVLMT_ALL_YN"));
  306. model.makeValue("/root/reqData/PLAN_WGT_ALL_YN",model.getValue("/root/formData/PLAN_WGT_ALL_YN"));
  307. model.makeValue("/root/reqData/REGED_BY_CD",model.getValue("/root/initData/rcvInfo/REG_ID"));//录入人
  308. model.makeValue("/root/reqData/CHGED_BY_CD",model.getValue("/root/initData/rcvInfo/REG_ID"));//修改人
  309. commSubmit("UID010010-service","saveSltedStlGrd","glueAction.do");
  310. errorMessage();
  311. model.removenode("/root/gridData1/sendInfo");
  312. model.refresh();
  313. ]]>
  314. </script>
  315. </button>
  316. <button id="button7" style="left:910px; top:5px; width:70px; height:20px; text-align:right; background-image:../../images/create.gif; ">
  317. <caption>对象提取</caption>
  318. <script type="javascript" ev:event="onclick">
  319. <![CDATA[
  320. model.removenode("/root/gridData/sendInfo");
  321. var clear_YN = model.getValue("/root/formData/clear_YN")
  322. var count = model.getXPathValue("count(/root/gridData2/EmpListResult_VO/EmpListResult_Row)");
  323. for(var i = 1; i <= count; i++)
  324. {
  325. var CHK = model.getValue("/root/gridData2/EmpListResult_VO/EmpListResult_Row["+i+"]/CHK2");
  326. if(CHK == "true")
  327. {
  328. model.makeNode("/root/gridData/sendInfo");
  329. model.duplicate("/root/gridData/sendInfo","/root/gridData2/EmpListResult_VO/EmpListResult_Row["+i+"]");
  330. }
  331. }
  332. commSendReq("/root/gridData/sendInfo");
  333. model.makeValue("/root/reqData/clear_YN",clear_YN);
  334. //commSendReq("/root/formData/clear_YN");
  335. commSubmit("UID010010-service","saveOrderDNObj","glueAction.do");
  336. ]]>
  337. </script>
  338. </button>
  339. <caption id="caption22" ref="/root/ORD_CNT_SUM" style="left:571px; top:600px; width:100px; height:20px; text-align:right; border-color:#000000; border-style:solid; "/>
  340. <caption id="caption12" ref="/root/REC_CNT_SUM" style="left:471px; top:600px; width:100px; height:20px; text-align:right; border-color:#000000; border-style:solid; "/>
  341. <caption id="caption7" class="cell" style="left:305px; top:600px; width:85px; height:20px; text-align:center; background-color:#ffcc99; border-color:#000000; border-style:solid; ">统计:</caption>
  342. <caption id="caption4" ref="/root/ORD_WGT_SUM" style="left:671px; top:600px; width:100px; height:20px; text-align:right; border-color:#000000; border-style:solid; "/>
  343. <select id="checkbox3" ref="/root/formData/clear_YN" overflow="visible" appearance="full" style="left:865px; top:35px; width:115px; height:20px; text-align:center; background-color:#e4ecf5; border-color:#000000; border-style:solid; ">
  344. <choices>
  345. <item>
  346. <label>清空前一批计划</label>
  347. <value>yes</value>
  348. </item>
  349. </choices>
  350. </select>
  351. </xhtml:body>
  352. </xhtml:html>