OrderReqeustList.jsp 9.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261
  1. <%--
  2. - Author(s) : Hyung min Son
  3. - Date : 2014.06.18
  4. - Description: 발주의뢰 접수 대상건 상세
  5. --%>
  6. <%@ page contentType="text/html; charset=utf-8" %>
  7. <%@ page import="com.udapsoft.waf.system.HandlerStorage" %>
  8. <%@ page import="com.udapsoft.waf.common.ui.*" %>
  9. <%@ page import="kr.co.hsnc.common.util.*"%>
  10. <%@ page import="kr.co.hsnc.common.sql.*" %>
  11. <%@ page import="com.udapsoft.waf.common.ui.InitCombo" %>
  12. <%@ page import="kr.co.udapsoft.common.code.CommCodeManager" %>
  13. <%@ include file="/jsp/work/taglib.jsp" %>
  14. <jsp:useBean id="ctx" class="com.udapsoft.waf.system.context.SessionContext" scope="session" />
  15. <%
  16. ctx.init(request, response);
  17. HandlerStorage storage = ctx.getHandlerStorage();
  18. ValueObject params = storage.getParams();
  19. ValueObject user = storage.getUser();
  20. //공통코드
  21. CommCodeManager commCodeManager = new CommCodeManager();
  22. InitCombo initCombo = new InitCombo();
  23. initCombo.makeComboData(commCodeManager.getCodeRowSet("ONBID"), "NAME", "CODE");
  24. String ONBID_CD = initCombo.getCode();
  25. String ONBID_NM = initCombo.getCodeName();
  26. InitCombo initCombo2 = new InitCombo();
  27. initCombo2.makeComboData(commCodeManager.getCodeRowSet("DEMANDDED_STATUS"), "NAME", "CODE");
  28. String DEMANDDED_STATUS_CD = initCombo2.getCode();
  29. String DEMANDDED_STATUS_NM = initCombo2.getCodeName();
  30. if(params.get("P_DEMANDED_STATUS").isEmpty()){
  31. params.set("P_DEMANDED_STATUS","3");
  32. }
  33. %>
  34. <SCRIPT language="JavaScript">
  35. document.body.onresize = addEvent( document.body.onresize, "autoResize()");
  36. /*예약함수*/
  37. var sheet1 = new ibsheetObject();
  38. var sheet1Row;
  39. var sheet1PageNo = 1;
  40. var pageLastRowIndex = 1;
  41. var validationResult = false;
  42. var filterShow = false;
  43. function _onReady(){
  44. /**
  45. * IBSheet object initialize
  46. */
  47. gridInit(sheet1);
  48. autoResize();
  49. /**
  50. * Application Initialize
  51. */
  52. jQuery("#btnSearch").click(function() {
  53. jQuery("#fevent").val("SHEET_SELECT");
  54. var url = Modular.model.PageContext.CONTEXT_ROOT + "/bid/outside/OrderReqeustList_sheet.screen";
  55. Modular.view.IBSheet7.doSearch(sheet1, url, jQuery("#form1"), 30, "");
  56. });
  57. /* $("#P_DEMANDED_STATUS").change(function(){
  58. $("#btnSearch").click();
  59. }); */
  60. $("#p_dept_nm").keydown(function (event){
  61. var keycode = (event.keyCode ? event.keyCode : event.which);
  62. if(keycode == 8 || keycode == 46){
  63. $("#p_dept_cd").val("");$("#p_dept_nm").val("");
  64. }
  65. });
  66. $("#P_DEMANDED_TITLE").keydown(function (event){
  67. var keycode = (event.keyCode ? event.keyCode : event.which);
  68. if(keycode == 13){
  69. $("#btnSearch").click();
  70. }
  71. });
  72. $("#btnSearch").click();
  73. }
  74. /**
  75. * IBSheet object initialize
  76. */
  77. function gridInit(sheetName){
  78. var init_sheet = {};
  79. init_sheet.Cfg = {SearchMode:2, Page:30};
  80. init_sheet.Cols = [
  81. {Header:'Del', Type:"DelCheck", SaveName:"DEL_CHECK", Width:50, Align:"Center", Hidden:"True"},
  82. {Header:'Status', Type:"Status", SaveName:"STATUS", Width:0, Align:"Center", Hidden:"True"},
  83. {Header:'No.', Type:"Seq", SaveName:"NO", Width:0, Align:"Center", Hidden:"True"},
  84. {Header:'발주의뢰번호', Type:"Text", SaveName:"DEMANDED_NO", Width:150, Align:"Center"},
  85. {Header:'현장', Type:"Text", SaveName:"DEPT_NM", Width:200, Align:"Left"},
  86. {Header:'☞발주의뢰명', Type:"Text", SaveName:"DEMANDED_TITLE", Width:200, Align:"Left", Cursor:"pointer"},
  87. {Header:'입찰방법', Type:"Combo", SaveName:"ONBID_YN", Width:0, Align:"Center", ComboText:"<%=ONBID_NM%>", ComboCode:"<%=ONBID_CD%>"},
  88. {Header:'발주의뢰 부서', Type:"Text", SaveName:"BUSEO_NM", Width:0, Align:"Center"},
  89. {Header:'발주의뢰자', Type:"Text", SaveName:"EMP_NM", Width:0, Align:"Center"},
  90. {Header:'발주의뢰자', Type:"Text", SaveName:"EMP_NO", Width:0, Align:"Center", Hidden:"True"},
  91. {Header:'발주의뢰일', Type:"Text", SaveName:"DEMANDED_DATE", Width:0, Align:"Center"},
  92. {Header:'접수자', Type:"Text", SaveName:"RECEIPT_NM", Width:0, Align:"Center"},
  93. {Header:'접수자', Type:"Text", SaveName:"RECEIPT_NO", Width:0, Align:"Center", Hidden:"True"},
  94. {Header:'상태', Type:"Combo", SaveName:"DEMANDED_STATUS", Width:50, Align:"Center", ComboText:"<%=DEMANDDED_STATUS_NM%>", ComboCode:"<%=DEMANDDED_STATUS_CD%>"},
  95. {Header:'BID_NO', Type:"Text", SaveName:"BID_NO", Width:100, Align:"Center", Hidden:"True"},
  96. {Header:'BID_DEG', Type:"Text", SaveName:"BID_DEG", Width:100, Align:"Center", Hidden:"True"},
  97. {Header:'DEMANDED_ID', Type:"Text", SaveName:"DEMANDED_ID", Width:100, Align:"Center", Hidden:"True"}
  98. ];
  99. init_sheet.HeaderMode = {Sort:1};
  100. IBS_InitSheet(sheetName, init_sheet);
  101. sheetName.SetDataAutoTrim(0);
  102. sheetName.SetEditable(false);
  103. sheetName.SetActionMenu("ExcelDown");
  104. setGridSize();
  105. }
  106. function sheet1_OnSelectMenu(Text, Code) {
  107. // text 또는 code값으로 Action수행
  108. switch(Text) {
  109. case "ExcelDown":
  110. sheetExcelDown(sheet1,$('li').html());
  111. break;
  112. }
  113. }
  114. /**
  115. * IBSheet Event: Search End(IBSheet 데이터 조회 CallBack)
  116. */
  117. function sheet1_OnSearchEnd(code, message) {
  118. if(code == 0) {
  119. setGridSize();
  120. sheet1.SetColFontColor("DEMANDED_TITLE", "#0000ff");
  121. } else {
  122. //조회 에러 수행
  123. alert(message);
  124. }
  125. }
  126. /**
  127. * IBSheet Event: Click
  128. */
  129. function sheet1_OnDblClick(Row, Col, Value, CellX, CellY, CellW, CellH) {
  130. if(Row == 0)return;
  131. if (Col == 5) {
  132. jQuery("#DEMANDED_ID").val(sheet1.GetCellValue(Row, "DEMANDED_ID"));
  133. jQuery("#BID_NO").val(sheet1.GetCellValue(Row, "BID_NO"));
  134. jQuery("#BID_DEG").val(sheet1.GetCellValue(Row, "BID_DEG"));
  135. jQuery("#fevent").val("FORM_SELECT");
  136. jQuery("#form1").attr("action", "/bid/outside/OrderReqeust.screen");
  137. jQuery("#form1").attr("target", "_self");
  138. jQuery("#form1").attr("method", "post");
  139. jQuery("#form1").submit();
  140. }
  141. }
  142. /**
  143. * IBSheet size setting
  144. */
  145. function setGridSize() {
  146. sheet1.FitColWidth();
  147. }
  148. function sheet1_OnSmartResize(Width, Height) {
  149. sheet1.FitColWidth();
  150. autoResize();
  151. }
  152. function autoResize(){
  153. var t1_height = document.getElementById("search-table").scrollHeight + document.getElementById("title").scrollHeight + 24;
  154. var iframeHeight= document.body.scrollHeight - t1_height;
  155. var iframeWidth= document.body.scrollWidth;
  156. sheet1.SetSheetHeight(iframeHeight);
  157. }
  158. function seacrch(){
  159. jQuery("#fevent").val("SHEET_SELECT");
  160. var url = Modular.model.PageContext.CONTEXT_ROOT + "/bid/outside/OrderReqeustList_sheet.screen";
  161. Modular.view.IBSheet7.doSearch(sheet1, url, jQuery("#form1"), 30, "");
  162. }
  163. </SCRIPT>
  164. <modular:search id="form1">
  165. <modular:key id="fevent" />
  166. </modular:search>
  167. <BODY onresize="autoResize()" >
  168. <form id="form1" name="form1" method="post" modular:type="search">
  169. <TABLE id="t1" border="0" cellspacing="0" cellpadding="0" width="100%" height="100%">
  170. <TR><TD height="1">
  171. <INPUT type="hidden" name="p_user_sabun" value="">
  172. <INPUT type="hidden" name="fevent" id="fevent" value="">
  173. <INPUT type="hidden" name="p_user_pw" value="">
  174. <INPUT type="hidden" name="P_DEMANDED_KIND" value="O">
  175. <INPUT type="hidden" name="p_tel_no" value="">
  176. <INPUT type="hidden" name="p_hand_tel_no" value="">
  177. <INPUT type="hidden" name="BID_DEG" value="">
  178. <INPUT type="hidden" name="BID_NO" value="">
  179. <INPUT type="hidden" name="DEMANDED_ID" value="">
  180. <INPUT type="hidden" name="j_usertype" value="head">
  181. <input type='hidden' name='login_id' >
  182. <input type='hidden' name='login_pw' >
  183. <INPUT type="hidden" name="j_admin_login_gb" value="Y">
  184. </TD></TR>
  185. <div align="left" id="title" >
  186. <ul><li>외주_발주의뢰접수</li></ul>
  187. </div>
  188. <!-- 검색조건 영역 : 시작 -->
  189. <TR><TD height="1">
  190. <!-- 검색조건 시작 -->
  191. <table id="search-table" class="search-form-table" >
  192. <colgroup>
  193. <col width="100px" />
  194. <col width="40%"/>
  195. <col width="100px" />
  196. <col/>
  197. <col width="150px" />
  198. </colgroup>
  199. <tr>
  200. <th>현장</th>
  201. <td colspan="3">
  202. <%=InputText.getSiteCodeNew("p_dept_cd", "p_dept_nm", "", user, params.get("p_dept_cd"), params.get("p_dept_nm"))%>
  203. </td>
  204. <td class="button" rowspan="2">
  205. <span class="btnSearch center" id="btnSearch"><a href="javascript:void(0);">검색</a></span>
  206. <span class="btnSearch center" id="btnExcel"><a href="javascript:sheetExcelDown(sheet1,$('li').html());">ExcelDown</a></span>
  207. </td>
  208. </tr>
  209. <tr>
  210. <th>발주의뢰명</th>
  211. <td>
  212. <INPUT type="text" name="P_DEMANDED_TITLE" id="P_DEMANDED_TITLE" class="input" value="<%=params.get("P_DEMANDED_TITLE") %>" style="width:90%">
  213. </td>
  214. <th>상태</th>
  215. <td>
  216. <%=CommCodeManager.getSelectCodeList("DEMANDDED_STATUS","P_DEMANDED_STATUS","height=18;width:80px;","<option value=''>--전체--</option>",params.get("P_DEMANDED_STATUS")) %>
  217. </td>
  218. </tr>
  219. </table>
  220. </TD></TR>
  221. <!-- 검색조건 영역 : 종료 -->
  222. <!-- 검색조건 영역, 테이터 영역 구분 여백 : 종료 -->
  223. </TABLE>
  224. <div id="sheet1_div" style="padding-top:5px; height: auto; min-height: 350px; overflow: auto;">
  225. <script>createIBSheet('sheet1','100%', '350px');</script>
  226. </div>
  227. </FORM>