detail.vue 9.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398
  1. <template>
  2. <div class="page">
  3. <div class="page-top"></div>
  4. <div class="page-content">
  5. <template v-if="clubInfo">
  6. <div class="page-title">机构认证</div>
  7. <div class="row">
  8. <div class="col">机构名称:</div>
  9. <div class="col">{{ clubInfo.authParty }}</div>
  10. </div>
  11. <div class="row">
  12. <div class="col">联系电话:</div>
  13. <div class="col">{{ clubInfo.mobile }}</div>
  14. </div>
  15. <div class="row">
  16. <div class="col">运营联系人:</div>
  17. <div class="col">{{ clubInfo.linkMan }}</div>
  18. </div>
  19. <div class="row">
  20. <div class="col">运营联系人手机号:</div>
  21. <div class="col">{{ clubInfo.linkMobile }}</div>
  22. </div>
  23. <div class="row">
  24. <div class="col">所在地区:</div>
  25. <div class="col">{{ clubInfo.area }}</div>
  26. </div>
  27. <div class="row">
  28. <div class="col">所在位置:</div>
  29. <div class="col">{{ clubInfo.address }}</div>
  30. </div>
  31. <div class="row">
  32. <div class="col max-width">logo:</div>
  33. <div class="col">
  34. <el-image
  35. v-if="clubInfo.logo"
  36. :src="clubInfo.logo"
  37. :preview-src-list="[clubInfo.logo]"
  38. >
  39. </el-image>
  40. <span v-else>暂无图片</span>
  41. </div>
  42. </div>
  43. <div class="row">
  44. <div class="col max-width">门头照:</div>
  45. <div class="col">
  46. <template
  47. v-if="clubInfo.bannerList && clubInfo.bannerList.length > 0"
  48. >
  49. <template v-for="(image, index) in clubInfo.bannerList">
  50. <el-image
  51. :key="index"
  52. :src="image"
  53. :preview-src-list="clubInfo.bannerList"
  54. />
  55. </template>
  56. </template>
  57. <span v-else>暂无图片</span>
  58. </div>
  59. </div>
  60. <div class="row">
  61. <div class="col">机构类型:</div>
  62. <div class="col">
  63. {{
  64. ['医美', '生美', '项目公司', '个人', '其他'][
  65. clubInfo.firstClubType - 1
  66. ]
  67. }}
  68. </div>
  69. </div>
  70. <div
  71. class="row"
  72. v-if="clubInfo.firstClubType === 1 || clubInfo.firstClubType === 2"
  73. >
  74. <div class="col">医美类型:</div>
  75. <div class="col">
  76. {{
  77. ['诊所', '门诊', '医院', '其他', '美容院', '养生馆', '其他'][
  78. clubInfo.secondClubType - 1
  79. ]
  80. }}
  81. </div>
  82. </div>
  83. <div class="row" v-if="clubInfo.firstClubType === 1">
  84. <div class="col max-width">医疗许可证:</div>
  85. <div class="col">
  86. <el-image
  87. v-if="clubInfo.medicalLicenseImage"
  88. :src="clubInfo.medicalLicenseImage"
  89. :preview-src-list="[clubInfo.medicalLicenseImage]"
  90. />
  91. <span v-else>暂无图片</span>
  92. </div>
  93. </div>
  94. <div class="row">
  95. <div class="col">员工人数:</div>
  96. <div class="col">{{ clubInfo.empNum }}</div>
  97. </div>
  98. <div class="row">
  99. <div class="col">状态:</div>
  100. <div class="col">
  101. <div class="status">
  102. <span class="success" v-if="clubInfo.auditStatus === 1"
  103. >认证成功</span
  104. >
  105. <span class="warning" v-else-if="clubInfo.auditStatus === 2"
  106. >认证中</span
  107. >
  108. <span class="danger" v-else>认证失败</span>
  109. </div>
  110. </div>
  111. </div>
  112. <div class="row" v-if="clubInfo.auditStatus === 0">
  113. <div class="col">原因:</div>
  114. <div class="col">
  115. {{ clubInfo.invalidReason ? clubInfo.invalidReason : '暂无' }}
  116. </div>
  117. </div>
  118. <div class="control flex flex-col items-center">
  119. <div
  120. class="button edit flex justify-center items-center mb-2"
  121. @click="onEdit"
  122. v-if="clubInfo.auditStatus === 0"
  123. >
  124. 编辑
  125. </div>
  126. <div
  127. class="button search flex justify-center items-center"
  128. @click="onToDeviceList"
  129. >
  130. 查看认证设备
  131. </div>
  132. </div>
  133. </template>
  134. <template v-else>
  135. <SimpleEmpty name="icon-empty-club.png" description="暂无机构认证~" />
  136. </template>
  137. </div>
  138. </div>
  139. </template>
  140. <script>
  141. import SimpleEmpty from '@/components/SimpleEmpty'
  142. import { mapGetters } from 'vuex'
  143. export default {
  144. layout: 'app-normal',
  145. components: {
  146. SimpleEmpty,
  147. },
  148. data() {
  149. return {
  150. clubInfo: null,
  151. authId: '',
  152. }
  153. },
  154. computed: {
  155. ...mapGetters(['supplierInfo', 'routePrefix', 'clubUserId', 'userInfo']),
  156. },
  157. created() {
  158. this.fetchAuthDetail()
  159. },
  160. methods: {
  161. // 获取认证机构信息
  162. async fetchAuthDetail() {
  163. try {
  164. const result = await this.$http.api.fetchClubAuthInfo({
  165. clubUserId: this.clubUserId,
  166. })
  167. if (!result.data.auth) return
  168. this.authId = result.data.auth.authId
  169. const res = await this.$http.api.fetchClubAuthInfoData({
  170. authId: result.data.auth.authId,
  171. })
  172. this.clubInfo = res.data
  173. } catch (error) {
  174. console.log(error)
  175. }
  176. },
  177. onToDeviceList() {
  178. this.$router.push(
  179. `${this.routePrefix}/record/device?authId=${this.authId}`
  180. )
  181. },
  182. onEdit() {
  183. this.$router.push(`${this.routePrefix}/record/club/edit`)
  184. },
  185. },
  186. }
  187. </script>
  188. <style lang="scss" scoped>
  189. @media screen and (min-width: 768px) {
  190. .page {
  191. background: #fff;
  192. }
  193. .page-top {
  194. height: 360px;
  195. background: url(~assets/theme-images/normal/pc/banner-record.png);
  196. background-size: auto 360px;
  197. background-position: center;
  198. .logo {
  199. display: block;
  200. width: 120px;
  201. height: 120px;
  202. border-radius: 50%;
  203. background: #fff;
  204. }
  205. .name {
  206. font-size: 30px;
  207. color: #fff;
  208. }
  209. }
  210. .page-content {
  211. width: 600px;
  212. margin: 0 auto;
  213. overflow: hidden;
  214. min-height: calc(100vh - 80px - 80px - 360px);
  215. box-sizing: border-box;
  216. padding-bottom: 40px;
  217. .page-title {
  218. font-size: 24px;
  219. font-weight: bold;
  220. text-align: center;
  221. padding: 40px 0;
  222. }
  223. .row {
  224. display: flex;
  225. justify-content: flex-start;
  226. align-items: flex-start;
  227. font-size: 18px;
  228. margin: 24px 0;
  229. .status {
  230. .success {
  231. color: #bc1724 !important;
  232. }
  233. .warning {
  234. color: #1890ff !important;
  235. }
  236. .danger {
  237. color: #f94b4b !important;
  238. }
  239. }
  240. .col {
  241. &:first-child {
  242. white-space: nowrap;
  243. width: 170px;
  244. color: #666;
  245. text-align: right;
  246. flex-shrink: 0;
  247. }
  248. &:last-child {
  249. color: #282828;
  250. }
  251. }
  252. .el-image {
  253. width: 120px;
  254. height: 120px;
  255. margin-right: 12px;
  256. }
  257. }
  258. .control {
  259. margin-top: 62px;
  260. .button {
  261. width: 295px;
  262. height: 50px;
  263. cursor: pointer;
  264. &.edit {
  265. border: 1px solid #bc1724;
  266. color: #bc1724;
  267. }
  268. &.search {
  269. background-color: #bc1724;
  270. color: #fff;
  271. }
  272. }
  273. }
  274. }
  275. }
  276. @media screen and (max-width: 768px) {
  277. .page {
  278. background: #fff;
  279. }
  280. .page-top {
  281. height: 46vw;
  282. background: url(~assets/theme-images/normal/pc/banner-record.png);
  283. background-size: auto 46vw;
  284. background-position: center;
  285. .logo {
  286. display: block;
  287. width: 14.8vw;
  288. height: 14.8vw;
  289. border-radius: 50%;
  290. background: #fff;
  291. }
  292. .name {
  293. font-size: 4vw;
  294. color: #fff;
  295. }
  296. }
  297. .page-content {
  298. box-sizing: border-box;
  299. padding: 8vw 7.2vw;
  300. .page-title {
  301. font-size: 4.2vw;
  302. font-weight: bold;
  303. text-align: center;
  304. margin-bottom: 8vw;
  305. color: #282828;
  306. }
  307. .row {
  308. display: flex;
  309. justify-content: flex-start;
  310. align-items: flex-start;
  311. font-size: 3.4vw;
  312. margin-bottom: 5.6vw;
  313. flex-wrap: wrap;
  314. .status {
  315. .success {
  316. color: #bc1724 !important;
  317. }
  318. .warning {
  319. color: #1890ff !important;
  320. }
  321. .danger {
  322. color: #f94b4b !important;
  323. }
  324. }
  325. .col {
  326. &:first-child {
  327. width: 17vw;
  328. color: #666;
  329. // text-align: right;
  330. &.max-width {
  331. width: 100% !important;
  332. margin-bottom: 2.6vw;
  333. }
  334. }
  335. &:last-child {
  336. color: #282828;
  337. }
  338. }
  339. .el-image {
  340. width: 25.6vw;
  341. height: 25.6vw;
  342. }
  343. }
  344. .control {
  345. margin-top: 22.8vw;
  346. .button {
  347. width: 100%;
  348. height: 12vw;
  349. cursor: pointer;
  350. &.edit {
  351. border: 1px solid #bc1724;
  352. color: #bc1724;
  353. }
  354. &.search {
  355. background-color: #bc1724;
  356. color: #fff;
  357. }
  358. }
  359. }
  360. }
  361. }
  362. </style>