index.vue 57 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075
  1. <template>
  2. <view v-if="XCXIsSelect=='是'">
  3. <view>
  4. <view class="food_all">
  5. <!-- banner -->
  6. <swiper class="swiper" :autoplay="true" interval="2000" duration="500" :circular="true"
  7. style="width: 100%;height: 300rpx;">
  8. <swiper-item v-for="(item,index) in shopDet.shopBanner" :key='index'>
  9. <image :src="item" mode="scaleToFill" style="width: 100%;"></image>
  10. </swiper-item>
  11. </swiper>
  12. <view class="shop padding">
  13. <view class="flex justify-between">
  14. <view style="width: 500rpx;">
  15. <view class="text-xl text-bold u-line-1">{{shopDet.shopName}}
  16. </view>
  17. <view class="flex align-center margin-top-xs">
  18. <view style="color: #FD6416;font-weight: bold;font-size: 30rpx;">
  19. <u-icon name="star-fill" color="#FD6416" size="28"></u-icon>
  20. {{shopDet.shopScore?shopDet.shopScore:0}}
  21. </view>
  22. <view class="margin-left-xs text-gray">销量 {{shopDet.shopSales?shopDet.shopSales:0}}
  23. </view>
  24. <view class="margin-left-xs text-gray" v-if="shopDet.errandTime">
  25. 约{{shopDet.errandTime}}分钟
  26. </view>
  27. <view class="margin-left-xs text-gray" v-if="shopDet.minimumDelivery">
  28. {{shopDet.minimumDelivery}}元起送
  29. </view>
  30. </view>
  31. <view class="flex align-center margin-top-xs">
  32. <!-- <view style="color: #FCD202;margin-right: 8rpx;">{{shopDet.autoSendOrder==1?'商家配送':'平台配送'}}</view> -->
  33. <view style="margin-right: 8rpx;">{{shopDet.autoSendOrder==1?'商家配送:':'平台配送:'}}</view>
  34. <view class="text-gray" style="margin-right: 8rpx;">
  35. 配送费{{shopDet.errandMoney?shopDet.errandMoney:0}}元</view>
  36. <!-- <view class="lable text-gray" v-if="shopDet.enableFullReductionFlag==1">
  37. 不参与配送费满减</view> -->
  38. <view class="lable text-gray" v-if="shopDet.enableFullReductionFlag==0&&shopDet.exemptMinMoney">
  39. 满{{shopDet.exemptMinMoney}}元免配送费</view>
  40. </view>
  41. </view>
  42. <view>
  43. <image :src="shopDet.shopCover" class="radius"
  44. style="width: 110rpx;height: 110rpx;margin-top: 30rpx;">
  45. </image>
  46. </view>
  47. </view>
  48. <view class="flex align-center margin-top-xs" v-if="shopDet.shopNotice">
  49. <text style="width: 14%;">公告:</text>
  50. <u-notice-bar color="#AAAAAA" :speed="100" border-radius="30" padding="0rpx 0rpx"
  51. bg-color="#f5f5f5" style="width: 86%;" type="none" mode="horizontal" :volume-icon="false"
  52. :list="shopDet.shopNotice.split(',')"></u-notice-bar>
  53. </view>
  54. <view style="display: flex; margin-top: 3px;" class="flex flex-wrap align-center" @click="clickGong">
  55. <view v-for="(ite,ind) in huoListss" :key='ind' v-if="huoListss && ite.activityType!='1'">
  56. <view class="lable flex justify-center align-center" style="border-radius: 4rpx;background-color: #ffffff;color: red;box-sizing: border-box;">
  57. <text v-if="ite.activityType=='2'">时段</text>
  58. <text v-if="ite.activityType=='3'">满额</text>
  59. <text v-if="ite.activityType=='4'">全场</text>
  60. <text style="margin-left: 3px;">|</text>
  61. <text style="margin-left: 3px;">{{ite.activityName}}</text>
  62. </view>
  63. <!-- <view class="lable flex justify-center align-center"
  64. style="border-radius: 4rpx;border: 1rpx solid red;background-color: #ffffff;color: red;box-sizing: border-box;"
  65. >{{ite.activityName}}
  66. </view> -->
  67. </view>
  68. </view>
  69. <view class="margin-top-xs" style="width: 100%;height: 40rpx;" v-if="couponList.length>0">
  70. <scroll-view scroll-x="true" class="scroll-view_H">
  71. <view class="coupon-item flex align-center" v-for="(item,index) in couponList" :key="index"
  72. @click="coupons=true">
  73. <text>优惠券</text>
  74. <text style="margin-left: 3px;">|</text>
  75. <view style="margin-left: 3px;">¥</view>
  76. <view class="" style="font-weight: bold;font-size: 24rpx;margin-right: 10rpx;">
  77. {{item.money}}
  78. </view>
  79. <view style="margin-right: 20rpx;">满{{item.minMoney}}可用</view>
  80. <view style="font-weight: bold;">领</view>
  81. </view>
  82. <!-- <view class="flex align-center" style="width: 100%;height: 100%;">
  83. </view> -->
  84. </scroll-view>
  85. </view>
  86. </view>
  87. <!-- 食品 -->
  88. <view class="food">
  89. <!-- 店名地址 -->
  90. <view class="food_address">
  91. <view class="flex flex-sub bg justify-between padding-right-xl">
  92. <view @click="switchTab(1)" :class="current==1? 'select':''" class="tabBtn">
  93. <view class="title">全部商品</view>
  94. <view :class="current==1? 'active1':''"></view>
  95. </view>
  96. <view @click="switchTab(2)" :class="current==2? 'select':''" class="tabBtn">
  97. <view class="title">评价</view>
  98. <view :class="current==2? 'active1':''"></view>
  99. </view>
  100. <view @click="switchTab(3)" :class="current==3? 'select':''" class="tabBtn">
  101. <view class="title">商家</view>
  102. <view :class="current==3? 'active1':''"></view>
  103. </view>
  104. </view>
  105. <!-- <view class="flex Switch">
  106. <view @click="tabSwidth(1)" :class="orderType==1?'selSwitch':''">自取</view>
  107. <view @click="tabSwidth(2)" :class="orderType==2?'selSwitch':''">外卖</view>
  108. </view> -->
  109. <view>
  110. <!-- #ifdef MP-WEIXIN -->
  111. <image @click="goPindan()" src="../../../static/images/index/pindan.png"
  112. style="width: 160rpx;height: 64rpx;" mode=""></image>
  113. <!-- #endif -->
  114. </view>
  115. </view>
  116. <view class="VerticalBox" v-if="current==1">
  117. <scroll-view class="VerticalNav nav bg-gray" scroll-y scroll-with-animation
  118. :scroll-top="verticalNavTop" style="height:calc(100vh - 590upx)">
  119. <view style="font-size: 28upx;" class="cu-item text-lg"
  120. :class="index==tabCur?'cur':'text-gray'" v-for="(item,index) in dataList" :key="index"
  121. @tap="TabSelect" :data-id="index">
  122. {{item.classifyName}}
  123. </view>
  124. </scroll-view>
  125. <scroll-view class="VerticalMain" scroll-y scroll-with-animation
  126. style="height:calc(100vh - 590rpx)" :scroll-into-view="'main-'+mainCur"
  127. @scroll="VerticalMain">
  128. <view class="bg-white padding-sm margin-bottom-sm" v-for="(item,index) in dataList"
  129. v-if="item.goodsList.length" :key="index" :id="'main-'+index">
  130. <view class="flex justify-between padding-bottom-sm" @click="goDet(ite.goodsId)"
  131. v-for="(ite,ind) in item.goodsList" :key='ind'>
  132. <image :src="ite.goodsCover" mode=""
  133. style="width: 184rpx;height: 184rpx;border-radius: 10rpx;"></image>
  134. <view
  135. class="flex-sub margin-left-sm padding-tb-xs flex flex-direction justify-between">
  136. <view class="text-black text-lg text-bold" style="font-size: 30upx;">
  137. {{ite.goodsName}}
  138. </view>
  139. <view class="text-gray">
  140. 已售 {{ite.sales?ite.sales:0}}
  141. </view>
  142. <view class="text-gray text-sm u-line-2"
  143. style="overflow: hidden;line-clamp: 2;-webkit-line-clamp: 2;width: 100%;">
  144. {{ite.goodsDescribe?ite.goodsDescribe:''}}
  145. </view>
  146. <view class="flex justify-between">
  147. <view class="text-sm text-red">
  148. ¥ <text class="text-lg">{{ite.goodsMoney}}</text>
  149. </view>
  150. <image @click.stop="selSku(ite)" src="../../../static/images/index/add.png"
  151. mode="" style="width: 40rpx;height: 40rpx"></image>
  152. </view>
  153. </view>
  154. </view>
  155. <view style="height: 30px;"></view>
  156. </view>
  157. </scroll-view>
  158. <empty v-if="!dataList.length"></empty>
  159. </view>
  160. <view class="" v-if="current==2">
  161. <view class="flex margin-lr padding-tb-sm u-border-bottom" v-if="shopDet.shopScore">
  162. <view class="flex padding-right">
  163. <view class="text-sl" style="color: #FD6416;">{{shopDet.shopScore}}</view>
  164. <view class="flex flex-direction justify-around margin-left-sm">
  165. <view>商家评分</view>
  166. <view class="flex">
  167. <u-icon v-for="ite in shopDet.shopScore1" :key='ite' color="#FCD202"
  168. name="star-fill"></u-icon>
  169. </view>
  170. </view>
  171. </view>
  172. <view class="flex-sub flex justify-around u-border-left padding-left">
  173. <view class="flex flex-direction justify-around text-center">
  174. <view>好评</view>
  175. <view>{{EvaluateData.goodReputation?EvaluateData.goodReputation:0}}</view>
  176. </view>
  177. <view class="flex flex-direction justify-around text-center">
  178. <view>中评</view>
  179. <view>{{EvaluateData.mediumReview?EvaluateData.mediumReview:0}}</view>
  180. </view>
  181. <view class="flex flex-direction justify-around text-center">
  182. <view>差评</view>
  183. <view>{{EvaluateData.negativeComment?EvaluateData.negativeComment:0}}</view>
  184. </view>
  185. </view>
  186. </view>
  187. <view class="padding-tb-sm margin-lr">
  188. <u-button hover-class='none' @click="sel(0)" type="primary" shape="circle" size="mini"
  189. :plain="false" :custom-style="count==0?customStyle:customStyle1">全部评论</u-button>
  190. <u-button hover-class='none' @click="sel(1)" type="primary" shape="circle" size="mini"
  191. :plain="false" :custom-style="count==1?customStyle:customStyle1">
  192. 好评({{EvaluateData.goodReputation?EvaluateData.goodReputation:0}})</u-button>
  193. <u-button hover-class='none' @click="sel(2)" type="primary" shape="circle" size="mini"
  194. :plain="false" :custom-style="count==2?customStyle:customStyle1">
  195. 中评({{EvaluateData.mediumReview?EvaluateData.mediumReview:0}})</u-button>
  196. <u-button hover-class='none' @click="sel(3)" type="primary" shape="circle" size="mini"
  197. :plain="false" :custom-style="count==3?customStyle:customStyle1">
  198. 差评({{EvaluateData.negativeComment?EvaluateData.negativeComment:0}})</u-button>
  199. </view>
  200. <view class="padding-tb-sm margin-lr u-border-bottom" v-for="(item, index) in EvaluateList"
  201. :key='index'>
  202. <view class="flex justify-between align-center">
  203. <view class="flex align-center">
  204. <u-avatar :src="item.avatar" size="65"></u-avatar>
  205. <view class=" margin-left-sm" style="line-height: 46upx;">
  206. {{item.userName?item.userName:'匿名'}}
  207. </view>
  208. <view class="flex margin-left-sm">
  209. <u-icon v-for="ite in item.score" :key='ite' color="#FCD202" name="star-fill">
  210. </u-icon>
  211. </view>
  212. </view>
  213. <view>{{item.createTime}}</view>
  214. </view>
  215. <view class="margin-top-sm">{{item.evaluateMessage}}</view>
  216. <view class="pinglunImg" v-if="item.pictures!=undefined && item.pictures">
  217. <view class="pinglunImg-box flex justify-between flex-wrap">
  218. <image style="margin-bottom: 20rpx;"
  219. @click="yuanlan(item.pictures==undefined?[]:item.pictures.split(','),index2)"
  220. v-for="(item2,index2) in item.pictures==undefined?[]:item.pictures.split(',')"
  221. :src="item2" mode=""></image>
  222. <image style="margin-bottom: 20rpx;width: 160rpx;height: 0;" src="" mode=""></image>
  223. <image style="margin-bottom: 20rpx;width: 160rpx;height: 0;" src="" mode=""></image>
  224. </view>
  225. </view>
  226. <view class="margin-top-sm" v-if="item.shopReplyMessage">
  227. <view class="flex align-center">
  228. <view class=" flex align-center text-df" style="color: #999999;">
  229. <view class="text-df">商家回复:</view>{{item.shopReplyMessage}}
  230. </view>
  231. </view>
  232. </view>
  233. </view>
  234. <empty v-if="!EvaluateList.length"></empty>
  235. </view>
  236. <view class="margin-lr padding-bottom" v-if="current==3">
  237. <view class="flex align-center margin-top-sm">
  238. <view class="flex-sub">
  239. <view class="text-black text-lg text-bold">{{shopDet.shopName}}</view>
  240. <view class="margin-top-sm" @click="goMap">
  241. <u-icon name="map" size="28"></u-icon> {{shopDet.detailedAddress}}
  242. </view>
  243. </view>
  244. <image @click="call(shopDet.phone)" src="../../../static/images/index/phone.png"
  245. class="radius" style="width: 38rpx;height: 49rpx;">
  246. </image>
  247. </view>
  248. <image :src="shopDet.shopCover" class="radius margin-top-sm"
  249. style="width: 140rpx;height: 140rpx;">
  250. </image>
  251. <view class="text-black text-lg text-bold margin-top-xs">商家信息</view>
  252. <view class="text-black margin-top-xs text-df">
  253. 营业时间:{{shopDet.businessHours}}-{{shopDet.lockHours}}</view>
  254. <view class="text-black margin-top-xs text-df">商家品类:{{shopDet.shopTypeName}}</view>
  255. <view class="text-black margin-top-xs text-df">配送范围:{{shopDet.distributionDistance}}以内</view>
  256. <view class="text-black margin-top-xs text-df" v-if="shopDet.shopNotice">
  257. 公告:{{shopDet.shopNotice}}</view>
  258. <view class="text-black margin-top-xs text-df" v-else>公告:店铺开业啦!</view>
  259. </view>
  260. </view>
  261. <!-- 结算 -->
  262. <view class="settlement" @click="isPopupShow" v-if="current==1">
  263. <view class="settlement_img">
  264. <image src="../../../static/images/index/diancan.png" mode=""></image>
  265. <view class="settlement_hot">{{goodsNum}}</view>
  266. </view>
  267. <view class="settlement_le">
  268. <text>¥</text>{{totalPrice}}
  269. <text v-if="shopDet.minimumDelivery"
  270. style="margin-left: 10rpx;">{{shopDet.minimumDelivery}}元起送</text>
  271. </view>
  272. <view v-if="totalPrice>=shopDet.minimumDelivery" class="settlement_ri" @click.stop="goConfirm()">去结算
  273. </view>
  274. <view v-else class="settlement_ri1">去结算</view>
  275. </view>
  276. <!-- 购物车弹窗 -->
  277. <u-popup v-model="popupShow" mode="bottom" border-radius="20">
  278. <view class="padding">
  279. <view class="flex justify-between align-center margin-bottom-sm">
  280. <view class="text-bold text-black text-df">已选餐品</view>
  281. <view class="flex align-center">
  282. <image src="../../../static/images/index/delete.png" style="width: 28rpx;height: 31rpx;"
  283. mode=""></image>
  284. <text class="margin-left-xs" @click="empty">清空购物车</text>
  285. </view>
  286. </view>
  287. <scroll-view scroll-y='true' class="popup">
  288. <view v-for="(item,ind) in goodsList.orderGoodsList[0]" :key='ind'>
  289. <view class="flex align-center margin-tb-sm">
  290. <image :src="item.goodsPicture[0]"
  291. style="width: 96rpx;height: 96rpx;border-radius: 10rpx;">
  292. </image>
  293. <view class="margin-left-sm">
  294. <view>{{item.goodsName}}</view>
  295. <view v-if="item.skuMessage">{{item.skuMessage}}</view>
  296. </view>
  297. </view>
  298. <view class="flex justify-between align-center">
  299. <view class="text-bold text-sm">¥<text class="text-lg">{{item.goodsPrice}}</text>
  300. </view>
  301. <view class="flex align-center justify-between">
  302. <view @click.stop="noAdd(item,ind)">
  303. <image src="../../../static/images/index/jian.png"
  304. style="width: 54rpx;height: 54rpx;"></image>
  305. </view>
  306. <view class="text-center margin-lr-xs">{{item.goodsNum}}</view>
  307. <view @click.stop="add(item,ind)">
  308. <image src="../../../static/images/index/add.png"
  309. style="width: 50rpx;height: 50rpx;"></image>
  310. </view>
  311. </view>
  312. </view>
  313. </view>
  314. </scroll-view>
  315. </view>
  316. <view class="settlement1 margin-top-lg">
  317. <view class="settlement_img">
  318. <image src="../../../static/images/index/diancan.png" mode=""></image>
  319. <view class="settlement_hot">{{goodsNum}}</view>
  320. </view>
  321. <view class="settlement_le">
  322. <text>¥</text>{{totalPrice}}
  323. <text v-if="shopDet.minimumDelivery"
  324. style="margin-left: 10rpx;">{{shopDet.minimumDelivery}}元起送</text>
  325. </view>
  326. <view v-if="totalPrice>=shopDet.minimumDelivery" class="settlement_ri"
  327. @click.stop="goConfirm()">去结算</view>
  328. <view v-else class="settlement_ri1">去结算</view>
  329. </view>
  330. </u-popup>
  331. <!-- 选择规格弹窗 -->
  332. <u-popup v-model="skuShow" mode="center" :closeable='true' border-radius="20">
  333. <view style="width: 700rpx;">
  334. <view class="text-center text-lg text-bold padding-tb">{{goodsDet.goodsName}}</view>
  335. <view class="margin-top-sm padding-lr" v-for="(item,index) in attrList" :key="index">
  336. <view class="text-bold text-black">{{item.value}}</view>
  337. <view class="flex margin-tb-sm flex-wrap">
  338. <view v-for="(ite, ind) in item.detail" :key="ind" @click="skuSel(ite,index,ind)"
  339. class="margin-bottom-sm">
  340. <view class="skuBtn"
  341. :class="item.goodsId == index && item.attrId == ind?'active': ''">
  342. {{ite.name}}
  343. </view>
  344. </view>
  345. </view>
  346. </view>
  347. <view class="flex justify-between padding-lr padding-top">
  348. <view>
  349. <view class="text-xl text-bold text-black"><text class="text-sm">¥</text>{{price}}
  350. </view>
  351. <view class="detail_describe_text2">{{checkString}}</view>
  352. </view>
  353. <u-number-box v-model="value" :min="1" @change="valChange"></u-number-box>
  354. </view>
  355. <view class="detail_account_bottom padding">
  356. <view class="detail_account_bottom_le" @click="payment()">立即购买</view>
  357. <view class="detail_account_bottom_ri" @click="orderSel(2)">加入购物车</view>
  358. </view>
  359. </view>
  360. </u-popup>
  361. <!-- 优惠券弹窗 -->
  362. <!-- coupons -->
  363. <u-popup v-model="coupons" height="520rpx" mode="bottom" :closeable="true">
  364. <view class="yhq flex justify-center align-center">
  365. <view class="yhq-box">
  366. <view class="yhq-box-title">
  367. 优惠券
  368. </view>
  369. <view class="yhq-box-list">
  370. <scroll-view scroll-y="true" style="width: 100%;height: 100%;padding-bottom: 20rpx;">
  371. <view class="yhq-box-list-item flex justify-center align-center"
  372. v-for="(item,index) in couponList" :key="index">
  373. <view class="yhq-box-list-item-c flex justify-between align-center">
  374. <view class="yhq-box-list-item-c-l flex align-center">
  375. <image
  376. :src="item.couponPicture?item.couponPicture:'../../../static/logo.png'"
  377. style="width: 80rpx;height: 80rpx;border-radius: 20rpx;" mode="">
  378. </image>
  379. <view class="" style="margin-left: 20rpx;">
  380. <view class="">
  381. <text
  382. style="color: red;margin-right: 10rpx;">¥{{item.money}}</text>
  383. <text style="font-weight: bold;margin-right: 10rpx;">优惠券</text>
  384. (满{{item.minMoney}}元可用)
  385. </view>
  386. <view class="" style="font-size: 20rpx;color: gray;">
  387. 领取后{{item.endDate}}天内有效
  388. </view>
  389. </view>
  390. </view>
  391. <view class="yhq-box-list-item-c-r" style="color: red;"
  392. @click="lingqv(item.couponId)">
  393. 领取
  394. </view>
  395. </view>
  396. </view>
  397. </scroll-view>
  398. </view>
  399. </view>
  400. </view>
  401. </u-popup>
  402. <!-- 点击店铺公告栏弹框 -->
  403. <u-popup v-model="popupGong" mode="center" border-radius="20">
  404. <view style="width: 700rpx;height: 592rpx;">
  405. <view style="width: 500rpx;display: flex;">
  406. <view class="gong_img">
  407. <image :src="shopDet.shopCover" class="radius"
  408. style="width: 110rpx;height: 110rpx;">
  409. </image>
  410. </view>
  411. <view class="gong_name">{{shopDet.shopName}}</view>
  412. <view class="flex align-center margin-top-xs gong_pei">
  413. <!-- <view style="color: #FCD202;margin-right: 8rpx;">{{shopDet.autoSendOrder==1?'商家配送':'平台配送'}}</view> -->
  414. <view style="margin-right: 8rpx;">{{shopDet.autoSendOrder==1?'商家配送:':'平台配送:'}}</view>
  415. <view class="text-gray" style="margin-right: 8rpx;">
  416. 配送费{{shopDet.errandMoney?shopDet.errandMoney:0}}元</view>
  417. <!-- <view class="lable text-gray" v-if="shopDet.enableFullReductionFlag==1">
  418. 不参与配送费满减</view> -->
  419. <view class="lable text-gray" v-if="shopDet.enableFullReductionFlag==0&&shopDet.exemptMinMoney">
  420. 满{{shopDet.exemptMinMoney}}元免配送费</view>
  421. </view>
  422. <view class="gong_line"></view>
  423. </view>
  424. <view class=" align-center margin-top-xs" style="margin-top: 35rpx;">
  425. <view v-for="(ite,ind) in gongHuo" :key='ind'>
  426. <view class=" flex align-center" style="margin-left: 40rpx;margin-top: 4px;" v-for="(ite2,ind2) in ite.activityInGroups" :key='ind2'>
  427. <text style="border-radius: 4rpx;background-color: #ffffff;color: red;box-sizing: border-box;border: 1px solid rgba(215, 55, 49, 1);" v-if="ite.activityType=='2'">时段</text>
  428. <text style="border-radius: 4rpx;background-color: #ffffff;color: red;box-sizing: border-box;border: 1px solid rgba(215, 55, 49, 1);" v-if="ite.activityType=='3'">满额</text>
  429. <text style="border-radius: 4rpx;background-color: #ffffff;color: red;box-sizing: border-box;border: 1px solid rgba(215, 55, 49, 1);" v-if="ite.activityType=='4'">全场</text>
  430. <text style="margin-left: 6px;">{{ite2.activityTitle}}</text>
  431. <view class="gong_huo" style="margin-left: 6px;">
  432. <text v-if="ite2.suitType=='1'">皆适用</text>
  433. <text v-if="ite2.suitType=='2'">仅针对第一次下单</text>
  434. <text v-if="ite2.limitType=='1'">无数量限制</text>
  435. <text v-if="ite2.limitType=='2'">每天限使用{{ite2.limitValue}}次</text>
  436. </view>
  437. </view>
  438. </view>
  439. <!-- <view v-for="(ite,ind) in gongHuo" :key='ind' v-if="ite.activityType=='3'">
  440. <view class=" flex align-center" style="margin-left: 40rpx;margin-top: 4px;" v-for="(ite2,ind2) in ite2.activityInGroups" :key='ind2'>
  441. <text style="border-radius: 4rpx;background-color: #ffffff;color: red;box-sizing: border-box;border: 1px solid rgba(215, 55, 49, 1);">时段</text>
  442. <text style="margin-left: 6px;">{{ite2.activityTitle}}</text>
  443. <view class="gong_huo" style="margin-left: 6px;">
  444. <text v-if="ite2.suitType=='1'">无限制</text>
  445. <text v-if="ite2.suitType=='2'">仅针对第一次下单</text>
  446. </view>
  447. </view>
  448. </view>
  449. <view v-for="(ite,ind) in gongHuo" :key='ind' v-if="ite.activityType=='4'">
  450. <view class=" flex align-center" style="margin-left: 40rpx;margin-top: 4px;" v-for="(ite2,ind2) in ite2.activityInGroups" :key='ind2'>
  451. <text style="border-radius: 4rpx;background-color: #ffffff;color: red;box-sizing: border-box;border: 1px solid rgba(215, 55, 49, 1);">时段</text>
  452. <text style="margin-left: 6px;">{{ite2.activityTitle}}</text>
  453. <view class="gong_huo" style="margin-left: 6px;">
  454. <text v-if="ite2.suitType=='1'">无限制</text>
  455. <text v-if="ite2.suitType=='2'">仅针对第一次下单</text>
  456. </view>
  457. </view>
  458. </view> -->
  459. </view>
  460. <view class="flex align-center margin-top-xs" v-if="shopDet.shopNotice" style="margin-top: 35rpx;margin-left: 40rpx;">
  461. <text style="width: 14%;">公告:</text>
  462. <view>{{shopDet.shopNotice}}</view>
  463. </view>
  464. </view>
  465. </u-popup>
  466. </view>
  467. <view class="hintPopul" v-if="shopDet&&shopDet.putawayFlag==1">
  468. <view class="content_">
  469. <image src="../../../static/images/index/shop.png" style="width: 200rpx;height: 180rpx;">
  470. </image>
  471. <view class="text-xl text-bold">店铺打烊啦</view>
  472. <view class="hintText margin-top-sm text-gray">现在店铺已经打烊了,营业时间</view>
  473. <view class="margin-top-xs text-gray margin-bottom">{{shopDet.businessHours}}-{{shopDet.lockHours}}
  474. </view>
  475. <view class="Btns" @click="goBack()">知道了</view>
  476. </view>
  477. </view>
  478. </view>
  479. </view>
  480. </template>
  481. <script>
  482. import empty from '@/components/empty.vue'
  483. export default {
  484. components: {
  485. empty
  486. },
  487. data() {
  488. return {
  489. maskCustomStyle: {
  490. background: 'rgba(0,0,0,0.1)'
  491. },
  492. hdStyle: {
  493. background: '#F5F5F5',
  494. },
  495. customStyle: {
  496. color: '#333333',
  497. background: '#FCD202',
  498. marginRight: '20rpx',
  499. border: 0
  500. },
  501. customStyle1: {
  502. color: '#333333',
  503. background: '#F2F2F2',
  504. marginRight: '20rpx',
  505. border: 0
  506. },
  507. current: 1,
  508. loading: false, // 是否显示骨架屏组件
  509. tabCur: 0,
  510. mainCur: 0,
  511. verticalNavTop: 0,
  512. load: true,
  513. dataList: [],
  514. shopDet: {},
  515. shopList: [],
  516. city: '西安',
  517. lat: '',
  518. lng: '',
  519. shopName: '',
  520. page: 1,
  521. limit: 10,
  522. evaluatePage: 1,
  523. evaluateLimit: 10,
  524. show: true,
  525. totalPrice: 0,
  526. goodsNum: 0,
  527. goodsList: {
  528. orderGoodsList: [
  529. []
  530. ]
  531. },
  532. popupShow: false,
  533. skuShow: false,
  534. popupGong: false,//店铺公告弹框
  535. gongHuo:[],//店铺公告活动
  536. userId: '',
  537. hintShow: true, //
  538. shouquan: 0,
  539. orderType: 2,
  540. value: 1,
  541. goodsDet: {},
  542. skuId: '',
  543. skuMessage: '',
  544. skuList: [],
  545. attrList: [],
  546. checkString: '',
  547. checkStateList: [],
  548. CheckattrValue: false,
  549. price: 0,
  550. echoSkuList: [],
  551. echoSku: [],
  552. isEchoSku: {},
  553. shopId: '',
  554. lng: '',
  555. lat: '',
  556. commentList: [],
  557. EvaluateList: [],
  558. EvaluateData: {},
  559. grade: '',
  560. count: 0,
  561. orderId: '',
  562. isTrue: false,
  563. XCXIsSelect: '否',
  564. couponList: [], //优惠券列表
  565. coupons: false,
  566. huoListss:[],//活动
  567. }
  568. },
  569. onLoad(option) {
  570. if(option.huoListss){
  571. this.huoListss = JSON.parse(decodeURIComponent(option.huoListss))
  572. }
  573. this.XCXIsSelect = this.$queue.getData('XCXIsSelect');
  574. if (this.XCXIsSelect == '否') {
  575. // this.getGuize()
  576. uni.setNavigationBarTitle({
  577. title: '隐私政策'
  578. });
  579. } else {
  580. uni.setNavigationBarTitle({
  581. title: '店铺详情'
  582. });
  583. }
  584. let that = this
  585. that.shopId = option.shopId
  586. uni.showLoading({
  587. title: '加载中'
  588. })
  589. // #ifndef H5
  590. uni.getLocation({
  591. type: 'gcj02', //返回可以用于uni.openLocation的经纬度
  592. success: function(res) {
  593. that.lat = res.latitude;
  594. that.lng = res.longitude;
  595. }
  596. });
  597. that.getData()
  598. // #endif
  599. // #ifdef H5
  600. uni.getLocation({
  601. type: 'gcj02', //返回可以用于uni.openLocation的经纬度
  602. success: function(res) {
  603. console.log(res, '经纬度')
  604. that.lat = res.latitude;
  605. that.lng = res.longitude;
  606. that.getData()
  607. }
  608. });
  609. that.getData()
  610. // #endif
  611. that.orderId = uni.getStorageSync('orderId') ? uni.getStorageSync('orderId') : ''
  612. },
  613. onHide() {
  614. uni.removeStorageSync('types')
  615. },
  616. onShow() {
  617. this.orderId = uni.getStorageSync('orderId') ? uni.getStorageSync('orderId') : ''
  618. if (this.orderId) {
  619. this.getOrderDetail();
  620. }
  621. this.userId = uni.getStorageSync('userId')
  622. this.getOrderList()
  623. this.getcouponList()
  624. },
  625. onShareAppMessage(res) { //发送给朋友
  626. return {
  627. title: this.shopDet.shopName,
  628. path: '/pages/index/index?shopId=' + this.shopDet.shopId,
  629. imageUrl: this.shopDet.shopCover,
  630. }
  631. },
  632. onShareTimeline(res) { //分享到朋友圈
  633. return {
  634. title: this.shopDet.shopName,
  635. path: '/pages/index/index?shopId=' + this.shopDet.shopId,
  636. imageUrl: this.shopDet.shopCover,
  637. }
  638. },
  639. methods: {
  640. //点击店铺公告弹框
  641. clickGong(){
  642. this.getHuoList()
  643. this.popupGong=true
  644. },
  645. //获取店铺活动信息
  646. getHuoList(){
  647. let data = {
  648. shopId: this.shopId,
  649. }
  650. this.$Request.get(`/app/activity-shop/shop-activity-group/${this.shopId}`, data).then(res => {
  651. if (res.code == 0) {
  652. this.gongHuo=res.data.activityTypeGroups
  653. }
  654. });
  655. },
  656. //领取优惠券
  657. lingqv(couponId, needIntegral) {
  658. let that = this
  659. let data = {
  660. couponId: couponId,
  661. }
  662. that.$Request.postT("/app/coupon/buyCoupon", data).then(res => {
  663. if (res.code == 0) {
  664. uni.showToast({
  665. title: '领取成功'
  666. })
  667. that.coupons = false
  668. } else {
  669. uni.showToast({
  670. title: res.msg,
  671. icon: 'none'
  672. })
  673. }
  674. });
  675. },
  676. //获取商家优惠券
  677. getcouponList() {
  678. // couponList
  679. let data = {
  680. shopId: this.shopId,
  681. }
  682. this.$Request.get("/app/coupon/seleteAllCoupon", data).then(res => {
  683. if (res.code == 0 && res.data) {
  684. this.couponList = res.data
  685. }
  686. });
  687. },
  688. // 预览图片
  689. yuanlan(arr, index) {
  690. uni.previewImage({
  691. urls: arr,
  692. current: index
  693. })
  694. },
  695. goBack() {
  696. uni.navigateBack({
  697. })
  698. },
  699. goNav(url) {
  700. uni.navigateTo({
  701. url
  702. })
  703. },
  704. switchTab(e) {
  705. // this.page = 1
  706. this.current = e
  707. if (this.current == 1) {
  708. this.getData()
  709. } else if (this.current == 2) {
  710. this.evaluatePage = 1;
  711. this.getEvaluateList()
  712. } else if (this.current == 3) {
  713. }
  714. },
  715. sel(e) {
  716. this.grade = e
  717. this.count = e
  718. this.evaluatePage = 1
  719. this.getEvaluateList()
  720. },
  721. // 获取评论列表
  722. getEvaluateList() {
  723. let data = {
  724. shopId: this.shopId,
  725. page: this.evaluatePage,
  726. limit: this.evaluateLimit,
  727. grade: this.grade
  728. }
  729. this.$Request.get("/app/goods/selectEvaluateByShopId", data).then(res => {
  730. if (res.code == 0 && res.data) {
  731. this.EvaluateData = res.data
  732. if (this.evaluatePage == 1) {
  733. this.EvaluateList = res.data.pageUtils.list
  734. } else {
  735. this.EvaluateList = [...this.EvaluateList, ...res.data.pageUtils.list]
  736. }
  737. }
  738. });
  739. },
  740. // 获取店铺信息
  741. getData() {
  742. let data = {
  743. shopId: this.shopId,
  744. lng: this.lng,
  745. lat: this.lat
  746. }
  747. this.$Request.get("/app/goods/selectGoodsList", data).then(res => {
  748. if (res.code == 0 && res.data) {
  749. this.dataList = res.data.list
  750. this.shopDet = res.data.goodsShop
  751. for (var i = 0; i < this.dataList.length; i++) {
  752. this.dataList[i].id = i
  753. }
  754. this.shopDet.shopScore1 = Math.floor(this.shopDet.shopScore)
  755. this.shopDet.errandTime = Math.round(this.shopDet.errandTime)
  756. if (this.shopDet.shopBanner) {
  757. this.shopDet.shopBanner = this.shopDet.shopBanner.split(',')
  758. }
  759. this.shopDet.shopScore = this.shopDet.shopScore.toFixed(2)
  760. if (this.shopDet.distributionDistance < 1000) {
  761. this.shopDet.distributionDistance = '<1000m'
  762. } else {
  763. this.shopDet.distributionDistance = Number(this.shopDet.distributionDistance / 1000) +
  764. 'km'
  765. }
  766. uni.setNavigationBarTitle({
  767. title: this.shopDet.shopName
  768. })
  769. }
  770. uni.hideLoading()
  771. });
  772. },
  773. getEchoOrder() {
  774. let data = {
  775. shopId: this.shopId,
  776. goodsId: this.goodsDet.goodsId
  777. }
  778. this.$Request.get("/app/order/echoOrder", data).then(res => {
  779. if (res.code == 0 && res.data.length) {
  780. this.echoSkuList = res.data
  781. if (res.data[0].skuMessage) {
  782. this.echoSku = res.data[0].skuMessage.split(',')
  783. }
  784. }
  785. });
  786. },
  787. // 弹窗展示商品详情
  788. selSku(item) {
  789. this.checkStateList = []
  790. this.checkString = ''
  791. this.attrList = [];
  792. this.skuId = '';
  793. this.skuMessage = '';
  794. this.$Request.get("/app/goods/selectGoodsById?goodsId=" + item.goodsId).then(res => {
  795. uni.hideLoading()
  796. if (res.code == 0) {
  797. this.goodsDet = res.data
  798. if (this.goodsDet.goodsLabel) {
  799. this.goodsDet.goodsLabel = this.goodsDet.goodsLabel.split(',')
  800. }
  801. if (this.goodsDet.goodsPicture) {
  802. this.goodsDet.goodsPicture = this.goodsDet.goodsPicture.split(',')
  803. }
  804. this.price = this.goodsDet.goodsMoney
  805. this.skuList = this.goodsDet.sku
  806. this.getEchoOrder()
  807. if (!this.skuList.length) {
  808. let that = this
  809. setTimeout(function() {
  810. that.orderSel(2)
  811. }, 500)
  812. } else {
  813. if (this.goodsDet.attr.length) {
  814. this.attrList = this.goodsDet.attr[0] ? this.goodsDet.attr[0].attrValue : []
  815. } else {
  816. this.skuId = this.goodsDet.sku[0].id
  817. }
  818. this.attrList.forEach(res => {
  819. let data = {
  820. name: ''
  821. }
  822. this.checkStateList.push(data);
  823. let detail = [];
  824. if (res.detail.length > 0) {
  825. res.detail.split(',').forEach(d => {
  826. let data = {
  827. name: '',
  828. state: ''
  829. }
  830. data.name = d;
  831. detail.push(data);
  832. });
  833. res.detail = detail;
  834. }
  835. })
  836. this.skuShow = true
  837. }
  838. }
  839. });
  840. },
  841. // 选择规格
  842. skuSel(item, index, ind) {
  843. this.attrList[index].goodsId = index
  844. this.attrList[index].attrId = ind
  845. this.checkStateList[index].name = item.name;
  846. this.checkString = '';
  847. this.checkStateList.forEach(d => {
  848. if (d.name) {
  849. if (this.checkString) {
  850. this.checkString = this.checkString + ',' + d.name;
  851. } else {
  852. this.checkString = d.name;
  853. }
  854. }
  855. });
  856. for (var i = 0; i < this.skuList.length; i++) {
  857. let d = this.skuList[i];
  858. if (d.detailJson == this.checkString) {
  859. console.log(d.detailJson, this.checkString)
  860. // if (d.stock > 0) {
  861. this.skuId = d.id
  862. this.skuMessage = d.detailJson
  863. this.price = d.skuPrice
  864. this.CheckattrValue = true;
  865. // } else {
  866. // this.$queue.showToast('库存不足请选择其他规格')
  867. // }
  868. break
  869. } else {
  870. this.CheckattrValue = false;
  871. }
  872. }
  873. },
  874. valChange(e) {
  875. console.log('当前值为: ' + e.value)
  876. this.value = e.value
  877. },
  878. // 立即购买
  879. payment() {
  880. if (!this.userId) {
  881. uni.navigateTo({
  882. url: '/pages/public/login'
  883. })
  884. return
  885. }
  886. if (this.attrList.length) {
  887. if (this.checkString == '' || !this.CheckattrValue) {
  888. this.$queue.showToast('请选择正确的商品规格');
  889. return;
  890. }
  891. }
  892. let goodstr1 = 0 //商品库的 必须次数
  893. let goodstr2 = 0 //购物车的 必须次数
  894. let regex = new RegExp('必选', 'g');
  895. let dataList = JSON.stringify(this.dataList)
  896. if (dataList.match(regex)) {
  897. goodstr1 = dataList.match(regex).length
  898. if (dataList.indexOf('必选') != -1) { //检测商品是否存在必选
  899. let goodsList = JSON.stringify(this.goodsDet)
  900. if (goodsList.match(regex)) {
  901. goodstr2 = goodsList.match(regex).length
  902. if (goodstr1 == goodstr2) { //检查购物车商品是否存在必须
  903. let data = {
  904. goodsId: this.goodsDet.goodsId,
  905. skuMessage: this.skuMessage,
  906. skuId: this.skuId,
  907. num: this.value,
  908. orderType: this.orderType,
  909. shopId: this.shopId,
  910. }
  911. this.$Request.post("/app/order/buyGoods", data).then(res => {
  912. if (res.code == 0) {
  913. this.skuShow = false
  914. uni.navigateTo({
  915. url: '/pages/index/shop/payOrder?orderId=' + res.data + '&orderType=' + this
  916. .orderType
  917. })
  918. } else {
  919. this.$queue.showToast(res.msg);
  920. }
  921. })
  922. } else {
  923. uni.showToast({
  924. title: "有" + goodstr1 + "个必选商品,请选择后结算",
  925. icon: "none"
  926. })
  927. return
  928. }
  929. } else {
  930. uni.showToast({
  931. title: "有" + goodstr1 + "个必选商品,请选择后结算",
  932. icon: "none"
  933. })
  934. return
  935. }
  936. }
  937. } else {
  938. let data = {
  939. goodsId: this.goodsDet.goodsId,
  940. skuMessage: this.skuMessage,
  941. skuId: this.skuId,
  942. num: this.value,
  943. orderType: this.orderType,
  944. shopId: this.shopId,
  945. }
  946. this.$Request.post("/app/order/buyGoods", data).then(res => {
  947. if (res.code == 0) {
  948. this.skuShow = false
  949. uni.navigateTo({
  950. url: '/pages/index/shop/payOrder?orderId=' + res.data + '&orderType=' + this
  951. .orderType
  952. })
  953. } else {
  954. this.$queue.showToast(res.msg);
  955. }
  956. })
  957. }
  958. },
  959. // 加入购物车
  960. orderSel(e) {
  961. if (!this.userId) {
  962. uni.navigateTo({
  963. url: '/pages/public/login'
  964. })
  965. return
  966. }
  967. if (this.attrList.length) {
  968. if (this.checkString == '' || !this.CheckattrValue) {
  969. this.$queue.showToast('请选择正确的商品规格');
  970. return;
  971. }
  972. }
  973. // if (this.echoSku.length) {
  974. // this.echoSkuList.forEach(res => {
  975. // if (res.skuMessage == this.skuMessage) {
  976. // this.isEchoSku = res
  977. // }
  978. // })
  979. // if (JSON.stringify(this.isEchoSku) != "{}") {
  980. // let data = {
  981. // orderGoodsId: this.isEchoSku.id,
  982. // type: 1,
  983. // num: this.value,
  984. // shopId: this.shopId,
  985. // }
  986. // this.$Request.get("/app/order/updateGoodsNum", data).then(res => {
  987. // if (res.code == 0) {
  988. // // setTimeout(function() {
  989. // this.$queue.showToast('添加成功');
  990. // this.skuShow = false
  991. // this.getOrderList()
  992. // // },1000)
  993. // } else {
  994. // this.$queue.showToast(res.msg);
  995. // }
  996. // });
  997. // return
  998. // }
  999. // }
  1000. let data = {
  1001. goodsId: this.goodsDet.goodsId,
  1002. skuMessage: this.skuMessage,
  1003. skuId: this.skuId,
  1004. num: this.value,
  1005. shopId: this.shopId,
  1006. }
  1007. let url = ''
  1008. if (this.types == 1) {
  1009. url = '/app/order/joinOrder'
  1010. } else {
  1011. url = '/app/order/insertOrder'
  1012. }
  1013. this.$Request.post('/app/order/insertOrder', data).then(res => {
  1014. if (res.code == 0) {
  1015. this.$queue.showToast('添加成功');
  1016. this.skuShow = false
  1017. this.getOrderList()
  1018. } else {
  1019. this.$queue.showToast(res.msg);
  1020. }
  1021. })
  1022. },
  1023. // 切换外卖/自提
  1024. tabSwidth(e) {
  1025. this.orderType = e
  1026. this.getOrderList()
  1027. },
  1028. // 展示购物车弹窗
  1029. isPopupShow() {
  1030. if (this.goodsList && this.goodsList.orderGoodsList && this.goodsList.orderGoodsList[0].length > 0) {
  1031. this.popupShow = true
  1032. } else {
  1033. uni.showToast({
  1034. title: '请先添加商品',
  1035. icon: "none"
  1036. })
  1037. }
  1038. },
  1039. // 添加数量
  1040. add(item, index) {
  1041. // this.count++;
  1042. this.goodsList.orderGoodsList[0][index].goodsNum++
  1043. let data = {
  1044. orderGoodsId: this.goodsList.orderGoodsList[0][index].id,
  1045. type: 1,
  1046. num: 1,
  1047. shopId: this.shopId
  1048. }
  1049. this.$Request.get("/app/order/updateGoodsNum", data).then(res => {
  1050. if (res.code == 0) {
  1051. this.getOrderList()
  1052. } else {
  1053. this.$queue.showToast(res.msg);
  1054. this.goodsList.orderGoodsList[0][index].goodsNum--
  1055. }
  1056. });
  1057. },
  1058. // 减少数量
  1059. noAdd(item, index) {
  1060. this.goodsList.orderGoodsList[0][index].goodsNum--
  1061. // this.count--;
  1062. let data = {
  1063. orderGoodsId: this.goodsList.orderGoodsList[0][index].id,
  1064. type: 2,
  1065. num: 1,
  1066. shopId: this.shopId
  1067. }
  1068. this.$Request.get("/app/order/updateGoodsNum", data).then(res => {
  1069. if (res.code == 0) {
  1070. this.getOrderList()
  1071. }
  1072. });
  1073. },
  1074. // 清空购物车
  1075. empty() {
  1076. let data = {
  1077. shopId: this.shopId,
  1078. }
  1079. this.$Request.post("/app/order/emptyShoppingTrolley", data).then(res => {
  1080. if (res.code == 0) {
  1081. this.totalPrice = 0
  1082. this.goodsNum = 0
  1083. this.goodsList = {
  1084. orderGoodsList: [
  1085. []
  1086. ]
  1087. }
  1088. this.echoSkuList = []
  1089. this.echoSku = []
  1090. this.getOrderList()
  1091. this.popupShow = false
  1092. this.getEchoOrder()
  1093. }
  1094. });
  1095. },
  1096. // 获取购物车商品列表
  1097. getOrderList() {
  1098. let data = {
  1099. shopId: this.shopId,
  1100. page: 1,
  1101. limit: 1000,
  1102. status: 1,
  1103. // orderType: this.orderType
  1104. }
  1105. this.$Request.get("/app/order/selectAllOrderList", data).then(res => {
  1106. if (res.code == 0 && res.data.pageUtils.list.length) {
  1107. this.goodsList = res.data.pageUtils.list[0]
  1108. if (this.goodsList && this.goodsList.orderGoodsList && this.goodsList.orderGoodsList[0]) {
  1109. this.totalPrice = res.data.money
  1110. this.goodsNum = 0
  1111. this.goodsList.orderGoodsList[0].forEach(res => {
  1112. if (res.goodsPicture) {
  1113. res.goodsPicture = res.goodsPicture.split(',')
  1114. }
  1115. this.goodsNum += res.goodsNum
  1116. })
  1117. if (!this.goodsList.orderGoodsList[0].length) {
  1118. this.popupShow = false
  1119. }
  1120. }
  1121. }
  1122. uni.hideLoading()
  1123. });
  1124. },
  1125. // 跳转商品详情
  1126. goDet(id) {
  1127. uni.navigateTo({
  1128. url: '/pages/index/shop/goodsDet?goodsId=' + id + '&shopId=' + this.shopId + '&orderType=' +
  1129. this.orderType
  1130. })
  1131. },
  1132. // 去结算
  1133. goConfirm() {
  1134. if (!this.userId) {
  1135. uni.navigateTo({
  1136. url: '/pages/public/login'
  1137. })
  1138. return
  1139. }
  1140. let goodstr1 = 0 //商品库的 必须次数
  1141. let goodstr2 = 0 //购物车的 必须次数
  1142. // let aa=[]
  1143. // let bb=[]
  1144. let regex = new RegExp('必选', 'g');
  1145. if (this.goodsList && this.goodsList.orderGoodsList[0].length > 0) {
  1146. // aa=this.dataList.map(item => item.goodsList)
  1147. // bb=aa.map(item => item)
  1148. let dataList = JSON.stringify(this.dataList)
  1149. if (dataList.match(regex)) {
  1150. goodstr1 = dataList.match(regex).length
  1151. if (dataList.indexOf('必选') != -1) { //检测商品是否存在必选
  1152. let goodsList = JSON.stringify(this.goodsList.orderGoodsList)
  1153. if (goodsList.match(regex)) {
  1154. goodstr2 = goodsList.match(regex).length
  1155. if (goodstr1 == goodstr2) { //检查购物车商品是否存在必须
  1156. uni.navigateTo({
  1157. url: '/pages/index/shop/confirmOrder?shopId=' + this.shopId +
  1158. '&orderType=' + this
  1159. .orderType
  1160. })
  1161. } else {
  1162. uni.showToast({
  1163. title: "有" + goodstr1 + "个必选商品,请选择后结算",
  1164. icon: "none"
  1165. })
  1166. return
  1167. }
  1168. } else {
  1169. uni.showToast({
  1170. title: "有" + goodstr1 + "个必选商品,请选择后结算",
  1171. icon: "none"
  1172. })
  1173. return
  1174. }
  1175. }
  1176. } else {
  1177. uni.navigateTo({
  1178. url: '/pages/index/shop/confirmOrder?shopId=' + this.shopId + '&orderType=' + this
  1179. .orderType
  1180. })
  1181. }
  1182. } else {
  1183. uni.showToast({
  1184. title: '请先添加商品',
  1185. icon: "none"
  1186. })
  1187. }
  1188. },
  1189. TabSelect(e) {
  1190. this.tabCur = e.currentTarget.dataset.id;
  1191. this.mainCur = e.currentTarget.dataset.id;
  1192. this.verticalNavTop = (e.currentTarget.dataset.id - 1) * 50
  1193. },
  1194. VerticalMain(e) {
  1195. let that = this;
  1196. let tabHeight = 0;
  1197. if (this.load) {
  1198. for (let i = 0; i < this.dataList.length; i++) {
  1199. let view = uni.createSelectorQuery().select("#main-" + this.dataList[i].id);
  1200. view.fields({
  1201. size: true
  1202. }, data => {
  1203. this.dataList[i].top = tabHeight;
  1204. tabHeight = tabHeight + data.height;
  1205. this.dataList[i].bottom = tabHeight;
  1206. }).exec();
  1207. }
  1208. this.load = false
  1209. }
  1210. let scrollTop = e.detail.scrollTop;
  1211. for (let i = 0; i < this.dataList.length; i++) {
  1212. if (scrollTop > this.dataList[i].top && scrollTop < this.dataList[i].bottom) {
  1213. this.verticalNavTop = (this.dataList[i].id - 1) * 50
  1214. this.tabCur = this.dataList[i].id
  1215. return false
  1216. }
  1217. }
  1218. },
  1219. // 打电话
  1220. call(e) {
  1221. uni.makePhoneCall({
  1222. phoneNumber: e
  1223. });
  1224. },
  1225. // 点击调起地图查看位置
  1226. goMap() {
  1227. //查看位置需要传经纬度才能执行
  1228. let that = this
  1229. uni.authorize({
  1230. scope: 'scope.userLocation',
  1231. success(res) {
  1232. uni.openLocation({
  1233. latitude: that.shopDet.shopLat,
  1234. longitude: that.shopDet.shopLng,
  1235. success: function() {}
  1236. });
  1237. },
  1238. fail(err) {
  1239. }
  1240. })
  1241. },
  1242. getOrderDetail() {
  1243. this.$Request.getT('/app/order/selectOrderById?orderId=' + this.orderId).then(res => {
  1244. if (res.code == 0 && res.data) {
  1245. if (res.data.isPay && res.data.isPay == 1) {
  1246. this.orderId = '';
  1247. uni.removeStorageSync('orderId')
  1248. }
  1249. }
  1250. });
  1251. },
  1252. goPindan() {
  1253. if (!this.userId) {
  1254. uni.navigateTo({
  1255. url: '/pages/public/login'
  1256. })
  1257. return
  1258. }
  1259. if (uni.getStorageSync('orderId')) {
  1260. uni.navigateTo({
  1261. url: '/pages/index/shop/pindanDet?shopId=' + this.shopId + '&orderId=' + uni
  1262. .getStorageSync('orderId')
  1263. })
  1264. } else {
  1265. let data = {
  1266. shopId: this.shopId,
  1267. }
  1268. this.$Request.post("/app/order/shareTheBill", data).then(res => {
  1269. if (res.code == 0) {
  1270. uni.navigateTo({
  1271. url: '/pages/index/shop/pindanDet?shopId=' + this.shopId + '&orderId=' +
  1272. res.data
  1273. })
  1274. }
  1275. });
  1276. }
  1277. }
  1278. },
  1279. onReachBottom: function() {
  1280. if (this.current == 2) {
  1281. this.evaluatePage = this.evaluatePage + 1;
  1282. this.getEvaluateList()
  1283. }
  1284. },
  1285. }
  1286. </script>
  1287. <style scoped lang="scss">
  1288. page {
  1289. background-color: #FFFFFF;
  1290. }
  1291. .yhq {
  1292. width: 100%;
  1293. height: 520rpx;
  1294. background-color: #F5F5F5;
  1295. overflow-y: hidden;
  1296. .yhq-box {
  1297. width: 686rpx;
  1298. height: 500rpx;
  1299. // background-color: red;
  1300. .yhq-box-title {
  1301. width: 100%;
  1302. text-align: center;
  1303. font-weight: bold;
  1304. }
  1305. .yhq-box-list {
  1306. width: 100%;
  1307. height: auto;
  1308. height: 460rpx;
  1309. margin-top: 30rpx;
  1310. .yhq-box-list-item {
  1311. width: 100%;
  1312. height: 120rpx;
  1313. border-radius: 24rpx;
  1314. background-color: #FFFFFF;
  1315. margin-bottom: 20rpx;
  1316. }
  1317. .yhq-box-list-item-c {
  1318. width: 646rpx;
  1319. height: 100%;
  1320. }
  1321. }
  1322. }
  1323. }
  1324. .scroll-view_H {
  1325. width: 100%;
  1326. white-space: nowrap;
  1327. }
  1328. .coupon-item {
  1329. display: inline-block;
  1330. height: 46rpx;
  1331. margin-right: 20rpx;
  1332. border: 1px solid red;
  1333. border-radius: 10rpx;
  1334. padding: 0rpx 10rpx 0rpx 10rpx;
  1335. font-size: 20rpx;
  1336. color: red;
  1337. line-height: 44rpx;
  1338. view {
  1339. display: inline-block;
  1340. }
  1341. }
  1342. .pinglunImg {
  1343. width: 100%;
  1344. margin-top: 10rpx;
  1345. }
  1346. .pinglunImg-box {
  1347. width: 100%;
  1348. image {
  1349. // margin-left: 10rpx;
  1350. width: 160upx;
  1351. height: 160upx;
  1352. border-radius: 10rpx;
  1353. }
  1354. }
  1355. .hintPopul {
  1356. width: 100%;
  1357. height: 100vh;
  1358. position: fixed;
  1359. top: 0;
  1360. background: rgba(0, 0, 0, .4);
  1361. z-index: 999;
  1362. }
  1363. .content_ {
  1364. position: absolute;
  1365. left: 0;
  1366. right: 0;
  1367. top: 0;
  1368. bottom: 0;
  1369. margin: auto;
  1370. text-align: center;
  1371. width: 500rpx;
  1372. height: 400rpx;
  1373. border-radius: 20rpx;
  1374. background-color: #fff;
  1375. padding-top: 120rpx;
  1376. }
  1377. .content_ image {
  1378. position: absolute;
  1379. top: -50rpx;
  1380. left: 0;
  1381. right: 0;
  1382. margin: auto;
  1383. }
  1384. .hintText {
  1385. font-size: 30rpx;
  1386. }
  1387. .Btns {
  1388. width: 460rpx;
  1389. height: 60rpx;
  1390. line-height: 60rpx;
  1391. text-align: center;
  1392. background: #FCD202;
  1393. font-size: 28rpx;
  1394. border: 2rpx solid #FCD202;
  1395. color: #333333;
  1396. border-radius: 50rpx;
  1397. font-weight: 700;
  1398. margin: auto;
  1399. }
  1400. .bg1 {
  1401. background: #FFFFFF;
  1402. }
  1403. .sticky-tabs {
  1404. z-index: 990;
  1405. position: sticky;
  1406. top: var(--window-top);
  1407. // background-color: #fff;
  1408. }
  1409. /* // 使用mescroll-uni,则top为0 */
  1410. .mescroll-uni,
  1411. /deep/.mescroll-uni {
  1412. .sticky-tabs {
  1413. top: 0;
  1414. }
  1415. }
  1416. .shop {
  1417. position: absolute;
  1418. top: 80rpx;
  1419. left: 0;
  1420. right: 0;
  1421. width: 686rpx;
  1422. margin: auto;
  1423. background: #FFFFFF;
  1424. border-radius: 20rpx;
  1425. box-shadow: 0 0 20rpx #CCCCCC;
  1426. }
  1427. .skuBtn {
  1428. padding: 10rpx 30rpx;
  1429. border-radius: 10rpx;
  1430. text-align: center;
  1431. margin: 10rpx 20rpx;
  1432. font-size: 28rpx;
  1433. color: #333333;
  1434. border: 2px solid #F2F2F2;
  1435. }
  1436. .active {
  1437. background: rgba(252, 210, 2, 0.2) !important;
  1438. border: 2px solid #FCD202 !important;
  1439. opacity: 0.6;
  1440. }
  1441. .active1 {
  1442. /* width: 82rpx; */
  1443. height: 16rpx;
  1444. background: #FCD202;
  1445. position: relative;
  1446. top: -10rpx;
  1447. z-index: 9;
  1448. }
  1449. .popup {
  1450. /* height: 500rpx; */
  1451. max-height: 500rpx;
  1452. /* overflow-y: auto; */
  1453. }
  1454. .tabBtn {
  1455. /* background-color: #f6f6fa; */
  1456. height: 60rpx;
  1457. line-height: 60rpx;
  1458. color: #999999;
  1459. font-size: 38rpx;
  1460. }
  1461. .Switch {
  1462. width: 164rpx;
  1463. height: 62rpx;
  1464. color: #FFFFFF;
  1465. background: #FCD202;
  1466. border-radius: 30rpx;
  1467. display: flex;
  1468. align-items: center;
  1469. padding: 2rpx;
  1470. }
  1471. .Switch>view {
  1472. /* flex: 1; */
  1473. width: 80rpx;
  1474. text-align: center;
  1475. line-height: 62rpx;
  1476. height: 58rpx;
  1477. }
  1478. .selSwitch {
  1479. color: #333333;
  1480. background: #FFFFFF;
  1481. border-radius: 30rpx;
  1482. }
  1483. .hintPopul {
  1484. width: 100%;
  1485. height: 100vh;
  1486. position: absolute;
  1487. top: 0;
  1488. background: rgba(0, 0, 0, .4);
  1489. }
  1490. .content {
  1491. position: absolute;
  1492. left: 0;
  1493. right: 0;
  1494. top: 0;
  1495. bottom: 0;
  1496. margin: auto;
  1497. text-align: center;
  1498. width: 500rpx;
  1499. height: 400rpx;
  1500. border-radius: 20rpx;
  1501. background-color: #fff;
  1502. padding-top: 120rpx;
  1503. }
  1504. .content image {
  1505. position: absolute;
  1506. top: -50rpx;
  1507. left: 0;
  1508. right: 0;
  1509. margin: auto;
  1510. }
  1511. .hintText {
  1512. font-size: 30rpx;
  1513. }
  1514. .VerticalNav.nav {
  1515. width: 200upx;
  1516. white-space: initial;
  1517. }
  1518. .VerticalNav.nav .cu-item {
  1519. width: 100%;
  1520. text-align: center;
  1521. background-color: #f1f1f1;
  1522. margin: 0;
  1523. border: none;
  1524. height: 50px;
  1525. line-height:25px;
  1526. position: relative;
  1527. }
  1528. .VerticalNav.nav .cu-item.cur {
  1529. background-color: #fff;
  1530. line-height:25px;
  1531. }
  1532. .VerticalBox {
  1533. display: flex;
  1534. }
  1535. .VerticalMain {
  1536. background-color: #f1f1f1;
  1537. flex: 1;
  1538. }
  1539. .detail_describe_text2 {
  1540. font-weight: 500;
  1541. margin-top: 2%;
  1542. color: #999999;
  1543. }
  1544. .detail_account_bottom {
  1545. margin-top: 20rpx;
  1546. width: 100%;
  1547. display: flex;
  1548. justify-content: space-between;
  1549. /* margin: 4% 0 3%; */
  1550. }
  1551. .detail_account_bottom_le {
  1552. width: 47.5%;
  1553. /* margin-right: 5%; */
  1554. border-radius: 44rpx;
  1555. text-align: center;
  1556. line-height: 2.8;
  1557. border: 2rpx solid #FCD202;
  1558. }
  1559. .detail_account_bottom_ri {
  1560. width: 47.5%;
  1561. border-radius: 44rpx;
  1562. text-align: center;
  1563. line-height: 2.8;
  1564. background-color: #FCD202;
  1565. }
  1566. .food_all {
  1567. position: relative;
  1568. }
  1569. .text-through {
  1570. text-decoration: line-through
  1571. }
  1572. /* 食物 */
  1573. .food {
  1574. width: 100%;
  1575. overflow: hidden;
  1576. // position: absolute;
  1577. // top: 350rpx;
  1578. // background-color: #FFFFFF;
  1579. border-top-left-radius: 18rpx;
  1580. border-top-right-radius: 18rpx;
  1581. }
  1582. .food_address {
  1583. // margin: 3% 3% 0 3%;
  1584. // margin: 3%;
  1585. display: flex;
  1586. justify-content: space-between;
  1587. align-items: center;
  1588. margin-top: 190rpx;
  1589. background-color: #FFFFFF;
  1590. // padding-bottom: 3%;
  1591. padding: 3%;
  1592. }
  1593. .food_address_le {
  1594. width: 75%;
  1595. }
  1596. .food_address_le_top {
  1597. display: flex;
  1598. align-items: center;
  1599. justify-content: space-between;
  1600. }
  1601. .food_address_le_top_le {
  1602. width: 40rpx;
  1603. height: 37rpx;
  1604. }
  1605. .food_address_le_top_le image {
  1606. width: 40rpx;
  1607. height: 37rpx;
  1608. }
  1609. .food_address_le_top_ce {
  1610. line-height: 1.6;
  1611. font-size: 38rpx;
  1612. font-weight: 600;
  1613. color: #333333;
  1614. }
  1615. .food_address_le_top_ce_ri {
  1616. width: 14rpx;
  1617. /* margin: 1% 0 0 2%; */
  1618. height: 24rpx;
  1619. margin-left: 2%;
  1620. }
  1621. .food_address_le_top_ce_ri image {
  1622. width: 14rpx;
  1623. height: 24rpx;
  1624. }
  1625. .food_address_text {
  1626. font-weight: 500;
  1627. font-size: 24rpx;
  1628. color: #999999;
  1629. }
  1630. .food_address_ri {
  1631. width: 24%;
  1632. height: 55rpx;
  1633. display: flex;
  1634. padding: 0.5% 1%;
  1635. background-color: #FCD202;
  1636. border-radius: 31rpx;
  1637. color: #FFFFFF;
  1638. }
  1639. .food_address_ri_sty {
  1640. flex: 1;
  1641. text-align: center;
  1642. padding-top: 4%;
  1643. font-size: 24rpx;
  1644. }
  1645. .food_address_ri_sty_active {
  1646. width: 100%;
  1647. overflow: hidden;
  1648. background-color: #FFFFFF;
  1649. border-radius: 31rpx;
  1650. color: #333333;
  1651. text-align: center;
  1652. }
  1653. /* 结算 */
  1654. .settlement {
  1655. width: 94%;
  1656. background-color: #000000;
  1657. line-height: 3.4;
  1658. border-radius: 49rpx;
  1659. position: fixed;
  1660. bottom: 10rpx;
  1661. left: 3%;
  1662. display: flex;
  1663. justify-content: space-between;
  1664. }
  1665. .settlement1 {
  1666. width: 94%;
  1667. background-color: #000000;
  1668. line-height: 2.8;
  1669. border-radius: 49rpx;
  1670. position: relative;
  1671. /* bottom: 10rpx; */
  1672. left: 0;
  1673. right: 0;
  1674. /* left: 3%; */
  1675. display: flex;
  1676. justify-content: space-between;
  1677. margin: 20rpx auto;
  1678. }
  1679. .settlement_le {
  1680. width: 48%;
  1681. padding-left: 18%;
  1682. color: #FFFFFF;
  1683. font-size: 30rpx;
  1684. }
  1685. .settlement_le text {
  1686. font-size: 22rpx;
  1687. }
  1688. .settlement_ri {
  1689. width: 35%;
  1690. background-color: #FCD202;
  1691. font-family: PingFang SC;
  1692. font-weight: 800;
  1693. color: #333333;
  1694. text-align: center;
  1695. border-top-right-radius: 49rpx;
  1696. border-bottom-right-radius: 49rpx;
  1697. }
  1698. .settlement_ri1 {
  1699. width: 35%;
  1700. background-color: #333333;
  1701. font-family: PingFang SC;
  1702. font-weight: 800;
  1703. color: #999999;
  1704. text-align: center;
  1705. border-top-right-radius: 49rpx;
  1706. border-bottom-right-radius: 49rpx;
  1707. }
  1708. .settlement_img {
  1709. width: 91rpx;
  1710. height: 96rpx;
  1711. position: absolute;
  1712. // bottom: 30rpx;
  1713. left: 5%;
  1714. }
  1715. .settlement_img image {
  1716. width: 74rpx;
  1717. height: 81rpx;
  1718. }
  1719. .settlement_hot {
  1720. width: 35rpx;
  1721. height: 35rpx;
  1722. line-height: 35rpx;
  1723. text-align: center;
  1724. border-radius: 50%;
  1725. position: absolute;
  1726. top: -10rpx;
  1727. right: 0;
  1728. background-color: #FF130A;
  1729. color: #FFFFFF;
  1730. font-size: 20rpx;
  1731. font-weight: bold;
  1732. color: #FFFFFF;
  1733. }
  1734. .select_all {
  1735. width: 100%;
  1736. position: relative;
  1737. }
  1738. /* 餐厅 */
  1739. .select {
  1740. color: #000000;
  1741. font-weight: bold;
  1742. background-color: #fff;
  1743. z-index: 10;
  1744. }
  1745. .select_line {
  1746. width: 15%;
  1747. height: 6rpx;
  1748. margin: 0 auto 4%;
  1749. background: #E6E6E6;
  1750. border-radius: 4rpx;
  1751. }
  1752. .select_search {
  1753. width: 100%;
  1754. margin: 2% 0;
  1755. display: flex;
  1756. align-items: center;
  1757. }
  1758. .select_search_le {
  1759. /* width: 10%; */
  1760. font-size: 30rpx;
  1761. line-height: 2.5;
  1762. margin-right: 1%;
  1763. }
  1764. .select_search_ce {
  1765. /* width: 5%; */
  1766. /* margin-top: 1%; */
  1767. margin-right: 20rpx;
  1768. margin-left: 6rpx;
  1769. /* margin: 0 20rpx; */
  1770. width: 20rpx;
  1771. height: 10rpx;
  1772. }
  1773. .select_search_ri {
  1774. /* width: 84%; */
  1775. height: 72rpx;
  1776. flex: 1;
  1777. display: flex;
  1778. }
  1779. .select_search_ri input {
  1780. flex: 1;
  1781. /* width: 100%; */
  1782. height: 72rpx;
  1783. background: #F5F5F5;
  1784. color: #999999;
  1785. border-radius: 36rpx;
  1786. text-decoration: 42rpx;
  1787. text-align: center;
  1788. }
  1789. /* 附近 */
  1790. .nearby {
  1791. width: 100%;
  1792. position: relative;
  1793. }
  1794. .nearby_text {
  1795. width: 18%;
  1796. font-size: 30rpx;
  1797. font-weight: 800;
  1798. color: #333333;
  1799. text-align: center;
  1800. border-bottom: 16rpx solid #FCD202;
  1801. /* line-height: 20rpx; */
  1802. margin-top: 10rpx;
  1803. }
  1804. .nearby_address_active {
  1805. border: 2rpx solid #FCD202;
  1806. width: 100%;
  1807. padding: 3%;
  1808. margin-top: 3%;
  1809. border-radius: 10upx;
  1810. display: flex;
  1811. }
  1812. .nearby_address {
  1813. width: 100%;
  1814. padding: 3%;
  1815. margin-top: 3%;
  1816. border-radius: 10upx;
  1817. display: flex;
  1818. }
  1819. .nearby_address_le {
  1820. flex: 1;
  1821. }
  1822. .nearby_address_ri {
  1823. line-height: 2.5;
  1824. text-align: right;
  1825. /* flex: 1; */
  1826. }
  1827. .nearby_text2 {
  1828. /* line-height: 1.5; */
  1829. display: flex;
  1830. justify-content: space-between;
  1831. align-items: center;
  1832. }
  1833. .nearby_text2_ {
  1834. font-size: 30rpx;
  1835. font-weight: 800;
  1836. color: #333333;
  1837. }
  1838. .nearby_text3 {
  1839. font-size: 24rpx;
  1840. font-weight: 500;
  1841. color: #999999;
  1842. margin-top: 2%;
  1843. }
  1844. /* 添加地址 */
  1845. .goorder {
  1846. width: 100%;
  1847. padding: 2% 3%;
  1848. position: fixed;
  1849. bottom: 0;
  1850. background-color: #FFFFFF;
  1851. border-top: 1rpx solid #999999;
  1852. }
  1853. .goorder_but {
  1854. width: 100%;
  1855. line-height: 2.5;
  1856. text-align: center;
  1857. background: #FCD202;
  1858. border-radius: 36rpx;
  1859. }
  1860. .lable {
  1861. border: 1rpx solid #FFE6D9;
  1862. height: 40rpx;
  1863. padding: 0 14rpx;
  1864. background: #FFE6D9;
  1865. border-radius: 4rpx;
  1866. font-weight: 500;
  1867. color: #FD6416;
  1868. font-size: 20rpx;
  1869. margin-right: 10rpx;
  1870. margin-bottom: 10rpx;
  1871. }
  1872. //店铺公告弹框
  1873. .gong_img{
  1874. margin: 40rpx 0 0 40rpx;
  1875. width: 46px;
  1876. height: 46px;
  1877. }
  1878. .gong_name{
  1879. position: absolute;
  1880. margin: 41rpx 0 0 163rpx;
  1881. font-size: 28rpx;
  1882. font-weight: 700;
  1883. color: rgba(0, 0, 0, 1);
  1884. }
  1885. .gong_pei{
  1886. position: absolute;
  1887. margin: 87rpx 0 0 163rpx;
  1888. font-size: 20rpx;
  1889. font-weight: 400;
  1890. color: rgba(0, 0, 0, 1);
  1891. }
  1892. .gong_line{
  1893. position: absolute;
  1894. margin: 161rpx 0 0 1rpx;
  1895. width: 635.5rpx;
  1896. border: 1rpx solid rgba(230, 230, 230, 1);
  1897. }
  1898. .gong_huo{
  1899. width: 151rpx;
  1900. height: 34rpx;
  1901. border-radius: 5rpx;
  1902. background: rgba(230, 74, 69, 1);
  1903. font-size: 16rpx;
  1904. font-weight: 400;
  1905. line-height: 34rpx;
  1906. color: rgba(255, 255, 255, 1);
  1907. text-align: center;
  1908. }
  1909. </style>