Browse Source

修改人员导出模板信息

user5 3 years ago
parent
commit
490d686217

+ 22 - 21
src/views/modules/reimbursementSys/accountant/reimbursementIsNoTicketList.vue

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