123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684 |
- <?xml version="1.0" encoding="utf-8"?>
- <FDL version="1.5">
- <TypeDefinition url="..\..\..\default_typedef.xml"/>
- <Form id="SMMNB01220" position="absolute 0 0 1110 800" titletext="야간순회보고" oninit="SMMNB01220_oninit" onload="SMMNB01220_onload">
- <Layouts>
- <Layout>
- <Div position="absolute 0 0 1094 13" id="group1"/>
- <Div position="absolute 0 0 1100 765" id="group2">
- <Layouts>
- <Layout>
- <Button position="absolute 960 5 1002 24" id="button16" class="btn2" visible="false" text="축소" onclick="group2_button16_onclick"/>
- <Shape position="absolute 0 25 1094 31" linetype="horizontal" id="line10" class="line_10"/>
- <Grid position="absolute 0 30 1095 760" align="align:center middle;" id="grd_wardlist" binddataset="ds_main_inpt_reptdata_wardlist" selecttype="multiarea">
- <Formats>
- <Format id="default">
- <Columns>
- <Column size="20"/>
- <Column size="0"/>
- <Column size="80"/>
- <Column size="63"/>
- <Column size="0"/>
- <Column size="0"/>
- <Column size="75"/>
- <Column size="556"/>
- <Column size="0"/>
- <Column size="120"/>
- <Column size="62"/>
- <Column size="0"/>
- <Column size="100"/>
- <Column size="0"/>
- <Column size="0"/>
- <Column size="0"/>
- <Column size="0"/>
- <Column size="0"/>
- </Columns>
- <Rows>
- <Row size="24" band="head"/>
- <Row size="22"/>
- </Rows>
- <Band id="head">
- <Cell/>
- <Cell col="1"/>
- <Cell col="2" text="날짜"/>
- <Cell col="3" text="요일"/>
- <Cell col="4" text="caption7"/>
- <Cell col="5" text="caption6"/>
- <Cell col="6" text="작성자"/>
- <Cell col="7" text="내용(부서 - CTRL + ENTER시 다음줄에 기입가능)"/>
- <Cell col="8" text="작성일시"/>
- <Cell col="9" text="작성일시"/>
- <Cell col="10" text="확인자"/>
- <Cell col="11" text="확인자ID"/>
- <Cell col="12" text="확인일시"/>
- <Cell col="13" text="SEQNO"/>
- <Cell col="14" text="caption5"/>
- <Cell col="15" text="caption4"/>
- <Cell col="16" text="caption3"/>
- <Cell col="17" text="caption2"/>
- </Band>
- <Band id="body">
- <Cell celltype="head"/>
- <Cell col="1" class="update_n" text="bind:status"/>
- <Cell col="2" style="background:EXPR(dutflag == 4 ? '#ffd3ff' : dutflag == 8 ? '#ffd3ff' : '');background2:EXPR(dutflag == 4 ? '#ffd3ff' : dutflag == 8 ? '#ffd3ff' : '');color:EXPR(dutflag == 4 ? '#0000ee' : dutflag == 8 ? '#ee0000' : '#000000');color2:EXPR(dutflag == 4 ? '#0000ee' : dutflag == 8 ? '#ee0000' : '#000000');selectbackground:EXPR(dutflag == 4 ? '#ffd3ff' : dutflag == 8 ? '#ffd3ff' : '');selectcolor:EXPR(dutflag == 4 ? '#0000ee' : dutflag == 8 ? '#ee0000' : '#000000');" text="bind:basedd"/>
- <Cell col="3" style="background:EXPR(dutflag == 4 ? '#ffd3ff' : dutflag == 8 ? '#ffd3ff' : '');background2:EXPR(dutflag == 4 ? '#ffd3ff' : dutflag == 8 ? '#ffd3ff' : '');color:EXPR(dutflag == 4 ? '#0000ee' : dutflag == 8 ? '#ee0000' : '#000000');color2:EXPR(dutflag == 4 ? '#0000ee' : dutflag == 8 ? '#ee0000' : '#000000');selectbackground:EXPR(dutflag == 4 ? '#ffd3ff' : dutflag == 8 ? '#ffd3ff' : '');selectcolor:EXPR(dutflag == 4 ? '#0000ee' : dutflag == 8 ? '#ee0000' : '#000000');" text="bind:holinm"/>
- <Cell col="4" style="background:EXPR(dutflag == 4 ? '#ffd3ff' : dutflag == 8 ? '#ffd3ff' : '');background2:EXPR(dutflag == 4 ? '#ffd3ff' : dutflag == 8 ? '#ffd3ff' : '');color:EXPR(dutflag == 4 ? '#0000ee' : dutflag == 8 ? '#ee0000' : '#000000');color2:EXPR(dutflag == 4 ? '#0000ee' : dutflag == 8 ? '#ee0000' : '#000000');selectbackground:EXPR(dutflag == 4 ? '#ffd3ff' : dutflag == 8 ? '#ffd3ff' : '');selectcolor:EXPR(dutflag == 4 ? '#0000ee' : dutflag == 8 ? '#ee0000' : '#000000');" text="bind:dutflag"/>
- <Cell col="5" style="background:EXPR(dutflag == 4 ? '#ffd3ff' : dutflag == 8 ? '#ffd3ff' : '');background2:EXPR(dutflag == 4 ? '#ffd3ff' : dutflag == 8 ? '#ffd3ff' : '');color:EXPR(dutflag == 4 ? '#0000ee' : dutflag == 8 ? '#ee0000' : '#000000');color2:EXPR(dutflag == 4 ? '#0000ee' : dutflag == 8 ? '#ee0000' : '#000000');selectbackground:EXPR(dutflag == 4 ? '#ffd3ff' : dutflag == 8 ? '#ffd3ff' : '');selectcolor:EXPR(dutflag == 4 ? '#0000ee' : dutflag == 8 ? '#ee0000' : '#000000');" text="bind:holiflag"/>
- <Cell col="6" style="background:EXPR(dutflag == 4 ? '#ffd3ff' : dutflag == 8 ? '#ffd3ff' : '');background2:EXPR(dutflag == 4 ? '#ffd3ff' : dutflag == 8 ? '#ffd3ff' : '');color:EXPR(dutflag == 4 ? '#0000ee' : dutflag == 8 ? '#ee0000' : '#000000');color2:EXPR(dutflag == 4 ? '#0000ee' : dutflag == 8 ? '#ee0000' : '#000000');selectbackground:EXPR(dutflag == 4 ? '#ffd3ff' : dutflag == 8 ? '#ffd3ff' : '');selectcolor:EXPR(dutflag == 4 ? '#0000ee' : dutflag == 8 ? '#ee0000' : '#000000');" text="bind:usernm"/>
- <Cell col="7" displaytype="text" edittype="text" style="background:EXPR(dutflag == 4 ? '#ffd3ff' : dutflag == 8 ? '#ffd3ff' : '');background2:EXPR(dutflag == 4 ? '#ffd3ff' : dutflag == 8 ? '#ffd3ff' : '');color:EXPR(dutflag == 4 ? '#0000ee' : dutflag == 8 ? '#ee0000' : '#000000');color2:EXPR(dutflag == 4 ? '#0000ee' : dutflag == 8 ? '#ee0000' : '#000000');selectbackground:EXPR(dutflag == 4 ? '#ffd3ff' : dutflag == 8 ? '#ffd3ff' : '');selectcolor:EXPR(dutflag == 4 ? '#0000ee' : dutflag == 8 ? '#ee0000' : '#000000');" text="bind:delivecnts"/>
- <Cell col="8" style="background:EXPR(dutflag == 4 ? '#ffd3ff' : dutflag == 8 ? '#ffd3ff' : '');background2:EXPR(dutflag == 4 ? '#ffd3ff' : dutflag == 8 ? '#ffd3ff' : '');color:EXPR(dutflag == 4 ? '#0000ee' : dutflag == 8 ? '#ee0000' : '#000000');color2:EXPR(dutflag == 4 ? '#0000ee' : dutflag == 8 ? '#ee0000' : '#000000');selectbackground:EXPR(dutflag == 4 ? '#ffd3ff' : dutflag == 8 ? '#ffd3ff' : '');selectcolor:EXPR(dutflag == 4 ? '#0000ee' : dutflag == 8 ? '#ee0000' : '#000000');" text="bind:plandd" mask="yyyy-mm-dd"/>
- <Cell col="9" displaytype="text" edittype="text" style="align:center;background:EXPR(dutflag == 4 ? '#ffd3ff' : dutflag == 8 ? '#ffd3ff' : '');background2:EXPR(dutflag == 4 ? '#ffd3ff' : dutflag == 8 ? '#ffd3ff' : '');color:EXPR(dutflag == 4 ? '#0000ee' : dutflag == 8 ? '#ee0000' : '#000000');color2:EXPR(dutflag == 4 ? '#0000ee' : dutflag == 8 ? '#ee0000' : '#000000');selectbackground:EXPR(dutflag == 4 ? '#ffd3ff' : dutflag == 8 ? '#ffd3ff' : '');selectcolor:EXPR(dutflag == 4 ? '#0000ee' : dutflag == 8 ? '#ee0000' : '#000000');" text="bind:plandt" mask="expr:utlf_isNull(plandt) ? '' : '####-##-## ##:##'" editlimit="12" editautoselect="true" editlimitbymask="integer"/>
- <Cell col="10" style="background:EXPR(dutflag == 4 ? '#ffd3ff' : dutflag == 8 ? '#ffd3ff' : '');background2:EXPR(dutflag == 4 ? '#ffd3ff' : dutflag == 8 ? '#ffd3ff' : '');color:EXPR(dutflag == 4 ? '#0000ee' : dutflag == 8 ? '#ee0000' : '#000000');color2:EXPR(dutflag == 4 ? '#0000ee' : dutflag == 8 ? '#ee0000' : '#000000');selectbackground:EXPR(dutflag == 4 ? '#ffd3ff' : dutflag == 8 ? '#ffd3ff' : '');selectcolor:EXPR(dutflag == 4 ? '#0000ee' : dutflag == 8 ? '#ee0000' : '#000000');" text="bind:certnm"/>
- <Cell col="11" style="background:EXPR(dutflag == 4 ? '#ffd3ff' : dutflag == 8 ? '#ffd3ff' : '');background2:EXPR(dutflag == 4 ? '#ffd3ff' : dutflag == 8 ? '#ffd3ff' : '');color:EXPR(dutflag == 4 ? '#0000ee' : dutflag == 8 ? '#ee0000' : '#000000');color2:EXPR(dutflag == 4 ? '#0000ee' : dutflag == 8 ? '#ee0000' : '#000000');selectbackground:EXPR(dutflag == 4 ? '#ffd3ff' : dutflag == 8 ? '#ffd3ff' : '');selectcolor:EXPR(dutflag == 4 ? '#0000ee' : dutflag == 8 ? '#ee0000' : '#000000');" text="bind:certid"/>
- <Cell col="12" style="align:center;background:EXPR(dutflag == 4 ? '#ffd3ff' : dutflag == 8 ? '#ffd3ff' : '');background2:EXPR(dutflag == 4 ? '#ffd3ff' : dutflag == 8 ? '#ffd3ff' : '');color:EXPR(dutflag == 4 ? '#0000ee' : dutflag == 8 ? '#ee0000' : '#000000');color2:EXPR(dutflag == 4 ? '#0000ee' : dutflag == 8 ? '#ee0000' : '#000000');selectbackground:EXPR(dutflag == 4 ? '#ffd3ff' : dutflag == 8 ? '#ffd3ff' : '');selectcolor:EXPR(dutflag == 4 ? '#0000ee' : dutflag == 8 ? '#ee0000' : '#000000');" text="bind:certdt" mask="expr:utlf_isNull(certdt) ? '' : '####-##-## ##:##'"/>
- <Cell col="13" text="bind:seqno"/>
- <Cell col="14" text="bind:wardcd"/>
- <Cell col="15" text="bind:deliveflagcd"/>
- <Cell col="16" text="bind:staiud"/>
- <Cell col="17" text="bind:userid"/>
- </Band>
- </Format>
- </Formats>
- </Grid>
- <Button position="absolute 865 5 918 24" id="button10" class="btn2" visible="false" text="행추가" onclick="group2_button10_onclick"/>
- <Button position="absolute 978 3 1034 25" id="button22" class="btn4" text="삭제" onclick="group2_button22_onclick"/>
- <Static text="야간순회보고" position="absolute 0 9 115 25" id="caption17" class="tit_2"/>
- <Button position="absolute 1035 3 1091 25" id="button23" class="btn4" text="저장" onclick="group2_button23_onclick"/>
- <Button position="absolute 915 5 957 24" id="button14" class="btn2" visible="false" text="확대" onclick="group2_button14_onclick"/>
- <Button position="absolute 864 3 920 25" id="btn_srch2" class="btn1" taborder="5" text="조회" onclick="group2_btn_srch2_onclick"/>
- <Static text="보고일자 :" position="absolute 670 7 746 24" id="caption21" class="search_name"/>
- <Calendar position="absolute 745 5 845 24" id="ipt_orddd2" class="input_default" taborder="1" onchanged="group2_ipt_orddd2_onchanged"/>
- <Button position="absolute 921 3 977 25" id="btn_excel2" class="btn7" text="엑셀" onclick="group2_btn_excel2_onclick"/>
- </Layout>
- </Layouts>
- </Div>
- <Button position="absolute 870 768 912 787" id="btn_cert" class="btn2" text="확인" onclick="btn_cert_onclick"/>
- <MaskEdit readonly="true" position="absolute 978 768 1078 787" align="align:center middle;" id="opt_certdt" mask="####-##-## ##:##" maskchar=" " displaynulltext=" " style="padding:0 2 0 2;align:center middle;" type="string"/>
- <Edit readonly="true" position="absolute 915 768 975 787" align="align:center middle;" id="opt_certnm" class="output" style="align:center middle;"/>
- </Layout>
- </Layouts>
- <Objects>
- <Dataset id="ds_send_reqdata" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
- <ColumnInfo>
- <Column id="wardcd" type="STRING" size="256" sumtext="병동코드"/>
- <Column id="authallyn" type="STRING" size="256" sumtext="전부서조회"/>
- <Column id="plandd" type="STRING" size="256" sumtext="계획일자"/>
- <Column id="seqno" type="STRING" size="256" sumtext="시퀀스"/>
- <Column id="duty" type="STRING" size="256" sumtext="todo"/>
- <Column id="deptflag" type="STRING" size="256" sumtext="todo"/>
- <Column id="deliveflagcd" type="STRING" size="256" sumtext="검색구분"/>
- </ColumnInfo>
- <Rows>
- <Row/>
- </Rows>
- </Dataset>
- <Dataset id="ds_main_inpt_reptdata_wardlist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false" oncolumnchanged="ds_main_inpt_reptdata_wardlist_oncolumnchanged">
- <ColumnInfo>
- <Column id="basedd" type="STRING" size="256" sumtext="일자"/>
- <Column id="holinm" type="STRING" size="256" sumtext="요일/공휴일"/>
- <Column id="dutflag" type="STRING" size="256" sumtext="근무구분"/>
- <Column id="holiflag" type="STRING" size="256" sumtext="휴일구분"/>
- <Column id="wardcd" type="STRING" size="256" sumtext="병동코드"/>
- <Column id="plandd" type="STRING" size="256" sumtext="계획일자"/>
- <Column id="plandt" type="STRING" size="256" sumtext="계획시간"/>
- <Column id="delivecnts" type="STRING" size="256" sumtext="내용"/>
- <Column id="deliveflagcd" type="STRING" size="256" sumtext="전달구분"/>
- <Column id="seqno" type="STRING" size="256" sumtext="시퀀스"/>
- <Column id="usernm" type="STRING" size="256" sumtext="작성자"/>
- <Column id="duty" type="STRING" size="256" sumtext="todo"/>
- <Column id="certnm" type="STRING" size="256" sumtext="확인자"/>
- <Column id="certid" type="STRING" size="256" sumtext="확인자id"/>
- <Column id="certdt" type="STRING" size="256" sumtext="확인일시"/>
- <Column id="status" type="STRING" size="256" sumtext="status"/>
- <Column id="staiud" type="STRING" size="256" sumtext="상태"/>
- <Column id="userid" type="STRING" size="256" sumtext="작성자id"/>
- <Column id="posdeptnm" type="STRING" size="256" sumtext="근무지nm"/>
- <Column id="certyn" type="STRING" size="256" sumtext="확인여부"/>
- <Column id="dutynm" type="STRING" size="256" sumtext="확인여부"/>
- </ColumnInfo>
- </Dataset>
- <Dataset id="ds_send_sReptPath" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
- <ColumnInfo>
- <Column id="basedd" type="STRING" size="256" sumtext="일자"/>
- <Column id="holinm" type="STRING" size="256" sumtext="요일/공휴일"/>
- <Column id="dutflag" type="STRING" size="256" sumtext="근무구분"/>
- <Column id="holiflag" type="STRING" size="256" sumtext="휴일구분"/>
- <Column id="wardcd" type="STRING" size="256" sumtext="병동코드"/>
- <Column id="plandd" type="STRING" size="256" sumtext="계획일자"/>
- <Column id="plandt" type="STRING" size="256" sumtext="계획시간"/>
- <Column id="delivecnts" type="STRING" size="256" sumtext="내용"/>
- <Column id="deliveflagcd" type="STRING" size="256" sumtext="전달구분"/>
- <Column id="seqno" type="STRING" size="256" sumtext="시퀀스"/>
- <Column id="usernm" type="STRING" size="256" sumtext="작성자"/>
- <Column id="duty" type="STRING" size="256" sumtext="todo"/>
- <Column id="certnm" type="STRING" size="256" sumtext="확인자"/>
- <Column id="certid" type="STRING" size="256" sumtext="확인자id"/>
- <Column id="certdt" type="STRING" size="256" sumtext="확인일시"/>
- <Column id="status" type="STRING" size="256" sumtext="status"/>
- <Column id="staiud" type="STRING" size="256" sumtext="상태"/>
- <Column id="userid" type="STRING" size="256" sumtext="작성자id"/>
- <Column id="posdeptnm" type="STRING" size="256" sumtext="근무지nm"/>
- <Column id="certyn" type="STRING" size="256" sumtext="확인여부"/>
- <Column id="dutynm" type="STRING" size="256" sumtext="확인여부"/>
- </ColumnInfo>
- </Dataset>
- <Dataset id="ds_temp" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
- <ColumnInfo>
- <Column id="srchdd2" type="STRING" size="256"/>
- <Column id="duty" type="STRING" size="256"/>
- <Column id="deptflag" type="STRING" size="256"/>
- <Column id="certnm" type="STRING" size="256"/>
- <Column id="certdt" type="STRING" size="256"/>
- <Column id="recdd" type="STRING" size="256"/>
- <Column id="deptcd" type="STRING" size="256"/>
- </ColumnInfo>
- <Rows>
- <Row/>
- </Rows>
- </Dataset>
- <Dataset id="ds_codelist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" reversesubsum="false">
- <ColumnInfo>
- <Column id="cdnm" type="STRING"/>
- <Column id="cdid" type="STRING"/>
- </ColumnInfo>
- </Dataset>
- <Dataset id="ds_send" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
- <ColumnInfo>
- <Column id="wardcd" type="STRING" size="256" sumtext="병동코드"/>
- <Column id="authallyn" type="STRING" size="256" sumtext="전부서조회"/>
- <Column id="plandd" type="STRING" size="256" sumtext="보고일자"/>
- <Column id="instcd" type="STRING" size="256" sumtext="보고일자"/>
- <Column id="seqno" type="STRING" size="256" sumtext="시퀀스"/>
- <Column id="duty" type="STRING" size="256" sumtext="todo"/>
- <Column id="deptflag" type="STRING" size="256" sumtext="todo"/>
- <Column id="orddd" type="STRING" size="256" sumtext="보고일자"/>
- <Column id="fromdd" type="STRING" size="256" sumtext="보고일자"/>
- <Column id="todd" type="STRING" size="256" sumtext="보고일자"/>
- <Column id="deliveflagcd" type="STRING" size="256"/>
- <Column id="plandt" type="STRING" size="256"/>
- <Column id="delivecnts" type="STRING" size="256"/>
- <Column id="staiud" type="STRING" size="256"/>
- <Column id="deptflg" type="STRING" size="256"/>
- <Column id="filepath" type="STRING" size="256"/>
- </ColumnInfo>
- <Rows>
- <Row/>
- </Rows>
- </Dataset>
- </Objects>
- <Bind>
- <BindItem id="item0" compid="group2.ipt_orddd2" propid="value" datasetid="ds_temp" columnid="srchdd2"/>
- <BindItem id="item1" compid="opt_certnm" propid="value" datasetid="ds_temp" columnid="certnm"/>
- <BindItem id="item2" compid="opt_certdt" propid="value" datasetid="ds_temp" columnid="certdt"/>
- </Bind>
- <Script type="xscript4.0"><![CDATA[/***************************************************************************************
- * System Name : 경대 의료정보시스템
- * Job Name : emr_wardcarexp -> SMMNB01220
- * Creator : yjh
- * Make Date : 2016-11-17
- * Description :
- *---------------------------------------------------------------------------------------
- * Modify Date Modifier Modify Description
- *---------------------------------------------------------------------------------------
- * 2016-11-17 yjh TF->XP
- *
- *---------------------------------------------------------------------------------------
- ****************************************************************************************/
- //=======================================================================================
- // Lib Include
- //---------------------------------------------------------------------------------------
- include "com_commonxp::comm_main.xjs";
- include "emr_carecomxp::CareCom.xjs";
- //=======================================================================================
- // Global Form Variable
- //---------------------------------------------------------------------------------------
- var authflag = "";
- var arErrorCode = new HashArray();
- //=======================================================================================
- // Function
- //---------------------------------------------------------------------------------------
- // 본원 야간 순회보고 저장
- function fSave_Reptrows2(){
-
- if(sysf_messageBox("","Q002") != 6) return;
-
- ds_send_sReptPath.clearData();
-
- for( var i=0 ; i<ds_main_inpt_reptdata_wardlist.rowcount ; i++ ){
- if( ds_main_inpt_reptdata_wardlist.getRowType(i) == 2 || ds_main_inpt_reptdata_wardlist.getRowType(i) == 4 || ds_main_inpt_reptdata_wardlist.getRowType(i) == 8 ){
- var nRow = ds_send_sReptPath.addRow();
- ds_send_sReptPath.copyRow(nRow, ds_main_inpt_reptdata_wardlist, i);
- }
- }
-
- if(utlf_isNull(ds_send_sReptPath) || ds_send_sReptPath.rowcount == 0){
- sysf_messageBox("저장할 자료가 존재하지 않습니다.","I");
- return;
- }
-
- var oParam = {};
- oParam.id = "TXMNB01204";
- oParam.service = "wardcareapp.WardBizMngt";
- oParam.method = "reqExeSetNightReport";
- oParam.inds = "reqExeSetRept=ds_send_sReptPath";
- oParam.outds = "";
- oParam.async = false;
- //oParam.callback = "cf_TXMNB01204";
- tranf_submit(oParam);
-
- group2.btn_srch2.click();
- }
- // 야간 순회보고 조회
- function fSearch_reptlist(){
- var searchdd = utlf_transNullToEmpty(ds_temp.getColumn(0, "srchdd2")).toString().substr(0,6);
- var searchdd2 = utlf_transNullToEmpty(ds_temp.getColumn(0, "srchdd2")).toString();
- // var searchdd2 = ipt_orddd2.value;
- // alert("searchdd : " + searchdd);
- if(searchdd2.length < 8) {
- sysf_messageBox("보고일자를 다시 한 번", "C001");
- return;
- }
-
- ds_main_inpt_reptdata_wardlist.clearData();
-
- ds_send_reqdata.setColumn(0, "plandd", searchdd); //계획일자
- ds_send_reqdata.setColumn(0, "deliveflagcd", "07"); //전달구분(야간순회보고 코드 : 07)
-
- // alert("authflag : " + authflag );
- if(authflag == "Y") {
- var oParam = {};
- oParam.id = "TRMNB01212";
- oParam.service = "wardcareapp.WardBizMngt";
- oParam.method = "reqGetNightReportList";
- oParam.inds = "req=ds_send_reqdata";
- oParam.outds = "ds_main_inpt_reptdata_wardlist=wardlist";
- oParam.async = false;
- //oParam.callback = "cf_TRMNB01212";
- tranf_submit(oParam);
-
- if( utlf_isNull(ds_main_inpt_reptdata_wardlist.getColumnInfo("staiud")) ){
- ds_main_inpt_reptdata_wardlist.addColumn("staiud", "string");
- }
- if( utlf_isNull(ds_main_inpt_reptdata_wardlist.getColumnInfo("userid")) ){
- ds_main_inpt_reptdata_wardlist.addColumn("userid", "string");
- }
- } else {
- sysf_messageBox("지정된 사용자 이외에는 조회", "E001");
- return;
- }
-
- opt_certnm.value = ds_main_inpt_reptdata_wardlist.lookup("basedd", searchdd2, "certnm");
- opt_certdt.value = ds_main_inpt_reptdata_wardlist.lookup("basedd", searchdd2, "certdt");
- //fSetColorHoliday(); //expr로 처리
-
- }
- function fUpt_Reptrows(grdflg){
- var wardcd = sysf_getUserInfo("dutplcecd");
- var plandd = group2.ipt_orddd2.value;
- var plandt = utlf_getCurrentDate()+utlf_getCurrentTime().substring(0,4);
- if(grdflg == "wardlist"){
-
- var staiud = ds_main_inpt_reptdata_wardlist.getColumn(ds_main_inpt_reptdata_wardlist.rowposition, "staiud");
-
- if( (staiud =="insert") || (staiud =="delete") ){
- return;
- }
-
- var dt = ds_main_inpt_reptdata_wardlist.getColumn(ds_main_inpt_reptdata_wardlist.rowposition, "plandt");
- var basedd = ds_main_inpt_reptdata_wardlist.getColumn(ds_main_inpt_reptdata_wardlist.rowposition, "basedd");
-
- if(utlf_isNull(dt)) {
- //model.setValue("/root/main/inpt/reptdata/wardlist["+grd_wardlist.row+"]/plandd",plandd);
- ds_main_inpt_reptdata_wardlist.setColumn(ds_main_inpt_reptdata_wardlist.rowposition, "plandd",basedd);
- ds_main_inpt_reptdata_wardlist.setColumn(ds_main_inpt_reptdata_wardlist.rowposition, "plandt",plandt);
- }
- ds_main_inpt_reptdata_wardlist.setColumn(ds_main_inpt_reptdata_wardlist.rowposition, "staiud","update");
- ds_main_inpt_reptdata_wardlist.setColumn(ds_main_inpt_reptdata_wardlist.rowposition, "usernm",sysf_getUserName());
- ds_main_inpt_reptdata_wardlist.setColumn(ds_main_inpt_reptdata_wardlist.rowposition, "userid",sysf_getUserId());
- ds_main_inpt_reptdata_wardlist.setColumn(ds_main_inpt_reptdata_wardlist.rowposition, "deliveflagcd","07");
- ds_main_inpt_reptdata_wardlist.setColumn(ds_main_inpt_reptdata_wardlist.rowposition, "wardcd", sysf_getUserInfo("dutplcecd"));
-
- }
- }
- // 일자별 표시기능
- function fSetColorHoliday(){
- for(var i=0;i<group2.grd_wardlist.rowcount;i++){
-
- var value = ds_main_inpt_reptdata_wardlist.getColumn(i, "dutflag");
- if(value == "4"){
- grd_wardlist.cellstyle("color", i, 1, i, grd_wardlist.colRef("certdt")) = "#0000ee";
- grd_wardlist.cellstyle("background-color", i, 1, i, grd_wardlist.colRef("certdt")) = "#ffd3ff";
- }else if(value == "8"){
- grd_wardlist.cellstyle("color", i, 1, i, grd_wardlist.colRef("certdt")) = "#ee0000";
- grd_wardlist.cellstyle("background-color", i, 1, i, grd_wardlist.colRef("certdt")) = "#ffd3ff";
- }else
- grd_wardlist.cellstyle("color", i, 1, i, grd_wardlist.colRef("certdt")) = "#000000";
- }
- }
- function fDel_Reptrows(grdflg){
- var reptcnt;
- var selrow;
- if(grdflg == "wardlist"){
- reptcnt = group2.grd_wardlist.rowcount;
- selrow = group2.grd_wardlist.currentrow;
- }
-
- // alert("selrow : " + selrow);
- if(reptcnt < 1 || selrow < 0){
- sysf_messageBox("삭제 할 자료가","I004");
- return;
- }
-
- if(utlf_isNull(selrow)){
- sysf_messageBox("선택된 셀이 ","I004");
- return;
- }
-
- if(grdflg == "wardlist"){
- ds_main_inpt_reptdata_wardlist.setColumn(ds_main_inpt_reptdata_wardlist.rowposition, "staiud","delete");
-
- ds_main_inpt_reptdata_wardlist.enableevent = false;
- ds_main_inpt_reptdata_wardlist.updatecontrol = false;
-
- ds_main_inpt_reptdata_wardlist.setRowType(ds_main_inpt_reptdata_wardlist.rowposition, 8);
-
- ds_main_inpt_reptdata_wardlist.updatecontrol = true;
- ds_main_inpt_reptdata_wardlist.enableevent = true;
- }
- }
- //=======================================================================================
- // Event
- //---------------------------------------------------------------------------------------
- /****************************************************************************************
- * Components : Form
- * Components ID : SMMNB01220
- * Event : oninit
- * Argument : 01.obj : Object Event has occurred
- * : 02.e : Event Object
- * Description : 화면 처음 초기화시
- ****************************************************************************************/
- function SMMNB01220_oninit(obj:Form, e:InitEventInfo)
- {
- frmf_initForm(obj); //폼 초기화
- }
- /****************************************************************************************
- * Components : Form
- * Components ID : SMMNB01220
- * Event : onload
- * Argument : 01.obj : Object Event has occurred
- * : 02.e : Event Object
- * Description : 화면 로딩 완료시
- ****************************************************************************************/
- function SMMNB01220_onload(obj:Form, e:LoadEventInfo)
- {
- ds_temp.setColumn(0, "duty", "1");
-
- grdf_setRowTypeIcon(group2.grd_wardlist, 0);
-
- //16.10.07_EMR.MNWHCAPL.DELIVEFLAGCD 설명
- //01.인사보고, 02.병동보고, 03.교육보고, 04.기타보고, 05.당직보고, 06.마취회복실 일일업무현황, 07.야간순회보고
-
- // 간호하드코딩 테이블 조회(I14 - 야간순회보고 조회가능 아이디)
- var pCode = "'I14'"; // 조회할 CdGrupID 코드정보
- var pDate = utlf_getCurrentDate(); //조회기준일자
- fGetNursHardCdInfo(pCode, pDate); //ds_codelist
-
- var jobkindcd = sysf_getUserInfo("jobkindcd");
- var jobposcd = sysf_getUserInfo("jobposcd");
- var userid = sysf_getUserInfo("userid");
- var dutplcecd = sysf_getUserInfo("dutplcecd");
-
- var curTime= utlf_getCurrentTime().substr(0,4);
- if(curTime <= "0800") {
- group2.ipt_orddd2.value = getAddDay(utlf_getCurrentDate(),-1);
- } else {
- group2.ipt_orddd2.value = utlf_getCurrentDate();
- }
-
- // 간호부장, 과장, 수간호사 및 등록된 사용자만 조회가능토록
- if ( jobkindcd == "1140" && (jobposcd == "41" || jobposcd == "75" || jobposcd == "62" || sysf_getUserInfo("userid") == "ENR" || sysf_getUserInfo("userid") == ds_codelist.lookupExpr("cdgrupid=='I14' && cdid=='"+sysf_getUserInfo("userid")+"'", "cdid"))){
- group2.btn_srch2.disabled = false;
- group2.btn_excel2.disabled = false;
- group2.button22.disabled = false;
- group2.button23.disabled = false;
- btn_cert.disabled = false;
- group2.ipt_orddd2.disabled = false;
- authflag = "Y";
- // rdo_deptflag.value = model.getValue("/root/code/codeinfo/codelist[cdgrupid='T52' and supcdid='"+dutplcecd+"']/cdid")
- } else {
- group2.btn_srch2.disabled = true;
- group2.btn_excel2.disabled = true;
- group2.button22.disabled = true;
- group2.button23.disabled = true;
- btn_cert.disabled = true;
- group2.ipt_orddd2.disabled = true;
- authflag = "N";
- //messageBox("지정된 사용자 이외에는 조회", "E001");
- }
- fSearch_reptlist();
- }
- /****************************************************************************************
- * Components : Button
- * Components ID : button16
- * Event : onclick
- * Argument : 01.obj : Object Event has occurred
- * : 02.e : Event Object
- * Description : 축소버튼 클릭시
- ****************************************************************************************/
- function group2_button16_onclick(obj:Button, e:ClickEventInfo)
- {
- group2.grd_wardlist.position.height = 250;
- }
- /****************************************************************************************
- * Components : Dataset
- * Components ID : ds_main_inpt_reptdata_wardlist
- * Event : oncolumnchanged
- * Argument : 01.obj : Object Event has occurred
- * : 02.e : Event Object
- * Description : 데이터셋 값 변경시
- ****************************************************************************************/
- function ds_main_inpt_reptdata_wardlist_oncolumnchanged(obj:Dataset, e:DSColChangeEventInfo)
- {
- fUpt_Reptrows("wardlist");
- }
- /****************************************************************************************
- * Components : Button
- * Components ID : button10
- * Event : onclick
- * Argument : 01.obj : Object Event has occurred
- * : 02.e : Event Object
- * Description : 행추가버튼 클릭시
- ****************************************************************************************/
- function group2_button10_onclick(obj:Button, e:ClickEventInfo)
- {
- fAdd_Reptrows("wardlist");
- }
- /****************************************************************************************
- * Components : Button
- * Components ID : button22
- * Event : onclick
- * Argument : 01.obj : Object Event has occurred
- * : 02.e : Event Object
- * Description : 삭제버튼 클릭시
- ****************************************************************************************/
- function group2_button22_onclick(obj:Button, e:ClickEventInfo)
- {
- fDel_Reptrows("wardlist");
- }
- /****************************************************************************************
- * Components : Button
- * Components ID : button23
- * Event : onclick
- * Argument : 01.obj : Object Event has occurred
- * : 02.e : Event Object
- * Description : 저장버튼 클릭시
- ****************************************************************************************/
- function group2_button23_onclick(obj:Button, e:ClickEventInfo)
- {
- fSave_Reptrows2();
- }
- /****************************************************************************************
- * Components : Button
- * Components ID : button14
- * Event : onclick
- * Argument : 01.obj : Object Event has occurred
- * : 02.e : Event Object
- * Description : 확대버튼 클릭시
- ****************************************************************************************/
- function group2_button14_onclick(obj:Button, e:ClickEventInfo)
- {
- group2.grd_wardlist.position.height = 644;
- }
- /****************************************************************************************
- * Components : Button
- * Components ID : btn_srch2
- * Event : onclick
- * Argument : 01.obj : Object Event has occurred
- * : 02.e : Event Object
- * Description : 조회버튼 클릭시
- ****************************************************************************************/
- function group2_btn_srch2_onclick(obj:Button, e:ClickEventInfo)
- {
- fSearch_reptlist();
- }
- /****************************************************************************************
- * Components : Calendar
- * Components ID : ipt_orddd2
- * Event : onchanged
- * Argument : 01.obj : Object Event has occurred
- * : 02.e : Event Object
- * Description : 달력 값 변경시
- ****************************************************************************************/
- function group2_ipt_orddd2_onchanged(obj:Calendar, e:ChangeEventInfo)
- {
- fSearch_reptlist();
- }
- /****************************************************************************************
- * Components : Button
- * Components ID : btn_excel2
- * Event : onclick
- * Argument : 01.obj : Object Event has occurred
- * : 02.e : Event Object
- * Description : 엑셀버튼 클릭시
- ****************************************************************************************/
- function group2_btn_excel2_onclick(obj:Button, e:ClickEventInfo)
- {
- if( group2.grd_wardlist.rowcount > 0 ){
- grdf_exportExcel(group2.grd_wardlist, "야간순회보고", "SheetName", false, "", "user", false);
- } else {
- sysf_messageBox("엑셀파일로 저장할 리스트 내역이", "I004");
- return;
- }
- }
- /****************************************************************************************
- * Components : Button
- * Components ID : btn_cert
- * Event : onclick
- * Argument : 01.obj : Object Event has occurred
- * : 02.e : Event Object
- * Description : 확인버튼 클릭시
- ****************************************************************************************/
- function btn_cert_onclick(obj:Button, e:ClickEventInfo)
- {
- var searchdd = ds_temp.getColumn(0, "srchdd2");
- var sseq = ds_main_inpt_reptdata_wardlist.lookup("basedd", searchdd, "seqno");
- if(utlf_isNull(sseq)){
- sysf_messageBox(searchdd + " 일자의 야간순회보고가 작성되지 않았습니다.","E");
- return;
- }
- if(sysf_messageBox(searchdd + "일자에 확인","Q002") != 6) return;
-
- opt_certnm.value = sysf_getUserInfo("usernm");
- opt_certdt.value = utlf_getCurrentDate() + utlf_getCurrentTime();
-
- // alert(ipt_orddd2.value);
- // alert("test : " + model.getValue("/root/main/inpt/reptdata/wardlist[basedd = '"+ searchdd +"']/basedd"));
-
- var nFindRow = ds_main_inpt_reptdata_wardlist.findRow("basedd", searchdd);
-
- ds_main_inpt_reptdata_wardlist.enableevent = false;
- ds_main_inpt_reptdata_wardlist.updatecontrol = false;
-
- ds_main_inpt_reptdata_wardlist.setColumn(nFindRow, "certid", sysf_getUserInfo("userid"));
- ds_main_inpt_reptdata_wardlist.setColumn(nFindRow, "certdt", utlf_getCurrentDate() + utlf_getCurrentTime());
- ds_main_inpt_reptdata_wardlist.setColumn(nFindRow, "staiud", "update");
-
- for( var i=0 ; i<ds_main_inpt_reptdata_wardlist.rowcount ; i++ ){
- if( ds_main_inpt_reptdata_wardlist.getColumn(i, "basedd").toString().indexOf(searchdd.toString()) > -1 ){
- ds_main_inpt_reptdata_wardlist.setRowType(i, 4);
- break;
- }
- }
-
- ds_main_inpt_reptdata_wardlist.updatecontrol = true;
- ds_main_inpt_reptdata_wardlist.enableevent = true;
-
- ds_send_sReptPath.clearData();
-
- for( var i=0 ; i<ds_main_inpt_reptdata_wardlist.rowcount ; i++ ){
- if( ds_main_inpt_reptdata_wardlist.getRowType(i) == 2 || ds_main_inpt_reptdata_wardlist.getRowType(i) == 4 || ds_main_inpt_reptdata_wardlist.getRowType(i) == 8 ){
- var nRow = ds_send_sReptPath.addRow();
- ds_send_sReptPath.copyRow(nRow, ds_main_inpt_reptdata_wardlist, i);
- }
- }
-
- // alert("updtdata : " + updtdata);
- if(utlf_isNull(ds_send_sReptPath) || ds_send_sReptPath.rowcount == 0){
- sysf_messageBox("저장할 자료가 존재하지 않습니다.","I");
- return;
- }
-
- var oParam = {};
- oParam.id = "TXMNB01204";
- oParam.service = "wardcareapp.WardBizMngt";
- oParam.method = "reqExeSetNightReport";
- oParam.inds = "reqExeSetRept=ds_send_sReptPath";
- oParam.outds = "";
- oParam.async = false;
- oParam.callback = "cf_TXMNB01204";
- tranf_submit(oParam);
-
- if(arErrorCode.pop("TXMNB01204") > -1) {
- sysf_messageBox("저장되었습니다.", "I");
- fSearch_reptlist();
- }
- }
- function cf_TXMNB01204(sSvcId, nErrorCode, sErrorMsg) {
- arErrorCode.push(sSvcId, nErrorCode);
- }
- ]]></Script>
- </Form>
- </FDL>
|