|
@@ -1,66 +1,87 @@
|
|
|
<!--费用模板-->
|
|
|
<template>
|
|
|
<div>
|
|
|
- <basic-container v-if="isShow">
|
|
|
- <avue-crud :option="option"
|
|
|
- :table-loading="loading"
|
|
|
- :data="data"
|
|
|
- :page.sync="page"
|
|
|
- :permission="permissionList"
|
|
|
- id="out-table"
|
|
|
- :header-cell-class-name="headerClassName"
|
|
|
- :before-open="beforeOpen"
|
|
|
- v-model="form"
|
|
|
- ref="crud"
|
|
|
- @row-update="rowUpdate"
|
|
|
- @row-save="rowSave"
|
|
|
- @row-del="rowDel"
|
|
|
- @search-change="searchChange"
|
|
|
- @search-reset="searchReset"
|
|
|
- @selection-change="selectionChange"
|
|
|
- @current-change="currentChange"
|
|
|
- @size-change="sizeChange"
|
|
|
- @refresh-change="refreshChange"
|
|
|
- @resetColumn="resetColumnTwo('crud', 'option', 'optionBack', 303)"
|
|
|
- @saveColumn="saveColumnTwo('crud', 'option', 'optionBack', 303)"
|
|
|
- @on-load="onLoad">
|
|
|
- <template slot="menuLeft">
|
|
|
- <el-button type="primary"
|
|
|
- size="small"
|
|
|
- icon="el-icon-plus"
|
|
|
- @click="addbtnfun()">新增费用模板
|
|
|
- </el-button>
|
|
|
- <el-button type="danger"
|
|
|
- size="small"
|
|
|
- icon="el-icon-delete"
|
|
|
- plain
|
|
|
- @click="handleDelete">删 除
|
|
|
- </el-button>
|
|
|
- </template>
|
|
|
- <template slot-scope="scope" slot="menu">
|
|
|
- <el-button
|
|
|
- :type="scope.type"
|
|
|
- :size="scope.size"
|
|
|
- icon="el-icon-edit"
|
|
|
- @click.stop="rowCellfun(scope.row, scope.index)"
|
|
|
- >编辑
|
|
|
- </el-button>
|
|
|
- <el-button
|
|
|
- :type="scope.type"
|
|
|
- :size="scope.size"
|
|
|
- icon="el-icon-delete"
|
|
|
- @click.stop="rowDel(scope.row, scope.index)"
|
|
|
- >删除
|
|
|
- </el-button>
|
|
|
- </template>
|
|
|
- <template slot="remarks" slot-scope="scope">
|
|
|
- <avue-text-ellipsis :text="scope.row.remarks" :height="30" use-tooltip placement="top">
|
|
|
- <small slot="more">...</small>
|
|
|
- </avue-text-ellipsis>
|
|
|
- </template>
|
|
|
+ <el-row v-if="isShow">
|
|
|
+ <el-col :span="5">
|
|
|
+ <div class="box">
|
|
|
+ <el-scrollbar>
|
|
|
+ <basic-container>
|
|
|
+ <avue-tree :option="treeOption" :data="feesTypeData" @node-click="nodeClick" >
|
|
|
+ <template slot="addBtn">
|
|
|
+ <el-tooltip class="item" effect="dark" content="新建分类" placement="top">
|
|
|
+ <i class="el-icon-setting" style="font-size:18px;line-height: 30px;width: 20px;padding: 0 10px;"
|
|
|
+ @click="corpTypeVisible = true"></i>
|
|
|
+ </el-tooltip>
|
|
|
+ </template>
|
|
|
+ </avue-tree>
|
|
|
+ </basic-container>
|
|
|
+ </el-scrollbar>
|
|
|
+ </div>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="19">
|
|
|
+ <basic-container>
|
|
|
+ <avue-crud :option="option"
|
|
|
+ :table-loading="loading"
|
|
|
+ :data="data"
|
|
|
+ :page.sync="page"
|
|
|
+ :search.sync="search"
|
|
|
+ :permission="permissionList"
|
|
|
+ id="out-table"
|
|
|
+ :header-cell-class-name="headerClassName"
|
|
|
+ :before-open="beforeOpen"
|
|
|
+ v-model="form"
|
|
|
+ ref="crud"
|
|
|
+ @row-update="rowUpdate"
|
|
|
+ @row-save="rowSave"
|
|
|
+ @row-del="rowDel"
|
|
|
+ @search-change="searchChange"
|
|
|
+ @search-reset="searchReset"
|
|
|
+ @selection-change="selectionChange"
|
|
|
+ @current-change="currentChange"
|
|
|
+ @size-change="sizeChange"
|
|
|
+ @refresh-change="refreshChange"
|
|
|
+ @resetColumn="resetColumnTwo('crud', 'option', 'optionBack', 303)"
|
|
|
+ @saveColumn="saveColumnTwo('crud', 'option', 'optionBack', 303)"
|
|
|
+ @on-load="onLoad">
|
|
|
+ <template slot="menuLeft">
|
|
|
+ <el-button type="primary"
|
|
|
+ size="small"
|
|
|
+ icon="el-icon-plus"
|
|
|
+ @click="addbtnfun()">新增费用模板
|
|
|
+ </el-button>
|
|
|
+ <el-button type="danger"
|
|
|
+ size="small"
|
|
|
+ icon="el-icon-delete"
|
|
|
+ plain
|
|
|
+ @click="handleDelete">删 除
|
|
|
+ </el-button>
|
|
|
+ </template>
|
|
|
+ <template slot-scope="scope" slot="menu">
|
|
|
+ <el-button
|
|
|
+ :type="scope.type"
|
|
|
+ :size="scope.size"
|
|
|
+ icon="el-icon-edit"
|
|
|
+ @click.stop="rowCellfun(scope.row, scope.index)"
|
|
|
+ >编辑
|
|
|
+ </el-button>
|
|
|
+ <el-button
|
|
|
+ :type="scope.type"
|
|
|
+ :size="scope.size"
|
|
|
+ icon="el-icon-delete"
|
|
|
+ @click.stop="rowDel(scope.row, scope.index)"
|
|
|
+ >删除
|
|
|
+ </el-button>
|
|
|
+ </template>
|
|
|
+ <template slot="remarks" slot-scope="scope">
|
|
|
+ <avue-text-ellipsis :text="scope.row.remarks" :height="30" use-tooltip placement="top">
|
|
|
+ <small slot="more">...</small>
|
|
|
+ </avue-text-ellipsis>
|
|
|
+ </template>
|
|
|
|
|
|
- </avue-crud>
|
|
|
- </basic-container>
|
|
|
+ </avue-crud>
|
|
|
+ </basic-container>
|
|
|
+ </el-col>
|
|
|
+ </el-row>
|
|
|
|
|
|
<fees-templateItems ref="feesTemplateItems" v-if="!isShow" :detailData="detailData" @goBack="goBack"></fees-templateItems>
|
|
|
</div>
|
|
@@ -70,11 +91,28 @@
|
|
|
import {losbfeestemplateList, losbfeestemplateDetail, losbfeestemplateSubmit, losbfeestemplateRemove} from "@/api/iosBasicData/losbfeestemplate.js";
|
|
|
import {mapGetters} from "vuex";
|
|
|
import feesTemplateItems from "@/views/iosBasicData/losbfeestemplate/feesTemplateItems.vue";
|
|
|
+ import {bbusinesstypeList} from "@/api/iosBasicData/bbusinesstype";
|
|
|
|
|
|
export default {
|
|
|
components:{ feesTemplateItems},
|
|
|
data() {
|
|
|
return {
|
|
|
+ treeOption: {
|
|
|
+ nodeKey: "id",
|
|
|
+ // lazy: true,
|
|
|
+ addBtn: false,
|
|
|
+ menu: false,
|
|
|
+ size: "small",
|
|
|
+ props: {
|
|
|
+ labelText: "标题",
|
|
|
+ label: "cnName",
|
|
|
+ value: "value",
|
|
|
+ children: "children"
|
|
|
+ }
|
|
|
+ },
|
|
|
+ feesTypeData:[],
|
|
|
+ corpTypeVisible:false,
|
|
|
+
|
|
|
// 详情传递的数据
|
|
|
detailData:{},
|
|
|
isShow:true,
|
|
@@ -87,6 +125,7 @@
|
|
|
currentPage: 1,
|
|
|
total: 0
|
|
|
},
|
|
|
+ search:{},
|
|
|
selectionList: [],
|
|
|
option:{},
|
|
|
optionBack: {
|
|
@@ -206,6 +245,15 @@
|
|
|
hide:true,
|
|
|
display:false,
|
|
|
},
|
|
|
+ {
|
|
|
+ label: "备注",
|
|
|
+ prop: "remarks",
|
|
|
+ span:24,
|
|
|
+ type: 'textarea',
|
|
|
+ width: "180",
|
|
|
+ slot: true,
|
|
|
+ minRows: 3,
|
|
|
+ },
|
|
|
{
|
|
|
label: "状态",
|
|
|
prop: "status",
|
|
@@ -280,15 +328,7 @@
|
|
|
width: 160,
|
|
|
display:false,
|
|
|
},
|
|
|
- {
|
|
|
- label: "备注",
|
|
|
- prop: "remarks",
|
|
|
- span:24,
|
|
|
- type: 'textarea',
|
|
|
- width: "180",
|
|
|
- slot: true,
|
|
|
- minRows: 3,
|
|
|
- },
|
|
|
+
|
|
|
]
|
|
|
},
|
|
|
data: []
|
|
@@ -314,8 +354,15 @@
|
|
|
},
|
|
|
async created() {
|
|
|
this.option = await this.getColumnData(this.getColumnName(303), this.optionBack);
|
|
|
+ this.bbusinesstypeListfun()
|
|
|
},
|
|
|
methods: {
|
|
|
+ // 获取左侧业务类别数据
|
|
|
+ bbusinesstypeListfun(){
|
|
|
+ bbusinesstypeList().then(res=>{
|
|
|
+ this.feesTypeData = res.data.data.records
|
|
|
+ })
|
|
|
+ },
|
|
|
// 详情的返回列表
|
|
|
goBack(){
|
|
|
// 初始化数据
|
|
@@ -329,12 +376,31 @@
|
|
|
this.isShow = true;
|
|
|
this.onLoad(this.page, this.search);
|
|
|
},
|
|
|
+ // 左侧筛选
|
|
|
+ nodeClick(data) {
|
|
|
+ console.log(data,331)
|
|
|
+ this.search.businessTypeId = data.id
|
|
|
+ this.detailData.businessTypeId = data.id
|
|
|
+ this.detailData.businessTypeCnName = data.cnName
|
|
|
+ this.detailData.businessTypeEnName = data.enName
|
|
|
+ this.onLoad(this.page,this.search);
|
|
|
+ },
|
|
|
// 添加弹窗开启
|
|
|
addbtnfun(){
|
|
|
- this.detailData = {
|
|
|
- seeDisabled: false,
|
|
|
- };
|
|
|
+ if (!this.detailData.businessTypeId) {
|
|
|
+ this.$message({
|
|
|
+ type: "warning",
|
|
|
+ message: "请先选择业务类型!"
|
|
|
+ });
|
|
|
+ return
|
|
|
+ }
|
|
|
+ this.detailData.seeDisabled = false
|
|
|
this.isShow = false
|
|
|
+ this.$nextTick(()=>{
|
|
|
+ this.$refs.feesTemplateItems.form.businessTypeId = this.detailData.businessTypeId
|
|
|
+ this.$refs.feesTemplateItems.form.businessTypeCnName = this.detailData.businessTypeCnName
|
|
|
+ this.$refs.feesTemplateItems.form.businessTypeEnName = this.detailData.businessTypeEnName
|
|
|
+ })
|
|
|
},
|
|
|
// 编辑详情打开
|
|
|
rowCellfun(row,index){
|
|
@@ -506,4 +572,7 @@
|
|
|
::v-deep#out-table .back-two {
|
|
|
background: #ecf5ff !important;
|
|
|
}
|
|
|
+::v-deep .el-input-group__append {
|
|
|
+ padding: 0 0px !important;
|
|
|
+}
|
|
|
</style>
|