packageDetails.vue 27 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118
  1. <template>
  2. <view class="content">
  3. <!-- #ifdef APP-PLUS -->
  4. <es-nav-title title="疗法详情"></es-nav-title>
  5. <!-- #endif -->
  6. <!-- 购买轮播列表 -->
  7. <view class="buy-lists" v-if="notics&&notics.length>0" :style="{height: boxHeight+'px'}">
  8. <view :class="{'buy-top': animate == true }" :style="{marginTop: animate == true ? `-${marginTop}px`:'0'}">
  9. <view class="buy-list buy-txtbox" v-for="(item,index) in notics" :key="index">
  10. <view class="buy-item"><text class="textOne buy-name" >{{item.fsUserName|| ''}}</text><text>{{item.timeTxt}} 已下单</text></view>
  11. </view>
  12. </view>
  13. </view>
  14. <view class="cont-box">
  15. <view class="goods-banner" @click="showImg()">
  16. <swiper
  17. class="swiper"
  18. :indicator-dots="false"
  19. :circular="true"
  20. :autoplay="true"
  21. :interval="3000"
  22. :duration="1000"
  23. indicator-color="rgba(255, 255, 255, 0.6)"
  24. indicator-active-color="#ffffff"
  25. @change="swiperChange">
  26. <swiper-item class="swiper-item" v-for="(item,index) in imgs" :key="index">
  27. <image :src="item" mode="aspectFit"></image>
  28. </swiper-item>
  29. </swiper>
  30. <!-- 数量 -->
  31. <view class="num-box">{{ activeImg }}/{{ imgs.length }}</view>
  32. </view>
  33. <view class="package-box">
  34. <view class="title">{{item.packageName}}</view>
  35. <view class="desc">
  36. <view class="cycle" v-if="item.cycle>0">服务周期{{item.cycle}}天</view>
  37. <view class="duration" v-if="item.duration>0">签约时长{{item.duration}}天</view>
  38. <view class="huabei-box x-c">
  39. <image class="huabei" src="@/static/images/huabei-icon.png" mode="aspectFill"></image>
  40. <text style="padding: 0 5rpx;">花呗</text>
  41. <text class="huabei-red">分期</text>
  42. </view>
  43. </view>
  44. <view class="num-box">
  45. <view class="price-box">
  46. <view class="price" v-if="item!=null">¥{{item.price&&item.price.toFixed(2)}}元/日</view>
  47. <view class="price" v-if="item!=null&&item.packageSubType==1">咨询包</view>
  48. <view class="price" v-if="item!=null&&item.packageSubType==2">治疗包</view>
  49. <view class="price" v-if="item!=null&&item.packageSubType==3">产品包</view>
  50. </view>
  51. <view class="count">{{item.sales}}人已购</view>
  52. </view>
  53. </view>
  54. <view class="drug-box" v-if="products.length>0 ">
  55. <view class="title-box">
  56. <view class="line"></view>
  57. <view class="title">处方列表</view>
  58. </view>
  59. <view class="drug-list" >
  60. <view v-for="(product,index) in products" class="drug-item" >
  61. <view class="drug" v-if="displayMore==0?index<2:true" >
  62. <view class="img-box">
  63. <image :src="product.image" mode="aspectFill"></image>
  64. </view>
  65. <view class="drug-info" >
  66. <view>
  67. <view class="name-box ellipsis2">
  68. {{product.productName}}
  69. </view>
  70. <view class="spec">{{product.sku}}</view>
  71. </view>
  72. <view class="num-box">
  73. <view class="use">
  74. {{product.usageMethod}}
  75. </view>
  76. <view class="price">
  77. <!-- <text class="unit">¥</text>
  78. <text class="num">{{product.price.toFixed(2)}}</text> -->
  79. </view>
  80. <!-- <view class="amount">x{{product.count}}</view> -->
  81. </view>
  82. </view>
  83. </view>
  84. </view>
  85. </view>
  86. <view v-if="products.length>2" class="display-more" @click="showMore()" >{{displayText}}</view>
  87. <view class="tip">
  88. <image class="img" src="/static/images/dui.png" style="flex-shrink: 0;"></image>
  89. <view class="text">本疗法所包含药品由{{storeName}}配送</view>
  90. </view>
  91. </view>
  92. <view class="desc-box" v-if="describe&&describe.use">
  93. <view class="title-box">
  94. <view class="line"></view>
  95. <view class="title">疗程</view>
  96. </view>
  97. <view class="desc" v-if="describe!=null" v-html="describe.use">
  98. </view>
  99. </view>
  100. <view class="desc-box">
  101. <view class="title-box">
  102. <view class="line"></view>
  103. <view class="title">疗法详情</view>
  104. </view>
  105. <view class="html" v-html="item.desc">
  106. </view>
  107. </view>
  108. <view class="desc-box" v-if="item.indication!=null">
  109. <view class="title-box">
  110. <view class="line"></view>
  111. <view class="title">功能主治</view>
  112. </view>
  113. <view class="desc" v-if="item!=null" v-html="item.indication">
  114. </view>
  115. </view>
  116. <view class="desc-box" v-if="describe&&describe.usageMethod">
  117. <view class="title-box">
  118. <view class="line"></view>
  119. <view class="title">服用/使用方式</view>
  120. </view>
  121. <view class="desc" v-html="describe.usageMethod">
  122. </view>
  123. </view>
  124. <view class="desc-box" v-if="describe&&describe.forPeople">
  125. <view class="title-box">
  126. <view class="line"></view>
  127. <view class="title">适宜人群</view>
  128. </view>
  129. <view class="desc" v-html="describe.forPeople">
  130. </view>
  131. </view>
  132. <view class="desc-box" v-if="describe&&describe.tabooPeople">
  133. <view class="title-box">
  134. <view class="line"></view>
  135. <view class="title">禁忌人群</view>
  136. </view>
  137. <view class="desc" v-html="describe.tabooPeople">
  138. </view>
  139. </view>
  140. <view class="desc-box" v-if="describe&&item.explain">
  141. <view class="title-box">
  142. <view class="line"></view>
  143. <view class="title">方解/搭配优势</view>
  144. </view>
  145. <view class="desc" v-html="item.explain">
  146. </view>
  147. </view>
  148. </view>
  149. <view class="btn-foot" v-if="packageId">
  150. <view>
  151. <view class="p-price-box">
  152. <view class="p-name" v-if="couponPrice >= 0">券后</view>
  153. <view class="p-name">¥</view>
  154. <view class="p-price" v-if="item!=null">{{couponPrice >= 0 ? couponPrice.toFixed(2):item.totalPrice&&item.totalPrice.toFixed(2)}}</view>
  155. </view>
  156. <view class="y-price" v-if="couponPrice >= 0">¥{{item.totalPrice&&item.totalPrice.toFixed(2)}}</view>
  157. </view>
  158. <view class="btn-box">
  159. <view class="btn share" v-if="!isH5" @click="doShare()">分享</view>
  160. <view class="btn buy" @click="doSubmit()">提交需求</view>
  161. </view>
  162. <!-- 待支付订单 -->
  163. <view class="message-box x-bc" v-if="messageShow">
  164. <view class="left x-c">
  165. <uni-icons type="close" size="22" color="#FF6633" style="margin-right: 18rpx;" @click="messageShow=false"></uni-icons>
  166. <view class="text ellipsis">您有{{count1}}个待支付订单</view>
  167. </view>
  168. <view class="btn x-c" @click="showOrder()">查看</view>
  169. </view>
  170. </view>
  171. <u-popup bgColor="#f6f6f6" :round="10" mode="bottom" :show="doctorShow" @open="doctorOpen()" @close="doctorClose()">
  172. <view class="doctors">
  173. <scroll-view class="scroll-list" scroll-y="true" @scrolltolower="lower" >
  174. <view class="doctor" @click="navTo('/pages_doctor/doctorDetails?doctorId='+item.doctorId)" v-for="(item,index) in doctors">
  175. <view class="item">
  176. <view class="left">
  177. <image mode="aspectFill" class="doc-img" :src="item.avatar"></image>
  178. <view class="right">
  179. <view class="doc-box">
  180. <view class="doc-name">
  181. {{item.doctorName}}
  182. </view>
  183. <view class="doc-position">{{item.position}}</view>
  184. </view>
  185. <view class="hospital">
  186. {{item.hospitalName}} {{item.deptName}}
  187. </view>
  188. </view>
  189. </view>
  190. <view class="btn" @click="handleDoctorClick(item)">选择</view>
  191. </view>
  192. </view>
  193. </scroll-view>
  194. </view>
  195. </u-popup>
  196. <!-- 分享弹窗 -->
  197. <u-popup :show="showShare" @close="showShare = false" >
  198. <share-box :shareItem="shareItem" @closeShare='showShare = false' ></share-box>
  199. </u-popup>
  200. </view>
  201. </template>
  202. <script>
  203. import { caculateTimeago } from '@/utils/tools.js';
  204. import {create,getMyPackageOrderList} from '@/api/packageOrder.js'
  205. import {bindCompanyUser} from '@/api/companyUser.js'
  206. import {getPackageById,getPackageDoctorList,getNewOrderByPackageId,checkContinue} from '@/api/package.js'
  207. export default {
  208. data() {
  209. return {
  210. // isDrug:0,
  211. storeName:"",
  212. displayText:"查看更多",
  213. displayMore:0,
  214. imgs:[],
  215. activeImg: 1,
  216. doctorShow:false,
  217. doctors:[],
  218. products:[],
  219. packageId:null,
  220. item:{},
  221. describe:null,
  222. doctorId:null,
  223. doctorPageNum:1,
  224. doctorLastPage:false,
  225. doctorTotal:0,
  226. companyUserId:null,
  227. companyId:null,
  228. showShare:false,
  229. isH5:false,
  230. shareItem:{ imageUrl:"",title:"",path:""},
  231. count1:0,
  232. messageShow:false,
  233. boxHeight: 94,
  234. marginTop: 30,
  235. animate:false,
  236. timer:null,
  237. notics:[],
  238. choose: 0,
  239. couponPrice: -1
  240. };
  241. },
  242. onLoad(option) {
  243. this.choose = option.choose || 0
  244. this.packageId=option.packageId;
  245. if(!this.$isEmpty(option.companyId)){
  246. this.companyId=option.companyId
  247. }
  248. if(!this.$isEmpty(option.companyUserId)){
  249. this.companyUserId=option.companyUserId
  250. }
  251. //#ifdef H5
  252. this.isH5=true;
  253. //#endif
  254. },
  255. onReady() {
  256. this.getNewOrderByPackageId()
  257. },
  258. onUnload() {
  259. if(this.timer) clearInterval(this.timer)
  260. },
  261. onShow() {
  262. if(this.$isLogin()){
  263. let data = {companyUserId:this.companyUserId};
  264. bindCompanyUser(data).then(
  265. res => {
  266. if(res.code==200){
  267. }
  268. },
  269. rej => {}
  270. );
  271. this.getOrder()
  272. } else {
  273. uni.navigateTo({
  274. url: '/pages/auth/loginIndex'
  275. })
  276. }
  277. this.getPackageById();
  278. this.getPackageDoctorList();
  279. },
  280. onShareAppMessage(res) {
  281. return {
  282. title: this.item.packageName,
  283. path: '/pages_index/packageDetails?packageId='+this.packageId+"&companyId="+this.companyId+"&companyUserId="+this.companyUserId,
  284. imageUrl: this.item.imgUrl //分享图标,路径可以是本地文件路径、代码包文件路径或者网络图片路径.支持PNG及JPG。显示图片长宽比是 5:4
  285. }
  286. },
  287. methods:{
  288. scroll() {
  289. this.animate = true;
  290. setTimeout(() => {
  291. this.notics.push(this.notics[0]);
  292. this.notics.shift();
  293. this.animate = false;
  294. }, 1000);
  295. },
  296. getText() {
  297. const query = uni.createSelectorQuery().in(this);
  298. query
  299. .select(".buy-txtbox")
  300. .boundingClientRect((data) => {
  301. if(data&&data.height) {
  302. this.marginTop = data.height + 7
  303. if(this.notics.length>2) {
  304. this.boxHeight = this.marginTop * 3 + 4
  305. } else {
  306. this.boxHeight = this.marginTop * this.notics.length + 4
  307. }
  308. }
  309. })
  310. .exec();
  311. },
  312. getNewOrderByPackageId() {
  313. if(this.timer) clearInterval(this.timer)
  314. getNewOrderByPackageId({packageId:this.packageId}).then(res=>{
  315. if(res.code== 200) {
  316. this.notics = res.data
  317. if(res.data&&res.data.length > 0) {
  318. this.notics = res.data.map(item=>({
  319. ...item,
  320. timeTxt: caculateTimeago(new Date(item.payTime).getTime(),1)
  321. }))
  322. this.$nextTick(()=>{
  323. this.getText()
  324. this.timer = setInterval(this.scroll, 1200);
  325. })
  326. }
  327. } else {
  328. this.notics = []
  329. }
  330. })
  331. },
  332. showOrder(){
  333. if(this.$isLogin()) {
  334. uni.navigateTo({
  335. url: '/pages/store/packageOrderList?status=1'
  336. })
  337. }
  338. },
  339. getOrder() {
  340. const data = {
  341. status: 1,
  342. pageNum: 1,
  343. pageSize: 10
  344. };
  345. getMyPackageOrderList(data).then(res => {
  346. if(res.code==200){
  347. this.count1 = res.data.total
  348. this.messageShow = res.data.total > 0
  349. }
  350. });
  351. },
  352. showMore(){
  353. this.displayMore=this.displayMore==1?0:1;
  354. this.displayText=this.displayMore==1?'收起':'查看更多'
  355. console.log(this.displayText)
  356. },
  357. swiperChange(event) {
  358. this.activeImg = event.detail.current + 1
  359. },
  360. handleDoctorClick(item){
  361. this.doctorShow=false;
  362. this.doctorId=item.doctorId
  363. this.doSubmit();
  364. },
  365. lower(event) {
  366. if(this.doctorTotal>this.doctors.length){
  367. this.doctorPageNum++;
  368. this.getPackageDoctorList();
  369. }
  370. },
  371. doSubmit(){
  372. var that=this
  373. if(!this.$isLogin()){
  374. this.$showLoginPage();
  375. return;
  376. }
  377. that.submit();
  378. },
  379. submit(){
  380. if(this.doctors.length>0&&this.doctorId==null){
  381. this.doctorShow=true;
  382. }
  383. else{
  384. checkContinue(this.packageId).then(res=>{
  385. if(res.code == 200){
  386. if(res.tip) {
  387. uni.showModal({
  388. title: '提示',
  389. content: res.tip,
  390. showCancel: false,
  391. success: function(res) {
  392. if (res.confirm) {
  393. console.log('用户点击确定');
  394. } else if (res.cancel) {
  395. console.log('用户点击取消');
  396. }
  397. }
  398. });
  399. return;
  400. }else {
  401. const choose = this.choose || ''
  402. uni.navigateTo({
  403. url:"/pages/store/packageForm?packageId="+this.packageId+"&doctorId="+this.doctorId+"&companyId="+this.companyId+"&companyUserId="+this.companyUserId+'&choose='+choose,
  404. });
  405. }
  406. } else {
  407. uni.showToast({
  408. title: res.msg,
  409. icon: "none"
  410. })
  411. }
  412. })
  413. }
  414. },
  415. createOrder(){
  416. uni.showLoading({
  417. title:"处理中..."
  418. })
  419. var data={
  420. companyId:this.companyId,
  421. companyUserId:this.companyUserId,
  422. packageId:this.packageId,
  423. doctorId:this.doctorId,
  424. }
  425. //#ifdef APP-PLUS
  426. data.source=2;
  427. //#endif
  428. //#ifdef H5
  429. data.source=3;
  430. //#endif
  431. var that=this;
  432. create(data).then(res => {
  433. uni.hideLoading()
  434. if(res.code==200){
  435. uni.navigateTo({
  436. url: '/pages_order/packageOrderPay?orderId='+res.order.orderId
  437. })
  438. }else{
  439. uni.showToast({
  440. icon:'none',
  441. title: res.msg,
  442. });
  443. }
  444. });
  445. },
  446. doctorOpen(){
  447. this.doctorShow=true;
  448. },
  449. doctorClose(){
  450. this.doctorShow=false;
  451. },
  452. showImg() {
  453. //预览图片
  454. uni.previewImage({
  455. urls: this.imgs,
  456. current: this.imgs[0]
  457. });
  458. },
  459. getPackageDoctorList(){
  460. if(this.doctorLastPage){
  461. return;
  462. }
  463. var data = {
  464. packageId:this.packageId,
  465. pageNum: this.doctorPageNum,
  466. pageSize: 10
  467. };
  468. var that=this;
  469. getPackageDoctorList(data).then(
  470. res => {
  471. if(res.code==200){
  472. //设置列表数据
  473. if (this.doctorPageNum == 0) {
  474. that.doctors = res.data.list;
  475. } else {
  476. that.doctors = that.doctors.concat(res.data.list);
  477. }
  478. this.doctorLastPage=res.data.isLastPage;
  479. this.doctorTotal=res.data.total
  480. console.log(that.doctors)
  481. }else{
  482. uni.showToast({
  483. icon:'none',
  484. title: "请求失败",
  485. });
  486. }
  487. },
  488. rej => {}
  489. );
  490. },
  491. getPackageById(){
  492. var that=this;
  493. let data = {packageId:this.packageId};
  494. getPackageById(data).then(res => {
  495. if(res.code==200){
  496. this.couponPrice = res.couponPrice
  497. this.item=res.data;
  498. this.storeName=res.storeName;
  499. if(res.data.images!=null){
  500. this.imgs=res.data.images.split(",")
  501. }
  502. else{
  503. this.activeImg=0;
  504. }
  505. this.describe=JSON.parse(this.item.describeJson);
  506. if(this.item.productJson!=null){
  507. this.products=JSON.parse(this.item.productJson);
  508. // this.isDrug=0;
  509. // this.products.forEach(function(element) {
  510. // if(element.isDrug!=null&&element.isDrug==1){
  511. // that.isDrug=1;
  512. // }
  513. // });
  514. }
  515. }else{
  516. uni.showToast({
  517. icon:'none',
  518. title: "请求失败",
  519. });
  520. }
  521. },
  522. rej => {}
  523. );
  524. },
  525. doShare(){
  526. if(this.isH5){
  527. return;
  528. }
  529. const that = this
  530. that.shareItem.title=that.item.packageName;
  531. that.shareItem.imageUrl=this.item.imgUrl
  532. that.shareItem.compressImage = 1;
  533. that.shareItem.summary=!that.$isEmpty(that.item.description)?that.item.description:"";
  534. that.shareItem.isMini=true;
  535. that.shareItem.showCopyUrl=false;
  536. that.shareItem.path="/pages_index/packageDetails?packageId="+that.packageId+"&companyId="+that.companyId+"&companyUserId="+that.companyUserId;
  537. let cdn=uni.getStorageSync('h5Path');
  538. that.shareItem.url=cdn+"/pages/store/packageDetails?packageId="+that.packageId+"&companyId="+that.companyId+"&companyUserId="+that.companyUserId;
  539. that.showShare=true;
  540. },
  541. }
  542. }
  543. </script>
  544. <style lang="scss" scoped>
  545. page{
  546. height: 100%;
  547. }
  548. .buy-lists{
  549. height: 94px;
  550. background-color:transparent;
  551. overflow: hidden;
  552. width: 60%;
  553. position: absolute;
  554. z-index: 99;
  555. top: 20vh;
  556. left: 20rpx;
  557. }
  558. .buy-list{
  559. height: 23px;
  560. font-size: 26rpx;
  561. margin-top: 7px;
  562. overflow: hidden;
  563. color: #fff;
  564. .buy-item {
  565. display: inline-flex;
  566. align-items: center;
  567. height: 100%;
  568. line-height: 100%;
  569. overflow: hidden;
  570. background-color: rgba(0, 0, 0, 0.35);
  571. border-radius: 10rpx;
  572. padding: 0 20rpx;
  573. box-sizing: border-box;
  574. word-break: break-all;
  575. white-space: nowrap;
  576. }
  577. .buy-name {
  578. width: 50%;
  579. margin-right: 10rpx;
  580. }
  581. }
  582. .buy-top {
  583. transition: all 0.8s ease-in;
  584. margin-top: -30px;
  585. }
  586. .content{
  587. height: 100%;
  588. display: flex;
  589. flex-direction: column;
  590. .cont-box{
  591. padding-bottom: 121rpx;
  592. .package-box{
  593. background-color: #fff;
  594. padding: 20rpx;
  595. width: 100%;
  596. display: flex;
  597. flex-direction: column;
  598. align-items: flex-start;
  599. justify-content: flex-start;
  600. .title{
  601. font-weight: bold;
  602. font-size: 34rpx;
  603. font-family: PingFang SC;
  604. color: #111;
  605. }
  606. .desc{
  607. margin-top: 15rpx;
  608. display: flex;
  609. align-items: flex-start;
  610. justify-content: flex-start;
  611. .cycle{
  612. background-color: #eee;
  613. border-radius: 30rpx;
  614. padding: 5rpx 15rpx;
  615. font-size: 26rpx;
  616. font-family: PingFang SC;
  617. color: #FF5030;
  618. }
  619. .duration{
  620. margin-left: 10rpx;
  621. background-color: #eee;
  622. border-radius: 30rpx;
  623. padding: 5rpx 15rpx;
  624. font-size: 26rpx;
  625. font-family: PingFang SC;
  626. color: #FF5030;
  627. }
  628. .huabei-box {
  629. font-size: 26rpx;
  630. font-family: PingFang SC;
  631. color: #403c3b;
  632. font-weight: 600;
  633. padding: 5rpx 15rpx;
  634. }
  635. .huabei {
  636. width: 30rpx;
  637. height: 30rpx;
  638. }
  639. .huabei-red {
  640. background-color: #e83944;
  641. color: #fff;
  642. border-radius: 8rpx 8rpx 8rpx 0;
  643. display: inline-block;
  644. padding: 0 5rpx;
  645. font-size: 24rpx;
  646. }
  647. }
  648. .num-box{
  649. margin-top: 15rpx;
  650. flex: 1;
  651. display: flex;
  652. align-items: flex-end;
  653. justify-content: space-between;
  654. width: 100%;
  655. .price-box{
  656. display: flex;
  657. align-items: center;
  658. justify-content: flex-start;
  659. .price{
  660. margin-right: 10rpx;
  661. padding: 5rpx 10rpx;
  662. background-color: #FF5030;
  663. border-radius: 30rpx;
  664. font-size: 20rpx;
  665. font-family: PingFang SC;
  666. color: #ffffff;
  667. }
  668. }
  669. .count{
  670. font-size: 24rpx;
  671. font-family: PingFang SC;
  672. color: #333333;
  673. }
  674. }
  675. }
  676. .desc-box{
  677. background-color: #fff;
  678. padding: 20rpx;
  679. margin-top: 10rpx;
  680. .title-box{
  681. display: flex;
  682. flex-direction: row;
  683. align-items: center;
  684. justify-content: flex-start;
  685. .title{
  686. font-size: 32rpx;
  687. font-family: PingFang SC;
  688. font-weight: bold;
  689. color: #111111;
  690. }
  691. .line{
  692. margin-right: 15rpx;
  693. height: 30rpx;
  694. width: 6rpx;
  695. background-color: #FF5030;
  696. }
  697. }
  698. .desc{
  699. margin-top: 15rpx;
  700. font-size: 28rpx;
  701. font-family: PingFang SC;
  702. color: #9a9a9c;
  703. }
  704. .html{
  705. margin-top: 15rpx;
  706. // font-size: 0px;
  707. vertical-align: middle;
  708. ::v-deep {
  709. img {
  710. font-size: 0px;
  711. vertical-align: middle;
  712. }
  713. }
  714. }
  715. }
  716. .drug-box{
  717. background-color: #fff;
  718. padding: 20rpx;
  719. margin-top: 10rpx;
  720. .title-box{
  721. display: flex;
  722. flex-direction: row;
  723. align-items: center;
  724. justify-content: flex-start;
  725. .title{
  726. font-size: 32rpx;
  727. font-family: PingFang SC;
  728. font-weight: bold;
  729. color: #111111;
  730. }
  731. .line{
  732. margin-right: 15rpx;
  733. height: 30rpx;
  734. width: 6rpx;
  735. background-color: #FF5030;
  736. }
  737. }
  738. .drug-list{
  739. margin-top: 15rpx;
  740. .drug-item{
  741. .drug{
  742. padding-bottom: 15rpx;
  743. border-bottom: 1px soli #F0F0F0;
  744. display: flex;
  745. align-items: center;
  746. .img-box{
  747. width: 160rpx;
  748. height: 160rpx;
  749. margin-right: 30rpx;
  750. flex-shrink: 0;
  751. image{
  752. width: 100%;
  753. height: 100%;
  754. }
  755. }
  756. .drug-info{
  757. width: calc(100% - 190rpx);
  758. height: 160rpx;
  759. display: flex;
  760. flex-direction: column;
  761. justify-content: space-between;
  762. .name-box{
  763. font-size: 28rpx;
  764. font-family: PingFang SC;
  765. font-weight: 500;
  766. color: #111111;
  767. line-height: 40rpx;
  768. .tag{
  769. display: inline-block;
  770. padding: 0 6rpx;
  771. height: 30rpx;
  772. background: linear-gradient(90deg, #2BC7B9 0%, #2BC7A4 100%);
  773. border-radius: 4rpx;
  774. margin-right: 10rpx;
  775. font-size: 22rpx;
  776. font-family: PingFang SC;
  777. font-weight: bold;
  778. color: #FFFFFF;
  779. line-height: 30rpx;
  780. float: left;
  781. margin-top: 7rpx;
  782. }
  783. }
  784. .spec{
  785. font-size: 24rpx;
  786. font-family: PingFang SC;
  787. font-weight: 500;
  788. color: #999999;
  789. line-height: 1;
  790. margin-top: 10rpx;
  791. }
  792. .num-box{
  793. display: flex;
  794. align-items: center;
  795. justify-content: space-between;
  796. .price{
  797. display: flex;
  798. align-items: flex-end;
  799. .unit{
  800. font-size: 24rpx;
  801. font-family: PingFang SC;
  802. font-weight: 500;
  803. color: #111111;
  804. line-height: 1.2;
  805. margin-right: 4rpx;
  806. }
  807. .num{
  808. font-size: 32rpx;
  809. font-family: PingFang SC;
  810. font-weight: 500;
  811. color: #111111;
  812. line-height: 1;
  813. }
  814. }
  815. .use{
  816. font-size: 24rpx;
  817. font-family: PingFang SC;
  818. color: #999999;
  819. }
  820. .amount{
  821. font-size: 24rpx;
  822. font-family: PingFang SC;
  823. font-weight: 500;
  824. color: #999999;
  825. line-height: 1;
  826. }
  827. }
  828. }
  829. }
  830. }
  831. }
  832. .display-more{
  833. font-size: 24rpx;
  834. font-family: PingFang SC;
  835. font-weight: 500;
  836. color: #999999;
  837. display: flex;
  838. align-items: center;
  839. justify-content: center;
  840. }
  841. .tip{
  842. margin-top: 10rpx;
  843. display: flex;
  844. align-items: center;
  845. justify-content: flex-start;
  846. .img{
  847. width: 20rpx;
  848. height:20rpx;
  849. }
  850. .text{
  851. margin-left: 10rpx;
  852. font-size: 26rpx;
  853. font-family: PingFang SC;
  854. font-weight: 500;
  855. color: #999999;
  856. }
  857. }
  858. }
  859. }
  860. }
  861. .btn-foot{
  862. box-sizing: border-box;
  863. width: 100%;
  864. min-height: 121rpx;
  865. background: #FFFFFF;
  866. padding: 0 32rpx 0 28rpx;
  867. display: flex;
  868. align-items: center;
  869. justify-content: space-between;
  870. position: fixed;
  871. left: 0;
  872. bottom: 0;
  873. z-index: 99;
  874. .p-price-box{
  875. display: flex;
  876. align-items: center;
  877. .p-name{
  878. font-size: 28rpx;
  879. font-family: PingFang SC;
  880. font-weight: 500;
  881. color: #FF6633;
  882. }
  883. .p-price{
  884. margin-left: 10rpx;
  885. color: #FF6633;
  886. font-size: 38rpx;
  887. font-family: PingFang SC;
  888. font-weight: bold;
  889. }
  890. }
  891. .y-price {
  892. font-size: 24rpx;
  893. font-family: PingFang SC;
  894. color: #999;
  895. text-decoration: line-through;
  896. }
  897. .btn-box{
  898. display: flex;
  899. align-items: center;
  900. .btn{
  901. min-width: 200rpx;
  902. min-height: 88rpx;
  903. line-height: 88rpx;
  904. text-align: center;
  905. border-radius: 44rpx;
  906. margin-left: 20rpx;
  907. font-size: 30rpx;
  908. font-family: PingFang SC;
  909. font-weight: bold;
  910. color: #FFFFFF;
  911. &:first-child{
  912. margin-left: 0;
  913. }
  914. &.share{
  915. background: #2BC7B9;
  916. }
  917. &.buy{
  918. background: #FF5030;
  919. }
  920. }
  921. }
  922. }
  923. .doctors{
  924. overflow-y: auto;
  925. padding: 20rpx;
  926. height: 650rpx;
  927. width: 100%;
  928. display: flex;
  929. flex-direction: column;
  930. align-items: flex-start;
  931. justify-content: flex-start;
  932. box-sizing: border-box;
  933. .scroll-list{
  934. height: 650rpx;
  935. }
  936. .doctor{
  937. width: 100%;
  938. margin-bottom: 15rpx;
  939. background: #f9f8fe;
  940. padding: 20rpx;
  941. display: flex;
  942. flex-direction: column;
  943. align-items: flex-start;
  944. justify-content: flex-start;
  945. &:last-child{
  946. margin-bottom: 0rpx;
  947. }
  948. .item{
  949. width: 100%;
  950. display: flex;
  951. align-items: center;
  952. justify-content: space-between;
  953. .left{
  954. flex: 1;
  955. width: 100%;
  956. display: flex;
  957. align-items: flex-start;
  958. justify-content: flex-start;
  959. .doc-img{
  960. width:80rpx;
  961. height:80rpx;
  962. border-radius: 50%;
  963. }
  964. .right{
  965. width: calc(100% - 100rpx);
  966. margin-left: 20rpx;
  967. display: flex;
  968. flex-direction: column;
  969. align-items: flex-start;
  970. justify-content: flex-start;
  971. .doc-box{
  972. display: flex;
  973. align-items: center;
  974. justify-content: space-between;
  975. .doc-name{
  976. font-size: 28rpx;
  977. font-family: PingFang SC;
  978. font-weight: bold;
  979. color: #111111;
  980. }
  981. .doc-position{
  982. margin-left: 50rpx;
  983. font-size: 26rpx;
  984. font-family: PingFang SC;
  985. color: #2d2b36;
  986. }
  987. }
  988. .hospital{
  989. margin-top: 10rpx;
  990. font-size: 24rpx;
  991. font-family: PingFang SC;
  992. color: #9a9a9c;
  993. }
  994. }
  995. }
  996. .btn{
  997. padding: 10rpx 30rpx;
  998. text-align: center;
  999. border-radius: 30rpx;
  1000. font-size: 28rpx;
  1001. font-family: PingFang SC;
  1002. color: #FF5030;
  1003. border:1rpx solid #FF5030;
  1004. }
  1005. }
  1006. }
  1007. }
  1008. .goods-banner{
  1009. height: 756rpx;
  1010. background-color: #FFFFFF;
  1011. position: relative;
  1012. .swiper-item{
  1013. box-sizing: border-box;
  1014. }
  1015. .swiper,
  1016. .swiper-item,
  1017. .swiper-item image{
  1018. width: 100%;
  1019. height: 100%;
  1020. }
  1021. .num-box{
  1022. width: 80rpx;
  1023. height: 44rpx;
  1024. line-height: 44rpx;
  1025. text-align: center;
  1026. font-size: 24rpx;
  1027. font-family: PingFang SC;
  1028. font-weight: 500;
  1029. color: #FFFFFF;
  1030. background: rgba(0, 0, 0, .3);
  1031. border-radius: 22rpx;
  1032. position: absolute;
  1033. right: 30rpx;
  1034. bottom: 30rpx;
  1035. z-index: 10;
  1036. }
  1037. }
  1038. .message-box{
  1039. box-sizing: border-box;
  1040. width: 693rpx;
  1041. min-height: 84rpx;
  1042. background: #fff3ee;
  1043. border: 1px solid #FF6633;
  1044. box-shadow: 0px 4rpx 12rpx 0px rgba(255, 102, 51, 0.08);
  1045. border-radius: 16rpx;
  1046. position: fixed;
  1047. left: 50%;
  1048. transform: translateX(-50%);
  1049. bottom: 128rpx;
  1050. z-index: 99;
  1051. padding: 0 20rpx 0 30rpx;
  1052. .left{
  1053. width: 80%;
  1054. .text{
  1055. width: 90%;
  1056. font-size: 28rpx;
  1057. font-family: PingFang SC;
  1058. font-weight: 500;
  1059. color: #FF6633;
  1060. }
  1061. }
  1062. .btn{
  1063. width: 100rpx;
  1064. min-height: 48rpx;
  1065. line-height: 48rpx;
  1066. text-align: center;
  1067. font-size: 24rpx;
  1068. font-family: PingFang SC;
  1069. font-weight: 500;
  1070. color: #FFFFFF;
  1071. background: linear-gradient(135deg, #FF6633 0%, #FF6633 100%);
  1072. border-radius: 24rpx;
  1073. margin-left: 30rpx;
  1074. }
  1075. }
  1076. </style>