model_1.vue 16 KB

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