123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880 |
- <?xml version="1.0" encoding="utf-8"?>
- <FDL version="1.5">
- <TypeDefinition url="..\..\..\default_typedef.xml"/>
- <Form id="SMMNW13800" position="absolute 0 0 1190 730" titletext="욕창발생보고" oninit="SMMNW13800_oninit" onload="SMMNW13800_onload">
- <Layouts>
- <Layout>
- <Div id="group2" taborder="0" position="absolute 0 13 1190 730">
- <Layouts>
- <Layout>
- <Grid id="grd_detlgruplist" taborder="12" binddataset="ds_out_detlgruplist" position="absolute 0 77 1190 711" anchor="default" cellsizingtype="both" oncelldblclick="group2_grd_detlgruplist_oncelldblclick" useinputpanel="false" scrollpixel="all">
- <Formats>
- <Format id="default">
- <Columns>
- <Column size="25" band="left"/>
- <Column size="30"/>
- <Column size="70"/>
- <Column size="0"/>
- <Column size="65"/>
- <Column size="80"/>
- <Column size="30"/>
- <Column size="30"/>
- <Column size="100"/>
- <Column size="80"/>
- <Column size="70"/>
- <Column size="107"/>
- <Column size="80"/>
- <Column size="90"/>
- <Column size="100"/>
- <Column size="170"/>
- <Column size="30"/>
- <Column size="30"/>
- <Column size="30"/>
- <Column size="50"/>
- <Column size="70"/>
- <Column size="50"/>
- <Column size="100"/>
- <Column size="50"/>
- <Column size="0"/>
- <Column size="0"/>
- <Column size="0"/>
- <Column size="0"/>
- </Columns>
- <Rows>
- <Row size="20" band="head"/>
- <Row size="20" band="head"/>
- <Row size="24"/>
- </Rows>
- <Band id="head">
- <Cell rowspan="2" taborder="undefined"/>
- <Cell col="1" rowspan="2" text="선택" taborder="undefined"/>
- <Cell col="2" rowspan="2" text="부 서" taborder="undefined"/>
- <Cell col="3" text="wardcd"/>
- <Cell col="4" rowspan="2" text="등록번호" taborder="undefined"/>
- <Cell col="5" rowspan="2" text="이름" taborder="undefined"/>
- <Cell col="6" rowspan="2" text="성별" taborder="undefined"/>
- <Cell col="7" rowspan="2" text="나이" taborder="undefined"/>
- <Cell col="8" rowspan="2" text="진료과" taborder="undefined"/>
- <Cell col="9" rowspan="2" text="진단명" taborder="undefined"/>
- <Cell col="10" rowspan="2" text="입원일" taborder="undefined"/>
- <Cell col="11" rowspan="2" text="욕창위험초기사정 Braden 점수/군" taborder="undefined"/>
- <Cell col="12" rowspan="2" text="발생일자" taborder="undefined"/>
- <Cell col="13" rowspan="2" text="발생장소" taborder="undefined"/>
- <Cell col="14" rowspan="2" text="발생장소(원내)" taborder="undefined"/>
- <Cell col="15" rowspan="2" text="발생부위" taborder="undefined"/>
- <Cell col="16" colspan="3" text="크기(cm)" taborder="undefined"/>
- <Cell col="19" rowspan="2" text="단계" taborder="undefined"/>
- <Cell col="20" rowspan="2" text="보고일" taborder="undefined"/>
- <Cell col="21" rowspan="2" text="보고자" taborder="undefined"/>
- <Cell col="22" rowspan="2" text="보고부서" taborder="undefined"/>
- <Cell col="23" rowspan="2" text="부서장 확인" taborder="undefined"/>
- <Cell col="24" text="grupcd"/>
- <Cell col="25" text="obsrecseq"/>
- <Cell col="26" text="obsrecrptseq"/>
- <Cell col="27" text="cretno"/>
- <Cell row="1" col="3" text="wardcd"/>
- <Cell row="1" col="16" text="가로"/>
- <Cell row="1" col="17" text="세로"/>
- <Cell row="1" col="18" text="깊이"/>
- <Cell row="1" col="24" text="grupcd"/>
- <Cell row="1" col="25" text="obsrecseq"/>
- <Cell row="1" col="26" text="obsrecrptseq"/>
- <Cell row="1" col="27" text="cretno"/>
- </Band>
- <Band id="body">
- <Cell celltype="head" text="expr:currow + 1"/>
- <Cell col="1" displaytype="checkbox" edittype="checkbox" text="bind:sel" expr="expr:(sel == "true" || sel == "1") ? 1 : 0"/>
- <Cell col="2" style="align:left;" text="bind:wardnm"/>
- <Cell col="3" text="bind:wardcd"/>
- <Cell col="4" style="align:left;" text="bind:pid"/>
- <Cell col="5" style="align:left;" text="bind:hngnm"/>
- <Cell col="6" style="align:left;" text="bind:sex"/>
- <Cell col="7" style="align:left;" text="bind:age"/>
- <Cell col="8" style="align:left;" text="bind:orddeptnm"/>
- <Cell col="9" style="align:left;" text="bind:diag"/>
- <Cell col="10" displaytype="date" text="bind:indd" mask="yyyy-MM-dd" calendardisplaynulltype="none"/>
- <Cell col="11" style="align:left;" text="bind:pntrslt"/>
- <Cell col="12" displaytype="date" text="bind:genrdd" mask="yyyy-MM-dd" calendardisplaynulltype="none"/>
- <Cell col="13" style="align:left;" text="bind:genrplce"/>
- <Cell col="14" displaytype="combo" style="align:left;" text="bind:genrplcewardcd" combodataset="ds_init_cmb_wardcd" combocodecol="wardcd" combodatacol="wardnm" enable="false"/>
- <Cell col="15" style="align:left;" text="bind:obspartnm"/>
- <Cell col="16" style="align:left;" text="bind:sizewidth"/>
- <Cell col="17" style="align:left;" text="bind:sizeheight"/>
- <Cell col="18" style="align:left;" text="bind:sizedepth"/>
- <Cell col="19" displaytype="combo" text="bind:stage" combodataset="ds_out_getVOStage" combocodecol="cd" combodatacol="cdnm" enable="false"/>
- <Cell col="20" displaytype="date" text="bind:reportdd" mask="yyyy-MM-dd" calendardisplaynulltype="none"/>
- <Cell col="21" style="align:left;" text="bind:reportid"/>
- <Cell col="22" style="align:left;" text="bind:reportdept"/>
- <Cell col="23" displaytype="checkbox" edittype="checkbox" text="bind:deptcnfmyn" expr="expr:(deptcnfmyn == "true" || deptcnfmyn == "1") ? 1 : 0"/>
- <Cell col="24" text="bind:grupcd"/>
- <Cell col="25" text="bind:obsrecseq"/>
- <Cell col="26" text="bind:obsrecrptseq"/>
- <Cell col="27" text="bind:cretno"/>
- </Band>
- </Format>
- </Formats>
- </Grid>
- <Shape id="line1" linetype="horizontal" class="line_10" position="absolute 0 72 1190 78" anchor="default"/>
- <Button id="btn_savedschresn" taborder="14" text="저장" class="btn5" position="absolute 1148 51 1190 71" onclick="group2_btn_savedschresn_onclick" anchor="default"/>
- <Button id="btn_delt" taborder="15" text="삭제" class="btn2" position="absolute 1103 51 1145 71" onclick="group2_btn_delt_onclick" anchor="default"/>
- </Layout>
- </Layouts>
- </Div>
- <Static id="cpt_title" text="욕창발생보고" class="tit_1" position="absolute 0 0 115 25"/>
- <Div id="grp_sea" taborder="1" position="absolute 0 25 1190 60" class="div_SA">
- <Layouts>
- <Layout width="1190" height="35">
- <Button id="button2" taborder="8" text="엑셀" class="btn7" position="absolute 1058 8 1114 28" anchor="default" onclick="grp_sea_button2_onclick"/>
- <Combo id="cmb_wardcd" taborder="9" class="combo_default" position="absolute 78 8 243 28" anchor="default" onitemchanged="grp_sea_cmb_wardcd_onitemchanged" index="-1" innerdataset="@ds_init_cmb_wardcd" codecolumn="wardcd" datacolumn="wardnm" enable="false"/>
- <Static id="caption29" text="병 동 :" class="search_name" position="absolute 20 8 87 28" anchor="default"/>
- <Shape id="line2" linetype="vertical" class="line_4" position="absolute 980 7 986 30" anchor="default"/>
- <Static id="caption3" text="보고일자 :" class="search_name" position="absolute 260 8 352 28" anchor="default"/>
- <Button id="button1" taborder="10" text="출력" class="btn6" position="absolute 1116 8 1172 28" anchor="default" onclick="grp_sea_button1_onclick"/>
- <Button id="btn_srchdschtpatlist" taborder="11" text="조회" class="btn1" position="absolute 1000 8 1056 28" anchor="default" onclick="grp_sea_btn_srchdschtpatlist_onclick"/>
- <Static id="caption2" text="~" position="absolute 434 8 449 28" anchor="default"/>
- <Calendar id="input23" taborder="12" class="input_default" position="absolute 338 8 428 28" anchor="default" autoskip="true" autoselect="true" dateformat="yyyy-MM-dd" value="null" onchanged="grp_sea_input23_onchanged"/>
- <Calendar id="input1" taborder="13" class="input_default" position="absolute 449 8 539 28" anchor="default" autoskip="true" autoselect="true" dateformat="yyyy-MM-dd" value="null" onchanged="grp_sea_input1_onchanged"/>
- </Layout>
- </Layouts>
- </Div>
- </Layout>
- </Layouts>
- <Objects>
- <Dataset id="ds_tmp_detlgruplist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" reversesubsum="false">
- <ColumnInfo>
- <Column id="stat" type="STRING" size="256" sumtext="그리드행 stat"/>
- <Column id="sel" type="STRING" size="256" sumtext="선택"/>
- <Column id="wardnm" type="STRING" size="256" sumtext="병동명"/>
- <Column id="wardcd" type="STRING" size="256" sumtext="병동코드"/>
- <Column id="pid" type="STRING" size="256" sumtext="등록번호"/>
- <Column id="hngnm" type="STRING" size="256" sumtext="환자명"/>
- <Column id="sex" type="STRING" size="256" sumtext="성별"/>
- <Column id="age" type="STRING" size="256" sumtext="나이"/>
- <Column id="orddeptnm" type="STRING" size="256" sumtext="진료과"/>
- <Column id="diag" type="STRING" size="256" sumtext="진단명"/>
- <Column id="indd" type="STRING" size="256" sumtext="입원일"/>
- <Column id="pntrslt" type="STRING" size="256" sumtext="욕창위험초기사정 Braden 점수/군"/>
- <Column id="genrdd" type="STRING" size="256" sumtext="발생일자"/>
- <Column id="genrplce" type="STRING" size="256" sumtext="발생장소"/>
- <Column id="obspartnm" type="STRING" size="256" sumtext="발생부위"/>
- <Column id="sizewidth" type="STRING" size="256" sumtext="크기가로"/>
- <Column id="sizeheight" type="STRING" size="256" sumtext="크기세로"/>
- <Column id="sizedepth" type="STRING" size="256" sumtext="크기깊이"/>
- <Column id="stage" type="STRING" size="256" sumtext="단계"/>
- <Column id="reportdd" type="STRING" size="256" sumtext="보고일자"/>
- <Column id="reportid" type="STRING" size="256" sumtext="보고자id"/>
- <Column id="deptcnfmyn" type="STRING" size="256" sumtext="부서장확인구분"/>
- <Column id="grupcd" type="STRING" size="256" sumtext="그룹코드"/>
- <Column id="obsrecseq" type="STRING" size="256" sumtext="욕창기록순번"/>
- <Column id="obsrecrptseq" type="STRING" size="256" sumtext="욕창발생보고순번"/>
- <Column id="cretno" type="STRING" size="256" sumtext="생성번호"/>
- <Column id="reportdept" type="STRING" size="256" sumtext="보고부서"/>
- <Column id="genrplcewardcd" type="STRING" size="256" sumtext="발생장소원내코드"/>
- <Column id="stageid" type="STRING" size="256" sumtext="발생장소원내코드"/>
- </ColumnInfo>
- </Dataset>
- <Dataset id="ds_init_cmb_wardcd" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" reversesubsum="false">
- <ColumnInfo>
- <Column id="wardnm" type="STRING"/>
- <Column id="wardcd" type="STRING"/>
- </ColumnInfo>
- </Dataset>
- <Dataset id="ds_main_cond" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
- <ColumnInfo>
- <Column id="wardcd" type="STRING" size="256"/>
- <Column id="fromdd" type="STRING" size="256"/>
- <Column id="todd" type="STRING" size="256"/>
- </ColumnInfo>
- <Rows>
- <Row/>
- </Rows>
- </Dataset>
- <Dataset id="ds_init_settingrn" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
- <ColumnInfo>
- <Column id="settingrnid" type="STRING" size="256" sumtext="세팅간호사ID"/>
- <Column id="settingrnnm" type="STRING" size="256" sumtext="세팅간호사명"/>
- </ColumnInfo>
- </Dataset>
- <Dataset id="ds_out_getVOStage" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
- <ColumnInfo>
- <Column id="cd" type="STRING" size="256" sumtext="코드"/>
- <Column id="cdnm" type="STRING" size="256" sumtext="코드명"/>
- </ColumnInfo>
- </Dataset>
- <Dataset id="ds_codelist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
- <Dataset id="ds_out_detlgruplist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false" oncolumnchanged="ds_out_detlgruplist_oncolumnchanged">
- <ColumnInfo>
- <Column id="stat" type="STRING" size="256" sumtext="그리드행 stat"/>
- <Column id="sel" type="STRING" size="256" sumtext="선택"/>
- <Column id="wardnm" type="STRING" size="256" sumtext="병동명"/>
- <Column id="wardcd" type="STRING" size="256" sumtext="병동코드"/>
- <Column id="pid" type="STRING" size="256" sumtext="등록번호"/>
- <Column id="hngnm" type="STRING" size="256" sumtext="환자명"/>
- <Column id="sex" type="STRING" size="256" sumtext="성별"/>
- <Column id="age" type="STRING" size="256" sumtext="나이"/>
- <Column id="orddeptnm" type="STRING" size="256" sumtext="진료과"/>
- <Column id="diag" type="STRING" size="256" sumtext="진단명"/>
- <Column id="indd" type="STRING" size="256" sumtext="입원일"/>
- <Column id="pntrslt" type="STRING" size="256" sumtext="욕창위험초기사정 Braden 점수/군"/>
- <Column id="genrdd" type="STRING" size="256" sumtext="발생일자"/>
- <Column id="genrplce" type="STRING" size="256" sumtext="발생장소"/>
- <Column id="obspartnm" type="STRING" size="256" sumtext="발생부위"/>
- <Column id="sizewidth" type="STRING" size="256" sumtext="크기가로"/>
- <Column id="sizeheight" type="STRING" size="256" sumtext="크기세로"/>
- <Column id="sizedepth" type="STRING" size="256" sumtext="크기깊이"/>
- <Column id="stage" type="STRING" size="256" sumtext="단계"/>
- <Column id="reportdd" type="STRING" size="256" sumtext="보고일자"/>
- <Column id="reportid" type="STRING" size="256" sumtext="보고자id"/>
- <Column id="deptcnfmyn" type="STRING" size="256" sumtext="부서장확인구분"/>
- <Column id="grupcd" type="STRING" size="256" sumtext="그룹코드"/>
- <Column id="obsrecseq" type="STRING" size="256" sumtext="욕창기록순번"/>
- <Column id="obsrecrptseq" type="STRING" size="256" sumtext="욕창발생보고순번"/>
- <Column id="cretno" type="STRING" size="256" sumtext="생성번호"/>
- <Column id="reportdept" type="STRING" size="256" sumtext="보고부서"/>
- <Column id="genrplcewardcd" type="STRING" size="256" sumtext="발생장소원내코드"/>
- </ColumnInfo>
- </Dataset>
- <Dataset id="ds_hidden_main_detlgrupinfo_detlgruplist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false" oncolumnchanged="ds_out_detlgruplist_oncolumnchanged">
- <ColumnInfo>
- <Column id="stat" type="STRING" size="256" sumtext="그리드행 stat"/>
- <Column id="sel" type="STRING" size="256" sumtext="선택"/>
- <Column id="wardnm" type="STRING" size="256" sumtext="병동명"/>
- <Column id="wardcd" type="STRING" size="256" sumtext="병동코드"/>
- <Column id="pid" type="STRING" size="256" sumtext="등록번호"/>
- <Column id="hngnm" type="STRING" size="256" sumtext="환자명"/>
- <Column id="sex" type="STRING" size="256" sumtext="성별"/>
- <Column id="age" type="STRING" size="256" sumtext="나이"/>
- <Column id="orddeptnm" type="STRING" size="256" sumtext="진료과"/>
- <Column id="diag" type="STRING" size="256" sumtext="진단명"/>
- <Column id="indd" type="STRING" size="256" sumtext="입원일"/>
- <Column id="pntrslt" type="STRING" size="256" sumtext="욕창위험초기사정 Braden 점수/군"/>
- <Column id="genrdd" type="STRING" size="256" sumtext="발생일자"/>
- <Column id="genrplce" type="STRING" size="256" sumtext="발생장소"/>
- <Column id="obspartnm" type="STRING" size="256" sumtext="발생부위"/>
- <Column id="sizewidth" type="STRING" size="256" sumtext="크기가로"/>
- <Column id="sizeheight" type="STRING" size="256" sumtext="크기세로"/>
- <Column id="sizedepth" type="STRING" size="256" sumtext="크기깊이"/>
- <Column id="stage" type="STRING" size="256" sumtext="단계"/>
- <Column id="reportdd" type="STRING" size="256" sumtext="보고일자"/>
- <Column id="reportid" type="STRING" size="256" sumtext="보고자id"/>
- <Column id="deptcnfmyn" type="STRING" size="256" sumtext="부서장확인구분"/>
- <Column id="grupcd" type="STRING" size="256" sumtext="그룹코드"/>
- <Column id="obsrecseq" type="STRING" size="256" sumtext="욕창기록순번"/>
- <Column id="obsrecrptseq" type="STRING" size="256" sumtext="욕창발생보고순번"/>
- <Column id="cretno" type="STRING" size="256" sumtext="생성번호"/>
- <Column id="reportdept" type="STRING" size="256" sumtext="보고부서"/>
- <Column id="genrplcewardcd" type="STRING" size="256" sumtext="발생장소원내코드"/>
- </ColumnInfo>
- </Dataset>
- </Objects>
- <Bind>
- <BindItem id="item0" compid="grp_sea.input23" propid="value" datasetid="ds_main_cond" columnid="fromdd"/>
- <BindItem id="item1" compid="grp_sea.input1" propid="value" datasetid="ds_main_cond" columnid="todd"/>
- <BindItem id="item2" compid="grp_sea.cmb_wardcd" propid="value" datasetid="ds_main_cond" columnid="wardcd"/>
- </Bind>
- <Script type="xscript4.0"><![CDATA[/***************************************************************************************
- * System Name :
- * Job Name :
- * Creator :
- * Make Date : 2015-11-13
- * Description :
- *---------------------------------------------------------------------------------------
- * Modify Date Modifier Modify Description
- *---------------------------------------------------------------------------------------
- * 2015-11-13 Live Converter TF->XP
- *
- *---------------------------------------------------------------------------------------
- ****************************************************************************************/
- //=======================================================================================
- // Lib Include
- //---------------------------------------------------------------------------------------
- include "com_commonxp::comm_main.xjs";
- //include "emr_carecomxp::CareCom.xjs";
- var mainDetlGrupGridPath = ds_out_detlgruplist;
- var tempDetlGrupGridPath = ds_hidden_main_detlgrupinfo_detlgruplist;
- //=======================================================================================
- // Functions
- //---------------------------------------------------------------------------------------
- /****************************************************************************************
- * Argument : N/A
- * Description : CareCom.xjs 파일을 로컬로 이동
- ****************************************************************************************/
- function fGetNursHardCdInfo(code, date){
- ds_codelist.clearData();
- ds_codelist.addRow();
-
- dsf_createDsRow('ds_req', [
- { col: 'cdgrupid', type: 'string', size: 256, val: code },
- { col: 'srchdd', type: 'string', size: 256, val: date },
- { col: 'flag', type: 'string', size: 256, val: '' },
- { col: 'allflag', type: 'string', size: 256, val: '' }
- ], false);
-
- var oParam = {};
- oParam.id = "TRMNW00001";
- oParam.service = "wardcareapp.WardCareMngt";
- oParam.method = "reqGetNursHardCdInfo";
- oParam.inds = "req=ds_req";
- oParam.outds = "ds_codelist=codelist";
- oParam.async = false;
- //oParam.callback = "cf_TRMNW00001";
- tranf_submit(oParam);
- }
- /****************************************************************************************
- * Argument : N/A
- * Description :
- ****************************************************************************************/
-
- /****************************************************************************************
- * Argument : N/A
- * Description : fInit
- ****************************************************************************************/
- function fInit(){
- // 간호하드코딩 테이블 조회_'15.06.02-AYS
- // 조회할 CdGrupID 코드정보
- var pCode ="'330'";
- // 조회기준일자
- var pDate = utlf_getCurrentDate();
-
- fGetNursHardCdInfo(pCode, pDate);
-
- var sInstcd = sysf_getUserInfo('dutplceinstcd');
- var sDutplcecd = sysf_getUserInfo('dutplcecd');
- var sUserid = sysf_getUserInfo("userid");
- var sSuperUser = 'N';
-
- // 부서장권한 체크 (2011.05.02)
- var jobPosCd = sysf_getUserInfo('jobposcd');
- // 부서장(수간호사) = '75'
- if(jobPosCd != '75'){
- group2.grd_detlgruplist.setCellProperty('Body', group2.grd_detlgruplist.getBindCellIndex('Body', 'deptcnfmyn'), 'edittype', 'none');
- group2.grd_detlgruplist.setCellProperty("Body", group2.grd_detlgruplist.getBindCellIndex('Body', 'deptcnfmyn'), "controlbackground", "silver");
- group2.grd_detlgruplist.setCellProperty("Body", group2.grd_detlgruplist.getBindCellIndex('Body', 'deptcnfmyn'), "controlborder", "1 solid #708090cc");
- group2.btn_delt.enable = false;
- group2.btn_savedschresn.enable = false;
- }
-
- // 그리드 초기화
- ds_out_detlgruplist.clearData();
- //ds_out_detlgruplist.addRow();
-
- ds_init_cmb_wardcd.clearData();
- ds_init_cmb_wardcd.addRow();
-
- ds_init_settingrn.clearData();
- ds_init_settingrn.addRow();
-
- dsf_createDsRow('ds_reqcond', [{ col: 'wardcd', type: 'string', size: 256, val: '' }], false);
-
- // 병동 조회
- var oParam = {};
- oParam.id = "TRMNW04705";
- oParam.service = "wardcareapp.WardCareMngt";
- oParam.method = "reqGetWMInitData";
- oParam.inds = "reqcond=ds_reqcond";
- oParam.outds = "ds_init_cmb_wardcd=ward ds_init_settingrn=settingrn";
- oParam.async = false;
- oParam.callback = "cf_TRMNW04705";
- tranf_submit(oParam);
- frmf_addComboItem('grp_sea.cmb_wardcd', '전체', '', 'above');
- grp_sea.cmb_wardcd.index = 0;
- // alert('asdf');
- // frmf_inputEnterKey('grp_sea.cmb_wardcd', 'onitemchanged', new ItemChangeEventInfo);
-
- // 그리드에 들어갈 공통리스트 조회
- dsf_createDsRow('tmp', [ {col: 'tmp', type: 'string', size: 256, val: '' }], false);
- ds_out_getVOStage.clearData();
- ds_out_getVOStage.addRow();
-
- oParam = {};
- oParam.id = "TRMNW04701";
- oParam.service = "wardcareapp.WardCareRec";
- oParam.method = "reqGetObsBaseDataComboList";
- oParam.inds = "refCond=tmp";
- oParam.outds = "ds_out_getVOStage=getVOStage";
- // "ds_=getVOCause ds_=getVOStage ds_=getVOColor ds_=ge;tVOState ds_=getVOAmount ds_=getVOSympTom ds_=getVOAngle ds_=getVODressing"
- oParam.async = false;
- oParam.callback = "cf_TRMNW04701";
- tranf_submit(oParam);
-
- grp_sea.cmb_wardcd.setFocus();
-
- // 업무일자(조회시작일자)
- ds_main_cond.setColumn(0, 'fromdd', utlf_getCurrentDate());
- // 업무일자(조회종료일자)
- ds_main_cond.setColumn(0, 'todd', utlf_getCurrentDate());
-
- if(ds_codelist.rowcount > 0){
- if(ds_codelist.findRow('cdid', sUserid) >= 0){
- sSuperUser = 'Y';
- }
- }
-
- if(sInstcd == '031' || sInstcd == '032'){
- if(sysf_getUserInfo('userid') == 'ENR' || sSuperUser == 'Y'){
- grp_sea.cmb_wardcd.enable = true;
- }
- else{
- ds_main_cond.setColumn(0, 'wardcd', sDutplcecd);
- grp_sea.cmb_wardcd.enable = false;
- }
- }
- else{
- // do noting
- //model.makeNode("/root/main/cond/wardcd");
- }
- }
- /****************************************************************************************
- * Argument : N/A
- * Description : cf_TRMNW04705
- ****************************************************************************************/
- function cf_TRMNW04701(sSvcId, nErrorCode, sErrorMsg) {
- if(nErrorCode < 0){
- sysf_messageBox('화면 초기화를', 'E009');
- return;
- }
- }
- /****************************************************************************************
- * Argument : N/A
- * Description : cf_TRMNW04705
- ****************************************************************************************/
- function cf_TRMNW04705(sSvcId, nErrorCode, sErrorMsg) {
- if(nErrorCode < 0){
- sysf_messageBox('화면 초기화를', 'E009');
- return;
- }
- }
- /****************************************************************************************
- * Argument : N/A
- * Description : fSearch
- ****************************************************************************************/
- function fSearch(){
- // 조회조건값 세팅
- // 병동코드
- var wardcd = ds_main_cond.getColumn(0, 'wardcd');
- // 조회시작일자
- var fromdd = ds_main_cond.getColumn(0, 'fromdd');
- // 조회종료일자
- var todd = ds_main_cond.getColumn(0, 'todd');
-
- if(fromdd == '' || todd == ''){
- sysf_messageBox('보고일자를 확인하십시오.', 'I');
- return;
- }
- dsf_createDsRow('ds_send', [
- { col: 'wardcd', type: 'string', size: 256, val: wardcd },
- { col: 'fromdd', type: 'string', size: 256, val: fromdd },
- { col: 'todd', type: 'string', size: 256, val: todd }
- ], false);
-
- // 욕창발생보고서 조회
- ds_out_detlgruplist.clearData();
- ds_out_detlgruplist.addRow();
-
- var oParam = {};
- oParam.id = "TRMNW13801";
- oParam.service = "wardcareapp.WardCareRec";
- oParam.method = "reqGetDetlRptList";
- oParam.inds = "req=ds_send";
- oParam.outds = "ds_out_detlgruplist=detlgruplist";
- oParam.async = false;
- oParam.callback = "cf_TRMNW13801";
- tranf_submit(oParam);
-
- dsf_setDefaultVal(ds_out_detlgruplist, "deptcnfmyn:false");
- //그리드변경시 update 상태파악 위한 노드백업
-
- ds_hidden_main_detlgrupinfo_detlgruplist.copyData(ds_out_detlgruplist);
-
- grdf_setGridSort(group2.grd_detlgruplist);
-
- ds_out_detlgruplist.rowposition = -1;
- //model.copyNode("/root/hidden/main/detlgrupinfo", "/root/main/detlgrupinfo");
- }
- /****************************************************************************************
- * Argument : N/A
- * Description : cf_TRMNW13801
- ****************************************************************************************/
- function cf_TRMNW13801(sSvcId, nErrorCode, sErrorMsg) {
- if(nErrorCode < 0){
- sysf_messageBox('욕창발생 보고서 조회를', 'E009');
- return;
- }
- }
- /****************************************************************************************
- * Argument : N/A
- * Description : fSaveCnfmChk
- ****************************************************************************************/
- function fSaveCnfmChk(){
- if(!fIsValid()){
- return false;
- }
-
- if(sysf_messageBox('', 'Q002') != 6){
- return false;
- }
-
-
- // 병동코드
- var wardcd = ds_main_cond.getColumn(0, 'wardcd');
- // 조회시작일자
- var fromdd = ds_main_cond.getColumn(0, 'fromdd');
- // 조회종료일자
- var todd = ds_main_cond.getColumn(0, 'todd');
-
- dsf_createDsRow('ds_cond', [
- { col: 'wardcd', type: 'string', size: 256, val: wardcd },
- { col: 'fromdd', type: 'string', size: 256, val: fromdd },
- { col: 'todd', type: 'string', size: 256, val: todd }
- ], false);
-
- var updated = grdf_getGridUpdateData(group2.grd_detlgruplist);
- grdf_setStatusColumn(updated, 'stat');
- ds_tmp_detlgruplist.copyData(updated, false);
-
- if( utlf_isNull(ds_tmp_detlgruplist.getColumnInfo("stageid")) ){
- ds_tmp_detlgruplist.addColumn("stageid", "string");
- }
-
- var oParam = {};
- oParam.id = "TXMNW13801";
- oParam.service = "wardcareapp.WardCareRec";
- oParam.method = "reqExeDetlRptList";
- oParam.inds = "cond=ds_cond detlgrup=ds_out_detlgruplist";
- oParam.outds = "ds_out_detlgruplist=detlgruplist";
- oParam.async = false;
- oParam.callback = "cf_TXMNW13801";
- tranf_submit(oParam);
-
- dsf_setDefaultVal(ds_out_detlgruplist, "deptcnfmyn:false");
-
- ds_hidden_main_detlgrupinfo_detlgruplist.copyData(ds_out_detlgruplist);
-
- ds_out_detlgruplist.rowposition = -1;
- // 그리드변경시 update 상태파악 위한 노드백업
- //model.copyNode("/root/hidden/main/detlgrupinfo", "/root/main/detlgrupinfo");
- }
- /****************************************************************************************
- * Argument : N/A
- * Description : cf_TXMNW13801
- ****************************************************************************************/
- function cf_TXMNW13801(sSvcId, nErrorCode, sErrorMsg) {
- if(nErrorCode < 0){
- sysf_messageBox('부서확인 저장을', 'E009');
- return;
- }
- }
- /****************************************************************************************
- * Argument : N/A
- * Description : fIsValid
- ****************************************************************************************/
- function fIsValid(){
- // 그리드 저장데이터 존재여부 체크(default rows = 2)
- if(ds_out_detlgruplist.rowcount < 1){
- sysf_messageBox('저장할 내역이', 'I004');
- return false;
- }
-
- // 그리드 변경데이터 존재여부 체크
- if(grdf_getGridUpdateData(group2.grd_detlgruplist, 'update') == ''){
- sysf_messageBox('변경된 내역이', 'I004');
- return false;
- }
- return true;
- }
- /****************************************************************************************
- * Argument : N/A
- * Description : fDel
- ****************************************************************************************/
- function fDel(){
- // 삭제할 항목이 선택되었는지 여부를 체크
- var delFlag = false; //체크박스 체크여부
- var sel = ''; //체크박스(true/false)
- var stat = ''; //그리드상태(i/u/d)
-
- // for(var i = 0; i < ds_out_detlgruplist.rowcount; i++){
- // sel =
- // }
- if(ds_out_detlgruplist.findRow('sel', 'true') < 0){
- sysf_messageBox('삭제할 항목을', 'C002');
- return;
- }
-
- if(sysf_messageBox('욕창발생보고를', 'Q001') == 7){
- return;
- }
-
-
- ds_tmp_detlgruplist.clearData();
-
- for(var i = 0; i < ds_out_detlgruplist.rowcount; i++){
- if(ds_out_detlgruplist.getColumn(i, 'sel') == 'true'){
- var idx = ds_tmp_detlgruplist.addRow();
- var result = ds_tmp_detlgruplist.copyRow(idx, ds_out_detlgruplist, i);
- //ds_tmp_detlgruplist.setRowType(idx, Dataset.ROWTYPE_DELETE);
- ds_tmp_detlgruplist.setColumn(idx, 'stat', 'd');
- }
- }
-
- ds_out_detlgruplist.clearData();
- ds_out_detlgruplist.addRow();
-
- // 병동코드
- var wardcd = ds_main_cond.getColumn(0, 'wardcd');
- // 조회시작일자
- var fromdd = ds_main_cond.getColumn(0, 'fromdd');
- // 조회종료일자
- var todd = ds_main_cond.getColumn(0, 'todd');
-
- dsf_createDsRow('ds_cond', [
- { col: 'wardcd', type: 'string', size: 256, val: wardcd },
- { col: 'fromdd', type: 'string', size: 256, val: fromdd },
- { col: 'todd', type: 'string', size: 256, val: todd }
- ], false);
-
- var oParam = {};
- oParam.id = "TXMNW13801";
- oParam.service = "wardcareapp.WardCareRec";
- oParam.method = "reqExeDetlRptList";
- oParam.inds = "cond=ds_cond detlgrup=ds_tmp_detlgruplist";
- oParam.outds = "ds_out_detlgruplist=detlgruplist";
- oParam.async = false;
- //oParam.callback = "cf_TXMNW13801";
- tranf_submit(oParam);
-
- dsf_setDefaultVal(ds_out_detlgruplist, "deptcnfmyn:false");
-
- ds_hidden_main_detlgrupinfo_detlgruplist.copyData(ds_out_detlgruplist);
-
- ds_out_detlgruplist.rowposition = -1;
- }
- /****************************************************************************************
- * Argument : N/A
- * Description : fOpenPopUp
- ****************************************************************************************/
- function fOpenPopUp(){
- if(ds_out_detlgruplist.rowcount > 0){
- ds_tmp_detlgruplist.clearData();
- ds_tmp_detlgruplist.addRow();
- ds_tmp_detlgruplist.copyRow(0, ds_out_detlgruplist, group2.grd_detlgruplist.currentrow);
- var objArgs = new Object();
- objArgs.args_ds_init_detlgruplist = ds_tmp_detlgruplist;
-
- frmf_setParameter('ScreenId', 'SMMNW13800');
-
- frmf_modal("SPMNW04704", "SPMNW04704", objArgs, null, null, null, null, null, null, null, null, null, 'M');
- }
- }
- /****************************************************************************************
- * Argument : N/A
- * Description : fExecPrint
- ****************************************************************************************/
- function fExecPrint(){
- var objDOM = rptf_createDOM();
-
- ds_tmp_detlgruplist.clearData();
- ds_tmp_detlgruplist.copyData(ds_out_detlgruplist);
-
- if( utlf_isNull(ds_tmp_detlgruplist.getColumnInfo("stageid")) ){
- ds_tmp_detlgruplist.addColumn("stageid", "string");
- }
-
- for(var i = 0; i < ds_tmp_detlgruplist.rowcount; i++){
- // 부서장확인 값을 boolean -> Y/N 변경
- ds_tmp_detlgruplist.setColumn(i, "deptcnfmyn", (ds_tmp_detlgruplist.getColumn(i, "deptcnfmyn") == "true") ? "Y" : "N");
- ds_tmp_detlgruplist.setColumn(i, "stage", group2.grd_detlgruplist.getCellText(i, group2.grd_detlgruplist.getBindCellIndex("body","stage") ));
- }
- rptf_setNodeListToDOM(objDOM, "/root/send/printdata/detlgrupinfo/detlgruplist" , ds_tmp_detlgruplist);
-
- var objParam = new Object();
- objParam.xml_data_XML1 = objDOM.documentElement.source;
-
- var option = "open=1;save=1;directprint=1;printdialog=0;print=1;zoom=0";
- rptf_exeReportPreview30(["RPMNW13800"],[objParam], option);
-
- }
- function fChangedGridCol(){
- var sDetlGrupRow = group2.grd_detlgruplist.currentrow;
- var sDetlGrupBKRow=-1;
- var iRow = group2.grd_detlgruplist.currentrow;
- var iCol = group2.grd_detlgruplist.currentcol;
-
- var stat = mainDetlGrupGridPath.getColumn(group2.grd_detlgruplist.currentrow, "stat");
- //데이터 변경시 그리드 상태값(stat)을 u상태로 변경한다.
- if(stat == "-"){
- //그리드의 stat update를 위한 비교할 hidden nodelist의 idx찾기
- var obsrecrptseq = mainDetlGrupGridPath.getColumn(sDetlGrupRow, "obsrecrptseq");
- for(var i=0; i< tempDetlGrupGridPath.rowcount ; i++){
- if(tempDetlGrupGridPath.getColumn(i, "obsrecrptseq") == obsrecrptseq){
- sDetlGrupBKRow = i;
- break;
- }
- }
- //체크박스 선택 아닐때 조회해서 hidden에 담아둔 nodelist와 변경된 그리드의 nodelist의 stat를 비교하여 수정상태로 바꿔준다.
-
- //if(iCol != 8){// 선택시 stat 값 변경 않기
- if(iCol != group2.grd_detlgruplist.getBindCellIndex("body", "sel")){// 선택시 stat 값 변경 않기
- for( var i=0 ; i<mainDetlGrupGridPath.getColCount() ; i++ ){
- var sColId = mainDetlGrupGridPath.getColID(i);
-
- if( mainDetlGrupGridPath.getColumn(sDetlGrupRow, sColId) != tempDetlGrupGridPath.getColumn(sDetlGrupBKRow, sColId) ){
- mainDetlGrupGridPath.setColumn(group2.grd_detlgruplist.currentrow, "stat", "u");
-
- break;
- }
- }
- // var preUpdatedStr = instance1.selectSingleNode(tempDetlGrupGridPath+"["+sDetlGrupBKRow+"]").xml;
- // var updatedStr = instance1.selectSingleNode(mainDetlGrupGridPath+"["+sDetlGrupRow+"]").xml;
- //
- // if(updatedStr != preUpdatedStr){
- // model.setValue(mainDetlGrupGridPath+"["+(grd_detlgruplist.row-1)+"]/stat","u");
- // }
-
- //var preUnderAngle = model.getValue(xClsListBKPath+"["+sDetlGrupBKRow+"]/underangle");
- //var updateUnerAngle = model.getValue(xBedsoreGridPath+"["+ sDetlGrupRow +"]/underangle");
-
- //if(preUnderAngle != updateUnerAngle) {
- // model.setValue(xBedsoreGridPath+"["+(grd_detlgrup.row-1)+"]/stat2","u");
- //}
- }
- }
- }
- //=======================================================================================
- // Events
- //---------------------------------------------------------------------------------------
- /****************************************************************************************
- * Argument : N/A
- * Description : oninit
- ****************************************************************************************/
- function SMMNW13800_oninit(obj:Form, e:InitEventInfo){
-
- }
- /****************************************************************************************
- * Argument : N/A
- * Description : onload
- ****************************************************************************************/
- function SMMNW13800_onload(obj:Form, e:LoadEventInfo){
- // 폼 초기화
- frmf_initForm(obj);
- fInit();
- }
- /****************************************************************************************
- * Argument : N/A
- * Description : 병동 콤보 아이템 변경 이벤트
- ****************************************************************************************/
- function grp_sea_cmb_wardcd_onitemchanged(obj:Combo, e:ItemChangeEventInfo){
- fSearch(); // 조회
- }
- /****************************************************************************************
- * Argument : N/A
- * Description : 보고일자 from 포커스 상실 이벤트
- ****************************************************************************************/
- function grp_sea_input23_onchanged(obj:Calendar, e:ChangeEventInfo){
- fSearch();
- }
- /****************************************************************************************
- * Argument : N/A
- * Description : 보고일자 to 포커스 상실 이벤트
- ****************************************************************************************/
- function grp_sea_input1_onchanged(obj:Calendar, e:ChangeEventInfo){
- fSearch();
- }
- /****************************************************************************************
- * Argument : N/A
- * Description : 조회버튼 클릭 이벤트
- ****************************************************************************************/
- function grp_sea_btn_srchdschtpatlist_onclick(obj:Button, e:ClickEventInfo){
- fSearch();
- }
- /****************************************************************************************
- * Argument : N/A
- * Description : 엑셀버튼 클릭 이벤트
- ****************************************************************************************/
- function grp_sea_button2_onclick(obj:Button, e:ClickEventInfo){
- var filenm = '욕창발생보고_' + utlf_getCurrentDate();
- grdf_exportExcel(group2.grd_detlgruplist, filenm, "SheetName1", true, "", "user", true);
- }
- /****************************************************************************************
- * Argument : N/A
- * Description : 출력버튼 클릭 이벤트
- ****************************************************************************************/
- function grp_sea_button1_onclick(obj:Button, e:ClickEventInfo){
- fExecPrint();
- }
- /****************************************************************************************
- * Argument : N/A
- * Description : 삭제버튼 클릭 이벤트
- ****************************************************************************************/
- function group2_btn_delt_onclick(obj:Button, e:ClickEventInfo){
- fDel();
- }
- /****************************************************************************************
- * Argument : N/A
- * Description : 저장버튼 클릭 이벤트
- ****************************************************************************************/
- function group2_btn_savedschresn_onclick(obj:Button, e:ClickEventInfo){
- fSaveCnfmChk();
- }
- /****************************************************************************************
- * Argument : N/A
- * Description : 데이터셋 컬럼 변경 이벤트
- ****************************************************************************************/
- function ds_out_detlgruplist_oncolumnchanged(obj:Dataset, e:DSColChangeEventInfo){
- if(e.columnid == 'sel' || e.columnid == 'deptcnfmyn'){
- obj.setColumn(e.row, e.columnid, (e.newvalue == 'true' || e.newvalue == '1') ? 'true' : 'false');
- }
-
- fChangedGridCol();
- }
- /****************************************************************************************
- * Argument : N/A
- * Description : 그리드 더블클릭 이벤트
- ****************************************************************************************/
- function group2_grd_detlgruplist_oncelldblclick(obj:Grid, e:GridClickEventInfo){
- fOpenPopUp();
- }
- ]]></Script>
- </Form>
- </FDL>
|