SMANB00800_식품재고관리.xrw 20 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492
  1. <?xml version="1.0" encoding="EUC-KR"?>
  2. <?xml-stylesheet href="../../../com/commonweb/css/common.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>식품재고관리</xhtml:title>
  6. <model id="model1">
  7. <instance id="instance1">
  8. <root xmlns="">
  9. <main>
  10. <foodlist>
  11. <item>
  12. <goodcd/>
  13. <goodnm/>
  14. <purcunit/>
  15. <junil/>
  16. <junilamt/>
  17. <receive/>
  18. <reunitcost/>
  19. <outgo/>
  20. <outunitcost/>
  21. <agomonqty/>
  22. <hyunqty/>
  23. <agoqty/>
  24. <agounitcost/>
  25. <hyunjae/>
  26. <hyunjaeamt/>
  27. <outgomon/>
  28. <rem/>
  29. <stockflag/>
  30. <iodd/>
  31. <pat_emp/>
  32. <magamflag/>
  33. <goodspec/>
  34. </item>
  35. </foodlist>
  36. </main>
  37. <send>
  38. <iodd/>
  39. <pat_emp>P</pat_emp>
  40. <req/>
  41. <stockflag>S</stockflag>
  42. <cnclflag/>
  43. <ricecd/>
  44. </send>
  45. <temp>
  46. <ret>
  47. <retmsg/>
  48. </ret>
  49. </temp>
  50. <init>
  51. <basecode>
  52. <meal>
  53. <A0055>
  54. <cdid/>
  55. <cdnm/>
  56. </A0055>
  57. </meal>
  58. <ward>
  59. <dept>
  60. <deptcd/>
  61. <depthngnm/>
  62. </dept>
  63. </ward>
  64. <aprvrslt>
  65. <A0433>
  66. <cdid/>
  67. <cdnm/>
  68. </A0433>
  69. </aprvrslt>
  70. </basecode>
  71. </init>
  72. </root>
  73. </instance>
  74. <script type="javascript" ev:event="xforms-ready">
  75. <![CDATA[
  76. finit();
  77. var auth_id = getUserInfo("userid");
  78. if ( auth_id == "99262" || auth_id == "99207" ) {
  79. btn_magam.visible = true; //마감버튼 보이도록
  80. btn_magamcncl.visible = true; //마감취소버튼 보이도록
  81. }else {
  82. btn_magam.visible = false; //마감버튼 안보이도록
  83. btn_magamcncl.visible = false; //마감취소버튼 안보이도록
  84. }
  85. // btn_search.disabled = !checkAuth("R");
  86. // btn_save.disabled = !checkAuth("X");
  87. // btn_aprv.disabled = !checkAuth("X");
  88. // btn_excel.disabled = !checkAuth("P");
  89. // btn_updtsum.disabled = !checkAuth("X");
  90. // model.setValue("/root/send/searchitem/instcd", getUserInfo("dutplceinstcd"));
  91. // model.setValue("/root/send/searchitem/userid", getUserInfo("userid"));
  92. //var posdeptcd = getUserInfo("posdeptcd"); //소속부서코드
  93. // var dutplcecd = getUserInfo("dutplcecd"); //소속부서코드
  94. ]]>
  95. </script>
  96. <script type="javascript">
  97. <![CDATA[
  98. function finit() {
  99. var instcd = getUserInfo("dutplceinstcd");
  100. // 화면open시 공통코드 setting
  101. //zbcfGetCodeList( new Array( "A0055", "A0433" ), new Array( "/root/init/basecode/meal", "/root/init/basecode/aprvrslt" ) );
  102. //zbcfGetDeptCodeList( instcd, 'orduseyn', 'W', '/root/init/basecode/ward');
  103. //zsdfGetWardDeptList(instcd, '/root/init/basecode/ward', 'depthngnm', 'asc', new Date().getDateFormat("YYYYMMDD"), 'after');
  104. model.setValue("/root/send/iodd", getCurrentDate());
  105. model.removeNodeset("/root/main/data");
  106. var userid = getUserInfo("userid");
  107. if(userid != "AST"){
  108. grd_data.colAttribute(10,"visibility") = "hidden";
  109. grd_data.colAttribute(11,"visibility") = "hidden";
  110. grd_data.colAttribute(12,"visibility") = "hidden";
  111. grd_data.rebuild();
  112. button1.visible = false;
  113. }
  114. model.refresh();
  115. }
  116. //전월 단가가 다르게 되면 전월재고량 부터 처리후 현재월 단가로 처리한다.
  117. function frealqtycalc() {
  118. var agomonqty = 0; //이월된재고량
  119. var hyunqty = 0; //
  120. var agoqty = 0; //
  121. var agounitcost = 0; //전월단가
  122. var outgo = 0; //출고량
  123. var outgomon = 0; //당월 출고량
  124. var realqty = 0; //이월된 재고량이 남은량
  125. for(var i = 1 ; i <= grd_data.rows-grd_data.fixedRows ; i++ ){
  126. agomonqty = model.getValue("/root/main/foodlist/item[" + i + "]/agomonqty");
  127. outgo = model.getValue("/root/main/foodlist/item[" + i + "]/outgo");
  128. outgomon = model.getValue("/root/main/foodlist/item[" + i + "]/outgomon");
  129. //var goodnm = model.getValue("/root/main/foodlist/item[" + i + "]/goodnm");
  130. //alert(goodnm + "=>"+outgo);
  131. //현재시점 전월재고
  132. realqty = agomonqty - outgomon;
  133. //현재시점 전월재고가 남아 있다면
  134. if(realqty > 0 ){
  135. //전월재고 보다 출고량이 작다면
  136. if(realqty > outgo){
  137. model.setValue("root/main/foodlist/item[" + i + "]/agoqty",outgo);
  138. model.setValue("root/main/foodlist/item[" + i + "]/hyunqty",0);
  139. }else {
  140. model.setValue("root/main/foodlist/item[" + i + "]/agoqty",realqty);
  141. model.setValue("root/main/foodlist/item[" + i + "]/hyunqty",outgo - realqty);
  142. }
  143. }else{
  144. model.setValue("root/main/foodlist/item[" + i + "]/agoqty",0);
  145. model.setValue("root/main/foodlist/item[" + i + "]/hyunqty",outgo);
  146. }
  147. }
  148. model.refresh();
  149. }
  150. ]]>
  151. </script>
  152. <submission id="TRZBC00101"/>
  153. <submission id="TRANB00800" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" resultref="/root/main/foodlist"/>
  154. <submission id="TXANB00801" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" replace="instance" resultref="/root/hidden"/>
  155. <submission id="TXANB00802" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" replace="instance" resultref="/root/hidden"/>
  156. <submission id="TXANB00803" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send" replace="instance" resultref="/root/hidden"/>
  157. </model>
  158. <script type="javascript" src="../../../com/commonweb/js/common.js"/>
  159. <script type="javascript" src="../../../com/commonweb/js/dateHelper.js"/>
  160. <script type="javascript" src="../../../com/commonweb/js/tfHelper.js"/>
  161. <script type="javascript" src="../../../com/basiccodeweb/js/ZBC001.js"/>
  162. <script type="javascript" src="../../../com/departmentcodeweb/js/ZSD001.js"/>
  163. <script type="javascript" src="../../../ast/commonweb/js/AST.js"/>
  164. </xhtml:head>
  165. <xhtml:body guideline="1,1194;2,755;" style="margin-left:8; margin-top:0; margin-right:8; margin-bottom:0; ">
  166. <group id="group1" style="left:0px; top:0px; width:1195px; height:13px; ">
  167. <caption id="caption1" class="tit_1" style="left:0px; top:0px; width:189px; height:14px; ">
  168. <![CDATA[식품재고관리]]>
  169. <script type="javascript" ev:event="onclick">
  170. <![CDATA[
  171. frealqtycalc();
  172. ]]>
  173. </script>
  174. </caption>
  175. </group>
  176. <group id="group3" scroll="auto" style="left:0px; top:13px; width:1195px; height:744px; ">
  177. <group id="group2" style="left:0px; top:10px; width:1194px; height:35px; vertical-align:top; ">
  178. <shape id="roundrect1" appearance="roundrect" ellipsewidth="10" ellipseheight="10" style="left:0px; top:0px; width:1194px; height:35px; background-color:#fffbf2; "/>
  179. <button id="btn_search" class="btn1_letter2" style="left:1122px; top:7px; width:56px; height:22px; ">
  180. <caption>조회</caption>
  181. <script type="javascript" ev:event="DOMActivate">
  182. <![CDATA[
  183. if (submit("TRANB00800")) {
  184. if(model.getValue("/root/main/foodlist/item[1]/stockflag") == "I" ){
  185. for(var i = 1 ; i <= grd_data.rows ; i++ ){
  186. grd_data.addStatus( i ,"insert");
  187. }
  188. }
  189. // 2011.04.22 식품재고 조회시 마감여부 파악해서 버튼 활성화해주기. - cyw
  190. if(model.getValue("/root/main/foodlist/item[1]/magamflag") == "Y" ){
  191. btn_magamcncl.disabled = false;
  192. btn_magam.disabled = true;
  193. }else if(model.getValue("/root/main/foodlist/item[1]/magamflag") == "N" ){
  194. btn_magamcncl.disabled = true;
  195. btn_magam.disabled = false;
  196. }else{
  197. btn_magamcncl.disabled = true;
  198. btn_magam.disabled = true;
  199. }
  200. model.setValue("/root/send/ricecd","");
  201. model.refresh();
  202. }
  203. ]]>
  204. </script>
  205. </button>
  206. <line id="line13" style="x1:1106px; y1:7px; x2:1106px; y2:29px; "/>
  207. <caption id="caption3" class="search_name" style="left:11px; top:8px; width:86px; height:17px; ">재고일자 :</caption>
  208. <input id="ipt_reqfromdd" ref="/root/send/iodd" class="input_s_essential" inputtype="date" style="left:105px; top:7px; width:90px; height:19px; "/>
  209. <caption id="caption4" class="search_name" style="left:291px; top:8px; width:64px; height:17px; ">구분 :</caption>
  210. <select1 id="rdo_diet" ref="/root/send/pat_emp" class="radio_search" appearance="full" cellspacing="2" cols="4" rows="1" overflow="visible" style="left:351px; top:8px; width:134px; height:19px; ">
  211. <choices>
  212. <item>
  213. <label>환자식</label>
  214. <value>P</value>
  215. </item>
  216. <item>
  217. <label>직원식</label>
  218. <value>E</value>
  219. </item>
  220. </choices>
  221. </select1>
  222. <button id="button1" visibility="hidden" style="left:845px; top:5px; width:100px; height:20px; ">
  223. <caption>button1</caption>
  224. <script type="javascript" ev:event="onclick">
  225. <![CDATA[
  226. frealqtycalc();
  227. ]]>
  228. </script>
  229. </button>
  230. </group>
  231. <line id="line1" class="line_1" style="x1:0px; y1:70px; x2:1194px; y2:70px; "/>
  232. <button id="btn_excel" class="btn2_letter2" style="left:1145px; top:49px; width:42px; height:19px; ">
  233. <caption>엑셀</caption>
  234. <script type="javascript" ev:event="DOMActivate">
  235. <![CDATA[
  236. var filename = window.fileDialog("save", ",", false, "식품재고관리", "xls", "Excel Files(*.xls)|*.xls|All Files (*.*)|*.*");
  237. if (filename != "") {
  238. grd_data.saveExcel(filename, "grd_data", true, false, "", "", "");
  239. }
  240. ]]>
  241. </script>
  242. </button>
  243. </group>
  244. <datagrid id="grd_data" nodeset="/root/main/foodlist/item" caption="식품코드^식품명^단위^전일재고^전일재고^입고량^입고량^출고량^출고량^출고단가계산^출고단가계산^출고단가계산^전월단가^현재고량^현재고량^당월출고량^비고^마감^입출고일자^환자직원식^선택^h_등록번호^병동^병실^환자명^처방일자^끼니^수정전^특이사항^수정후^수정요청시간^요청구분^요청횟수^요청자^처리결과^처리담당자^처리시간^보호자식구분^요청취소|식품코드^식품명^단위^총재고^총금액^입고^입고단가^출고^출고단가^전월재고량^당월처리량^전월처리량^전월단가^현재고^현재고금액^당월출고량^비고^마감^입출고일자^환자직원식^선택^h_등록번호^병동^병실^환자명^처방일자^끼니^수정전^특이사항^수정후^수정요청시간^요청구분^요청횟수^요청자^처리결과^처리담당자^처리시간^보호자식구분^요청취소^규격" colsep="^" colwidth="75, 140, 30, 75, 75, 75, 75, 75, 75, 65, 65, 65, 65, 75, 75, 75, 170, 100, 100, 100,100" dataheight="25" explorerbar="sort" mergecellsfixedrows="bycolrec" rowheader="update" rowsep="|" style="left:0px; top:88px; width:1194px; height:665px; text-align:center; ">
  245. <col ref="goodcd"/>
  246. <col ref="goodnm" style="text-align:left; "/>
  247. <col ref="purcunit" style="text-align:right; "/>
  248. <col ref="junil" style="text-align:right; "/>
  249. <col ref="junilamt" style="text-align:right; "/>
  250. <col ref="receive" style="text-align:right; "/>
  251. <col ref="reunitcost" format="#,##0" style="text-align:right; "/>
  252. <col ref="outgo" type="input" style="text-align:right; "/>
  253. <col ref="outunitcost" format="#,##0.#" style="text-align:right; "/>
  254. <col ref="agomonqty" visibility="visible"/>
  255. <col ref="hyunqty" visibility="visible"/>
  256. <col ref="agoqty" visibility="visible"/>
  257. <col ref="agounitcost" visibility="visible"/>
  258. <col ref="hyunjae" style="text-align:right; "/>
  259. <col ref="hyunjaeamt" style="text-align:right; "/>
  260. <col ref="outgomon" style="text-align:right; "/>
  261. <col ref="rem" type="input" style="text-align:left; "/>
  262. <col ref="stockflag" visibility="hidden"/>
  263. <col ref="iodd" visibility="hidden"/>
  264. <col ref="pat_emp" visibility="hidden"/>
  265. <col ref="goodspec" visibility="visible"/>
  266. <script type="javascript" ev:event="ondblclick">
  267. <![CDATA[
  268. //
  269. // for( var i = 0 ; i < grd_data.selectedRows ; i++ ){
  270. // if(grd_data.col == grd_data.colRef("reunitcost") || grd_data.col == grd_data.colRef("outunitcost") ){
  271. // var goodcd = grd_data.valueMatrix(grd_data.row, grd_data.colRef("goodcd"));
  272. // var outunitcost = grd_data.valueMatrix(grd_data.row, grd_data.colRef("outunitcost"));
  273. // if (goodcd == "S01101000"){
  274. // alert("수정가능");
  275. // }else{
  276. // messageBox("백미 이외의 식품코드는 수정할 수", "I004", "");
  277. // if(model.getValue("/root/main/prprtystoc/prprtystoclist[" + grd_prprtystoclist.selectedRow(i) + "]/status") == "1" || model.getValue("/root/main/prprtystoc/prprtystoclist[" + grd_prprtystoclist.selectedRow(i) + "]/status") == "5"){
  278. // grd_data.row
  279. // return;
  280. // model.setValue(
  281. // }
  282. // }
  283. ]]>
  284. </script>
  285. </datagrid>
  286. <group id="group4" scroll="auto" style="left:0px; top:757px; width:1195px; height:27px; ">
  287. <button id="btn_save" class="btn4_letter2" style="left:1077px; top:3px; width:56px; height:22px; ">
  288. <caption>저장</caption>
  289. <script type="javascript" ev:event="DOMActivate">
  290. <![CDATA[
  291. if(model.getValue("/root/main/foodlist/item[1]/magamflag") == "S" ){
  292. messageBox("마감데이터는 수정할수 없습니다.", "I");
  293. }else{
  294. if ( messageBox("식품재고정보를", "Q002") == 6 ) {
  295. //재계산
  296. frealqtycalc();
  297. var update = getGridUpdateData(grd_data);
  298. if (update == "" ) {
  299. messageBox("업데이트 정보가 없습니다.", "I");
  300. }
  301. else {
  302. model.setValue("/root/send/cnclflag", "S");
  303. model.setValue("/root/send/req", update);
  304. submit("TXANB00801");
  305. btn_search.dispatch("DOMActivate");
  306. }
  307. }
  308. }
  309. model.refresh();
  310. ]]>
  311. </script>
  312. </button>
  313. <button id="btn_magam" class="btn4_letter2" style="left:939px; top:3px; width:56px; height:22px; ">
  314. <caption>마감</caption>
  315. <script type="javascript" ev:event="DOMActivate">
  316. <![CDATA[
  317. if(model.getValue("/root/main/foodlist/item[1]/stockflag") == "S" ){
  318. if ( messageBox("마감을", "Q002") == 6 ) {
  319. model.setValue("/root/send/cnclflag", "N");
  320. model.setValue("/root/send/stockflag", "S");
  321. if(submit("TXANB00802")){
  322. btn_search.dispatch("DOMActivate");
  323. }
  324. }
  325. }else{
  326. messageBox("출고되지 않은 데이터는 마감할수 없습니다.", "I");
  327. }
  328. model.refresh();
  329. ]]>
  330. </script>
  331. </button>
  332. <button id="btn_magamcncl" class="btn4_letter4" style="left:996px; top:3px; width:80px; height:22px; ">
  333. <caption>마감취소</caption>
  334. <script type="javascript" ev:event="DOMActivate">
  335. <![CDATA[
  336. // 2011.04.18 cyw 마감취소기능 추가.
  337. if(model.getValue("/root/main/foodlist/item[1]/stockflag") == "S" ){
  338. if ( messageBox("마감취소를", "Q002") == 6 ) {
  339. model.setValue("/root/send/cnclflag", "Y");
  340. model.setValue("root/send/stockflag", "S");
  341. if(submit("TXANB00802")){
  342. btn_search.dispatch("DOMActivate");
  343. }
  344. }
  345. }else{
  346. messageBox("출고되지 않은 데이터는 마감할수 없습니다.", "I");
  347. }
  348. model.refresh();
  349. ]]>
  350. </script>
  351. </button>
  352. <button id="btn_del" class="btn4_letter2" style="left:1134px; top:3px; width:56px; height:22px; ">
  353. <caption>삭제</caption>
  354. <script type="javascript" ev:event="DOMActivate">
  355. <![CDATA[
  356. if(model.getValue("/root/main/foodlist/item[1]/magamflag") == "Y" ){
  357. messageBox("마감취소 후에 삭제 가능합니다.", "I");
  358. }else{
  359. var siodd = model.getValue("/root/main/foodlist/item[1]/iodd");
  360. var spat_emp = model.getValue("/root/main/foodlist/item[1]/pat_emp");
  361. model.setValue("/root/send/iodd", siodd );
  362. model.setValue("/root/send/pat_emp", spat_emp);
  363. if (siodd == "" || spat_emp == ""){
  364. messageBox("삭제할 리스트를 다시 조회하세요.","I");
  365. return;
  366. }
  367. for(var i = 1 ; i <= grd_data.rows ; i++ ){
  368. grd_data.addStatus( i,"delete");
  369. }
  370. var update = getGridUpdateData(grd_data);
  371. if (update == "" ) {
  372. messageBox("업데이트 정보가 없습니다.", "I");
  373. }
  374. else {
  375. model.setValue("/root/send/cnclflag", "S");
  376. model.setValue("/root/send/req", update);
  377. submit("TXANB00801");
  378. messageBox(siodd +"일 재고 삭제가", "I001")
  379. btn_search.dispatch("DOMActivate");
  380. }
  381. }
  382. model.refresh();
  383. ]]>
  384. </script>
  385. </button>
  386. <button id="button3" class="btn6_letter2" style="left:0px; top:3px; width:56px; height:22px; ">
  387. <caption>재고</caption>
  388. <script type="javascript" ev:event="DOMActivate">
  389. <![CDATA[
  390. // 2011.09.14_By 김금련 재고목록 출력기능 추가.
  391. model.removenode("/root/rexprnt/foodlist");
  392. model.makeValue("/root/rexprnt/foodlist/iodd", ipt_reqfromdd.label );
  393. model.makeValue("/root/rexprnt/foodlist/patemp", rdo_diet.label );
  394. var cnt = getNodesetCount("/root/main/foodlist/item");
  395. for( var i = 1; i <= cnt ; i++ ){
  396. model.makeNode("/root/rexprnt/foodlist");
  397. model.makeNode("/root/rexprnt/foodlist/item[" + i + "]");
  398. model.copyNode("/root/rexprnt/foodlist/item[" + i + "]", "/root/main/foodlist/item[" + i + "]");
  399. if( i % 3 == 0 ){
  400. model.makeValue("/root/rexprnt/foodlist/item[" + i + "]/styleflag", "Y");
  401. }else{
  402. model.makeValue("/root/rexprnt/foodlist/item[" + i + "]/styleflag", "N");
  403. }
  404. }
  405. exeReportPreview("RPANB00801", "XMLSTR" , "" , "" , "false" , "", "", "", "", "false");
  406. model.refresh();
  407. ]]>
  408. </script>
  409. </button>
  410. <button id="button2" class="btn6_letter3" style="left:57px; top:3px; width:68px; height:22px; ">
  411. <caption>입·출고</caption>
  412. <script type="javascript" ev:event="DOMActivate">
  413. <![CDATA[
  414. // 2011.04.18 cyw 출력기능 추가.
  415. model.removenode("/root/rexprnt/foodlist");
  416. model.makeValue("/root/rexprnt/foodlist/iodd", ipt_reqfromdd.label );
  417. model.makeValue("/root/rexprnt/foodlist/patemp", rdo_diet.label );
  418. var cnt = getNodesetCount("/root/main/foodlist/item");
  419. for( var i = 1; i <= cnt ; i++ ){
  420. model.makeNode("/root/rexprnt/foodlist");
  421. model.makeNode("/root/rexprnt/foodlist/item[" + i + "]");
  422. model.copyNode("/root/rexprnt/foodlist/item[" + i + "]", "/root/main/foodlist/item[" + i + "]");
  423. if( i % 3 == 0 ){
  424. model.makeValue("/root/rexprnt/foodlist/item[" + i + "]/styleflag", "Y");
  425. }else{
  426. model.makeValue("/root/rexprnt/foodlist/item[" + i + "]/styleflag", "N");
  427. }
  428. }
  429. exeReportPreview("RPANB00802", "XMLSTR" , "" , "" , "false" , "", "", "", "", "false");
  430. model.refresh();
  431. ]]>
  432. </script>
  433. </button>
  434. <input id="ipt_ricecd" ref="/root/send/ricecd" format="#,##0.0" style="left:756px; top:2px; width:105px; height:19px; "/>
  435. <button id="btn_rice" class="btn2_letter4" style="left:866px; top:2px; width:42px; height:19px; ">
  436. <caption>일괄적용</caption>
  437. <script type="javascript" ev:event="DOMActivate">
  438. <![CDATA[
  439. var ricecd = model.getValue("/root/send/ricecd");
  440. if(ricecd != ""){
  441. var btnchk = messageBox("변경된 백미단가를 일괄", "Q009", "");
  442. if(btnchk == "6"){
  443. if(model.getValue("/root/main/foodlist/item[1]/magamflag") == "S" ){
  444. messageBox("마감데이터는 수정할수 없습니다.", "I");
  445. }else{
  446. submit("TXANB00803");
  447. }
  448. }else{
  449. return;
  450. }
  451. // for(var i = 1; i < grd_data.rows ; i++ ){
  452. // var goodcd = model.getValue("/root/main/foodlist/item[" + i + "]/goodcd");
  453. // if(goodcd == "S01101000"){
  454. // model.setValue("/root/main/foodlist/item[" + i + "]/reunitcost",ricecd);
  455. // model.setValue("/root/main/foodlist/item[" + i + "]/outunitcost",ricecd);
  456. // grd_data.addStatus( i+1 ,"update");
  457. // //재계산
  458. // frealqtycalc();
  459. // }
  460. // }
  461. }else{
  462. messageBox("변경된 백미단가를", "C001", "");
  463. model.setFocus("ipt_ricecd");
  464. }
  465. model.refresh();
  466. ]]>
  467. </script>
  468. </button>
  469. </group>
  470. </xhtml:body>
  471. </xhtml:html>