SMRAD02000_구매검수자료일괄기표.xfdl 34 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <FDL version="1.5">
  3. <TypeDefinition url="..\..\..\default_typedef.xml"/>
  4. <Form id="SMRAD02000" position="absolute 0 0 1197 787" titletext="구매검수자료일괄기표" onload="SMRAD02000_onload">
  5. <Layouts>
  6. <Layout>
  7. <Div id="grp_srch" taborder="10" position="absolute 0 51 1195 91" class="div_SA2" anchor="left top right"/>
  8. <Div position="absolute 0 26 1195 54" id="grp_btn" scrollbars="autoboth" anchor="left top right">
  9. <Layouts>
  10. <Layout>
  11. <Button position="absolute 1139 0 1195 22" id="button36" class="btn4" text="저장" anchor="right" onclick="grp_btn_button36_onclick"/>
  12. <Button position="absolute 806 0 874 22" id="button35" class="btn4" visible="false" text="초기화" anchor="right" onclick="grp_btn_button35_onclick"/>
  13. <Shape position="absolute 0 21 1195 27" id="line9" class="line_6" anchor="left top right"/>
  14. <Button position="absolute 750 0 803 22" id="button3" class="btn6" visible="false" text="출력" anchor="right" onclick="grp_btn_button3_onclick"/>
  15. <Button position="absolute 1008 0 1136 22" id="btn_change" class="btn4" text="지급처 일괄변경" anchor="right" onclick="grp_btn_btn_change_onclick"/>
  16. <Button position="absolute 877 0 1005 22" id="btn_batch" class="btn4" text="확인건 일괄체크" anchor="right" onclick="grp_btn_btn_batch_onclick"/>
  17. <Static text="※ 기표불가 자료(빨강색)가 포함되었습니다. 정보통신실로 연락하셔서 조치 후 기표가능합니다." position="absolute 160 2 743 22" align="align:right middle;" id="cpt_alert" visible="false" anchor="default" style="color:#ff0000ff;font:Dotum,9,bold;"/>
  18. </Layout>
  19. </Layouts>
  20. </Div>
  21. <Static id="caption6" text="구매검수자료일괄기표" class="tit_1" position="absolute 0 0 180 25"/>
  22. <Button id="btn_search" taborder="1" text="조회" class="btn1" position="absolute 1123 60 1179 82" anchor="right" onclick="btn_search_onclick"/>
  23. <Shape id="line13" linetype="vertical" class="line_4" position="absolute 1103 59 1109 81" anchor="right"/>
  24. <Shape id="line1" class="line_10" position="absolute 0 115 1195 121" anchor="left top right"/>
  25. <Combo id="cmb_instcd" taborder="2" class="combo_essential" enable="false" position="absolute 78 61 193 80"/>
  26. <Static id="caption2" text="기관 :" class="search_name" position="absolute 12 62 73 79"/>
  27. <Grid id="grd_grntpsn1" taborder="3" binddataset="ds_main_grnt_grntlist2" useinputpanel="false" position="absolute 0 120 1195 785" anchor="all" autoenter="select" cellclickbound="cell">
  28. <Formats>
  29. <Format id="default">
  30. <Columns>
  31. <Column size="25" band="left"/>
  32. <Column size="35"/>
  33. <Column size="69"/>
  34. <Column size="80"/>
  35. <Column size="38"/>
  36. <Column size="43"/>
  37. <Column size="120"/>
  38. <Column size="212"/>
  39. <Column size="80"/>
  40. <Column size="38"/>
  41. <Column size="101"/>
  42. <Column size="94"/>
  43. <Column size="55"/>
  44. <Column size="33"/>
  45. <Column size="36"/>
  46. <Column size="80"/>
  47. <Column size="36"/>
  48. <Column size="0"/>
  49. <Column size="0"/>
  50. <Column size="0"/>
  51. <Column size="0"/>
  52. <Column size="0"/>
  53. <Column size="0"/>
  54. <Column size="0"/>
  55. <Column size="0"/>
  56. </Columns>
  57. <Rows>
  58. <Row size="24" band="head"/>
  59. <Row size="24"/>
  60. </Rows>
  61. <Band id="head">
  62. <Cell/>
  63. <Cell col="1" text="결재"/>
  64. <Cell col="2" text="계정"/>
  65. <Cell col="3" colspan="2" text="계약일자" taborder="undefined"/>
  66. <Cell col="5" colspan="2" text="거래처" taborder="undefined"/>
  67. <Cell col="7" text="계약건명"/>
  68. <Cell col="8" colspan="2" text="검수일자" taborder="undefined"/>
  69. <Cell col="10" text="예정일자"/>
  70. <Cell col="11" text="금액"/>
  71. <Cell col="12" text="지급처"/>
  72. <Cell col="13" text="여부"/>
  73. <Cell col="14" text="순번"/>
  74. <Cell col="15" text="기표일자"/>
  75. <Cell col="16" text="확인"/>
  76. <Cell col="17" text="caption4"/>
  77. <Cell col="18" text="caption5"/>
  78. <Cell col="19" text="caption1"/>
  79. <Cell col="20" text="caption2"/>
  80. <Cell col="21" text="caption3"/>
  81. <Cell col="22" text="caption6"/>
  82. <Cell col="23" text="caption7"/>
  83. <Cell col="24" text="caption8"/>
  84. </Band>
  85. <Band id="body">
  86. <Cell celltype="head"/>
  87. <Cell col="1" style="background:EXPR(utlf_isNull(ymdaction) ? 'red' : '');background2:EXPR(utlf_isNull(ymdaction) ? 'red' : '');font:EXPR(utlf_isNull(ymdaction) ? 'Dotum,9,bold' : '');" text="bind:aprvtype"/>
  88. <Cell col="2" style="background:EXPR(utlf_isNull(ymdaction) ? 'red' : '');background2:EXPR(utlf_isNull(ymdaction) ? 'red' : '');font:EXPR(utlf_isNull(ymdaction) ? 'Dotum,9,bold' : '');" text="bind:acctid" enable="false"/>
  89. <Cell col="3" displaytype="date" style="background:EXPR(utlf_isNull(ymdaction) ? 'red' : '');background2:EXPR(utlf_isNull(ymdaction) ? 'red' : '');font:EXPR(utlf_isNull(ymdaction) ? 'Dotum,9,bold' : '');" text="bind:kydate"/>
  90. <Cell col="4" style="background:EXPR(utlf_isNull(ymdaction) ? 'red' : '');background2:EXPR(utlf_isNull(ymdaction) ? 'red' : '');font:EXPR(utlf_isNull(ymdaction) ? 'Dotum,9,bold' : '');" text="bind:kyseq"/>
  91. <Cell col="5" style="background:EXPR(utlf_isNull(ymdaction) ? 'red' : '');background2:EXPR(utlf_isNull(ymdaction) ? 'red' : '');font:EXPR(utlf_isNull(ymdaction) ? 'Dotum,9,bold' : '');" text="bind:custcode"/>
  92. <Cell col="6" displaytype="text" style="background:EXPR(utlf_isNull(ymdaction) ? 'red' : '');background2:EXPR(utlf_isNull(ymdaction) ? 'red' : '');font:EXPR(utlf_isNull(ymdaction) ? 'Dotum,9,bold' : '');" text="bind:custnm"/>
  93. <Cell col="7" displaytype="text" style="background:EXPR(utlf_isNull(ymdaction) ? 'red' : '');background2:EXPR(utlf_isNull(ymdaction) ? 'red' : '');font:EXPR(utlf_isNull(ymdaction) ? 'Dotum,9,bold' : '');" text="bind:rmrk"/>
  94. <Cell col="8" displaytype="date" style="background:EXPR(utlf_isNull(ymdaction) ? 'red' : '');background2:EXPR(utlf_isNull(ymdaction) ? 'red' : '');font:EXPR(utlf_isNull(ymdaction) ? 'Dotum,9,bold' : '');" text="bind:ibgoymd"/>
  95. <Cell col="9" style="background:EXPR(utlf_isNull(ymdaction) ? 'red' : '');background2:EXPR(utlf_isNull(ymdaction) ? 'red' : '');font:EXPR(utlf_isNull(ymdaction) ? 'Dotum,9,bold' : '');" text="bind:ibgoseq"/>
  96. <Cell col="10" displaytype="date" edittype="date" style="padding:0 0 0 0;background:EXPR(utlf_isNull(ymdaction) ? 'red' : '');background2:EXPR(utlf_isNull(ymdaction) ? 'red' : '');font:EXPR(utlf_isNull(ymdaction) ? 'Dotum,9,bold' : '');" text="bind:yejungymd" editdisplay="edit" calendardisplay="display"/>
  97. <Cell col="11" displaytype="number" edittype="masknumber" style="background:EXPR(utlf_isNull(ymdaction) ? 'red' : '');background2:EXPR(utlf_isNull(ymdaction) ? 'red' : '');font:EXPR(utlf_isNull(ymdaction) ? 'Dotum,9,bold' : '');" text="bind:keumak"/>
  98. <Cell col="12" displaytype="combo" edittype="combo" style="background:EXPR(utlf_isNull(ymdaction) ? 'red' : '');background2:EXPR(utlf_isNull(ymdaction) ? 'red' : '');font:EXPR(utlf_isNull(ymdaction) ? 'Dotum,9,bold' : '');" text="bind:flagbank" combodataset="ds_cmb_flagbank" combocodecol="value" combodatacol="label"/>
  99. <Cell col="13" displaytype="checkbox" edittype="checkbox" style="background:EXPR(utlf_isNull(ymdaction) ? 'red' : '');background2:EXPR(utlf_isNull(ymdaction) ? 'red' : '');font:EXPR(utlf_isNull(ymdaction) ? 'Dotum,9,bold' : '');" text="bind:flag" expr="expr:(flag==&quot;Y&quot;||flag==1)?1:0"/>
  100. <Cell col="14" style="background:EXPR(utlf_isNull(ymdaction) ? 'red' : '');background2:EXPR(utlf_isNull(ymdaction) ? 'red' : '');font:EXPR(utlf_isNull(ymdaction) ? 'Dotum,9,bold' : '');" text="bind:gipyoseq"/>
  101. <Cell col="15" displaytype="date" style="background:EXPR(utlf_isNull(ymdaction) ? 'red' : '');background2:EXPR(utlf_isNull(ymdaction) ? 'red' : '');font:EXPR(utlf_isNull(ymdaction) ? 'Dotum,9,bold' : '');" text="bind:gipyoymd"/>
  102. <Cell col="16" style="background:EXPR(utlf_isNull(ymdaction) ? 'red' : '');background2:EXPR(utlf_isNull(ymdaction) ? 'red' : '');font:EXPR(utlf_isNull(ymdaction) ? 'Dotum,9,bold' : '');" text="bind:elecaprvyn"/>
  103. <Cell col="17" text="bind:gubun"/>
  104. <Cell col="18" text="bind:ymdwrite"/>
  105. <Cell col="19" text="bind:fromdd"/>
  106. <Cell col="20" text="bind:kyno"/>
  107. <Cell col="21" text="bind:seqwrite"/>
  108. <Cell col="22" text="bind:maxseq"/>
  109. <Cell col="23" text="bind:ymdaction"/>
  110. <Cell col="24" text="bind:entrregno"/>
  111. </Band>
  112. </Format>
  113. </Formats>
  114. </Grid>
  115. <Calendar id="ipt_unsldd" taborder="4" class="input_essential" position="absolute 320 61 435 80" onchanged="ipt_unsldd_onchanged"/>
  116. <Static id="caption5" text="기표일자 :" class="search_name" position="absolute 230 62 316 79"/>
  117. <Static id="caption1" text="구매검수내역" class="tit_2" position="absolute 0 99 131 116"/>
  118. <Edit id="input1" taborder="5" position="absolute 659 61 789 80" onkeyup="input1_onkeyup"/>
  119. <Edit id="input2" taborder="6" visible="false" position="absolute 460 61 560 80"/>
  120. <Edit id="output1" taborder="7" readonly="true" position="absolute 820 61 860 80" class="edt_transbg"/>
  121. <Static id="caption4" text="검색어 :" class="search_name" position="absolute 580 60 655 82"/>
  122. <Static id="caption3" text="※ 기표처리 이후에는 예정일자, 금액의 변경이 불가합니다." position="absolute 130 99 495 116" style="color:#ff0000ff;font:Dotum,9,bold;"/>
  123. <Button id="button1" taborder="8" text="엑셀출력" class="btn7" position="absolute 1115 93 1195 115" anchor="right" onclick="button1_onclick"/>
  124. <MaskEdit id="ipt_totamt" taborder="9" mask="(-)#,###" position="absolute 803 96 923 115"/>
  125. </Layout>
  126. </Layouts>
  127. <Objects>
  128. <Dataset id="ds_hidden_item" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="keep">
  129. <ColumnInfo>
  130. <Column id="pumno" type="STRING" size="256"/>
  131. </ColumnInfo>
  132. <Rows>
  133. <Row>
  134. <Col id="pumno"/>
  135. </Row>
  136. </Rows>
  137. </Dataset>
  138. <Dataset id="ds_hidden" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="keep">
  139. <ColumnInfo/>
  140. </Dataset>
  141. <Dataset id="ds_maxseq" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="keep">
  142. <ColumnInfo>
  143. <Column id="maxseq" type="STRING" size="256"/>
  144. </ColumnInfo>
  145. <Rows>
  146. <Row>
  147. <Col id="maxseq"/>
  148. </Row>
  149. </Rows>
  150. </Dataset>
  151. <Dataset id="ds_send_paydedu" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="keep" oncolumnchanged="ds_send_paydedu_oncolumnchanged">
  152. <ColumnInfo>
  153. <Column id="instcd" type="STRING" size="256"/>
  154. <Column id="fromdd" type="STRING" size="256"/>
  155. <Column id="todd" type="STRING" size="256"/>
  156. <Column id="kyno" type="STRING" size="256"/>
  157. <Column id="chk" type="STRING" size="256"/>
  158. <Column id="totamt" type="STRING" size="256"/>
  159. </ColumnInfo>
  160. <Rows>
  161. <Row>
  162. <Col id="instcd"/>
  163. <Col id="fromdd"/>
  164. <Col id="todd"/>
  165. <Col id="kyno"/>
  166. <Col id="chk"/>
  167. <Col id="totamt"/>
  168. </Row>
  169. </Rows>
  170. </Dataset>
  171. <Dataset id="ds_seqinfo_seqlist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="keep">
  172. <ColumnInfo>
  173. <Column id="flagseq" type="STRING" size="256"/>
  174. </ColumnInfo>
  175. <Rows>
  176. <Row>
  177. <Col id="flagseq"/>
  178. </Row>
  179. </Rows>
  180. </Dataset>
  181. <Dataset id="ds_main_grnt_grntlist2" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="keep" oncolumnchanged="ds_main_grnt_grntlist2_oncolumnchanged">
  182. <ColumnInfo>
  183. <Column id="acctid" type="STRING" size="256"/>
  184. <Column id="kydate" type="STRING" size="256"/>
  185. <Column id="kyseq" type="STRING" size="256"/>
  186. <Column id="custcode" type="STRING" size="256"/>
  187. <Column id="custnm" type="STRING" size="256"/>
  188. <Column id="rmrk" type="STRING" size="256"/>
  189. <Column id="ibgoymd" type="STRING" size="256"/>
  190. <Column id="ibgoseq" type="STRING" size="256"/>
  191. <Column id="yejungymd" type="STRING" size="256"/>
  192. <Column id="keumak" type="STRING" size="256"/>
  193. <Column id="gipyoymd" type="STRING" size="256"/>
  194. <Column id="flag" type="STRING" size="256"/>
  195. <Column id="gipyoseq" type="STRING" size="256"/>
  196. <Column id="gubun" type="STRING" size="256"/>
  197. <Column id="ymdwrite" type="STRING" size="256"/>
  198. <Column id="fromdd" type="STRING" size="256"/>
  199. <Column id="kyno" type="STRING" size="256"/>
  200. <Column id="seqwrite" type="STRING" size="256"/>
  201. <Column id="maxseq" type="STRING" size="256"/>
  202. <Column id="ymdaction" type="STRING" size="256"/>
  203. <Column id="flagbank" type="STRING" size="256"/>
  204. <Column id="entrregno" type="STRING" size="256"/>
  205. <Column id="aprvtype" type="STRING" size="256"/>
  206. <Column id="elecaprvyn" type="STRING" size="256"/>
  207. </ColumnInfo>
  208. <Rows>
  209. <Row>
  210. <Col id="acctid"/>
  211. <Col id="kydate"/>
  212. <Col id="kyseq"/>
  213. <Col id="custcode"/>
  214. <Col id="custnm"/>
  215. <Col id="rmrk"/>
  216. <Col id="ibgoymd"/>
  217. <Col id="ibgoseq"/>
  218. <Col id="yejungymd"/>
  219. <Col id="keumak"/>
  220. <Col id="gipyoymd"/>
  221. <Col id="flag"/>
  222. <Col id="gipyoseq"/>
  223. <Col id="gubun"/>
  224. <Col id="ymdwrite"/>
  225. <Col id="fromdd"/>
  226. <Col id="kyno"/>
  227. <Col id="seqwrite"/>
  228. <Col id="maxseq"/>
  229. <Col id="ymdaction"/>
  230. <Col id="flagbank"/>
  231. <Col id="entrregno"/>
  232. <Col id="aprvtype"/>
  233. <Col id="elecaprvyn"/>
  234. </Row>
  235. </Rows>
  236. </Dataset>
  237. <Dataset id="ds_send_save_grntlist1" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="keep"/>
  238. <Dataset id="ds_cmb_flagbank" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  239. <ColumnInfo>
  240. <Column id="label" type="STRING" size="256"/>
  241. <Column id="value" type="STRING" size="256"/>
  242. </ColumnInfo>
  243. <Rows>
  244. <Row>
  245. <Col id="label">은행</Col>
  246. <Col id="value">1</Col>
  247. </Row>
  248. <Row>
  249. <Col id="label">직불</Col>
  250. <Col id="value">2</Col>
  251. </Row>
  252. <Row>
  253. <Col id="label">자동</Col>
  254. <Col id="value">3</Col>
  255. </Row>
  256. <Row>
  257. <Col id="label">전자</Col>
  258. <Col id="value">4</Col>
  259. </Row>
  260. </Rows>
  261. </Dataset>
  262. </Objects>
  263. <Bind>
  264. <BindItem id="item0" compid="cmb_instcd" propid="value" datasetid="ds_send_paydedu" columnid="instcd"/>
  265. <BindItem id="item1" compid="ipt_unsldd" propid="value" datasetid="ds_send_paydedu" columnid="fromdd"/>
  266. <BindItem id="item2" compid="input1" propid="value" datasetid="ds_send_paydedu" columnid="kyno"/>
  267. <BindItem id="item3" compid="input2" propid="value" datasetid="ds_send_paydedu" columnid="chk"/>
  268. <BindItem id="item4" compid="output1" propid="value" datasetid="ds_seqinfo_seqlist" columnid="flagseq"/>
  269. <BindItem id="item5" compid="ipt_totamt" propid="value" datasetid="ds_send_paydedu" columnid="totamt"/>
  270. </Bind>
  271. <Script type="xscript4.0"><![CDATA[/***************************************************************************************
  272. * System Name :
  273. * Job Name :
  274. * Creator :
  275. * Make Date : 2017-12-04
  276. * Description :
  277. *---------------------------------------------------------------------------------------
  278. * Modify Date Modifier Modify Description
  279. *---------------------------------------------------------------------------------------
  280. * 2017-06-19 Live Converter TF->XP
  281. *
  282. *---------------------------------------------------------------------------------------
  283. ****************************************************************************************/
  284. //=======================================================================================
  285. // Lib Include
  286. //---------------------------------------------------------------------------------------
  287. include "com_commonxp::comm_main.xjs";
  288. include "mis_miscommonxp::MIS.xjs";
  289. include "mis_paybaseinfomngtxp::RWC001.xjs";
  290. include "mis_humtrafactmngtxp::RPB001.xjs";
  291. include "mis_miscommonxp::RAC001.xjs";
  292. include "mis_acntcommonxp::RAD001.xjs";
  293. //=======================================================================================
  294. // Global Form Variable
  295. //---------------------------------------------------------------------------------------
  296. var arErrorCode = new HashArray();
  297. //=======================================================================================
  298. // Function
  299. //---------------------------------------------------------------------------------------
  300. /*-**************************************************************************************
  301. * Argument : N/A
  302. * Description :
  303. ****************************************************************************************/
  304. // function fOpenPopupDeptHelp(pControl, pInstance)
  305. // {
  306. // misfOpenPopUpList("02", pControl, "", pInstance);
  307. //
  308. // //model.refresh();
  309. //
  310. // }
  311. // function fOpenPopupHelp(pHelper, pControl, pInstance, pCdgrupid, pValueControl, pNodeName)
  312. // {
  313. // misfOpenPopUpList(pHelper, pControl, pCdgrupid, pInstance, pValueControl, pNodeName);
  314. //
  315. // //model.refresh();
  316. //
  317. // }
  318. /*-**************************************************************************************
  319. * Argument : N/A
  320. * Description : 초기화
  321. ****************************************************************************************/
  322. function initialize(){
  323. misfGridInit(grd_grntpsn1);
  324. misfMsterDetailSet(grd_grntpsn1, null, "TRRAD02001" ,"Y");
  325. var curdate = utlf_getCurrentDate();
  326. cmb_instcd.value = sysf_getUserInfo("dutplceinstcd");
  327. var deptcd = sysf_getUserInfo("dutplcecd");
  328. var deptnm = sysf_getUserInfo("dutplcenm");
  329. ds_send_paydedu.setColumn( 0, "fromdd", curdate); //기표일자 setting
  330. misfComboInstCdListMulti("cmb_instcd",utlf_getCurrentDate(),"","N"); //기관코드 setting
  331. ds_send_paydedu.setColumn( 0, "chk", "1");
  332. misfMsterDetailRetrieve(); //조회 및 그리드 setting
  333. //2011.05.02 박준범 - maxseq를 setting한다.
  334. if( ds_main_grnt_grntlist2.rowcount > 0 ){
  335. ds_maxseq.setColumn( 0, "maxseq", ds_main_grnt_grntlist2.getColumn(0, "maxseq") );
  336. } else {
  337. ds_maxseq.setColumn( 0, "maxseq", "0");
  338. }
  339. //2011.04.28 박준범 - ymdaction 이 null 인 경우, 기표시 error 가 발생하므로 사전에 data를 구분하기 위해
  340. //빨강색이 되도록 한다.
  341. for(var i = 0 ; i < ds_main_grnt_grntlist2.rowcount ; i++) {
  342. if(utlf_isNull(ds_main_grnt_grntlist2.getColumn(i, "ymdaction"))) {
  343. // grd_grntpsn1.rowStyle(i, "all", "color") = "red";
  344. // grd_grntpsn1.rowStyle(i, "all", "font-weight") = "bold";
  345. grp_btn.cpt_alert.visible = true;
  346. }else{
  347. // grd_grntpsn1.rowStyle(i, "all", "color") = "";
  348. // grd_grntpsn1.rowStyle(i, "all", "font-weight") = "";
  349. }
  350. }
  351. ds_main_grnt_grntlist2.rowposition = 0;
  352. }
  353. // function Popup(){
  354. // var ymd = ds_main_grnt_grntlist1.getColumn(0, "junpyodate");
  355. // var mdeptcd = ds_main_grnt_grntlist1.getColumn(0, "makedeptcd");
  356. // var ydeptcd = ds_main_grnt_grntlist1.getColumn(0, "yogudeptcd");
  357. // if (ymd != "" && mdeptcd != "" && ydeptcd != ""){
  358. // ds_popdata.setColumn( 0, "junpyodate", ymd);
  359. // ds_popdata.setColumn( 0, "makedeptcd", mdeptcd);
  360. // ds_popdata.setColumn( 0, "yogudeptcd", ydeptcd);
  361. // ds_popdata.setColumn( 0, "pumgubun", "3");
  362. // frmf_modal("SPRAD00400", "SPRAD00400", "ds_popdata""-"ds_popdata"", "", "", "", "", "", "", "", "", "", "M");
  363. // }
  364. // }
  365. /*-**************************************************************************************
  366. * Argument : N/A
  367. * Description : gipyoseq setting
  368. ****************************************************************************************/
  369. function Setseq(){
  370. //2011.05.02 박준범 - seq 생성하는 것 새로 생성
  371. var curseq; //현재의 maxseq를 담기위한 변수
  372. if( ds_main_grnt_grntlist2.getColumn(ds_main_grnt_grntlist2.rowposition, "flag") == "Y" ) {
  373. curseq = parseInt(ds_maxseq.getColumn(0, "maxseq")) + 1;
  374. ds_main_grnt_grntlist2.setColumn(ds_main_grnt_grntlist2.rowposition, "gipyoseq", curseq);
  375. } else {
  376. curseq = parseInt(ds_maxseq.getColumn(0, "maxseq")) - 1;
  377. ds_main_grnt_grntlist2.setColumn(ds_main_grnt_grntlist2.rowposition, "gipyoseq", "");
  378. }
  379. ds_maxseq.setColumn( 0, "maxseq", curseq);
  380. //2011.05.02 박준범
  381. // 이미 기표된 것을 check 해지 후 저장하지 않은 상태에서 다시 check할 경우, row가 수정된 것으로 인식되는데,
  382. // 이 경우는 row가 수정된 것으로 인식되지 않도록 row의 status 를 강제 조정한다.
  383. //2011.05.04 박준범
  384. // 기표가 안된 것인데 check했다가 check를 해지했을 경우 row가 수정된 것으로 인식하므로
  385. // 이 경우도 row가 수정된 것으로 인식하시 않도록 row의 status를 강제 조정한다.
  386. if( (ds_main_grnt_grntlist2.getColumn(ds_main_grnt_grntlist2.rowposition, "flag") == "Y" && !utlf_isNull(ds_main_grnt_grntlist2.getColumn(ds_main_grnt_grntlist2.rowposition, "gipyoymd")))
  387. || (ds_main_grnt_grntlist2.getColumn(ds_main_grnt_grntlist2.rowposition, "flag") == "N" && utlf_isNull(ds_main_grnt_grntlist2.getColumn(ds_main_grnt_grntlist2.rowposition, "gipyoymd"))) ) {
  388. grdf_setStatus(grd_grntpsn1, "N", [ds_main_grnt_grntlist2.rowposition]);
  389. }
  390. }
  391. //=======================================================================================
  392. // Event
  393. //---------------------------------------------------------------------------------------
  394. /****************************************************************************************
  395. * Components : Form
  396. * Description : 화면 처음 초기화시 폼초기화
  397. ****************************************************************************************/
  398. function SMRAD02000_onload(obj:Form, e:LoadEventInfo) {
  399. frmf_initForm(obj);
  400. //grdf_initGrid(grd_XXX);
  401. //grdf_setGridSort(grd_XXX);
  402. grdf_setRowTypeIcon(grd_grntpsn1, 0);
  403. initialize();
  404. }
  405. /****************************************************************************************
  406. * Components : Button
  407. * Description : 조회
  408. ****************************************************************************************/
  409. function btn_search_onclick(obj:Button, e:ClickEventInfo) {
  410. var totamt = 0; //금액총계
  411. grp_btn.cpt_alert.visible = false;
  412. ipt_totamt.value = "";
  413. ds_send_paydedu.setColumn( 0, "chk", "2");
  414. misfMsterDetailRetrieve();
  415. //2011.05.02 박준범 - maxseq를 setting한다.
  416. if( ds_main_grnt_grntlist2.rowcount > 0 ){
  417. ds_maxseq.setColumn( 0, "maxseq", ds_main_grnt_grntlist2.getColumn(0, "maxseq") );
  418. } else {
  419. ds_maxseq.setColumn( 0, "maxseq", "0");
  420. }
  421. //2011.04.28 박준범 - ymdaction 이 null 인 경우, 기표시 error 가 발생하므로 사전에 data를 구분하기 위해
  422. // 빨강색이 되도록 한다.
  423. for(var i = 0 ; i < ds_main_grnt_grntlist2.rowcount ; i++) {
  424. if(utlf_isNull(ds_main_grnt_grntlist2.getColumn(i, "ymdaction"))) {
  425. // grd_grntpsn1.rowStyle(i, "all", "color") = "red";
  426. // grd_grntpsn1.rowStyle(i, "all", "font-weight") = "bold";
  427. grp_btn.cpt_alert.visible = true;
  428. } else {
  429. // grd_grntpsn1.rowStyle(i, "all", "color") = "";
  430. // grd_grntpsn1.rowStyle(i, "all", "font-weight") = "";
  431. }
  432. //2012.03.02 박준범 - 전표처리된 것을 예정일자,금액을 변경하여 저장하면 전표가 또 생성되는 오류가 발생함
  433. // 그래서 전표처리가 된 것은 예정일자,금액을 변경하지 못하도록 컬럼 disable처리함
  434. // 전표처리 후 예정일자의 변경은 "예정일자 일괄변경" 프로그램을 사용토록 함
  435. if(ds_main_grnt_grntlist2.getColumn(i, "flag") == "Y") {
  436. misfSetReadOnlyCol(grd_grntpsn1, "yejungymd,keumak", true, i);
  437. //2013.06.18. 기표처리 후 지급처를 수정할 수 있기 때문에 comment처리
  438. //grd_grntpsn1.cellAttribute("disabled", i, grd_grntpsn1.colRef("flagbank") ) = "true"; //2013.06.12 박준범-Grid에 지급처를 추가하면서 추가
  439. totamt = parseFloat(totamt) + parseFloat(ds_main_grnt_grntlist2.getColumn(i, "keumak"));
  440. } else {
  441. misfSetReadOnlyCol(grd_grntpsn1, "yejungymd,keumak", false, i);
  442. //2013.06.18. 기표처리 후 지급처를 수정할 수 있기 때문에 comment처리
  443. //grd_grntpsn1.cellAttribute("disabled", i, grd_grntpsn1.colRef("flagbank") ) = "false"; //2013.06.12 박준범-Grid에 지급처를 추가하면서 추가
  444. }
  445. }
  446. ipt_totamt.value = totamt;
  447. ds_main_grnt_grntlist2.rowposition = 0;
  448. }
  449. /****************************************************************************************
  450. * Components : Edit
  451. * Description : 검색어 입력 후 처리
  452. ****************************************************************************************/
  453. function input1_onkeyup(obj:Edit, e:KeyEventInfo) {
  454. if(e.keycode == 13) {
  455. obj.updateToDataset();
  456. }
  457. }
  458. /****************************************************************************************
  459. * Components : Button
  460. * Description : 엑셀저장
  461. ****************************************************************************************/
  462. function button1_onclick(obj:Button, e:ClickEventInfo) {
  463. misfSaveExcel(grd_grntpsn1, "excel");
  464. }
  465. /****************************************************************************************
  466. * Components : Button
  467. * Description : 저장
  468. ****************************************************************************************/
  469. function grp_btn_button36_onclick(obj:Button, e:ClickEventInfo) {
  470. var success = misfSave("TXRAD02001");
  471. if (success){
  472. //2011.05.02 박준범 - 저장 후 다시 조회 루틴을 실행. 그렇지 않으면 삭제,저장 후 기표일자가 남아있어
  473. // 다시 check 하여 저장하면 기존에 그리드에 남아있던 일자로 전표가 또 발생하게 된다.
  474. btn_search.click();
  475. }
  476. }
  477. /****************************************************************************************
  478. * Components : Button
  479. * Description : 초기화(사용안함)
  480. ****************************************************************************************/
  481. function grp_btn_button35_onclick(obj:Button, e:ClickEventInfo) {
  482. // ds_main_grnt_grntlist1.clearData();
  483. // grd_grntpsn1.enable = true;
  484. // ipt_unsldd.enable = true;
  485. // input4.enable = true;
  486. // input14.enable = false;
  487. // input15.enable = false;
  488. // input10.enable = false;
  489. // ds_send_paydedu.setColumn( 0, "pumno1", "");
  490. // ds_send_paydedu.setColumn( 0, "pumno2", "");
  491. //
  492. // initialize();
  493. }
  494. /****************************************************************************************
  495. * Components : Button
  496. * Description : 출력(사용안함)
  497. ****************************************************************************************/
  498. function grp_btn_button3_onclick(obj:Button, e:ClickEventInfo) {
  499. // if( sysf_messageBox("출력하시겠습니까" , "Q99" ) == 6 ){
  500. // var objDOM = rptf_createDOM();
  501. // var objParam = new Object();
  502. // rptf_setNodeListToDOM(objDOM, "/root/main/grnt/grntlist3" , ds_main_grnt_grntlist2);
  503. // objParam.xml_data_XML1 = objDOM.documentElement.source;
  504. // var option = "open=1;save=1;directprint=0;printdialog=1;print=1;zoom=0";
  505. // rptf_exeReportPreview30(["RPRAD01501"],[objParam], option);
  506. // }
  507. }
  508. /****************************************************************************************
  509. * Components : Button
  510. * Description : 지급처 일괄변경
  511. ****************************************************************************************/
  512. function grp_btn_btn_change_onclick(obj:Button, e:ClickEventInfo) {
  513. frmf_modal("SPRAD00200", "SPRAD00200", "", "", "", "", "", "", "", "", "", "", "M"); //미전환
  514. }
  515. /****************************************************************************************
  516. * Components : Button
  517. * Description : 확인건 일괄체크
  518. ****************************************************************************************/
  519. function grp_btn_btn_batch_onclick(obj:Button, e:ClickEventInfo) {
  520. var totamt = 0; //금액총계
  521. for(var i = 0; i < ds_main_grnt_grntlist2.rowcount; i++) {
  522. if( ds_main_grnt_grntlist2.getColumn(i, "elecaprvyn") == "Y" && ds_main_grnt_grntlist2.getColumn(i, "flag") != "Y" ) {
  523. // 그리드의 row중 ymdaction 컬럼이 null 인 것은 기표시 Error가 발생하므로,
  524. // 기표대상으로 선택되지 않도록 처리하고, Message를 발생시켜 정보통신실에서 처리하도록 한다.
  525. if( utlf_isNull(ds_main_grnt_grntlist2.getColumn(i, "ymdaction")) ) {
  526. sysf_messageBox("기표불가한 자료가 포함되어 있어 작업을 중단합니다. 정보통신실로 연락하셔서 조치 후 기표 가능합니다.", "E999", "");
  527. ipt_totamt.value = "";
  528. return;
  529. }
  530. ds_main_grnt_grntlist2.setColumn(i, "flag", "Y");
  531. grdf_setStatus(grd_grntpsn1, "U", [i]);
  532. // Setseq를 call 하기 위해 focus 위치를 옮김
  533. ds_main_grnt_grntlist2.rowposition = i;
  534. // grd_grntpsn1.col = grd_grntpsn1.colRef("flag");
  535. Setseq(); //gipyoseq setting
  536. totamt = parseFloat(totamt) + parseFloat(ds_main_grnt_grntlist2.getColumn(i, "keumak"));
  537. }
  538. }
  539. ipt_totamt.value = totamt;
  540. }
  541. function ds_main_grnt_grntlist2_oncolumnchanged(obj:Dataset, e:DSColChangeEventInfo)
  542. {
  543. if(e.columnid=="flag") {
  544. obj.setColumn(e.row,e.columnid,(e.newvalue=="Y"||e.newvalue==1)?"Y":"N");
  545. //2011.04.29 박준범
  546. // 그리드의 row중 ymdaction 컬럼이 null 인 것은 기표시 Error가 발생하므로,
  547. // 기표대상으로 선택되지 않도록 처리하고, Message를 발생시켜 정보통신실에서 처리하도록 한다.
  548. if( utlf_isNull(obj.getColumn(e.row, "ymdaction")) ) {
  549. obj.setColumn( e.row, "flag", "N");
  550. grdf_setStatus(grd_grntpsn1, "N", [e.row]);
  551. sysf_messageBox("기표불가한 자료입니다. 정보통신실로 연락하셔서 조치 후 기표 가능합니다.", "E999", "");
  552. return;
  553. }
  554. Setseq(); //gipyoseq setting
  555. }
  556. }
  557. function ds_send_paydedu_oncolumnchanged(obj:Dataset, e:DSColChangeEventInfo)
  558. {
  559. if(e.columid=="kyno") {
  560. //2011.06.02 박준범 - 검색어 부분에 값이 있을 경우에는 아래 findrow 작업을 하도록 수정
  561. // 값이 없는 경우, findrow를 실행하면 첫 row를 찾아 check하는 오류 방지
  562. if (utlf_isNull(e.newvalue)) return;
  563. var kyno = e.newvalue;
  564. var irow = ds_main_grnt_grntlist2.findRow("kyno", kyno);
  565. if (irow > -1){
  566. ds_main_grnt_grntlist2.rowposition = irow;
  567. grd_grntpsn1.vscrollbar.pos = idx;
  568. if (ds_main_grnt_grntlist2.getColumn(irow, "flag") == "N"){
  569. //2011.05.04 박준범
  570. // 그리드의 row중 ymdaction 컬럼이 null 인 것은 기표시 Error가 발생하므로,
  571. // 기표대상으로 선택되지 않도록 처리하고, Message를 발생시켜 정보통신실에서 처리하도록 한다.
  572. if( utlf_isNull(ds_main_grnt_grntlist2.getColumn(irow, "ymdaction")) ) {
  573. sysf_messageBox("기표불가한 자료입니다. 정보통신실로 연락하셔서 조치 후 기표 가능합니다.", "E999", "");
  574. return;
  575. }
  576. ds_main_grnt_grntlist2.setColumn( irow , "flag", "Y");
  577. grdf_setStatus(grd_grntpsn1, "U", [irow]);
  578. Setseq();
  579. }
  580. }
  581. }
  582. }
  583. /****************************************************************************************
  584. * Components : Calendar
  585. * Description : 기표일자 변경
  586. ****************************************************************************************/
  587. function ipt_unsldd_onchanged(obj:Calendar, e:ChangeEventInfo)
  588. {
  589. btn_search.click();
  590. }
  591. ]]></Script>
  592. </Form>
  593. </FDL>