123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846 |
- <?xml version="1.0" encoding="utf-8" standalone="no"?>
- <FDL version="1.5">
- <TypeDefinition url="..\..\..\default_typedef.xml"/>
- <Form id="SPPID21500" position="absolute 0 0 963 654" titletext="외래미시행오더상병관리" oninit="SPPID21500_oninit" onload="SPPID21500_onload">
- <Layouts>
- <Layout>
- <Static id="caption6" text="상병관리" class="tit_1" position="absolute 0 0 196 23"/>
- <Button id="btn_init" taborder="3" text="저장" class="btn2" position="absolute 913 25 955 44" onclick="btn_init_onclick"/>
- <Shape id="line1" class="line_10" position="absolute 0 44 450 55"/>
- <Grid id="grd_orddiaghist" taborder="4" binddataset="ds_main_diaghist_list01_mmohdiag1" useinputpanel="false" position="absolute 0 51 450 622" autofittype="col" cellsizingtype="col">
- <Formats>
- <Format id="default">
- <Columns>
- <Column size="25"/>
- <Column size="35"/>
- <Column size="54"/>
- <Column size="135"/>
- <Column size="75"/>
- <Column size="80"/>
- <Column size="40"/>
- <Column size="0"/>
- </Columns>
- <Rows>
- <Row size="23" band="head"/>
- <Row size="23"/>
- </Rows>
- <Band id="head">
- <Cell/>
- <Cell col="1" text="R/O"/>
- <Cell col="2" text="상병코드"/>
- <Cell col="3" text="상병명(한글)"/>
- <Cell col="4" text="과"/>
- <Cell col="5" text="진료일자"/>
- <Cell col="6" text="치식"/>
- <Cell col="7" text="보험유형"/>
- </Band>
- <Band id="body">
- <Cell celltype="head" expr="currow+1"/>
- <Cell col="1" displaytype="checkbox" edittype="checkbox" text="bind:diagkindcd" expr="expr:diagkindcd == 'true' ? 1 : 0"/>
- <Cell col="2" text="bind:diagcd"/>
- <Cell col="3" text="bind:diaghngnm"/>
- <Cell col="4" displaytype="combo" edittype="combo" text="bind:orddeptcd" combodataset="ds_list2_dept" combocodecol="deptcd" combodatacol="depthngnm"/>
- <Cell col="5" displaytype="date" text="bind:orddd" mask="yyyy/MM/dd"/>
- <Cell col="6" text="bind:toot"/>
- <Cell col="7" text="bind:insukind"/>
- </Band>
- </Format>
- </Formats>
- </Grid>
- <Static id="caption5" text="진료상병" class="tit_2" position="absolute 0 30 105 51"/>
- <Grid id="grd_diaglist" taborder="5" binddataset="ds_main_diaghist_list02_mmohdiag2" useinputpanel="false" position="absolute 455 51 955 622" onstartedit="grp_biz_grd_diaglist_onstartedit" oncolumnchanged="grp_biz_grd_diaglist_oncolumnchanged" oncelldblclick="grd_diaglist_oncelldblclick" autofittype="col" cellsizingtype="col">
- <Formats>
- <Format id="default">
- <Columns>
- <Column size="22"/>
- <Column size="22"/>
- <Column size="31"/>
- <Column size="54"/>
- <Column size="135"/>
- <Column size="75"/>
- <Column size="86"/>
- <Column size="0"/>
- <Column size="0"/>
- <Column size="50"/>
- <Column size="0"/>
- <Column size="0"/>
- <Column size="0"/>
- <Column size="0"/>
- <Column size="0"/>
- <Column size="0"/>
- <Column size="0"/>
- <Column size="0"/>
- <Column size="0"/>
- </Columns>
- <Rows>
- <Row size="24" band="head"/>
- <Row size="24"/>
- </Rows>
- <Band id="head">
- <Cell/>
- <Cell col="1" text="S"/>
- <Cell col="2" text="R/O"/>
- <Cell col="3" text="상병코드"/>
- <Cell col="4" text="상 병 명"/>
- <Cell col="5" text="과"/>
- <Cell col="6" text="진료개시일"/>
- <Cell col="7" text="치"/>
- <Cell col="8" text="치식EDI"/>
- <Cell col="9" text="치식"/>
- <Cell col="10" text="pid"/>
- <Cell col="11" text="seqno"/>
- <Cell col="12" text="cretno"/>
- <Cell col="13" text="orddd"/>
- <Cell col="14" text="addflag"/>
- <Cell col="15" text="drinptyn"/>
- <Cell col="16" text="rowstat"/>
- <Cell col="17" text="orddeptcdkey"/>
- <Cell col="18" text="보험유형"/>
- <Cell col="19" text="drinptyn"/>
- <Cell col="20" text="addflag"/>
- <Cell col="21" text="mskind"/>
- </Band>
- <Band id="body">
- <Cell celltype="head"/>
- <Cell col="1" text="bind:diagseq" expr="currow+1"/>
- <Cell col="2" displaytype="checkbox" edittype="checkbox" text="bind:ruleoutyn" expr="expr:ruleoutyn == 'Y' ? 1 : 0"/>
- <Cell col="3" edittype="normal" text="bind:diagcd"/>
- <Cell col="4" edittype="normal" style="align:left middle;" text="bind:diagnm"/>
- <Cell col="5" displaytype="combo" edittype="combo" text="bind:diagorddeptcd" combodataset="ds_list2_dept" combocodecol="deptcd" combodatacol="depthngnm"/>
- <Cell col="6" displaytype="date" edittype="date" text="bind:ordfromdd" mask="yyyy/MM/dd"/>
- <Cell col="7" text="bind:toothyn"/>
- <Cell col="8" text="bind:toot"/>
- <Cell col="9" text="bind:toot1"/>
- <Cell col="10" text="bind:pid"/>
- <Cell col="11" text="bind:seqno"/>
- <Cell col="12" text="bind:cretno"/>
- <Cell col="13" text="bind:orddd"/>
- <Cell col="14" text="bind:addflag"/>
- <Cell col="15" text="bind:drinptyn"/>
- <Cell col="16" text="bind:rowstat"/>
- <Cell col="17" text="bind:orddeptcd"/>
- <Cell col="18" text="bind:insukind"/>
- </Band>
- </Format>
- </Formats>
- </Grid>
- <Static id="caption87" text="상병" onclick="grp_biz_caption87_onclick" class="tit_2" position="absolute 455 30 547 51"/>
- <Shape id="line34" class="line_10" position="absolute 455 44 955 55"/>
- <Button id="btn_close" taborder="7" text="닫기" class="btn4" position="absolute 900 626 956 648" onclick="btn_close_onclick"/>
- <Shape id="line9" class="line_6" position="absolute 0 624 952 627"/>
- </Layout>
- </Layouts>
- <Objects>
- <Dataset id="ds_send" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
- <Dataset id="ds_main_diaghist_list01_mmohdiag1" firefirstcount="0" firenextcount="0" useclientlayout="true" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false" oncolumnchanged="ds_main_diaghist_list01_mmohdiag1_oncolumnchanged">
- <ColumnInfo>
- <Column id="diagkindcd" type="STRING" size="256" sumtext="R/O"/>
- <Column id="diagcd" type="STRING" size="256" sumtext="상병코드"/>
- <Column id="diaghngnm" type="STRING" size="256" sumtext="상병명(한글)"/>
- <Column id="orddeptcd" type="STRING" size="256" sumtext="진료과"/>
- <Column id="orddd" type="STRING" size="256" sumtext="진료과"/>
- <Column id="tootfact" type="STRING" size="256" sumtext="치식내용"/>
- <Column id="insukind" type="STRING" size="256" sumtext="보험유형"/>
- <Column id="toot" type="STRING" size="256"/>
- <Column id="toot1" type="STRING" size="256"/>
- </ColumnInfo>
- </Dataset>
- <Dataset id="ds_main_diaghist_list02_mmohdiag2" firefirstcount="0" firenextcount="0" useclientlayout="true" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false" oncolumnchanged="ds_main_diaghist_list02_mmohdiag2_oncolumnchanged">
- <ColumnInfo>
- <Column id="diagseq" type="STRING" size="256" sumtext="일련번호"/>
- <Column id="seqno" type="STRING" size="256" sumtext="일련번호"/>
- <Column id="ruleoutyn" type="STRING" size="256" sumtext="처방코드"/>
- <Column id="diagcd" type="STRING" size="256" sumtext="상병코드"/>
- <Column id="diagnm" type="STRING" size="256" sumtext="상병명"/>
- <Column id="orddeptcd" type="STRING" size="256" sumtext="진료과"/>
- <Column id="ordfromdd" type="STRING" size="256" sumtext="진료개시일"/>
- <Column id="toothyn" type="STRING" size="256" sumtext="치식여부"/>
- <Column id="toot" type="STRING" size="256" sumtext="치식EDI"/>
- <Column id="toot1" type="STRING" size="256" sumtext="치식"/>
- <Column id="pid" type="STRING" size="256" sumtext="등록번호"/>
- <Column id="orddd" type="STRING" size="256" sumtext="진료일자"/>
- <Column id="addflag" type="STRING" size="256" sumtext="추가구분"/>
- <Column id="drinptyn" type="STRING" size="256" sumtext="의사입력여부"/>
- <Column id="rowstat" type="STRING" size="256" sumtext="상태"/>
- <Column id="diagorddeptcd" type="STRING" size="256" sumtext="상병별 진료과"/>
- <Column id="insukind" type="STRING" size="256" sumtext="보험유형"/>
- <Column id="cretno" type="STRING" size="256" sumtext="생성번호"/>
- </ColumnInfo>
- </Dataset>
- <Dataset id="ds_list2_dept" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
- <ColumnInfo>
- <Column id="depthngnm" type="STRING" size="256"/>
- <Column id="deptcd" type="STRING" size="256"/>
- </ColumnInfo>
- </Dataset>
- <Dataset id="ds_hidden_sppiz00600_cond" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
- <ColumnInfo>
- <Column id="pid" type="STRING" size="256"/>
- <Column id="toot" type="STRING" size="256"/>
- <Column id="clamym" type="STRING" size="256"/>
- <Column id="clamdg" type="STRING" size="256"/>
- <Column id="pidsn" type="STRING" size="256"/>
- </ColumnInfo>
- <Rows>
- <Row/>
- </Rows>
- </Dataset>
- <Dataset id="ds_hidden_sppiz00600_rslt" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
- <Dataset id="ds_hidden_sppiz00600_cond_list_toothapplist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
- <ColumnInfo>
- <Column id="chos" type="STRING" size="256"/>
- </ColumnInfo>
- </Dataset>
- <Dataset id="ds_hidden_sppiz00400_rslt" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
- <ColumnInfo>
- <Column id="diagcd" type="STRING" size="256"/>
- <Column id="diagengnm" type="STRING" size="256"/>
- <Column id="diaghngnm" type="STRING" size="256"/>
- </ColumnInfo>
- </Dataset>
- <Dataset id="ds_hidden_sppiz00400_cond" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
- <ColumnInfo>
- <Column id="basedd" type="STRING" size="256"/>
- <Column id="diagcd" type="STRING" size="256"/>
- <Column id="diagnm" type="STRING" size="256"/>
- <Column id="selectedrdodiagkind" type="STRING" size="256"/>
- </ColumnInfo>
- <Rows>
- <Row/>
- </Rows>
- </Dataset>
- </Objects>
- <Bind/>
- <Script type="xscript4.0"><![CDATA[/***************************************************************************************
- * System Name :
- * Job Name :
- * Creator :
- * Make Date : 2015-05-01
- * Description :
- *---------------------------------------------------------------------------------------
- * Modify Date Modifier Modify Description
- *---------------------------------------------------------------------------------------
- * 2015-05-01 Live Converter TF->XP
- *
- *---------------------------------------------------------------------------------------
- ****************************************************************************************/
- include "com_commonxp::comm_main.xjs";
- function SPPID21500_oninit(obj:Form, e:InitEventInfo)
- {
- frmf_initForm(obj);
- }
- function SPPID21500_onload(obj:Form, e:LoadEventInfo)
- {
- grdf_initGrid(grd_orddiaghist);
- grdf_initGrid(grd_diaglist);
-
- grdf_setRowTypeIcon(grd_diaglist, 0);
-
- fInitialize();
-
- var oParam = {};
- oParam.id = "TRPID21502";
- oParam.service = "aftjudgapp.OutUnExecOrd";
- oParam.method = "reqGetPatIODiagHistList";
- oParam.inds = "req=ds_send";
- oParam.outds = "ds_main_diaghist_list01_mmohdiag1=mmohdiag1";
- oParam.async = false;
- //oParam.callback = "cf_TRPID21502";
- tranf_submit(oParam);
- var oParam = {};
- oParam.id = "TRPID21501";
- oParam.service = "aftjudgapp.OutUnExecOrd";
- oParam.method = "reqGetDiagHistList";
- oParam.inds = "req=ds_send";
- oParam.outds = "ds_main_diaghist_list02_mmohdiag2=mmohdiag2";
- oParam.async = false;
- //oParam.callback = "cf_TRPID21501";
- tranf_submit(oParam);
-
- list01cnt = ds_main_diaghist_list01_mmohdiag1.rowcount;
- list02cnt = ds_main_diaghist_list02_mmohdiag2.rowcount;
-
- var check = "";
-
- for (var i = 0; i < list01cnt ; i++)
- {
- check = "false";
-
- var ruleoutyn = ds_main_diaghist_list01_mmohdiag1.getColumn(i, "diagkindcd");
- var rdiagcd = ds_main_diaghist_list01_mmohdiag1.getColumn(i, "diagcd");
- var diaghngnm = ds_main_diaghist_list01_mmohdiag1.getColumn(i, "diaghngnm");
- var orddeptcd = ds_main_diaghist_list01_mmohdiag1.getColumn(i, "orddeptcd");
- var orddd = ds_main_diaghist_list01_mmohdiag1.getColumn(i, "orddd");
- var toot = ds_main_diaghist_list01_mmohdiag1.getColumn(i, "toot");
- var toot1 = ds_main_diaghist_list01_mmohdiag1.getColumn(i, "toot1");
- var insukind = ds_main_diaghist_list01_mmohdiag1.getColumn(i, "insukind");
-
- for (var j = 0; j < list02cnt ; j++)
- {
- var fdiagcd = ds_main_diaghist_list02_mmohdiag2.getColumn(j, "diagcd");
-
- if (rdiagcd == fdiagcd)
- {
- check = "true";
- }
- }
-
- if (check == "false")
- {
- fDiagGridInsertRow(false);
-
- var row = ds_main_diaghist_list02_mmohdiag2.rowcount-1;
- ds_main_diaghist_list02_mmohdiag2.setColumn(row, "ruleoutyn", ruleoutyn);
- ds_main_diaghist_list02_mmohdiag2.setColumn(row, "diagcd", rdiagcd);
- ds_main_diaghist_list02_mmohdiag2.setColumn(row, "diagnm", diaghngnm);
- ds_main_diaghist_list02_mmohdiag2.setColumn(row, "orddeptcd", orddeptcd);
- ds_main_diaghist_list02_mmohdiag2.setColumn(row, "diagorddeptcd", orddeptcd);
- ds_main_diaghist_list02_mmohdiag2.setColumn(row, "ordfromdd", orddd);
- ds_main_diaghist_list02_mmohdiag2.setColumn(row, "insukind", insukind);
- ds_main_diaghist_list02_mmohdiag2.setColumn(row, "rowstat", "I");
-
- if (utlf_isNull(toot))
- {
- ds_main_diaghist_list02_mmohdiag2.setColumn(row, "toothyn", "N");
- ds_main_diaghist_list02_mmohdiag2.setColumn(row, "toot", "-");
- ds_main_diaghist_list02_mmohdiag2.setColumn(row, "toot1", "");
- }
- else
- {
- ds_main_diaghist_list02_mmohdiag2.setColumn(row, "toothyn", "Y");
- ds_main_diaghist_list02_mmohdiag2.setColumn(row, "toot", toot);
- ds_main_diaghist_list02_mmohdiag2.setColumn(row, "toot1", toot1);
- }
- }
- }
- fDiagGridInsertRow(false);
- }
- function fInitialize()
- {
- if (frmf_checkOpener())
- {
- if(arg_ds_send)
- {
- ds_send.copyData(arg_ds_send);
- }
- }
-
- dsf_createDsRow("ds_req", [{col:"insucd", type:"STRING", size:256 , val : ""}
- , {col:"ordfromdd", type:"STRING", size:256 , val : ""}
- , {col:"basedd", type:"STRING", size:256 , val : ds_send.getColumn(0, "orddd")}]);
- var oParam = {};
- oParam.id = "TRPIJ00305";
- oParam.service = "bfjudgapp.InHospJudg";
- oParam.method = "reqGetDeptList";
- oParam.inds = "req=ds_req";
- oParam.outds = "ds_list2_dept=dept";
- oParam.async = false;
- //oParam.callback = "cf_TRPIJ00305";
- tranf_submit(oParam);
- }
- function fDiagGridInsertRow(flag)
- {
- if (ds_main_diaghist_list02_mmohdiag2.getRowType(0) == 8)
- {
- var diagrow = ds_main_diaghist_list02_mmohdiag2.addRow();
-
- ds_main_diaghist_list02_mmohdiag2.setColumn(diagrow, "diagseq", diagrow);
-
- fSortDiagNo();
- }
- else
- {
- var diagrow = ds_main_diaghist_list02_mmohdiag2.addRow();
-
- ds_main_diaghist_list02_mmohdiag2.setColumn(diagrow, "diagseq", diagrow);
- ds_main_diaghist_list02_mmohdiag2.setColumn(diagrow, "pid", ds_send.getColumn(0, "pid"));
- ds_main_diaghist_list02_mmohdiag2.setColumn(diagrow, "orddd", ds_send.getColumn(0, "orddd"));
- ds_main_diaghist_list02_mmohdiag2.setColumn(diagrow, "orddeptcd", ds_send.getColumn(0, "deptcd"));
- ds_main_diaghist_list02_mmohdiag2.setColumn(diagrow, "diagorddeptcd", ds_send.getColumn(0, "deptcd"));
- ds_main_diaghist_list02_mmohdiag2.setColumn(diagrow, "insukind", ds_send.getColumn(0, "insukind"));
- ds_main_diaghist_list02_mmohdiag2.setColumn(diagrow, "ruleoutyn", "false");
- ds_main_diaghist_list02_mmohdiag2.setColumn(diagrow, "toothyn", "N");
- ds_main_diaghist_list02_mmohdiag2.setColumn(diagrow, "toot", "-");
- ds_main_diaghist_list02_mmohdiag2.setColumn(diagrow, "toot1", "");
- ds_main_diaghist_list02_mmohdiag2.setColumn(diagrow, "addflag", "Y");
- ds_main_diaghist_list02_mmohdiag2.setColumn(diagrow, "drinptyn", "N");
- ds_main_diaghist_list02_mmohdiag2.setColumn(diagrow, "cretno", ds_send.getColumn(0, "cretno"));
- ds_main_diaghist_list02_mmohdiag2.setColumn(diagrow, "ordfromdd", ds_send.getColumn(0, "orddd"));
- ds_main_diaghist_list02_mmohdiag2.setColumn(diagrow, "rowstat", "I");
-
- if (flag == true)
- {
- fSortDiagNo();
- }
- }
- }
- function fSortDiagNo()
- {
- if (ds_main_diaghist_list02_mmohdiag2.rowcount > 0)
- {
- for (var j = ds_main_diaghist_list02_mmohdiag2.rowcount; j > 0; j--)
- {
- var rowstatus = ds_main_diaghist_list02_mmohdiag2.getRowType(j);
- var diagcd = ds_main_diaghist_list02_mmohdiag2.getColumn(j, "diagcd");
- var diagnm = ds_main_diaghist_list02_mmohdiag2.getColumn(j, "diagnm");
-
- if (rowstatus != 8 && utlf_isNull(diagcd) && utlf_isNull(diagnm))
- {
- ds_main_diaghist_list02_mmohdiag2.deleteRow(j);
- }
- }
-
- var maxRow = parseInt(ds_main_diaghist_list02_mmohdiag2.rowcount);
- }
- }
- function btn_close_onclick(obj:Button, e:ClickEventInfo)
- {
- this.close();
- }
- function grd_diaglist_oncelldblclick(obj:Grid, e:GridClickEventInfo)
- {
- var row = e.row;
-
- if (row > -1)
- {
- var col = e.col;
-
- if (col == grd_diaglist.getBindCellIndex("Body", "diagcd") || col == grd_diaglist.getBindCellIndex("Body", "diagnm"))
- {
- fSearchDiageCode();
- }
- else if (col == grd_diaglist.getBindCellIndex("Body", "toot1"))
- {
- var row = e.row;
- var diagcd = ds_main_diaghist_list02_mmohdiag2.getColumn(row, "diagcd");
-
- if (diagcd)
- {
- ds_hidden_sppiz00600_cond.setColumn(0, "pid", ds_main_diaghist_list02_mmohdiag2.getColumn(row, "pid"));
- ds_hidden_sppiz00600_cond.setColumn(0, "toot", ds_main_diaghist_list02_mmohdiag2.getColumn(row, "toot"));
- ds_hidden_sppiz00600_cond.setColumn(0, "clamym", "");
- ds_hidden_sppiz00600_cond.setColumn(0, "clamdg", "");
- ds_hidden_sppiz00600_cond.setColumn(0, "pidsn", "");
-
- fSetToothPop(row, "1");
-
- ds_hidden_sppiz00600_rslt.clearData();
-
- var objArg = new Object();
- objArg.arg_ds_hidden_cond= ds_hidden_sppiz00600_cond;
-
- frmf_modal("SPPIZ00600", "SPPIZ00600", objArg, "", "", "", "", "", "", "", "", "", "M");
-
- fGetToothPop();
- }
- }
- }
- }
- function fSetToothPop(row, flag)
- {
- ds_hidden_sppiz00600_cond_list_toothapplist.clearData();
-
- var cntcldi = ds_main_diaghist_list02_mmohdiag2.rowcount;
-
- var cd = "";
- var cdnm = "";
- var orddd = "";
- var toot = "";
- for (var i = 0; i < cntcldi; i++)
- {
- cd = ds_main_diaghist_list02_mmohdiag2.getColumn(i, "diagcd");
- cdnm = ds_main_diaghist_list02_mmohdiag2.getColumn(i, "diagnm");
- orddd = ds_main_diaghist_list02_mmohdiag2.getColumn(i, "ordfromdd");
- toot = ds_main_diaghist_list02_mmohdiag2.getColumn(i, "toot");
-
- var rowcnt = ds_hidden_sppiz00600_cond_list_toothapplist.addRow();
-
- if (toot != "-" && !utlf_isNull(toot))
- {
- dsf_makeValue(ds_hidden_sppiz00600_cond_list_toothapplist, "chos", "string", "", rowcnt);
- dsf_makeValue(ds_hidden_sppiz00600_cond_list_toothapplist, "flag", "string", "", rowcnt);
- dsf_makeValue(ds_hidden_sppiz00600_cond_list_toothapplist, "cd", "string", "", rowcnt);
- dsf_makeValue(ds_hidden_sppiz00600_cond_list_toothapplist, "cdnm", "string", "", rowcnt);
- dsf_makeValue(ds_hidden_sppiz00600_cond_list_toothapplist, "rightupper", "string", "", rowcnt);
- dsf_makeValue(ds_hidden_sppiz00600_cond_list_toothapplist, "leftupper", "string", "", rowcnt);
- dsf_makeValue(ds_hidden_sppiz00600_cond_list_toothapplist, "rightlower", "string", "", rowcnt);
- dsf_makeValue(ds_hidden_sppiz00600_cond_list_toothapplist, "leftlower", "string", "", rowcnt);
- dsf_makeValue(ds_hidden_sppiz00600_cond_list_toothapplist, "orddd", "string", "", rowcnt);
- dsf_makeValue(ds_hidden_sppiz00600_cond_list_toothapplist, "toot", "string", "", rowcnt);
- dsf_makeValue(ds_hidden_sppiz00600_cond_list_toothapplist, "row", "string", "", rowcnt);
-
- var milktoothstr = "ABCDE000";
- var subTootStr = "";
-
- for (var inx = 0; inx < 32; inx++)
- {
- var tootnum = toot.substr(inx,1);
- if (tootnum == "*")
- { // 선택된 영구치의 경우 1~8 사이 숫자로 표시한다.
- if (inx < 8)
- {
- subTootStr += (8 - inx);
- }
- else if (inx > 7 && inx < 16)
- {
- subTootStr += (inx - 7);
- }
- else if (inx > 15 && inx < 24)
- {
- subTootStr += (24 - inx);
- }
- else
- {
- subTootStr += (inx - 23);
- }
- }
- else if (tootnum == "#")
- {
- if (inx < 8)
- {
- subTootStr += milktoothstr.charAt(7 - inx);
- }
- else if (inx > 7 && inx < 16)
- {
- subTootStr += milktoothstr.charAt(inx - 8);
- }
- else if (inx > 15 && inx < 24)
- {
- subTootStr += milktoothstr.charAt(23 - inx);
- }
- else
- {
- subTootStr += milktoothstr.charAt(inx - 24);
- }
- }
- else
- {
- subTootStr += " ";
- }
- }
-
- if (row == i && flag == "1" )
- {
- ds_hidden_sppiz00600_cond_list_toothapplist.setColumn(rowcnt, "chos", "true");
- }
- else
- {
- ds_hidden_sppiz00600_cond_list_toothapplist.setColumn(rowcnt, "chos", "false");
- }
- ds_hidden_sppiz00600_cond_list_toothapplist.setColumn(rowcnt, "flag", "상병");
- ds_hidden_sppiz00600_cond_list_toothapplist.setColumn(rowcnt, "cd", cd);
- ds_hidden_sppiz00600_cond_list_toothapplist.setColumn(rowcnt, "cdnm", cdnm);
- ds_hidden_sppiz00600_cond_list_toothapplist.setColumn(rowcnt, "rightupper", String(rightupper).substr(0,8));
- ds_hidden_sppiz00600_cond_list_toothapplist.setColumn(rowcnt, "leftupper", String(rightupper).substr(8,8));
- ds_hidden_sppiz00600_cond_list_toothapplist.setColumn(rowcnt, "rightlower", String(rightupper).substr(16,8));
- ds_hidden_sppiz00600_cond_list_toothapplist.setColumn(rowcnt, "leftlower", String(rightupper).substr(24,8));
- ds_hidden_sppiz00600_cond_list_toothapplist.setColumn(rowcnt, "orddd", orddd);
- ds_hidden_sppiz00600_cond_list_toothapplist.setColumn(rowcnt, "toot", toot);
- ds_hidden_sppiz00600_cond_list_toothapplist.setColumn(rowcnt, "row", i);
- }
- else
- {
- if (row == i && flag == "1" )
- {
- dsf_makeValue(ds_hidden_sppiz00600_cond_list_toothapplist, "chos", "string", "true", rowcnt);
- dsf_makeValue(ds_hidden_sppiz00600_cond_list_toothapplist, "flag", "string", "상병", rowcnt);
- dsf_makeValue(ds_hidden_sppiz00600_cond_list_toothapplist, "cd", "string", cd, rowcnt);
- dsf_makeValue(ds_hidden_sppiz00600_cond_list_toothapplist, "cdnm", "string", cdnm, rowcnt);
- dsf_makeValue(ds_hidden_sppiz00600_cond_list_toothapplist, "rightupper", "string", "", rowcnt);
- dsf_makeValue(ds_hidden_sppiz00600_cond_list_toothapplist, "leftupper", "string", "", rowcnt);
- dsf_makeValue(ds_hidden_sppiz00600_cond_list_toothapplist, "rightlower", "string", "", rowcnt);
- dsf_makeValue(ds_hidden_sppiz00600_cond_list_toothapplist, "leftlower", "string", "", rowcnt);
- dsf_makeValue(ds_hidden_sppiz00600_cond_list_toothapplist, "orddd", "string", orddd, rowcnt);
- dsf_makeValue(ds_hidden_sppiz00600_cond_list_toothapplist, "toot", "string", "", rowcnt);
- dsf_makeValue(ds_hidden_sppiz00600_cond_list_toothapplist, "row", "string", i, rowcnt);
- }
- }
- }
- }
- function fGetToothPop()
- {
- var tootSelectcnt = ds_hidden_sppiz00600_rslt.rowcount;
-
- var flag = "";
- var row = "";
- var toot = "";
-
- tootSelectcnt = eval(tootSelectcnt) + 1;
-
- for (var i = 0; i < tootSelectcnt; i++)
- {
- flag = ds_hidden_sppiz00600_rslt.getColumn(i, "flag");
- row = ds_hidden_sppiz00600_rslt.getColumn(i, "row");
-
- var rlsttoot = ds_hidden_sppiz00600_rslt.getColumn(i, "toot");
- var rlsttoot1 = ds_hidden_sppiz00600_rslt.getColumn(i, "toot1");
-
- if (utlf_isNull(rlsttoot))
- {
- rlsttoot = "-";
- }
- if (utlf_isNull(rlsttoot1))
- {
- rlsttoot1 = "-";
- }
-
- if (flag == "1")
- {
- toot = ds_main_diaghist_list02_mmohdiag2.getColumn(row, "toot");
- ds_main_diaghist_list02_mmohdiag2.setColumn(row, "toot", rlsttoot);
- ds_main_diaghist_list02_mmohdiag2.setColumn(row, "toot1", rlsttoot1);
-
- if (rlsttoot != toot)
- {
- var cldistatus = ds_main_diaghist_list02_mmohdiag2.getRowType(row);
-
- if (cldistatus == 2 || cldistatus == 4)
- {
- ds_main_diaghist_list02_mmohdiag2.setRowType(row, "u");
- }
- }
- }
- }
- }
- function fSearchDiageCode()
- {
- ds_hidden_sppiz00400_rslt.clearData();
-
- var row = ds_main_diaghist_list02_mmohdiag2.rowposition;
- var rows = ds_main_diaghist_list02_mmohdiag2.rowcount;
- var diagcd = ds_main_diaghist_list02_mmohdiag2.getColumn(row, "diagcd");
-
- ds_hidden_sppiz00400_cond.setColumn(0, "basedd", utlf_getCurrentDate());
- ds_hidden_sppiz00400_cond.setColumn(0, "diagcd", diagcd);
- ds_hidden_sppiz00400_cond.setColumn(0, "diagnm", "");
- ds_hidden_sppiz00400_cond.setColumn(0, "selectedrdodiagkind", "1");
-
- if (diagcd)
- {
- var oParam = {};
- oParam.id = "TRPIJ00308";
- oParam.service = "aftjudgapp.OutAftJudg";
- oParam.method = "reqGetSickAndWounded";
- oParam.inds = "req=ds_hidden_sppiz00400_cond";
- oParam.outds = "ds_hidden_sppiz00400_rslt=rslt";
- oParam.async = false;
- //oParam.callback = "cf_TRPIJ00308";
- tranf_submit(oParam);
-
- var rsltList = ds_hidden_sppiz00400_rslt.rowcount;
-
- if (rsltList == 1)
- {
- fSetDiagCdNm();
- }
- else
- {
- fSearchSPPIZ00400();
- }
- }
- else
- {
- // 상병코드 입력 없이 상병명 선택 시
- fSearchSPPIZ00400();
- }
-
- var addrow = row + 1;
- if (addrow == rows)
- {
- var diagcd = ds_hidden_sppiz00400_rslt.getColumn(0, "diagcd");
-
- if (!utlf_isNull(diagcd))
- {
- fDiagGridInsertRow(false);
- }
- }
- }
- function btn_init_onclick(obj:Button, e:ClickEventInfo)
- {
- var diagnm = "";
- var orddeptcd = "";
- var rows = ds_main_diaghist_list02_mmohdiag2.rowcount;
- var row = rows - 1;
-
- for (var j = rows; j > 0; j--)
- {
- var rowstatus = ds_main_diaghist_list02_mmohdiag2.getRowType(j);
- var diagcd = ds_main_diaghist_list02_mmohdiag2.getColumn(j, "diagcd");
- var diagnm = ds_main_diaghist_list02_mmohdiag2.getColumn(j, "diagnm");
-
- if (rowstatus != 8 && utlf_isNull(diagcd) && utlf_isNull(diagnm))
- {
- ds_main_diaghist_list02_mmohdiag2.deleteRow(j);
- }
- }
-
- var updateData = grdf_getGridUpdateData(grd_diaglist).rowcount;
- if (updateData == 0)
- {
- sysf_messageBox("저장할 상병 정보가","I004","");
- fDiagGridInsertRow();
- return;
- }
-
- // 저장할 데이터가 올바른지 확인
- rows = ds_main_diaghist_list02_mmohdiag2.rowcount;
-
- for (var i = 0; i < rows; i++)
- {
- var diagstatus = ds_main_diaghist_list02_mmohdiag2.getRowType(i);
-
- diagseq = ds_main_diaghist_list02_mmohdiag2.getColumn(i, "diagseq");
- diagnm = ds_main_diaghist_list02_mmohdiag2.getColumn(i, "diagnm");
- orddeptcd = ds_main_diaghist_list02_mmohdiag2.getColumn(i, "orddeptcd");
-
- if (utlf_isNull(diagnm) && !utlf_isNull(orddeptcd))
- {
- sysf_messageBox("상병을 입력하여 주십시요!","E999","");
- return;
- }
- if (!utlf_isNull(diagnm) && utlf_isNull(orddeptcd))
- {
- sysf_messageBox("진료과를 선택해 주십시요!","E999","");
- return;
- }
- if (utlf_isNull(diagnm) && utlf_isNull(orddeptcd))
- {
- ds_main_diaghist_list02_mmohdiag2.setRowType(i, "");
- }
- }
-
- var oParam = {};
- oParam.id = "TXPID21501";
- oParam.service = "aftjudgapp.OutUnExecOrd";
- oParam.method = "reqExeDiag";
- oParam.inds = "req=ds_main_diaghist_list02_mmohdiag2:U";
- oParam.outds = "ds_main_diaghist_list02_mmohdiag2=mmohdiag2";
- oParam.async = false;
- oParam.callback = "cf_TXPID21501";
- tranf_submit(oParam);
-
- fDiagGridInsertRow();
- }
- function cf_TXPID21501(sSvcId, nErrorCode, sErrorMsg)
- {
- if(nErrorCode < 0) return;
- else
- {
- var list02cnt = ds_main_diaghist_list02_mmohdiag2.rowcount;
- var openerRows = ds_send.getColumn(0, "row");
-
- if (list02cnt > 0)
- {
- for (var i = 0; i <openerRows; i++)
- {
- opener.ds_main_grd2_unexecordlist.setColumn(i, "diagyn", "Y");
- }
- }
- else
- {
- for (var i = 0; i < openerRows; i++)
- {
- opener.ds_main_grd2_unexecordlist.setColumn(i, "diagyn", "N");
- }
- }
- }
- }
- function fSetDiagCdNm()
- {
- var diagcd = ds_hidden_sppiz00400_rslt.getColumn(0, "diagcd");
- var diaghngnm = ds_hidden_sppiz00400_rslt.getColumn(0, "diaghngnm");
- var diagengnm = ds_hidden_sppiz00400_rslt.getColumn(0, "diagengnm");
-
- if (diagcd)
- {
- ds_main_diaghist_list02_mmohdiag2.setColumn(ds_main_diaghist_list02_mmohdiag2.rowposition, "diagcd", diagcd);
- }
-
- if (diaghngnm)
- {
- ds_main_diaghist_list02_mmohdiag2.setColumn(ds_main_diaghist_list02_mmohdiag2.rowposition, "diagnm", diaghngnm);
- }
-
- var chk_key = ds_main_diaghist_list02_mmohdiag2.getColumn(ds_main_diaghist_list02_mmohdiag2.rowposition, "pid");
-
- if(chk_key)
- {
- return;
- }
- else
- {
- ds_main_diaghist_list02_mmohdiag2.setColumn(ds_main_diaghist_list02_mmohdiag2.rowposition, "pid", ds_send.getColumn(0, "pid"));
- ds_main_diaghist_list02_mmohdiag2.setColumn(ds_main_diaghist_list02_mmohdiag2.rowposition, "indd", ds_send.getColumn(0, "indd"));
- ds_main_diaghist_list02_mmohdiag2.setColumn(ds_main_diaghist_list02_mmohdiag2.rowposition, "cretno", ds_send.getColumn(0, "cretno"));
- ds_main_diaghist_list02_mmohdiag2.setColumn(ds_main_diaghist_list02_mmohdiag2.rowposition, "fromdd", ds_send.getColumn(0, "fromdd"));
- ds_main_diaghist_list02_mmohdiag2.setColumn(ds_main_diaghist_list02_mmohdiag2.rowposition, "mskind", ds_send.getColumn(0, "mskind"));
- ds_main_diaghist_list02_mmohdiag2.setColumn(ds_main_diaghist_list02_mmohdiag2.rowposition, "drinptyn", "N");
- ds_main_diaghist_list02_mmohdiag2.setColumn(ds_main_diaghist_list02_mmohdiag2.rowposition, "addflag", "Y");
- ds_main_diaghist_list02_mmohdiag2.setColumn(ds_main_diaghist_list02_mmohdiag2.rowposition, "insukind", ds_send.getColumn(0, "insukind"));
-
- ds_main_diaghist_list02_mmohdiag2.setColumn(ds_main_diaghist_list02_mmohdiag2.rowposition, "diagorddeptcd", ds_send.getColumn(0, "deptcd"));
- ds_main_diaghist_list02_mmohdiag2.setColumn(ds_main_diaghist_list02_mmohdiag2.rowposition, "orddeptcd", ds_send.getColumn(0, "deptcd"));
- }
- }
- function fSearchSPPIZ00400()
- {
- ds_hidden_sppiz00400_rslt.clearData();
-
- var row = ds_main_diaghist_list02_mmohdiag2.rowposition;
- var diagcd = ds_main_diaghist_list02_mmohdiag2.getColumn(row, "diagcd");
-
- var objArg = new Object();
- objArg.sDiagcd = diagcd;
- objArg.sSelectedrdodiagkind = 3;
- objArg.sSingleFlag = "M";
- var objDs = frmf_modal("SPPIZ00400", "SPPIZ00400", objArg, "", "", "", "", "", "", "", "", "", "M");
-
- ds_hidden_sppiz00400_rslt.copyData(objDs);
-
- ds_main_diaghist_list02_mmohdiag2.setColumn(ds_main_diaghist_list02_mmohdiag2.rowposition, "diagcd", ds_hidden_sppiz00400_rslt.getColumn(0, "diagcd"));
- ds_main_diaghist_list02_mmohdiag2.setColumn(ds_main_diaghist_list02_mmohdiag2.rowposition, "diagnm", ds_hidden_sppiz00400_rslt.getColumn(0, "diaghngnm"));
- }
-
- function ds_main_diaghist_list01_mmohdiag1_oncolumnchanged(obj:Dataset, e:DSColChangeEventInfo)
- {
- if(e.columnid == "diagkindcd")
- {
- obj.setColumn(e.row, "diagkindcd", (e.newvalue == "true" || e.newvalue == 1) ? "true" : "false");
- }
- }
- function ds_main_diaghist_list02_mmohdiag2_oncolumnchanged(obj:Dataset, e:DSColChangeEventInfo)
- {
- if(e.columnid == "ruleoutyn")
- {
- obj.setColumn(e.row, "ruleoutyn", (e.newvalue == "true" || e.newvalue == 1) ? "true" : "false");
- }
- }
- ]]></Script>
- </Form>
- </FDL>
|