|
@@ -34,7 +34,7 @@
|
|
</el-form>
|
|
</el-form>
|
|
|
|
|
|
<div class="bg-white top">
|
|
<div class="bg-white top">
|
|
- <vxe-toolbar :refresh="{query: refreshList}" import export print resizable custom>
|
|
|
|
|
|
+ <vxe-toolbar :refresh="{query: refreshList}" export print resizable custom>
|
|
<template #buttons>
|
|
<template #buttons>
|
|
<el-row>
|
|
<el-row>
|
|
<el-button v-if="hasPermission('sys:role:assign')" type="primary" size="small" icon="el-icon-plus"
|
|
<el-button v-if="hasPermission('sys:role:assign')" type="primary" size="small" icon="el-icon-plus"
|
|
@@ -117,7 +117,7 @@
|
|
width="60%">
|
|
width="60%">
|
|
<el-col :span="12">
|
|
<el-col :span="12">
|
|
<label-wrap>请选择年份:</label-wrap>
|
|
<label-wrap>请选择年份:</label-wrap>
|
|
- <el-select v-model="selectedYear" filterable placeholder="请选择" @change="findSelectCodeListByYear">
|
|
|
|
|
|
+ <el-select v-model="selectedYear" filterable placeholder="请选择年份" @change="findSelectCodeListByYear">
|
|
<el-option
|
|
<el-option
|
|
v-for="item in selectYear"
|
|
v-for="item in selectYear"
|
|
:key="item"
|
|
:key="item"
|
|
@@ -128,8 +128,8 @@
|
|
</el-col>
|
|
</el-col>
|
|
|
|
|
|
<el-col :span="12">
|
|
<el-col :span="12">
|
|
- <label-wrap>请选择编号:</label-wrap>
|
|
|
|
- <el-select v-model="selectedCode" filterable placeholder="请选择" @change="determination($event)">
|
|
|
|
|
|
+ <label-wrap>请选择业务编号:</label-wrap>
|
|
|
|
+ <el-select v-model="selectedCode" filterable clearable placeholder="请选择业务编号" @change="determination($event)">
|
|
<el-option
|
|
<el-option
|
|
v-for="item in selectCode"
|
|
v-for="item in selectCode"
|
|
:key="item.id"
|
|
:key="item.id"
|
|
@@ -160,7 +160,7 @@
|
|
import reimbursementSelect from './reimbursementSelectDialog'
|
|
import reimbursementSelect from './reimbursementSelectDialog'
|
|
|
|
|
|
export default {
|
|
export default {
|
|
- data() {
|
|
|
|
|
|
+ data () {
|
|
return {
|
|
return {
|
|
dataList: [],
|
|
dataList: [],
|
|
searchForm: {
|
|
searchForm: {
|
|
@@ -194,15 +194,15 @@
|
|
SelectUserTree
|
|
SelectUserTree
|
|
},
|
|
},
|
|
ReimbursementSys: null,
|
|
ReimbursementSys: null,
|
|
- created() {
|
|
|
|
|
|
+ created () {
|
|
this.reimbursementSys = new ReimbursementSys()
|
|
this.reimbursementSys = new ReimbursementSys()
|
|
},
|
|
},
|
|
- activated() {
|
|
|
|
|
|
+ activated () {
|
|
this.refreshList()
|
|
this.refreshList()
|
|
},
|
|
},
|
|
methods: {
|
|
methods: {
|
|
// 获取数据列表
|
|
// 获取数据列表
|
|
- refreshList() {
|
|
|
|
|
|
+ refreshList () {
|
|
this.loading = true
|
|
this.loading = true
|
|
this.reimbursementSys.findList({
|
|
this.reimbursementSys.findList({
|
|
'current': this.tablePage.currentPage,
|
|
'current': this.tablePage.currentPage,
|
|
@@ -216,23 +216,23 @@
|
|
})
|
|
})
|
|
},
|
|
},
|
|
// 当前页
|
|
// 当前页
|
|
- currentChangeHandle({currentPage, pageSize}) {
|
|
|
|
|
|
+ currentChangeHandle ({currentPage, pageSize}) {
|
|
this.tablePage.currentPage = currentPage
|
|
this.tablePage.currentPage = currentPage
|
|
this.tablePage.pageSize = pageSize
|
|
this.tablePage.pageSize = pageSize
|
|
this.refreshList()
|
|
this.refreshList()
|
|
},
|
|
},
|
|
- resetSearch() {
|
|
|
|
|
|
+ resetSearch () {
|
|
this.$refs.searchForm.resetFields()
|
|
this.$refs.searchForm.resetFields()
|
|
this.$nextTick(() => {
|
|
this.$nextTick(() => {
|
|
this.refreshList()
|
|
this.refreshList()
|
|
})
|
|
})
|
|
},
|
|
},
|
|
// 修改发票信息
|
|
// 修改发票信息
|
|
- modifyInvoice(id) {
|
|
|
|
|
|
+ modifyInvoice (id) {
|
|
this.$refs.reimbursementInvoiceModify.init('modifyInvoice', {id: id, parent: {id: '', name: ''}})
|
|
this.$refs.reimbursementInvoiceModify.init('modifyInvoice', {id: id, parent: {id: '', name: ''}})
|
|
},
|
|
},
|
|
// 删除
|
|
// 删除
|
|
- delInvoice(id) {
|
|
|
|
|
|
+ delInvoice (id) {
|
|
let ids = id || this.$refs.xTree.getCheckboxRecords().map(item => {
|
|
let ids = id || this.$refs.xTree.getCheckboxRecords().map(item => {
|
|
return item.id
|
|
return item.id
|
|
}).join(',')
|
|
}).join(',')
|
|
@@ -253,7 +253,7 @@
|
|
})
|
|
})
|
|
})
|
|
})
|
|
},
|
|
},
|
|
- addBusinessInfo(id, businessCode) {
|
|
|
|
|
|
+ addBusinessInfo (id, businessCode) {
|
|
this.$refs.reimbursementBusinessForm.init('addBusinessInfo', {
|
|
this.$refs.reimbursementBusinessForm.init('addBusinessInfo', {
|
|
id: '',
|
|
id: '',
|
|
businessCodeId: '',
|
|
businessCodeId: '',
|
|
@@ -261,9 +261,9 @@
|
|
parent: {id: '', name: ''}
|
|
parent: {id: '', name: ''}
|
|
})
|
|
})
|
|
},
|
|
},
|
|
- bindBusinessCode() {
|
|
|
|
|
|
+ bindBusinessCode () {
|
|
if (this.selectedCode === '') {
|
|
if (this.selectedCode === '') {
|
|
- this.$message('请选择绑定编号')
|
|
|
|
|
|
+ this.$message.error('请选择业务编号')
|
|
return
|
|
return
|
|
}
|
|
}
|
|
this.reimbursementSys.modifyBindCode({
|
|
this.reimbursementSys.modifyBindCode({
|
|
@@ -273,11 +273,12 @@
|
|
}).then(({data}) => {
|
|
}).then(({data}) => {
|
|
if (!data) {
|
|
if (!data) {
|
|
this.$message.error('可报销额度不足')
|
|
this.$message.error('可报销额度不足')
|
|
|
|
+ } else {
|
|
|
|
+ this.closeDialog()
|
|
}
|
|
}
|
|
- this.closeDialog()
|
|
|
|
})
|
|
})
|
|
},
|
|
},
|
|
- openDialog(obj) {
|
|
|
|
|
|
+ openDialog (obj) {
|
|
// eslint-disable-next-line eqeqeq
|
|
// eslint-disable-next-line eqeqeq
|
|
this.bindObj = obj.id || obj.map(item => {
|
|
this.bindObj = obj.id || obj.map(item => {
|
|
return item.id
|
|
return item.id
|
|
@@ -296,21 +297,21 @@
|
|
this.findSelectCodeListByYear()
|
|
this.findSelectCodeListByYear()
|
|
})
|
|
})
|
|
},
|
|
},
|
|
- closeDialog() {
|
|
|
|
|
|
+ closeDialog () {
|
|
this.dialogVisible = false
|
|
this.dialogVisible = false
|
|
this.selectedCode = ''
|
|
this.selectedCode = ''
|
|
this.refreshList()
|
|
this.refreshList()
|
|
this.bindObj = []
|
|
this.bindObj = []
|
|
this.reimbursementAmount = 0
|
|
this.reimbursementAmount = 0
|
|
},
|
|
},
|
|
- findSelectCodeListByYear() {
|
|
|
|
|
|
+ findSelectCodeListByYear () {
|
|
this.selectedCode = ''
|
|
this.selectedCode = ''
|
|
this.reimbursementSys.findSelectCodeListByYear(this.selectedYear).then(({data}) => {
|
|
this.reimbursementSys.findSelectCodeListByYear(this.selectedYear).then(({data}) => {
|
|
this.selectCode = data
|
|
this.selectCode = data
|
|
- this.selectedCode = this.selectCode[0].id
|
|
|
|
|
|
+ this.selectedCode = ''
|
|
})
|
|
})
|
|
},
|
|
},
|
|
- determination(e) {
|
|
|
|
|
|
+ determination (e) {
|
|
console.log(e)
|
|
console.log(e)
|
|
for (let i = 0; i < this.selectCode.length; i++) {
|
|
for (let i = 0; i < this.selectCode.length; i++) {
|
|
if (this.selectCode[i].id === e) {
|
|
if (this.selectCode[i].id === e) {
|