优化代码

This commit is contained in:
wuxw 2024-09-03 17:59:09 +08:00
parent 5df430e3be
commit 336561f8bb
12 changed files with 50 additions and 50 deletions

View File

@ -1,5 +1,5 @@
<div>
<div id="doBatchPayFeeModal" class="modal" role="dialog">
<div id="doBatchPayFeeModal" class="modal" role="dialog">
<div class="modal-dialog" role="document">
<div class="modal-content">
<div class="modal-header">
@ -91,7 +91,10 @@
<button type="button" class="btn btn-secondary" @click="_back()">
<vc:i18n name="返回" namespace="batchPayConfirm"></vc:i18n>
</button>
<button type="button" class="btn btn-primary" @click="_printAndBack()">
<button type="button" class="btn btn-primary" @click="_printAndBack('ON')">
<vc:i18n name="合并打印" namespace="batchPayConfirm"></vc:i18n>
</button>
<button type="button" class="btn btn-primary" @click="_printAndBack('OFF')">
<vc:i18n name="打印收据" namespace="batchPayConfirm"></vc:i18n>
</button>
</div>

View File

@ -184,9 +184,9 @@
vc.emit('batchPayFeeOrder', 'loadBatchFees',{});
},
_printAndBack: function () {
_printAndBack: function (_merge) {
$('#payFeeResult').modal("hide");
window.open($that.batchPayConfirmInfo.printUrl + "?detailIds=" + $that.batchPayConfirmInfo.detailIds)
window.open($that.batchPayConfirmInfo.printUrl + "?detailIds=" + $that.batchPayConfirmInfo.detailIds+"&merge="+_merge)
},
_back: function () {

View File

@ -1,11 +1,9 @@
<div id="payFeeResult" class="modal" tabindex="-1" role="dialog">
<div id="payFeeResult" class="modal" role="dialog">
<div class="modal-dialog" role="document">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title">
<span>
<span><vc:i18n name="缴费提示" namespace="payFeeOrderResult"></vc:i18n></span>
</span>
<vc:i18n name="缴费提示" namespace="payFeeOrderResult"></vc:i18n>
</h5>
<button type="button" class="close" @click="_back()">
<span aria-hidden="true">&times;</span>
@ -13,34 +11,29 @@
</div>
<div class="modal-body">
<p>
<span>
<span><vc:i18n name="缴费成功" namespace="payFeeOrderResult"></vc:i18n></span>
</span>
<vc:i18n name="缴费成功" namespace="payFeeOrderResult"></vc:i18n>
</p>
<p v-if="!payFeeOrderResultInfo.receiptId">
<span>
<span><vc:i18n name="请到业务受理页面补打收据" namespace="payFeeOrderResult"></vc:i18n></span>
</span>
<vc:i18n name="请到业务受理页面补打收据" namespace="payFeeOrderResult"></vc:i18n>
</p>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-secondary" @click="_back()">
<span>
<span><vc:i18n name="返回" namespace="payFeeOrderResult"></vc:i18n></span>
</span>
<vc:i18n name="返回" namespace="payFeeOrderResult"></vc:i18n>
</button>
<button type="button" class="btn btn-primary" v-if="payFeeOrderResultInfo.receiptId"
@click="_printSmallAndBack()">
<span>
<span><vc:i18n name="打印小票" namespace="payFeeOrderResult"></vc:i18n></span>
</span>
@click="_printSmallAndBack()">
<vc:i18n name="打印小票" namespace="payFeeOrderResult"></vc:i18n>
</button>
<button type="button" class="btn btn-primary" v-if="payFeeOrderResultInfo.receiptId"
@click="_printAndBack()">
<span>
<span><vc:i18n name="打印收据" namespace="payFeeOrderResult"></vc:i18n></span>
</span>
@click="_printAndBack('ON')">
<vc:i18n name="合并打印" namespace="payFeeOrderResult"></vc:i18n>
</button>
<button type="button" class="btn btn-primary" v-if="payFeeOrderResultInfo.receiptId"
@click="_printAndBack('OFF')">
<vc:i18n name="打印收据" namespace="payFeeOrderResult"></vc:i18n>
</button>
</div>
</div>
</div>

View File

@ -53,9 +53,9 @@
}
);
},
_printAndBack: function () {
_printAndBack: function (_merge) {
//$('#payFeeResult').modal("hide");
window.open($that.payFeeOrderResultInfo.printUrl + "?receiptId=" + $that.payFeeOrderResultInfo.receiptId)
window.open($that.payFeeOrderResultInfo.printUrl + "?receiptId=" + $that.payFeeOrderResultInfo.receiptId+"&merge="+_merge)
},
_printSmallAndBack: function () {
//$('#payFeeResult').modal("hide");

View File

@ -3,10 +3,6 @@
<div class="col-lg-2 padding-right-xs padding-left-xl">
<select class="custom-select custom-select-sm" v-model="simplifyFeeReceiptInfo.objType"
@change="_changeSimplifyFeeReceiptFeeTypeCd(simplifyFeeReceiptInfo.objType)">
<option disabled value="">{{vc.i18n('请选择收费类型','simplifyFeeReceipt')}}</option>
<option selected value="3333">{{vc.i18n('房屋费','simplifyFeeReceipt')}}</option>
<option value="6666">{{vc.i18n('车位费','simplifyFeeReceipt')}}</option>
<option value="7777">{{vc.i18n('合同费','simplifyFeeReceipt')}}</option>-->
<option selected disabled value="">
{{vc.i18n('请选择收费类型','simplifyFeeReceipt')}}
</option>
@ -56,7 +52,10 @@
</div>
<div class="col-lg-4 text-right padding-right-lg">
<button type="button" class="btn btn-primary btn-sm" style="margin-left:10px"
v-on:click="_printFeeReceipt()">打印
v-on:click="_printFeeReceipt('OFF')">打印
</button>
<button type="button" class="btn btn-primary btn-sm" style="margin-left:10px"
v-on:click="_printFeeReceipt('ON')">合并打印
</button>
<button type="button" class="btn btn-primary btn-sm" style="margin-left:10px"
v-on:click="_printFeeSmallReceipt()">打印小票
@ -132,13 +131,6 @@
<td class="text-center">{{feeReceipt.receiptId}}</td>
</tr>
</tbody>
<tfoot>
<tr>
<td colspan="10">
<ul class="pagination float-right"></ul>
</td>
</tr>
</tfoot>
</table>
<div class="row">
<div class="col-sm-12 float-right">

View File

@ -114,7 +114,7 @@
_queryFeeReceiptMethod: function () {
vc.component._listSimplifyFeeReceipt(DEFAULT_PAGE, DEFAULT_ROWS);
},
_printFeeReceipt: function (_receipt) {
_printFeeReceipt: function (_merge) {
if ($that.simplifyFeeReceiptInfo.selectReceipts.length < 1) {
vc.toast('请选择打印收据');
return;
@ -126,7 +126,7 @@
if (receiptids.endsWith(',')) {
receiptids = receiptids.substring(0, receiptids.length - 1);
}
window.open($that.simplifyFeeReceiptInfo.printUrl + "?receiptIds=" + receiptids + "&apply=N");
window.open($that.simplifyFeeReceiptInfo.printUrl + "?receiptIds=" + receiptids + "&apply=N&merge="+_merge);
},
_printApplyFeeReceipt: function (_receipt) {
if ($that.simplifyFeeReceiptInfo.selectReceipts.length < 1) {

View File

@ -192,7 +192,11 @@
<button type="button" class="btn btn-secondary" @click="_back()">
<vc:i18n name="返回" namespace="owePayFeeOrder"></vc:i18n>
</button>
<button type="button" class="btn btn-primary" @click="_printAndBack()">
<button type="button" class="btn btn-primary"
@click="_printAndBack('ON')">
<vc:i18n name="合并打印" namespace="payFeeOrderResult"></vc:i18n>
</button>
<button type="button" class="btn btn-primary" @click="_printAndBack('OFF')">
<vc:i18n name="打印收据" namespace="owePayFeeOrder"></vc:i18n>
</button>
</div>

View File

@ -301,10 +301,10 @@
$('#payFeeResult').modal("hide");
vc.getBack();
},
_printAndBack: function () {
_printAndBack: function (_merge) {
$('#payFeeResult').modal("hide");
// window.open("/print.html#/pages/property/printPayFee?receiptIds=" + $that.owePayFeeOrderInfo.receiptIds);
window.open($that.owePayFeeOrderInfo.printUrl + "?detailIds=" + $that.owePayFeeOrderInfo.detailIds)
window.open($that.owePayFeeOrderInfo.printUrl + "?detailIds=" + $that.owePayFeeOrderInfo.detailIds+"&merge="+_merge)
},
_dealSelectFee: function () {
let totalFee = 0.00;

View File

@ -28,6 +28,7 @@
$that.printPayFeeInfo.receiptIds = vc.getParam('receiptIds');
$that.printPayFeeInfo.detailIds = vc.getParam('detailIds');
$that.printPayFeeInfo.apply = vc.getParam('apply');
$that.printPayFeeInfo.merge = vc.getParam('merge');
//$that.printPayFeeInfo.feeTime = vc.dateTimeFormat(new Date());
@ -93,7 +94,8 @@
receiptId: $that.printPayFeeInfo.receiptId,
receiptIds: $that.printPayFeeInfo.receiptIds,
detailIds: $that.printPayFeeInfo.detailIds,
communityId: vc.getCurrentCommunity().communityId
communityId: vc.getCurrentCommunity().communityId,
mergeFee:$that.printPayFeeInfo.merge
}
};

View File

@ -26,7 +26,7 @@
$that.printPayFeeInfo.receiptId = vc.getParam('receiptId');
$that.printPayFeeInfo.receiptIds = vc.getParam('receiptIds');
$that.printPayFeeInfo.apply = vc.getParam('apply');
$that.printPayFeeInfo.merge = vc.getParam('merge');
//$that.printPayFeeInfo.feeTime = vc.dateTimeFormat(new Date());
$that.printPayFeeInfo.communityName = vc.getCurrentCommunity().name;
@ -89,7 +89,9 @@
row: 100,
receiptId: $that.printPayFeeInfo.receiptId,
receiptIds: $that.printPayFeeInfo.receiptIds,
communityId: vc.getCurrentCommunity().communityId
communityId: vc.getCurrentCommunity().communityId,
mergeFee:$that.printPayFeeInfo.merge
}
};

View File

@ -32,6 +32,8 @@
$that.printPayFeeInfo.receiptIds = vc.getParam('receiptIds');
$that.printPayFeeInfo.detailIds = vc.getParam('detailIds');
$that.printPayFeeInfo.apply = vc.getParam('apply');
$that.printPayFeeInfo.merge = vc.getParam('merge');
//$that.printPayFeeInfo.feeTime = vc.dateTimeFormat(new Date());
@ -100,7 +102,8 @@
receiptId: $that.printPayFeeInfo.receiptId,
receiptIds: $that.printPayFeeInfo.receiptIds,
detailIds: $that.printPayFeeInfo.detailIds,
communityId: vc.getCurrentCommunity().communityId
communityId: vc.getCurrentCommunity().communityId,
mergeFee:$that.printPayFeeInfo.merge
}
};

View File

@ -28,7 +28,7 @@
$that.printPayFeeInfo.receiptIds = vc.getParam('receiptIds');
$that.printPayFeeInfo.detailIds = vc.getParam('detailIds');
$that.printPayFeeInfo.apply = vc.getParam('apply');
$that.printPayFeeInfo.merge = vc.getParam('merge');
//$that.printPayFeeInfo.feeTime = vc.dateTimeFormat(new Date());
$that.printPayFeeInfo.communityName = vc.getCurrentCommunity().name;
@ -93,7 +93,8 @@
receiptId: $that.printPayFeeInfo.receiptId,
receiptIds: $that.printPayFeeInfo.receiptIds,
detailIds: $that.printPayFeeInfo.detailIds,
communityId: vc.getCurrentCommunity().communityId
communityId: vc.getCurrentCommunity().communityId,
mergeFee:$that.printPayFeeInfo.merge
}
};