SPZSN00601_직원공유팝업.xfdl 35 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <FDL version="1.5">
  3. <TypeDefinition url="..\..\..\default_typedef.xml"/>
  4. <Form id="SPZSN00601" classname="SPZSN00501_직원공유팝업" inheritanceid="" position="absolute 0 0 900 900" titletext="직원공유" oninit="SPZSN00601_oninit" onload="SPZSN00601_onload" onbeforeclose="SPZSN00601_onbeforeclose">
  5. <Layouts>
  6. <Layout>
  7. <ActiveX id="atx_HwpCtrl" position="absolute 0 105 900 819" progid="{bd9c32de-3155-4691-8972-097d53b10052}" taborder="0"/>
  8. <Div id="div_noticeinfo" taborder="1" position="absolute 0 26 900 104">
  9. <Layouts>
  10. <Layout>
  11. <Edit id="edt_title" taborder="1" position="absolute 74 1 899 21" anchor="default" autoselect="true" imemode="hangul" style="font:Dotum,9,bold;"/>
  12. <Shape id="line7" class="line_2" position="absolute 1 20 899 26" anchor="default"/>
  13. <Static id="Static00" text="제목" class="cell_1" position="absolute 1 1 69 23" anchor="default"/>
  14. <Shape id="line00" class="line_2" position="absolute 1 43 899 49" anchor="default"/>
  15. <Static id="Static01" text="게시자" class="cell_1" position="absolute 1 24 69 46" anchor="default"/>
  16. <Shape id="line01" class="line_2" position="absolute 1 66 899 72" anchor="default"/>
  17. <Static id="Static02" text="게시판" class="cell_1" position="absolute 1 47 69 69" anchor="default"/>
  18. <Static id="Static03" text="게시일" class="cell_1" position="absolute 265 24 333 46" anchor="default"/>
  19. <Static id="stt_usernm" position="absolute 79 25 263 45" anchor="default" style="color:#0058c5ff;"/>
  20. <Calendar id="cal_fromdd" taborder="2" position="absolute 338 24 485 44" anchor="default" autoselect="true" dateformat="yyyy년 MM월 dd일 (ddd)" value="null" editformat="yyyy년 MM월 dd일"/>
  21. <Calendar id="cal_todd" taborder="5" position="absolute 338 47 485 67" anchor="default" autoselect="true" dateformat="yyyy년 MM월 dd일 (ddd)" value="null" editformat="yyyy년 MM월 dd일"/>
  22. <Static id="Static04" text="종료일" class="cell_1" position="absolute 265 47 333 69" anchor="default"/>
  23. <Shape id="line02" class="line_10" position="absolute 0 72 900 78" anchor="default"/>
  24. <Static id="stt_boardnm" position="absolute 79 48 263 68" anchor="default" style="font:Dotum,9,bold;"/>
  25. <Static id="stt_tempsave" text="임시저장중" position="absolute 496 25 596 45" style="color:red;font:Dotum,9,bold;" visible="false" anchor="default"/>
  26. </Layout>
  27. </Layouts>
  28. </Div>
  29. <Div id="div_noticereadinfo" taborder="5" text="Div00" position="absolute 0 0 900 29">
  30. <Layouts>
  31. <Layout>
  32. <Static id="stt_seqno" position="absolute 79 4 143 24" anchor="default"/>
  33. <Static id="stt_readcnt" position="absolute 231 4 295 24" anchor="default"/>
  34. <Shape id="line7" class="line_2" position="absolute 1 23 900 29" anchor="default"/>
  35. <Static id="Static00" text="번호" class="cell_1" position="absolute 1 4 69 26" anchor="default"/>
  36. <Static id="Static01" text="조회" class="cell_1" position="absolute 153 4 221 26" anchor="default"/>
  37. <Shape id="line02" class="line_10" position="absolute 0 0 900 5" anchor="default"/>
  38. </Layout>
  39. </Layouts>
  40. </Div>
  41. <Button id="btn_tempsave" taborder="6" text="임시저장" onclick="btn_tempsave_onclick" class="btn2" position="absolute 662 4 738 24" visible="false"/>
  42. <Button id="btn_edit" taborder="7" text="수정" onclick="btn_edit_onclick" class="btn5" position="absolute 796 4 846 24" visible="false"/>
  43. <Button id="btn_close" taborder="8" text="닫기" onclick="btn_close_onclick" class="btn3" position="absolute 850 4 900 24"/>
  44. <Button id="btn_del" taborder="9" text="삭제" position="absolute 743 4 793 24" class="btn5" visible="false" onclick="btn_del_onclick"/>
  45. <Button id="btn_save" taborder="13" text="게시" onclick="btn_save_onclick" class="btn5" position="absolute 741 4 793 24" visible="false"/>
  46. <Static id="Static05" text="첨부파일" class="cell_1" position="absolute 0 825 68 900" style="padding:5 0 0 8;align:left top;"/>
  47. <Grid id="grd_files" taborder="14" binddataset="ds_file" scrollpixel="all" useinputpanel="false" selecttype="multirow" oncellclick="grd_files_oncellclick" position="absolute 72 826 900 900" onmousewheel="grd_files_onmousewheel" autofittype="col">
  48. <Formats>
  49. <Format id="default">
  50. <Columns>
  51. <Column size="30"/>
  52. <Column size="531"/>
  53. <Column size="100"/>
  54. <Column size="30"/>
  55. <Column size="60"/>
  56. <Column size="60"/>
  57. </Columns>
  58. <Rows>
  59. <Row size="24"/>
  60. </Rows>
  61. <Band id="body">
  62. <Cell celltype="head" text="expr:currow + 1"/>
  63. <Cell col="1" displaytype="text" style="padding:0 8 0 8;" text="bind:filename"/>
  64. <Cell col="2" colspan="2" taborder="undefined">
  65. <Cell displaytype="number" style="align:right middle;padding:0 0 0 0;" text="bind:filesize" expr="expr:Math.ceil(filesize / 1024)"/>
  66. <Cell col="1" displaytype="text" style="align:left middle;padding:0 0 0 0;" text="KB"/>
  67. </Cell>
  68. <Cell col="4" displaytype="expr:utlf_isNull(filekey) ? &quot;normal&quot; : &quot;button&quot;" edittype="expr:utlf_isNull(filekey) ? &quot;none&quot; : &quot;button&quot;" text="expr:utlf_isNull(filekey) ? &quot;&quot; : &quot;미리보기&quot;"/>
  69. <Cell col="5" displaytype="expr:utlf_isNull(filekey) ? &quot;normal&quot; : &quot;button&quot;" edittype="expr:utlf_isNull(filekey) ? &quot;none&quot; : &quot;button&quot;" text="expr:utlf_isNull(filekey) ? &quot;&quot; : &quot;파일받기&quot;"/>
  70. </Band>
  71. </Format>
  72. </Formats>
  73. </Grid>
  74. <Button id="btn_file_add" taborder="15" text="추가" position="absolute 5 850 64 870" class="btn5" onclick="btn_file_add_onclick" visible="false"/>
  75. <Button id="btn_file_del" taborder="16" text="삭제" class="btn5" position="absolute 5 874 64 894" onclick="btn_file_del_onclick" visible="false"/>
  76. <Shape id="line02" class="line_10" position="absolute 0 820 900 826"/>
  77. </Layout>
  78. </Layouts>
  79. <Objects>
  80. <Dataset id="ds_send" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  81. <ColumnInfo>
  82. <Column id="genrno" type="STRING" size="256"/>
  83. </ColumnInfo>
  84. <Rows>
  85. <Row/>
  86. </Rows>
  87. </Dataset>
  88. <Dataset id="ds_boardtype" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  89. <ColumnInfo>
  90. <Column id="label" type="STRING" size="256"/>
  91. <Column id="value" type="STRING" size="256"/>
  92. <Column id="titleYn" type="STRING" size="256"/>
  93. <Column id="title" type="STRING" size="256"/>
  94. <Column id="popuptitle" type="STRING" size="256"/>
  95. <Column id="instcd" type="STRING" size="256"/>
  96. </ColumnInfo>
  97. <Rows>
  98. <Row>
  99. <Col id="label">공지사항</Col>
  100. <Col id="value">C1</Col>
  101. <Col id="titleYn">N</Col>
  102. <Col id="instcd"/>
  103. <Col id="popuptitle">직원공유</Col>
  104. <Col id="title">직원공유게시판</Col>
  105. </Row>
  106. <Row>
  107. <Col id="value">C2</Col>
  108. <Col id="label">지침게시물</Col>
  109. <Col id="titleYn">N</Col>
  110. <Col id="popuptitle">직원공유</Col>
  111. <Col id="title">직원공유게시판</Col>
  112. </Row>
  113. <Row>
  114. <Col id="value">Q1</Col>
  115. <Col id="label">질향상활동</Col>
  116. <Col id="titleYn">N</Col>
  117. <Col id="popuptitle">직원공유</Col>
  118. <Col id="title">직원공유게시판</Col>
  119. </Row>
  120. <Row>
  121. <Col id="value">Q2</Col>
  122. <Col id="label">지표관리활동</Col>
  123. <Col id="titleYn">N</Col>
  124. <Col id="popuptitle">직원공유</Col>
  125. <Col id="title">직원공유게시판</Col>
  126. </Row>
  127. <Row>
  128. <Col id="value">Q3</Col>
  129. <Col id="label">표준진료지침활동</Col>
  130. <Col id="titleYn">N</Col>
  131. <Col id="popuptitle">직원공유</Col>
  132. <Col id="title">직원공유게시판</Col>
  133. </Row>
  134. <Row>
  135. <Col id="label">교육자료</Col>
  136. <Col id="value">Q4</Col>
  137. <Col id="titleYn">N</Col>
  138. <Col id="popuptitle">직원공유</Col>
  139. <Col id="title">직원공유게시판</Col>
  140. </Row>
  141. <Row>
  142. <Col id="label">주의경보및정보제공</Col>
  143. <Col id="value">P1</Col>
  144. <Col id="titleYn">N</Col>
  145. <Col id="popuptitle">직원공유</Col>
  146. <Col id="title">직원공유게시판</Col>
  147. </Row>
  148. <Row>
  149. <Col id="value">P2</Col>
  150. <Col id="label">환자안전관리활동(KNUH)</Col>
  151. <Col id="titleYn">N</Col>
  152. <Col id="instcd">031</Col>
  153. <Col id="popuptitle">직원공유</Col>
  154. <Col id="title">직원공유게시판</Col>
  155. </Row>
  156. <Row>
  157. <Col id="label">환자안전관리활동(KNUCH)</Col>
  158. <Col id="value">P2</Col>
  159. <Col id="titleYn">N</Col>
  160. <Col id="instcd">032</Col>
  161. <Col id="popuptitle">직원공유</Col>
  162. <Col id="title">직원공유게시판</Col>
  163. </Row>
  164. <Row>
  165. <Col id="value">P3</Col>
  166. <Col id="label">환자안전교육</Col>
  167. <Col id="titleYn">N</Col>
  168. <Col id="popuptitle">직원공유</Col>
  169. <Col id="title">직원공유게시판</Col>
  170. </Row>
  171. <Row>
  172. <Col id="value">I1</Col>
  173. <Col id="label">감염관리활동</Col>
  174. <Col id="titleYn">N</Col>
  175. <Col id="popuptitle">직원공유</Col>
  176. <Col id="title">직원공유게시판</Col>
  177. </Row>
  178. <Row>
  179. <Col id="label">감염관리매뉴얼</Col>
  180. <Col id="value">I2</Col>
  181. <Col id="titleYn">N</Col>
  182. <Col id="popuptitle">직원공유</Col>
  183. <Col id="title">직원공유게시판</Col>
  184. <Col id="instcd">031</Col>
  185. </Row>
  186. <Row>
  187. <Col id="label">감염관리지침</Col>
  188. <Col id="value">I2</Col>
  189. <Col id="titleYn">N</Col>
  190. <Col id="title">직원공유게시판</Col>
  191. <Col id="popuptitle">직원공유</Col>
  192. <Col id="instcd">032</Col>
  193. </Row>
  194. <Row>
  195. <Col id="value">I3</Col>
  196. <Col id="label">교육자료</Col>
  197. <Col id="titleYn">N</Col>
  198. <Col id="popuptitle">직원공유</Col>
  199. <Col id="title">직원공유게시판</Col>
  200. </Row>
  201. <Row>
  202. <Col id="value">I4</Col>
  203. <Col id="label">지침게시물</Col>
  204. <Col id="titleYn">N</Col>
  205. <Col id="popuptitle">직원공유</Col>
  206. <Col id="title">직원공유게시판</Col>
  207. </Row>
  208. <Row>
  209. <Col id="value">I5</Col>
  210. <Col id="label">국내외감염병동향</Col>
  211. <Col id="titleYn">N</Col>
  212. <Col id="popuptitle">직원공유</Col>
  213. <Col id="title">직원공유게시판</Col>
  214. </Row>
  215. <Row>
  216. <Col id="label">환자∙보호자 교육자료</Col>
  217. <Col id="value">I6</Col>
  218. <Col id="titleYn">N</Col>
  219. <Col id="title">직원공유게시판</Col>
  220. <Col id="popuptitle">직원공유</Col>
  221. <Col id="instcd">032</Col>
  222. </Row>
  223. <Row>
  224. <Col id="value">S1</Col>
  225. <Col id="label">직원안전활동</Col>
  226. <Col id="titleYn">N</Col>
  227. <Col id="popuptitle">직원공유</Col>
  228. <Col id="title">직원공유게시판</Col>
  229. </Row>
  230. <Row>
  231. <Col id="value">M1</Col>
  232. <Col id="label">공지사항</Col>
  233. <Col id="titleYn">Y</Col>
  234. <Col id="popuptitle">만족도조사</Col>
  235. <Col id="title">공지사항</Col>
  236. </Row>
  237. <Row>
  238. <Col id="value">M2</Col>
  239. <Col id="label">만족도조사 보고서</Col>
  240. <Col id="titleYn">Y</Col>
  241. <Col id="popuptitle">만족도조사</Col>
  242. <Col id="title">만족도조사 보고서</Col>
  243. </Row>
  244. </Rows>
  245. </Dataset>
  246. <Dataset id="ds_notice" firefirstcount="0" firenextcount="0" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  247. <ColumnInfo>
  248. <Column id="status" type="STRING" size="255"/>
  249. <Column id="genrdd" type="STRING" size="255"/>
  250. <Column id="genrno" type="BIGDECIMAL" size="255"/>
  251. <Column id="seqno" type="BIGDECIMAL" size="255"/>
  252. <Column id="boardtype" type="STRING" size="255"/>
  253. <Column id="userid" type="STRING" size="255"/>
  254. <Column id="usernm" type="STRING" size="255"/>
  255. <Column id="deptcd" type="STRING" size="255"/>
  256. <Column id="deptnm" type="STRING" size="255"/>
  257. <Column id="fromdd" type="STRING" size="255"/>
  258. <Column id="todd" type="STRING" size="255"/>
  259. <Column id="histstat" type="STRING" size="255"/>
  260. <Column id="title" type="STRING" size="255"/>
  261. <Column id="conts" type="STRING" size="255"/>
  262. <Column id="contstxt" type="STRING" size="255"/>
  263. <Column id="filekey" type="STRING" size="255"/>
  264. <Column id="hitcount" type="BIGDECIMAL" size="255"/>
  265. <Column id="edityn" type="STRING" size="256"/>
  266. </ColumnInfo>
  267. <Rows>
  268. <Row/>
  269. </Rows>
  270. </Dataset>
  271. <Dataset id="ds_temp_file" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  272. <ColumnInfo>
  273. <Column id="filekey" type="STRING" size="256"/>
  274. <Column id="fileseq" type="STRING" size="256"/>
  275. <Column id="filename" type="STRING" size="256" sumtext="파일명"/>
  276. <Column id="filepath" type="STRING" size="256" sumtext="파일서버경로"/>
  277. <Column id="filesize" type="STRING" size="256" sumtext="파일크기"/>
  278. <Column id="filetype" type="STRING" size="256" sumtext="파일종류"/>
  279. <Column id="filedata" type="BLOB" size="256" sumtext="파일데이터"/>
  280. </ColumnInfo>
  281. <Rows>
  282. <Row/>
  283. </Rows>
  284. </Dataset>
  285. <Dataset id="ds_file" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  286. <ColumnInfo>
  287. <Column id="filekey" type="STRING" size="256"/>
  288. <Column id="fileseq" type="STRING" size="256"/>
  289. <Column id="filename" type="STRING" size="256" sumtext="파일명"/>
  290. <Column id="filepath" type="STRING" size="256" sumtext="파일서버경로"/>
  291. <Column id="filesize" type="STRING" size="256" sumtext="파일크기"/>
  292. <Column id="filetype" type="STRING" size="256" sumtext="파일종류"/>
  293. <Column id="filedata" type="BLOB" size="256" sumtext="파일데이터"/>
  294. </ColumnInfo>
  295. </Dataset>
  296. <Dataset id="ds_attfile" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  297. <ColumnInfo>
  298. <Column id="filepath" type="STRING" size="256"/>
  299. <Column id="fullpath" type="STRING" size="256"/>
  300. </ColumnInfo>
  301. <Rows>
  302. <Row/>
  303. </Rows>
  304. </Dataset>
  305. <Dataset id="ds_result" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  306. <ColumnInfo>
  307. <Column id="count" type="STRING" size="256"/>
  308. </ColumnInfo>
  309. </Dataset>
  310. <Dataset id="ds_filelist" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  311. <ColumnInfo>
  312. <Column id="attfilecnts" type="STRING" size="256" sumtext="첨부파일내용"/>
  313. <Column id="fullpath" type="STRING" size="256"/>
  314. </ColumnInfo>
  315. </Dataset>
  316. <Dataset id="ds_save_file" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  317. <ColumnInfo>
  318. <Column id="filekey" type="STRING" size="256"/>
  319. <Column id="fileseq" type="STRING" size="256"/>
  320. <Column id="filename" type="STRING" size="256" sumtext="파일명"/>
  321. <Column id="filepath" type="STRING" size="256" sumtext="파일서버경로"/>
  322. <Column id="filesize" type="STRING" size="256" sumtext="파일크기"/>
  323. <Column id="filetype" type="STRING" size="256" sumtext="파일종류"/>
  324. <Column id="filedata" type="BLOB" size="256" sumtext="파일데이터"/>
  325. </ColumnInfo>
  326. </Dataset>
  327. <Dataset id="ds_delete_file" firefirstcount="0" firenextcount="0" useclientlayout="false" updatecontrol="true" enableevent="true" loadkeymode="keep" loadfiltermode="keep" reversesubsum="false">
  328. <ColumnInfo>
  329. <Column id="filekey" type="STRING" size="256"/>
  330. <Column id="fileseq" type="STRING" size="256"/>
  331. <Column id="filename" type="STRING" size="256" sumtext="파일명"/>
  332. <Column id="filepath" type="STRING" size="256" sumtext="파일서버경로"/>
  333. <Column id="filesize" type="STRING" size="256" sumtext="파일크기"/>
  334. <Column id="filetype" type="STRING" size="256" sumtext="파일종류"/>
  335. <Column id="filedata" type="BLOB" size="256" sumtext="파일데이터"/>
  336. </ColumnInfo>
  337. </Dataset>
  338. </Objects>
  339. <Bind>
  340. <BindItem id="item0" compid="div_noticeinfo.edt_title" propid="value" datasetid="ds_notice" columnid="title"/>
  341. <BindItem id="item1" compid="div_noticeinfo.cal_fromdd" propid="value" datasetid="ds_notice" columnid="fromdd"/>
  342. <BindItem id="item2" compid="div_noticeinfo.cal_todd" propid="value" datasetid="ds_notice" columnid="todd"/>
  343. <BindItem id="item3" compid="div_noticereadinfo.stt_seqno" propid="text" datasetid="ds_notice" columnid="seqno"/>
  344. <BindItem id="item4" compid="div_noticereadinfo.stt_readcnt" propid="text" datasetid="ds_notice" columnid="hitcount"/>
  345. </Bind>
  346. <Script type="xscript4.0"><![CDATA[include "com_commonxp::comm_main.xjs";
  347. var gMaxSize = 10485760;
  348. var gIsRefresh = false;
  349. function SPZSN00601_oninit(obj:Form, e:InitEventInfo)
  350. {
  351. frmf_initForm(obj);
  352. }
  353. function SPZSN00601_onload(obj:Form, e:LoadEventInfo)
  354. {
  355. var boardtype = "Q1";
  356. var genrno = "-1";
  357. try {
  358. genrno = plgv_genrno;
  359. boardtype = plgv_boardtype;
  360. } catch(e) {}
  361. //글자 서식, 테이블, 이미지 툴만 show
  362. atx_HwpCtrl.SetToolBar(-1, "TOOLBAR_FORMAT");
  363. atx_HwpCtrl.SetToolBar(-1, "TOOLBAR_TABLE");
  364. atx_HwpCtrl.SetToolBar(-1, "TOOLBAR_IMAGE");
  365. fInit(boardtype, genrno);
  366. }
  367. function fInit(sBoardtype, sGenrno) {
  368. if(fIsEditing()) { // 내용 작성한 것이 있을 때는 한번 물어본다
  369. if(sysf_messageBox("작성 중인 내용이 있습니다. 저장하지 않고 새로 여시겠습니까?", "Q") != 6) {
  370. return;
  371. }
  372. }
  373. if(sGenrno == -1) { // 새글
  374. gIsRefresh = true; // 창 닫을 때 메인 게시판 재조회
  375. div_noticeinfo.stt_usernm.text = sysf_getUserInfo("usernm") + " (" + sysf_getUserInfo("dutplcenm") + ")";
  376. fSetTitle(sBoardtype);
  377. ds_notice.clearData();
  378. ds_notice.addRow();
  379. ds_notice.setColumn(0, "status", "i");
  380. ds_notice.setColumn(0, "fromdd", utlf_getCurrentDate());
  381. ds_notice.setColumn(0, "todd", "99991231");
  382. ds_notice.setColumn(0, "boardtype", sBoardtype);
  383. fSetEditMode(true);
  384. atx_HwpCtrl.Clear(1);
  385. fInitHWP(true);
  386. } else {
  387. fInitHWP(false);
  388. ds_send.setColumn(0, "genrno", sGenrno);
  389. var oParam = {};
  390. oParam.id = "SPZSN00601";
  391. oParam.service = "noticeinfoapp.noticeinfo";
  392. oParam.method = "reqGetStaffShareNoticeDetail";
  393. oParam.inds = "req=ds_send";
  394. oParam.outds = "ds_notice=notice ds_file=files";
  395. oParam.async = true;
  396. oParam.callback = "cf_SPZSN00601";
  397. tranf_submit(oParam);
  398. }
  399. }
  400. function fSetTitle(sBoardtype) {
  401. var instcd = sysf_getUserInfo("dutplceinstcd");
  402. ds_boardtype.filter("(utlf_isNull(instcd) || instcd == " + instcd + ") && value == '" + sBoardtype + "'");
  403. var titleYn = ds_boardtype.getColumn(0, "titleYn");
  404. var title = ds_boardtype.getColumn(0, "popuptitle");
  405. var boardnm = ds_boardtype.getColumn(0, "label");
  406. if(titleYn == "Y") frmf_initTitle(this, title);
  407. div_noticeinfo.stt_boardnm.text = boardnm;
  408. this.titletext = this.titletext + " - " + boardnm;
  409. }
  410. function cf_SPZSN00601(sSvcId, nErrorCode, sErrorMsg)
  411. {
  412. if(nErrorCode < 0) return;
  413. div_noticeinfo.stt_usernm.text = ds_notice.getColumn(0, "usernm") + " (" + ds_notice.getColumn(0, "deptnm") + ")";
  414. fSetTitle(ds_notice.getColumn(0, "boardtype"));
  415. ds_file.addColumn("filedata", "BLOB");
  416. ds_file.rowposition = -1;
  417. var conts = ds_notice.getColumn(0, "conts");
  418. if(utlf_isNull(conts)) {
  419. sysf_messageBox("내용 조회에 실패하였습니다", "E");
  420. } else {
  421. atx_HwpCtrl.SetTextFile(conts, "HWPML2X", "");
  422. atx_HwpCtrl.MovePos(2, null, 1); // 커서를 제일 앞으로 이동
  423. }
  424. fSetEditMode(false);
  425. }
  426. function fIsEditing() { // 현재 내용에 텍스트가 입력되어 있을 때
  427. return (fIsEditMode() && !utlf_isNull(atx_HwpCtrl.GetTextFile("TEXT", "")));
  428. }
  429. function fIsEditMode() { // 현재 EditMode 중일 때
  430. return (atx_HwpCtrl.EditMode == 0) ? false : true;
  431. }
  432. function fSetEditMode(enable) {
  433. atx_HwpCtrl.ShowToolBar(enable);
  434. if(enable) {
  435. atx_HwpCtrl.EditMode = 1;
  436. btn_edit.text = "취소";
  437. if(ds_notice.getColumn(0, "status") == "i") // 새 글 일때는 취소 버튼 안보이도록 함
  438. btn_edit.visible = false;
  439. else
  440. btn_edit.visible = true;
  441. btn_tempsave.visible = true;
  442. btn_del.visible = false;
  443. btn_save.visible = true;
  444. btn_file_add.visible = true;
  445. btn_file_del.visible = true;
  446. // 임시저장중일 때는 따로 표시
  447. if(ds_notice.getColumn(0, "histstat") == "N")
  448. div_noticeinfo.stt_tempsave.visible = true;
  449. else
  450. div_noticeinfo.stt_tempsave.visible = false;
  451. div_noticereadinfo.visible = false;
  452. div_noticeinfo.cal_fromdd.class = "";
  453. div_noticeinfo.cal_fromdd.readonly = false;
  454. div_noticeinfo.cal_todd.class = "";
  455. div_noticeinfo.cal_todd.readonly = false;
  456. div_noticeinfo.edt_title.class = "";
  457. div_noticeinfo.edt_title.readonly = false;
  458. div_noticeinfo.edt_title.setFocus();
  459. } else {
  460. // 내용도 원복
  461. ds_notice.reset();
  462. ds_file.reset();
  463. var conts = ds_notice.getColumn(0, "conts");
  464. atx_HwpCtrl.SetTextFile(conts, "HWPML2X", "");
  465. atx_HwpCtrl.EditMode = 0;
  466. btn_edit.text = "수정";
  467. // 자신이 올린 것은 수정 가능
  468. if(ds_notice.getColumn(0, "edityn") == "Y") {
  469. btn_edit.visible = true;
  470. btn_del.visible = true;
  471. if(ds_notice.getColumn(0, "histstat") == "N")
  472. div_noticeinfo.stt_tempsave.visible = true;
  473. else
  474. div_noticeinfo.stt_tempsave.visible = false;
  475. } else {
  476. btn_edit.visible = false;
  477. btn_del.visible = false;
  478. div_noticeinfo.stt_tempsave.visible = false;
  479. }
  480. btn_tempsave.visible = false;
  481. btn_save.visible = false;
  482. btn_file_add.visible = false;
  483. btn_file_del.visible = false;
  484. div_noticereadinfo.visible = true;
  485. div_noticeinfo.cal_fromdd.class = "cal_transbg";
  486. div_noticeinfo.cal_fromdd.readonly = true;
  487. div_noticeinfo.cal_todd.class = "cal_transbg";
  488. div_noticeinfo.cal_todd.readonly = true;
  489. div_noticeinfo.edt_title.class = "edt_transbg";
  490. div_noticeinfo.edt_title.readonly = true;
  491. }
  492. }
  493. function fInitHWP() {
  494. // atx_HwpCtrl.ShowToolBar(true);
  495. // //atx_HwpCtrl.ShowStatusBar(1);
  496. //
  497. // //글자 서식, 테이블, 이미지 툴만 show
  498. // //atx_HwpCtrl.SetToolBar(-1, "TOOLBAR_MENU");
  499. // //atx_HwpCtrl.SetToolBar(-1, "TOOLBAR_STANDARD");
  500. // atx_HwpCtrl.SetToolBar(-1, "TOOLBAR_FORMAT");
  501. // //atx_HwpCtrl.SetToolBar(-1, "TOOLBAR_DRAW");
  502. // atx_HwpCtrl.SetToolBar(-1, "TOOLBAR_TABLE");
  503. // atx_HwpCtrl.SetToolBar(-1, "TOOLBAR_IMAGE");
  504. // //atx_HwpCtrl.SetToolBar(-1, "TOOLBAR_NUMBERBULLET");
  505. // //atx_HwpCtrl.SetToolBar(-1, "TOOLBAR_HEADER_FOOTER");
  506. // //atx_HwpCtrl.SetToolBar(-1, "TOOLBAR_MASTERPAGE");
  507. // //atx_HwpCtrl.SetToolBar(-1, "TOOLBAR_NOTE");
  508. // //atx_HwpCtrl.SetToolBar(-1, "TOOLBAR_COMMENT");
  509. // 기본 글자체를 굴림으로
  510. var act = atx_HwpCtrl.CreateAction("CharShape");
  511. var set = act.CreateSet();
  512. act.GetDefault(set);
  513. set.SetItem("FaceNameHangul", "돋움");
  514. set.SetItem("FaceNameLatin", "돋움");
  515. set.SetItem("FaceNameHanja", "돋움");
  516. set.SetItem("FaceNameJapanese", "돋움");
  517. set.SetItem("FaceNameOther", "돋움");
  518. set.SetItem("FaceNameSymbol", "돋움");
  519. set.SetItem("FaceNameUser", "돋움");
  520. act.Execute(set); // 액션 실행
  521. // 페이지 여백 설정
  522. var act = atx_HwpCtrl.CreateAction("PageSetup");// 액션 생성
  523. var set = act.CreateSet();// parameter set 생성
  524. act.GetDefault(set);// parameter set 초기화
  525. set.setItem("ApplyTo", 3);
  526. var pset = set.CreateItemSet("PageDef","PageDef");
  527. var MARGIN = 1000;
  528. pset.SetItem("PaperWidth", 70000);
  529. pset.SetItem("PaperHeight", 70000);
  530. pset.SetItem("TopMargin", MARGIN);
  531. pset.SetItem("BottomMargin", MARGIN);
  532. pset.SetItem("LeftMargin", MARGIN);
  533. pset.SetItem("RightMargin", MARGIN);
  534. pset.SetItem("HeaderLen", 0);
  535. pset.SetItem("FooterLen", 0);
  536. pset.SetItem("GutterLen", 0);
  537. act.Execute(set);// 액션 실행
  538. }
  539. function btn_close_onclick(obj:Button, e:ClickEventInfo)
  540. {
  541. if(fIsEditing()) { // 내용 작성한 것이 있을 때는 한번 물어본다
  542. if(sysf_messageBox("작성 중인 내용이 있습니다. 저장하지 않고 창을 닫으시겠습니까?", "Q") == 6) {
  543. this.close();
  544. }
  545. } else {
  546. this.close();
  547. }
  548. }
  549. function btn_edit_onclick(obj:Button, e:ClickEventInfo)
  550. {
  551. if(fIsEditMode()) {
  552. fSetEditMode(false);
  553. } else {
  554. fSetEditMode(true);
  555. }
  556. }
  557. function btn_tempsave_onclick(obj:Button, e:ClickEventInfo)
  558. {
  559. fSaveHWP("N");
  560. }
  561. function btn_save_onclick(obj:Button, e:ClickEventInfo)
  562. {
  563. fSaveHWP("Y");
  564. }
  565. function fSaveHWP(sHiststat) {
  566. // 입력값 체크
  567. if(utlf_isNull(ds_notice.getColumn(0, "title"))) {
  568. sysf_messageBox("제목을 입력하여 주십시오", "E");
  569. div_noticeinfo.edt_title.setFocus();
  570. return;
  571. }
  572. if(utlf_isNull(ds_notice.getColumn(0, "fromdd"))) {
  573. sysf_messageBox("게시일을 입력하여 주십시오", "E");
  574. div_noticeinfo.cal_fromdd.setFocus();
  575. return;
  576. }
  577. if(utlf_isNull(ds_notice.getColumn(0, "todd"))) {
  578. sysf_messageBox("종료일을 입력하여 주십시오", "E");
  579. div_noticeinfo.cal_todd.setFocus();
  580. return;
  581. }
  582. ds_notice.setColumn(0, "histstat", sHiststat);
  583. ds_notice.setColumn(0, "conts", atx_HwpCtrl.GetTextFile("HWPML2X", ""));
  584. ds_notice.setColumn(0, "contstxt", atx_HwpCtrl.GetTextFile("TEXT", ""));
  585. ds_save_file.clearData();
  586. if(ds_file.rowcount <= 0) {
  587. ds_notice.setColumn(0, "filekey", "");
  588. } else {
  589. ds_file.filter("utlf_isNull(filekey) == true");
  590. ds_save_file.copyData(ds_file, true);
  591. ds_file.filter("");
  592. }
  593. var oParam = {};
  594. oParam.id = "SPZSN00601";
  595. oParam.service = "noticeinfoapp.noticeinfo";
  596. oParam.method = "reqSetStaffShareNotice";
  597. oParam.inds = "req=ds_notice savefiles=ds_save_file deletefiles=ds_delete_file";
  598. oParam.outds = "ds_result=result ds_notice=notice ds_file=files";
  599. oParam.async = false;
  600. tranf_submit(oParam);
  601. if(ds_result.getColumn(0, "count") == -1) {
  602. sysf_messageBox("저장에 실패하였습니다", "E");
  603. return;
  604. }
  605. ds_file.addColumn("filedata", "BLOB");
  606. ds_delete_file.clearData();
  607. ds_file.rowposition = -1;
  608. // 임시저장중일 때는 따로 표시
  609. if(ds_notice.getColumn(0, "histstat") == "N")
  610. div_noticeinfo.stt_tempsave.visible = true;
  611. else
  612. div_noticeinfo.stt_tempsave.visible = false;
  613. fSetEditMode(false);
  614. }
  615. function btn_del_onclick(obj:Button, e:ClickEventInfo)
  616. {
  617. if(sysf_messageBox("삭제 하시겠습니까? (첨부파일까지 함께 삭제됩니다)", "Q") != 6)
  618. return;
  619. ds_notice.setColumn(0, "status", "d");
  620. if(ds_file.rowcount <= 0) {
  621. ds_notice.setColumn(0, "filekey", "");
  622. } else {
  623. ds_file.filter("utlf_isNull(filekey) == false");
  624. ds_delete_file.appendData(ds_file);
  625. ds_file.filter("");
  626. }
  627. var oParam = {};
  628. oParam.id = "SPZSN00601";
  629. oParam.service = "noticeinfoapp.noticeinfo";
  630. oParam.method = "reqSetStaffShareNotice";
  631. oParam.inds = "req=ds_notice deletefiles=ds_delete_file";
  632. oParam.outds = "ds_result=result";
  633. oParam.async = false;
  634. tranf_submit(oParam);
  635. if(ds_result.getColumn(0, "count") == -1) {
  636. sysf_messageBox("삭제 실패 하였습니다", "E");
  637. } else {
  638. sysf_messageBox("삭제 하였습니다", "I");
  639. gIsRefresh = true; // 창 닫을 때 메인 게시판 재조회
  640. this.close();
  641. }
  642. }
  643. function btn_file_add_onclick(obj:Button, e:ClickEventInfo)
  644. {
  645. fFileAdd();
  646. }
  647. function fFileAdd(colName) {
  648. //******파일을 첨부하기 위해 파일열기가 open 되게 한다.
  649. var oDsSaveFile = ds_file;
  650. //파일을 받아오기 위해 파일열기 팝업창을 띄운다.
  651. var fd = new FileDialog;
  652. var objVFileList = fd.open("첨부 할 파일을 선택하여 주십시오.", FileDialog.MULTILOAD);
  653. if(utlf_isNull(objVFileList)) return;
  654. ds_temp_file.clearData();
  655. for(var i = 0; i < objVFileList.length; i++) {
  656. var nRow = ds_temp_file.addRow();
  657. var objFileinfo = dsf_writeFileToDs(objVFileList[i], ds_temp_file, nRow, "filedata");
  658. if (!checkFileSize(objFileinfo.filesize)){
  659. sysf_messageBox(objFileinfo.filename + " 파일의 크기가 최대치(" + gMaxSize + "Byte)를 초과하여 첨부할 수 없습니다", "E");
  660. ds_temp_file.deleteRow(nRow);
  661. } else {
  662. ds_temp_file.setColumn(nRow, "filename", objFileinfo.filename);
  663. ds_temp_file.setColumn(nRow, "filesize", objFileinfo.filesize);
  664. ds_temp_file.setColumn(nRow, "filetype", objFileinfo.filetype);
  665. }
  666. }
  667. oDsSaveFile.appendData(ds_temp_file);
  668. grd_files.vscrollbar.pos = grd_files.vscrollbar.max;
  669. oDsSaveFile.rowposition = oDsSaveFile.rowcount - 1;
  670. }
  671. function checkFileSize(fileSize)
  672. {
  673. if (fileSize <= gMaxSize)
  674. return true;
  675. else
  676. return false;
  677. }
  678. function grd_files_onmousewheel(obj:Grid, e:MouseWheelEventInfo)
  679. {
  680. obj.vscrollbar.pos += ((e.amount < 0) ? 6 : -6);
  681. //obj.vscrollbar.pos = obj.vscrollbar.pos - e.amount;
  682. return true;
  683. }
  684. function btn_file_del_onclick(obj:Button, e:ClickEventInfo)
  685. {
  686. // 서버에 저장 되어 있는 것들을 지우기 위해 담아둠
  687. var selectedRows = grdf_getSelectedRows(grd_files);
  688. for(var i = selectedRows.length - 1; i >= 0; i--) {
  689. var currow = selectedRows[i];
  690. if(!utlf_isNull(ds_file.getColumn(currow, "filekey"))) {
  691. var nRow = ds_delete_file.addRow();
  692. ds_delete_file.copyRow(nRow, ds_file, currow);
  693. }
  694. ds_file.deleteRow(currow);
  695. }
  696. }
  697. function grd_files_oncellclick(obj:Grid, e:GridClickEventInfo)
  698. {
  699. if(e.col == 4) {
  700. fPreview(ds_file.getColumn(e.row, "filename"), ds_file.getColumn(e.row, "filepath"));
  701. } else if(e.col == 5) {
  702. fFileDown(ds_file.getColumn(e.row, "filename"), ds_file.getColumn(e.row, "filepath"));
  703. }
  704. }
  705. function fPreview(filenm, filepath) {
  706. if(utlf_isNull(filepath)) return;
  707. var temp_path = "C:\\temp2";
  708. var objActiveX = new ActiveX();
  709. var FSO = objActiveX.createObject("Scripting.FileSystemObject");
  710. objActiveX.destroy();
  711. objActiveX = null;
  712. // 객체 생성 실패하면 리턴
  713. if (FSO == null) return;
  714. // 시스템 드라이브가 없다면..
  715. if (FSO.DriveExists("C") == false) return;
  716. // 임시디렉토리가 없으면 생성
  717. if (FSO.FolderExists(temp_path) == false)
  718. folder = FSO.CreateFolder(temp_path);
  719. ds_attfile.setColumn(0, "filepath", filepath);
  720. ds_attfile.setColumn(0, "fullpath", temp_path + "\\" + filenm);
  721. //키값을 가지고 DB에 저장된 데이타를 조회하러 간다
  722. var oParam = {};
  723. oParam.id = "SPZSN00603";
  724. oParam.service = "noticeinfoapp.noticeinfo";
  725. oParam.method = "reqGetAttachFile";
  726. oParam.inds = "req=ds_attfile";
  727. oParam.outds = "ds_filelist=file";
  728. oParam.async = true;
  729. oParam.callback = "cf_SPZSN00603";
  730. tranf_submit(oParam);
  731. }
  732. function cf_SPZSN00603(sSvcId, nErrorCode, sErrorMsg)
  733. {
  734. if(nErrorCode < 0) return;
  735. if(ds_filelist.rowcount > 0) {
  736. var fullpath = ds_filelist.getColumn(0, "fullpath");
  737. dsf_readFileFromDs(fullpath, ds_filelist, 0, "filecnts"); // 파일저장
  738. system.execShell("\"" + fullpath + "\"");
  739. }
  740. }
  741. function fFileDown(filenm, filepath) {
  742. if(utlf_isNull(filepath)) return;
  743. //파일을 다운로드 하기 위해 저장할 창을 띄움
  744. var fd = new FileDialog;
  745. var objVFileList = fd.open("다운 받을 위치를 선택하여 주십시오.", FileDialog.SAVE, "", filenm);
  746. if (objVFileList != null) {
  747. ds_attfile.setColumn(0, "filepath", filepath);
  748. ds_attfile.setColumn(0, "fullpath", objVFileList.fullpath);
  749. //키값을 가지고 DB에 저장된 데이타를 조회하러 간다
  750. var oParam = {};
  751. oParam.id = "SPZSN00602";
  752. oParam.service = "noticeinfoapp.noticeinfo";
  753. oParam.method = "reqGetAttachFile";
  754. oParam.inds = "req=ds_attfile";
  755. oParam.outds = "ds_filelist=file";
  756. oParam.async = true;
  757. oParam.callback = "cf_SPZSN00602";
  758. tranf_submit(oParam);
  759. }
  760. }
  761. function cf_SPZSN00602(sSvcId, nErrorCode, sErrorMsg)
  762. {
  763. if(nErrorCode < 0) return;
  764. if(ds_filelist.rowcount > 0) {
  765. var fullpath = ds_filelist.getColumn(0, "fullpath");
  766. dsf_readFileFromDs(fullpath, ds_filelist, 0, "filecnts"); // 파일저장
  767. if(sysf_messageBox("파일을", "Q004") == "6")
  768. system.execShell("\"" + fullpath + "\"");
  769. }
  770. }
  771. function SPZSN00601_onbeforeclose(obj:Form, e:CloseEventInfo)
  772. {
  773. var mainObj = frmf_getMainViewer();
  774. if(!utlf_isNull(mainObj) && mainObj.frmf_getScreenID() == "SPZSN00600" && gIsRefresh) {
  775. mainObj.fRefresh();
  776. }
  777. }
  778. ]]></Script>
  779. </Form>
  780. </FDL>