123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611 |
- <?xml version="1.0" encoding="utf-8"?>
- <FDL version="1.5">
- <TypeDefinition url="..\..\..\default_typedef.xml"/>
- <Form id="SMADT30900" position="absolute 0 0 1200 794" titletext="마약/향정약 처방관리" oninit="SMADT30900_oninit" onload="SMADT30900_onload">
- <Layouts>
- <Layout>
- <Div position="absolute 0 13 1195 757" id="group3" scrollbars="autoboth">
- <Layouts>
- <Layout>
- <Div position="absolute 0 12 1195 52" id="group2" class="div_SA" anchor="default">
- <Layouts>
- <Layout>
- <Static text="조회년월 :" position="absolute 10 13 99 30" id="caption9" class="search_name" anchor="default"/>
- <cp_monthCal id="ipt_fstdd" titletext="monthCalendar" taborder="2" text="cp_monthCal00" scrollbars="none" position="absolute 98 10 198 31"/>
- <Button id="button1" taborder="3" text="일계표 재고반영" onclick="group3_button1_onclick" class="btn4" position="absolute 924 10 1051 32"/>
- <Button id="btn_prcp" taborder="4" text="상비품/비고 저장" onclick="group3_btn_prcp_onclick" class="btn4" position="absolute 1060 10 1188 32"/>
- </Layout>
- </Layouts>
- </Div>
- <Tab position="absolute 0 80 1195 744" id="switch1" class="sw_no_border" anchor="default">
- <Tabpages/>
- </Tab>
- </Layout>
- </Layouts>
- </Div>
- <Button position="absolute 1122 768 1195 790" id="btn_excel" class="btn7" text="엑셀저장" onclick="btn_excel_onclick"/>
- <Button position="absolute 987 768 1115 790" id="button8" class="btn6" text="월사용현황보고서" onclick="button8_onclick"/>
- <Grid position="absolute 0 98 1195 763" id="grd_narclist" class="datagrid2" binddataset="ds_grd_narclist" autoenter="select" cellsizingtype="both" extendsizetype="row">
- <Formats>
- <Format id="default">
- <Columns>
- <Column size="25" band="left"/>
- <Column size="109" band="left"/>
- <Column size="56"/>
- <Column size="60"/>
- <Column size="61"/>
- <Column size="80"/>
- <Column size="77"/>
- <Column size="45"/>
- <Column size="40"/>
- <Column size="64"/>
- <Column size="39"/>
- <Column size="45"/>
- <Column size="68"/>
- <Column size="38"/>
- <Column size="23"/>
- <Column size="43"/>
- <Column size="24"/>
- <Column size="41"/>
- <Column size="23"/>
- <Column size="43"/>
- <Column size="24"/>
- <Column size="100"/>
- <Column size="59"/>
- <Column size="62"/>
- <Column size="64"/>
- <Column size="58"/>
- <Column size="73"/>
- <Column size="67"/>
- <Column size="74"/>
- <Column size="76"/>
- <Column size="87"/>
- </Columns>
- <Rows>
- <Row size="24" band="head"/>
- <Row size="24" band="head"/>
- <Row size="24" band="head"/>
- <Row size="24"/>
- </Rows>
- <Band id="head">
- <Cell rowspan="3" taborder="undefined"/>
- <Cell col="1" rowspan="3" text="약품코드" taborder="undefined"/>
- <Cell col="2" colspan="5" text="전일재고" taborder="undefined"/>
- <Cell col="7" colspan="15" text="출고" taborder="undefined"/>
- <Cell col="22" colspan="3" text="입고/이송" taborder="undefined"/>
- <Cell col="25" colspan="5" text="당일재고" taborder="undefined"/>
- <Cell col="30" rowspan="3" text="당월 누적사용" wordwrap="word" taborder="undefined"/>
- <Cell row="1" col="2" rowspan="2" text="창고" taborder="undefined"/>
- <Cell row="1" col="3" rowspan="2" text="병동약국" taborder="undefined"/>
- <Cell row="1" col="4" rowspan="2" text="외래약국" taborder="undefined"/>
- <Cell row="1" col="5" rowspan="2" text="병동상비품" taborder="undefined"/>
- <Cell row="1" col="6" rowspan="2" text="병원총재고" taborder="undefined"/>
- <Cell row="1" col="7" colspan="3" text="병동약국" taborder="undefined"/>
- <Cell row="1" col="10" colspan="3" text="외래약국" taborder="undefined"/>
- <Cell row="1" col="13" colspan="8" text="비고수량/출고구분" taborder="undefined"/>
- <Cell row="1" col="21" rowspan="2" text="비고기록" taborder="undefined"/>
- <Cell row="1" col="22" rowspan="2" text="창고입고" taborder="undefined"/>
- <Cell row="1" col="23" colspan="2" text="이송" taborder="undefined"/>
- <Cell row="1" col="25" rowspan="2" text="창고" taborder="undefined"/>
- <Cell row="1" col="26" rowspan="2" text="병동약국" taborder="undefined"/>
- <Cell row="1" col="27" rowspan="2" text="외래약국" taborder="undefined"/>
- <Cell row="1" col="28" rowspan="2" text="병동상비품" taborder="undefined"/>
- <Cell row="1" col="29" rowspan="2" text="병원총재고" taborder="undefined"/>
- <Cell row="2" col="7" text="출고"/>
- <Cell row="2" col="8" text="반환"/>
- <Cell row="2" col="9" text="출고-반환"/>
- <Cell row="2" col="10" text="출고"/>
- <Cell row="2" col="11" text="반환"/>
- <Cell row="2" col="12" text="출고-반환"/>
- <Cell row="2" col="13" colspan="2" text="D0" taborder="undefined"/>
- <Cell row="2" col="15" colspan="2" text="D1" taborder="undefined"/>
- <Cell row="2" col="17" colspan="2" text="D2" taborder="undefined"/>
- <Cell row="2" col="19" colspan="2" text="N" taborder="undefined"/>
- <Cell row="2" col="23" text="병동약국"/>
- <Cell row="2" col="24" text="외래약국"/>
- </Band>
- <Band id="body">
- <Cell celltype="head"/>
- <Cell col="1" text="bind:drugcd"/>
- <Cell col="2" displaytype="number" edittype="masknumber" text="bind:bf_warestocqty" mask="expr:utlf_isNull(bf_warestocqty) ? "" : "0.09""/>
- <Cell col="3" displaytype="number" edittype="masknumber" text="bind:bf_instocqty" mask="expr:utlf_isNull(bf_instocqty) ? "" : "0.09""/>
- <Cell col="4" displaytype="number" edittype="masknumber" text="bind:bf_outstocqty" mask="expr:utlf_isNull(bf_outstocqty) ? "" : "0.09""/>
- <Cell col="5" displaytype="number" edittype="masknumber" text="bind:bf_fixstocqty" mask="expr:utlf_isNull(bf_fixstocqty) ? "" : "0.09""/>
- <Cell col="6" displaytype="number" edittype="masknumber" text="bind:bf_totstocqty" mask="expr:utlf_isNull(bf_totstocqty) ? "" : "0.09""/>
- <Cell col="7" displaytype="number" text="bind:indeleqty" mask="0.09" editautoselect="true" editacceptsenter="false"/>
- <Cell col="8" displaytype="number" text="bind:inrtnqty" mask="0.09"/>
- <Cell col="9" displaytype="number" text="bind:inrealdeleqty" mask="0.09"/>
- <Cell col="10" displaytype="number" text="bind:outdeleqty" mask="0.09"/>
- <Cell col="11" displaytype="number" text="bind:outrtnqty" mask="0.09"/>
- <Cell col="12" displaytype="number" text="bind:outrealdeleqty" mask="0.09"/>
- <Cell col="13" displaytype="number" edittype="masknumber" text="bind:remqty1" mask="expr:utlf_isNull(remqty1) ? "":"0.09"" editautoselect="true"/>
- <Cell col="14" displaytype="combo" edittype="combo" text="bind:remflag1" editautoselect="true" combodataset="ds_init_remflag" combocodecol="cdid" combodatacol="cdnm"/>
- <Cell col="15" displaytype="number" edittype="masknumber" text="bind:remqty2" mask="expr:utlf_isNull(remqty2) ? "":"0.09"" editautoselect="true"/>
- <Cell col="16" displaytype="combo" edittype="combo" text="bind:remflag2" editautoselect="true" combodataset="ds_init_remflag" combocodecol="cdid" combodatacol="cdnm"/>
- <Cell col="17" displaytype="number" edittype="masknumber" text="bind:remqty3" mask="expr:utlf_isNull(remqty1) ? "":"0.09"" editautoselect="true"/>
- <Cell col="18" displaytype="combo" edittype="combo" text="bind:remflag3" editautoselect="true" combodataset="ds_init_remflag" combocodecol="cdid" combodatacol="cdnm"/>
- <Cell col="19" displaytype="number" edittype="masknumber" text="bind:remqty4" mask="expr:utlf_isNull(remqty1) ? "":"0.09"" editautoselect="true"/>
- <Cell col="20" displaytype="combo" edittype="combo" text="bind:remflag4" editautoselect="true" combodataset="ds_init_remflag" combocodecol="cdid" combodatacol="cdnm"/>
- <Cell col="21" displaytype="text" edittype="text" text="bind:remcmt" editautoselect="true"/>
- <Cell col="22" displaytype="number" text="bind:winqty" mask="0.09"/>
- <Cell col="23" displaytype="number" text="bind:intranqty" mask="0.09"/>
- <Cell col="24" displaytype="number" text="bind:outtranqty" mask="0.09"/>
- <Cell col="25" displaytype="number" text="bind:warestocqty" mask="0.09"/>
- <Cell col="26" displaytype="number" text="bind:instocqty" mask="0.09"/>
- <Cell col="27" displaytype="number" text="bind:outstocqty" mask="0.09"/>
- <Cell col="28" displaytype="number" text="bind:fixstocqty" mask="0.09"/>
- <Cell col="29" displaytype="number" text="bind:totstocqty" mask="0.09"/>
- <Cell col="30" displaytype="number" text="bind:monthsum" mask="0.09"/>
- </Band>
- </Format>
- </Formats>
- </Grid>
- <Button position="absolute 877 768 981 790" id="button19" class="btn6" text="수불대장출력" onclick="button19_onclick"/>
- <CheckBox position="absolute 797 768 865 787" id="checkbox2" class="checkbox_search" text="미리보기"/>
- <Static id="caption19" text="마약일계표" class="tit_1" position="absolute 0 0 211 25"/>
- <Button id="btn_d1" taborder="1" text="1" position="absolute 0 75 33 98" visible="false" onclick="Button_onclick" class="btn_tab"/>
- <Button id="btn_d2" taborder="2" text="2" class="btn_tab" position="absolute 33 75 66 98" visible="false" onclick="Button_onclick"/>
- <Button id="btn_d3" taborder="3" text="3" class="btn_tab" position="absolute 66 75 99 98" visible="false" onclick="Button_onclick"/>
- <Button id="btn_d4" taborder="4" text="4" class="btn_tab" position="absolute 99 75 132 98" visible="false" onclick="Button_onclick"/>
- <Button id="btn_d5" taborder="5" text="5" class="btn_tab" position="absolute 132 75 165 98" visible="false" onclick="Button_onclick"/>
- <Button id="btn_d6" taborder="6" text="6" class="btn_tab" position="absolute 165 75 198 98" visible="false" onclick="Button_onclick"/>
- <Button id="btn_d7" taborder="7" text="7" class="btn_tab" position="absolute 198 75 231 98" visible="false" onclick="Button_onclick"/>
- <Button id="btn_d8" taborder="8" text="8" class="btn_tab" position="absolute 231 75 264 98" visible="false" onclick="Button_onclick"/>
- <Button id="btn_d9" taborder="9" text="9" class="btn_tab" position="absolute 264 75 297 98" visible="false" onclick="Button_onclick"/>
- <Button id="btn_d10" taborder="10" text="10" class="btn_tab" position="absolute 297 75 330 98" visible="false" onclick="Button_onclick"/>
- <Button id="btn_d11" taborder="11" text="11" class="btn_tab" position="absolute 330 75 363 98" visible="false" onclick="Button_onclick"/>
- <Button id="btn_d12" taborder="12" text="12" class="btn_tab" position="absolute 363 75 396 98" visible="false" onclick="Button_onclick"/>
- <Button id="btn_d13" taborder="13" text="13" class="btn_tab" position="absolute 396 75 429 98" visible="false" onclick="Button_onclick"/>
- <Button id="btn_d14" taborder="14" text="14" class="btn_tab" position="absolute 429 75 462 98" visible="false" onclick="Button_onclick"/>
- <Button id="btn_d15" taborder="15" text="15" class="btn_tab" position="absolute 462 75 495 98" visible="false" onclick="Button_onclick"/>
- <Button id="btn_d16" taborder="16" text="16" class="btn_tab" position="absolute 495 75 528 98" visible="false" onclick="Button_onclick"/>
- <Button id="btn_d17" taborder="17" text="17" class="btn_tab" position="absolute 528 75 561 98" visible="false" onclick="Button_onclick"/>
- <Button id="btn_d18" taborder="18" text="18" class="btn_tab" position="absolute 561 75 594 98" visible="false" onclick="Button_onclick"/>
- <Button id="btn_d19" taborder="19" text="19" class="btn_tab" position="absolute 594 75 627 98" visible="false" onclick="Button_onclick"/>
- <Button id="btn_d20" taborder="20" text="20" class="btn_tab" position="absolute 627 75 660 98" visible="false" onclick="Button_onclick"/>
- <Button id="btn_d21" taborder="21" text="21" class="btn_tab" position="absolute 660 75 693 98" visible="false" onclick="Button_onclick"/>
- <Button id="btn_d22" taborder="22" text="22" class="btn_tab" position="absolute 693 75 726 98" visible="false" onclick="Button_onclick"/>
- <Button id="btn_d23" taborder="23" text="23" class="btn_tab" position="absolute 726 75 759 98" visible="false" onclick="Button_onclick"/>
- <Button id="btn_d24" taborder="24" text="24" class="btn_tab" position="absolute 759 75 792 98" visible="false" onclick="Button_onclick"/>
- <Button id="btn_d25" taborder="25" text="25" class="btn_tab" position="absolute 792 75 825 98" visible="false" onclick="Button_onclick"/>
- <Button id="btn_d26" taborder="26" text="26" class="btn_tab" position="absolute 825 75 858 98" visible="false" onclick="Button_onclick"/>
- <Button id="btn_d27" taborder="27" text="27" class="btn_tab" position="absolute 858 75 891 98" visible="false" onclick="Button_onclick"/>
- <Button id="btn_d28" taborder="28" text="28" class="btn_tab" position="absolute 891 75 924 98" visible="false" onclick="Button_onclick"/>
- <Button id="btn_d29" taborder="29" text="29" class="btn_tab" position="absolute 924 75 957 98" visible="false" onclick="Button_onclick"/>
- <Button id="btn_d30" taborder="30" text="30" class="btn_tab" position="absolute 957 75 990 98" visible="false" onclick="Button_onclick"/>
- <Button id="btn_d31" taborder="31" text="31" class="btn_tab" position="absolute 990 75 1023 98" visible="false" onclick="Button_onclick"/>
- </Layout>
- </Layouts>
- <Objects>
- <Dataset id="ds_grd_narclist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" reversesubsum="false">
- <ColumnInfo>
- <Column id="drugcd" type="STRING"/>
- <Column id="bf_warestocqty" type="STRING"/>
- <Column id="bf_instocqty" type="STRING"/>
- <Column id="bf_outstocqty" type="STRING"/>
- <Column id="bf_fixstocqty" type="STRING"/>
- <Column id="bf_totstocqty" type="STRING"/>
- <Column id="indeleqty" type="STRING"/>
- <Column id="inrtnqty" type="STRING"/>
- <Column id="inrealdeleqty" type="STRING"/>
- <Column id="outdeleqty" type="STRING"/>
- <Column id="outrtnqty" type="STRING"/>
- <Column id="outrealdeleqty" type="STRING"/>
- <Column id="remqty1" type="STRING"/>
- <Column id="remflag1" type="STRING"/>
- <Column id="remqty2" type="STRING"/>
- <Column id="remflag2" type="STRING"/>
- <Column id="remqty3" type="STRING"/>
- <Column id="remflag3" type="STRING"/>
- <Column id="remqty4" type="STRING"/>
- <Column id="remflag4" type="STRING"/>
- <Column id="remcmt" type="STRING"/>
- <Column id="winqty" type="STRING"/>
- <Column id="intranqty" type="STRING"/>
- <Column id="outtranqty" type="STRING"/>
- <Column id="warestocqty" type="STRING"/>
- <Column id="instocqty" type="STRING"/>
- <Column id="outstocqty" type="STRING"/>
- <Column id="fixstocqty" type="STRING"/>
- <Column id="totstocqty" type="STRING"/>
- <Column id="monthsum" type="STRING"/>
- </ColumnInfo>
- </Dataset>
- <Dataset id="ds_main_prntlist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
- <Dataset id="ds_send_srchinfo" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
- <ColumnInfo>
- <Column id="yyyymm" type="STRING" size="256"/>
- <Column id="dd" type="STRING" size="256"/>
- </ColumnInfo>
- <Rows>
- <Row/>
- </Rows>
- </Dataset>
- <Dataset id="ds_send_saveinfo" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
- <ColumnInfo>
- <Column id="data1" type="STRING" size="256"/>
- </ColumnInfo>
- <Rows>
- <Row/>
- </Rows>
- </Dataset>
- <Dataset id="ds_send_print1" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
- <Dataset id="ds_send_srchdata" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
- <ColumnInfo>
- <Column id="preview" type="STRING" size="256"/>
- </ColumnInfo>
- <Rows>
- <Row/>
- </Rows>
- </Dataset>
- <Dataset id="ds_init_remflag" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
- <ColumnInfo>
- <Column id="cdid" type="STRING" size="256"/>
- <Column id="cdnm" type="STRING" size="256"/>
- </ColumnInfo>
- <Rows>
- <Row/>
- <Row>
- <Col id="cdnm">병동약국재고 출고</Col>
- <Col id="cdid">1</Col>
- </Row>
- <Row>
- <Col id="cdnm">창고재고 출고</Col>
- <Col id="cdid">2</Col>
- </Row>
- <Row>
- <Col id="cdnm">병동약국재고 -> 상비품 이동</Col>
- <Col id="cdid">3</Col>
- </Row>
- <Row>
- <Col id="cdnm">창고재고 -> 상비품 이동</Col>
- <Col id="cdid">4</Col>
- </Row>
- </Rows>
- </Dataset>
- <Dataset id="ds_hidden" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
- </Objects>
- <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
- *
- *---------------------------------------------------------------------------------------
- ****************************************************************************************/
- include "com_commonxp::comm_main.xjs";
- var arErrorCode = new HashArray();
- /******************************************************************
- * Argument :
- * Description : 초기화
- ******************************************************************/
- function SMADT30900_oninit(obj:Form, e:InitEventInfo)
- {
- frmf_initForm(obj);
- }
- function SMADT30900_onload(obj:Form, e:LoadEventInfo)
- {
- //row 상태값 설정
- grdf_setRowTypeIcon(grd_narclist, 0);
-
- ds_send_srchinfo.setColumn(0, "yyyymm", utlf_getCurrentDate().substr(0,6));
- fSetTab();
-
- //조회기간 달력 set
- group3.group2.ipt_fstdd.setData(ds_send_srchinfo.getColumn(0, "yyyymm"));
-
- //조회기간 event
- group3.group2.ipt_fstdd.setCallEvent("fn_Cal");
- }
- /******************************************************************
- * Argument :
- * Description : 조회기간(fromdd) event
- ******************************************************************/
- function fn_Cal(){
- var fromdd = group3.group2.ipt_fstdd.getData();
- ds_send_srchinfo.setColumn(0, "yyyymm", fromdd);
- fSetTab();
- }
- /******************************************************************
- * Argument :
- * Description : Tab설정
- ******************************************************************/
- function fSetTab(){
- var terms = ds_send_srchinfo.getColumn(0, "yyyymm")+ "01";
- var lastDate = utlf_getLastDate(terms);
- lastDate = lastDate.substr(6,2);
- var tabButton = "";
- var no = "";
-
- if( utlf_isNull(lastDate) ) {
- return false;
- }
-
- for( var i = 1; i < 32 ; i++ ){
- if( i <= lastDate ) {
- no = (i+1).toString();
- tabButton = "btn_d" + i
- components[tabButton].visible = true;
- } else {
- no = (i+1).toString();
- tabButton = "btn_d" + i
- components[tabButton].visible = false;
- }
- }
- }
- /******************************************************************
- * Argument :
- * Description : 조회년월 event
- ******************************************************************/
- function group3_group2_ipt_fstdd_onchanged(obj:Calendar, e:ChangeEventInfo)
- {
- fSetTab();
- }
- /******************************************************************
- * Argument :
- * Description : Tab Button event
- ******************************************************************/
- function Button_onclick(obj:Button, e:ClickEventInfo)
- {
- var btn_text = obj.text;
- var btn_dd = Number(btn_text);
-
- if( btn_dd > 0 && btn_dd < 32 ){
- if( btn_dd < 10 ) {
- ds_send_srchinfo.setColumn(0, "dd" , "0" + btn_text);
- } else {
- ds_send_srchinfo.setColumn(0, "dd" , btn_text);
- }
-
- ds_send_srchinfo.setColumn(0, "yyyymm", ds_send_srchinfo.getColumn(0, "yyyymm").substr(0,6));
-
- var oParam = {};
- oParam.id = "TRADT30901";
- oParam.service = "pharmacyprescriptionapp.Narcotics";
- oParam.method = "reqGetNarcDayList";
- oParam.inds = "req=ds_send_srchinfo";
- oParam.outds = "ds_grd_narclist=narclist";
- oParam.async = false;
- oParam.callback = "cf_TRADT30901";
- tranf_submit(oParam);
-
- lf_btn_Selected(obj.name);
- }
- }
- function cf_TRADT30901(sSvcId, nErrorCode, sErrorMsg) {
- if(nErrorCode < 0) return;
- dsf_setTypeFormat(ds_grd_narclist, "bf_warestocqty:FLOAT^bf_instocqty:FLOAT^bf_outstocqty:FLOAT^bf_fixstocqty:FLOAT^bf_totstocqty:FLOAT^indeleqty:FLOAT^inrtnqty:FLOAT^inrealdeleqty:FLOAT^outdeleqty:FLOAT^outrtnqty:FLOAT^outrealdeleqty:FLOAT^remqty:FLOAT^winqty:FLOAT^intranqty:FLOAT^outtranqty:FLOAT^warestocqty:FLOAT^instocqty:FLOAT^outstocqty:FLOAT^fixstocqty:FLOAT^totstocqty:FLOAT^monthsum:FLOAT^remqty1:FLOAT^remqty2:FLOAT^remqty3:FLOAT^remqty4:FLOAT");
- }
- /****************************************************************************************
- * Function : lf_btn_Selected
- * Description : 버튼 선택상태 설정
- * Argument : 01.btnId : 활성화 버튼 ID
- * retrun type :
- * Creator :
- ****************************************************************************************/
- function lf_btn_Selected(btnId){
- if( utlf_isNull(btnId) ) return;
- var cmpId = btnId.substring(5,btnId.length);
-
- for( var i = 1; i < 32; i++ ){
- if( i == cmpId){
- var btnObj = this.components["btn_d"+i];
- btnObj.setSelectStatus(true);
- btnObj.class = "btn_tab_S";
- }else{
- var btnObj = this.components["btn_d"+i];
- btnObj.setSelectStatus(false);
- btnObj.class = "btn_tab";
- }
- }
- }
-
- /******************************************************************
- * Argument :
- * Description : 일계표 재고반영 Button event
- ******************************************************************/
- function group3_button1_onclick(obj:Button, e:ClickEventInfo)
- {
- //ds_send_saveinfo.setColumn(0, "data1", dsf_getDsCSV(ds_grd_narclist));
- ds_send_saveinfo.copyData(ds_grd_narclist);
- //dsf_setTypeFormat(ds_send_saveinfo, "warestocqty:FLOAT^instocqty:FLOAT^outstocqty:FLOAT^fixstocqty:FLOAT^totstocqty:FLOAT");
- var oParam = {};
- oParam.id = "TXADT30902";
- oParam.service = "pharmacyprescriptionapp.Narcotics";
- oParam.method = "reqExeNarcDayListStoc";
- oParam.inds = "req=ds_send_srchinfo data1=ds_send_saveinfo";
- oParam.outds = "ds_hidden=item";
- oParam.async = false;
- oParam.callback = "cf_TXADT30902";
- tranf_submit(oParam);
- }
- function cf_TXADT30902(sSvcId, nErrorCode, sErrorMsg) {
- if(nErrorCode < 0) return;
- var oParam = {};
- oParam.id = "TRADT30901";
- oParam.service = "pharmacyprescriptionapp.Narcotics";
- oParam.method = "reqGetNarcDayList";
- oParam.inds = "req=ds_send_srchinfo";
- oParam.outds = "ds_grd_narclist=narclist";
- oParam.async = false;
- oParam.callback = "cf_TRADT30901";
- tranf_submit(oParam);
- }
- /******************************************************************
- * Argument :
- * Description : 상비품/비고 저장 Button event
- ******************************************************************/
- function group3_btn_prcp_onclick(obj:Button, e:ClickEventInfo)
- {
- var oDsUpdate = grdf_getGridUpdateData(grd_narclist);
-
- if( oDsUpdate.rowcount < 1 ){
- sysf_messageBox("업데이트 정보가 없습니다.", "I");
- return;
- } else {
- for(var i = 0 ; i < ds_grd_narclist.rowcount; i++ ){
- if( utlf_isNull(ds_grd_narclist.getColumn(i, "remflag1")) && !utlf_isNull(ds_grd_narclist.getColumn(i, "remqty1")) ) {
- sysf_messageBox("D0의 비고수량이 입력되었으므로 출고구분을 선택하여 주십시오.", "I");
- return;
- }
- if( utlf_isNull(ds_grd_narclist.getColumn(i, "remflag2")) && !utlf_isNull(ds_grd_narclist.getColumn(i, "remqty2")) ) {
- sysf_messageBox("D1의 비고수량이 입력되었으므로 출고구분을 선택하여 주십시오.", "I");
- return;
- }
- if( utlf_isNull(ds_grd_narclist.getColumn(i, "remflag3")) && !utlf_isNull(ds_grd_narclist.getColumn(i, "remqty3")) ) {
- sysf_messageBox("D2의 비고수량이 입력되었으므로 출고구분을 선택하여 주십시오.", "I");
- return;
- }
- if( utlf_isNull(ds_grd_narclist.getColumn(i, "remflag4")) && !utlf_isNull(ds_grd_narclist.getColumn(i, "remqty4")) ) {
- messageBox("N의 비고수량이 입력되었으므로 출고구분을 선택하여 주십시오.", "I");
- sysf_return0;
- }
- }
-
- grdf_setStatusColumn(oDsUpdate, "m"); // 각행의 status에 rowType 값에 따라 'i', 'u', 'd'로 업데이트 시켜준다
- ds_send_saveinfo.copyData(oDsUpdate, true);
-
- dsf_setTypeFormat(ds_send_saveinfo, "bf_warestocqty:FLOAT^bf_instocqty:FLOAT^bf_outstocqty:FLOAT^bf_fixstocqty:FLOAT^bf_totstocqty:FLOAT^remqty:FLOAT^remqty1:FLOAT^remqty2:FLOAT^remqty3:FLOAT^remqty4:FLOAT");
- var oParam = {};
- oParam.id = "TXADT30901";
- oParam.service = "pharmacyprescriptionapp.Narcotics";
- oParam.method = "reqExeNarcDayList";
- oParam.inds = "req=ds_send_srchinfo data1=ds_send_saveinfo";
- oParam.outds = "ds_hidden=item";
- oParam.async = false;
- oParam.callback = "cf_TXADT30901";
- tranf_submit(oParam);
- }
- }
- function cf_TXADT30901(sSvcId, nErrorCode, sErrorMsg) {
- if(nErrorCode < 0) return;
- var oParam = {};
- oParam.id = "TRADT30901";
- oParam.service = "pharmacyprescriptionapp.Narcotics";
- oParam.method = "reqGetNarcDayList";
- oParam.inds = "req=ds_send_srchinfo";
- oParam.outds = "ds_grd_narclist=narclist";
- oParam.async = false;
- oParam.callback = "cf_TRADT30901";
- tranf_submit(oParam);
- }
- /******************************************************************
- * Argument :
- * Description : 수불대장출력 Button event
- ******************************************************************/
- function button19_onclick(obj:Button, e:ClickEventInfo)
- {
- //수불대장 조회
- var oParam = {};
- oParam.id = "TRADT30903";
- oParam.service = "pharmacyprescriptionapp.Narcotics";
- oParam.method = "reqGetNarcDayPrntList";
- oParam.inds = "req=ds_send_srchinfo";
- oParam.outds = "ds_send_print1=item";
- oParam.async = false;
- oParam.callback = "cf_TRADT30903";
- tranf_submit(oParam);
-
- ds_send_srchdata.addColumn("enddd", "string", 256);
- ds_send_srchdata.addColumn("stocprntyn", "string", 256);
- ds_send_srchdata.setColumn(0, "enddd", ds_send_print1.getColumn(0, "enddd"));
- ds_send_srchdata.setColumn(0, "stocprntyn", "Y");
-
- var objDOM = rptf_createDOM(); // DOM 객체 설정
- rptf_setNodeListToDOM(objDOM, "/root/send/data/print1/item", ds_send_print1); // 데이터셋 1
- rptf_setNodeListToDOM(objDOM, "/root/send/srchdata", ds_send_srchinfo); // 데이터셋 2
-
- var objParam = new Object();
- objParam.xml_data_XML1 = objDOM.documentElement.source; // 최상의노드 XML 스트링 추출
-
- if( !utlf_isNull(ds_send_srchdata.getColumn(0, "enddd")) ) {
- if( checkbox2.value == 1 ){ //미리보기가 체크된 경우
- var option = "open=1;save=1;directprint=0;printdialog=1;print=1;zoom=0;";
- } else {
- var option = "open=1;save=1;directprint=1;printdialog=0;print=1;zoom=0;";
- }
- rptf_exeReportPreview30(["RPADT30302"],[objParam], option);
- ds_send_print1.clearData();
- }
- }
- function cf_TRADT30903(sSvcId, nErrorCode, sErrorMsg) {
- if(nErrorCode < 0) return;
- ds_send_print1.updateColID("stocdd","enddd");
- ds_send_print1.updateColID("drugcd","narccd");
- }
- /******************************************************************
- * Argument :
- * Description : 수불대장출력 Button event
- ******************************************************************/
- function button8_onclick(obj:Button, e:ClickEventInfo)
- {
- var oParam = {};
- oParam.id = "TRADT30902";
- oParam.service = "pharmacyprescriptionapp.Narcotics";
- oParam.method = "reqGetNarcDaySumPrntList";
- oParam.inds = "req=ds_send_srchinfo";
- oParam.outds = "ds_main_prntlist=narclist";
- oParam.async = false;
- //oParam.callback = "cf_TRADT30902";
- tranf_submit(oParam);
-
- var objDOM = rptf_createDOM(); // DOM 객체 설정
- rptf_setNodeListToDOM(objDOM, "/root/main/prntlist/narclist", ds_main_prntlist); // 데이터셋 1
-
- var objParam = new Object();
- objParam.xml_data_XML1 = objDOM.documentElement.source; // 최상의노드 XML 스트링 추출
-
- if( checkbox2.value == 1 ){ //미리보기가 체크된 경우
- var option = "open=1;save=1;directprint=0;printdialog=1;print=1;zoom=0;";
- } else {
- var option = "open=1;save=1;directprint=1;printdialog=0;print=1;zoom=0;";
- }
-
- rptf_exeReportPreview30(["RPADT30901"],[objParam], option);
- }
- /******************************************************************
- * Argument :
- * Description : 수불대장출력 Button event
- ******************************************************************/
- function btn_excel_onclick(obj:Button, e:ClickEventInfo)
- {
- if( ds_grd_narclist.rowcount > 0 ){
- grdf_exportExcel(grd_narclist, "마약일계표", "마약일계표", false, "", "none", false);
- } else {
- sysf_messageBox("조회된 데이터가 ", "I004");
- }
- }
- ]]></Script>
- </Form>
- </FDL>
|