|
|
@ -25,13 +25,15 @@ |
|
|
|
<div class="form-group"> |
|
|
|
<label class="col-sm-5 control-label">报价币种:</label> |
|
|
|
<div class="col-sm-7"> |
|
|
|
<div class="radio-box" th:each="dict : ${@dict.getType('sys_common_currency')}"> |
|
|
|
<input type="radio" th:id="${'commonCurrency_' + dict.dictCode}" name="commonCurrency" th:value="${dict.dictValue}" th:field="*{commonCurrency}" readonly> |
|
|
|
<label th:for="${'commonCurrency_' + dict.dictCode}" th:text="${dict.dictLabel}"></label> |
|
|
|
</div> |
|
|
|
<select name="commonCurrency" class="form-control m-b" th:with="type=${@dict.getType('sys_common_currency')}" readonly> |
|
|
|
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{commonCurrency}"></option> |
|
|
|
</select> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<div class="form-group"> |
|
|
|
<label class="col-sm-5 control-label">客户代码/ID:</label> |
|
|
|
<div class="col-sm-7"> |
|
|
@ -174,7 +176,7 @@ |
|
|
|
<div class="form-group"> |
|
|
|
<label class="col-sm-5 control-label">含税总价(RMB):</label> |
|
|
|
<div class="col-sm-7"> |
|
|
|
<input name="rmbTaxSum" th:field="*{rmbTaxSum}" class="form-control" type="text" readonly> |
|
|
|
<input name="rmbTaxSum" th:field="*{rmbTaxSum}" class="form-control" type="text" id="rmbTaxSumInput" readonly> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
|
|
|
@ -194,7 +196,7 @@ |
|
|
|
<label class="col-sm-5 control-label">开票额度比例:</label> |
|
|
|
<div class="col-sm-7"> |
|
|
|
<div class="input-group"> |
|
|
|
<input name="invoiceQuotaRatio" th:field="*{invoiceQuotaRatio}" class="form-control" type="text"> |
|
|
|
<input name="invoiceQuotaRatio" th:field="*{invoiceQuotaRatio}" class="form-control" type="text" id="invoiceQuotaRatioInput"> |
|
|
|
<span class="input-group-addon">%</span> |
|
|
|
</div> |
|
|
|
</div> |
|
|
@ -203,7 +205,7 @@ |
|
|
|
<div class="form-group"> |
|
|
|
<label class="col-sm-5 control-label">开票金额(RMB):</label> |
|
|
|
<div class="col-sm-7"> |
|
|
|
<input name="invoiceAmountUsd" th:field="*{invoiceAmountUsd}" class="form-control" type="text"> |
|
|
|
<input name="invoiceAmountRmb" th:field="*{invoiceAmountRmb}" class="form-control" type="text" id="invoiceAmountRmbInput" readonly> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
<div class="form-group"> |
|
|
@ -213,9 +215,6 @@ |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</form> |
|
|
|
</div> |
|
|
|
<th:block th:include="include :: footer" /> |
|
|
@ -389,24 +388,13 @@ |
|
|
|
field: 'invoiceHistoryId', |
|
|
|
visible: false |
|
|
|
}, |
|
|
|
{ |
|
|
|
title: '国税发票单号', |
|
|
|
field: 'taxInvoiceCode', |
|
|
|
}, |
|
|
|
{ |
|
|
|
title: '发票状态', //(0待审核、1待开具、2已开具、3审核拒绝) |
|
|
|
field: 'taxInvoiceStatus', |
|
|
|
formatter: function(value, row, index) { |
|
|
|
return $.table.selectDictLabel(taxInvoiceStatusDatas, value); |
|
|
|
} |
|
|
|
}, |
|
|
|
{ |
|
|
|
title: '申请时间', |
|
|
|
field: 'applyTime', |
|
|
|
}, |
|
|
|
{ |
|
|
|
title: '财务员', |
|
|
|
field: 'financeMembers', |
|
|
|
title: '国税发票单号', |
|
|
|
field: 'taxInvoiceCode', |
|
|
|
}, |
|
|
|
{ |
|
|
|
title: '开票额度比例', |
|
|
@ -416,16 +404,28 @@ |
|
|
|
title: '开票金额(RMB)', |
|
|
|
field: 'invoiceAmountRmb', |
|
|
|
}, |
|
|
|
|
|
|
|
{ |
|
|
|
title: '开票用途', |
|
|
|
field: 'invoicePurpose', |
|
|
|
}, |
|
|
|
{ |
|
|
|
title: '发票状态', //(0待审核、1待开具、2已开具、3审核拒绝) |
|
|
|
field: 'taxInvoiceStatus', |
|
|
|
formatter: function(value, row, index) { |
|
|
|
return $.table.selectDictLabel(taxInvoiceStatusDatas, value); |
|
|
|
} |
|
|
|
}, |
|
|
|
{ |
|
|
|
title: '财务员', |
|
|
|
field: 'financeMembers', |
|
|
|
}, |
|
|
|
{ |
|
|
|
title: '操作', |
|
|
|
align: 'center', |
|
|
|
formatter: function(value, row, index) { |
|
|
|
var actions = []; |
|
|
|
actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="javascript:void(0)" onclick="$.operate.edit(\'' + row.invoiceHistoryId + '\')"><i class="fa fa-edit"></i>编辑</a> '); |
|
|
|
actions.push('<a class="btn btn-success btn-xs " href="javascript:void(0)" onclick="$.operate.edit(\'' + row.invoiceHistoryId + '\')"><i class="fa fa-edit"></i>详情</a> '); |
|
|
|
return actions.join(''); |
|
|
|
} |
|
|
|
}] |
|
|
@ -528,6 +528,29 @@ |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//通过监听额度比例输入框的值,动态计算开票金额 |
|
|
|
$(document).ready(function() { |
|
|
|
|
|
|
|
var invoiceAmountRmbInput = $('#invoiceAmountRmbInput'); |
|
|
|
var invoiceQuotaRatioInput = $('#invoiceQuotaRatioInput'); |
|
|
|
var rmbTaxSumInput = $('#rmbTaxSumInput'); |
|
|
|
|
|
|
|
//监听开票额度比例输入框的变化 |
|
|
|
invoiceQuotaRatioInput.on('input', function() { |
|
|
|
var rmbTaxSum = parseFloat(rmbTaxSumInput.val()); |
|
|
|
var invoiceQuotaRatio = parseFloat($(this).val()); |
|
|
|
if (!isNaN(rmbTaxSum) && !isNaN(invoiceQuotaRatio)) { |
|
|
|
//计算开票金额 = 税前总额 * 开票比例 |
|
|
|
var invoiceAmountRmb = rmbTaxSum * (invoiceQuotaRatio / 100); |
|
|
|
//更新开票金额输入框 |
|
|
|
invoiceAmountRmbInput.val(invoiceAmountRmb.toFixed(2)); |
|
|
|
} else { |
|
|
|
invoiceAmountRmbInput.val(''); |
|
|
|
} |
|
|
|
}); |
|
|
|
}); |
|
|
|
|
|
|
|
</script> |
|
|
|
</body> |
|
|
|
</html> |