|
@@ -1,195 +1,43 @@
|
|
|
<template>
|
|
|
<div class="page-form-container">
|
|
|
- <div class="grid">
|
|
|
- <div class="row">
|
|
|
- <div class="col">机构名称:</div>
|
|
|
- <div class="col">{{ clubInfo.authParty }}</div>
|
|
|
+ <club-detail :auth-id="authId" />
|
|
|
+ <template v-if="type === 'audit'">
|
|
|
+ <el-form ref="auditForm" label-width="112px" :model="auditForm" :rules="rules">
|
|
|
+ <el-form-item label="审核:">
|
|
|
+ <el-radio-group v-model="auditForm.auditStatus">
|
|
|
+ <el-radio :label="1">通过</el-radio>
|
|
|
+ <el-radio :label="0">不通过</el-radio>
|
|
|
+ </el-radio-group>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item v-if="auditForm.auditStatus === 0" label="原因:" prop="invalidReason">
|
|
|
+ <el-input v-model="auditForm.invalidReason" type="textarea" :rows="3" />
|
|
|
+ </el-form-item>
|
|
|
+ </el-form>
|
|
|
+ <div class="control-box">
|
|
|
+ <el-button type="info" @click="$_back">返回</el-button>
|
|
|
+ <el-button type="primary" @click="submit">提交</el-button>
|
|
|
</div>
|
|
|
- <div class="row">
|
|
|
- <div class="col">联系电话:</div>
|
|
|
- <div class="col">{{ clubInfo.mobile }}</div>
|
|
|
- </div>
|
|
|
- <div class="row">
|
|
|
- <div class="col">所在地区:</div>
|
|
|
- <div class="col">{{ clubInfo.area }}</div>
|
|
|
- </div>
|
|
|
- <div class="row">
|
|
|
- <div class="col">详细地址:</div>
|
|
|
- <div class="col">{{ clubInfo.address }}</div>
|
|
|
- </div>
|
|
|
- <div class="row">
|
|
|
- <div class="col">所在位置:</div>
|
|
|
- <div class="col">
|
|
|
- <div class="map" @click="initMap">
|
|
|
- <i class="el-icon-map-location" />
|
|
|
- <span>点击查看</span>
|
|
|
- </div>
|
|
|
- </div>
|
|
|
- </div>
|
|
|
- </div>
|
|
|
- <div class="row">
|
|
|
- <div class="col">logo:</div>
|
|
|
- <div class="col">
|
|
|
- <preview-image v-if="clubInfo.logo" :src="clubInfo.logo" />
|
|
|
- </div>
|
|
|
- </div>
|
|
|
- <div class="row">
|
|
|
- <div class="col">门头照:</div>
|
|
|
- <div class="col">
|
|
|
- <template v-if="clubInfo.bannerList.length > 0">
|
|
|
- <template v-for="(image, index) in clubInfo.bannerList">
|
|
|
- <preview-image :key="index" class="preview-image" :src="image" :preview-src-list="clubInfo.bannerList" />
|
|
|
- </template>
|
|
|
- </template>
|
|
|
- </div>
|
|
|
- </div>
|
|
|
-
|
|
|
- <div class="row">
|
|
|
- <div class="col">机构类型:</div>
|
|
|
- <div class="col">
|
|
|
- <el-radio-group v-model="clubInfo.firstClubType">
|
|
|
- <el-radio
|
|
|
- v-for="item in clubTypeList"
|
|
|
- :key="item.id"
|
|
|
- :label="item.id"
|
|
|
- :disabled="clubInfo.firstClubType !== item.id"
|
|
|
- >{{ item.name }}</el-radio>
|
|
|
- </el-radio-group>
|
|
|
- </div>
|
|
|
- </div>
|
|
|
-
|
|
|
- <div v-if="clubInfo.firstClubType === 1" class="row">
|
|
|
- <div class="col">医美类型:</div>
|
|
|
- <div class="col">
|
|
|
- <el-radio-group v-model="clubInfo.secondClubType">
|
|
|
- <el-radio
|
|
|
- v-for="item in medicalTypeList1"
|
|
|
- :key="item.id"
|
|
|
- :label="item.id"
|
|
|
- :disabled="clubInfo.secondClubType !== item.id"
|
|
|
- >{{ item.name }}</el-radio>
|
|
|
- </el-radio-group>
|
|
|
- </div>
|
|
|
- </div>
|
|
|
-
|
|
|
- <div v-if="clubInfo.firstClubType === 2" class="row">
|
|
|
- <div class="col">生美类型:</div>
|
|
|
- <div class="col">
|
|
|
- <el-radio-group v-model="clubInfo.secondClubType">
|
|
|
- <el-radio
|
|
|
- v-for="item in medicalTypeList2"
|
|
|
- :key="item.id"
|
|
|
- :label="item.id"
|
|
|
- :disabled="clubInfo.secondClubType !== item.id"
|
|
|
- >{{ item.name }}</el-radio>
|
|
|
- </el-radio-group>
|
|
|
- </div>
|
|
|
- </div>
|
|
|
-
|
|
|
- <div v-if="clubInfo.firstClubType === 1" class="row">
|
|
|
- <div class="col">医疗许可证:</div>
|
|
|
- <div class="col">
|
|
|
- <preview-image v-if="clubInfo.medicalLicenseImage" :src="clubInfo.medicalLicenseImage" />
|
|
|
- </div>
|
|
|
- </div>
|
|
|
- <div class="row">
|
|
|
- <div class="col">员工人数:</div>
|
|
|
- <div class="col">{{ clubInfo.empNum }}人</div>
|
|
|
- </div>
|
|
|
-
|
|
|
- <div class="row">
|
|
|
- <div class="col">自定义属性:</div>
|
|
|
- <div class="col">
|
|
|
- <el-radio-group v-model="clubInfo.customFlag">
|
|
|
- <el-radio :label="1" :disabled="clubInfo.customFlag !== 1">是</el-radio>
|
|
|
- <el-radio :label="0" :disabled="clubInfo.customFlag !== 0">否</el-radio>
|
|
|
- </el-radio-group>
|
|
|
- </div>
|
|
|
- </div>
|
|
|
- <div v-if="clubInfo.customFlag > 0" class="row">
|
|
|
- <div class="col">店铺备注:</div>
|
|
|
- <div class="col">{{ clubInfo.remarks }}人</div>
|
|
|
- </div>
|
|
|
- <el-form ref="auditForm" label-width="112px" :model="auditForm" :rules="rules">
|
|
|
- <el-form-item label="审核:">
|
|
|
- <el-radio-group v-model="auditForm.auditStatus">
|
|
|
- <el-radio :label="1">通过</el-radio>
|
|
|
- <el-radio :label="0">不通过</el-radio>
|
|
|
- </el-radio-group>
|
|
|
- </el-form-item>
|
|
|
- <el-form-item v-if="auditForm.auditStatus === 0" label="原因:" prop="invalidReason">
|
|
|
- <el-input v-model="auditForm.invalidReason" type="textarea" :rows="3" />
|
|
|
- </el-form-item>
|
|
|
- <el-form-item>
|
|
|
- <div class="control-box left">
|
|
|
- <el-button type="info" @click="$_back">返回</el-button>
|
|
|
- <el-button type="primary" @click="submit">提交</el-button>
|
|
|
- </div>
|
|
|
- </el-form-item>
|
|
|
- </el-form>
|
|
|
- <!-- 地图坐标拾取 -->
|
|
|
- <el-dialog class="map-dialog" title="地图信息" :visible.sync="dialogMapVisible" width="60%">
|
|
|
- <a-map ref="aMap" :lnglat="lnglat" />
|
|
|
- </el-dialog>
|
|
|
+ </template>
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
-import SimpleAMap from '@/components/SimpleAMap'
|
|
|
-import { getAuthFormData, auditAuth } from '@/api/auth'
|
|
|
+import { auditAuth } from '@/api/auth'
|
|
|
+import { ClubDetail } from '@/views/components'
|
|
|
import { mapGetters } from 'vuex'
|
|
|
export default {
|
|
|
components: {
|
|
|
- [SimpleAMap.name]: SimpleAMap
|
|
|
+ ClubDetail
|
|
|
},
|
|
|
data() {
|
|
|
return {
|
|
|
- isLoading: false,
|
|
|
- dialogMapVisible: false,
|
|
|
- clubTypeList: [
|
|
|
- { id: 1, name: '医美' },
|
|
|
- { id: 2, name: '生美' },
|
|
|
- { id: 3, name: '项目公司' },
|
|
|
- { id: 4, name: '个人' },
|
|
|
- { id: 5, name: '其他' }
|
|
|
- ],
|
|
|
- medicalTypeList1: [
|
|
|
- { id: 1, name: '诊所' },
|
|
|
- { id: 2, name: '门诊' },
|
|
|
- { id: 3, name: '医院' },
|
|
|
- { id: 4, name: '其他' }
|
|
|
- ],
|
|
|
- medicalTypeList2: [
|
|
|
- { id: 5, name: '美容院' },
|
|
|
- { id: 6, name: '养生馆' },
|
|
|
- { id: 7, name: '其他' }
|
|
|
- ],
|
|
|
+ type: 'audit',
|
|
|
authId: '',
|
|
|
- clubInfo: {
|
|
|
- secondClubType: 1,
|
|
|
- firstClubType: 1,
|
|
|
- medicalLicenseImage: '',
|
|
|
- empNum: '',
|
|
|
- address: '',
|
|
|
- area: '',
|
|
|
- authId: '',
|
|
|
- authParty: '',
|
|
|
- bannerList: [],
|
|
|
- cityId: '',
|
|
|
- lngAndLat: '',
|
|
|
- logo: '',
|
|
|
- mobile: '',
|
|
|
- provinceId: '',
|
|
|
- townId: '',
|
|
|
- customFlag: 0,
|
|
|
- remarks: ''
|
|
|
- },
|
|
|
auditForm: {
|
|
|
auditBy: '', // 审核人id
|
|
|
authId: '', // 机构id
|
|
|
auditStatus: 1, // 审核状态
|
|
|
- invalidReason: '', // 审核信息
|
|
|
- source: 2
|
|
|
+ invalidReason: '' // 审核信息
|
|
|
},
|
|
|
rules: {
|
|
|
invalidReason: { required: true, message: '不通过原因不能为空', tigger: 'blur' }
|
|
@@ -197,15 +45,11 @@ export default {
|
|
|
}
|
|
|
},
|
|
|
computed: {
|
|
|
- ...mapGetters(['authUserId']),
|
|
|
- // 位置坐标
|
|
|
- lnglat() {
|
|
|
- return this.clubInfo.lngAndLat ? this.clubInfo.lngAndLat.split(',') : null
|
|
|
- }
|
|
|
+ ...mapGetters(['authUserId'])
|
|
|
},
|
|
|
created() {
|
|
|
- this.auditForm.authId = this.$route.query.authId
|
|
|
- this.getDetail()
|
|
|
+ this.authId = this.$route.query.authId
|
|
|
+ this.type = this.$route.query.type
|
|
|
},
|
|
|
methods: {
|
|
|
// 地图定位
|
|
@@ -217,74 +61,21 @@ export default {
|
|
|
})
|
|
|
}
|
|
|
},
|
|
|
- // 数据回显
|
|
|
- getDetail() {
|
|
|
- getAuthFormData({ authId: this.auditForm.authId }).then((res) => {
|
|
|
- this.clubInfo = { ...this.clubInfo, ...res.data }
|
|
|
- })
|
|
|
- },
|
|
|
// 提交审核信息
|
|
|
submit() {
|
|
|
+ this.auditForm.authId = this.authId
|
|
|
+ this.auditForm.auditBy = this.authUserId
|
|
|
this.$refs.auditForm.validate((valid) => {
|
|
|
if (valid) {
|
|
|
- this.isLoading = true
|
|
|
- // 指定审核人
|
|
|
- this.auditForm.auditBy = this.authUserId
|
|
|
// 提交审核信息
|
|
|
- auditAuth(this.auditForm)
|
|
|
- .then((res) => {
|
|
|
- this.$message.success(res.data)
|
|
|
- this.$store.dispatch('tagsView/delView', this.$route)
|
|
|
- this.$router.back()
|
|
|
- })
|
|
|
- .finally(() => {
|
|
|
- this.isLoading = false
|
|
|
- })
|
|
|
+ auditAuth(this.auditForm).then((res) => {
|
|
|
+ this.$message.success(res.data)
|
|
|
+ this.$store.dispatch('tagsView/delView', this.$route)
|
|
|
+ this.$router.back()
|
|
|
+ })
|
|
|
}
|
|
|
})
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
</script>
|
|
|
-
|
|
|
-<style lang="scss" scoped>
|
|
|
-.map {
|
|
|
- cursor: pointer;
|
|
|
- span {
|
|
|
- margin-left: 4px;
|
|
|
- color: #409eff;
|
|
|
- }
|
|
|
-}
|
|
|
-
|
|
|
-.grid {
|
|
|
- display: grid;
|
|
|
- grid-template-columns: repeat(2, 1fr);
|
|
|
- // grid-template-rows: repeat(2, 1fr);
|
|
|
- grid-column-gap: 0px;
|
|
|
- grid-row-gap: 0px;
|
|
|
-}
|
|
|
-.row {
|
|
|
- display: flex;
|
|
|
- justify-content: flex-start;
|
|
|
- align-items: flex-start;
|
|
|
- margin-bottom: 25px;
|
|
|
- .col {
|
|
|
- font-size: 14px;
|
|
|
- color: #333;
|
|
|
- &:first-child {
|
|
|
- min-width: 100px;
|
|
|
- text-align: right;
|
|
|
- margin-right: 8px;
|
|
|
- font-weight: bold;
|
|
|
- color: #666;
|
|
|
- }
|
|
|
-
|
|
|
- .preview-image {
|
|
|
- margin-left: 12px;
|
|
|
- &:first-child {
|
|
|
- margin-left: 0;
|
|
|
- }
|
|
|
- }
|
|
|
- }
|
|
|
-}
|
|
|
-</style>
|