model_2.vue 17 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716
  1. <template>
  2. <view class="mone">
  3. <view class="m-top">
  4. <image :src="baseURL + '/resource/icon/model2/tli.png'" mode="" class="top-left-img"></image>
  5. <button type="default" class="top-btn fx-btn" v-if="isShare" open-type="share">
  6. <image :src="baseURL + '/resource/icon/model1/fx.png'" mode=""></image>
  7. </button>
  8. <!-- 模板查看次数 -->
  9. <view class="top-btn visit mvisit padding-r-10" v-if="isLook==1">
  10. 浏览:{{cardInfo.look_count}}
  11. </view>
  12. <!-- 别人查看次数 -->
  13. <view class="top-btn visit padding-r-10" v-else-if="isLook==2">
  14. 浏览:{{cardInfo.card_look_count}}
  15. </view>
  16. </view>
  17. <view class="m-body ">
  18. <!-- 个人信息 -->
  19. <view class="hua3">
  20. <view class="hua2 ">
  21. <view class="m-card m-card-t " >
  22. <!-- 用户名称 -->
  23. <view class="u-name">
  24. {{cardInfo.name || '暂无'}}
  25. </view>
  26. <!-- 编号 -->
  27. <view class="u-bh flex">
  28. <image :src="baseURL + '/resource/icon/model2/bh.png'" mode=""></image>编号:{{cardInfo.no || "myj23031421"}}
  29. </view>
  30. <!-- 头像 -->
  31. <view class="user-img">
  32. <image :src="baseURL + '/resource/icon/model2/txk.png'" mode="" class="base-bg"></image>
  33. <image :src="cardInfo.avatar" mode="" class="user-av"></image>
  34. </view>
  35. <!-- 职业 -->
  36. <view class="zy-wrap" v-if="cardInfo.user_work_type_title">
  37. <view class="zy">
  38. 职业:{{cardInfo.user_work_type_title || '暂无'}}
  39. </view>
  40. </view>
  41. <view class="card-content card-content-t">
  42. <view class="user-info-t flex">
  43. <view class="info-item-b">
  44. 年龄: {{cardInfo.age|| '暂无'}}
  45. </view>
  46. <view class="info-item-b">
  47. 属相: {{cardInfo.twelve|| '暂无'}}
  48. </view>
  49. <view class="info-item-b">
  50. 从业: {{(cardInfo.work_year + '年')|| '暂无'}}
  51. </view>
  52. <view class="info-item-b">
  53. 星座: {{cardInfo.constellation.replace('座','') || '暂无'}}
  54. </view>
  55. <!-- <view class="info-item-b">
  56. 职业: {{cardInfo.user_work_type_title || '暂无'}}
  57. </view> -->
  58. <view class="info-item-b">
  59. 籍贯: {{cardInfo.ancestral_place || '暂无'}}
  60. </view>
  61. <view class="info-item-b">
  62. 民族: {{cardInfo.minority || '暂无'}}
  63. </view>
  64. <view class="info-item-b">
  65. 学历: {{cardInfo.education || '暂无'}}
  66. </view>
  67. </view>
  68. <view class="user-info flex">
  69. <view class="info-item-q flex" style="align-items: flex-start;">
  70. <text style="flex-shrink: 0;">服务地区:</text>
  71. <view class="fwdz flex">
  72. <view v-for="(fwitem,fwindex) in cardInfo.service_area_all">
  73. {{fwitem}}{{fwindex ==(cardInfo.service_area_all.length -1) ?'': '、' }}
  74. </view>
  75. </view>
  76. </view>
  77. <view class="info-item-q flex" style="align-items: flex-start;height: 110rpx;">
  78. <text style="flex-shrink: 0;">服务价格: </text>
  79. <view class="gzt">
  80. <image :src="baseURL + '/resource/icon/model2/tiao.png'" mode=""></image>
  81. <view class="gzt-price">
  82. <text>{{cardInfo.service_min_price}}</text>元/{{ cardInfo.service_time_type_title && cardInfo.service_time_type_title.replace('每','')}}
  83. </view>
  84. <view class=" gzt-price-b">
  85. <text>{{cardInfo.service_max_price}}</text>元/{{cardInfo.service_time_type_title && cardInfo.service_time_type_title.replace('每','')}}
  86. </view>
  87. </view>
  88. <image :src="baseURL + '/resource/icon/model1/yrz.png'" mode="" class="rz"
  89. v-if="cardInfo.is_type_audit == 1"></image>
  90. </view>
  91. </view>
  92. </view>
  93. <!-- <view class="" style="height: 40rpx;"></view> -->
  94. </view>
  95. </view>
  96. </view>
  97. <!-- 自我评价 -->
  98. <view class="hua4">
  99. <view class="">
  100. <view class="m-card">
  101. <view class="card-tit flex">
  102. <image :src="baseURL + '/resource/icon/model2/zwpj.png'" mode="" class=""></image>
  103. </view>
  104. <view class="card-content">
  105. {{cardInfo.service_intro_content}}
  106. </view>
  107. <view class="img-list flex" style="padding-top: 0;">
  108. <image :src="siiitem" mode="" v-for="siiitem in cardInfo.service_intro_imgs"></image>
  109. </view>
  110. </view>
  111. </view>
  112. </view>
  113. <!-- 我的证书 -->
  114. <view class="hua5" v-if="cardInfo.service_audit_imgs && cardInfo.service_audit_imgs.length > 0">
  115. <view class="m-card">
  116. <view class="card-tit flex">
  117. <image :src="baseURL + '/resource/icon/model2/wdzs.png'" mode="" class=""></image>
  118. </view>
  119. <view class="img-list flex">
  120. <image :src="saiitem" mode="" v-for="saiitem in cardInfo.service_audit_imgs"></image>
  121. </view>
  122. </view>
  123. </view>
  124. <!-- 服务内容 -->
  125. <view class="hua6">
  126. <view class="m-card">
  127. <view class="card-tit flex">
  128. <image :src="baseURL + '/resource/icon/model2/fwnr.png'" mode="" class=""></image>
  129. </view>
  130. <view class="card-content">
  131. <view class="fw" v-for="spaitem in cardInfo.service_project_ar">
  132. <view class="fw-tit">
  133. <text class="yg"></text>{{spaitem.title}}
  134. </view>
  135. <view class="fw-content">
  136. {{spaitem.content}}
  137. </view>
  138. </view>
  139. </view>
  140. </view>
  141. </view>
  142. <!-- 服务照片 -->
  143. <view class="hua7" v-if="cardInfo.service_imgs && cardInfo.service_imgs.length > 0">
  144. <view class="hua8">
  145. <view class="m-card" >
  146. <view class="card-tit flex">
  147. <image :src="baseURL + '/resource/icon/model2/fwzp.png'" mode="" class=""></image>
  148. </view>
  149. <view class="img-list flex">
  150. <image :src="siitem" mode="" v-for="siitem in cardInfo.service_imgs"></image>
  151. </view>
  152. </view>
  153. </view>
  154. </view>
  155. </view>
  156. </view>
  157. </template>
  158. <script>
  159. import {
  160. mapState,
  161. mapMutations
  162. } from 'vuex';
  163. import {
  164. getUserCardInfo,
  165. getCommonUserCardInfo,
  166. getShowTemplateItem,
  167. subShowTemplateOrder
  168. } from '@/api/model.js'
  169. import {
  170. getUser
  171. } from '@/api/user.js';
  172. export default {
  173. props: {
  174. isShare: {
  175. type: Boolean,
  176. default: false
  177. },
  178. //1为模板2为用户
  179. isLook: {
  180. type: Number,
  181. default: 0
  182. },
  183. cardInfo: {
  184. type: Object,
  185. default: () => {
  186. return {
  187. name: '佚名',
  188. avatar: 'https://api.myjie.cn/resource/icon/base/f.png',
  189. age: '41',
  190. twelve: '鼠',
  191. work_year: '10',
  192. constellation: '处女座',
  193. ancestral_place: '浙江',
  194. minority: '汉族',
  195. education: '本科',
  196. service_area_all: ['浙江省台州市路桥区'],
  197. service_min_price: 100,
  198. service_max_price: 200,
  199. service_time_type_title: '每小时',
  200. service_intro_content: '高级育婴师证|高级催乳师证|早产儿护理师母婴护理证|金牌月嫂证|产后恢复师证|公共营养师证|月子药膳调理师证|国际宝宝睡眠咨询师证|普通话二级甲等|中央广播电视大学学历|学前教育专业,深耕幼教十年,技能全面,性格活泼,有亲和力,做事干净利落,有很强的责任心。对宝宝有爱心,体贴新手妈妈。专业技能熟练。应急能力强。让家人放心、产妇舒心的坐好月子。',
  201. service_intro_imgs: ['https://api.myjie.cn/resource/icon/base/pj1.png',
  202. 'https://api.myjie.cn/resource/icon/base/pj2.png',
  203. 'https://api.myjie.cn/resource/icon/base/pj3.png',
  204. 'https://api.myjie.cn/resource/icon/base/pj4.png'
  205. ],
  206. service_imgs: ['https://api.myjie.cn/resource/icon/base/pj1.png',
  207. 'https://api.myjie.cn/resource/icon/base/pj2.png',
  208. 'https://api.myjie.cn/resource/icon/base/pj3.png',
  209. 'https://api.myjie.cn/resource/icon/base/pj4.png'
  210. ],
  211. service_audit_imgs: ['https://api.myjie.cn/resource/icon/base/zs1.png',
  212. 'https://api.myjie.cn/resource/icon/base/zs2.png',
  213. 'https://api.myjie.cn/resource/icon/base/zs3.png',
  214. 'https://api.myjie.cn/resource/icon/base/zs4.png'
  215. ],
  216. service_project_ar: [{
  217. title: '婴幼儿睡眠管理',
  218. content: '如:日夜颠倒、睡眠不规律、乳头混淆、奶睡、抱睡等问题,帮助宝爸宝妈规律孩子作息、解决婴幼儿喂养困扰,培养良好的生活、学习习惯。'
  219. }, {
  220. title: '特色月子餐',
  221. content: '套用客户的一句话“养眼、养心更养胃”!家常菜、面食、点心、甜品、靓汤、五谷杂粮粥、婴幼儿花样辅食等。'
  222. },
  223. {
  224. title: '早产儿特殊护理',
  225. content: '包括早产儿基础护理、安全喂养方法、追赶性生长、消化与免疫系统等技能,根据宝宝具体情况给予早产儿家长的科学入户指导。'
  226. },
  227. {
  228. title: '0-6岁早期教育',
  229. content: '在婴孩最敏感最能接受的时期进行事半功倍的适时教育,针对不同年龄段的孩子,开发婴幼儿潜能的教育,为孩子多元化和健康人格打下良好基础。'
  230. }
  231. ],
  232. is_type_audit: 1
  233. }
  234. }
  235. },
  236. },
  237. data() {
  238. return {}
  239. },
  240. computed: {
  241. ...mapState(['baseURL']),
  242. ...mapState('user', ['userInfo'])
  243. },
  244. onShow() {
  245. // this.getUser()
  246. },
  247. onUnload() {
  248. let pages = getCurrentPages(); //获取加载的页面
  249. let currentPage = pages[pages.length - 2]; //获取当前页面的对象
  250. if (currentPage.route == 'pages/public/wxLogin') {
  251. uni.switchTab({
  252. url: '/pages/index/index'
  253. })
  254. }
  255. },
  256. methods: {}
  257. }
  258. </script>
  259. <style lang="scss" scoped>
  260. .mone {
  261. background-color: #fffbed;
  262. padding-bottom: 43rpx;
  263. .m-top {
  264. width: 750rpx;
  265. position: relative;
  266. width: 750rpx;
  267. height: 150rpx;
  268. background-color: #fffbed;
  269. .top-left-img {
  270. position: absolute;
  271. top: 0;
  272. left: 0;
  273. width: 280rpx;
  274. height: 248rpx;
  275. }
  276. .top-bg {
  277. position: relative;
  278. width: 750rpx;
  279. height: 370rpx;
  280. }
  281. .readme {
  282. width: 534rpx;
  283. height: 83rpx;
  284. position: absolute;
  285. top: 172rpx;
  286. left: 0;
  287. right: 0;
  288. margin: auto;
  289. }
  290. .fx-btn {
  291. padding: 0;
  292. &::after {
  293. border: none;
  294. }
  295. border-radius: 24rpx 0 0 24rpx;
  296. image {
  297. width: 150rpx;
  298. height: 48rpx;
  299. display: block;
  300. }
  301. }
  302. .top-btn {
  303. height: 48rpx;
  304. position: absolute;
  305. right: 0;
  306. top: 70rpx;
  307. line-height: 48rpx;
  308. font-size: 24rpx;
  309. }
  310. .visit {
  311. border-radius: 24rpx 0 0 24rpx;
  312. top: 130rpx;
  313. border: 1px solid #f65486;
  314. color: #f65486;
  315. padding-left: 24rpx;
  316. }
  317. .mvisit {
  318. top: 70rpx;
  319. }
  320. }
  321. }
  322. .m-body {
  323. width: 750rpx;
  324. margin: auto;
  325. margin-top: 20rpx;
  326. padding: 45rpx 0;
  327. }
  328. .info-item-b,
  329. .info-item-q {
  330. padding: 10rpx 0;
  331. color: #000000;
  332. position: relative;
  333. padding-left: 20rpx;
  334. &::before {
  335. display: inline-block;
  336. content: '';
  337. width: 15rpx;
  338. height: 15rpx;
  339. background: linear-gradient(225deg, #FE9E32, #FDE37D);
  340. border-radius: 50%;
  341. position: absolute;
  342. top: 22rpx;
  343. left: 0;
  344. }
  345. .qianger {
  346. width: 2em;
  347. display: inline-block;
  348. }
  349. .laner {
  350. width: 0.5em;
  351. display: inline-block;
  352. }
  353. }
  354. .m-card-t {
  355. border: none !important;
  356. background: transparent !important;
  357. }
  358. .m-card {
  359. width: 640rpx;
  360. background: rgba(255, 255, 255, 0.6);
  361. border-radius: 20rpx;
  362. position: relative;
  363. // min-height: 270rpx;
  364. border: 4px solid #fff;
  365. margin: 0 auto 46rpx;
  366. .user-img {
  367. position: absolute;
  368. right: -20rpx;
  369. top: -49rpx;
  370. width: 318rpx;
  371. height: 366rpx;
  372. .base-bg {
  373. width: 100%;
  374. height: 100%;
  375. }
  376. .user-av {
  377. width: 272rpx;
  378. height: 272rpx;
  379. position: absolute;
  380. bottom: 17rpx;
  381. left: 12rpx;
  382. }
  383. }
  384. .zy-wrap {
  385. position: absolute;
  386. right: 0;
  387. top: 330rpx;
  388. width: 300rpx;
  389. // background-color: #fea540;
  390. display: flex;
  391. justify-content: center;
  392. font-size: 26rpx;
  393. .zy {
  394. display: inline-block;
  395. margin: auto;
  396. border: 1px solid #fea540;
  397. border-radius: 10rpx;
  398. padding: 8rpx 16rpx;
  399. color: #fea540;
  400. margin: auto;
  401. }
  402. }
  403. .card-tit {
  404. justify-content: center;
  405. padding-top: 55rpx;
  406. position: relative;
  407. &::after {
  408. content: '';
  409. width: 60rpx;
  410. height: 10rpx;
  411. background: #FE9E32;
  412. border-radius: 5rpx;
  413. position: absolute;
  414. bottom: -20rpx;
  415. left: 0;
  416. right: 0;
  417. margin: auto;
  418. }
  419. image {
  420. width: 213rpx;
  421. height: 47rpx;
  422. }
  423. }
  424. .card-bg {
  425. width: 100%;
  426. height: 270rpx;
  427. position: absolute;
  428. bottom: 0rpx;
  429. }
  430. .card-content {
  431. padding: 25rpx 35rpx;
  432. font-size: 26rpx;
  433. font-weight: 500;
  434. color: #2C2E35;
  435. position: relative;
  436. }
  437. .card-content-t {
  438. padding: 0;
  439. }
  440. .img-list {
  441. justify-content: space-between;
  442. flex-wrap: wrap;
  443. margin: auto;
  444. padding: 30rpx 30rpx 0;
  445. position: relative;
  446. image {
  447. width: 270rpx;
  448. height: 270rpx;
  449. background-color: #fff;
  450. margin-bottom: 30rpx;
  451. box-shadow: 0px 0px 20rpx 0px rgba(50, 50, 52, 0.6);
  452. }
  453. }
  454. .fw {
  455. font-size: 26rpx;
  456. font-weight: 500;
  457. color: #2C2E35;
  458. padding: 10rpx 0;
  459. .fw-tit {
  460. color: #FE9E32;
  461. display: flex;
  462. align-items: center;
  463. .yg {
  464. background-color: #FE9E32;
  465. display: inline-block;
  466. width: 10rpx;
  467. height: 10rpx;
  468. border-radius: 50%;
  469. margin-right: 10rpx;
  470. }
  471. }
  472. .fw-content {
  473. padding-top: 10rpx;
  474. padding-left: 18rpx;
  475. text-align: justify;
  476. }
  477. }
  478. }
  479. .user-info-t {
  480. width: 350rpx;
  481. }
  482. .user-info, .user-info-t {
  483. flex-wrap: wrap;
  484. font-size: 26rpx;
  485. font-weight: 500;
  486. color: #000000;
  487. position: relative;
  488. .info-item-b {
  489. width: 50%;
  490. }
  491. .info-item-q {
  492. width: 100%;
  493. display: flex;
  494. align-items: flex-start;
  495. justify-content: start;
  496. .fwdz {
  497. flex-direction: column;
  498. align-items: flex-start;
  499. }
  500. .gzt {
  501. width: 312rpx;
  502. height: 24rpx;
  503. padding-top: 10rpx;
  504. position: relative;
  505. image {
  506. width: 312rpx;
  507. height: 24rpx;
  508. position: relative;
  509. }
  510. .gzt-price,
  511. .gzt-price-b {
  512. width: 200rpx;
  513. text-align: center;
  514. position: absolute;
  515. padding-top: 20rpx;
  516. &::after {
  517. content: '';
  518. width: 0px;
  519. height: 0rpx;
  520. border: 14rpx solid;
  521. border-color: transparent transparent #FE9E32;
  522. position: absolute;
  523. top: -14rpx;
  524. left: 0;
  525. right: 0;
  526. margin: auto;
  527. }
  528. text {
  529. color:#FE9E32;
  530. }
  531. }
  532. .gzt-price {
  533. left: -100rpx;
  534. }
  535. .gzt-price-b {
  536. right: -100rpx;
  537. }
  538. }
  539. .rz {
  540. margin-top: 10rpx;
  541. margin-left: 10rpx;
  542. width: 87rpx;
  543. height: 26rpx;
  544. }
  545. }
  546. }
  547. .hua2 {
  548. position: relative;
  549. &::before {
  550. content: '';
  551. width: 370rpx;
  552. height: 629rpx;
  553. border-radius: 20rpx 314rpx 315rpx 20rpx;
  554. background: radial-gradient(ellipse at 0 50%, #e0f2f8,#f8f9ef, transparent);
  555. // background: url($base-url + '/resource/icon/model1/hua2.png') no-repeat;
  556. position: absolute;
  557. bottom: -315rpx;
  558. left: 0;
  559. background-size: 100% 100%;
  560. }
  561. }
  562. .hua3 {
  563. position: relative;
  564. &::before {
  565. content: '';
  566. width: 360rpx;
  567. height: 629rpx;
  568. background: radial-gradient(ellipse at 100% 50%, #FFE4E9,#fff4f5, transparent);
  569. position: absolute;
  570. bottom: -400rpx;
  571. right: 0;
  572. margin: auto;
  573. background-size: 100% 100%;
  574. }
  575. }
  576. .hua4 {
  577. position: relative;
  578. &::before {
  579. content: '';
  580. width: 272rpx;
  581. height: 621rpx;
  582. background: radial-gradient(ellipse at 100% 50%, #e0f2f8,#f8f9ef, transparent);
  583. position: absolute;
  584. bottom: -310rpx;
  585. right: 0;
  586. background-size: 100% 100%;
  587. }
  588. }
  589. .hua5 {
  590. position: relative;
  591. &::before {
  592. content: '';
  593. width: 199rpx;
  594. height: 298rpx;
  595. background: radial-gradient(ellipse at 100% 50%, #FFE4E9,#fff4f5, transparent);
  596. position: absolute;
  597. bottom: -100rpx;
  598. left: 0;
  599. background-size: 100% 100%;
  600. transform: rotateY(180deg);
  601. }
  602. }
  603. .hua6 {
  604. position: relative;
  605. &::before {
  606. content: '';
  607. width: 313rpx;
  608. height: 629rpx;
  609. position: absolute;
  610. background: radial-gradient(ellipse at 0 50%, #FFE4E9,#fff4f5, transparent);
  611. bottom: -315rpx;
  612. right: 0;
  613. background-size: 100% 100%;
  614. transform: rotateY(180deg);
  615. }
  616. }
  617. .hua7 {
  618. position: relative;
  619. &::before {
  620. content: '';
  621. width: 344rpx;
  622. height: 286rpx;
  623. position: absolute;
  624. background: url($base-url + '/resource/icon/model2/hua8.png') no-repeat;
  625. bottom: -143rpx;
  626. right: 0;
  627. background-size: 100% 100%;
  628. }
  629. }
  630. .hua8 {
  631. position: relative;
  632. &::before {
  633. content: '';
  634. width: 367rpx;
  635. height: 372rpx;
  636. position: absolute;
  637. border-radius: 20rpx 150rpx 150rpx 20rpx;
  638. background: radial-gradient(ellipse at 0% 50%, #FFE4E9,#fff7f2, transparent);
  639. bottom: -143rpx;
  640. left: 0;
  641. background-size: 100% 100%;
  642. }
  643. }
  644. .u-name {
  645. font-size: 73rpx;
  646. font-weight: 400;
  647. color: #202E4F;
  648. }
  649. .u-bh {
  650. justify-content: flex-start;
  651. image {
  652. width: 26rpx;
  653. height: 26rpx;
  654. margin-right: 10rpx;
  655. }
  656. font-size: 28rpx;
  657. font-weight: bold;
  658. color: #202e4f;
  659. }
  660. </style>