给收款单和付款单页面增加欠款列表界面,并可以快捷收款或付款

This commit is contained in:
jishenghua
2025-04-29 11:52:14 +08:00
parent 320fb7d404
commit 6ef8848bf4
7 changed files with 117 additions and 18 deletions

View File

@@ -100,7 +100,7 @@
<!-- 操作按钮区域 --> <!-- 操作按钮区域 -->
<div class="table-operator" style="margin-top: 5px"> <div class="table-operator" style="margin-top: 5px">
<a-button v-if="btnEnableList.indexOf(1)>-1" @click="myHandleAdd" type="primary" icon="plus">新增</a-button> <a-button v-if="btnEnableList.indexOf(1)>-1" @click="myHandleAdd" type="primary" icon="plus">新增</a-button>
<a-button v-if="btnEnableList.indexOf(1)>-1" @click="handleWaitNeed('客户')" icon="link">待收款({{waitTotal}})</a-button> <a-button v-if="btnEnableList.indexOf(1)>-1" @click="myHandleAddWithOrgan" icon="link">待收款({{waitTotal}})</a-button>
<a-button v-if="btnEnableList.indexOf(1)>-1" icon="delete" @click="batchDel">删除</a-button> <a-button v-if="btnEnableList.indexOf(1)>-1" icon="delete" @click="batchDel">删除</a-button>
<a-button v-if="checkFlag && btnEnableList.indexOf(2)>-1" icon="check" @click="batchSetStatus(1)">审核</a-button> <a-button v-if="checkFlag && btnEnableList.indexOf(2)>-1" icon="check" @click="batchSetStatus(1)">审核</a-button>
<a-button v-if="checkFlag && btnEnableList.indexOf(7)>-1" icon="stop" @click="batchSetStatus(0)">反审核</a-button> <a-button v-if="checkFlag && btnEnableList.indexOf(7)>-1" icon="stop" @click="batchSetStatus(0)">反审核</a-button>
@@ -145,7 +145,6 @@
<!-- 表单区域 --> <!-- 表单区域 -->
<money-in-modal ref="modalForm" @ok="modalFormOk" @close="modalFormClose"></money-in-modal> <money-in-modal ref="modalForm" @ok="modalFormOk" @close="modalFormClose"></money-in-modal>
<financial-detail ref="modalDetail" @ok="modalFormOk" @close="modalFormClose"></financial-detail> <financial-detail ref="modalDetail" @ok="modalFormOk" @close="modalFormClose"></financial-detail>
<wait-need-list ref="waitNeedList" @ok="modalFormOk" @close="modalFormClose"></wait-need-list>
<bill-excel-iframe ref="billExcelIframe" @ok="modalFormOk" @close="modalFormClose"></bill-excel-iframe> <bill-excel-iframe ref="billExcelIframe" @ok="modalFormOk" @close="modalFormClose"></bill-excel-iframe>
</a-card> </a-card>
</a-col> </a-col>
@@ -154,19 +153,19 @@
<script> <script>
import MoneyInModal from './modules/MoneyInModal' import MoneyInModal from './modules/MoneyInModal'
import FinancialDetail from './dialog/FinancialDetail' import FinancialDetail from './dialog/FinancialDetail'
import WaitNeedList from './dialog/WaitNeedList'
import BillExcelIframe from '@/components/tools/BillExcelIframe' import BillExcelIframe from '@/components/tools/BillExcelIframe'
import { JeecgListMixin } from '@/mixins/JeecgListMixin' import { JeecgListMixin } from '@/mixins/JeecgListMixin'
import { FinancialListMixin } from './mixins/FinancialListMixin' import { FinancialListMixin } from './mixins/FinancialListMixin'
import JDate from '@/components/jeecg/JDate' import JDate from '@/components/jeecg/JDate'
import Vue from 'vue' import { getFormatDate, getPrevMonthFormatDate } from '@/utils/util'
import moment from 'moment'
import { getAction } from '@/api/manage'
export default { export default {
name: "MoneyInList", name: "MoneyInList",
mixins:[JeecgListMixin, FinancialListMixin], mixins:[JeecgListMixin, FinancialListMixin],
components: { components: {
MoneyInModal, MoneyInModal,
FinancialDetail, FinancialDetail,
WaitNeedList,
BillExcelIframe, BillExcelIframe,
JDate JDate
}, },
@@ -232,9 +231,28 @@
this.initUser() this.initUser()
this.initPerson() this.initPerson()
this.initAccount() this.initAccount()
this.initGetNeedCount('customer')
}, },
methods: { methods: {
loadData(arg) {
if (arg === 1) {
this.ipagination.current = 1
}
let params = this.getQueryParams() //查询条件
this.loading = true
getAction(this.url.list, params).then((res) => {
if (res.code===200) {
this.dataSource = res.data.rows
this.ipagination.total = res.data.total
this.initGetNeedCount('customer')
} else if(res.code===510){
this.$message.warning(res.data)
} else {
this.$message.warning(res.data.message)
}
this.loading = false
this.onClearSelected()
})
}
} }
} }
</script> </script>

View File

@@ -100,7 +100,7 @@
<!-- 操作按钮区域 --> <!-- 操作按钮区域 -->
<div class="table-operator" style="margin-top: 5px"> <div class="table-operator" style="margin-top: 5px">
<a-button v-if="btnEnableList.indexOf(1)>-1" @click="myHandleAdd" type="primary" icon="plus">新增</a-button> <a-button v-if="btnEnableList.indexOf(1)>-1" @click="myHandleAdd" type="primary" icon="plus">新增</a-button>
<a-button v-if="btnEnableList.indexOf(1)>-1" @click="handleWaitNeed('供应商')" icon="link">待付款({{waitTotal}})</a-button> <a-button v-if="btnEnableList.indexOf(1)>-1" @click="myHandleAddWithOrgan" icon="link">待付款({{waitTotal}})</a-button>
<a-button v-if="btnEnableList.indexOf(1)>-1" icon="delete" @click="batchDel">删除</a-button> <a-button v-if="btnEnableList.indexOf(1)>-1" icon="delete" @click="batchDel">删除</a-button>
<a-button v-if="checkFlag && btnEnableList.indexOf(2)>-1" icon="check" @click="batchSetStatus(1)">审核</a-button> <a-button v-if="checkFlag && btnEnableList.indexOf(2)>-1" icon="check" @click="batchSetStatus(1)">审核</a-button>
<a-button v-if="checkFlag && btnEnableList.indexOf(7)>-1" icon="stop" @click="batchSetStatus(0)">反审核</a-button> <a-button v-if="checkFlag && btnEnableList.indexOf(7)>-1" icon="stop" @click="batchSetStatus(0)">反审核</a-button>
@@ -145,7 +145,6 @@
<!-- 表单区域 --> <!-- 表单区域 -->
<money-out-modal ref="modalForm" @ok="modalFormOk" @close="modalFormClose"></money-out-modal> <money-out-modal ref="modalForm" @ok="modalFormOk" @close="modalFormClose"></money-out-modal>
<financial-detail ref="modalDetail" @ok="modalFormOk" @close="modalFormClose"></financial-detail> <financial-detail ref="modalDetail" @ok="modalFormOk" @close="modalFormClose"></financial-detail>
<wait-need-list ref="waitNeedList" @ok="modalFormOk" @close="modalFormClose"></wait-need-list>
<bill-excel-iframe ref="billExcelIframe" @ok="modalFormOk" @close="modalFormClose"></bill-excel-iframe> <bill-excel-iframe ref="billExcelIframe" @ok="modalFormOk" @close="modalFormClose"></bill-excel-iframe>
</a-card> </a-card>
</a-col> </a-col>
@@ -154,19 +153,18 @@
<script> <script>
import MoneyOutModal from './modules/MoneyOutModal' import MoneyOutModal from './modules/MoneyOutModal'
import FinancialDetail from './dialog/FinancialDetail' import FinancialDetail from './dialog/FinancialDetail'
import WaitNeedList from './dialog/WaitNeedList'
import BillExcelIframe from '@/components/tools/BillExcelIframe' import BillExcelIframe from '@/components/tools/BillExcelIframe'
import { JeecgListMixin } from '@/mixins/JeecgListMixin' import { JeecgListMixin } from '@/mixins/JeecgListMixin'
import { FinancialListMixin } from './mixins/FinancialListMixin' import { FinancialListMixin } from './mixins/FinancialListMixin'
import JDate from '@/components/jeecg/JDate' import JDate from '@/components/jeecg/JDate'
import Vue from 'vue' import Vue from 'vue'
import { getAction } from '@/api/manage'
export default { export default {
name: "MoneyOutList", name: "MoneyOutList",
mixins:[JeecgListMixin, FinancialListMixin], mixins:[JeecgListMixin, FinancialListMixin],
components: { components: {
MoneyOutModal, MoneyOutModal,
FinancialDetail, FinancialDetail,
WaitNeedList,
BillExcelIframe, BillExcelIframe,
JDate JDate
}, },
@@ -232,9 +230,28 @@
this.initUser() this.initUser()
this.initPerson() this.initPerson()
this.initAccount() this.initAccount()
this.initGetNeedCount('vendor')
}, },
methods: { methods: {
loadData(arg) {
if (arg === 1) {
this.ipagination.current = 1
}
let params = this.getQueryParams() //查询条件
this.loading = true
getAction(this.url.list, params).then((res) => {
if (res.code===200) {
this.dataSource = res.data.rows
this.ipagination.total = res.data.total
this.initGetNeedCount('vendor')
} else if(res.code===510){
this.$message.warning(res.data)
} else {
this.$message.warning(res.data.message)
}
this.loading = false
this.onClearSelected()
})
}
} }
} }
</script> </script>

View File

@@ -64,6 +64,7 @@
import { JeecgListMixin } from '@/mixins/JeecgListMixin' import { JeecgListMixin } from '@/mixins/JeecgListMixin'
import { findBySelectCus, findBySelectSup } from '@/api/api' import { findBySelectCus, findBySelectSup } from '@/api/api'
import { getFormatDate } from '@/utils/util' import { getFormatDate } from '@/utils/util'
import { getAction } from '@/api/manage'
export default { export default {
name: 'WaitNeedList', name: 'WaitNeedList',
mixins:[JeecgListMixin], mixins:[JeecgListMixin],
@@ -75,6 +76,7 @@
organType: '', organType: '',
actionType: '', actionType: '',
supList: [], supList: [],
selectBillRows: [],
queryParam: { queryParam: {
organId: undefined, organId: undefined,
supplierType: '', supplierType: '',
@@ -131,8 +133,6 @@
this.queryParam.supplierType = '供应商' this.queryParam.supplierType = '供应商'
this.actionType = '付款' this.actionType = '付款'
} }
this.ipagination.pageSize = 100
this.ipagination.pageSizeOptions = ['100', '200', '300']
this.loadData(1) this.loadData(1)
this.initSupplier() this.initSupplier()
}, },
@@ -152,8 +152,37 @@
}) })
} }
}, },
//选择供应商进行付款,选择客户进行收款
handleAction(record) { handleAction(record) {
let type = ''
let subType = ''
if(this.organType === '客户') {
type = '出库'
subType = '销售'
} else if(this.organType === '供应商') {
type = '入库'
subType = '采购'
}
let params = {
search: {
organId: record.id,
materialParam: "",
number: "",
type: type,
subType: subType,
status: ""
},
currentPage: 1,
pageSize: 1000
}
getAction('/depotHead/debtList', params).then((res) => {
if (res.code === 200) {
this.selectBillRows = res.data.rows
this.$emit('ok', record.id, this.selectBillRows)
this.selectBillRows = []
this.close()
}
})
}, },
close () { close () {
this.$emit('close') this.$emit('close')

View File

@@ -60,7 +60,16 @@ export const FinancialListMixin = {
}, },
methods: { methods: {
myHandleAdd() { myHandleAdd() {
this.$refs.modalForm.action = "add"; this.$refs.modalForm.action = "add"
this.$refs.modalForm.actionWithOrgan = false
if(this.btnEnableList.indexOf(2)===-1) {
this.$refs.modalForm.isCanCheck = false
}
this.handleAdd();
},
myHandleAddWithOrgan() {
this.$refs.modalForm.action = "add"
this.$refs.modalForm.actionWithOrgan = true
if(this.btnEnableList.indexOf(2)===-1) { if(this.btnEnableList.indexOf(2)===-1) {
this.$refs.modalForm.isCanCheck = false this.$refs.modalForm.isCanCheck = false
} }
@@ -204,9 +213,6 @@ export const FinancialListMixin = {
onDateOk(value) { onDateOk(value) {
console.log(value); console.log(value);
}, },
handleWaitNeed(organType) {
this.$refs.waitNeedList.show(organType)
},
//导出单据 //导出单据
handleExport() { handleExport() {
let search = this.getQueryParams().search let search = this.getQueryParams().search

View File

@@ -9,6 +9,7 @@ export const FinancialModalMixin = {
data() { data() {
return { return {
action: '', action: '',
actionWithOrgan: false,
supList: [], supList: [],
cusList: [], cusList: [],
retailList: [], retailList: [],
@@ -233,6 +234,14 @@ export const FinancialModalMixin = {
workflowModalFormOk() { workflowModalFormOk() {
this.close() this.close()
}, },
waitNeedListOk(organId, selectBillRows) {
if(organId) {
this.form.setFieldsValue({'organId': organId})
}
if (selectBillRows && selectBillRows.length > 0) {
this.requestSubTableDataEx(selectBillRows, this.accountTable);
}
},
onAdded(event) { onAdded(event) {
let that = this let that = this
const { row, target } = event const { row, target } = event

View File

@@ -144,6 +144,7 @@
<customer-modal ref="customerModalForm" @ok="customerModalFormOk"></customer-modal> <customer-modal ref="customerModalForm" @ok="customerModalFormOk"></customer-modal>
<account-modal ref="accountModalForm" @ok="accountModalFormOk"></account-modal> <account-modal ref="accountModalForm" @ok="accountModalFormOk"></account-modal>
<person-modal ref="personModalForm" @ok="personModalFormOk"></person-modal> <person-modal ref="personModalForm" @ok="personModalFormOk"></person-modal>
<wait-need-list ref="waitNeedList" @ok="waitNeedListOk"></wait-need-list>
<workflow-iframe ref="modalWorkflow" @ok="workflowModalFormOk"></workflow-iframe> <workflow-iframe ref="modalWorkflow" @ok="workflowModalFormOk"></workflow-iframe>
</j-modal> </j-modal>
</template> </template>
@@ -153,6 +154,7 @@
import CustomerModal from '../../system/modules/CustomerModal' import CustomerModal from '../../system/modules/CustomerModal'
import AccountModal from '../../system/modules/AccountModal' import AccountModal from '../../system/modules/AccountModal'
import PersonModal from '../../system/modules/PersonModal' import PersonModal from '../../system/modules/PersonModal'
import WaitNeedList from '../dialog/WaitNeedList'
import WorkflowIframe from '@/components/tools/WorkflowIframe' import WorkflowIframe from '@/components/tools/WorkflowIframe'
import { FormTypes } from '@/utils/JEditableTableUtil' import { FormTypes } from '@/utils/JEditableTableUtil'
import { JEditableTableMixin } from '@/mixins/JEditableTableMixin' import { JEditableTableMixin } from '@/mixins/JEditableTableMixin'
@@ -167,6 +169,7 @@
CustomerModal, CustomerModal,
AccountModal, AccountModal,
PersonModal, PersonModal,
WaitNeedList,
WorkflowIframe, WorkflowIframe,
JUpload, JUpload,
JDate, JDate,
@@ -240,6 +243,13 @@
if (this.action === 'add') { if (this.action === 'add') {
this.addInit(this.prefixNo) this.addInit(this.prefixNo)
this.fileList = [] this.fileList = []
if(this.actionWithOrgan) {
//自动弹出待收款客户列表
let that = this
setTimeout(function() {
that.$refs.waitNeedList.show('客户')
},1000)
}
} else { } else {
this.model.billTime = this.model.billTimeStr this.model.billTime = this.model.billTimeStr
this.$nextTick(() => { this.$nextTick(() => {

View File

@@ -144,6 +144,7 @@
<vendor-modal ref="vendorModalForm" @ok="vendorModalFormOk"></vendor-modal> <vendor-modal ref="vendorModalForm" @ok="vendorModalFormOk"></vendor-modal>
<account-modal ref="accountModalForm" @ok="accountModalFormOk"></account-modal> <account-modal ref="accountModalForm" @ok="accountModalFormOk"></account-modal>
<person-modal ref="personModalForm" @ok="personModalFormOk"></person-modal> <person-modal ref="personModalForm" @ok="personModalFormOk"></person-modal>
<wait-need-list ref="waitNeedList" @ok="waitNeedListOk"></wait-need-list>
<workflow-iframe ref="modalWorkflow" @ok="workflowModalFormOk"></workflow-iframe> <workflow-iframe ref="modalWorkflow" @ok="workflowModalFormOk"></workflow-iframe>
</j-modal> </j-modal>
</template> </template>
@@ -153,6 +154,7 @@
import VendorModal from '../../system/modules/VendorModal' import VendorModal from '../../system/modules/VendorModal'
import AccountModal from '../../system/modules/AccountModal' import AccountModal from '../../system/modules/AccountModal'
import PersonModal from '../../system/modules/PersonModal' import PersonModal from '../../system/modules/PersonModal'
import WaitNeedList from '../dialog/WaitNeedList'
import WorkflowIframe from '@/components/tools/WorkflowIframe' import WorkflowIframe from '@/components/tools/WorkflowIframe'
import { FormTypes } from '@/utils/JEditableTableUtil' import { FormTypes } from '@/utils/JEditableTableUtil'
import { JEditableTableMixin } from '@/mixins/JEditableTableMixin' import { JEditableTableMixin } from '@/mixins/JEditableTableMixin'
@@ -167,6 +169,7 @@
VendorModal, VendorModal,
AccountModal, AccountModal,
PersonModal, PersonModal,
WaitNeedList,
WorkflowIframe, WorkflowIframe,
JUpload, JUpload,
JDate, JDate,
@@ -243,6 +246,13 @@
if (this.action === 'add') { if (this.action === 'add') {
this.addInit(this.prefixNo) this.addInit(this.prefixNo)
this.fileList = [] this.fileList = []
if(this.actionWithOrgan) {
//自动弹出待收款客户列表
let that = this
setTimeout(function() {
that.$refs.waitNeedList.show('供应商')
},1000)
}
} else { } else {
this.model.billTime = this.model.billTimeStr this.model.billTime = this.model.billTimeStr
this.$nextTick(() => { this.$nextTick(() => {