123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377 |
- <?xml version="1.0" encoding="EUC-KR"?>
- <?xml-stylesheet href="../../../com/commonweb/css/common.css" type="text/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>SMRPS06300_훈련등록및조회</xhtml:title>
- <model id="model1">
- <instance id="instance1">
- <root xmlns="">
- <main>
- <grid>
- <depttraining/>
- </grid>
- </main>
- <send>
- <search>
- <emplno/>
- <emplnm/>
- <tnemplnm/>
- <adminyn>N</adminyn>
- <tnemplno/>
- <trainingfrom/>
- <trainingto/>
- <useremplno/>
- <tremplno/>
- <trrgstyn/>
- <instcd/>
- </search>
- </send>
- <init>
- <trinerlist>
- <dutteamcd/>
- <emplno/>
- <adminyn/>
- <instcd/>
- </trinerlist>
- </init>
- <temp>
- </temp>
- <deptadmin>
- <emplno/>
- <emplnm/>
- </deptadmin>
- <trainerlist>
- <tremplno/>
- <tremplnm/>
- </trainerlist>
- </root>
- </instance>
- <script type="javascript" ev:event="xforms-ready">
- <![CDATA[
- model.setValue("/root/send/search/useremplno", getUserInfo("userid"));
- submit("TRRPS06000");
- if( model.getValue("/root/init/trinerlist/emplno") != '' ) {
- // user정보조회
- model.setValue("/root/send/search/emplno", getUserInfo("userid"));
- model.setValue("/root/send/search/emplnm", getUserInfo("usernm"));
- model.setValue("/root/send/search/tremplno",ipt_tremplno.value);
- fTraineeList();
- }
- else {
- // user정보조회
- model.setValue("/root/send/search/tnemplno", getUserInfo("userid"));
- model.setValue("/root/send/search/tnemplnm", getUserInfo("usernm"));
- submit("TRRPS06300");
- model.refresh();
- model.setValue("/root/send/search/emplno",model.getValue("/root/trainerlist/tremplno"));
- model.setValue("/root/send/search/emplnm",model.getValue("/root/trainerlist/tremplnm"));
- model.setValue("/root/send/search/instcd",model.getValue("/root/trainerlist/instcd"));
- model.setValue("/root/send/search/tremplno",ipt_tremplno.value);
- model.refresh();
- }
- fCheckAuth(); // 권한 체크해서 구분 flag 값 변경
-
- misfGridInit(grd_depttraining);
- misfMsterDetailSet(grd_depttraining,null, "TRRPS06301" ,"Y");
- model.removenode("/root/main/grid/depttraining");
- grd_depttraining.selectionMode = "byrow";
-
- model.refresh();
- ]]>
- </script>
- <submission id="TRRPS06000" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/search" resultref="/root/init/trinerlist"/>
- <submission id="TRRPS06201" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/search" resultref="/root/deptadmin"/>
- <submission id="TRRPS06300" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/search" resultref="/root/trainerlist"/>
- <submission id="TRRPS06301" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/send/search" resultref="/root/main/grid/depttraining"/>
- <submission id="TXRPS06301" mediatype="application/x-www-form-urlencoded" method="post" ref="/root/main/grid/depttraining" resultref="/root/temp"/>
- </model>
- <script type="javascript" src="../../../com/commonweb/js/common.js"/>
- <script type="javascript" src="../../../com/commonweb/js/dateHelper.js"/>
- <script type="javascript" src="../../../com/commonweb/js/tfHelper.js"/>
- <script type="javascript" src="../../../com/commonweb/js/stringHelper.js"/>
- <script type="javascript" src="../../../mis/miscommonweb/js/MIS.js"/>
- <script type="javascript" src="../../../mis/miscommonweb/js/RSZ001.js"/>
- <script type="javascript" src="../../../mis/educationmngtweb/js/RPS001.js"/>
- <script type="javascript" src="../../../mis/humtrafactmngtweb/js/RPB001.js"/>
- <script type="javascript">
- <![CDATA[
- function fTraineeList() {
- submit("TRRPS06201");
- }
-
- function fCheckAuth() { // 인사팀이면 모든 부분 활성화, 트레이너이면 트레이니 콤보박스로 보여지도록 하고, 트레이니이면 모두 비활성화
- if( model.getValue("/root/init/trinerlist/dutteamcd") == '4020500000' ) {
- ipt_tremplno.disabled = false;
- btn_tremplsearch.disabled = false;
- ipt_tremplnm.disabled = false;
-
- ipt_tnemplnm.visible = false;
- cmb_tnemplnm.visible = true;
-
- ipt_tnemplnm.disabled = false;
- }
- else if ( model.getValue("/root/init/trinerlist/adminyn") == 'N' ) {
- grd_depttraining.colHidden(grd_depttraining.colRef("tremplno")) = true;
- grd_depttraining.colHidden(grd_depttraining.colRef("tremplnm")) = true;
-
- grd_depttraining.colDisabled(grd_depttraining.colRef("trainingdd")) = true;
- grd_depttraining.colDisabled(grd_depttraining.colRef("trainingfromtm")) = true;
- grd_depttraining.colDisabled(grd_depttraining.colRef("trainingtotm")) = true;
- grd_depttraining.colDisabled(grd_depttraining.colRef("trainingplce")) = true;
- grd_depttraining.colDisabled(grd_depttraining.colRef("trainingcnt")) = true;
- grd_depttraining.colDisabled(grd_depttraining.colRef("tnvalu")) = true;
-
- btn_add.disabled = true;
- btn_del.disabled = true;
-
- ipt_tremplno.disabled = true;
- btn_tremplsearch.disabled = true;
- ipt_tremplnm.disabled = true;
-
- cmb_tnemplnm.visible = true;
- }
- else {
- grd_depttraining.colHidden(grd_depttraining.colRef("tnemplno"))= true;
- grd_depttraining.colHidden(grd_depttraining.colRef("tnemplnm"))= true;
- grd_depttraining.colHidden(grd_depttraining.colRef("trvalu"))= true;
- grd_depttraining.colHidden(grd_depttraining.colRef("trrgstyn"))= true;
-
- ipt_tremplno.disabled = true;
- btn_tremplsearch.disabled = true;
- ipt_tremplnm.disabled = true;
-
- ipt_tnemplnm.visible = true;
- cmb_tnemplnm.visible = false;
-
- ipt_tnemplnm.disabled = true;
- }
- model.refresh();
- }
- ]]>
- </script>
- </xhtml:head>
- <xhtml:body style="margin-left:8; margin-right:8; ">
- <group id="group1" style="left:0px; top:0px; width:1195px; height:13px; ">
- <caption id="caption6" class="tit_1" style="left:0px; top:0px; width:800px; height:14px; ">훈련등록 및 조회</caption>
- </group>
- <group id="group2" scroll="auto" style="left:0px; top:38px; width:1195px; height:744px; ">
- <shape id="roundrect1" appearance="roundrect" ellipsewidth="10" ellipseheight="10" style="left:0px; top:10px; width:1195px; height:60px; background-color:#fffbf2; border-color:#ffd799; "/>
- <button id="btn_search" class="btn1_letter2" style="left:1118px; top:30px; width:56px; height:22px; ">
- <caption>조회</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- if(!isRequiredControls("ipt_tremplno")) return;
-
- submit("TRRPS06301");
- ]]>
- </script>
- </button>
- <line id="line13" class="line_4" style="x1:1100px; y1:16px; x2:1100px; y2:64px; "/>
- <line id="line8" class="line_1" style="x1:0px; y1:95px; x2:1195px; y2:95px; "/>
- <caption id="caption20" class="tit_2" style="left:5px; top:81px; width:169px; height:13px; ">훈련내역</caption>
- <button id="btn_del" class="btn2_letter3" style="left:1139px; top:74px; width:53px; height:19px; ">
- <caption>행삭제</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- misfGridIUD(grd_depttraining, "D");
- model.refresh();
- ]]>
- </script>
- </button>
- <button id="btn_add" class="btn2_letter3" style="left:1084px; top:74px; width:53px; height:19px; ">
- <caption>행추가</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- if(!isRequiredControls("ipt_tremplno")) return;
- if(!isRequiredControls("ipt_tnemplno")) return;
-
- grd_depttraining.addRow();
- grd_depttraining.valueMatrix(grd_depttraining.row,grd_depttraining.colRef("tremplno")) = ipt_tremplno.value;
- grd_depttraining.valueMatrix(grd_depttraining.row,grd_depttraining.colRef("tremplnm")) = ipt_tremplnm.value;
- grd_depttraining.valueMatrix(grd_depttraining.row,grd_depttraining.colRef("tnemplno")) = ipt_tnemplno.value;
- grd_depttraining.valueMatrix(grd_depttraining.row,grd_depttraining.colRef("tnemplnm")) = ipt_tnemplnm.value;
- grd_depttraining.valueMatrix(grd_depttraining.row,grd_depttraining.colRef("tryn")) = (model.getValue("/root/init/trinerlist/adminyn")=='N' ? "Y" : "N") ;
- grd_depttraining.valueMatrix(grd_depttraining.row,grd_depttraining.colRef("instcd")) = getUserInfo("dutplceinstcd");
- model.refresh();
- ]]>
- </script>
- </button>
- <datagrid id="grd_depttraining" nodeset="/root/main/grid/depttraining" caption="트레이니^트레이니^훈련일자^Gap(일)^훈련시간^훈련시간^총시간
(분)^훈련장소^훈련내용^평가(트레이니)^등록일시^담당 트레이너^담당 트레이너^평가(트레이너)^등록^등록일시^트레이너여부^기관|트레이니^트레이니^훈련일자^Gap(일)^From^To^총시간
(분)^훈련장소^훈련내용^평가(트레이니)^등록일시^담당 트레이너^담당 트레이너^평가(트레이너)^등록^등록일시^트레이너여부^기관" colsep="^" colwidth="80, 70, 100, 60, 60, 60, 50, 100, 100, 200, 100, 90, 70, 200, 40, 100, 50, 100" mergecellsfixedrows="bycolrec" rowheader="update" rowsep="|" selectionmode="byrow" style="left:0px; top:100px; width:1194px; height:620px; ">
- <col class="input_search" ref="tnemplno" _key="true" style="text-align:center; "/>
- <col class="input_search" ref="tnemplnm" _key="true" style="text-align:center; "/>
- <col class="input_s_essential" ref="trainingdd" type="inputdate" format="yyyy-mm-dd" _key="true" style="text-align:center; "/>
- <col class="input_search" ref="gap" style="text-align:center; "/>
- <col class="input_s_essential" ref="trainingfromtm" type="input" format="hh:nn" style="text-align:center; "/>
- <col class="input_s_essential" ref="trainingtotm" type="input" format="hh:nn" style="text-align:center; "/>
- <col class="input_search" ref="totalmnt" style="text-align:center; "/>
- <col class="input_s_essential" ref="trainingplce" type="input"/>
- <col class="combo_s_essential" ref="trainingcnt" type="combo">
- <choices>
- <itemset>
- <label/>
- <value/>
- </itemset>
- </choices>
- </col>
- <col class="input_s_essential" ref="tnvalu" type="input" maxlength="100" style="text-align:center; "/>
- <col class="input_search" ref="tnrgstdt" format="yyyy-mm-dd hh:nn" style="text-align:center; "/>
- <col class="input_search" ref="tremplno" style="text-align:center; "/>
- <col class="input_search" ref="tremplnm" style="text-align:center; "/>
- <col class="input_essential" ref="trvalu" type="input" maxlength="100" style="text-align:center; "/>
- <col class="input_essential" checkvalue="Y,N" ref="trrgstyn" type="checkbox" style="text-align:center; "/>
- <col class="input_search" ref="trrgstdt" format="yyyy-mm-dd hh:nn" style="text-align:center; "/>
- <col ref="tryn" visibility="hidden"/>
- <col ref="instcd" visibility="hidden"/>
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- var fromtm = grd_depttraining.valueMatrix(grd_depttraining.row, grd_depttraining.colRef("trainingfromtm"));
- var totm = grd_depttraining.valueMatrix(grd_depttraining.row, grd_depttraining.colRef("trainingtotm"));
- var col_tnvalu = grd_depttraining.colRef("tnvalu");
- var col_trvalu = grd_depttraining.colRef("trvalu");
- var col_trainingplce = grd_depttraining.colRef("trainingplce");
- var col_trainingcnt = grd_depttraining.colRef("trainingcnt");
-
- var col_trrgstyn = grd_depttraining.colRef("trrgstyn");
- var col_trainingdd = grd_depttraining.colRef("trainingdd");
-
- var fromdd = grd_depttraining.valueMatrix(grd_depttraining.row-1,grd_depttraining.colRef("trainingdd")) ;
- var todd = grd_depttraining.valueMatrix(grd_depttraining.row,grd_depttraining.colRef("trainingdd"));
-
- if( fromtm != '' && totm != '' ) {
- var totalsec = getTimeInterval(fromtm,totm); // dateHelper.js 에 있는 함수. 시간차이를 초단위로 반환
- grd_depttraining.valueMatrix(grd_depttraining.row, grd_depttraining.colRef("totalmnt")) = parseInt(totalsec / 60);
- }
-
- if ( col_tnvalu == grd_depttraining.col && grd_depttraining.valueMatrix(grd_depttraining.row,grd_depttraining.colRef("tnvalu")) != '' ) {
- grd_depttraining.valueMatrix(grd_depttraining.row, grd_depttraining.colRef("tnrgstdt")) = getCurrentDateTime();
- }
- else if ( col_trainingplce == grd_depttraining.col && grd_depttraining.valueMatrix(grd_depttraining.row,grd_depttraining.colRef("trainingplce")) != '' ) {
- grd_depttraining.valueMatrix(grd_depttraining.row, grd_depttraining.colRef("tnrgstdt")) = getCurrentDateTime();
- }
- else if ( col_trainingcnt == grd_depttraining.col && grd_depttraining.valueMatrix(grd_depttraining.row,grd_depttraining.colRef("trainingcnt")) != '' ) {
- grd_depttraining.valueMatrix(grd_depttraining.row, grd_depttraining.colRef("tnrgstdt")) = getCurrentDateTime();
- }
-
- if ( col_trvalu == grd_depttraining.col && grd_depttraining.valueMatrix(grd_depttraining.row,grd_depttraining.colRef("trvalu")) != '' ) {
- grd_depttraining.valueMatrix(grd_depttraining.row, grd_depttraining.colRef("trrgstdt")) = getCurrentDateTime();
- }
- if( col_trrgstyn == grd_depttraining.col && grd_depttraining.valueMatrix(grd_depttraining.row,grd_depttraining.colRef("trvalu")) == '' ) {
- // 평가를 입력하지 않고 등록만 체크하면 메세지를 띄운다.
- messageBox("평가를 입력해 주세요.","I999");
- grd_depttraining.valueMatrix(grd_depttraining.row,grd_depttraining.colRef("trrgstyn")) = "N" ;
- }
-
- if( col_trainingdd == grd_depttraining.col && grd_depttraining.row > grd_depttraining.fixedRows ) {
- // 이전훈련일자와 현재 훈련일자의 차이를 gap에 넣어준다.
- grd_depttraining.valueMatrix(grd_depttraining.row,grd_depttraining.colRef("gap")) = getDateInterval(fromdd, todd); // dateHelper.js 에 있는 함수. 날짜차이를 보여줌
- }
- model.refresh();
- ]]>
- </script>
- </datagrid>
- <button id="btn_saveexcel" class="btn2_letter4" style="left:1015px; top:74px; width:64px; height:19px; ">
- <caption>엑셀저장</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- misfSaveExcel(grd_depttraining);
- ]]>
- </script>
- </button>
- <input id="input1" ref="/root/send/search/useremplno" navindex="20" visibility="hidden" style="left:445px; top:40px; width:81px; height:19px; text-align:center; "/>
- <caption id="caption1" class="search_name" style="left:565px; top:43px; width:148px; height:17px; ">트레이너 확인여부 :</caption>
- <select1 id="rdo_trrgstyn" ref="/root/send/search/trrgstyn" appearance="full" cellspacing="10" cols="3" overflow="visible" style="left:711px; top:43px; width:275px; height:20px; border-style:none; ">
- <choices>
- <item>
- <label>전체</label>
- <value/>
- </item>
- <item>
- <label>평가 등록전</label>
- <value>N</value>
- </item>
- <item>
- <label>평가 등록완료</label>
- <value>Y</value>
- </item>
- </choices>
- </select1>
- <input id="ipt_trainingfrom" ref="/root/send/search/trainingfrom" class="input_search" inputtype="date" format="yyyy-mm-dd" style="left:713px; top:18px; width:105px; height:19px; text-align:center; ">
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- ]]>
- </script>
- </input>
- <input id="ipt_trainingto" ref="/root/send/search/trainingto" class="input_search" inputtype="date" format="yyyy-mm-dd" style="left:839px; top:18px; width:105px; height:19px; text-align:center; ">
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- ]]>
- </script>
- </input>
- <caption id="caption3" style="left:820px; top:18px; width:18px; height:20px; text-align:center; ">~</caption>
- <caption id="caption2" class="search_name" style="left:565px; top:18px; width:146px; height:17px; ">훈 련 기 간 :</caption>
- <input id="ipt_tnemplnm" ref="/root/send/search/tnemplnm" class="input_s_essential" navindex="21" style="left:314px; top:43px; width:116px; height:19px; text-align:center; "/>
- <input id="ipt_tnemplno" ref="/root/send/search/tnemplno" class="input_s_essential" disabled="true" navindex="20" style="left:196px; top:43px; width:116px; height:19px; text-align:center; "/>
- <select1 id="cmb_tnemplnm" ref="/root/deptadmin" class="combo_s_essential" visibility="hidden" appearance="minimal" style="left:314px; top:43px; width:116px; height:19px; text-align:center; ">
- <choices>
- <itemset nodeset="/root/deptadmin">
- <label ref="emplnm"/>
- <value ref="emplno"/>
- </itemset>
- </choices>
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- model.setValue("/root/send/search/tnemplno",cmb_tnemplnm.value);
- model.setValue("/root/send/search/tnemplnm",cmb_tnemplnm.label);
- model.refresh();
- ]]>
- </script>
- </select1>
- <caption id="cap_tnemplno" class="search_name" style="left:50px; top:43px; width:143px; height:17px; ">트레이니 사원번호 :</caption>
- <input id="ipt_tremplnm" ref="/root/send/search/emplnm" class="input_s_essential" navindex="21" style="left:324px; top:18px; width:106px; height:19px; text-align:center; ">
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- var recv_list = "emplno,emplnm";
- rpbfValidationCheck("tremplno", recv_list);
- model.refresh();
- ]]>
- </script>
- </input>
- <input id="ipt_tremplno" ref="/root/send/search/emplno" class="input_s_essential" navindex="20" style="left:196px; top:18px; width:106px; height:19px; text-align:center; ">
- <script type="javascript" ev:event="xforms-value-changed">
- <![CDATA[
- var recv_list = "emplno,emplnm";
- rpbfValidationCheck("tremplno", recv_list);
- model.refresh();
- ]]>
- </script>
- </input>
- <button id="btn_tremplsearch" class="icon_search" style="left:305px; top:20px; width:16px; height:16px; ">
- <caption/>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- var recv_list = "emplno,emplnm";
- rpbfOpenPopUpList("SPRPB00101", ipt_tremplno, recv_list,"","N","Y");
- model.setValue("/root/send/search/tremplno",ipt_tremplno.value);
- fTraineeList();
- model.refresh();
- ]]>
- </script>
- </button>
- <caption id="cap_tremplno" class="search_name" style="left:50px; top:19px; width:143px; height:17px; ">트레이너 사원번호 :</caption>
- </group>
- <group id="grp_btn" scroll="auto" style="left:0px; top:12px; width:1195px; height:27px; ">
- <button id="btn_save" class="btn4_letter2" style="left:1139px; top:3px; width:56px; height:22px; ">
- <caption>저장</caption>
- <script type="javascript" ev:event="DOMActivate">
- <![CDATA[
- if( checkKeyColumn("grd_depttraining") == false) return;
-
- if(misfSave("TXRPS06301")) {
- btn_search.dispatch("DOMActivate");
- }
- ]]>
- </script>
- </button>
- </group>
- </xhtml:body>
- </xhtml:html>
|