| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265 |
- <?xml version="1.0" encoding="UTF-8"?>
- <?xml-stylesheet type="text/css" href="../../css/body.css" ?>
- <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">
- <xhtml:head>
- <xhtml:title>
- <![CDATA[品质设计>>成分参数录入>>替代刚号录入]]>
- </xhtml:title>
- <model id="model1">
- <instance id="instance1">
- <root xmlns="">
- <formData>
- <Radio/>
- <STL_GRD/>
- </formData>
- <datagrid1/>
- <test>
- <updateData/>
- </test>
- <tempData>
- <cellStatus/>
- <MOD_SEQ/>
- <STL_GRD/>
- <MOD_STL_GRD/>
- </tempData>
- <datagrid2/>
- <reqData/>
- <initData>
- <StlGrdResult_Row>
- <LABEL/>
- <VALUE/>
- </StlGrdResult_Row>
- </initData>
- </root>
- </instance>
- <script type="javascript" ev:event="xforms-ready">
- <![CDATA[
- if(window.parent==null) Init();
- ]]>
- </script>
- </model>
- <script type="javascript" src="../../js/boaCommon.js"/>
- <script type="javascript" src="../../js/b01.js"/>
- <script type="javascript">
- <![CDATA[
- function Init(node)
- {
- InitParams(node);
-
- datagrid1.colStatus(1)=false;//忽略第一列值变化(即getUpdatedata方法等不检查第一列的值变化)
-
- // model.makeNode("/root/reqData/STL_GRD");//使其不空,能做初始化操作
- // commSubmit("UIB010060-service", "success", "glueAction.do");//页面初始化
- //注意使用duplicate和copyNode时,节点的方式的区别
- // model.duplicate("/root/initData" , "/root/resData/StlGrdResult_VO");//对下拉列表
- // model.copyNode("/root/datagrid1","/root/resData/ModStlGrdResult_VO");//对表格1
- radio1.select(0);
-
- }
-
- function find()
- {
- if(radio1.value=="")
- {
- window.alert("请选择厂内钢号或标准钢号" , "提示");
- return;
- }
- //按计划钢号进行查询(条件可选)
- model.removenode("/root/reqData");
- model.makeValue("/root/reqData/STL_GRD_YN",radio1.value);//传递下拉框中的计划钢号
- commSubmit("UIB010060-service", "find", "glueAction.do");//按计划刚号查询
- model.copyNode("/root/datagrid1","/root/resData/ModStlGrdResult_VO");
- model.refresh();
- }
-
- function save()
- {
- if(beGridChanged(datagrid1)=="0")//判断表格是否被修改,若无修改则直接返回,不做任何操作
- return;
-
- model.removenode("/root/reqData");
- model.makeNode("/root/reqData");
- commMultiUpdate(datagrid1,"/root/reqData","A",true,"rowStuts");
- model.makeValue("/root/reqData/STL_GRD_YN" , radio1.value);
- commSubmit("UIB010060-service", "save", "glueAction.do");
-
- errMSG = model.getValue("/root/resData/errorData");
- if(errMSG != "")
- {
- window.alert(errMSG," 警告 ");
- return;
- }
-
- datagrid1.clearStatus();
- window.alert("保存成功"," 提示 ");
- }
- ]]>
- </script>
- </xhtml:head>
- <xhtml:body pagewidth="980" pageheight="620" style="font-family:宋体; ">
- <datagrid id="datagrid1" nodeset="/root/datagrid1/ModStlGrdResult_Row" caption="选择^计划钢号^替代钢号1^替代钢号2^替代钢号3^替代钢号4^替代钢号5^替代钢号6^替代钢号7^替代钢号8^替代钢号9^替代钢号10^H计划钢号" colsep="^" colwidth="32, 133, 80, 80, 80, 80, 80, 80, 80, 80, 80, 80, 52" defaultrows="28" explorerbar="sortshow" mergecellsfixedrows="bycolrec" rowheader="seq" rowsep="|" tooltip="label" style="left:0px; top:35px; width:980px; height:585px; border-color:#000000; border-style:solid; ">
- <col checkvalue="Y,N" ref="CHK" type="checkbox"/>
- <col editmode="search" ref="STL_GRD" type="combo" style="left:0px; top:42px; width:90px; height:21px; text-align:left; background-color:#ffff99; ">
- <choices>
- <itemset nodeset="/root/initData/StlGrdResult_Row">
- <label ref="LABEL"/>
- <value ref="VALUE"/>
- </itemset>
- </choices>
- </col>
- <col editmode="search" ref="MOD_STL_GRD1" type="combo" style="background-color:#ffff99; ">
- <choices>
- <itemset nodeset="/root/initData/StlGrdResult_Row">
- <label ref="LABEL"/>
- <value ref="VALUE"/>
- </itemset>
- </choices>
- </col>
- <col editmode="search" ref="MOD_STL_GRD2" type="combo" style="background-color:#ffff99; ">
- <choices>
- <itemset nodeset="/root/initData/StlGrdResult_Row">
- <label ref="LABEL"/>
- <value ref="VALUE"/>
- </itemset>
- </choices>
- </col>
- <col editmode="search" ref="MOD_STL_GRD3" type="combo" style="background-color:#ffff99; ">
- <choices>
- <itemset nodeset="/root/initData/StlGrdResult_Row">
- <label ref="LABEL"/>
- <value ref="VALUE"/>
- </itemset>
- </choices>
- </col>
- <col editmode="search" ref="MOD_STL_GRD4" type="combo" style="background-color:#ffff99; ">
- <choices>
- <itemset nodeset="/root/initData/StlGrdResult_Row">
- <label ref="LABEL"/>
- <value ref="VALUE"/>
- </itemset>
- </choices>
- </col>
- <col editmode="search" ref="MOD_STL_GRD5" type="combo" style="background-color:#ffff99; ">
- <choices>
- <itemset nodeset="/root/initData/StlGrdResult_Row">
- <label ref="LABEL"/>
- <value ref="VALUE"/>
- </itemset>
- </choices>
- </col>
- <col editmode="search" ref="MOD_STL_GRD6" type="combo" style="background-color:#ffff99; ">
- <choices>
- <itemset nodeset="/root/initData/StlGrdResult_Row">
- <label ref="LABEL"/>
- <value ref="VALUE"/>
- </itemset>
- </choices>
- </col>
- <col editmode="search" ref="MOD_STL_GRD7" type="combo" style="background-color:#ffff99; ">
- <choices>
- <itemset nodeset="/root/initData/StlGrdResult_Row">
- <label ref="LABEL"/>
- <value ref="VALUE"/>
- </itemset>
- </choices>
- </col>
- <col editmode="search" ref="MOD_STL_GRD8" type="combo" style="background-color:#ffff99; ">
- <choices>
- <itemset nodeset="/root/initData/StlGrdResult_Row">
- <label ref="LABEL"/>
- <value ref="VALUE"/>
- </itemset>
- </choices>
- </col>
- <col editmode="search" ref="MOD_STL_GRD9" type="combo" style="background-color:#ffff99; ">
- <choices>
- <itemset nodeset="/root/initData/StlGrdResult_Row">
- <label ref="LABEL"/>
- <value ref="VALUE"/>
- </itemset>
- </choices>
- </col>
- <col editmode="search" ref="MOD_STL_GRD10" type="combo" style="background-color:#ffff99; ">
- <choices>
- <itemset nodeset="/root/initData/StlGrdResult_Row">
- <label ref="LABEL"/>
- <value ref="VALUE"/>
- </itemset>
- </choices>
- </col>
- <col ref="STL_GRD1" visibility="hidden"/>
- <script type="javascript" ev:event="onclick">
- <![CDATA[
- datagrid1.editCell();
- ]]>
- </script>
- </datagrid>
- <caption id="caption1" class="cell" style="left:0px; top:5px; width:220px; height:20px; text-align:left; border-color:#000000; border-style:solid; ">钢号区分:</caption>
- <button id="button1" style="left:825px; top:5px; width:70px; height:20px; background-image:../../images/btn_add.gif; ">
- <caption>增加</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- if(radio1.value=="")
- {
- window.alert("请选择厂内钢号或标准钢号" , "提示");
- return;
- }
- datagrid1.addRow();
- ]]>
- </script>
- </button>
- <button id="button2" style="left:900px; top:5px; width:60px; height:20px; background-image:../../images/btn_move.gif; ">
- <caption>删除</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- for(var i=datagrid1.rows; i >= 1 ; i--)
- {
- if(datagrid1.valueMatrix(i , 1)=="Y")
- {
- datagrid1.deleteRow(i , false);
- }
- }
- save();
- ]]>
- </script>
- </button>
- <select1 id="radio1" ref="/root/formData/Radio" appearance="full" cols="2" overflow="visible" style="left:70px; top:5px; width:145px; height:20px; border-style:none; ">
- <choices>
- <item>
- <label>厂内钢号</label>
- <value>F</value>
- </item>
- <item>
- <label>标准钢号</label>
- <value>S</value>
- </item>
- </choices>
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- //若按厂内钢号查询
- for(var i=datagrid1.rows; i>1; i--)
- {
- model.destroy("/root/datagrid1/ModStlGrdResult_Row["+i+"]");
- datagrid1.removeRow(false);
- }
-
- if(radio1.value=="F")
- {
- model.removenode("/root/reqData");
- commSubmit("UIB010060-service", "findFac", "glueAction.do");//页面初始化
- }
- else//按标准钢号查询
- {
- model.removenode("/root/reqData");
- commSubmit("UIB010060-service", "findSpec", "glueAction.do");//页面初始化
- }
- model.copyNode("/root/initData" , "/root/resData/StlGrdResult_VO");
- model.refresh();
- ]]>
- </script>
- </select1>
- <line id="line3" style="x1:0px; y1:0px; x2:980px; y2:0px; "/>
- <line id="line1" style="x1:5px; y1:30px; x2:985px; y2:30px; "/>
- </xhtml:body>
- </xhtml:html>
|