Commit 2fa13a5e by chenwq

fix(financeManage): 修复财务管理系统中的多个问题

修复动态表格删除行时未触发输入框失焦事件的问题
调整价格限制函数参数从9位改为7位
统一分页参数currentPage为pageNum
优化表格样式和高度设置
修复金额验证提示信息错误
调整表格列固定和样式
优化图片预览逻辑
1 parent 334e11eb
...@@ -19,9 +19,9 @@ ...@@ -19,9 +19,9 @@
<el-table-column align="center" width="60px" label="序号" type="index" :index=" <el-table-column align="center" width="60px" label="序号" type="index" :index="
(index) => (index) =>
index + index +
((page.currentPage ((page.pageNum
? page.currentPage ? page.pageNum
: page.currentPage) - : page.pageNum) -
1) * page.pageSize + 1 1) * page.pageSize + 1
" /> " />
<el-table-column label="订单编号" prop="orderCode" align="center"></el-table-column> <el-table-column label="订单编号" prop="orderCode" align="center"></el-table-column>
...@@ -57,7 +57,7 @@ ...@@ -57,7 +57,7 @@
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
<el-pagination background @current-change="jumpPage" :current-page.sync="page.currentPage" :page-size="page.pageSize" layout="total, prev, pager, next" :total="tableTotal" /> <el-pagination background @current-change="jumpPage" :current-page.sync="page.pageNum" :page-size="page.pageSize" layout="total, prev, pager, next" :total="tableTotal" />
<div class="selected_box" v-if="selectedData.length"> <div class="selected_box" v-if="selectedData.length">
<span>已选订单:</span> <span>已选订单:</span>
<el-tooltip class="item" :content="formatSelected(selectedData, 'all')" placement="right"> <el-tooltip class="item" :content="formatSelected(selectedData, 'all')" placement="right">
...@@ -142,7 +142,7 @@ export default { ...@@ -142,7 +142,7 @@ export default {
tableTotal: 0, tableTotal: 0,
page: { page: {
pageSize: 10, pageSize: 10,
currentPage: 1 pageNum: 1
}, },
baseData: { baseData: {
searchPayTypeList: deepClone(payTypeList) searchPayTypeList: deepClone(payTypeList)
...@@ -288,7 +288,7 @@ export default { ...@@ -288,7 +288,7 @@ export default {
ymerchantId: this.infoForm?.yqMerchantId, // 对账园区店 ymerchantId: this.infoForm?.yqMerchantId, // 对账园区店
merchantId: this.infoForm?.shopMerchantId, // 对账流量方 merchantId: this.infoForm?.shopMerchantId, // 对账流量方
...searchFormSearch, ...searchFormSearch,
currentPage: this.page.currentPage, pageNum: this.page.pageNum,
pageSize: this.page.pageSize, pageSize: this.page.pageSize,
// filterTransferAccounts: true, // 固定传参 // filterTransferAccounts: true, // 固定传参
// shopTrafficMoneyFlag: 'Y', // 固定传参 // shopTrafficMoneyFlag: 'Y', // 固定传参
...@@ -296,7 +296,7 @@ export default { ...@@ -296,7 +296,7 @@ export default {
} }
}, },
jumpPage(page) { jumpPage(page) {
this.page.currentPage = page this.page.pageNum = page
this.getOrderList() this.getOrderList()
}, },
handleSearch() { handleSearch() {
...@@ -311,7 +311,7 @@ export default { ...@@ -311,7 +311,7 @@ export default {
payType: '', payType: '',
orderGoodsName: '' orderGoodsName: ''
} }
this.page.currentPage = 1 this.page.pageNum = 1
this.handleSearch() this.handleSearch()
}, },
......
<template> <template>
<div class="dynamic-table-container"> <div class="dynamic-table-container">
{{configObj.title}}调整:<el-button type="default" style="padding: 8px 20px;" v-if="isEdit" @click="addRow"> <span class="title">{{configObj.title}}调整:</span><el-button type="default" style="padding: 8px 20px;" v-if="isEdit" @click="addRow">
添加事由 添加事由
</el-button> </el-button>
...@@ -121,11 +121,12 @@ export default { ...@@ -121,11 +121,12 @@ export default {
deleteRow(index) { deleteRow(index) {
this.tableData.splice(index, 1); this.tableData.splice(index, 1);
this.tableOldData = deepClone(this.tableData) this.tableOldData = deepClone(this.tableData)
this.$emit('handleInputBlur')
}, },
handleInput(rowIdx, attr) { handleInput(rowIdx, attr) {
const val = this.tableData[rowIdx][attr] const val = this.tableData[rowIdx][attr]
const oldVal = this.tableOldData[rowIdx][attr] const oldVal = this.tableOldData[rowIdx][attr]
this.tableData[rowIdx][attr] = limitPrice(val, oldVal, 9, 2, '', '', 'priceReg_negative') this.tableData[rowIdx][attr] = limitPrice(val, oldVal, 7, 2, '', '', 'priceReg_negative')
this.tableOldData[rowIdx][attr] = this.tableData[rowIdx][attr] this.tableOldData[rowIdx][attr] = this.tableData[rowIdx][attr]
}, },
handleInputBlur() { handleInputBlur() {
...@@ -146,8 +147,11 @@ export default { ...@@ -146,8 +147,11 @@ export default {
<style lang="scss"> <style lang="scss">
.dynamic-table-container { .dynamic-table-container {
box-sizing: border-box;
padding: 20px 20px 0 20px; padding: 20px 20px 0 20px;
.title {
font-size: 14px;
}
.el-table--medium td { .el-table--medium td {
padding: 4px 16px !important; padding: 4px 16px !important;
} }
......
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
<div>{{dateStr}}销售对账单</div> <div>{{dateStr}}销售对账单</div>
<div>适用对象:{{billTmplInfo.billMerchantName}}</div> <div>适用对象:{{billTmplInfo.billMerchantName}}</div>
</div> </div>
<el-table v-loading="loading" :data="tableList" style="width: 100%" height="452px" ref="billMutiTable" show-summary :summary-method="getSummaries" :span-method="arraySpanMethod"> <el-table v-loading="loading" :data="tableList" style="width: 100%" height="652px" ref="billMutiTable" show-summary :summary-method="getSummaries" :span-method="arraySpanMethod">
<el-table-column v-for="(item, idx) in tableHeader" :key="idx" :label="item.moduleName"> <el-table-column v-for="(item, idx) in tableHeader" :key="idx" :label="item.moduleName">
<el-table-column v-for="(subItem, subIdx) in item.items" :key="subIdx" :prop="subItem.fieldCode" :label="subItem.fieldName" :width="subItem.width || '120px'"> <el-table-column v-for="(subItem, subIdx) in item.items" :key="subIdx" :prop="subItem.fieldCode" :label="subItem.fieldName" :width="subItem.width || '120px'">
<div class="tb-header-cell" slot="header"> <div class="tb-header-cell" slot="header">
...@@ -44,8 +44,8 @@ ...@@ -44,8 +44,8 @@
<div>总产值:{{ totalAmount }}元</div> <div>总产值:{{ totalAmount }}元</div>
<div v-if="billTypeStr == 'traffic'">应收总额:{{ totalReceivable }}元</div> <div v-if="billTypeStr == 'traffic'">应收总额:{{ totalReceivable }}元</div>
<div>应付总额:{{ totalPayable }}元</div> <div>应付总额:{{ totalPayable }}元</div>
<div>线上分账总额:{{ totalSplitPaidAmount }}元</div> <div v-if="billTypeStr == 'traffic'">线上分账总额:{{ totalSplitPaidAmount }}元</div>
<div>线下已付总额:{{ totalOfflinePaidAmount }}元</div> <div v-if="billTypeStr == 'traffic'">线下已付总额:{{ totalOfflinePaidAmount }}元</div>
<div v-if="billTypeStr == 'traffic'">线下对账总额:{{ totalOfflineReconciliation }}元</div> <div v-if="billTypeStr == 'traffic'">线下对账总额:{{ totalOfflineReconciliation }}元</div>
</div> </div>
<div class="btn-box"> <div class="btn-box">
...@@ -138,14 +138,6 @@ export default { ...@@ -138,14 +138,6 @@ export default {
optionLabel: 'confLabel', optionLabel: 'confLabel',
optionsName: 'reconcileStatusList', optionsName: 'reconcileStatusList',
}, { }, {
name: '备注',
source: 'ORDER',
attr: 'coverReceiverType',
type: 'select',
optionId: 'confId',
optionLabel: 'confLabel',
optionsName: 'coverReceiverTypeList',
}, {
name: '订单时间', name: '订单时间',
source: 'ORDER', source: 'ORDER',
attr: 'orderTime', attr: 'orderTime',
...@@ -225,14 +217,6 @@ export default { ...@@ -225,14 +217,6 @@ export default {
optionLabel: 'confLabel', optionLabel: 'confLabel',
optionsName: 'payTypeList', optionsName: 'payTypeList',
}, { }, {
name: '备注',
source: 'ORDER',
attr: 'coverReceiverType',
type: 'select',
optionId: 'confId',
optionLabel: 'confLabel',
optionsName: 'coverReceiverTypeList',
}, {
name: '订单时间', name: '订单时间',
source: 'ORDER', source: 'ORDER',
attr: 'orderTime', attr: 'orderTime',
...@@ -584,6 +568,9 @@ export default { ...@@ -584,6 +568,9 @@ export default {
row.ORDER.payVoucherList.forEach(item => { row.ORDER.payVoucherList.forEach(item => {
this.imgList.push(item.payVoucher) this.imgList.push(item.payVoucher)
}) })
if (!this.imgList.length) {
return true
}
this.imgVisible = !this.imgVisible this.imgVisible = !this.imgVisible
}, },
...@@ -648,9 +635,11 @@ export default { ...@@ -648,9 +635,11 @@ export default {
} }
} }
.privacyDrawer { .privacyDrawer {
box-sizing: border-box;
padding: 20px; padding: 20px;
overflow: scroll; overflow: scroll;
height: calc(100% - 120px); height: auto;
max-height: calc(100vh - 148px);
} }
.flex { .flex {
display: flex; display: flex;
...@@ -755,11 +744,11 @@ export default { ...@@ -755,11 +744,11 @@ export default {
display: inline-block; /* 或者 inline */ display: inline-block; /* 或者 inline */
} }
.tb-cell { .tb-cell {
padding: 6px; padding: 0px 6px;
text-align: center; text-align: center;
} }
::v-deep .el-table .cell { ::v-deep .el-table .cell {
padding: 6px !important; padding: 0px 6px !important;
text-align: center; text-align: center;
} }
::v-deep .el-table__footer-wrapper tbody td { ::v-deep .el-table__footer-wrapper tbody td {
...@@ -812,6 +801,7 @@ export default { ...@@ -812,6 +801,7 @@ export default {
align-items: center; align-items: center;
// text-align: right; // text-align: right;
padding: 0 30px; padding: 0 30px;
background: #ffffff;
.btn-box { .btn-box {
background: #ffffff; background: #ffffff;
width: 200px; width: 200px;
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!