|
@@ -14,24 +14,24 @@ $(document).ready(function () {
|
|
$('#erro').modal('show');
|
|
$('#erro').modal('show');
|
|
}
|
|
}
|
|
|
|
|
|
- $('#advance_add').click(function() {
|
|
|
|
- postData(`${window.location.pathname}/${type}/create`, {}, res => {
|
|
|
|
- const html = `<tr>
|
|
|
|
- <td><a href="/tender/${res.tid}/advance/${res.id}/detail" data-id="${res.id}">第${res.order}期</a></td>
|
|
|
|
- <td>${res.pay_ratio || 0}%</td>
|
|
|
|
- <td class="text-right">${formatMoney((res.cur_amount || 0), ',', decimal)}</td>
|
|
|
|
- <td class="text-right">${formatMoney((res.prev_amount || 0), ',', decimal)}</td>
|
|
|
|
- <td class="text-right">${formatMoney((res.prev_total_amount || 0),',', decimal)}</td>
|
|
|
|
- <td><a class="btn btn-sm" href="#file" data-toggle="modal" data-target="#file"><i class="fa fa-paperclip "></i> 3</a></td>
|
|
|
|
- <td>${auditConst.statusString[res.status]}</td>
|
|
|
|
- <td><a href="/tender/${res.tid}/advance/${res.id}/detail" class="btn btn-primary btn-sm">编辑</a></td>
|
|
|
|
- </tr>`
|
|
|
|
- $('#advanceList').prepend(html)
|
|
|
|
- $('#advance_add').remove()
|
|
|
|
- window.location.href = `${window.location.pathname}/${res.id}/detail`
|
|
|
|
- })
|
|
|
|
- return false
|
|
|
|
- })
|
|
|
|
|
|
+ // $('#advance_add').click(function() {
|
|
|
|
+ // postData(`${window.location.pathname}/${type}/create`, {}, res => {
|
|
|
|
+ // const html = `<tr>
|
|
|
|
+ // <td><a href="/tender/${res.tid}/advance/${res.id}/detail" data-id="${res.id}">第${res.order}期</a></td>
|
|
|
|
+ // <td>${res.pay_ratio || 0}%</td>
|
|
|
|
+ // <td class="text-right">${formatMoney((res.cur_amount || 0), ',', decimal)}</td>
|
|
|
|
+ // <td class="text-right">${formatMoney((res.prev_amount || 0), ',', decimal)}</td>
|
|
|
|
+ // <td class="text-right">${formatMoney((res.prev_total_amount || 0),',', decimal)}</td>
|
|
|
|
+ // <td><a class="btn btn-sm" href="#file" data-toggle="modal" data-target="#file"><i class="fa fa-paperclip "></i> 3</a></td>
|
|
|
|
+ // <td>${auditConst.statusString[res.status]}</td>
|
|
|
|
+ // <td><a href="/tender/${res.tid}/advance/${res.id}/detail" class="btn btn-primary btn-sm">编辑</a></td>
|
|
|
|
+ // </tr>`
|
|
|
|
+ // $('#advanceList').prepend(html)
|
|
|
|
+ // $('#advance_add').remove()
|
|
|
|
+ // window.location.href = `${window.location.pathname}/${res.id}/detail`
|
|
|
|
+ // })
|
|
|
|
+ // return false
|
|
|
|
+ // })
|
|
|
|
|
|
$('#advanceList').on('click', `a[href="#file"]`, function() {
|
|
$('#advanceList').on('click', `a[href="#file"]`, function() {
|
|
const { fileList = [] } = advanceList.find(item => item.id === parseInt($(this).data('id')))
|
|
const { fileList = [] } = advanceList.find(item => item.id === parseInt($(this).data('id')))
|