| | |
| | | /* * @Author: Morpheus * @Date: 2021-07-05 16:31:54 * @Last Modified by: liu * |
| | | @Last Modified time: 2021-11-23 14:14:38 * menu-name 题库查询 */ |
| | | @Last Modified time: 2021-11-23 14:14:38 * menu-name 物业评定题库查询 */ |
| | | <template> |
| | | <basic-container :class=""> |
| | | <avue-crud class="company-box tablesss" :option="questionBankOption" :search.sync="questionBankSearch" |
| | |
| | | </template> |
| | | </avue-crud> |
| | | |
| | | <el-dialog title="题库导入" append-to-body :visible.sync="excelBox" width="555px"> |
| | | <!-- <el-dialog title="题库导入" append-to-body :visible.sync="excelBox" width="555px"> |
| | | <avue-form :option="excelOption" v-model="excelForm" :upload-after="uploadAfter"> |
| | | <template slot="excelTemplate"> |
| | | <el-button type="primary" @click="handleTemplate"> |
| | |
| | | </el-button> |
| | | </template> |
| | | </avue-form> |
| | | </el-dialog> |
| | | </el-dialog> --> |
| | | <addsubject ref="addsubject" v-on:refreshPage="refreshPage"></addsubject> |
| | | </basic-container> |
| | | </template> |
| | |
| | | <!-- 走访日志 --> |
| | | <template> |
| | | <basic-container> |
| | | <avue-crud :option="option" :table-loading="loading" :data="data" :page.sync="page" ref="crud" v-model="form" |
| | | :permission="permissionList" @search-change="searchChange" @row-save="rowSave" @row-update="rowUpdate" |
| | | @row-del="rowDel" :before-open="beforeOpen" @search-reset="searchReset" @selection-change="selectionChange" |
| | | @current-change="currentChange" @size-change="sizeChange" @refresh-change="refreshChange" @on-load="onLoad"> |
| | | <template slot-scope="scope" slot="menu"> |
| | | <el-button type="text" icon="el-icon-circle-plus-outline" size="small" |
| | | @click="manageMember(scope.row)">业委会成员 |
| | | </el-button> |
| | | </template> |
| | | <basic-container> |
| | | <avue-crud :option="option" :table-loading="loading" :data="data" :page.sync="page" ref="crud" v-model="form" |
| | | :permission="permissionList" @search-change="searchChange" @row-save="rowSave" @row-update="rowUpdate" |
| | | @row-del="rowDel" :before-open="beforeOpen" @search-reset="searchReset" @selection-change="selectionChange" |
| | | @current-change="currentChange" @size-change="sizeChange" @refresh-change="refreshChange" @on-load="onLoad"> |
| | | <template slot-scope="scope" slot="menu"> |
| | | <el-button type="text" icon="el-icon-circle-plus-outline" size="small" @click="manageMember(scope.row)">业委会成员 |
| | | </el-button> |
| | | </template> |
| | | |
| | | <template slot-scope="{ row, size }" slot="status"> |
| | | <el-tag :size="size" :type="showStatus(row.status).type" v-text="showStatus(row.status).text"> |
| | | </el-tag> |
| | | </template> |
| | | </avue-crud> |
| | | <template slot-scope="{ row, size }" slot="status"> |
| | | <el-tag :size="size" :type="showStatus(row.status).type" v-text="showStatus(row.status).text"> |
| | | </el-tag> |
| | | </template> |
| | | </avue-crud> |
| | | |
| | | <el-drawer title="业委会成员" size="40%" append-to-body :visible.sync="memberFlag" :direction="'rtl'"> |
| | | <ownersMemberManager ref="ownersMemberManager" /> |
| | | </el-drawer> |
| | | </basic-container> |
| | | <el-drawer title="业委会成员" size="40%" append-to-body :visible.sync="memberFlag" :direction="'rtl'"> |
| | | <ownersMemberManager ref="ownersMemberManager" /> |
| | | </el-drawer> |
| | | </basic-container> |
| | | </template> |
| | | |
| | | <script> |
| | | import { |
| | | import { |
| | | getList, |
| | | add, |
| | | update, |
| | | remove, |
| | | getDetatil |
| | | } from "@/api/owners_committee" |
| | | import { |
| | | } from "@/api/owners_committee" |
| | | import { |
| | | mapGetters |
| | | } from "vuex" |
| | | import website from '@/config/website' |
| | | import func from "@/util/func" |
| | | import ownersMemberManager from "./components/ownersMemberManager" |
| | | } from "vuex" |
| | | import website from '@/config/website' |
| | | import func from "@/util/func" |
| | | import ownersMemberManager from "./components/ownersMemberManager" |
| | | |
| | | export default { |
| | | export default { |
| | | components: { |
| | | ownersMemberManager |
| | | ownersMemberManager |
| | | }, |
| | | data () { |
| | | return { |
| | | form: {}, |
| | | query: {}, |
| | | loading: true, |
| | | page: { |
| | | pageSize: 10, |
| | | currentPage: 1, |
| | | total: 0, |
| | | data() { |
| | | return { |
| | | form: {}, |
| | | query: {}, |
| | | loading: true, |
| | | page: { |
| | | pageSize: 10, |
| | | currentPage: 1, |
| | | total: 0, |
| | | }, |
| | | datetime: "", |
| | | selectionList: [], |
| | | memberFlag: false, |
| | | option: { |
| | | labelWidth: 120, |
| | | searchLabelWidth: 96, |
| | | searchShow: true, |
| | | searchMenuSpan: 3, |
| | | menuWidth: 300, |
| | | |
| | | // menu: false, |
| | | // addBtn: false, |
| | | border: true, |
| | | index: true, |
| | | selection: false, |
| | | height: "auto", |
| | | calcHeight: 54, |
| | | dialogWidth: 950, |
| | | tip: false, |
| | | //stripe:true, |
| | | viewBtn: true, |
| | | excelBtn: true, |
| | | dialogClickModal: false, |
| | | column: [{ |
| | | hide: true, |
| | | label: "小区", |
| | | prop: "areaId", |
| | | searchSpan: 5, |
| | | type: 'tree', |
| | | dicUrl: `/api/blade-district/district/getDistrictTree`, |
| | | props: { |
| | | label: "name", |
| | | value: "id" |
| | | }, |
| | | defaultExpandedKeys: ["361102003"], |
| | | cascader: ['principalId'], |
| | | overHidden: true, |
| | | change: ({ |
| | | value, |
| | | column, |
| | | item, |
| | | dic |
| | | }) => { |
| | | this.form.areaName = '' |
| | | |
| | | if (value) { |
| | | this.form.areaName = item.name |
| | | } |
| | | }, |
| | | rules: [{ |
| | | required: true, |
| | | message: "请选择小区", |
| | | trigger: "blur", |
| | | }, ], |
| | | }, |
| | | datetime: "", |
| | | selectionList: [], |
| | | memberFlag: false, |
| | | option: { |
| | | labelWidth: 120, |
| | | searchLabelWidth: 96, |
| | | searchShow: true, |
| | | searchMenuSpan: 3, |
| | | menuWidth: 300, |
| | | |
| | | // menu: false, |
| | | // addBtn: false, |
| | | border: true, |
| | | index: true, |
| | | selection: false, |
| | | height: "auto", |
| | | calcHeight: 54, |
| | | dialogWidth: 950, |
| | | tip: false, |
| | | //stripe:true, |
| | | viewBtn: true, |
| | | excelBtn: true, |
| | | dialogClickModal: false, |
| | | column: [ |
| | | { |
| | | hide: true, |
| | | label: "小区", |
| | | prop: "areaId", |
| | | searchSpan: 5, |
| | | type: 'tree', |
| | | dicUrl: `/api/blade-district/district/getDistrictTree`, |
| | | props: { |
| | | label: "name", |
| | | value: "id" |
| | | }, |
| | | defaultExpandedKeys: ["361102003"], |
| | | cascader: ['principalId'], |
| | | overHidden: true, |
| | | change: ({ |
| | | value, |
| | | column, |
| | | item, |
| | | dic |
| | | }) => { |
| | | this.form.areaName = '' |
| | | |
| | | if (value) { |
| | | this.form.areaName = item.name |
| | | } |
| | | }, |
| | | rules: [{ |
| | | required: true, |
| | | message: "请选择小区", |
| | | trigger: "blur", |
| | | },], |
| | | }, |
| | | |
| | | { |
| | | overHidden: true, |
| | | width: 120, |
| | | label: "业委会名称", |
| | | prop: "name", |
| | | search: true, |
| | | searchLabelWidth: 90, |
| | | rules: [{ |
| | | required: true, |
| | | message: "请输入业委会名称", |
| | | trigger: "blur", |
| | | },], |
| | | }, |
| | | |
| | | { |
| | | overHidden: true, |
| | | width: 220, |
| | | label: '小区名称', |
| | | addDisplay: false, |
| | | editDisplay: false, |
| | | viewDisplay: false, |
| | | prop: "areaName" |
| | | }, |
| | | |
| | | { |
| | | label: "总人数", |
| | | prop: "peopleTotal", |
| | | display: false, |
| | | }, |
| | | { |
| | | label: "业委会负责人", |
| | | prop: "principalId", |
| | | type: "tree", |
| | | remote: true, |
| | | props: { |
| | | label: 'name', |
| | | value: 'id' |
| | | }, |
| | | hide: true, |
| | | dicUrl: `/api/blade-system/user/searchUserByDistrictId?districtId={{key}}`, |
| | | defaultExpandedKeys: [], |
| | | change: ({ |
| | | value, |
| | | column, |
| | | item, |
| | | dic |
| | | }) => { |
| | | this.form.mobile = '' |
| | | this.form.principalName = '' |
| | | |
| | | if (value) { |
| | | this.form.mobile = item.phone |
| | | this.form.principalName = item.name |
| | | } |
| | | }, |
| | | rules: [{ |
| | | required: true, |
| | | message: "请选择业委会负责人", |
| | | trigger: "blur", |
| | | },], |
| | | }, |
| | | { |
| | | width: 120, |
| | | label: "负责人名称", |
| | | prop: "principalName", |
| | | display: false, |
| | | rules: [{ |
| | | required: true, |
| | | message: "请输入负责人名称", |
| | | trigger: "blur", |
| | | },], |
| | | }, |
| | | { |
| | | width: 120, |
| | | label: "负责人手机号", |
| | | prop: "mobile", |
| | | rules: [{ |
| | | required: true, |
| | | message: "请输入负责人手机号", |
| | | trigger: "blur", |
| | | },], |
| | | }, |
| | | |
| | | { |
| | | width: 120, |
| | | label: "业委会届别", |
| | | prop: "session", |
| | | type: "number", |
| | | rules: [{ |
| | | required: true, |
| | | message: "请输入业委会届别", |
| | | trigger: "blur", |
| | | },], |
| | | }, |
| | | |
| | | { |
| | | width: 100, |
| | | label: "成立时间", |
| | | prop: "establishTime", |
| | | type: "date", |
| | | format: "yyyy-MM-dd", |
| | | valueFormat: "yyyy-MM-dd", |
| | | }, |
| | | |
| | | { |
| | | span: 24, |
| | | label: "所在地址", |
| | | prop: "location", |
| | | }, |
| | | |
| | | { |
| | | width: 124, |
| | | label: "任期开始时间", |
| | | prop: "startTime", |
| | | type: "date", |
| | | format: "yyyy-MM-dd", |
| | | valueFormat: "yyyy-MM-dd", |
| | | rules: [{ |
| | | required: true, |
| | | message: "请输入任期开始时间", |
| | | trigger: "blur", |
| | | },], |
| | | }, |
| | | |
| | | { |
| | | width: 124, |
| | | label: "任期结束时间", |
| | | prop: "endTime", |
| | | type: "date", |
| | | format: "yyyy-MM-dd", |
| | | valueFormat: "yyyy-MM-dd", |
| | | rules: [{ |
| | | required: true, |
| | | message: "请输入任期结束时间", |
| | | trigger: "blur", |
| | | },], |
| | | }, |
| | | |
| | | { |
| | | width: 110, |
| | | label: "图片", |
| | | prop: "imageUrl", |
| | | type: "upload", |
| | | listType: "picture-img", |
| | | action: "/api/blade-resource/oss/endpoint/put-file", |
| | | propsHttp: { |
| | | res: "data", |
| | | name: 'name', |
| | | url: "link", |
| | | }, |
| | | viewDisplay: false, |
| | | span: 24, |
| | | }, |
| | | |
| | | { |
| | | span: 12, |
| | | label: "排序", |
| | | prop: "sort", |
| | | type: 'number', |
| | | rules: [{ |
| | | required: true, |
| | | message: "请输入排序", |
| | | trigger: "blur", |
| | | },], |
| | | }, |
| | | |
| | | { |
| | | width: 100, |
| | | span: 12, |
| | | label: "状态", |
| | | slot: true, |
| | | prop: "status", |
| | | type: 'switch', |
| | | activeColor: "#13ce66", |
| | | inactiveColor: "#ccc", |
| | | dicData: [ |
| | | { |
| | | label: "关闭", |
| | | value: 1 |
| | | }, |
| | | { |
| | | label: "正常", |
| | | value: 0 |
| | | }, |
| | | ], |
| | | rules: [{ |
| | | required: true, |
| | | message: "请输入排序", |
| | | trigger: "blur", |
| | | },], |
| | | }, |
| | | |
| | | { |
| | | span: 20, |
| | | label: "简介", |
| | | prop: "profile", |
| | | component: "AvueUeditor", |
| | | options: { |
| | | action: "/api/blade-resource/oss/endpoint/put-file", |
| | | props: { |
| | | res: "data", |
| | | url: "link", |
| | | }, |
| | | }, |
| | | hide: true, |
| | | minRows: 6, |
| | | }, |
| | | |
| | | // { |
| | | // label: "简介", |
| | | // prop: "profile", |
| | | // viewDisplay: false, |
| | | // type: "textarea" |
| | | // }, |
| | | |
| | | ], |
| | | { |
| | | overHidden: true, |
| | | width: 120, |
| | | label: "业委会名称", |
| | | prop: "name", |
| | | search: true, |
| | | searchLabelWidth: 90, |
| | | rules: [{ |
| | | required: true, |
| | | message: "请输入业委会名称", |
| | | trigger: "blur", |
| | | }, ], |
| | | }, |
| | | data: [], |
| | | } |
| | | |
| | | { |
| | | overHidden: true, |
| | | width: 220, |
| | | label: '小区名称', |
| | | addDisplay: false, |
| | | editDisplay: false, |
| | | viewDisplay: false, |
| | | prop: "areaName" |
| | | }, |
| | | |
| | | { |
| | | label: "总人数", |
| | | prop: "peopleTotal", |
| | | display: false, |
| | | }, |
| | | { |
| | | label: "业委会负责人", |
| | | prop: "principalId", |
| | | type: "tree", |
| | | remote: true, |
| | | props: { |
| | | label: 'name', |
| | | value: 'id' |
| | | }, |
| | | hide: true, |
| | | dicUrl: `/api/blade-system/user/searchUserByDistrictId?districtId={{key}}`, |
| | | defaultExpandedKeys: [], |
| | | change: ({ |
| | | value, |
| | | column, |
| | | item, |
| | | dic |
| | | }) => { |
| | | this.form.mobile = '' |
| | | this.form.principalName = '' |
| | | |
| | | if (value) { |
| | | this.form.mobile = item.phone |
| | | this.form.principalName = item.name |
| | | } |
| | | }, |
| | | rules: [{ |
| | | required: true, |
| | | message: "请选择业委会负责人", |
| | | trigger: "blur", |
| | | }, ], |
| | | }, |
| | | { |
| | | width: 120, |
| | | label: "负责人名称", |
| | | prop: "principalName", |
| | | display: false, |
| | | rules: [{ |
| | | required: true, |
| | | message: "请输入负责人名称", |
| | | trigger: "blur", |
| | | }, ], |
| | | }, |
| | | { |
| | | width: 120, |
| | | label: "负责人手机号", |
| | | prop: "mobile", |
| | | rules: [{ |
| | | required: true, |
| | | message: "请输入负责人手机号", |
| | | trigger: "blur", |
| | | }, ], |
| | | }, |
| | | |
| | | { |
| | | width: 120, |
| | | label: "业委会届别", |
| | | prop: "session", |
| | | type: "number", |
| | | rules: [{ |
| | | required: true, |
| | | message: "请输入业委会届别", |
| | | trigger: "blur", |
| | | }, ], |
| | | value: 1 |
| | | }, |
| | | |
| | | { |
| | | width: 100, |
| | | label: "成立时间", |
| | | prop: "establishTime", |
| | | type: "date", |
| | | format: "yyyy-MM-dd", |
| | | valueFormat: "yyyy-MM-dd", |
| | | }, |
| | | |
| | | { |
| | | span: 24, |
| | | label: "所在地址", |
| | | prop: "location", |
| | | }, |
| | | |
| | | { |
| | | width: 124, |
| | | label: "任期开始时间", |
| | | prop: "startTime", |
| | | type: "date", |
| | | format: "yyyy-MM-dd", |
| | | valueFormat: "yyyy-MM-dd", |
| | | rules: [{ |
| | | required: true, |
| | | message: "请输入任期开始时间", |
| | | trigger: "blur", |
| | | }, ], |
| | | }, |
| | | |
| | | { |
| | | width: 124, |
| | | label: "任期结束时间", |
| | | prop: "endTime", |
| | | type: "date", |
| | | format: "yyyy-MM-dd", |
| | | valueFormat: "yyyy-MM-dd", |
| | | rules: [{ |
| | | required: true, |
| | | message: "请输入任期结束时间", |
| | | trigger: "blur", |
| | | }, ], |
| | | }, |
| | | |
| | | { |
| | | width: 110, |
| | | label: "图片", |
| | | prop: "imageUrl", |
| | | type: "upload", |
| | | listType: "picture-img", |
| | | action: "/api/blade-resource/oss/endpoint/put-file", |
| | | propsHttp: { |
| | | res: "data", |
| | | name: 'name', |
| | | url: "link", |
| | | }, |
| | | viewDisplay: false, |
| | | span: 24, |
| | | }, |
| | | |
| | | { |
| | | span: 12, |
| | | label: "排序", |
| | | prop: "sort", |
| | | type: 'number', |
| | | rules: [{ |
| | | required: true, |
| | | message: "请输入排序", |
| | | trigger: "blur", |
| | | }, ], |
| | | value: 1 |
| | | }, |
| | | |
| | | { |
| | | width: 100, |
| | | span: 12, |
| | | label: "状态", |
| | | slot: true, |
| | | prop: "status", |
| | | type: 'switch', |
| | | activeColor: "#13ce66", |
| | | inactiveColor: "#ccc", |
| | | dicData: [{ |
| | | label: "关闭", |
| | | value: 1 |
| | | }, |
| | | { |
| | | label: "正常", |
| | | value: 0 |
| | | }, |
| | | ], |
| | | value: 0, |
| | | rules: [{ |
| | | required: true, |
| | | message: "请输入排序", |
| | | trigger: "blur", |
| | | }, ], |
| | | }, |
| | | |
| | | { |
| | | span: 20, |
| | | label: "简介", |
| | | prop: "profile", |
| | | component: "AvueUeditor", |
| | | options: { |
| | | action: "/api/blade-resource/oss/endpoint/put-file", |
| | | props: { |
| | | res: "data", |
| | | url: "link", |
| | | }, |
| | | }, |
| | | hide: true, |
| | | minRows: 6, |
| | | }, |
| | | |
| | | // { |
| | | // label: "简介", |
| | | // prop: "profile", |
| | | // viewDisplay: false, |
| | | // type: "textarea" |
| | | // }, |
| | | |
| | | ], |
| | | }, |
| | | data: [], |
| | | } |
| | | }, |
| | | watch: {}, |
| | | computed: { |
| | | ...mapGetters(["permission", "userInfo"]), |
| | | permissionList () { |
| | | return { |
| | | addBtn: this.vaildData(this.permission.gridWorkLog_add, true), |
| | | viewBtn: this.vaildData(this.permission.gridWorkLog_view, true), |
| | | delBtn: this.vaildData(this.permission.gridWorkLog_delete, true), |
| | | editBtn: this.vaildData(this.permission.gridWorkLog_edit, true), |
| | | } |
| | | }, |
| | | ids () { |
| | | let ids = [] |
| | | this.selectionList.forEach((ele) => { |
| | | ids.push(ele.id) |
| | | }) |
| | | return ids.join(",") |
| | | }, |
| | | showStatus () { |
| | | return (data) => { |
| | | if (data == 0) { |
| | | return { |
| | | text: '正常', |
| | | type: 'success' |
| | | } |
| | | } else { |
| | | return { |
| | | text: '关闭', |
| | | type: 'info' |
| | | } |
| | | } |
| | | } |
| | | ...mapGetters(["permission", "userInfo"]), |
| | | permissionList() { |
| | | return { |
| | | addBtn: this.vaildData(this.permission.gridWorkLog_add, true), |
| | | viewBtn: this.vaildData(this.permission.gridWorkLog_view, true), |
| | | delBtn: this.vaildData(this.permission.gridWorkLog_delete, true), |
| | | editBtn: this.vaildData(this.permission.gridWorkLog_edit, true), |
| | | } |
| | | }, |
| | | ids() { |
| | | let ids = [] |
| | | this.selectionList.forEach((ele) => { |
| | | ids.push(ele.id) |
| | | }) |
| | | return ids.join(",") |
| | | }, |
| | | showStatus() { |
| | | return (data) => { |
| | | if (data == 0) { |
| | | return { |
| | | text: '正常', |
| | | type: 'success' |
| | | } |
| | | } else { |
| | | return { |
| | | text: '关闭', |
| | | type: 'info' |
| | | } |
| | | } |
| | | } |
| | | } |
| | | }, |
| | | methods: { |
| | | manageMember (row) { |
| | | this.memberFlag = true |
| | | var that = this |
| | | this.$nextTick(() => { |
| | | that.$refs.ownersMemberManager.init(row) |
| | | }) |
| | | }, |
| | | rowSave (row, done, loading) { |
| | | row.imageUrl = func.join(row.imageUrl) |
| | | if (row.imageUrl.length > 0) { |
| | | var urls = [] |
| | | var split = row.imageUrl.split(",") |
| | | split.forEach(url => { |
| | | var names = url.split("jczz/") |
| | | urls.push(names[1]) |
| | | }) |
| | | row.imageUrl = urls.join(",") |
| | | } |
| | | row.propertyFlag = 1 |
| | | add(row).then( |
| | | () => { |
| | | this.onLoad(this.page) |
| | | this.$message({ |
| | | type: "success", |
| | | message: "操作成功!", |
| | | }) |
| | | done() |
| | | }, |
| | | (error) => { |
| | | window.console.log(error) |
| | | loading() |
| | | } |
| | | ) |
| | | }, |
| | | rowUpdate (row, index, done, loading) { |
| | | if (row.imageUrl.length > 0) { |
| | | var urls = [] |
| | | var split = row.imageUrl.split(",") |
| | | split.forEach(url => { |
| | | var names = url.split("jczz/") |
| | | urls.push(names[1]) |
| | | }) |
| | | row.imageUrl = urls.join(",") |
| | | } |
| | | update(row).then( |
| | | () => { |
| | | this.onLoad(this.page) |
| | | this.$message({ |
| | | type: "success", |
| | | message: "操作成功!", |
| | | }) |
| | | done() |
| | | }, |
| | | (error) => { |
| | | window.console.log(error) |
| | | loading() |
| | | } |
| | | ) |
| | | }, |
| | | rowDel (row) { |
| | | this.$confirm("确定将选择数据删除?", { |
| | | confirmButtonText: "确定", |
| | | cancelButtonText: "取消", |
| | | type: "warning", |
| | | }) |
| | | .then(() => { |
| | | return remove(row.id) |
| | | }) |
| | | .then(() => { |
| | | this.onLoad(this.page) |
| | | this.$message({ |
| | | type: "success", |
| | | message: "操作成功!", |
| | | }) |
| | | }) |
| | | }, |
| | | // handleDelete() { |
| | | // if (this.selectionList.length === 0) { |
| | | // this.$message.warning("请选择至少一条数据"); |
| | | // return; |
| | | // } |
| | | // this.$confirm("确定将选择数据删除?", { |
| | | // confirmButtonText: "确定", |
| | | // cancelButtonText: "取消", |
| | | // type: "warning", |
| | | // }) |
| | | // .then(() => { |
| | | // return remove(this.ids); |
| | | // }) |
| | | // .then(() => { |
| | | // this.onLoad(this.page); |
| | | // this.$message({ |
| | | // type: "success", |
| | | // message: "操作成功!", |
| | | // }); |
| | | // this.$refs.crud.toggleSelection(); |
| | | // }); |
| | | // }, |
| | | beforeOpen (done, type) { |
| | | if (["edit", "view"].includes(type)) { |
| | | getDetatil(this.form.id).then((res) => { |
| | | this.form = res.data.data |
| | | this.form.propertyFlag = 1 |
| | | if (this.form.constructionSchemeUrls.length > 0) { |
| | | var urls = [] |
| | | var names = this.form.constructionSchemeUrls.split(",") |
| | | names.forEach(name => { |
| | | urls.push(website.minioUrl + name) |
| | | }) |
| | | this.form.constructionSchemeUrls = urls.join(",") |
| | | const column = this.findObject(this.option.column, "principalId") |
| | | let arr = [] |
| | | arr.push(this.form.areaId) |
| | | column.defaultExpandedKeys = arr |
| | | } |
| | | }) |
| | | } |
| | | // con |
| | | done() |
| | | }, |
| | | searchReset () { |
| | | this.query = {} |
| | | this.onLoad(this.page) |
| | | }, |
| | | searchChange (params, done) { |
| | | this.query = params |
| | | this.page.currentPage = 1 |
| | | this.onLoad(this.page, params) |
| | | done() |
| | | }, |
| | | selectionChange (list) { |
| | | this.selectionList = list |
| | | }, |
| | | selectionClear () { |
| | | this.selectionList = [] |
| | | this.$refs.crud.toggleSelection() |
| | | }, |
| | | |
| | | currentChange (currentPage) { |
| | | this.page.currentPage = currentPage |
| | | }, |
| | | sizeChange (pageSize) { |
| | | this.page.pageSize = pageSize |
| | | }, |
| | | refreshChange () { |
| | | this.onLoad(this.page, this.query) |
| | | }, |
| | | onLoad (page, params = {}) { |
| | | this.loading = true |
| | | |
| | | getList(page.currentPage, page.pageSize, Object.assign(params, this.query)).then(res => { |
| | | const data = res.data.data |
| | | this.page.total = data.total |
| | | this.data = data.records.map(item => { |
| | | if (item.imageUrl && item.imageUrl.length > 0) { |
| | | var urls = [] |
| | | var names = item.imageUrl.split(",") |
| | | names.forEach(name => { |
| | | urls.push(website.minioUrl + name) |
| | | }) |
| | | item.imageUrl = urls.join(",") |
| | | } |
| | | |
| | | return item |
| | | }) |
| | | |
| | | this.loading = false |
| | | this.selectionClear() |
| | | }) |
| | | manageMember(row) { |
| | | this.memberFlag = true |
| | | var that = this |
| | | this.$nextTick(() => { |
| | | that.$refs.ownersMemberManager.init(row) |
| | | }) |
| | | }, |
| | | rowSave(row, done, loading) { |
| | | row.imageUrl = func.join(row.imageUrl) |
| | | if (row.imageUrl.length > 0) { |
| | | var urls = [] |
| | | var split = row.imageUrl.split(",") |
| | | split.forEach(url => { |
| | | var names = url.split("jczz/") |
| | | urls.push(names[1]) |
| | | }) |
| | | row.imageUrl = urls.join(",") |
| | | } |
| | | row.propertyFlag = 1 |
| | | add(row).then( |
| | | () => { |
| | | this.onLoad(this.page) |
| | | this.$message({ |
| | | type: "success", |
| | | message: "操作成功!", |
| | | }) |
| | | done() |
| | | }, |
| | | (error) => { |
| | | window.console.log(error) |
| | | loading() |
| | | } |
| | | ) |
| | | }, |
| | | rowUpdate(row, index, done, loading) { |
| | | if (row.imageUrl.length > 0) { |
| | | var urls = [] |
| | | var split = row.imageUrl.split(",") |
| | | split.forEach(url => { |
| | | var names = url.split("jczz/") |
| | | urls.push(names[1]) |
| | | }) |
| | | row.imageUrl = urls.join(",") |
| | | } |
| | | update(row).then( |
| | | () => { |
| | | this.onLoad(this.page) |
| | | this.$message({ |
| | | type: "success", |
| | | message: "操作成功!", |
| | | }) |
| | | done() |
| | | }, |
| | | (error) => { |
| | | window.console.log(error) |
| | | loading() |
| | | } |
| | | ) |
| | | }, |
| | | rowDel(row) { |
| | | this.$confirm("确定将选择数据删除?", { |
| | | confirmButtonText: "确定", |
| | | cancelButtonText: "取消", |
| | | type: "warning", |
| | | }) |
| | | .then(() => { |
| | | return remove(row.id) |
| | | }) |
| | | .then(() => { |
| | | this.onLoad(this.page) |
| | | this.$message({ |
| | | type: "success", |
| | | message: "操作成功!", |
| | | }) |
| | | }) |
| | | }, |
| | | // handleDelete() { |
| | | // if (this.selectionList.length === 0) { |
| | | // this.$message.warning("请选择至少一条数据"); |
| | | // return; |
| | | // } |
| | | // this.$confirm("确定将选择数据删除?", { |
| | | // confirmButtonText: "确定", |
| | | // cancelButtonText: "取消", |
| | | // type: "warning", |
| | | // }) |
| | | // .then(() => { |
| | | // return remove(this.ids); |
| | | // }) |
| | | // .then(() => { |
| | | // this.onLoad(this.page); |
| | | // this.$message({ |
| | | // type: "success", |
| | | // message: "操作成功!", |
| | | // }); |
| | | // this.$refs.crud.toggleSelection(); |
| | | // }); |
| | | // }, |
| | | beforeOpen(done, type) { |
| | | if (["edit", "view"].includes(type)) { |
| | | getDetatil(this.form.id).then((res) => { |
| | | this.form = res.data.data |
| | | this.form.propertyFlag = 1 |
| | | if (this.form.constructionSchemeUrls.length > 0) { |
| | | var urls = [] |
| | | var names = this.form.constructionSchemeUrls.split(",") |
| | | names.forEach(name => { |
| | | urls.push(website.minioUrl + name) |
| | | }) |
| | | this.form.constructionSchemeUrls = urls.join(",") |
| | | const column = this.findObject(this.option.column, "principalId") |
| | | let arr = [] |
| | | arr.push(this.form.areaId) |
| | | column.defaultExpandedKeys = arr |
| | | } |
| | | }) |
| | | } |
| | | // con |
| | | done() |
| | | }, |
| | | searchReset() { |
| | | this.query = {} |
| | | this.onLoad(this.page) |
| | | }, |
| | | searchChange(params, done) { |
| | | this.query = params |
| | | this.page.currentPage = 1 |
| | | this.onLoad(this.page, params) |
| | | done() |
| | | }, |
| | | selectionChange(list) { |
| | | this.selectionList = list |
| | | }, |
| | | selectionClear() { |
| | | this.selectionList = [] |
| | | this.$refs.crud.toggleSelection() |
| | | }, |
| | | |
| | | currentChange(currentPage) { |
| | | this.page.currentPage = currentPage |
| | | }, |
| | | sizeChange(pageSize) { |
| | | this.page.pageSize = pageSize |
| | | }, |
| | | refreshChange() { |
| | | this.onLoad(this.page, this.query) |
| | | }, |
| | | onLoad(page, params = {}) { |
| | | this.loading = true |
| | | |
| | | getList(page.currentPage, page.pageSize, Object.assign(params, this.query)).then(res => { |
| | | const data = res.data.data |
| | | this.page.total = data.total |
| | | this.data = data.records.map(item => { |
| | | if (item.imageUrl && item.imageUrl.length > 0) { |
| | | var urls = [] |
| | | var names = item.imageUrl.split(",") |
| | | names.forEach(name => { |
| | | urls.push(website.minioUrl + name) |
| | | }) |
| | | item.imageUrl = urls.join(",") |
| | | } |
| | | |
| | | return item |
| | | }) |
| | | |
| | | this.loading = false |
| | | this.selectionClear() |
| | | }) |
| | | } |
| | | }, |
| | | } |
| | | } |
| | | </script> |
| | | |
| | | <style scoped> |
| | | .avue-upload__icon { |
| | | .avue-upload__icon { |
| | | line-height: 6; |
| | | } |
| | | } |
| | | </style> |
| | |
| | | // 保存按钮 |
| | | handleSubmit() { |
| | | // 保存基本信息 |
| | | // this.saveBasicInfo() |
| | | this.saveBasicInfo() |
| | | // 保持考试信息 |
| | | this.saveQuestionBank() |
| | | }, |
| | |
| | | <!-- 物业公司管理 --> |
| | | <template> |
| | | <basic-container> |
| | | <avue-crud :option="option" :table-loading="loading" :data="data" :page.sync="page" ref="crud" @row-del="rowDel" |
| | | v-model="form" :permission="permissionList" @row-update="rowUpdate" @row-save="rowSave" |
| | | :before-open="beforeOpen" @search-change="searchChange" @search-reset="searchReset" |
| | | @selection-change="selectionChange" @current-change="currentChange" @size-change="sizeChange" |
| | | @refresh-change="refreshChange" @on-load="onLoad"> |
| | | <template slot="menuLeft"> |
| | | <el-button size="small" icon="el-icon-delete" plain v-if="permission.propertyCompany_delete" |
| | | @click="handleDelete">删 除 |
| | | </el-button> |
| | | <basic-container> |
| | | <avue-crud :option="option" :table-loading="loading" :data="data" :page.sync="page" ref="crud" @row-del="rowDel" |
| | | v-model="form" :permission="permissionList" @row-update="rowUpdate" @row-save="rowSave" :before-open="beforeOpen" |
| | | @search-change="searchChange" @search-reset="searchReset" @selection-change="selectionChange" |
| | | @current-change="currentChange" @size-change="sizeChange" @refresh-change="refreshChange" @on-load="onLoad"> |
| | | <template slot="menuLeft"> |
| | | <el-button size="small" icon="el-icon-delete" plain v-if="permission.propertyCompany_delete" |
| | | @click="handleDelete">删 除 |
| | | </el-button> |
| | | |
| | | |
| | | </template> |
| | | </template> |
| | | |
| | | <template slot-scope="{row, size, index}" slot="menu"> |
| | | <el-button :size="size" v-if="permission.payInfo" type="text" icon="el-icon-circle-plus-outline" |
| | | @click="openPayConfig(row)">商户配置 |
| | | </el-button> |
| | | <template slot-scope="{row, size, index}" slot="menu"> |
| | | <el-button :size="size" v-if="permission.payInfo" type="text" icon="el-icon-circle-plus-outline" |
| | | @click="openPayConfig(row)">商户配置 |
| | | </el-button> |
| | | |
| | | <el-button :size="size" v-if="permission.property_evaluation" icon="el-icon-circle-plus-outline" type="text" |
| | | @click="addProperty(row)">物业评定 |
| | | </el-button> |
| | | </template> |
| | | </avue-crud> |
| | | <el-button :size="size" v-if="permission.property_evaluation" icon="el-icon-circle-plus-outline" type="text" |
| | | @click="addProperty(row)">物业评定 |
| | | </el-button> |
| | | </template> |
| | | </avue-crud> |
| | | |
| | | <el-dialog title="商户配置" append-to-body :visible.sync="payInfoVisible" top="10vh" width="70%"> |
| | | <el-tabs v-model="currentTab"> |
| | | <el-tab-pane label="微信商户配置" name="wxInfo"> |
| | | <avue-form ref="wxForm" :option="wxPayOption" v-model="wxPayForm" @submit="wxSubmit"> |
| | | </avue-form> |
| | | </el-tab-pane> |
| | | <el-tab-pane label="支付宝商户配置" name="second"> |
| | | <avue-form ref="aliForm" :option="aliPayOption" v-model="aliPayForm" @submit="aliSubmit"> |
| | | </avue-form> |
| | | </el-tab-pane> |
| | | <el-dialog title="商户配置" append-to-body :visible.sync="payInfoVisible" top="10vh" width="70%"> |
| | | <el-tabs v-model="currentTab"> |
| | | <el-tab-pane label="微信商户配置" name="wxInfo"> |
| | | <avue-form ref="wxForm" :option="wxPayOption" v-model="wxPayForm" @submit="wxSubmit"> |
| | | </avue-form> |
| | | </el-tab-pane> |
| | | <el-tab-pane label="支付宝商户配置" name="second"> |
| | | <avue-form ref="aliForm" :option="aliPayOption" v-model="aliPayForm" @submit="aliSubmit"> |
| | | </avue-form> |
| | | </el-tab-pane> |
| | | |
| | | </el-tabs> |
| | | </el-tabs> |
| | | |
| | | <!-- <div slot="footer" class="dialog-footer">--> |
| | | <!-- <el-button @click="payInfoVisible = false">取 消</el-button>--> |
| | | <!-- <el-button type="primary"@click="submit">提 交</el-button>--> |
| | | <!-- </div>--> |
| | | <!-- <div slot="footer" class="dialog-footer">--> |
| | | <!-- <el-button @click="payInfoVisible = false">取 消</el-button>--> |
| | | <!-- <el-button type="primary"@click="submit">提 交</el-button>--> |
| | | <!-- </div>--> |
| | | |
| | | </el-dialog> |
| | | </el-dialog> |
| | | |
| | | <propertyEdit ref="propertyEdit"></propertyEdit> |
| | | <propertyEdit ref="propertyEdit"></propertyEdit> |
| | | |
| | | |
| | | </basic-container> |
| | | </basic-container> |
| | | </template> |
| | | |
| | | <script> |
| | | import { |
| | | import { |
| | | getList, |
| | | remove, |
| | | update, |
| | |
| | | getPayConfig, |
| | | saveOrUpdateWx, |
| | | saveOrUpdateAli |
| | | } from "@/api/property/propertyCompany" |
| | | import { |
| | | } from "@/api/property/propertyCompany" |
| | | import { |
| | | mapGetters |
| | | } from "vuex" |
| | | import website from '@/config/website' |
| | | import func from "@/util/func" |
| | | } from "vuex" |
| | | import website from '@/config/website' |
| | | import func from "@/util/func" |
| | | |
| | | import propertyEdit from './components/propertyEdit.vue' |
| | | import propertyEdit from './components/propertyEdit.vue' |
| | | |
| | | const labelWidth = 120 |
| | | export default { |
| | | const labelWidth = 120 |
| | | export default { |
| | | components: { |
| | | propertyEdit |
| | | propertyEdit |
| | | }, |
| | | data () { |
| | | return { |
| | | currentTab: "wxInfo", |
| | | payInfoVisible: false, |
| | | currentRow: {}, |
| | | data() { |
| | | return { |
| | | currentTab: "wxInfo", |
| | | payInfoVisible: false, |
| | | currentRow: {}, |
| | | |
| | | form: {}, |
| | | query: {}, |
| | | loading: true, |
| | | page: { |
| | | pageSize: 10, |
| | | currentPage: 1, |
| | | total: 0, |
| | | form: {}, |
| | | query: {}, |
| | | loading: true, |
| | | page: { |
| | | pageSize: 10, |
| | | currentPage: 1, |
| | | total: 0, |
| | | }, |
| | | datetime: "", |
| | | selectionList: [], |
| | | option: { |
| | | labelWidth: 120, |
| | | searchLabelWidth: 96, |
| | | searchShow: true, |
| | | searchMenuSpan: 3, |
| | | menuWidth: 280, |
| | | |
| | | height: "auto", |
| | | calcHeight: 54, |
| | | dialogWidth: 1150, |
| | | tip: false, |
| | | border: true, |
| | | //stripe:true, |
| | | index: true, |
| | | // viewBtn: true, |
| | | delBtn: false, |
| | | selection: true, |
| | | dialogClickModal: false, |
| | | column: [{ |
| | | overHidden: true, |
| | | label: "物业公司名称", |
| | | prop: "name", |
| | | searchSpan: 5, |
| | | searchLabelWidth: 104, |
| | | search: true, |
| | | span: 18, |
| | | row: true, |
| | | width: 200, |
| | | rules: [{ |
| | | required: true, |
| | | message: "请输入物业公司名称", |
| | | trigger: "blur", |
| | | }, ], |
| | | }, |
| | | datetime: "", |
| | | selectionList: [], |
| | | option: { |
| | | labelWidth: 120, |
| | | searchLabelWidth: 96, |
| | | searchShow: true, |
| | | searchMenuSpan: 3, |
| | | menuWidth: 280, |
| | | |
| | | height: "auto", |
| | | calcHeight: 54, |
| | | dialogWidth: 1150, |
| | | tip: false, |
| | | border: true, |
| | | //stripe:true, |
| | | index: true, |
| | | // viewBtn: true, |
| | | delBtn: false, |
| | | selection: true, |
| | | dialogClickModal: false, |
| | | column: [{ |
| | | overHidden: true, |
| | | label: "物业公司名称", |
| | | prop: "name", |
| | | searchSpan: 5, |
| | | searchLabelWidth: 104, |
| | | search: true, |
| | | span: 18, |
| | | row: true, |
| | | width: 200, |
| | | rules: [{ |
| | | required: true, |
| | | message: "请输入物业公司名称", |
| | | trigger: "blur", |
| | | },], |
| | | }, |
| | | { |
| | | label: '省份', |
| | | prop: 'province', |
| | | type: 'select', |
| | | props: { |
| | | label: 'name', |
| | | value: 'code' |
| | | }, |
| | | hide: true, |
| | | span: 6, |
| | | cascader: ['city'], |
| | | dicUrl: `/api/blade-system/region/select?code=100000`, |
| | | rules: [{ |
| | | required: true, |
| | | message: '请选择省份', |
| | | trigger: 'blur' |
| | | }] |
| | | }, |
| | | { |
| | | label: '城市', |
| | | prop: 'city', |
| | | type: 'select', |
| | | span: 6, |
| | | labelWidth: 60, |
| | | cascader: ['area'], |
| | | props: { |
| | | label: 'name', |
| | | value: 'code' |
| | | }, |
| | | hide: true, |
| | | dicUrl: `/api/blade-system/region/select?code={{key}}`, |
| | | rules: [{ |
| | | required: true, |
| | | message: '请选择城市', |
| | | trigger: 'blur' |
| | | }] |
| | | }, |
| | | { |
| | | label: '地区', |
| | | prop: 'area', |
| | | type: 'select', |
| | | span: 6, |
| | | width: 260, |
| | | props: { |
| | | label: 'name', |
| | | value: 'code' |
| | | }, |
| | | hide: true, |
| | | dicUrl: `/api/blade-system/region/select?code={{key}}`, |
| | | rules: [{ |
| | | required: true, |
| | | message: '请选择地区', |
| | | trigger: 'blur' |
| | | }] |
| | | }, |
| | | { |
| | | overHidden: true, |
| | | label: "地址", |
| | | prop: "address", |
| | | span: 18, |
| | | row: true, |
| | | width: 160, |
| | | }, |
| | | { |
| | | label: "社会信用代码", |
| | | prop: "socialCreditCode", |
| | | searchSpan: 5, |
| | | searchLabelWidth: 124, |
| | | search: true, |
| | | span: 18, |
| | | row: true, |
| | | width: 100, |
| | | }, |
| | | { |
| | | label: "基础信息分", |
| | | prop: "baseInfoScore", |
| | | display: false, |
| | | }, |
| | | { |
| | | label: "经营信息分", |
| | | prop: "operateinfoScore", |
| | | display: false, |
| | | }, |
| | | { |
| | | label: "纳税信息分", |
| | | prop: "taxInfoScore", |
| | | display: false, |
| | | }, |
| | | { |
| | | label: "党建信息分", |
| | | prop: "partyBuildingInfoScore", |
| | | display: false, |
| | | }, |
| | | { |
| | | label: "企业良好信息分", |
| | | prop: "goodCorporateScore", |
| | | display: false, |
| | | }, |
| | | { |
| | | label: "项目良好信息分", |
| | | prop: "goodCorporateScore", |
| | | display: false, |
| | | }, |
| | | { |
| | | label: "违法违规行为分", |
| | | prop: "goodCorporateScore", |
| | | display: false, |
| | | }, |
| | | { |
| | | label: "评价平均分", |
| | | prop: "evaluateScore", |
| | | display: false, |
| | | }, |
| | | { |
| | | label: "街道社区分", |
| | | prop: "streetScore", |
| | | display: false, |
| | | }, |
| | | { |
| | | label: "总分", |
| | | prop: "allScore", |
| | | display: false, |
| | | }, |
| | | |
| | | { |
| | | label: "简介", |
| | | prop: "remark", |
| | | component: "AvueUeditor", |
| | | options: { |
| | | action: "/api/blade-resource/oss/endpoint/put-file-attach", |
| | | props: { |
| | | res: "data", |
| | | url: "link", |
| | | }, |
| | | }, |
| | | hide: true, |
| | | minRows: 6, |
| | | span: 24, |
| | | }, |
| | | ], |
| | | { |
| | | label: '省份', |
| | | prop: 'province', |
| | | type: 'select', |
| | | props: { |
| | | label: 'name', |
| | | value: 'code' |
| | | }, |
| | | hide: true, |
| | | span: 6, |
| | | cascader: ['city'], |
| | | dicUrl: `/api/blade-system/region/select?code=100000`, |
| | | rules: [{ |
| | | required: true, |
| | | message: '请选择省份', |
| | | trigger: 'blur' |
| | | }] |
| | | }, |
| | | data: [], |
| | | |
| | | wxPayForm: {}, |
| | | wxPayOption: { |
| | | emptyBtn: false, |
| | | height: "auto", |
| | | calcHeight: 180, |
| | | //stripe:true, |
| | | column: [{ |
| | | label: "appId", |
| | | labelWidth: labelWidth, |
| | | prop: "appId", |
| | | span: 24, |
| | | rules: [{ |
| | | required: true, |
| | | message: "请输入appId", |
| | | trigger: ["blur", "change"] |
| | | },], |
| | | }, |
| | | { |
| | | label: "mch-id", |
| | | labelWidth: labelWidth, |
| | | prop: "mchId", |
| | | span: 24, |
| | | rules: [{ |
| | | required: true, |
| | | message: "请输入mch-id", |
| | | trigger: ["blur", "change"] |
| | | },], |
| | | }, |
| | | { |
| | | label: "mchKey", |
| | | labelWidth: labelWidth, |
| | | prop: "mchKey", |
| | | rules: [{ |
| | | required: true, |
| | | message: "请输入mchKey", |
| | | trigger: ["blur", "change"] |
| | | },], |
| | | span: 24, |
| | | }, |
| | | { |
| | | label: "appSecret", |
| | | labelWidth: labelWidth, |
| | | prop: "appSecret", |
| | | rules: [{ |
| | | required: true, |
| | | message: "请输入appSecret", |
| | | trigger: ["blur", "change"] |
| | | },], |
| | | span: 24, |
| | | }, |
| | | { |
| | | label: '安全证书', |
| | | labelWidth: labelWidth, |
| | | prop: 'keyPath', |
| | | type: 'upload', |
| | | drag: true, |
| | | limit: 1, |
| | | loadText: '上传中,请稍等', |
| | | span: 24, |
| | | action: "/api/blade-resource/oss/endpoint/put-file", |
| | | propsHttp: { |
| | | res: "data", |
| | | name: 'name', |
| | | url: "link", |
| | | }, |
| | | rules: [{ |
| | | required: true, |
| | | message: "请上传安全证书", |
| | | trigger: ["blur", "change"] |
| | | },], |
| | | }, |
| | | ], |
| | | { |
| | | label: '城市', |
| | | prop: 'city', |
| | | type: 'select', |
| | | span: 6, |
| | | labelWidth: 60, |
| | | cascader: ['area'], |
| | | props: { |
| | | label: 'name', |
| | | value: 'code' |
| | | }, |
| | | hide: true, |
| | | dicUrl: `/api/blade-system/region/select?code={{key}}`, |
| | | rules: [{ |
| | | required: true, |
| | | message: '请选择城市', |
| | | trigger: 'blur' |
| | | }] |
| | | }, |
| | | { |
| | | label: '地区', |
| | | prop: 'area', |
| | | type: 'select', |
| | | span: 6, |
| | | width: 260, |
| | | props: { |
| | | label: 'name', |
| | | value: 'code' |
| | | }, |
| | | hide: true, |
| | | dicUrl: `/api/blade-system/region/select?code={{key}}`, |
| | | rules: [{ |
| | | required: true, |
| | | message: '请选择地区', |
| | | trigger: 'blur' |
| | | }] |
| | | }, |
| | | { |
| | | overHidden: true, |
| | | label: "地址", |
| | | prop: "address", |
| | | span: 18, |
| | | row: true, |
| | | width: 160, |
| | | }, |
| | | { |
| | | label: "社会信用代码", |
| | | prop: "socialCreditCode", |
| | | searchSpan: 5, |
| | | searchLabelWidth: 124, |
| | | search: true, |
| | | span: 18, |
| | | row: true, |
| | | width: 100, |
| | | }, |
| | | { |
| | | label: "基础信息分", |
| | | prop: "baseInfoScore", |
| | | display: false, |
| | | }, |
| | | { |
| | | label: "经营信息分", |
| | | prop: "operateinfoScore", |
| | | display: false, |
| | | }, |
| | | { |
| | | label: "纳税信息分", |
| | | prop: "taxInfoScore", |
| | | display: false, |
| | | }, |
| | | { |
| | | label: "党建信息分", |
| | | prop: "partyBuildingInfoScore", |
| | | display: false, |
| | | }, |
| | | { |
| | | label: "企业良好信息分", |
| | | prop: "goodCorporateScore", |
| | | display: false, |
| | | }, |
| | | { |
| | | label: "项目良好信息分", |
| | | prop: "goodCorporateScore", |
| | | display: false, |
| | | }, |
| | | { |
| | | label: "违法违规行为分", |
| | | prop: "lllegalAndIrregularScore", |
| | | display: false, |
| | | }, |
| | | { |
| | | label: "评价平均分", |
| | | prop: "evaluateScore", |
| | | display: false, |
| | | }, |
| | | { |
| | | label: "街道社区分", |
| | | prop: "streetScore", |
| | | display: false, |
| | | }, |
| | | { |
| | | label: "总分", |
| | | prop: "allScore", |
| | | display: false, |
| | | }, |
| | | |
| | | aliPayForm: {}, |
| | | aliPayOption: { |
| | | emptyBtn: false, |
| | | height: "auto", |
| | | calcHeight: 180, |
| | | //stripe:true, |
| | | column: [{ |
| | | label: "appId", |
| | | labelWidth: labelWidth, |
| | | prop: "appId", |
| | | span: 24, |
| | | rules: [{ |
| | | required: true, |
| | | message: "请输入appId", |
| | | trigger: ["blur", "change"] |
| | | },], |
| | | { |
| | | label: "简介", |
| | | prop: "remark", |
| | | component: "AvueUeditor", |
| | | options: { |
| | | action: "/api/blade-resource/oss/endpoint/put-file-attach", |
| | | props: { |
| | | res: "data", |
| | | url: "link", |
| | | }, |
| | | { |
| | | label: "privateKey", |
| | | labelWidth: labelWidth, |
| | | prop: "privateKey", |
| | | span: 24, |
| | | rules: [{ |
| | | required: true, |
| | | message: "请输入privateKey", |
| | | trigger: ["blur", "change"] |
| | | },], |
| | | }, |
| | | { |
| | | label: "publicKey", |
| | | labelWidth: labelWidth, |
| | | prop: "publicKey", |
| | | span: 24, |
| | | rules: [{ |
| | | required: true, |
| | | message: "请输入publicKey", |
| | | trigger: ["blur", "change"] |
| | | },], |
| | | }, |
| | | ], |
| | | } |
| | | }, |
| | | hide: true, |
| | | minRows: 6, |
| | | span: 24, |
| | | }, |
| | | ], |
| | | }, |
| | | data: [], |
| | | |
| | | wxPayForm: {}, |
| | | wxPayOption: { |
| | | emptyBtn: false, |
| | | height: "auto", |
| | | calcHeight: 180, |
| | | //stripe:true, |
| | | column: [{ |
| | | label: "appId", |
| | | labelWidth: labelWidth, |
| | | prop: "appId", |
| | | span: 24, |
| | | rules: [{ |
| | | required: true, |
| | | message: "请输入appId", |
| | | trigger: ["blur", "change"] |
| | | }, ], |
| | | }, |
| | | { |
| | | label: "mch-id", |
| | | labelWidth: labelWidth, |
| | | prop: "mchId", |
| | | span: 24, |
| | | rules: [{ |
| | | required: true, |
| | | message: "请输入mch-id", |
| | | trigger: ["blur", "change"] |
| | | }, ], |
| | | }, |
| | | { |
| | | label: "mchKey", |
| | | labelWidth: labelWidth, |
| | | prop: "mchKey", |
| | | rules: [{ |
| | | required: true, |
| | | message: "请输入mchKey", |
| | | trigger: ["blur", "change"] |
| | | }, ], |
| | | span: 24, |
| | | }, |
| | | { |
| | | label: "appSecret", |
| | | labelWidth: labelWidth, |
| | | prop: "appSecret", |
| | | rules: [{ |
| | | required: true, |
| | | message: "请输入appSecret", |
| | | trigger: ["blur", "change"] |
| | | }, ], |
| | | span: 24, |
| | | }, |
| | | { |
| | | label: '安全证书', |
| | | labelWidth: labelWidth, |
| | | prop: 'keyPath', |
| | | type: 'upload', |
| | | drag: true, |
| | | limit: 1, |
| | | loadText: '上传中,请稍等', |
| | | span: 24, |
| | | action: "/api/blade-resource/oss/endpoint/put-file", |
| | | propsHttp: { |
| | | res: "data", |
| | | name: 'name', |
| | | url: "link", |
| | | }, |
| | | rules: [{ |
| | | required: true, |
| | | message: "请上传安全证书", |
| | | trigger: ["blur", "change"] |
| | | }, ], |
| | | }, |
| | | ], |
| | | }, |
| | | |
| | | aliPayForm: {}, |
| | | aliPayOption: { |
| | | emptyBtn: false, |
| | | height: "auto", |
| | | calcHeight: 180, |
| | | //stripe:true, |
| | | column: [{ |
| | | label: "appId", |
| | | labelWidth: labelWidth, |
| | | prop: "appId", |
| | | span: 24, |
| | | rules: [{ |
| | | required: true, |
| | | message: "请输入appId", |
| | | trigger: ["blur", "change"] |
| | | }, ], |
| | | }, |
| | | { |
| | | label: "privateKey", |
| | | labelWidth: labelWidth, |
| | | prop: "privateKey", |
| | | span: 24, |
| | | rules: [{ |
| | | required: true, |
| | | message: "请输入privateKey", |
| | | trigger: ["blur", "change"] |
| | | }, ], |
| | | }, |
| | | { |
| | | label: "publicKey", |
| | | labelWidth: labelWidth, |
| | | prop: "publicKey", |
| | | span: 24, |
| | | rules: [{ |
| | | required: true, |
| | | message: "请输入publicKey", |
| | | trigger: ["blur", "change"] |
| | | }, ], |
| | | }, |
| | | ], |
| | | } |
| | | |
| | | } |
| | | }, |
| | | watch: {}, |
| | | computed: { |
| | | ...mapGetters(["permission", "userInfo"]), |
| | | permissionList () { |
| | | return { |
| | | addBtn: this.vaildData(this.permission.propertyCompany_add, true), |
| | | viewBtn: this.vaildData(this.permission.propertyCompany_view, true), |
| | | delBtn: this.vaildData(this.permission.propertyCompany_delete, true), |
| | | editBtn: this.vaildData(this.permission.propertyCompany_edit, true), |
| | | } |
| | | }, |
| | | ids () { |
| | | let ids = [] |
| | | this.selectionList.forEach((ele) => { |
| | | ids.push(ele.id) |
| | | }) |
| | | return ids.join(",") |
| | | }, |
| | | ...mapGetters(["permission", "userInfo"]), |
| | | permissionList() { |
| | | return { |
| | | addBtn: this.vaildData(this.permission.propertyCompany_add, true), |
| | | viewBtn: this.vaildData(this.permission.propertyCompany_view, true), |
| | | delBtn: this.vaildData(this.permission.propertyCompany_delete, true), |
| | | editBtn: this.vaildData(this.permission.propertyCompany_edit, true), |
| | | } |
| | | }, |
| | | ids() { |
| | | let ids = [] |
| | | this.selectionList.forEach((ele) => { |
| | | ids.push(ele.id) |
| | | }) |
| | | return ids.join(",") |
| | | }, |
| | | }, |
| | | created () { }, |
| | | created() {}, |
| | | methods: { |
| | | |
| | | |
| | | addProperty (row) { |
| | | this.$refs.propertyEdit.init(row) |
| | | }, |
| | | addProperty(row) { |
| | | this.$refs.propertyEdit.init(row) |
| | | }, |
| | | |
| | | aliSubmit (form, done) { |
| | | aliSubmit(form, done) { |
| | | |
| | | console.log("支付宝商户配置", this.aliPayForm) |
| | | console.log("支付宝商户配置", this.aliPayForm) |
| | | |
| | | this.aliPayForm.propertyCompanyId = this.currentRow.id |
| | | saveOrUpdateAli(this.aliPayForm).then(res => { |
| | | this.$message({ |
| | | type: "success", |
| | | message: "操作成功!", |
| | | }) |
| | | done() |
| | | }) |
| | | this.aliPayForm.propertyCompanyId = this.currentRow.id |
| | | saveOrUpdateAli(this.aliPayForm).then(res => { |
| | | this.$message({ |
| | | type: "success", |
| | | message: "操作成功!", |
| | | }) |
| | | done() |
| | | }) |
| | | |
| | | }, |
| | | }, |
| | | |
| | | wxSubmit (form, done) { |
| | | this.wxPayForm.propertyCompanyId = this.currentRow.id |
| | | wxSubmit(form, done) { |
| | | this.wxPayForm.propertyCompanyId = this.currentRow.id |
| | | |
| | | this.wxPayForm.keyPath = func.join(this.wxPayForm.keyPath) |
| | | if (this.wxPayForm.keyPath.length > 0) { |
| | | var urls = [] |
| | | var split = this.wxPayForm.keyPath.split(",") |
| | | split.forEach(url => { |
| | | var names = url.split("jczz/") |
| | | urls.push(names[1]) |
| | | }) |
| | | this.wxPayForm.keyPath = urls.join(",") |
| | | } |
| | | |
| | | console.log("微信商户配置", this.wxPayForm) |
| | | saveOrUpdateWx(this.wxPayForm).then(res => { |
| | | this.$message({ |
| | | type: "success", |
| | | message: "操作成功!", |
| | | }) |
| | | done() |
| | | }) |
| | | }, |
| | | |
| | | openPayConfig (row) { |
| | | this.currentRow = row |
| | | //调接口获取商户数据 |
| | | getPayConfig(row.id).then(res => { |
| | | let data = res.data.data |
| | | this.wxPayForm = data.wxPayInfo ? data.wxPayInfo : {} |
| | | this.aliPayForm = data.aliPayInfo ? data.aliPayInfo : {} |
| | | }) |
| | | this.payInfoVisible = !this.payInfoVisible |
| | | }, |
| | | |
| | | rowSave (row, done, loading) { |
| | | row.userid = this.userInfo.user_id |
| | | add(row).then( |
| | | () => { |
| | | this.onLoad(this.page) |
| | | this.$message({ |
| | | type: "success", |
| | | message: "操作成功!", |
| | | }) |
| | | done() |
| | | }, |
| | | (error) => { |
| | | window.console.log(error) |
| | | loading() |
| | | } |
| | | ) |
| | | }, |
| | | rowUpdate (row, index, done, loading) { |
| | | update(row).then( |
| | | () => { |
| | | this.onLoad(this.page) |
| | | this.$message({ |
| | | type: "success", |
| | | message: "操作成功!", |
| | | }) |
| | | done() |
| | | }, |
| | | (error) => { |
| | | window.console.log(error) |
| | | loading() |
| | | } |
| | | ) |
| | | }, |
| | | rowDel (row) { |
| | | this.$confirm("确定将选择数据删除?", { |
| | | confirmButtonText: "确定", |
| | | cancelButtonText: "取消", |
| | | type: "warning", |
| | | }) |
| | | .then(() => { |
| | | return remove(row.id) |
| | | }) |
| | | .then(() => { |
| | | this.onLoad(this.page) |
| | | this.$message({ |
| | | type: "success", |
| | | message: "操作成功!", |
| | | }) |
| | | }) |
| | | }, |
| | | searchReset () { |
| | | this.query = {} |
| | | this.onLoad(this.page) |
| | | }, |
| | | searchChange (params, done) { |
| | | this.query = params |
| | | this.page.currentPage = 1 |
| | | this.onLoad(this.page, params) |
| | | done() |
| | | }, |
| | | selectionChange (list) { |
| | | this.selectionList = list |
| | | }, |
| | | selectionClear () { |
| | | this.selectionList = [] |
| | | this.$refs.crud.toggleSelection() |
| | | }, |
| | | handleDelete () { |
| | | if (this.selectionList.length === 0) { |
| | | this.$message.warning("请选择至少一条数据") |
| | | return |
| | | } |
| | | this.$confirm("确定将选择数据删除?", { |
| | | confirmButtonText: "确定", |
| | | cancelButtonText: "取消", |
| | | type: "warning", |
| | | }) |
| | | .then(() => { |
| | | return remove(this.ids) |
| | | }) |
| | | .then(() => { |
| | | this.onLoad(this.page) |
| | | this.$message({ |
| | | type: "success", |
| | | message: "操作成功!", |
| | | }) |
| | | this.$refs.crud.toggleSelection() |
| | | }) |
| | | }, |
| | | beforeOpen (done, type) { |
| | | if (["edit", "view"].includes(type)) { |
| | | getPropertyCompany(this.form.id).then((res) => { |
| | | this.form = res.data.data |
| | | }) |
| | | } |
| | | // con |
| | | done() |
| | | }, |
| | | currentChange (currentPage) { |
| | | this.page.currentPage = currentPage |
| | | }, |
| | | sizeChange (pageSize) { |
| | | this.page.pageSize = pageSize |
| | | }, |
| | | refreshChange () { |
| | | this.onLoad(this.page, this.query) |
| | | }, |
| | | onLoad (page, params = {}) { |
| | | const { |
| | | dateTime |
| | | } = this.query |
| | | let values = { |
| | | ...params, |
| | | } |
| | | if (dateTime) { |
| | | values = { |
| | | ...params, |
| | | startTime: dateTime[0], |
| | | endTime: dateTime[1], |
| | | ...this.query, |
| | | } |
| | | values.dateTime = null |
| | | } |
| | | this.loading = true |
| | | getList(page.currentPage, page.pageSize, values).then((res) => { |
| | | const data = res.data.data |
| | | this.page.total = data.total |
| | | this.data = data.records |
| | | this.loading = false |
| | | this.selectionClear() |
| | | }) |
| | | this.wxPayForm.keyPath = func.join(this.wxPayForm.keyPath) |
| | | if (this.wxPayForm.keyPath.length > 0) { |
| | | var urls = [] |
| | | var split = this.wxPayForm.keyPath.split(",") |
| | | split.forEach(url => { |
| | | var names = url.split("jczz/") |
| | | urls.push(names[1]) |
| | | }) |
| | | this.wxPayForm.keyPath = urls.join(",") |
| | | } |
| | | |
| | | console.log("微信商户配置", this.wxPayForm) |
| | | saveOrUpdateWx(this.wxPayForm).then(res => { |
| | | this.$message({ |
| | | type: "success", |
| | | message: "操作成功!", |
| | | }) |
| | | done() |
| | | }) |
| | | }, |
| | | |
| | | openPayConfig(row) { |
| | | this.currentRow = row |
| | | //调接口获取商户数据 |
| | | getPayConfig(row.id).then(res => { |
| | | let data = res.data.data |
| | | this.wxPayForm = data.wxPayInfo ? data.wxPayInfo : {} |
| | | this.aliPayForm = data.aliPayInfo ? data.aliPayInfo : {} |
| | | }) |
| | | this.payInfoVisible = !this.payInfoVisible |
| | | }, |
| | | |
| | | rowSave(row, done, loading) { |
| | | row.userid = this.userInfo.user_id |
| | | add(row).then( |
| | | () => { |
| | | this.onLoad(this.page) |
| | | this.$message({ |
| | | type: "success", |
| | | message: "操作成功!", |
| | | }) |
| | | done() |
| | | }, |
| | | (error) => { |
| | | window.console.log(error) |
| | | loading() |
| | | } |
| | | ) |
| | | }, |
| | | rowUpdate(row, index, done, loading) { |
| | | update(row).then( |
| | | () => { |
| | | this.onLoad(this.page) |
| | | this.$message({ |
| | | type: "success", |
| | | message: "操作成功!", |
| | | }) |
| | | done() |
| | | }, |
| | | (error) => { |
| | | window.console.log(error) |
| | | loading() |
| | | } |
| | | ) |
| | | }, |
| | | rowDel(row) { |
| | | this.$confirm("确定将选择数据删除?", { |
| | | confirmButtonText: "确定", |
| | | cancelButtonText: "取消", |
| | | type: "warning", |
| | | }) |
| | | .then(() => { |
| | | return remove(row.id) |
| | | }) |
| | | .then(() => { |
| | | this.onLoad(this.page) |
| | | this.$message({ |
| | | type: "success", |
| | | message: "操作成功!", |
| | | }) |
| | | }) |
| | | }, |
| | | searchReset() { |
| | | this.query = {} |
| | | this.onLoad(this.page) |
| | | }, |
| | | searchChange(params, done) { |
| | | this.query = params |
| | | this.page.currentPage = 1 |
| | | this.onLoad(this.page, params) |
| | | done() |
| | | }, |
| | | selectionChange(list) { |
| | | this.selectionList = list |
| | | }, |
| | | selectionClear() { |
| | | this.selectionList = [] |
| | | this.$refs.crud.toggleSelection() |
| | | }, |
| | | handleDelete() { |
| | | if (this.selectionList.length === 0) { |
| | | this.$message.warning("请选择至少一条数据") |
| | | return |
| | | } |
| | | this.$confirm("确定将选择数据删除?", { |
| | | confirmButtonText: "确定", |
| | | cancelButtonText: "取消", |
| | | type: "warning", |
| | | }) |
| | | .then(() => { |
| | | return remove(this.ids) |
| | | }) |
| | | .then(() => { |
| | | this.onLoad(this.page) |
| | | this.$message({ |
| | | type: "success", |
| | | message: "操作成功!", |
| | | }) |
| | | this.$refs.crud.toggleSelection() |
| | | }) |
| | | }, |
| | | beforeOpen(done, type) { |
| | | if (["edit", "view"].includes(type)) { |
| | | getPropertyCompany(this.form.id).then((res) => { |
| | | this.form = res.data.data |
| | | }) |
| | | } |
| | | // con |
| | | done() |
| | | }, |
| | | currentChange(currentPage) { |
| | | this.page.currentPage = currentPage |
| | | }, |
| | | sizeChange(pageSize) { |
| | | this.page.pageSize = pageSize |
| | | }, |
| | | refreshChange() { |
| | | this.onLoad(this.page, this.query) |
| | | }, |
| | | onLoad(page, params = {}) { |
| | | const { |
| | | dateTime |
| | | } = this.query |
| | | let values = { |
| | | ...params, |
| | | } |
| | | if (dateTime) { |
| | | values = { |
| | | ...params, |
| | | startTime: dateTime[0], |
| | | endTime: dateTime[1], |
| | | ...this.query, |
| | | } |
| | | values.dateTime = null |
| | | } |
| | | this.loading = true |
| | | getList(page.currentPage, page.pageSize, values).then((res) => { |
| | | const data = res.data.data |
| | | this.page.total = data.total |
| | | this.data = data.records |
| | | this.loading = false |
| | | this.selectionClear() |
| | | }) |
| | | } |
| | | } |
| | | } |
| | | } |
| | | </script> |
| | | |
| | | <style> |
| | | .avue-upload__icon { |
| | | .avue-upload__icon { |
| | | line-height: 6; |
| | | } |
| | | </style> |
| | | } |
| | | </style> |