/* ================================================================================================ - File Name : SMPID20600.js - Description : ¸í¼¼¼­°ü¸® - Create : 2008.08.29 ±è»óÁø ================================================================================================== */ /* -------------------------------------------------------------------------------------------------- Fucntion Name || Description ----------------------------------------------------------------------------------------------------- - fInitialize : È­¸é ÃʱâÈ­ -------------------------------------------------------------------------------------------------- */ var gToday = new Date(); var gBaseyear = gToday.getDateFormat("YYYY"); // (dateHelper.js)¿¡¼­ Á¦°øÇÏ´Â ÇÔ¼ö¸¦ »ç¿ëÇÏ¿© ÇØ´ç ³â¸¦ ±¸ÇÑ´Ù. var gBasemonth = gToday.getDateFormat("MM"); var gBaseday = gToday.getDateFormat("DD"); var gCurrentdd = gBaseyear + gBasemonth + gBaseday; var gCurrentym = gBaseyear + gBasemonth; // ----------------------- // ¢º È­¸éÃʱâÈ­ // ----------------------- function fInitialize() { // --------------------------------------------------------------- // °øÅëÄڵ带 Á¶È¸ÇÑ´Ù. // (ZBC001.js) com.ZBCMCODE ¿¡¼­ ±âÃÊÄÚµå °ª Get // --------------------------------------------------------------- zbcfGetCodeList( new Array("P0008" // º¸ÇèÀ¯Çü ,"P0010" // º¸Á¶À¯Çü ,"P0291" // Áø·áºÐ¾ß ,"P0155" // û±¸±¸ºÐ ), new Array("/root/init/P0008list" ,"/root/init/P0010list" ,"/root/init/P0291list" ,"/root/init/P0155list" ) ); /* // --------------------------------------------------------------- // û±¸°ú, ½É»çÀÚ, Áø·á°ú, ÁÖÄ¡ÀÇ, û±¸Â÷¼ö, »ï½ÃÀÚ¼±Åà ÃʱâÈ­ // --------------------------------------------------------------- var clamym = model.getValue("/root/send/item1/clamym"); model.setValue("/root/send/item1/clamym", ""); submit("TRPID20201",false); model.removeNodeset("root/init/judgrid"); model.removeNodeset("root/init/suppkind"); model.removeNodeset("root/init/orddrid"); model.removeNodeset("root/init/clamdept"); model.removeNodeset("root/init/orddeptcd"); model.removeNodeset("root/init/item3"); model.removeNodeset("root/init/clamdg"); model.makeNode("root/init/judgrid"); model.makeNode("root/init/suppkind"); model.makeNode("root/init/orddrid"); model.makeNode("root/init/clamdept"); model.makeNode("root/init/orddeptcd"); model.makeNode("root/init/item3"); model.makeNode("root/init/clamdg"); model.copyNode("root/init/judgrid", "root/init/tmp/judgrid"); model.copyNode("root/init/suppkind", "root/init/tmp/suppkind"); model.copyNode("root/init/orddrid", "root/init/tmp/orddrid"); model.copyNode("root/init/clamdept", "root/init/tmp/clamdept"); model.copyNode("root/init/orddeptcd", "root/init/tmp/orddeptcd"); model.copyNode("root/init/item3", "root/init/tmp/item3"); model.copyNode("root/init/clamdg", "root/init/tmp/clamdg"); model.removeNodeset("root/init/tmp/judgrid"); model.removeNodeset("root/init/tmp/suppkind"); model.removeNodeset("root/init/tmp/orddrid"); model.removeNodeset("root/init/tmp/clamdept"); model.removeNodeset("root/init/tmp/orddeptcd"); model.removeNodeset("root/init/tmp/item3"); model.removeNodeset("root/init/tmp/clamdg"); */ // --------------------------------------------------------------- // Áø·á°ú ÁÖÄ¡ÀÇ ÃʱâÈ­ // --------------------------------------------------------------- submit("TRPID20309", false); model.makeNode("root/hidden/tmp/orddeptcd"); model.makeNode("root/hidden/tmp/orddeptcd2"); model.makeNode("root/hidden/tmp/orddrid"); model.makeNode("root/hidden/tmp/orddrid2"); model.removeNodeset("root/init/orddeptcd"); model.removeNodeset("root/init/orddeptcd2"); model.removeNodeset("root/init/orddrid"); model.removeNodeset("root/init/orddrid2"); model.makeNode("root/init/orddeptcd"); model.makeNode("root/init/orddeptcd2"); model.makeNode("root/init/orddrid"); model.makeNode("root/init/orddrid2"); model.copyNode("root/init/orddeptcd", "root/hidden/tmp/orddeptcd"); model.copyNode("root/init/orddeptcd2", "root/hidden/tmp/orddeptcd2"); model.copyNode("root/init/orddrid", "root/hidden/tmp/orddrid"); model.copyNode("root/init/orddrid2", "root/hidden/tmp/orddrid2"); model.removeNodeset("root/hidden/tmp/orddeptcd"); model.removeNodeset("root/hidden/tmp/orddeptcd2"); model.removeNodeset("root/hidden/tmp/orddrid"); model.removeNodeset("root/hidden/tmp/orddrid2"); model.refreshpart("/root/send/item1/orddeptcd"); model.refreshpart("/root/send/item1/orddeptcd2"); model.refreshpart("/root/send/item1/orddrid"); model.refreshpart("/root/send/item1/orddrid2"); // û±¸¿ù ¼ÂÆÃ if (model.getValue("/root/send/item1/clamym") == "") { var lv_date = gCurrentym.toDate("YYYYMM" + "01"); lv_date = lv_date.getAddDate(-1, "M") gCurrentym = lv_date.getDateFormat("YYYYMM") model.setValue("/root/send/item1/clamym", gCurrentym); } model.refresh(); } // ---------------------------------------------------------------------- // ¢º ¸í¼¼¼­°ü¸® ´ë»óÁ¶È¸ // ---------------------------------------------------------------------- function fGetDocuList() { // ----------------------------------- // ÀÛ¾÷±¸ºÐ¿¡ µû¸¥ ÃʱâÁ¤º¸ ValidCheck // ----------------------------------- var makeflag = model.getValue("/root/send/item1/makeflag"); //ÇÕö, º¹»ç, À̵¿, ÀڰݼöÁ¤, DonorÀ϶§´Â µî·Ï¹øÈ£´Â ÇʼöÀÔ·ÂÁ¶°Ç if (makeflag != "4") { if (model.getValue("/root/send/item1/pid") == "") { messageBox("µî·Ï¹øÈ£´Â", "I003"); ///I003=µî·Ï¹øÈ£´Â ÇʼöÀÔ·ÂÀÔ´Ï´Ù. model.dispatch("ipt_patunitsrch"); return; } } //´ë»óÀÚ Á¶È¸ if (submit("TRPID20601")) { // Ãß°¡Ã»±¸Àϰæ¿ì ÃÖÁ¾Ã»±¸Â÷¼ö °¡Á®¿Â´Ù. fGetMaxClamdg(); var nodeList = instance1.selectNodes("/root/main/list1/clbs"); if (nodeList.length == 1) { model.setValue("/root/main/list1/clbs[1]/fromchk", "Y"); grd_clbsmast.refresh(); grd_clbsmast.row = 1; g_from_cnt = 1; } } } // ---------------------------------------------------------------------- // ¢º ¸í¼¼¼­°ü¸® ÀÚ·á»ý¼º // ---------------------------------------------------------------------- function fSetDocuMake() { // ÀÚ·á»ý¼ºÀü üũ var rslt = fValidcheck(); if (rslt != false) { model.resetInstanceNode("root/send/list1/clbs"); var makeflag = model.getValue("root/send/item1/makeflag"); var fromchk=""; var iCnt=0; // 1. ÇÕö if (makeflag == "1") { for (var i = 1; i < grd_clbsmast.rows; i++) { fromchk = model.getValue("/root/main/list1/clbs[" + i + "]/fromchk"); tochk = model.getValue("/root/main/list1/clbs[" + i + "]/tochk"); if (fromchk == "Y" || tochk == "Y") { iCnt++; model.makeValue("/root/send/list1/clbs[" + iCnt + "]/makeflag", model.getValue("/root/send/item1/makeflag")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/ioflag", model.getValue("/root/send/item1/ioflag")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/fromchk", model.getValue("/root/main/list1/clbs[" + i + "]/fromchk")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/tochk", model.getValue("/root/main/list1/clbs[" + i + "]/tochk")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/clamym", model.getValue("/root/main/list1/clbs[" + i + "]/clamym")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/clamdg", model.getValue("/root/main/list1/clbs[" + i + "]/clamdg")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/pid", model.getValue("/root/main/list1/clbs[" + i + "]/pid")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/pidsn", model.getValue("/root/main/list1/clbs[" + i + "]/pidsn")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/workflag", model.getValue("/root/main/list1/clbs[" + i + "]/workflag")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/clamkey", model.getValue("/root/main/list1/clbs[" + i + "]/clamkey")); } } } // 2:º¹»ç, 3:À̵¿ else if (makeflag == "2" || makeflag == "3") { for (var i = 1; i < grd_clbsmast.rows; i++) { fromchk = model.getValue("/root/main/list1/clbs[" + i + "]/fromchk"); if (fromchk == "Y") { iCnt++; model.makeValue("/root/send/list1/clbs[" + iCnt + "]/makeflag", model.getValue("/root/send/item1/makeflag")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/copyflag", model.getValue("/root/send/item1/copyflag")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/clamym", model.getValue("/root/main/list1/clbs[" + i + "]/clamym")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/clamdg", model.getValue("/root/main/list1/clbs[" + i + "]/clamdg")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/pid", model.getValue("/root/main/list1/clbs[" + i + "]/pid")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/pidsn", model.getValue("/root/main/list1/clbs[" + i + "]/pidsn")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/workflag", model.getValue("/root/main/list1/clbs[" + i + "]/workflag")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/clamkey", model.getValue("/root/main/list1/clbs[" + i + "]/clamkey")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/t_clamym", model.getValue("/root/send/item1/t_clamym")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/t_clamdg", model.getValue("/root/send/item1/t_clamdg")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/t_clamflagcd", model.getValue("/root/send/item1/t_clamflagcd")); } } } // 4:Ãß°¡Ã»±¸ else if (makeflag == "4") { for (var i = 1; i < grd_clbsmast.rows; i++) { fromchk = model.getValue("/root/main/list1/clbs[" + i + "]/fromchk"); if (fromchk == "Y") { iCnt++; model.makeValue("/root/send/list1/clbs[" + iCnt + "]/makeflag", model.getValue("/root/send/item1/makeflag")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/ioflag", model.getValue("/root/send/item1/ioflag")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/clamym", model.getValue("/root/main/list1/clbs[" + i + "]/clamym")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/clamdg", model.getValue("/root/main/list1/clbs[" + i + "]/clamdg")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/pid", model.getValue("/root/main/list1/clbs[" + i + "]/pid")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/pidsn", model.getValue("/root/main/list1/clbs[" + i + "]/pidsn")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/workflag", model.getValue("/root/main/list1/clbs[" + i + "]/workflag")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/clamkey", model.getValue("/root/main/list1/clbs[" + i + "]/clamkey")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/t_clamym", model.getValue("/root/send/item1/t_clamym")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/t_clamdg", model.getValue("/root/send/item1/t_clamdg")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/t_clamflagcd", model.getValue("/root/send/item1/t_clamflagcd")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/acptno", model.getValue("/root/main/list1/clbs[" + i + "]/acptno")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/acptdd", model.getValue("/root/main/list1/clbs[" + i + "]/acptdd")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/docuseqno", model.getValue("/root/main/list1/clbs[" + i + "]/docuseqno")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/adjtresncd", model.getValue("/root/main/list1/clbs[" + i + "]/adjtresncd")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/ms010", model.getValue("/root/send/item1/ms010")); } } } // 5:ÀڰݼöÁ¤ else if (makeflag == "5") { for (var i = 1; i < grd_clbsmast.rows; i++) { fromchk = model.getValue("/root/main/list1/clbs[" + i + "]/fromchk"); if (fromchk == "Y") { iCnt++; model.makeValue("/root/send/list1/clbs[" + iCnt + "]/makeflag", model.getValue("/root/send/item1/makeflag")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/ioflag", model.getValue("/root/send/item1/ioflag")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/clamym", model.getValue("/root/main/list1/clbs[" + i + "]/clamym")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/clamdg", model.getValue("/root/main/list1/clbs[" + i + "]/clamdg")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/pid", model.getValue("/root/main/list1/clbs[" + i + "]/pid")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/pidsn", model.getValue("/root/main/list1/clbs[" + i + "]/pidsn")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/workflag", model.getValue("/root/main/list1/clbs[" + i + "]/workflag")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/clamkey", model.getValue("/root/main/list1/clbs[" + i + "]/clamkey")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/insukind", model.getValue("/root/main/list1/clbs[" + i + "]/insukind")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/suppkind", model.getValue("/root/main/list1/clbs[" + i + "]/suppkind")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/t_clamym", model.getValue("/root/send/item1/t_clamym")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/t_clamdg", model.getValue("/root/send/item1/t_clamdg")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/t_clamflagcd", model.getValue("/root/send/item1/t_clamflagcd")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/t_insukind", model.getValue("/root/main/list1/clbs[" + i + "]/t_insukind")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/t_suppkind", model.getValue("/root/main/list1/clbs[" + i + "]/t_suppkind")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/insuno", model.getValue("/root/main/list1/clbs[" + i + "]/insuno")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/certno", model.getValue("/root/main/list1/clbs[" + i + "]/certno")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/insdnm", model.getValue("/root/main/list1/clbs[" + i + "]/insdnm")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/acddd", model.getValue("/root/main/list1/clbs[" + i + "]/acddd")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/acdacptno", model.getValue("/root/main/list1/clbs[" + i + "]/acdacptno")); model.makeValue("/root/send/list1/clbs[" + iCnt + "]/insucd", model.getValue("/root/main/list1/clbs[" + i + "]/insucd")); } } } // ÀÚ·á»ý¼º... if (submit("TXPID20601")) { // 2:º¹»ç, 3:À̵¿, 4:Ãß°¡Ã»±¸ÀÌ¸é º¯°æµÈ ¸í¼¼¼­¸¦ Á¶È¸ÇÑ´Ù. if (makeflag == "2" || makeflag =="3" || makeflag == "4") { model.setValue("/root/send/item1/clamym", model.getValue("/root/send/item1/t_clamym")); model.setValue("/root/send/item1/clamdg", model.getValue("/root/send/item1/t_clamdg")); // model.setValue("/root/send/item1/clamflagcd", model.getValue("/root/send/item1/t_clamflagcd")); var clamym = model.getValue("/root/send/item1/clamym"); var t_clamym = model.getValue("/root/send/item1/t_clamym"); model.setValue("/root/send/item1/clamdg", model.getValue("/root/send/item1/t_clamdg")); var clamdg = model.getValue("/root/send/item1/t_clamdg"); if (clamym == t_clamym) { addComboItem("cmb_clamdg", clamdg, clamdg, "above"); } else { addComboItem("cmb_clamdg", clamdg, clamdg, "init"); } model.refreshpart("/root/send/item1/clamym"); model.refreshpart("/root/send/item1/clamdg"); // model.refreshpart("/root/send/item1/clamflagcd"); } btn_select.dispatch("DOMActivate"); // ÀÚ·á»ý¼º ÈÄ ¹Ù·Î Á¶È¸... } } } // ---------------------------------------------------------------------- // ¢º ÀÚ·á»ý¼ºÀü üũ // ---------------------------------------------------------------------- function fValidcheck() { var makeflag = model.getValue("root/send/item1/makeflag"); // »ý¼ºÇÒ ¸í¼¼¼­ ¼±ÅõǾú´ÂÁö üũ if (makeflag == "1") { if (g_from_cnt == 0) { messageBox("¼Û½Å(FROM) ¸í¼¼¼­°¡", "I004"); //¼Û½Å(FROM) ¸í¼¼¼­°¡ ¾ø½À´Ï´Ù. return false; } if (g_to_cnt == 0) { messageBox("¼ö½Å(FROM) ¸í¼¼¼­°¡", "I004"); //¼ö½Å(FROM) ¸í¼¼¼­°¡ ¾ø½À´Ï´Ù. return false; } } else { if (g_from_cnt == 0) { messageBox("ÀÚ·á»ý¼ºÇÒ ¸í¼¼¼­°¡", "I004"); //I004: ¾ø½À´Ï´Ù. return false; } } // º¹»çÀÎ °æ¿ì if (makeflag == "2") { var clamym = model.getValue("/root/send/item1/clamym"); var clamdg = model.getValue("/root/send/item1/clamdg"); var clamflagcd = model.getValue("/root/send/item1/clamflagcd"); var t_clamym = model.getValue("/root/send/item1/t_clamym"); var t_clamdg = model.getValue("/root/send/item1/t_clamdg"); var t_clamflagcd = model.getValue("/root/send/item1/t_clamflagcd"); if (t_clamym == "") { messageBox("»ý¼º û±¸³â¿ùÀÌ", "I004"); //I004: ¾ø½À´Ï´Ù. return false; } else if (t_clamdg == "") { messageBox("»ý¼º û±¸Â÷¼ö°¡", "I004"); //I004: ¾ø½À´Ï´Ù. return false; } else if (t_clamflagcd == "") { messageBox("»ý¼º û±¸±¸ºÐÀÌ", "I004"); //I004: ¾ø½À´Ï´Ù. return false; } else if (model.getValue("/root/send/item1/copyflag") == "") { messageBox("»ý¼ºÁ¶°ÇÀÌ", "I004"); //I004: ¾ø½À´Ï´Ù. return false; } else { if ( clamym + clamdg + clamflagcd == t_clamym + t_clamdg + t_clamflagcd ) { messageBox(" »ý¼º û±¸³â¿ù, û±¸Â÷¼ö, û±¸±¸ºÐÁß Çϳªµµ º¯°æµÇÁö", "E007"); //E007=¾Ê¾Ò½À´Ï´Ù. model.setFocus("ipt_toclamym"); return false; } } } // À̵¿ÀÎ °æ¿ì else if (makeflag == "3") { var clamym = model.getValue("/root/send/item1/clamym"); var clamdg = model.getValue("/root/send/item1/clamdg"); var t_clamym = model.getValue("/root/send/item1/t_clamym"); var t_clamdg = model.getValue("/root/send/item1/t_clamdg"); if (t_clamym == "") { messageBox("»ý¼º û±¸³â¿ùÀÌ", "I004"); //I004: ¾ø½À´Ï´Ù. return false; } else if (t_clamdg == "") { messageBox("»ý¼º û±¸Â÷¼ö°¡", "I004"); //I004: ¾ø½À´Ï´Ù. return false; } /* else if (model.getValue("/root/send/item1/t_clamflagcd") == "") { messageBox("»ý¼º û±¸±¸ºÐÀÌ", "I004"); //I004: ¾ø½À´Ï´Ù. } */ else { if ( clamym + clamdg == t_clamym + t_clamdg ) { messageBox(" »ý¼º û±¸³â¿ù ¶Ç´Â û±¸Â÷¼ö°¡ º¯°æµÇÁö", "E007"); //E007=¾Ê¾Ò½À´Ï´Ù. model.setFocus("ipt_toclamym"); return false; } } } // Ãß°¡Ã»±¸ÀÎ °æ¿ì else if (makeflag == "4") { var clamym = model.getValue("/root/send/item1/clamym"); var clamdg = model.getValue("/root/send/item1/clamdg"); var t_clamym = model.getValue("/root/send/item1/t_clamym"); var t_clamdg = model.getValue("/root/send/item1/t_clamdg"); if (t_clamym == "") { messageBox("»ý¼º û±¸³â¿ùÀÌ", "I004"); //I004: ¾ø½À´Ï´Ù. return false; } else if (t_clamdg == "") { messageBox("»ý¼º û±¸Â÷¼ö°¡", "I004"); //I004: ¾ø½À´Ï´Ù. return false; } else { if ( clamym + clamdg == t_clamym + t_clamdg ) { messageBox(" »ý¼º û±¸³â¿ù ¶Ç´Â û±¸Â÷¼ö°¡ º¯°æµÇÁö", "E007"); //E007=¾Ê¾Ò½À´Ï´Ù. model.setFocus("ipt_toclamym"); return false; } } } // ÀڰݼöÁ¤ ÀÎ °æ¿ì else if (makeflag == "5") { var fromchkyn; var insukind; var suppkind; var t_insukind; var t_suppkind; var nodeList = instance1.selectNodes("/root/main/list1/clbs"); for ( i = 1; i <= nodeList.length; i++) { fromchkyn = model.getValue("/root/main/list1/clbs[ " + i + "]/fromchk"); if (fromchkyn == "Y") { insukind = model.getValue("/root/main/list1/clbs[ " + i + "]/insukind"); suppkind = model.getValue("/root/main/list1/clbs[ " + i + "]/suppkind"); t_insukind = model.getValue("/root/main/list1/clbs[ " + i + "]/t_insukind"); t_suppkind = model.getValue("/root/main/list1/clbs[ " + i + "]/t_suppkind"); insuno = model.getValue("/root/main/list1/clbs[ " + i + "]/insuno"); certno = model.getValue("/root/main/list1/clbs[ " + i + "]/certno"); insdnm = model.getValue("/root/main/list1/clbs[ " + i + "]/insdnm"); acddd = model.getValue("/root/main/list1/clbs[ " + i + "]/acddd"); acdacptno = model.getValue("/root/main/list1/clbs[ " + i + "]/acdacptno"); insucd = model.getValue("/root/main/list1/clbs[ " + i + "]/insucd"); if (t_insukind == "") { messageBox("º¯°æ º¸ÇèÀ¯ÇüÀÌ", "I004"); //I004: ¾ø½À´Ï´Ù. return false; } else if (t_suppkind == "") { messageBox("º¯°æ º¸Á¶À¯ÇüÀÌ", "I004"); //I004: ¾ø½À´Ï´Ù. return false; } else { if ( insukind + suppkind == t_insukind + t_suppkind ) { messageBox("º¸ÇèÀ¯Çü ¶Ç´Â º¸Á¶À¯ÇüÀÌ º¯°æµÇÁö", "E007"); //E007=¾Ê¾Ò½À´Ï´Ù. model.setFocus("ipt_toclamym"); return false; } } if (t_insukind == "11" || t_insukind == "21" || t_insukind == "22") { if (insuno == "") { messageBox("»ç¾÷Àå±âÈ£°¡", "I004"); //I004: ¾ø½À´Ï´Ù. return false; } else if (certno == "") { messageBox("Áõ¹øÈ£°¡", "I004"); //I004: ¾ø½À´Ï´Ù. return false; } if (insuno == "") { messageBox("ÇǺ¸ÇèÀÚ°¡", "I004"); //I004: ¾ø½À´Ï´Ù. return false; } } else if (t_insukind == "31") { if (acddd == "") { messageBox("»ç°íÀÏÀÚ°¡", "I004"); //I004: ¾ø½À´Ï´Ù. return false; } else if (acdacptno == "") { messageBox("Á¢¼ö¹øÈ£°¡", "I004"); //I004: ¾ø½À´Ï´Ù. return false; } if (insucd == "") { messageBox("º¸Çèȸ»ç°¡", "I004"); //I004: ¾ø½À´Ï´Ù. return false; } } else if (t_insukind == "41" || t_insukind == "42") { if (acdacptno == "") { messageBox("»êÀç°ü¸®¹øÈ£°¡", "I004"); //I004: ¾ø½À´Ï´Ù. return false; } if (insucd == "") { messageBox("»êÀçÁö»ç°¡", "I004"); //I004: ¾ø½À´Ï´Ù. return false; } } } } } } // ---------------------------------------------------------------------- // ¢º ȯÀÚÁ¶È¸ // ---------------------------------------------------------------------- function fGetSrchPid() { var ipt_pid = model.getValue("/root/send/item1/pid"); if (ipt_pid.charCodeAt(0) > 255) { model.setValue("/root/hidden/sppmc02500/cond/srchcond", "2"); // °Ë»öÁ¶°Ç : ȯÀÚ¸íÀ¸·Î ¼³Á¤ model.setValue("/root/hidden/sppmc02500/cond/hngnm", ipt_pid); } else { model.setValue("/root/hidden/sppmc02500/cond/srchcond", "1"); // °Ë»öÁ¶°Ç : µî·Ï¹øÈ£·Î ¼³Á¤ model.setValue("/root/hidden/sppmc02500/cond/pid", ipt_pid); } // pam/commonweb/xrw/SPPMC02500_ȯÀÚÁ¶È¸.xrw modal("SPPMC02500", "1", "150", "150", "SPPMC02500", "/root/hidden/sppmc02500/cond", "/root/send", "", ""); // SPPMC02500_ȯÀÚÁ¶È¸.xrw var srch_pid = model.getValue("/root/main/patinfo/patinfolist/pid"); if (srch_pid) { // SPPMC02500_ȯÀÚÁ¶È¸ È­¸é¿¡¼­ Á¶È¸ÇÑ °æ¿ìÀÓ model.removeNodeset("/root/main/patinfo/patinfolist"); // patinfolist°¡ Á¦°ÅµÊ (resetInstanceNodeÀÇ °æ¿ì °ªÀº Áö¿ì°í ³ëµå´Â ³²¾ÆÀÖÀ½) model.makeNode("/root/main/patinfo/patinfolist"); // SPPMC02500_ȯÀÚÁ¶È¸ ÆË¾÷À» ´Ù½Ã Á¶È¸ÇÒ °æ¿ì¸¦ À§ÇØ ´Ù½Ã ³ëµå¸¦ Ãß°¡ÇÔ model.setValue("/root/send/item1/pid", srch_pid); } model.refresh(); } // ---------------------------------- // ¢ºÃß°¡Ã»±¸À϶§¸¸ û±¸Â÷¼ö¸¦ Á¶È¸ // ---------------------------------- function fGetClamdg() { var makeflag = model.getValue("/root/send/item1/makeflag"); if (makeflag == "4") { //pidfGetClamdg(); } } // ---------------------------------- // ¢ºÃß°¡Ã»±¸½Ã ±×¸®µå Àüü¼±ÅÃ,ÇØÁ¦ // ---------------------------------- function fChkAll(chkflag) { var i=0; var nodeList = instance1.selectNodes("/root/main/list1/clbs"); g_from_cnt = 0; for ( i = 1; i <= nodeList.length; i++) { if (chkflag == "Y") { model.setValue("/root/main/list1/clbs[" + i + "]/fromchk", "Y"); g_from_cnt++; } else { model.setValue("/root/main/list1/clbs[" + i + "]/fromchk", "N"); } } grd_clbsmast.refresh(); } // ---------------------------------- // ¢ºÃß°¡Ã»±¸½Ã Ãß°¡Ã»±¸ maxÂ÷¼ö Á¶È¸ // ---------------------------------- function fGetMaxClamdg() { var makeflag = model.getValue("/root/send/item1/makeflag"); // "Ãß°¡Ã»±¸"Àϰæ¿ì¿¡´Â ÃÖÁ¾ û±¸Â÷¼ö¸¦ Á¶È¸ÇÑ´Ù. if (makeflag == "4") { model.makeValue("/root/send/item1/clamflag", "2"); if (submit("TRPID20602")) { model.setValue("/root/send/item1/t_clamdg", model.getValue("/root/hidden/item1/maxclamdg")); model.refreshpart("/root/send/item1/t_clamdg"); } } }