chgItemList.jsp 5.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394
  1. <%
  2. if((params.get("TEMPLATE_CD").equals("6"))){
  3. if(chgItemList.size()>0){
  4. %>
  5. <textarea id="chgItemList" style="display:none;">
  6. <table width="100%" border="0" cellpadding="0" cellspacing="0" style="border-top:2px solid black; padding:5px 0px 5px 0px">
  7. <colgroup>
  8. <col width="50">
  9. <col width="50">
  10. <col width="50">
  11. <col width="50">
  12. <col width="100">
  13. <col width="100">
  14. <col width="50">
  15. <col width="100">
  16. <col width="100">
  17. <col width="50">
  18. <col width="100">
  19. </colgroup>
  20. <tr>
  21. <td rowspan="2" align="center" style="border-bottom:1px solid black; padding:2px 0px 5px 0px">품명</td>
  22. <td rowspan="2" align="center" style="border-bottom:1px solid black; padding:2px 0px 5px 0px">규격</td>
  23. <td rowspan="2" align="center" style="border-bottom:1px solid black; padding:2px 0px 5px 0px">단위</td>
  24. <td colspan="3" align="center" style="border-bottom:1px solid black; padding:2px 0px 5px 0px">변경전</td>
  25. <td colspan="3" align="center" style="border-bottom:1px solid black; padding:2px 0px 5px 0px">변경후</td>
  26. <td colspan="2" align="center" style="border-bottom:1px solid black; padding:2px 0px 5px 0px">증감금액</td>
  27. </tr>
  28. <tr>
  29. <td align="center" style="border-bottom:1px solid black; padding:2px 0px 5px 0px">수량</td>
  30. <td align="center" style="border-bottom:1px solid black; padding:2px 0px 5px 0px">단가(<%=ContInfo.get("CURR_STD_NM")%>)</td>
  31. <td align="center" style="border-bottom:1px solid black; padding:2px 0px 5px 0px">금액(<%=ContInfo.get("CURR_STD_NM")%>)</td>
  32. <td align="center" style="border-bottom:1px solid black; padding:2px 0px 5px 0px">수량</td>
  33. <td align="center" style="border-bottom:1px solid black; padding:2px 0px 5px 0px">단가(<%=ContInfo.get("CURR_STD_NM")%>)</td>
  34. <td align="center" style="border-bottom:1px solid black; padding:2px 0px 5px 0px">금액(<%=ContInfo.get("CURR_STD_NM")%>)</td>
  35. <td align="center" style="border-bottom:1px solid black; padding:2px 0px 5px 0px">수량</td>
  36. <td align="center" style="border-bottom:1px solid black; padding:2px 0px 5px 0px">금액(<%=ContInfo.get("CURR_STD_NM")%>)</td>
  37. </tr>
  38. <%
  39. double sum_qty=0;
  40. double sum_amt=0;
  41. double sum_con_qty=0;
  42. double sum_con_amt=0;
  43. for(int i=0;i<chgItemList.size();i++){
  44. sum_qty = sum_qty + chgItemList.getRow(i).getDouble("ITEM_QTY");
  45. sum_amt = sum_amt + chgItemList.getRow(i).getDouble("ITEM_AMT");
  46. sum_con_qty = sum_con_qty + chgItemList.getRow(i).getDouble("CONT_QTY");
  47. sum_con_amt = sum_con_amt + chgItemList.getRow(i).getDouble("CONT_AMT");
  48. %>
  49. <tr>
  50. <td style="padding:2px 0px 2px 0px">&nbsp;<%=chgItemList.getRow(i).get("ITEM_NAME")%></td>
  51. <td align="center" style="padding:2px 0px 2px 0px">&nbsp;<%=chgItemList.getRow(i).get("ITEM_SPEC")%></td>
  52. <td align="center" style="padding:2px 0px 2px 0px">&nbsp;<%=chgItemList.getRow(i).get("ITEM_UNIT_NM")%></td>
  53. <td align="right" style="padding:2px 0px 2px 0px"><%=Formatter2.currency(chgItemList.getRow(i).getDouble("ITEM_QTY"),2)%>&nbsp;</td>
  54. <td align="right" style="padding:2px 0px 2px 0px"><%=Formatter2.currency(chgItemList.getRow(i).getDouble("ITEM_PRICE"), ContInfo.getInt("SOSUNUM"))%>&nbsp;</td>
  55. <td align="right" style="padding:2px 0px 2px 0px"><%=Formatter2.currency(chgItemList.getRow(i).getDouble("ITEM_AMT"), ContInfo.getInt("SOSUNUM"))%>&nbsp;</td>
  56. <td align="right" style="padding:2px 0px 2px 0px"><%=Formatter2.currency(chgItemList.getRow(i).getDouble("CONT_QTY"),2)%>&nbsp;</td>
  57. <td align="right" style="padding:2px 0px 2px 0px"><%=Formatter2.currency(chgItemList.getRow(i).getDouble("CONT_PRICE"), ContInfo.getInt("SOSUNUM"))%>&nbsp;</td>
  58. <td align="right" style="padding:2px 0px 2px 0px"><%=Formatter2.currency(chgItemList.getRow(i).getDouble("CONT_AMT"), ContInfo.getInt("SOSUNUM"))%>&nbsp;</td>
  59. <td align="right" style="padding:2px 0px 2px 0px"><%=Formatter2.currency((chgItemList.getRow(i).getDouble("CONT_QTY") - chgItemList.getRow(i).getDouble("ITEM_QTY")),2)%>&nbsp;</td>
  60. <td align="right" style="padding:2px 0px 2px 0px"><%=Formatter2.currency((chgItemList.getRow(i).getDouble("CONT_AMT") - chgItemList.getRow(i).getDouble("ITEM_AMT")), ContInfo.getInt("SOSUNUM"))%>&nbsp;</td>
  61. </tr>
  62. <%
  63. }
  64. %>
  65. <tr>
  66. <td colspan="3" align="center" style="border-top:1px solid black;border-bottom:1px solid black; padding:2px 0px 2px 0px"><b>합계</b></td>
  67. <td align="right" style="border-top:1px solid black;border-bottom:1px solid black; padding:2px 0px 2px 0px"><%=Formatter2.currency(sum_qty, 2)%>&nbsp;</td>
  68. <td colspan="2" align="right" style="border-top:1px solid black;border-bottom:1px solid black; padding:2px 0px 2px 0px"><%=Formatter2.currency(sum_amt, ContInfo.getInt("SOSUNUM"))%>&nbsp;</td>
  69. <td align="right" style="border-top:1px solid black;border-bottom:1px solid black; padding:2px 0px 2px 0px"><%=Formatter2.currency(sum_qty, 2)%>&nbsp;</td>
  70. <td colspan="2" align="right" style="border-top:1px solid black;border-bottom:1px solid black; padding:2px 0px 2px 0px"><%=Formatter2.currency(sum_con_amt, ContInfo.getInt("SOSUNUM"))%>&nbsp;</td>
  71. <td colspan="2" align="right" style="border-top:1px solid black;border-bottom:1px solid black; padding:2px 0px 2px 0px"><%=Formatter2.currency((sum_con_amt - sum_amt), ContInfo.getInt("SOSUNUM"))%>&nbsp;</td>
  72. </tr>
  73. </table>
  74. </textarea>
  75. <script>
  76. if ( document.getElementById("div_chg_con_item") != null ) {
  77. <%
  78. //아이템 팝업 창에서 할때는 오프너로 연다.
  79. if(params.get("pop_win_id").equals("ItemPop")){
  80. %>
  81. parent.document.getElementById("div_chg_con_item").innerHTML=document.getElementById("chgItemList").value;
  82. <%
  83. }else{
  84. %>
  85. document.getElementById("div_chg_con_item").innerHTML=document.getElementById("chgItemList").value;
  86. <%
  87. }
  88. %>
  89. }
  90. </script>
  91. <%
  92. }
  93. }
  94. %>