OrdItemPopup.jsp 5.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141
  1. <%--
  2. - FileName : OrdItemPopup.jsp
  3. - Author(s) : mklee
  4. - Date : 2018.10.18
  5. - Description: ITEM 내역
  6. --%>
  7. <%@ page contentType="text/html; charset=utf-8" %>
  8. <%@ page import="kr.co.hsnc.common.sql.RowSet" %>
  9. <%@ page import="kr.co.hsnc.common.util.ValueObject" %>
  10. <%@ page import="com.udapsoft.waf.system.*" %>
  11. <%@ page import="com.udapsoft.waf.common.*" %>
  12. <%@ page import="kr.co.udapsoft.common.*" %>
  13. <%@ page import="com.udapsoft.waf.common.util.*" %>
  14. <%@ page import="kr.co.hsnc.common.util.*"%>
  15. <%@ page import="kr.co.hsnc.common.util.Formatter"%>
  16. <%@ page import="com.udapsoft.waf.common.ui.HTMLMaker" %>
  17. <%@ page import="com.udapsoft.waf.system.HandlerStorage" %>
  18. <%@page import="java.net.URLDecoder"%>
  19. <%@ include file="/jsp/work/taglib.jsp" %>
  20. <jsp:useBean id="ctx" class="com.udapsoft.waf.system.context.SessionContext" scope="session" />
  21. <%
  22. ctx.init(request, response);
  23. HandlerStorage storage = ctx.getHandlerStorage();
  24. ValueObject user = ctx.getUser();
  25. ValueObject params = storage.getParams();
  26. String event = storage.getEvent();
  27. %>
  28. <SCRIPT language="JavaScript">
  29. var sheet1;
  30. var sheet1Row;
  31. var sheet1PageNo = 1;
  32. var pageLastRowIndex = 1;
  33. var validationResult = false;
  34. var filterShow = false;
  35. function _onReady(){
  36. gridInit(sheet1);
  37. //autoResize();
  38. jQuery("#btnSearch").click(function() {
  39. jQuery("#fevent").val("SHEET_ITEM_SELECT");
  40. var url = Modular.model.PageContext.CONTEXT_ROOT + "/bid/outside/OrdItemPopup_sheet.screen";
  41. Modular.view.IBSheet7.doSearch(sheet1, url, jQuery("#form1"), 30, "");
  42. });
  43. jQuery("#btnSearch").click();
  44. }
  45. function gridInit(sheetName){
  46. var init_sheet = {};
  47. init_sheet.Cfg = {SearchMode:2, Page:5000, MergeSheet:msPrevColumnMerge + msHeaderOnly};
  48. init_sheet.Cols = [
  49. {Header:'발주번호', Type:"Text", SaveName:"DEMANDED_ID", Width:100, Align:"Left", Edit:"false", Hidden:"True"},
  50. {Header:'공종코드', Type:"Text", SaveName:"CD_CSTR", Width:40, Align:"Left", Edit:"false"},
  51. {Header:'내역코드', Type:"Text", SaveName:"DL_CSTR", Width:40, Align:"Left", Edit:"false"},
  52. {Header:'예산순번', Type:"Text", SaveName:"SEQ_BUDGET", Width:10, Align:"Left", Edit:"false", Hidden:"True"},
  53. {Header:'예산차수', Type:"Text", SaveName:"SQ_BUDGET", Width:10, Align:"Left", Edit:"false", Hidden:"True"},
  54. {Header:'내역명', Type:"Text", SaveName:"NM_CSTR", Width:200, Align:"Left", Edit:"false"},
  55. {Header:'전체도급', Type:"AutoSum", SaveName:"TOT_CONT_AMT", Width:80, Align:"Right", Edit:"false"},
  56. {Header:'전체실행', Type:"AutoSum", SaveName:"TOT_EXE_AMT", Width:80, Align:"Right", Edit:"false"},
  57. {Header:'도급금액', Type:"AutoSum", SaveName:"CONT_AMT", Width:80, Align:"Right", Edit:"false"},
  58. {Header:'실행금액', Type:"AutoSum", SaveName:"EXE_AMT", Width:80, Align:"Right", Edit:"false"}
  59. ];
  60. init_sheet.HeaderMode = {Sort:1};
  61. IBS_InitSheet(sheetName, init_sheet);
  62. sheetName.SetDataAutoTrim(0);
  63. setGridSize();
  64. }
  65. function setGridSize() {
  66. sheet1.FitColWidth();
  67. }
  68. function sheet1_OnSearchEnd(code, message) {
  69. if(code == 0) {
  70. setGridSize();
  71. } else {
  72. //조회 에러 수행
  73. alert(message);
  74. }
  75. }
  76. function sheet1_OnSmartResize(Width, Height) {
  77. sheet1.FitColWidth();
  78. //autoResize();
  79. }
  80. /**
  81. * enter click 시 자동으로 검색이되도록 조
  82. */
  83. function check_Enter(){
  84. if (event.keyCode==13)
  85. jQuery("#btnSearch").click();
  86. }
  87. function autoResize(){
  88. var t1_height = document.getElementById("search-table").scrollHeight + document.getElementById("title_pop").scrollHeight + 20;
  89. var iframeHeight= document.body.scrollHeight - t1_height;
  90. var iframeWidth= document.body.scrollWidth;
  91. sheet1.SetSheetHeight(iframeHeight);
  92. }
  93. document.onkeydown = closePopupWindow;
  94. //document.body.onresize = addEvent( document.body.onresize, "autoResize()");
  95. </SCRIPT>
  96. <modular:search id="form1">
  97. <modular:key id="fevent" />
  98. </modular:search>
  99. <FORM id="form1" name="form1" method="get" modular:type="search">
  100. <INPUT type="hidden" name="fevent" id="fevent" value="">
  101. <INPUT type="hidden" name="DEMANDED_ID" value="<%=params.get("DEMANDED_ID")%>" />
  102. <INPUT type="hidden" name="pop_win_id" value="<%=params.get("pop_win_id")%>" />
  103. <table id="search-table" class="search-form-table">
  104. <colgroup>
  105. <col width="*" />
  106. </colgroup>
  107. <tr>
  108. <td class="button" style="text-align:right; padding-right:10px;">
  109. <span class="btnSearch center" id="btnSearch" style="display:;"><a href="javascript:void(0);">검색</a></span>
  110. </td>
  111. </tr>
  112. </table>
  113. <!-- 검색조건 종료 -->
  114. <div id="sheet1_div" style="padding-top:5px; height: auto; min-height: 450px; overflow: auto;">
  115. <script>createIBSheet('sheet1','100%', '450px');</script>
  116. </div>
  117. </form>