activitiCostRequestOther-add.jsp 8.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234
  1. <%@ page language="java" import="java.util.*" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
  2. <%@include file="/context/mytags.jsp"%>
  3. <!DOCTYPE html>
  4. <html>
  5. <head>
  6. <title>费用申请签报</title>
  7. <t:base type="jquery,easyui,tools,DatePicker"></t:base>
  8. <script src="webpage/cn/com/lzt/useractiviti/select_user_tools.js"></script>
  9. <script src="webpage/cn/com/lzt/cost/cost_tools.js"></script>
  10. <script type="text/javascript" src="plug-in/tools/money.js"></script>
  11. <script type="text/javascript" src="webpage/cn/com/lzt/budget/data/js/budget_control.js"></script>
  12. <script type="text/javascript">
  13. //编写自定义JS代码
  14. function openDep(){
  15. selectUserDep('项目列表');
  16. }
  17. function openCostType(){
  18. selectCostType();
  19. }
  20. function setChnMoney(money){
  21. var chn = convertCurrency(money);
  22. $('#totalamountCHN').html(chn);
  23. }
  24. $(function(){
  25. $('#expectMoney').bind('input',function(){
  26. var $t = $(this);
  27. var v =$t.val().replace(/^(\-)*(\d+)\.(\d\d).*$/,'$1$2.$3');
  28. $t.val(v);
  29. setChnMoney(v)
  30. var fv = parseFloat(v);
  31. if(!isNaN(fv)){
  32. var leftValue=budgetValue.expectValue-budgetValue.actualValue-fv;
  33. budgetValue.leftValue= leftValue;
  34. if(leftValue<0) leftValue=0;
  35. $('#leftValue').html(leftValue);
  36. }
  37. });
  38. setChnMoney($('#expectMoney').val());
  39. $('#budgetMonth').bind('change',getActualValue);
  40. $('#measureId').bind('change',getActualValue);
  41. getActualValue();
  42. })
  43. function getActualValue() {
  44. var yearMonth = $('#budgetMonth').val();
  45. var measureId = $('#measureId').val();
  46. if(!yearMonth || !measureId){
  47. return;
  48. }
  49. var departId = $('#departId').val();
  50. var busType = 'cost_request_other';
  51. getExpectActualValue(busType,yearMonth,departId,measureId,function(expectValue,actualValue,leftValue){
  52. $('#actualValue').html(actualValue);
  53. $('#leftValue').html(leftValue);
  54. $('#expectMoney').trigger('input');
  55. });
  56. }
  57. </script>
  58. </head>
  59. <body>
  60. <%--处理回调--%>
  61. <c:set var="_callback">
  62. <c:choose>
  63. <c:when test="${in_process}">@Overridecallback</c:when>
  64. <c:otherwise>callback</c:otherwise>
  65. </c:choose>
  66. </c:set>
  67. <t:formvalid formid="formobj" dialog="true" usePlugin="password" layout="table" action="activitiCostRequestOtherController.do?doAdd"
  68. callback="${_callback}" beforeSubmit="checkOverBudget">
  69. <input id="id" name="id" type="hidden" value="${entity.id }"/>
  70. <table style="width: 600px;" cellpadding="0" cellspacing="1" class="formtable">
  71. <c:if test="${in_process}">
  72. <tr>
  73. <td align="right">
  74. <label class="Validform_label">
  75. 申请人:
  76. </label>
  77. </td>
  78. <td class="value">
  79. ${entity.realName}
  80. </td>
  81. </tr>
  82. </c:if>
  83. <tr>
  84. <td align="right">
  85. <label class="Validform_label">
  86. 所属部门:
  87. </label>
  88. </td>
  89. <td class="value">
  90. <input type="hidden" name="departId" id="departId" value="${empty entity.departId?param.departId:entity.departId}"/>
  91. <input type="hidden" name="depName" id="depName" value="${empty entity.depName?param.depName:entity.depName}"/>
  92. ${empty entity.depName?param.depName:entity.depName}
  93. <%--<c:if test="${(empty param.load && !in_process)|| (in_process&& param.flag==1)}">
  94. <a href="javascript:void(0)" class="easyui-linkbutton" plain="true" icon="icon-select" id="dutiesSearch" onclick="openDep()">选择</a>
  95. </c:if>--%>
  96. <span class="Validform_checktip"></span>
  97. <label class="Validform_label" style="display: none;">所属部门</label>
  98. </td>
  99. </tr>
  100. <tr>
  101. <td align="right">
  102. <label class="Validform_label">
  103. <span color="red" class="requiredIcon">*</span>计入预算月份:
  104. </label>
  105. </td>
  106. <td class="value">
  107. <input id="budgetMonth" name="budgetMonth" type="text" class="Wdate" onClick="WdatePicker({dateFmt:'yyyy-MM',onpicked:getActualValue})" value="${entity.budgetMonth}" datatype="*"/>
  108. <span class="Validform_checktip"></span>
  109. <label class="Validform_label" style="display: none;">计入预算月份</label>
  110. </td>
  111. </tr>
  112. <tr>
  113. <td align="right">
  114. <label class="Validform_label">
  115. <span color="red" class="requiredIcon">*</span>预算指标:
  116. </label>
  117. </td>
  118. <td class="value">
  119. <%--
  120. A01A06 公共事业费 A01A16 保险费 A01A17 不可预见费用 A01A18 应急活动费 A01A03差旅费
  121. --%>
  122. <t:dictSelect field="measureId" id="measureId" type="list" dictTable="t_b_budget_measure" dictField="id" dictText="name" defaultVal="${entity.measureId}" datatype="*"
  123. dictCondition=" where code like 'A01A06_%' or code='A01A17' or code like 'A01A18_%' or code='A01A16A01'
  124. or code='A01A16A02' or code='A01A16A03' or code='A01A16A04' or code='A01A16A05' or code='A01A16A06'
  125. or code='A01A16A07' or code='A01A16A08' or code like 'A01A03_%' order by code" />
  126. <span class="Validform_checktip"></span>
  127. <label class="Validform_label" style="display: none;">预算指标</label>
  128. </td>
  129. </tr>
  130. <tr>
  131. <td align="right">
  132. <label class="Validform_label">
  133. 已占用预算额度:
  134. </label>
  135. </td>
  136. <td class="value">
  137. <span id="actualValue"></span>
  138. </td>
  139. </tr>
  140. <tr>
  141. <td align="right">
  142. <label class="Validform_label">
  143. 剩余预算额度:
  144. </label>
  145. </td>
  146. <td class="value">
  147. <span id="leftValue"></span>
  148. </td>
  149. </tr>
  150. <tr>
  151. <td align="right">
  152. <label class="Validform_label">
  153. <span color="red" class="requiredIcon">*</span>预计费用:
  154. </label>
  155. </td>
  156. <td class="value">
  157. <input id="expectMoney" name="expectMoney" type="text" style="width: 150px" class="inputxt"
  158. datatype="d,fix2" value="${entity.expectMoney}"/>
  159. <label id="totalamountCHN" style="font-size: 18px"></label>
  160. <span class="Validform_checktip"></span>
  161. <label class="Validform_label" style="display: none;">预计费用</label>
  162. </td>
  163. </tr>
  164. <tr>
  165. <td align="right">
  166. <label class="Validform_label">
  167. <span color="red" class="requiredIcon">*</span>用途摘要:
  168. </label>
  169. </td>
  170. <td class="value">
  171. <input id="summary" name="summary" type="text" style="width: 250px" class="inputxt" datatype="s1-20" value="${entity.summary}"/>
  172. <span class="Validform_checktip"></span>
  173. <label class="Validform_label" style="display: none;">用途摘要</label>
  174. </td>
  175. </tr>
  176. <tr>
  177. <td align="right">
  178. <label class="Validform_label">
  179. 备注:
  180. </label>
  181. </td>
  182. <td class="value" >
  183. <textarea style="width:400px;height: 150px" class="inputxt" rows="6" id="remark" name="remark" >${entity.remark}</textarea>
  184. <span class="Validform_checktip"></span>
  185. <label class="Validform_label" style="display: none;">备注</label>
  186. </td>
  187. </tr>
  188. <c:if test="${entity.bpmStatus!='3'}"> <%--审批通过后不可见--%>
  189. <tr>
  190. <td align="right">
  191. <label class="Validform_label">
  192. 特殊说明:
  193. </label>
  194. </td>
  195. <td class="value" >
  196. <input id="special" name="special" type="text" style="width: 250px" class="inputxt" value="${entity.special}"/>
  197. <span class="Validform_checktip"></span>
  198. <label class="Validform_label" style="display: none;">备注</label>
  199. </td>
  200. </tr>
  201. </c:if>
  202. <tr>
  203. <td align="right">
  204. <label class="Validform_label">
  205. 附件:
  206. </label>
  207. </td>
  208. <td class="value">
  209. <t:webUploader auto="true" busiId="${entity.id}" readOnly="${param.load=='detail' || in_process}"
  210. busiTable="t_b_activiti_cost_request_other"
  211. bizType="attachment"
  212. extensions="png,jpg,jpeg,bmp"
  213. name="attachment" duplicate="true"
  214. nullMsg="附件不可为空"></t:webUploader>
  215. <span class="Validform_checktip Validform_right" style="display: none;">文件已上传</span>
  216. </td>
  217. </tr>
  218. </table>
  219. <table style="width: 100%">
  220. <tr>
  221. <td style="text-align:center;">
  222. <%@include file="/webpage/cn/com/lzt/useractiviti/view_submit_buttons.jsp"%>
  223. </td>
  224. </tr>
  225. </table>
  226. </t:formvalid>
  227. </body>