123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651 |
- <?xml version="1.0" encoding="utf-8"?>
- <FDL version="1.5">
- <TypeDefinition url="..\..\..\default_typedef.xml"/>
- <Form id="SMMNG04700" position="absolute 0 0 1195 737" titletext="장비정기점검일지" oninit="SMMNG04700_oninit" onload="SMMNG04700_onload">
- <Layouts>
- <Layout>
- <Div position="absolute 0 20 1195 737" id="grp_biz" scrollbars="autoboth">
- <Layouts>
- <Layout>
- <Div position="absolute 0 5 1186 40" align="align:center top;" id="grp_sea" anchor="left top right" class="div_SA">
- <Layouts>
- <Layout>
- <Static text="업무년월 :" position="absolute 10 9 99 26" id="caption9" class="search_name" anchor="default"/>
- <Button position="absolute 1004 7 1060 29" align="align:left middle;" id="button2" class="btn1" taborder="7" text="조회" anchor="top right" onclick="grp_biz_grp_sea_button2_onclick"/>
- <Calendar position="absolute 84 8 150 27" align="align:center middle;" id="ipt_workmm" class="input_s_essential" mask="yyyy-mm" anchor="default" autoselect="true"/>
- <Button position="absolute 1063 7 1119 29" align="align:left middle;" id="button1" class="btn4" taborder="7" text="저장" anchor="top right" onclick="grp_biz_grp_sea_button1_onclick"/>
- <Button position="absolute 1122 7 1178 29" align="align:left middle;" id="button5" class="btn6" taborder="7" text="출력" anchor="top right" onclick="grp_biz_grp_sea_button5_onclick"/>
- </Layout>
- </Layouts>
- </Div>
- <Tab position="absolute 0 47 1195 717" id="switch1" anchor="all" tabindex="0">
- <Tabpages>
- <Tabpage text="체크리스트" id="case1">
- <Layouts>
- <Layout>
- <Grid position="absolute 0 28 1195 643" id="grd_chklist" binddataset="ds_main_chkinfo_chklist" anchor="default" autoenter="select" selecttype="cell" cellclickbound="cell" autofittype="col" cellsizebandtype="allband" cellsizingtype="col">
- <Formats>
- <Format id="default">
- <Columns>
- <Column size="63"/>
- <Column size="212"/>
- <Column size="80"/>
- <Column size="80"/>
- <Column size="80"/>
- <Column size="80"/>
- <Column size="80"/>
- <Column size="80"/>
- <Column size="80"/>
- <Column size="80"/>
- <Column size="80"/>
- <Column size="80"/>
- <Column size="80"/>
- <Column size="80"/>
- <Column size="80"/>
- </Columns>
- <Rows>
- <Row size="24" band="head"/>
- <Row size="40" band="head"/>
- <Row size="24"/>
- </Rows>
- <Band id="head">
- <Cell rowspan="2" text="표준" taborder="undefined"/>
- <Cell col="1" rowspan="2" text="Check List" taborder="undefined"/>
- <Cell col="2" taborder="undefined"/>
- <Cell col="3" taborder="undefined"/>
- <Cell col="4" taborder="undefined"/>
- <Cell col="5" taborder="undefined"/>
- <Cell col="6" taborder="undefined"/>
- <Cell col="7" taborder="undefined"/>
- <Cell col="8" taborder="undefined"/>
- <Cell col="9" taborder="undefined"/>
- <Cell col="10" taborder="undefined"/>
- <Cell col="11" taborder="undefined"/>
- <Cell col="12"/>
- <Cell col="13"/>
- <Cell col="14"/>
- <Cell row="1" col="2" text="caption7"/>
- <Cell row="1" col="3" text="caption11"/>
- <Cell row="1" col="4" text="caption10"/>
- <Cell row="1" col="5" text="caption9"/>
- <Cell row="1" col="6" text="caption8"/>
- <Cell row="1" col="7" text="caption6"/>
- <Cell row="1" col="8" text="caption5"/>
- <Cell row="1" col="9" text="caption4"/>
- <Cell row="1" col="10" text="caption3"/>
- <Cell row="1" col="11" text="caption2"/>
- <Cell row="1" col="12" text="caption1"/>
- <Cell row="1" col="13" text="caption12"/>
- <Cell row="1" col="14" text="caption13"/>
- </Band>
- <Band id="body">
- <Cell style="line:EXPR(line);font:arial,9,bold;" text="bind:chkdivsnm"/>
- <Cell col="1" style="align:left top;padding:5 2 0 2;line:EXPR(line);font:arial,9,bold;" text="bind:chknm" wordwrap="char"/>
- <Cell col="2" displaytype="checkbox" edittype="checkbox" style="line:EXPR(line);" text="bind:eq1" expr="expr:eq1 == 'Y' || eq1 == '1' ? '1' : '0'"/>
- <Cell col="3" displaytype="checkbox" edittype="checkbox" style="line:EXPR(line);" text="bind:eq2" expr="expr:eq2 == 'Y' || eq2 == '1' ? '1' : '0'"/>
- <Cell col="4" displaytype="checkbox" edittype="checkbox" style="line:EXPR(line);" text="bind:eq3" expr="expr:eq3 == 'Y' || eq3 == '1' ? '1' : '0'"/>
- <Cell col="5" displaytype="checkbox" edittype="checkbox" style="line:EXPR(line);" text="bind:eq4" expr="expr:eq4 == 'Y' || eq4 == '1' ? '1' : '0'"/>
- <Cell col="6" displaytype="checkbox" edittype="checkbox" style="line:EXPR(line);" text="bind:eq5" expr="expr:eq5 == 'Y' || eq5 == '1' ? '1' : '0'"/>
- <Cell col="7" displaytype="checkbox" edittype="checkbox" style="line:EXPR(line);" text="bind:eq6" expr="expr:eq6 == 'Y' || eq6 == '1' ? '1' : '0'"/>
- <Cell col="8" displaytype="checkbox" edittype="checkbox" style="line:EXPR(line);" text="bind:eq7" expr="expr:eq7 == 'Y' || eq7 == '1' ? '1' : '0'"/>
- <Cell col="9" displaytype="checkbox" edittype="checkbox" style="line:EXPR(line);" text="bind:eq8" expr="expr:eq8 == 'Y' || eq8 == '1' ? '1' : '0'"/>
- <Cell col="10" displaytype="checkbox" edittype="checkbox" style="line:EXPR(line);" text="bind:eq9" expr="expr:eq9 == 'Y' || eq9 == '1' ? '1' : '0'"/>
- <Cell col="11" displaytype="checkbox" edittype="checkbox" style="line:EXPR(line);" text="bind:eq10" expr="expr:eq10 == 'Y' || eq10 == '1' ? '1' : '0'"/>
- <Cell col="12" displaytype="checkbox" edittype="checkbox" style="line:EXPR(line);" text="bind:eq11" expr="expr:eq11 == 'Y' || eq11 == '1' ? '1' : '0'"/>
- <Cell col="13" displaytype="checkbox" edittype="checkbox" style="line:EXPR(line);" text="bind:eq12" expr="expr:eq12 == 'Y' || eq11 == '1' ? '1' : '0'"/>
- <Cell col="14" displaytype="checkbox" edittype="checkbox" style="line:EXPR(line);" text="bind:eq13" expr="expr:eq11 == 'Y' || eq13 == '1' ? '1' : '0'"/>
- </Band>
- </Format>
- </Formats>
- </Grid>
- <Static text="체크리스트" position="absolute 0 5 100 22" id="caption1" class="tit_2" anchor="default"/>
- <Shape position="absolute 0 24 1195 29" linetype="horizontal" id="line1" class="line_10" anchor="default"/>
- </Layout>
- </Layouts>
- </Tabpage>
- <Tabpage text="점검일지" id="case2">
- <Layouts>
- <Layout>
- <Grid position="absolute 0 24 1195 643" id="grd_chklist2" class="datagrid2" binddataset="ds_main_chkinfo_chklist2" anchor="all" onexpanddown="grp_biz_switch1_case2_grd_chklist2_onexpanddown" autoenter="select" cellclickbound="cell" selecttype="cell" autofittype="col" cellsizebandtype="allband" cellsizingtype="col">
- <Formats>
- <Format id="default">
- <Columns>
- <Column size="0"/>
- <Column size="0"/>
- <Column size="24"/>
- <Column size="100"/>
- <Column size="89"/>
- <Column size="100"/>
- <Column size="100"/>
- <Column size="100"/>
- <Column size="569"/>
- <Column size="100"/>
- <Column size="0"/>
- <Column size="0"/>
- </Columns>
- <Rows>
- <Row size="28" band="head"/>
- <Row size="24"/>
- </Rows>
- <Band id="head">
- <Cell text="상태"/>
- <Cell col="1" text="workmm"/>
- <Cell col="2"/>
- <Cell col="3" text="장비명"/>
- <Cell col="4" text="점검후상태 (양호여부)"/>
- <Cell col="5" text="점검일자"/>
- <Cell col="6" text="점검자"/>
- <Cell col="7" text="멸균팀확인자"/>
- <Cell col="8" text="수리요구 계획 : 특이사항"/>
- <Cell col="9" text="의공학팀 확인자"/>
- <Cell col="10" text="멸균팀확인자ID"/>
- <Cell col="11" text="의공학팀 확인자"/>
- </Band>
- <Band id="body">
- <Cell text="bind:stat"/>
- <Cell col="1" text="bind:workmm"/>
- <Cell col="2" celltype="head"/>
- <Cell col="3" displaytype="combo" edittype="combo" style="padding:1 2 1 2;" text="bind:fixasetcd" combodataset="ds_cond_codeinfo_codelist" combocodecol="cdid" combodatacol="cdnm" combodisplayrowcount="10"/>
- <Cell col="4" displaytype="checkbox" edittype="checkbox" text="bind:statyn" expr="expr:statyn == 'Y' || statyn == '1' ? '1' : '0'"/>
- <Cell col="5" displaytype="date" edittype="date" text="bind:chkdd" calendardisplaynulltype="none"/>
- <Cell col="6" displaytype="text" edittype="text" text="bind:chknm"/>
- <Cell col="7" displaytype="text" edittype="text" text="bind:certnm" expandshow="show"/>
- <Cell col="8" displaytype="text" edittype="text" text="bind:cmt"/>
- <Cell col="9" displaytype="text" edittype="text" text="bind:certnm2" expandshow="show"/>
- <Cell col="10" text="bind:certid"/>
- <Cell col="11" text="bind:certid2"/>
- </Band>
- </Format>
- </Formats>
- </Grid>
- <Static text="체크리스트" position="absolute 0 3 100 24" id="caption2" class="tit_2" anchor="default"/>
- <Shape position="absolute 0 20 1195 29" linetype="horizontal" id="line2" class="line_10" anchor="left top right"/>
- </Layout>
- </Layouts>
- </Tabpage>
- </Tabpages>
- </Tab>
- </Layout>
- </Layouts>
- </Div>
- <Static id="cap_title" text="장비 정기점검일지" class="tit_1" position="absolute 0 0 141 25"/>
- </Layout>
- </Layouts>
- <Objects>
- <Dataset id="ds_main_cond" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
- <ColumnInfo>
- <Column id="workmm" type="STRING" size="256"/>
- </ColumnInfo>
- <Rows>
- <Row>
- <Col id="workmm"/>
- </Row>
- </Rows>
- </Dataset>
- <Dataset id="ds_temp_titleinfo_titlelist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
- <Dataset id="ds_send_reqdata" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
- <Dataset id="ds_main_chkinfo_chklist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
- <Dataset id="ds_cond_codeinfo_codelist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
- <Dataset id="ds_main_chkinfo_chklist2" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
- <Dataset id="ds_temp_chkinfo_chklist2" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
- <Dataset id="ds_temp_chkinfo_chklist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
- <Dataset id="ds_send_savedata_chklist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
- <Dataset id="ds_send_savedata_chklist2" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
- <Dataset id="ds_printinfo_cmtinfo" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
- <Dataset id="ds_printinfo_statinfo" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
- <Dataset id="ds_printinfo_chkddinfo" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
- <Dataset id="ds_printinfo_chknminfo" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
- <Dataset id="ds_printinfo_certnm2info" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
- <Dataset id="ds_temp_title" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
- <Dataset id="ds_temp_title2" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
- <Dataset id="ds_printinfo_certnminfo" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false"/>
- </Objects>
- <Bind>
- <BindItem id="item0" compid="grp_biz.grp_sea.ipt_workmm" propid="value" datasetid="ds_main_cond" columnid="workmm"/>
- </Bind>
- <Script type="xscript4.0"><![CDATA[/***************************************************************************************
- * System Name :
- * Job Name :
- * Creator :
- * Make Date : 2017-07-11
- * Description :
- *---------------------------------------------------------------------------------------
- * Modify Date Modifier Modify Description
- *---------------------------------------------------------------------------------------
- * 2017-07-11 Live Converter TF->XP
- *
- *---------------------------------------------------------------------------------------
- ****************************************************************************************/
- include "com_commonxp::comm_main.xjs";
- var arErrorCode = new HashArray();
- var oGridFromat;
- function SMMNG04700_oninit(obj:Form, e:InitEventInfo)
- {
- frmf_initForm(obj); //폼 초기화
- grdf_setRowTypeIcon(grp_biz.switch1.case2.grd_chklist2, 2);
- grdf_initGrid(grp_biz.switch1.case1.grd_chklist);
- grdf_initGrid(grp_biz.switch1.case2.grd_chklist2);
- }
- function SMMNG04700_onload(obj:Form, e:LoadEventInfo)
- {
- //Grid 초기 포맷을 가지고 있음
- oGridFromat = grp_biz.switch1.case1.grd_chklist.formats;
-
- var curdd = utlf_getCurrentDate();
- grp_biz.grp_sea.ipt_workmm.value = curdd.substr(0,6);
-
- fSearch();
- }
- // 화면 open시와 초기화 버튼 클릭시 화면 초기화 기능을 수행한다.
- function fTitleInitialize() {
- //그리드 초기 포맷에서 그리드 수정을 하므로, 조회시 초기 포맷으로 초기화함
- grp_biz.switch1.case1.grd_chklist.formats = oGridFromat;
-
- var oParam = {};
- oParam.id = "TRMNG04701";
- oParam.service = "csrapp.CsrMngt";
- oParam.method = "reqGetEqCheckTitleInfo";
- oParam.inds = "req=ds_main_cond";
- oParam.outds = "ds_temp_titleinfo_titlelist=titlelist";
- oParam.async = false;
- tranf_submit(oParam);
-
- var caption1 = ds_temp_titleinfo_titlelist.getColumn(0, "caption");
- var caption2 = caption1.split("|");
- var arr1 = caption2[0].split("^");
- var arr2 = caption2[1].split("^");
-
- var count = 0;
- var colcount = 5;
-
- //DB 쿼리에 맞추어 최대 col num은 15로 설정
- var iTotalColNum = 15;
- //merge를 위한 시작 및 종료 col num 을 가지는 array
- var arrStartNum = new Array();
- var arrEndNum = new Array();
- var jIndex = 0;
- //하단 타이틀 시작 총컬럼수 15(0~14)개이므로 14부터 시작
- var zIndex = 14;
-
- //////////////////////////////////////////////////////////////////////////////////////////////////////////////////
- //하단 타이틀 입력
- //총 컬럼 수 28(0~27)
- for(var iIndex = 27 ; iIndex >= 15; iIndex--){
- grp_biz.switch1.case1.grd_chklist.setCellProperty("head", iIndex, "text", arr2[zIndex]);
- zIndex = zIndex - 1;
- }
- //////////////////////////////////////////////////////////////////////////////////////////////////////////////////
-
- //////////////////////////////////////////////////////////////////////////////////////////////////////////////////
- //서로 merge할 cell들을 계산하여 array에 넣어줌
- for(var iIndex = 0 ; iIndex < iTotalColNum -1; iIndex++){
- //0 : 표준, 1 : checklist 이므로 continue
- if(iIndex == 0 || iIndex == 1){
- continue;
- }
-
- //null항목은 사이즈 0 설정, index가 2부터 null인 경우도 arrStartNum에 다음 iIndex를 넣어줌
- if(arr1[iIndex] == 'null'){
- //중간에 null이 있는 경우 시작 위치를 iIndex+1 부터 시작 되도록 설정
- arrStartNum[jIndex] = iIndex+1;
- grp_biz.switch1.case1.grd_chklist.setFormatColProperty(iIndex, "size", 0);
- continue;
- }
-
- //2 는 시작이므로 기본으로 시작점에 입력
- if(iIndex == 2){
- arrStartNum[jIndex] = iIndex;
- }
- else {
- //현재의 값과 다음 값이 다른 경우에 merge 처리
- if(arr1[iIndex] != arr1[iIndex+1]){
- arrEndNum[jIndex] = iIndex;
- jIndex++;
- //merge end 값을 넣어 주고 다음 merge 시작 값을 넣어줌
- arrStartNum[jIndex] = iIndex+1;
- }
- if(iIndex == iTotalColNum -2)
- {
- arrEndNum[jIndex] = iIndex+1;
- }
- }
- }
-
- trace(arrStartNum);
- trace(arrEndNum);
-
- //위의 루틴에서 iTotalColNum의 -2까지만 null check(iTotalColNum의 -1까지 merge 처리)하므로
- if(arr1[iTotalColNum-1] == 'null'){
- grp_biz.switch1.case1.grd_chklist.setFormatColProperty(iTotalColNum-1, "size", 0);
- }
-
- //merge 관련 array를 참고하여 merge 처리 : 앞에서 merge 처리 안되어서 뒤에서 부터 merge 처리
- for(var iIndex = arrEndNum.length-1 ; iIndex >= 0 ; iIndex--){
- //merge 처리
- grp_biz.switch1.case1.grd_chklist.mergeContentsCell("head", 0,arrStartNum[iIndex], 0,arrEndNum[iIndex], arrStartNum[iIndex], false);
-
- //title 입력 처리
- grp_biz.switch1.case1.grd_chklist.setCellProperty("head", arrStartNum[iIndex], "text", arr1[arrStartNum[iIndex]]);
- }
- //////////////////////////////////////////////////////////////////////////////////////////////////////////////////
-
-
- }
- //20180124 이돈희 : 월별로 입력 자료 이므로 월별 code 조회
- function fInitCode()
- {
- var curdd = grp_biz.grp_sea.ipt_workmm.value + "01";
-
- dsf_makeValue(ds_send_reqdata, "srchdd", "string", curdd);
- dsf_makeValue(ds_send_reqdata, "cdgrupid", "string", "'U12'");
- dsf_makeValue(ds_send_reqdata, "flag", "string", "1");
-
- var oParam = {};
- oParam.id = "TRMNW00001";
- oParam.service = "wardcareapp.WardCareMngt";
- oParam.method = "reqGetNursHardCdInfo";
- oParam.inds = "req=ds_send_reqdata";
- oParam.outds = "ds_cond_codeinfo_codelist=codelist";
- oParam.async = false;
- tranf_submit(oParam);
- }
- function fSearch(){
-
- //타이틀 초기화
- fTitleInitialize();
-
- //조회할때 해당 월의 코드 조회
- fInitCode();
-
- dsf_makeValue(ds_send_reqdata, "workmm", "string", String(grp_biz.grp_sea.ipt_workmm.value).substr(0, 6));
-
- var oParam = {};
- oParam.id = "TRMNG04702";
- oParam.service = "csrapp.CsrMngt";
- oParam.method = "reqGetEqCheckInfo";
- oParam.inds = "req=ds_send_reqdata";
- oParam.outds = "ds_temp_chkinfo_chklist=chklist ds_temp_chkinfo_chklist2=chklist2";
- oParam.async = false;
- tranf_submit(oParam);
-
- ds_main_chkinfo_chklist.copyData(ds_temp_chkinfo_chklist);
- ds_main_chkinfo_chklist2.copyData(ds_temp_chkinfo_chklist2);
-
- ds_main_chkinfo_chklist.addColumn("line", "string");
-
- var rows = ds_main_chkinfo_chklist.rowcount;
-
- //var height = rows * 23 + 19;
- //grd_chklist.attribute("height") = height;
-
- var chkdivsnm;
- var chkdivsnm2;
-
- for(var i = 0; i < ds_main_chkinfo_chklist.rowcount; i++) {
-
- if(i == 0) {
- chkdivsnm = ds_main_chkinfo_chklist.getColumn(i, "chkdivsnm");
- chkdivsnm2 = ds_main_chkinfo_chklist.getColumn(i, "chkdivsnm");
- } else {
- chkdivsnm = ds_main_chkinfo_chklist.getColumn(i-1, "chkdivsnm");
- chkdivsnm2 = ds_main_chkinfo_chklist.getColumn(i, "chkdivsnm");
- }
-
- if(chkdivsnm != chkdivsnm2) {
- dsf_makeValue(ds_main_chkinfo_chklist, "chkflag", "string", "1", (i-2));
- dsf_makeValue(ds_temp_chkinfo_chklist, "chkflag", "string", "1", (i-2));
-
- ds_main_chkinfo_chklist.setColumn(i - 1, "line", "1 solid #B0B0B0, 1 solid #B0B0B0, 2 solid blue, 1 solid #B0B0B0");
- } else {
- dsf_makeValue(ds_main_chkinfo_chklist, "chkflag", "string", "0", (i-1));
- dsf_makeValue(ds_temp_chkinfo_chklist, "chkflag", "string", "0", (i-1));
- }
- }
-
- var stat;
-
- for(var i = 0; i < ds_main_chkinfo_chklist2.rowcount; i++) {
- stat = ds_main_chkinfo_chklist2.getColumn(i, "stat");
-
- if(stat=="1") {
- ds_main_chkinfo_chklist2.enableevent = false;
- ds_main_chkinfo_chklist2.updatecontrol = false;
- ds_main_chkinfo_chklist2.setRowType(i, 2);
- ds_main_chkinfo_chklist2.updatecontrol = true;
- ds_main_chkinfo_chklist2.enableevent = true;
- } else {
- ds_main_chkinfo_chklist2.enableevent = false;
- ds_main_chkinfo_chklist2.updatecontrol = false;
- ds_main_chkinfo_chklist2.setRowType(i, 1);
- ds_main_chkinfo_chklist2.updatecontrol = true;
- ds_main_chkinfo_chklist2.enableevent = true;
- }
- }
- }
- function grp_biz_grp_sea_button2_onclick(obj:Button, e:ClickEventInfo)
- {
- fSearch();
- }
- function grp_biz_grp_sea_button1_onclick(obj:Button, e:ClickEventInfo)
- {
- fSave();
- }
- function fSave() {
- var tempPath = ds_temp_chkinfo_chklist;
- var mainPath = ds_main_chkinfo_chklist;
-
- var nodecnt = ds_main_chkinfo_chklist.rowcount;
-
- var updtheader="workmm▦fixasetcd▦chkid▦chkyn▩";
- var updtdata = "";
-
- var tempval;
- var mainval;
- var eq;
- for(var i = 0; i < nodecnt; i++) {
- for(var j = 1; j <= 11; j++) {
- tempval = tempPath.getColumn(i, "eq" + j);
- mainval = mainPath.getColumn(i, "eq" + j);
-
- if(tempval != mainval) {
-
- if(mainPath.getColumn(i, "eq" + j) == "Y" || mainPath.getColumn(i, "eq" + j) == "1"){
- eq = "Y";
- }else{
- // 20200129 김현석 N 체크를 안 하도록
- //eq = "N";
- eq = "";
- }
-
- updtdata += mainPath.getColumn(i, "workmm") + "▦"
- + mainPath.getColumn(i, "eqcd" + j) + "▦"
- + mainPath.getColumn(i, "chkid") + "▦"
- + eq + "▩"
- }
- }
- }
-
- ds_main_chkinfo_chklist2.enableevent = false;
- ds_main_chkinfo_chklist2.updatecontrol = false;
- for(var i = 0; i < ds_main_chkinfo_chklist2.rowcount ;i++){
- // 20191210 김현석, 점검일자가 들어간 경우에만 Y,N를 입력 되도록 수정
- if (! utlf_isNull(ds_main_chkinfo_chklist2.getColumn(i, "chkdd")))
- {
- if(ds_main_chkinfo_chklist2.getColumn(i, "statyn") == "Y" || ds_main_chkinfo_chklist2.getColumn(i, "statyn") == "1"){
- ds_main_chkinfo_chklist2.setColumn(i, "statyn", "Y");
- }else{
- ds_main_chkinfo_chklist2.setColumn(i, "statyn", "N");
- }
- }
- else
- {
- ds_main_chkinfo_chklist2.setColumn(i, "statyn", "");
- }
- }
- ds_main_chkinfo_chklist2.updatecontrol = true;
- ds_main_chkinfo_chklist2.enableevent = true;
-
- var updtdata2 = grdf_getGridUpdateData(grp_biz.switch1.case2.grd_chklist2);
- grdf_setStatusColumn(updtdata2, "status");
-
- if(utlf_isNull(updtdata) && (utlf_isNull(updtdata2) || updtdata2.rowcount == 0)) {
- sysf_messageBox("저장할 데이터가 존재하지 않습니다.", "E");
- return;
- }
-
- dsf_setCSVToDs("ds_send_savedata_chklist", updtheader + updtdata);
- ds_send_savedata_chklist2.copyData(updtdata2);
- var oParam = {};
- oParam.id = "TXMNG04701";
- oParam.service = "csrapp.CsrMngt";
- oParam.method = "reqExeEqCheckInfo";
- oParam.inds = "req=ds_send_savedata_chklist req2=ds_send_savedata_chklist2";
- oParam.outds = "";
- oParam.async = false;
- tranf_submit(oParam);
-
- sysf_messageBox("저장하였습니다.", "E");
-
- fSearch();
- }
- function grp_biz_switch1_case2_grd_chklist2_onexpanddown(obj:Grid, e:GridMouseEventInfo)
- {
- var iCol = grp_biz.switch1.case2.grd_chklist2.currentcol;
- var iRow = ds_main_chkinfo_chklist2.rowposition;
-
- if(iCol == grp_biz.switch1.case2.grd_chklist2.getBindCellIndex("body", "certnm")) {
- ds_main_chkinfo_chklist2.setColumn(iRow, "certnm", sysf_getUserInfo("usernm"));
- ds_main_chkinfo_chklist2.setColumn(iRow, "certid", sysf_getUserInfo("userid"));
- }
-
- if(iCol == grp_biz.switch1.case2.grd_chklist2.getBindCellIndex("body", "certnm2")) {
- ds_main_chkinfo_chklist2.setColumn(iRow, "certnm2", sysf_getUserInfo("usernm"));
- ds_main_chkinfo_chklist2.setColumn(iRow, "certid2", sysf_getUserInfo("userid"));
- }
-
- if(ds_main_chkinfo_chklist2.getRowType(iRow) == "1" ) {
- ds_main_chkinfo_chklist2.enableevent = false;
- ds_main_chkinfo_chklist2.updatecontrol = false;
- ds_main_chkinfo_chklist2.setRowType(iRow, 4);
- ds_main_chkinfo_chklist2.updatecontrol = true;
- ds_main_chkinfo_chklist2.enableevent = true;
- }
- }
- function grp_biz_grp_sea_button5_onclick(obj:Button, e:ClickEventInfo)
- {
- fPrint();
- }
- function fPrint() {
-
- for(var i = 0; i < grp_biz.switch1.case1.grd_chklist.getCellCount("Head"); i++) {
- var title = grp_biz.switch1.case1.grd_chklist.getCellProperty("Head", i, "text");
- // 20191210, 김현석, null 값인 경우 ""으로 치환
- if (title == "null")
- title = "";
-
- if(i < 5){
- dsf_makeValue(ds_temp_title , "title" + grp_biz.switch1.case1.grd_chklist.getCellProperty("Head", i, "col"), "string", title);
- }else{
- dsf_makeValue(ds_temp_title2, "title" + grp_biz.switch1.case1.grd_chklist.getCellProperty("Head", i, "col"), "string", title);
- }
- }
-
- var colCnt = grp_biz.switch1.case2.grd_chklist2.getBindCellIndex("body", "certnm2") - grp_biz.switch1.case2.grd_chklist2.getBindCellIndex("body", "statyn");
-
- var idx = grp_biz.switch1.case2.grd_chklist2.getBindCellIndex("body", "statyn");
-
- var cnt = 0;
- var fixasetcd ="";
- var fixasetcd2 = "";
- var grupdetldesc = "";
- var grupdetldesc2 = "";
- var str="";
- var cmt = "";
- var idx= 0;
-
- for(var i = 0; i < ds_main_chkinfo_chklist2.rowcount; i++) {
- cmt = grp_biz.switch1.case2.grd_chklist2.getCellValue(i, grp_biz.switch1.case2.grd_chklist2.getBindCellIndex("body", "cmt"));
-
- if(i == 0) {
- fixasetcd = grp_biz.switch1.case2.grd_chklist2.getCellValue(i , grp_biz.switch1.case2.grd_chklist2.getBindCellIndex("body", "fixasetcd"));
- fixasetcd2 = grp_biz.switch1.case2.grd_chklist2.getCellValue(i , grp_biz.switch1.case2.grd_chklist2.getBindCellIndex("body", "fixasetcd"));
- } else {
- fixasetcd = grp_biz.switch1.case2.grd_chklist2.getCellValue(i-1 , grp_biz.switch1.case2.grd_chklist2.getBindCellIndex("body", "fixasetcd"));
- fixasetcd2 = grp_biz.switch1.case2.grd_chklist2.getCellValue(i , grp_biz.switch1.case2.grd_chklist2.getBindCellIndex("body", "fixasetcd"));
- }
-
- grupdetldesc = ds_cond_codeinfo_codelist.lookup("cdid", fixasetcd, "grupdetldesc");
- grupdetldesc2 = ds_cond_codeinfo_codelist.lookup("cdid", fixasetcd2, "grupdetldesc");
-
- if(grupdetldesc != grupdetldesc2) {
- dsf_makeValue(ds_printinfo_cmtinfo,"cmt" + cnt,"string",str);
- str = cmt;
- cnt++;
- if(i == ds_main_chkinfo_chklist2.rowcount - 1) {
- dsf_makeValue(ds_printinfo_cmtinfo,"cmt" + cnt,"string",str);
- }
-
- } else {
- if( !utlf_isNull(cmt) ) {
- if(idx == 0) {
- str += cmt;
- idx++;
- } else {
- str += ", " + cmt;
- }
- }
- }
-
- for(var j = idx; j <= idx + colCnt; j++) {
- var statyn = "";
-
- if (!utlf_isNull(grp_biz.switch1.case2.grd_chklist2.getCellValue(i, grp_biz.switch1.case2.grd_chklist2.getBindCellIndex("body", "chkdd"))))
- {
- statyn = grp_biz.switch1.case2.grd_chklist2.getCellValue(i, grp_biz.switch1.case2.grd_chklist2.getBindCellIndex("body", "statyn"));
- }
- //dsf_makeValue(ds_printinfo_statinfo ,"stat" + (i +1) ,"string", grp_biz.switch1.case2.grd_chklist2.getCellValue(i, grp_biz.switch1.case2.grd_chklist2.getBindCellIndex("body", "statyn")) );
- dsf_makeValue(ds_printinfo_statinfo ,"stat" + (i +1) ,"string", statyn );
-
- dsf_makeValue(ds_printinfo_chkddinfo,"chkdd" + (i+ 1),"string",grp_biz.switch1.case2.grd_chklist2.getCellValue(i, grp_biz.switch1.case2.grd_chklist2.getBindCellIndex("body", "chkdd")) );
- dsf_makeValue(ds_printinfo_chknminfo,"chknm" + (i+1),"string",utlf_transNullToEmpty(grp_biz.switch1.case2.grd_chklist2.getCellValue(i, grp_biz.switch1.case2.grd_chklist2.getBindCellIndex("body", "chknm"))) + "/" + utlf_transNullToEmpty(grp_biz.switch1.case2.grd_chklist2.getCellValue(i, grp_biz.switch1.case2.grd_chklist2.getBindCellIndex("body", "certnm"))) );
- dsf_makeValue(ds_printinfo_certnm2info,"certnm2" + (i+1),"string",grp_biz.switch1.case2.grd_chklist2.getCellValue(i, grp_biz.switch1.case2.grd_chklist2.getBindCellIndex("body", "certnm2")) );
- }
- }
-
- //미리보기출력
- var objDOM = rptf_createDOM();
- rptf_setNodeListToDOM(objDOM, "root/main/chkinfo/chklist" , ds_main_chkinfo_chklist); // 데이터셋 1
- rptf_setNodeListToDOM(objDOM, "root/temp/title" , ds_temp_title);
- rptf_setNodeListToDOM(objDOM, "root/temp/title2" , ds_temp_title2);
- rptf_setNodeListToDOM(objDOM, "root/printinfo/statinfo" , ds_printinfo_statinfo);
- rptf_setNodeListToDOM(objDOM, "root/printinfo/chkddinfo" , ds_printinfo_chkddinfo);
- rptf_setNodeListToDOM(objDOM, "root/printinfo/chknminfo" , ds_printinfo_chknminfo);
- rptf_setNodeListToDOM(objDOM, "root/printinfo/certnminfo" , ds_printinfo_certnminfo);
- rptf_setNodeListToDOM(objDOM, "root/printinfo/cmtinfo" , ds_printinfo_cmtinfo);
- rptf_setNodeListToDOM(objDOM, "root/printinfo/certnm2info" , ds_printinfo_certnm2info);
-
- var objParam = new Object();
- objParam.xml_data_XML1 = objDOM.documentElement.source; // 최상의노드 XML 스트링 추출
-
- var option = "open=1;save=1;directprint=0;print=1;zoom=0;";
- rptf_exeReportPreview30(["RPMNG04700"],[objParam], option);
- }]]></Script>
- </Form>
- </FDL>
|