|
@@ -17,84 +17,103 @@
|
|
|
<div class="c-body">
|
|
|
<form method="post" action="/compilation/save-lib" enctype="application/x-www-form-urlencoded21">
|
|
|
<div class="row">
|
|
|
- <div class="col-md-4">
|
|
|
- <div class="form-group">
|
|
|
- <label>标准清单</label>
|
|
|
- <div class="bill-list">
|
|
|
- <% if (Object.keys(libData).length > 0 && libData.bill_lib.length > 0) { %>
|
|
|
- <% libData.bill_lib.forEach(function (bill, index){ %>
|
|
|
- <p class="form-control-static">
|
|
|
- <a class="pull-right text-danger remove-lib" data-model="bill" title="移除">
|
|
|
- <span class="glyphicon glyphicon-remove"></span>
|
|
|
- </a>
|
|
|
- <input type="hidden" name="bill_lib" data-id="<%= bill.id %>" value="<%= JSON.stringify({id: bill.id, name: bill.name}) %>">
|
|
|
- <% if (index === 0) {%><i class="glyphicon glyphicon-flag"></i> <% } %><%= bill.name %>
|
|
|
- </p>
|
|
|
- <% }) %>
|
|
|
- <% } %>
|
|
|
+ <div class="col-md-12">
|
|
|
+ <div class="row">
|
|
|
+ <div class="form-group col-md-4">
|
|
|
+ <label>标准清单</label>
|
|
|
+ <div class="bill-list">
|
|
|
+ <% if (Object.keys(libData).length > 0 && libData.bill_lib.length > 0) { %>
|
|
|
+ <% libData.bill_lib.forEach(function (bill, index){ %>
|
|
|
+ <p class="form-control-static">
|
|
|
+ <a class="pull-right text-danger remove-lib" data-model="bill" title="移除">
|
|
|
+ <span class="glyphicon glyphicon-remove"></span>
|
|
|
+ </a>
|
|
|
+ <input type="hidden" name="bill_lib" data-id="<%= bill.id %>" value="<%= JSON.stringify({id: bill.id, name: bill.name}) %>">
|
|
|
+ <% if (index === 0) {%><i class="glyphicon glyphicon-flag"></i> <% } %><%= bill.name %>
|
|
|
+ </p>
|
|
|
+ <% }) %>
|
|
|
+ <% } %>
|
|
|
+ </div>
|
|
|
+ <a class="btn btn-link btn-sm add-compilation" href="javascript:void(0)" data-model="bill">添加</a>
|
|
|
</div>
|
|
|
- <a class="btn btn-link btn-sm add-compilation" href="javascript:void(0)" data-model="bill">添加</a>
|
|
|
- </div>
|
|
|
- <div class="form-group">
|
|
|
- <label>定额库</label>
|
|
|
- <div class="ration-list">
|
|
|
- <% if (Object.keys(libData).length > 0 && libData.ration_lib.length > 0) { %>
|
|
|
- <% libData.ration_lib.forEach(function (ration, index){ %>
|
|
|
- <p class="form-control-static">
|
|
|
- <a class="pull-right text-danger remove-lib" data-model="ration" title="移除" data-id="<%= ration.id %>">
|
|
|
- <span class="glyphicon glyphicon-remove"></span>
|
|
|
- </a>
|
|
|
- <input type="hidden" name="ration_lib" data-id="<%= ration.id %>" value="<%= JSON.stringify({id: ration.id, name: ration.name}) %>">
|
|
|
- <% if (index === 0) {%><i class="glyphicon glyphicon-flag"></i> <% } %><%= ration.name %>
|
|
|
- </p>
|
|
|
- <% }) %>
|
|
|
- <% } %>
|
|
|
+ <div class="form-group col-md-4">
|
|
|
+ <label>定额库</label>
|
|
|
+ <div class="ration-list">
|
|
|
+ <% if (Object.keys(libData).length > 0 && libData.ration_lib.length > 0) { %>
|
|
|
+ <% libData.ration_lib.forEach(function (ration, index){ %>
|
|
|
+ <p class="form-control-static">
|
|
|
+ <a class="pull-right text-danger remove-lib" data-model="ration" title="移除" data-id="<%= ration.id %>">
|
|
|
+ <span class="glyphicon glyphicon-remove"></span>
|
|
|
+ </a>
|
|
|
+ <input type="hidden" name="ration_lib" data-id="<%= ration.id %>" value="<%= JSON.stringify({id: ration.id, name: ration.name}) %>">
|
|
|
+ <% if (index === 0) {%><i class="glyphicon glyphicon-flag"></i> <% } %><%= ration.name %>
|
|
|
+ </p>
|
|
|
+ <% }) %>
|
|
|
+ <% } %>
|
|
|
+ </div>
|
|
|
+ <a href="#" class="btn btn-link btn-sm add-compilation" data-model="ration">添加</a>
|
|
|
</div>
|
|
|
- <a href="#" class="btn btn-link btn-sm add-compilation" data-model="ration">添加</a>
|
|
|
- </div>
|
|
|
- <div class="form-group">
|
|
|
- <label>工料机库</label>
|
|
|
- <div class="glj-list">
|
|
|
- <% if (Object.keys(libData).length > 0 && libData.glj_lib.length > 0) { %>
|
|
|
- <% libData.glj_lib.forEach(function (glj, index){ %>
|
|
|
- <p class="form-control-static">
|
|
|
- <a class="pull-right text-danger remove-lib" data-model="glj" title="移除" data-id="<%= glj.id %>">
|
|
|
- <span class="glyphicon glyphicon-remove"></span>
|
|
|
- </a>
|
|
|
- <input type="hidden" name="glj_lib" data-id="<%= glj.id %>" value="<%= JSON.stringify({id: glj.id, name: glj.name}) %>">
|
|
|
- <% if (index === 0) {%><i class="glyphicon glyphicon-flag"></i> <% } %><%= glj.name %>
|
|
|
- </p>
|
|
|
- <% }) %>
|
|
|
- <% } %>
|
|
|
+ <div class="form-group col-md-4">
|
|
|
+ <label>工料机库</label>
|
|
|
+ <div class="glj-list">
|
|
|
+ <% if (Object.keys(libData).length > 0 && libData.glj_lib.length > 0) { %>
|
|
|
+ <% libData.glj_lib.forEach(function (glj, index){ %>
|
|
|
+ <p class="form-control-static">
|
|
|
+ <a class="pull-right text-danger remove-lib" data-model="glj" title="移除" data-id="<%= glj.id %>">
|
|
|
+ <span class="glyphicon glyphicon-remove"></span>
|
|
|
+ </a>
|
|
|
+ <input type="hidden" name="glj_lib" data-id="<%= glj.id %>" value="<%= JSON.stringify({id: glj.id, name: glj.name}) %>">
|
|
|
+ <% if (index === 0) {%><i class="glyphicon glyphicon-flag"></i> <% } %><%= glj.name %>
|
|
|
+ </p>
|
|
|
+ <% }) %>
|
|
|
+ <% } %>
|
|
|
+ </div>
|
|
|
+ <a href="#" class="btn btn-link btn-sm add-compilation" data-model="glj">添加</a>
|
|
|
</div>
|
|
|
- <a href="#" class="btn btn-link btn-sm add-compilation" data-model="glj">添加</a>
|
|
|
- </div>
|
|
|
- <div class="form-group">
|
|
|
- <label>费率标准</label>
|
|
|
- <div class="fee-list">
|
|
|
- <% if (Object.keys(libData).length > 0 && libData.fee_lib.length > 0) { %>
|
|
|
- <% libData.fee_lib.forEach(function (fee, index){ %>
|
|
|
- <p class="form-control-static">
|
|
|
- <a class="pull-right text-danger remove-lib" data-model="fee" title="移除" data-id="<%= fee.id %>">
|
|
|
- <span class="glyphicon glyphicon-remove"></span>
|
|
|
- </a>
|
|
|
- <input type="hidden" name="fee_lib" data-id="<%= fee.id %>" value="<%= JSON.stringify({id: fee.id, name: fee.name}) %>">
|
|
|
- <% if (index === 0) {%><i class="glyphicon glyphicon-flag"></i> <% } %><%= fee.name %>
|
|
|
- </p>
|
|
|
- <% }) %>
|
|
|
- <% } %>
|
|
|
+ <div class="form-group col-md-4">
|
|
|
+ <label>费率标准</label>
|
|
|
+ <div class="fee-list">
|
|
|
+ <% if (Object.keys(libData).length > 0 && libData.fee_lib.length > 0) { %>
|
|
|
+ <% libData.fee_lib.forEach(function (fee, index){ %>
|
|
|
+ <p class="form-control-static">
|
|
|
+ <a class="pull-right text-danger remove-lib" data-model="fee" title="移除" data-id="<%= fee.id %>">
|
|
|
+ <span class="glyphicon glyphicon-remove"></span>
|
|
|
+ </a>
|
|
|
+ <input type="hidden" name="fee_lib" data-id="<%= fee.id %>" value="<%= JSON.stringify({id: fee.id, name: fee.name}) %>">
|
|
|
+ <% if (index === 0) {%><i class="glyphicon glyphicon-flag"></i> <% } %><%= fee.name %>
|
|
|
+ </p>
|
|
|
+ <% }) %>
|
|
|
+ <% } %>
|
|
|
+ <a href="#" class="btn btn-link btn-sm add-compilation" data-model="fee">添加</a>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <div class="form-group col-md-4">
|
|
|
+ <label>人工系数</label>
|
|
|
+ <div class="artificial-list">
|
|
|
+ <% if (Object.keys(libData).length > 0 && libData.artificial_lib.length > 0) { %>
|
|
|
+ <% libData.artificial_lib.forEach(function (artificial, index){ %>
|
|
|
+ <p class="form-control-static">
|
|
|
+ <a class="pull-right text-danger remove-lib" data-model="artificial" title="移除" data-id="<%= artificial.id %>">
|
|
|
+ <span class="glyphicon glyphicon-remove"></span>
|
|
|
+ </a>
|
|
|
+ <input type="hidden" name="artificial_lib" data-id="<%= artificial.id %>" value="<%= JSON.stringify({id: artificial.id, name: artificial.name}) %>">
|
|
|
+ <% if (index === 0) {%><i class="glyphicon glyphicon-flag"></i> <% } %><%= artificial.name %>
|
|
|
+ </p>
|
|
|
+ <% }) %>
|
|
|
+ <% } %>
|
|
|
+ <a href="#" class="btn btn-link btn-sm add-compilation" data-model="artificial">添加</a>
|
|
|
+ </div>
|
|
|
</div>
|
|
|
- <a href="#" class="btn btn-link btn-sm add-compilation" data-model="fee">添加</a>
|
|
|
</div>
|
|
|
</div>
|
|
|
- <div class="col-md-8">
|
|
|
- <legend>
|
|
|
- 清单模板 / 造价书列
|
|
|
- <a href="javascript:void(0)" data-toggle="modal" data-target="#set-column" class="btn btn-primary btn-sm pull-right">设置</a>
|
|
|
- <a href="/compilation/template/<%= section %>/<%= valuationId %>/<%= engineeringInfo.id%>" data-toggle="modal" data-target="" class="btn btn-primary btn-sm pull-right" style="margin-right:5px">模板设置</a>
|
|
|
- <input type="hidden" name="main_tree_col" value="<%= mainTreeCol %>">
|
|
|
- <div id="main-tree-col">
|
|
|
- </div>
|
|
|
+ <div class="col-md-12">
|
|
|
+ <legend>清单模板 / 造价书列
|
|
|
+ <a href="javascript:void(0)" data-toggle="modal" data-target="#set-column" class="btn btn-primary btn-sm pull-right">设置</a>
|
|
|
+ <a href="/compilation/template/<%= section %>/<%= valuationId %>/<%= engineeringInfo.id%>"
|
|
|
+ data-toggle="modal" data-target="" class="btn btn-primary btn-sm pull-right"
|
|
|
+ style="margin-right:5px">模板设置</a>
|
|
|
+ <input type="hidden" name="main_tree_col" value="<%= mainTreeCol %>">
|
|
|
+ <div id="main-tree-col"></div>
|
|
|
</div>
|
|
|
</div>
|
|
|
<input type="hidden" name="engineering" value="<%= engineeringInfo.id %>" id="engineering">
|
|
@@ -109,6 +128,7 @@
|
|
|
let rationList = '<%- rationList %>';
|
|
|
let gljList = '<%- gljList %>';
|
|
|
let feeRateList = '<%- feeRateList %>';
|
|
|
+ let artificialCoefficientList = '<%- artificialCoefficientList %>';
|
|
|
let mainTreeCol = '<%- mainTreeCol %>';
|
|
|
let billsTemplateData = '<%- billsTemplateData %>';
|
|
|
let colSpread = null;
|