index.vue 55 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011
  1. <template>
  2. <view class="content">
  3. <view @click="goAddress()" class="address text-bold">
  4. <view class="address_name">{{address?address:'选择地址'}}</view>
  5. <u-icon name="arrow-down" color="#333333" size="28"></u-icon>
  6. </view>
  7. <!-- #ifdef H5 -->
  8. <view class="bg-white">
  9. <!-- #endif -->
  10. <!-- #ifndef H5 -->
  11. <view class="bg-white" style="margin-top: 180rpx;">
  12. <!-- #endif -->
  13. <view class="padding-lr padding-top">
  14. <view class="flex align-center padding-left" @click="goNav('/pages/index/search/index',2)"
  15. style="border: 2rpx solid #558C83;height: 80rpx;border-radius: 60rpx;">
  16. <u-icon name="search" size="46"></u-icon>
  17. <view class="flex-sub text-gray margin-left-sm">输入商家或商品名称</view>
  18. <view class="search-btn">搜索</view>
  19. </view>
  20. </view>
  21. <view class="padding-top padding-lr">
  22. <swiper class="swiper radius" :autoplay="true" interval="2000" duration="500" :circular="true"
  23. style="width: 100%;height: 280rpx;">
  24. <swiper-item v-for="(item,index) in bannerList" :key='index' @click="goNav(item.url,1)">
  25. <image :src="item.imageUrl" class="radius" style="width: 100%;height: 280rpx;"></image>
  26. </swiper-item>
  27. </swiper>
  28. </view>
  29. <view class="padding-lr radius" v-if="XCXIsSelect == '是'">
  30. <u-grid :col="5" :border="false">
  31. <u-grid-item v-for="(item,index) in gridData" :key='index' @tap="goDetail(item)">
  32. <image :src="item.imageUrl" style="width: 92rpx;height: 92rpx;border-radius: 92rpx;">
  33. </image>
  34. <view class="grid-text margin-top-sm">{{item.name}}</view>
  35. </u-grid-item>
  36. </u-grid>
  37. </view>
  38. </view>
  39. <view class="padding-lr" @click="natiVip">
  40. <image class="radius" style="width: 100%;height: 280rpx;" src="https://mxys.chuanghai-tech.com/wmfile/20251128/aa2e9bf9a4e04b758090007ac04cea44.jpg"></image>
  41. </view>
  42. <!-- 公告 -->
  43. <!-- <view class="flex justify-between align-center bg-white padding-bottom padding-lr radius bg-white"
  44. style="width: 100%;height: 100rpx;">
  45. <image @click="ceshi" src="../../static/images/index/gonggao.png" style="width: 140rpx;height: 50rpx;" mode=""></image>
  46. <view class="flex-sub margin-left-sm" style="height:82rpx;overflow: hidden;">
  47. <uni-notice-bar single speed="25" scrollable background-color="#fff" color="#000" :text="noticeList.value" />
  48. </view>
  49. </view>
  50. <view class="flex justify-between padding-lr bg-white" v-if="XCXIsSelect == '是'">
  51. <image src="https://mxys.chuanghai-tech.com/wmfile/20250618/9eeeec20031849fe8379536ffa0f28b3.png" @click="goNav('/my/integral/index')"
  52. style="width: 338rpx;height: 180rpx;" mode=""></image>
  53. <image src="https://mxys.chuanghai-tech.com/wmfile/20250618/ddbb2b42ec9749afab93863bc078614f.png" @click="goNav('/my/task/index')"
  54. style="width: 338rpx;height: 180rpx;" mode=""></image>
  55. </view> -->
  56. <!-- <view class="padding-top padding-lr bg-white" v-if="!shopStatus == 1&&XCXIsSelect=='是'">
  57. <image src="../../static/images/index/banner.png" @click="goNav('/my/apply/index')"
  58. style="width: 100%;height: 170rpx;" mode=""></image>
  59. </view> -->
  60. <!-- 活动推荐 -->
  61. <!-- <view class="huodong flex justify-center" v-if="huodongList.length>0&&XCXIsSelect!='否'">
  62. <view class="huodong-box flex justify-center">
  63. <view class="huodong-box-c">
  64. <view class="huodong-box-c-title flex justify-between align-center">
  65. <view class="huodong-box-c-title-l flex align-center">
  66. <image src="../../static/images/index/hd.png" mode=""></image>
  67. </view>
  68. <view class="huodong-box-c-title-r">
  69. 美食速达
  70. </view>
  71. </view>
  72. <view class="huodong-box-c-list">
  73. <swiper @change="swiperChange" :indicator-dots="false" display-multiple-items="3"
  74. :circular="true" style="height: 300rpx;" :autoplay="false" previous-margin="5"
  75. :interval="300" :duration="300">
  76. <swiper-item v-for="(item,index) in huodongList"
  77. style="border-radius: 28rpx;height: 320rpx;"
  78. @click="gotohuodong(item.name,item.id,item.imageUrl,item.url)">
  79. <view class="swiper-item flex justify-center flex-wrap align-center"
  80. style="width: 200rpx;height: 240rpx;background: linear-gradient(0deg, rgba(252, 210, 2, 0.8) 0%, rgba(252, 210, 2, 1) 100%);border-radius: 28rpx;"
  81. :style="currents==index?'height:260rpx;border-radius: 28rpx;':'margin-top:14rpx;'">
  82. <view class="flex justify-center align-center"
  83. :style="currents==index?'height:200rpx':''"
  84. style="width: 190rpx;height: 180rpx;border-radius: 28rpx;margin-top: 5rpx;">
  85. <image :src="item.imageUrl"
  86. style="width: 95%;height: 95%;border-radius: 20rpx;" mode="aspectFill">
  87. </image>
  88. </view>
  89. <view class=""
  90. style="width: 100%;text-align: center;font-size: 32rpx;color: white;font-weight: bold;padding-bottom: 10rpx;">
  91. {{item.name}}
  92. </view>
  93. </view>
  94. </swiper-item>
  95. </swiper>
  96. </view>
  97. </view>
  98. </view>
  99. </view> -->
  100. <!-- 推荐商家 -->
  101. <!-- <view class="jxShop flex justify-center" v-if="jxlist.length>0&&XCXIsSelect!='否'">
  102. <view class="jxShop-box flex justify-center">
  103. <view class="jxShop-box-c">
  104. <view class="jxShop-box-c-title flex justify-between align-center">
  105. <view class="jxShop-box-c-title-l">
  106. 推荐商家
  107. </view>
  108. <view class="jxShop-box-c-title-r flex align-center" @click="gotoList()">
  109. 更多
  110. <u-icon name="arrow-right" color="#1E1F31" size="28"></u-icon>
  111. </view>
  112. </view>
  113. <view class="jxShop-box-c-list flex justify-between">
  114. <view class="jxShop-box-c-list-item"
  115. @click="goShopDet(item.shopId,item,item.shopActivityList)"
  116. v-for="(item,index) in jxlist" :key="index">
  117. <image :src="item.shopCover" mode="aspectFill"></image>
  118. <view class="jxShop-box-c-list-item-name">
  119. {{item.shopName}}
  120. </view>
  121. </view>
  122. <view class="jxShop-box-c-list-item" style="height: 0;">
  123. </view>
  124. <view class="jxShop-box-c-list-item" style="height: 0;">
  125. </view>
  126. </view>
  127. </view>
  128. </view>
  129. </view> -->
  130. <view class="flex justify-center"
  131. style="position: relative;background-color: #ffffff;padding-top: 20rpx;padding-bottom: 20rpx;">
  132. <view style="width: 686rpx;" class="flex justify-between align-center bg-white">
  133. <view :class="current==1?'select':''" @click="confirm(1)">综合排序</view>
  134. <view :class="current==3?'select':''" @click="confirm(3)">距离优先</view>
  135. <view :class="current==4?'select':''" @click="confirm(4)">销量优先</view>
  136. <view class="flex" @click="isShow = !isShow">
  137. <view class="flex align-center" style="margin: 0 auto;">
  138. <view :class="isShow?'select':''">筛选</view>
  139. <u-icon v-if="!isShow" name="arrow-down" size="28"></u-icon>
  140. <u-icon v-if="isShow" name="arrow-up" color="#558C83" size="28"></u-icon>
  141. </view>
  142. </view>
  143. </view>
  144. <view v-if="isShow"
  145. style="position: absolute;top: 50rpx;width: 100%;z-index: 10;background: rgba(0,0,0,.5);height: 100vh;"
  146. @click="isShow =false">
  147. <view class="padding-lr bg-white">
  148. <view class="flex justify-between align-center padding-tb-sm u-border-bottom"
  149. v-for="(item,index) in options4" :key='index' @click.stop="getSelect(item)">
  150. <view class="text-df" :class="item.select?'select':''">{{item.shopTypeName}}</view>
  151. <u-icon v-if="item.select" name="checkmark" color="#558C83" size="28"></u-icon>
  152. </view>
  153. </view>
  154. </view>
  155. </view>
  156. <!-- 活动筛选 -->
  157. <view class="hd flex justify-center" v-if="hdlist.length>0">
  158. <view class="hd-box">
  159. <scroll-view scroll-x="true" class="scroll-view_H">
  160. <view class="hd-box-item" :style="currenthd==index?'background-color:#9ACAB9;':''"
  161. @click="searchhd(index,item.id)" v-for="(item,index) in hdlist" :key="index">
  162. {{item.title}}
  163. </view>
  164. </scroll-view>
  165. </view>
  166. </view>
  167. <view class="padding-lr">
  168. <view class="margin-tb-sm flex justify-between bg-white padding-sm radius"
  169. v-for="(item,index) in shopList" :key='index'
  170. @click="goShopDet(item.shopId,item,item.shopActivityList)">
  171. <image :src="item.shopCover[0]" class="radius" style="width: 180rpx;height: 180rpx;" mode="aspectFill"></image>
  172. <view class=" margin-left-sm" style="width: 450rpx;">
  173. <view class=" flex flex-direction justify-between">
  174. <view class="text-lg text-bold text-black">{{item.shopName}}</view>
  175. <view class="flex align-center margin-top-xs" style="width: 100%;">
  176. <!-- <u-icon name="star-fill" color="#FD6416" size="28"></u-icon> -->
  177. <text class="text-lg" style="color: #FF8205;"> {{item.shopScore?item.shopScore:0}}分</text>
  178. <text
  179. class="text-gray flex-sub margin-left-xs">销量{{item.shopSales?item.shopSales:0}}</text>
  180. <!-- <view style="font-size:20rpx;color:#707070;border: 2rpx solid #CCC6C6;border-radius: 8rpx;padding: 5rpx 8rpx;">{{item.autoSendOrder==1?'商家配送':'平台配送'}}</view> -->
  181. </view>
  182. <view class="text-gray margin-top-xs flex justify-between">
  183. <view>起送 ¥{{item.minimumDelivery}} 配送 ¥{{item.errandMoney?item.errandMoney:0}}</view>
  184. <view>
  185. <text class="text-gray margin-left-xs">{{item.errandTime}}分钟</text>
  186. <text class="text-gray margin-left-xs">{{item.distance}}</text>
  187. </view>
  188. </view>
  189. <view style="display: flex;" v-if="item.businessHours&&item.lockHours">
  190. <view class="text-gray margin-top-xs" style="background-color: #FFF5EB;color: #FF8205;border-radius: 8rpx;padding: 5rpx 16rpx;" >
  191. 营业时间:{{item.businessHours}}-{{item.lockHours}}
  192. </view>
  193. </view>
  194. <view class="flex margin-top-xs justify-between align-start" style="width: 100%;">
  195. <view class="flex flex-wrap align-center"
  196. style="width: 100%;height: 100%;overflow: hidden;">
  197. <!-- <view class="lable flex justify-center align-center" v-if="item.enableFullReductionFlag==1">
  198. 不参与配送费满减</view> -->
  199. <view class="lable flex justify-center align-center" v-if="item.enableFullReductionFlag==0&&item.exemptMinMoney">
  200. 满{{item.exemptMinMoney}}免配送费</view>
  201. <view v-for="(ite,ind) in item.shopActivityList" :key='ind' v-if="item.shopActivityList && ite.activityType!='1'">
  202. <view class="lable flex justify-center align-center" style="border-radius: 8rpx;border: 2rpx solid #F97A7A;background-color: #ffffff;color: #FF0000;box-sizing: border-box;">
  203. <text v-if="ite.activityType=='2'">时段</text>
  204. <text v-if="ite.activityType=='3'">满额</text>
  205. <text v-if="ite.activityType=='4'">全场</text>
  206. <text style="margin-left: 3px;">|</text>
  207. <text style="margin-left: 3px;">{{ite.activityName}}</text>
  208. </view>
  209. <!-- <view class="lable flex justify-center align-center"
  210. style="border-radius: 4rpx;border: 1rpx solid red;background-color: #ffffff;color: red;box-sizing: border-box;"
  211. >{{ite.activityName}}
  212. </view> -->
  213. </view>
  214. <view class="lable flex justify-center align-center" v-for="(ite,ind) in item.shopLable" :key='ind'
  215. v-if="item.shopLable">
  216. {{ite}}
  217. </view>
  218. <view class="lable flex justify-center align-center" v-if="item.couponList" style="border-radius: 8rpx;border: 1rpx solid #F97A7A;background-color: #ffffff;color: #FF0000;box-sizing: border-box;" v-for="(it,ide) in item.couponList" :key="ide">
  219. <text>优惠券</text>
  220. <text style="margin-left: 3px;">|</text>
  221. <text style="margin-left: 3px;">满{{it.minMoney}}减{{it.money}}</text>
  222. </view>
  223. </view>
  224. </view>
  225. </view>
  226. <view class="flex margin-top-xs">
  227. <view v-for="(ite,ind) in item.goodsList" :key='ind'
  228. @click.stop="goDet(ite.goodsId,item.shopId)" style="width: 33%;">
  229. <image :src="ite.goodsCover" style="width: 120rpx;height: 120rpx;" class="radius"
  230. mode="">
  231. </image>
  232. <view class="u-line-1 text-df text-bold margin-top-xs">{{ite.goodsName}}</view>
  233. <view class="text-bold margin-top-xs" style="color: #FD6416;"> <text
  234. class="text-sm">¥</text> {{ite.goodsMoney}}</view>
  235. </view>
  236. </view>
  237. </view>
  238. </view>
  239. </view>
  240. <!-- <empty v-if="!shopList.length" ></empty> -->
  241. <view class="page-box" v-if="!shopList.length">
  242. <view class="centre" v-if="XCXIsSelect == '是'">
  243. <image src="https://mxys.chuanghai-tech.com/wmfile/20250814/99c5ced85df04062a736276ba75bdd1e.png" mode=""></image>
  244. <view class="tips">暂无内容</view>
  245. </view>
  246. <view class="centre" v-else-if="XCXIsSelect == '否'">
  247. <image style="width: 345px;height: 140px;" src="https://mxys.chuanghai-tech.com/img/20240315/12fa3c96351f4f10abae1ba251d4c284.jpg" mode=""></image>
  248. </view>
  249. </view>
  250. <!-- 打样提示 -->
  251. <view v-if="hintShow" class="hintPopul" @click.stop="hintShow=false">
  252. <view class="content_">
  253. <image src="../../static/images/index/shop.png" mode="" style="width: 200rpx;height: 180rpx;">
  254. </image>
  255. <view class="text-xl text-bold">店铺打烊啦</view>
  256. <view class="hintText margin-top-sm text-gray">现在店铺已经打烊了,营业时间</view>
  257. <view class="margin-top-xs text-gray margin-bottom">{{shop.businessHours}}-{{shop.lockHours}}</view>
  258. <view class="skuBtn" @click="hintShow=false">知道了</view>
  259. </view>
  260. </view>
  261. <u-popup v-model="Authorization" mode="center" close-icon="close-circle" close-icon-pos="top-right"
  262. close-icon-color="#8f9298" close-icon-size="50">
  263. <view class="contentview">
  264. <view class="title">隐私保护指引</view>
  265. <view class="des" @click="openPrivacyContract">
  266. 在使用当前小程序服务之前,请仔细阅读<text
  267. style="color: #FF7F00;">{{privacyContractName}}</text>。如你同意{{privacyContractName}},请点击“同意”开始使用。
  268. </view>
  269. <view class="btns">
  270. <button class="item reject" @click="exitMiniProgram">拒绝</button>
  271. <button id="agree-btn" class="item agree" open-type="agreePrivacyAuthorization"
  272. @agreeprivacyauthorization="handleAgreePrivacyAuthorization">同意</button>
  273. </view>
  274. </view>
  275. </u-popup>
  276. <!-- 新人红包 -->
  277. <view class="hongbao" v-if="waimaiHB == '是' &&HBShow">
  278. <view style="width: 62%;margin: 0 auto;position: relative;">
  279. <view @click="HBShow=false"
  280. style="position: absolute;right: -10rpx;top: -10rpx;z-index: 999;;font-size: 60rpx;font-weight: bold;">
  281. X
  282. </view>
  283. <!-- @click="takemoney()" https://mxys.chuanghai-tech.com/wmfile/20250814/f5146f4e2f1e46d28d4613260ab58c92.png-->
  284. <image :src="Tupian('/%E5%BE%AE%E4%BF%A1%E5%9B%BE%E7%89%87_20240520171928.jpg')" class="hb_img"></image>
  285. <!-- <image src="../../static/images/index/hb_btn.png" class="hb_btn" @click="takemoney()"></image> -->
  286. </view>
  287. </view>
  288. <!-- 联系客服悬浮按钮区域 -->
  289. <view class="serviceBtn" @click="goChat">
  290. </view>
  291. </view>
  292. </template>
  293. <script>
  294. import empty from '@/components/empty.vue'
  295. import {
  296. requestAndroidPermission,
  297. gotoAppPermissionSetting
  298. } from '@/components/permission.js'
  299. export default {
  300. components: {
  301. empty
  302. },
  303. data() {
  304. return {
  305. Authorization: false,
  306. privacyContractName: '',
  307. lookShow: false,
  308. currenthd: -1,
  309. hdlist: [],
  310. activityId: '',
  311. currents: 1,
  312. HBShow: false,
  313. isShow: false,
  314. hintShow: false,
  315. address: '暂无地址',
  316. city:'',
  317. bannerList: [{
  318. "id": 3,
  319. "createTime": "2021-12-24 17:52:27",
  320. "name": "banner3",
  321. "imageUrl": "https://diancan.xianmxkj.com/file/uploadPath/2021/12/24/0bfdbabcde9c62b42e77aecdb583033b.png",
  322. "state": 1,
  323. "classify": 1,
  324. "url": "",
  325. "sort": 3,
  326. "describess": "banner3"
  327. },
  328. {
  329. "id": 45,
  330. "createTime": "2021-12-24 17:52:27",
  331. "name": "banner",
  332. "imageUrl": "https://diancan.xianmxkj.com/file/uploadPath/2021/12/24/589d72b40a690147a48854a3b7f88953.png",
  333. "state": 1,
  334. "classify": 1,
  335. "url": "",
  336. "sort": 1,
  337. "describess": ""
  338. },
  339. ],
  340. gridData: [],
  341. page: 1,
  342. limit: 10,
  343. shopList: [],
  344. screen: '1',
  345. lng: '',
  346. lat: '',
  347. shopType: '1',
  348. shopTypeList: [{
  349. id: '0',
  350. shopTypeName: "全部"
  351. }],
  352. userId: '',
  353. src1: '../../static/images/index/xia.png',
  354. noticeList: {},
  355. show: false,
  356. typeShow: false,
  357. current: 1,
  358. sort: 1,
  359. fabuclassifyId: '',
  360. typeName: '全部',
  361. fabuclassifyName: '筛选',
  362. shopTypeId: '',
  363. value1: 0,
  364. value2: 0,
  365. value3: 0,
  366. value4: 0,
  367. options1: [{
  368. label: '综合排序',
  369. value: 1,
  370. }],
  371. options2: [{
  372. value: '3',
  373. label: "距离优先"
  374. }],
  375. options3: [{
  376. value: '4',
  377. label: "销量优先"
  378. }],
  379. options4: [{
  380. id: '',
  381. select: true,
  382. shopTypeName: "全部"
  383. }],
  384. defaultIndex: [0, 0, 0, 0],
  385. filterData: [
  386. [{
  387. label: '综合排序',
  388. value: '1',
  389. }],
  390. [{
  391. label: '距离优先',
  392. value: '3',
  393. }],
  394. [{
  395. label: '销量优先',
  396. value: '4',
  397. }],
  398. [{
  399. label: '不限性别',
  400. value: '0',
  401. },
  402. {
  403. label: '限男生',
  404. value: 1,
  405. },
  406. {
  407. label: '限女生',
  408. value: 2,
  409. }
  410. ],
  411. ],
  412. shopStatus: '',
  413. shop: {},
  414. title: '综合排序',
  415. title1: '距离优先',
  416. title2: '销量优先',
  417. title3: '筛选',
  418. XCXIsSelect: '否',
  419. arr: [],
  420. showModal: true,
  421. shopId: '',
  422. totalCount: 0,
  423. newUserFlagWm: 2,
  424. waimaiHB: '否',
  425. tuiguang: '',
  426. tuiguangImg: '',
  427. huodongList: [],
  428. jxlist: [],
  429. huoList:[],//商户参与的活动
  430. token:""
  431. }
  432. },
  433. onLoad(e) {
  434. let that = this
  435. that.token = that.$queue.getData("token")
  436. that.userId = uni.getStorageSync('userId') ? uni.getStorageSync('userId') : ''
  437. that.getZiZhi();
  438. that.getBannerList()
  439. that.getGridList()
  440. that.getShopType()
  441. that.getNoticeList()
  442. // that.getHuoDongList() //活动列表
  443. that.getHuoDList() //活动轮播
  444. that.gethdlist();
  445. uni.getLocation({
  446. type: 'gcj02', //返回可以用于uni.openLocation的经纬度
  447. highAccuracyExpireTime: 100,
  448. success: function(res) {
  449. that.lat = res.latitude;
  450. that.lng = res.longitude;
  451. that.defaultAddress()
  452. // that.getShopList()
  453. },
  454. fail(e) {
  455. uni.showModal({
  456. title: '温馨提示',
  457. content: '您的定位权限未开启,请开启后再来刷新操作吧!',
  458. showCancel: true,
  459. cancelText: '取消',
  460. confirmText: '确认',
  461. success: res => {
  462. if (res.confirm) {
  463. // #ifdef MP-WEIXIN
  464. uni.openSetting({ // 打开设置页
  465. success(rea) {
  466. console.log(rea.authSetting)
  467. }
  468. });
  469. // #endif
  470. // #ifdef APP-PLUS
  471. gotoAppPermissionSetting()
  472. // #endif
  473. }
  474. }
  475. });
  476. }
  477. });
  478. console.log(that.lat, that.lng, '经纬度')
  479. // #ifdef MP-WEIXIN
  480. if (e.scene) {
  481. const scene = decodeURIComponent(e.scene);
  482. let params = {}
  483. // 分割成键值对数组
  484. let pairs = scene.split('&')
  485. // 遍历并解析每个键值对
  486. pairs.forEach((pair) => {
  487. const [key, value] = pair.split('=')
  488. params[key] = value
  489. })
  490. let shopId = params.shopId
  491. let shopTypeId = params.shopTypeId
  492. if (shopId) {
  493. that.shopId = shopId
  494. }
  495. // if (!that.userId) {
  496. // uni.navigateTo({
  497. // url: '/pages/public/login'
  498. // })
  499. // return;
  500. // }
  501. setTimeout(function() {
  502. uni.navigateTo({
  503. url: '/pages/index/shop/index?shopId=' + that.shopId +'&shopTypeId=' + shopTypeId+'&lat='+this.lat+'&lng='+this.lng
  504. })
  505. }, 100)
  506. } else if (e.orderId) {
  507. uni.setStorageSync('orderId', e.orderId)
  508. // if (!that.userId) {
  509. // uni.navigateTo({
  510. // url: '/pages/public/login'
  511. // })
  512. // return;
  513. // }
  514. setTimeout(function() {
  515. uni.navigateTo({
  516. url: '/pages/index/shop/goodsList?shopId=' + e.shopId
  517. })
  518. }, 100)
  519. }
  520. try {
  521. wx.getPrivacySetting({
  522. success: res => {
  523. console.log("是否需要授权:", res.needAuthorization, "隐私协议的名称为:", res.privacyContractName)
  524. if (res.needAuthorization) {
  525. that.privacyContractName = res.privacyContractName;
  526. // this.$refs.popusAuthorization.open();
  527. that.Authorization = true;
  528. }
  529. },
  530. fail: () => {},
  531. complete: () => {},
  532. })
  533. } catch (e) {
  534. //TODO handle the exception
  535. }
  536. // #endif
  537. },
  538. onShow() {
  539. let that = this
  540. that.token = that.$queue.getData('token')
  541. that.$Request.get('/app/common/type/264').then(res => {
  542. if (res.code == 0) {
  543. // #ifdef MP-WEIXIN
  544. that.XCXIsSelect = res.data.value;
  545. that.$queue.setData('XCXIsSelect', res.data.value);
  546. that.$queue.setData('shangxianSelect', res.data.value);
  547. // #endif
  548. // #ifndef MP-WEIXIN
  549. that.$queue.setData('XCXIsSelect', '是');
  550. that.$queue.setData('shangxianSelect', '是');
  551. that.XCXIsSelect = '是'
  552. // #endif
  553. }
  554. });
  555. that.getHuoDList() //活动轮播
  556. that.gethdlist();
  557. uni.getLocation({
  558. type: 'gcj02', //返回可以用于uni.openLocation的经纬度
  559. success: function(res) {
  560. console.log(res)
  561. that.lat = res.latitude;
  562. that.lng = res.longitude;
  563. that.defaultAddress()
  564. }
  565. });
  566. that.userId = uni.getStorageSync('userId') ? uni.getStorageSync('userId') : ''
  567. that.lng = uni.getStorageSync('lng') ? uni.getStorageSync('lng') : that.lng
  568. that.lat = uni.getStorageSync('lat') ? uni.getStorageSync('lat') : that.lat
  569. console.log(that.userId, '我的id')
  570. // if (this.lng && this.lat) {
  571. // that.defaultAddress()
  572. // that.getjxShop(); //精选商家
  573. // }
  574. if (that.userId) {
  575. that.getUserInfo()
  576. that.$Request.getT('/app/common/type/266').then(res => { //订单取消通知
  577. // console.log(res, 963)
  578. if (res.code == 0) {
  579. if (res.data && res.data.value) {
  580. that.arr.push(res.data.value)
  581. }
  582. }
  583. })
  584. that.$Request.getT('/app/common/type/269').then(res => { //订单状态通知
  585. // console.log(res, 966)
  586. if (res.code == 0) {
  587. if (res.data && res.data.value) {
  588. that.arr.push(res.data.value)
  589. }
  590. }
  591. })
  592. // that.$Request.getT('/app/common/type/440').then(res => { //订单状态通知
  593. // // console.log(res, 999)
  594. // if (res.code == 0) {
  595. // if (res.data && res.data.value) {
  596. // that.arr.push(res.data.value)
  597. // }
  598. // }
  599. // })
  600. // that.$Request.getT('/app/common/type/441').then(res => { //订单状态通知
  601. // // console.log(res, 999)
  602. // if (res.code == 0) {
  603. // if (res.data && res.data.value) {
  604. // that.arr.push(res.data.value)
  605. // }
  606. // }
  607. // })
  608. // #ifdef MP-WEIXIN
  609. if (that.showModal) {
  610. that.openMsg()
  611. }
  612. // #endif
  613. }
  614. // this.getShopList()
  615. },
  616. onShareAppMessage(res) { //发送给朋友
  617. return {
  618. title: this.tuiguang,
  619. path: '/pages/index/index',
  620. imageUrl: this.tuiguangImg,
  621. }
  622. },
  623. onShareTimeline(res) { //分享到朋友圈
  624. return {
  625. title: this.tuiguang,
  626. path: '/pages/index/index',
  627. imageUrl: this.tuiguangImg,
  628. }
  629. },
  630. methods: {
  631. //跳转到会员页
  632. natiVip(){
  633. if (this.token) {
  634. uni.navigateTo({
  635. url:'/my/vip/shop?city='+this.city
  636. })
  637. } else {
  638. this.bindlogin()
  639. }
  640. },
  641. //测试付钱
  642. ceshi(){
  643. console.log('付钱')
  644. wx.requestPayment( {
  645. "appId": 'wx45ab46867002aa0b', //公众号ID,由商户传入
  646. "timeStamp": '1730281084', //时间戳,自1970年以来的秒数
  647. "nonceStr": '14cdaf9f6ab64c0ab4d2df3a63f2b484', //随机串
  648. "package": 'prepay_id=wx30173804948968a92217fddbd7942d0000',
  649. "signType": 'RSA', //微信签名方式:
  650. "paySign": 'QFMu/l1/WIM9QTXaalpiHSwKr6MpeNt6ixpWb/qaT2u0Dw344kknTQRWSs86T+aqSSnBuVyL+mjEchC/GkNwG489omH03fWtVWM3jEtgpzS4oEQF7F+QehyxKR/Lw11OBvQont+xmuhI7DwSVn5OKB5yEfxG57LdcFBb2x6+FGlLFvSEB0p/XqJh8aW+80tvaz1lhX677AyxU5VwP1aBIB5MivqvBWypbyfKR30qA7oM8wOq6O4baYQtXrq0z0kokhNk0aZxHTYuqqNXftcyyBGyyM6hl0LHXvlxhrbS8N/GitwgSX3KJ3Jate+V5UVNv0+vY1NNxVOzDMhNirWNMg==' //微信签名
  651. },
  652. function(res) {
  653. console.log(res,'res')
  654. if (res.err_msg == "get_brand_wcpay_request:ok") {
  655. // 使用以上方式判断前端返回,微信团队郑重提示:
  656. //res.err_msg将在用户支付成功后返回ok,但并不保证它绝对可靠。
  657. }else{
  658. this.chapayIf()
  659. }
  660. });
  661. },
  662. goChat() {
  663. if (this.token) {
  664. uni.navigateTo({
  665. url: '/my/setting/chat'
  666. })
  667. } else {
  668. this.bindlogin()
  669. }
  670. },
  671. bindlogin() {
  672. uni.navigateTo({
  673. url: '/pages/public/login'
  674. })
  675. },
  676. // 打开隐私协议页面
  677. openPrivacyContract() {
  678. let that = this;
  679. wx.openPrivacyContract({
  680. fail: () => {
  681. that.$queue.showToast('遇到错误无法打开!');
  682. }
  683. })
  684. },
  685. // 拒绝隐私协议
  686. exitMiniProgram() {
  687. // 直接退出小程序
  688. wx.exitMiniProgram()
  689. },
  690. // 同意隐私协议
  691. handleAgreePrivacyAuthorization() {
  692. // this.$refs.popusAuthorization.close();
  693. this.Authorization = false;
  694. let that = this;
  695. uni.getLocation({
  696. type: 'gcj02', //返回可以用于uni.openLocation的经纬度
  697. highAccuracyExpireTime: 100,
  698. success: function(res) {
  699. console.log(res)
  700. that.lat = res.latitude;
  701. that.lng = res.longitude;
  702. that.defaultAddress()
  703. // that.getShopList()
  704. },
  705. fail(e) {
  706. uni.showModal({
  707. title: '温馨提示',
  708. content: '您的定位权限未开启,请开启后再来刷新操作吧!',
  709. showCancel: true,
  710. cancelText: '取消',
  711. confirmText: '确认',
  712. success: res => {
  713. if (res.confirm) {
  714. // #ifdef MP-WEIXIN
  715. uni.openSetting({ // 打开设置页
  716. success(rea) {
  717. console.log(rea.authSetting)
  718. }
  719. });
  720. // #endif
  721. // #ifdef APP-PLUS
  722. gotoAppPermissionSetting()
  723. // #endif
  724. }
  725. }
  726. });
  727. }
  728. });
  729. },
  730. selectShow() {
  731. this.lookShow = !this.lookShow
  732. },
  733. //筛选活动
  734. searchhd(index, activityId) {
  735. if (index == this.currenthd) {
  736. this.page=1
  737. this.currenthd = -1
  738. this.activityId = '';
  739. this.shopList =[]
  740. this.getShopList()
  741. } else {
  742. console.log('eww','ll')
  743. this.page=1
  744. this.currenthd = index;
  745. this.activityId = activityId;
  746. this.shopList =[]
  747. // this.getShopList()
  748. this.huoDListSh()
  749. }
  750. },
  751. //获取所有活动
  752. gethdlist() {
  753. // this.$Request.get("/app/activityManage/getActivityList").then(res => {
  754. let data={
  755. page:1,
  756. limit:10,
  757. }
  758. this.$Request.get('/app/activity/page').then(res => {
  759. if (res.code == 0) {
  760. var total=res.totalCount
  761. let data={
  762. page:1,
  763. limit:total,
  764. }
  765. this.$Request.get('/app/activity/page').then(res => {
  766. if (res.code == 0) {
  767. res.data.list.map((item, index) => {
  768. if (item.id == 14) {
  769. res.data.list.splice(index, 1)
  770. }
  771. })
  772. this.hdlist = res.data.list
  773. }
  774. });
  775. }
  776. });
  777. },
  778. // 获取精选商家
  779. getjxShop() {
  780. let data = {
  781. activityId: 14,
  782. page: 1,
  783. limit: 4,
  784. lat: this.lat,
  785. lng: this.lng,
  786. }
  787. this.$Request.get("/app/activityManage/getShoActivityShopList", data).then(res => {
  788. if (res.code == 0) {
  789. this.jxlist = res.data.records
  790. }
  791. });
  792. },
  793. gotoList() {
  794. uni.navigateTo({
  795. url: '/running/huodong/list?activityId=14'
  796. })
  797. },
  798. gotohuodong(name,id,imageUrl, url) {
  799. uni.navigateTo({
  800. url: url + '?activityTitle=' + name+'&activityId='+id+'&imageUrl='+imageUrl
  801. })
  802. },
  803. // 获取活动轮播图
  804. getHuoDList() {
  805. let data = {
  806. classify: 12
  807. }
  808. this.$Request.get("/app/banner/selectBannerList", data).then(res => {
  809. if (res.code == 0) {
  810. let arr = []
  811. arr = res.data
  812. arr.map((item, index) => {
  813. if (item.name == '推荐商家') {
  814. arr.splice(index, 1)
  815. }
  816. })
  817. this.huodongList = arr
  818. }
  819. });
  820. },
  821. swiperChange(e) {
  822. if (this.huodongList.length - 1 == e.detail.current) {
  823. this.currents = 0
  824. } else {
  825. this.currents = e.detail.current + 1
  826. }
  827. // this.moneys = this.swiper[this.currents].mysteryBoxTypePrice
  828. // this.boxType = this.swiper[this.currents].mysteryBoxTypeId
  829. // this.getgoodsList(this.swiper[this.currents].mysteryBoxTypeId)
  830. },
  831. //活动列表
  832. getHuoDongList() {
  833. // huodongList
  834. //
  835. // this.$Request.getT('/app/activityManage/getActivityList').then(res => {
  836. let data={
  837. page:1,
  838. limit:10,
  839. }
  840. this.$Request.getT('/app/activity/page',data).then(res => {
  841. if (res.code === 0) {
  842. var total=res.totalCount
  843. let data={
  844. page:1,
  845. limit:total,
  846. }
  847. this.$Request.getT('/app/activity/page',data).then(res => {
  848. if (res.code === 0) {
  849. this.huodongList = res.data.list
  850. }
  851. });
  852. }
  853. });
  854. },
  855. // 分享文案和图片
  856. getZiZhi() {
  857. this.$Request.getT('/app/common/type/239').then(res => {
  858. if (res.code === 0) {
  859. this.tuiguang = res.data.value;
  860. }
  861. });
  862. this.$Request.getT('/app/common/type/238').then(res => {
  863. if (res.code === 0) {
  864. this.tuiguangImg = res.data.value;
  865. }
  866. });
  867. },
  868. // 红包
  869. takemoney() {
  870. this.$Request.getT('/app/userinfo/getNewUserRedPacketWm').then(res => {
  871. console.log(res.code)
  872. if (res.code == 0) {
  873. this.HBShow = false
  874. this.getUserInfo()
  875. setTimeout(function() {
  876. uni.navigateTo({
  877. url: '/my/coupon/index'
  878. })
  879. }, 100)
  880. }
  881. });
  882. },
  883. getSelect(e) {
  884. this.options4.forEach(res => {
  885. if (res.id == e.id) {
  886. res.select = true
  887. this.page = 1
  888. this.shopTypeId = e.id
  889. this.getShopList();
  890. this.isShow = false
  891. } else {
  892. res.select = false
  893. }
  894. })
  895. },
  896. // 获取用户信息
  897. getUserInfo() {
  898. this.$Request.getT('/app/user/selectUserMessage').then(res => {
  899. console.log(res)
  900. if (res.code == 0) {
  901. this.shopStatus = res.data.shopStatus
  902. this.newUserFlagWm = res.data.newUserFlagWm
  903. if (this.newUserFlagWm == 1) {
  904. this.waimaiHB = this.$queue.getData('waimaiHB');
  905. if (this.waimaiHB === '是') {
  906. this.HBShow = true
  907. }
  908. } else {
  909. this.HBShow = false
  910. }
  911. }
  912. });
  913. },
  914. // 获取公告
  915. getNoticeList() {
  916. let data = {
  917. page: 1,
  918. limit: 100
  919. }
  920. this.$Request.get("/app/common/type/432", data).then(res => {
  921. if (res.code == 0) {
  922. this.noticeList = res.data
  923. // console.log(this.noticeList,999);
  924. }
  925. });
  926. },
  927. confirm(e) {
  928. this.isShow = false
  929. this.page = 1
  930. this.current = e;
  931. this.getShopList();
  932. },
  933. // 获取轮播图
  934. getBannerList() {
  935. let data = {
  936. classify: 1
  937. }
  938. this.$Request.get("/app/banner/selectBannerList", data).then(res => {
  939. if (res.code == 0) {
  940. this.bannerList = res.data
  941. }
  942. });
  943. },
  944. // 获取轮播图
  945. getGridList() {
  946. let data = {
  947. classify: 4
  948. }
  949. this.$Request.get("/app/banner/selectBannerList", data).then(res => {
  950. if (res.code == 0) {
  951. this.gridData = res.data
  952. }
  953. });
  954. },
  955. // 商户类型
  956. getShopType() {
  957. this.$Request.getT('/app/shoptype/selectShopTypeList').then(res => {
  958. if (res.code == 0) {
  959. // this.shopTypeList = [...this.shopTypeList ,...res.data]
  960. res.data.forEach(res => {
  961. res.select = false
  962. })
  963. this.options4 = [...this.options4, ...res.data]
  964. console.log(this.options4, '+++++++++++++++++++')
  965. }
  966. })
  967. },
  968. //活动下的商户
  969. huoDListSh(){
  970. let data = {
  971. page: this.page,
  972. limit: this.limit,
  973. screen: this.current,
  974. shopTypeId: this.shopTypeId,
  975. lng: this.lng,
  976. lat: this.lat,
  977. // activityId: this.activityId,
  978. city:this.city,
  979. }
  980. this.$Request.getT('/app/goods/selectShop', data).then(res => {
  981. if (res.code == 0) {
  982. var totalCount=res.data.totalCount
  983. let data = {
  984. page: this.page,
  985. limit: totalCount,
  986. }
  987. console.log(data,this.activityId)
  988. this.$Request.getT(`/app/activity-shop/activity-shop-page/${this.activityId}`, data).then(res => {
  989. console.log(res,'hhhhhh2h')
  990. if (res.code == 0) {
  991. var huodongList=[]
  992. huodongList=res.data.list
  993. let data = {
  994. page: this.page,
  995. limit: totalCount,
  996. screen: this.current,
  997. shopTypeId: this.shopTypeId,
  998. lng: this.lng,
  999. lat: this.lat,
  1000. // activityId: this.activityId,
  1001. city:this.city,
  1002. }
  1003. this.$Request.getT('/app/goods/selectShop', data).then(res => {
  1004. if (res.code == 0) {
  1005. this.totalCount = res.data.totalCount
  1006. res.data.list.forEach(ret => {
  1007. if (ret.distance > 1000) {
  1008. ret.distance = Number((ret.distance / 1000)).toFixed(2) + "km"
  1009. } else {
  1010. if (ret.distance == 0) {
  1011. ret.distance = "0m";
  1012. } else {
  1013. ret.distance = Number(ret.distance).toFixed(1) + "m";
  1014. }
  1015. }
  1016. ret.shopScore = ret.shopScore.toFixed(1)
  1017. ret.shopLable = ret.shopLable ? ret.shopLable.split(',') : ''
  1018. ret.shopCover = ret.shopCover ? ret.shopCover.split(',') :
  1019. 'https://mxys.chuanghai-tech.com/wmfile/20250814/fff4dc5d02ea4af881db9685f2e1e61d.png'
  1020. ret.errandTime = Math.round(ret.errandTime)
  1021. })
  1022. var shopList=[]
  1023. shopList=res.data.list
  1024. for (let i = 0; i < shopList.length; i++) {
  1025. let item1 = shopList[i];
  1026. // 内层循环遍历array2
  1027. for (let j = 0; j < huodongList.length; j++) {
  1028. let item2 = huodongList[j];
  1029. // 检查id是否相等
  1030. if (item1.shopId === item2.shopId) {
  1031. // 如果相等,将对象添加到matchedArray
  1032. this.shopList.push(item1);
  1033. // 如果只需要添加一次,则可以在这里退出内层循环
  1034. // break;
  1035. }
  1036. }
  1037. }
  1038. // for(var i=0;i<shopList.length;i++){
  1039. // let item1 = shopList[i];
  1040. // for(var j=0;j<huodongList.length;j++){
  1041. // let item2 = huodongList[j];
  1042. // console.log(shopList[i].shopId==huodongList[j].shopId,'oppoo')
  1043. // if(item1.shopId==item2.shopId){
  1044. // this.shopList.push(item1)
  1045. // console.log(this.shopList,'pp')
  1046. // // return一次就退出
  1047. // }else{
  1048. // this.shopList =[]
  1049. // }
  1050. // }
  1051. // }
  1052. }
  1053. })
  1054. }
  1055. })
  1056. }
  1057. uni.stopPullDownRefresh();
  1058. uni.hideLoading()
  1059. })
  1060. },
  1061. // 商户列表
  1062. getShopList() {
  1063. console.log(this.city,'city')
  1064. uni.setStorageSync('lng', this.lng);
  1065. uni.setStorageSync('lat', this.lat);
  1066. let data = {
  1067. page: this.page,
  1068. limit: this.limit,
  1069. screen: this.current,
  1070. shopTypeId: this.shopTypeId,
  1071. lng: this.lng,
  1072. lat: this.lat,
  1073. // activityId: this.activityId,
  1074. city:this.city,
  1075. }
  1076. console.log(data,'jjj')
  1077. this.$Request.getT('/app/goods/selectShop', data).then(res => {
  1078. console.log(res,'hhhhhh6')
  1079. if (res.code == 0) {
  1080. this.totalCount = res.data.totalCount
  1081. res.data.list.forEach(ret => {
  1082. if (ret.distance > 1000) {
  1083. ret.distance = Number((ret.distance / 1000)).toFixed(2) + "km"
  1084. } else {
  1085. if (ret.distance == 0) {
  1086. ret.distance = "0m";
  1087. } else {
  1088. ret.distance = Number(ret.distance).toFixed(1) + "m";
  1089. }
  1090. }
  1091. ret.shopScore = ret.shopScore.toFixed(2)
  1092. ret.shopLable = ret.shopLable ? ret.shopLable.split(',') : ''
  1093. ret.shopCover = ret.shopCover ? ret.shopCover.split(',') :
  1094. 'https://mxys.chuanghai-tech.com/wmfile/20250814/fff4dc5d02ea4af881db9685f2e1e61d.png'
  1095. ret.errandTime = Math.round(ret.errandTime)
  1096. })
  1097. if (this.page == 1) {
  1098. this.shopList = res.data.list
  1099. } else {
  1100. this.shopList = [...this.shopList, ...res.data.list]
  1101. }
  1102. console.log(this.shopList)
  1103. }
  1104. uni.stopPullDownRefresh();
  1105. uni.hideLoading()
  1106. })
  1107. },
  1108. goNav(url,type) {
  1109. console.log(url,'lkk')
  1110. if(url=='/my/integral/index' || url=='/my/task/index'){
  1111. uni.navigateTo({
  1112. url: '/pages/public/login'
  1113. })
  1114. return
  1115. }
  1116. // if (this.userId) {
  1117. if (uni.getStorageSync('sendMsg')) {
  1118. console.log('授权+1')
  1119. wx.requestSubscribeMessage({
  1120. tmplIds: this.arr,
  1121. success(re) {
  1122. console.log(JSON.stringify(re), 111111111111)
  1123. var datas = JSON.stringify(re);
  1124. if (datas.indexOf("accept") != -1) {
  1125. // console.log(re)
  1126. }
  1127. },
  1128. fail: (res) => {
  1129. // console.log(res)
  1130. }
  1131. })
  1132. }
  1133. if(type ==2&&url){
  1134. console.log('po','ssss')
  1135. uni.navigateTo({
  1136. url
  1137. })
  1138. }else if(type !=1&&url){
  1139. uni.navigateTo({
  1140. url:`/my/web/web?url=${url}`
  1141. })
  1142. }else{
  1143. uni.navigateTo({
  1144. url
  1145. })
  1146. }
  1147. // } else {
  1148. // uni.navigateTo({
  1149. // url: '/pages/public/login'
  1150. // })
  1151. // }
  1152. },
  1153. goShopDet(url, e,shuzu) {
  1154. if (uni.getStorageSync('sendMsg')) {
  1155. console.log('授权+1')
  1156. wx.requestSubscribeMessage({
  1157. tmplIds: this.arr,
  1158. success(re) {
  1159. console.log(JSON.stringify(re), 111111111111)
  1160. var datas = JSON.stringify(re);
  1161. if (datas.indexOf("accept") != -1) {
  1162. // console.log(re)
  1163. }
  1164. },
  1165. fail: (res) => {
  1166. // console.log(res)
  1167. }
  1168. })
  1169. }
  1170. this.shop = e
  1171. // console.log(e, '当前店铺')
  1172. let myDate = new Date();
  1173. let hours = myDate.getHours();
  1174. let minute = myDate.getMinutes();
  1175. let openTime = this.shop.businessHours.split(':')[0] //开始小时
  1176. let openTime1 = this.shop.businessHours.split(':')[1] //开始分钟
  1177. let closeTime = this.shop.lockHours.split(':')[0] //结束小时
  1178. let closeTime1 = this.shop.lockHours.split(':')[1] //结束分钟.
  1179. // console.log(hours)
  1180. // console.log(minute)
  1181. // console.log(openTime)
  1182. // console.log(openTime1)
  1183. // console.log(closeTime)
  1184. // console.log(closeTime1)
  1185. // console.log(minute >= closeTime1)
  1186. if (hours < openTime) {
  1187. this.hintShow = true
  1188. return
  1189. } else if (hours == openTime && minute < openTime1) {
  1190. this.hintShow = true
  1191. return
  1192. } else if (hours > closeTime) {
  1193. this.hintShow = true
  1194. return
  1195. } else if (hours == closeTime && minute >= closeTime1) {
  1196. this.hintShow = true
  1197. return
  1198. }
  1199. // console.log(url)
  1200. let items = encodeURIComponent(JSON.stringify(shuzu));
  1201. uni.navigateTo({
  1202. url:'/pages/index/shop/index?shopId='+url+'&huoListss='+items+'&shopTypeId='+e.shopTypeId+'&lat='+this.lat+'&lng='+this.lng
  1203. })
  1204. },
  1205. defaultAddress() {
  1206. if (uni.getStorageSync('city')) {
  1207. this.address = uni.getStorageSync('city')
  1208. this.lng = uni.getStorageSync('lng')
  1209. this.lat = uni.getStorageSync('lat')
  1210. this.page = 1
  1211. this.getShopList()
  1212. return
  1213. }
  1214. let data = {
  1215. page: 1,
  1216. limit: 1000
  1217. }
  1218. this.$Request.get('/app/address/selectAddressList', data).then(res => {
  1219. if (res.code == 0 && res.data.list.length) {
  1220. this.address = res.data.list[0].addressDetail
  1221. this.city=res.data.list[0].city
  1222. this.lng = res.data.list[0].lng
  1223. this.lat = res.data.list[0].lat
  1224. res.data.list.forEach(res => {
  1225. if (res.addressDefault) {
  1226. this.address = res.addressDetail
  1227. this.city=res.city
  1228. this.lng = res.lng
  1229. this.lat = res.lat
  1230. }
  1231. })
  1232. console.log('选择的经纬度', this.lng, this.lat)
  1233. } else {
  1234. let data = {
  1235. lat: this.lat,
  1236. lng: this.lng
  1237. }
  1238. this.$Request.get("/app/address/selectCity", data).then(res => {
  1239. if (res.code == 0) {
  1240. this.address = res.data.city
  1241. // console.log(3333333333)
  1242. // this.getShopList()
  1243. }
  1244. });
  1245. }
  1246. this.page = 1
  1247. this.getShopList()
  1248. })
  1249. },
  1250. goAddress() {
  1251. let userId = this.$queue.getData('userId');
  1252. // if (!userId) {
  1253. // uni.navigateTo({
  1254. // url: '/pages/public/login'
  1255. // })
  1256. // return
  1257. // }
  1258. uni.navigateTo({
  1259. url: '/pages/index/selectCampus'
  1260. })
  1261. },
  1262. // 查看金刚区详情
  1263. goDetail(item) {
  1264. console.log(item,'kkkk');
  1265. if (uni.getStorageSync('sendMsg')) {
  1266. console.log('授权+1',this.arr)
  1267. wx.requestSubscribeMessage({
  1268. tmplIds: this.arr,
  1269. success(re) {
  1270. console.log(JSON.stringify(re), 111111111111)
  1271. var datas = JSON.stringify(re);
  1272. if (datas.indexOf("accept") != -1) {
  1273. // console.log(re)
  1274. }
  1275. },
  1276. fail: (res) => {
  1277. // console.log(res)
  1278. }
  1279. })
  1280. }
  1281. let userId = this.$queue.getData('userId');
  1282. // if (!userId) {
  1283. // uni.navigateTo({
  1284. // url: '/pages/public/login'
  1285. // })
  1286. // return
  1287. // }
  1288. //如果是小程序跳转就是设置这个
  1289. if (item.describes) {
  1290. uni.navigateToMiniProgram({
  1291. appId: item.describes,
  1292. path: item.classifyUrl,
  1293. success: res => {
  1294. // 打开成功
  1295. console.log("打开成功", res);
  1296. },
  1297. fail: err => {
  1298. console.log(err);
  1299. }
  1300. })
  1301. return
  1302. }
  1303. if(item.url.indexOf('https:')){
  1304. uni.navigateTo({
  1305. url: item.url
  1306. });
  1307. }else{
  1308. uni.navigateTo({
  1309. url:`/my/web/web?url=${item.url}`
  1310. })
  1311. }
  1312. },
  1313. // 开启订阅消息
  1314. openMsg() {
  1315. console.log('订阅消息')
  1316. var that = this
  1317. uni.getSetting({
  1318. withSubscriptions: true, //是否获取用户订阅消息的订阅状态,默认false不返回
  1319. success(ret) {
  1320. console.log(ret.subscriptionsSetting, '------------------')
  1321. // if (ret.subscriptionsSetting.itemSettings && Object.keys(ret.subscriptionsSetting.itemSettings).length == 2) {
  1322. if (ret.subscriptionsSetting.itemSettings) {
  1323. uni.setStorageSync('sendMsg', true)
  1324. uni.openSetting({ // 打开设置页
  1325. success(rea) {
  1326. console.log(rea.authSetting)
  1327. }
  1328. });
  1329. } else { // 用户没有点击“总是保持以上,不再询问”则每次都会调起订阅消息
  1330. console.log(99999)
  1331. uni.setStorageSync('sendMsg', false)
  1332. uni.showModal({
  1333. title: '提示',
  1334. content: '为了更好的体验,请绑定消息推送',
  1335. confirmText: '确定',
  1336. cancelText: '取消',
  1337. success: function(res) {
  1338. if (res.confirm) {
  1339. console.log(that.arr)
  1340. wx.requestSubscribeMessage({
  1341. tmplIds: that.arr,
  1342. success(re) {
  1343. console.log(JSON.stringify(re),
  1344. '++++++++++++++')
  1345. var datas = JSON.stringify(re);
  1346. if (datas.indexOf("accept") != -1) {
  1347. console.log(re)
  1348. uni.setStorageSync('sendMsg', true)
  1349. }
  1350. },
  1351. fail: (res) => {
  1352. console.log(res)
  1353. }
  1354. })
  1355. uni.setStorageSync('sendMsg', true)
  1356. console.log('确认')
  1357. that.showModal = false
  1358. } else if (res.cancel) {
  1359. console.log('取消')
  1360. uni.setStorageSync('sendMsg', false)
  1361. that.showModal = true
  1362. }
  1363. }
  1364. })
  1365. }
  1366. }
  1367. })
  1368. },
  1369. // 跳转商品详情
  1370. goDet(goodsId, shopId) {
  1371. let userId = this.$queue.getData('userId');
  1372. // if (!userId) {
  1373. // uni.navigateTo({
  1374. // url: '/pages/public/login'
  1375. // })
  1376. // return
  1377. // }
  1378. uni.navigateTo({
  1379. url: '/pages/index/shop/goodsDet?goodsId=' + goodsId + '&shopId=' + shopId + '&orderType=2'
  1380. })
  1381. },
  1382. },
  1383. onReachBottom: function() {
  1384. console.log('当前长度',this.shopList.length,this.totalCount)
  1385. if (this.shopList.length < this.totalCount) {
  1386. if(this.activityId==''){
  1387. wx.showLoading({
  1388. title: '加载中...',
  1389. mask: true, // 是否显示透明蒙层,防止触摸穿透
  1390. })
  1391. this.page = this.page + 1;
  1392. this.getShopList()
  1393. }
  1394. } else {
  1395. uni.showToast({
  1396. title: '已经到底了',
  1397. icon: 'none'
  1398. })
  1399. }
  1400. },
  1401. onPullDownRefresh: function() {
  1402. if(this.activityId==''){
  1403. this.page = 1;
  1404. this.getShopList()
  1405. }
  1406. },
  1407. }
  1408. </script>
  1409. <style lang="scss" scoped>
  1410. .privacy {
  1411. position: fixed;
  1412. top: 0;
  1413. right: 0;
  1414. bottom: 0;
  1415. left: 0;
  1416. background: rgba(0, 0, 0, .5);
  1417. z-index: 9999999;
  1418. display: flex;
  1419. align-items: center;
  1420. justify-content: center;
  1421. }
  1422. .contentview {
  1423. width: 632rpx;
  1424. padding: 48rpx;
  1425. box-sizing: border-box;
  1426. background: #fff;
  1427. border-radius: 16rpx;
  1428. }
  1429. .contentview .title {
  1430. text-align: center;
  1431. color: #333;
  1432. font-weight: bold;
  1433. font-size: 32rpx;
  1434. }
  1435. .contentview .des {
  1436. font-size: 26rpx;
  1437. color: #666;
  1438. margin-top: 40rpx;
  1439. text-align: justify;
  1440. line-height: 1.6;
  1441. }
  1442. .contentview .des .link {
  1443. color: #07c160;
  1444. text-decoration: underline;
  1445. }
  1446. button::after {
  1447. border: none;
  1448. }
  1449. .btns {
  1450. margin-top: 48rpx;
  1451. display: flex;
  1452. }
  1453. .btns .item {
  1454. justify-content: space-between;
  1455. width: 244rpx;
  1456. height: 80rpx;
  1457. display: flex;
  1458. align-items: center;
  1459. justify-content: center;
  1460. border-radius: 16rpx;
  1461. box-sizing: border-box;
  1462. border: none;
  1463. }
  1464. .btns .reject {
  1465. background: #f4f4f5;
  1466. color: #909399;
  1467. }
  1468. .btns .agree {
  1469. background: #07c160;
  1470. color: #fff;
  1471. }
  1472. .hd {
  1473. width: 100%;
  1474. height: auto;
  1475. // margin-top: 20rpx;
  1476. background-color: #ffffff;
  1477. .hd-box {
  1478. width: 686rpx;
  1479. height: 100%;
  1480. // padding-top: 20rpx;
  1481. padding-bottom: 20rpx;
  1482. .scroll-view_H {
  1483. width: 100%;
  1484. white-space: nowrap;
  1485. }
  1486. .hd-box-item {
  1487. display: inline-block;
  1488. padding: 6rpx 20rpx 6rpx 20rpx;
  1489. background-color: #F7F5F6;
  1490. font-size: 24rpx;
  1491. border-radius: 16rpx;
  1492. margin-right: 10rpx;
  1493. }
  1494. }
  1495. }
  1496. .select {
  1497. padding: 6rpx 15rpx;
  1498. color: #000;
  1499. border-bottom: 6rpx solid #568D84;
  1500. }
  1501. .jxShop {
  1502. width: 100%;
  1503. height: 320rpx;
  1504. background-color: #ffffff;
  1505. .jxShop-box {
  1506. margin-top: 20rpx;
  1507. width: 686rpx;
  1508. height: 300rpx;
  1509. // background-color: #F7F5F6;
  1510. // background: linear-gradient(rgba(252,210,2,0.4) 1%,#fffdf2 100%);
  1511. // background: linear-gradient(#ffee99 1%,#fffbe5 100%);
  1512. background: #fff8d3;
  1513. border-radius: 16rpx;
  1514. .jxShop-box-c {
  1515. width: 626rpx;
  1516. height: 100%;
  1517. }
  1518. .jxShop-box-c-title {
  1519. width: 100%;
  1520. margin-top: 20rpx;
  1521. }
  1522. .jxShop-box-c-title-l {
  1523. color: #1A1A1A;
  1524. font-size: 34rpx;
  1525. font-weight: 800;
  1526. }
  1527. .jxShop-box-c-title-r {
  1528. color: #1E1F31;
  1529. font-size: 26rpx;
  1530. font-weight: 500;
  1531. }
  1532. .jxShop-box-c-list {
  1533. width: 100%;
  1534. height: 190rpx;
  1535. margin-top: 20rpx;
  1536. }
  1537. .jxShop-box-c-list-item {
  1538. width: 149rpx;
  1539. height: 100%;
  1540. background: #ffffff;
  1541. border-radius: 8px;
  1542. image {
  1543. width: 100%;
  1544. height: 114rpx;
  1545. border-radius: 8rpx 8rpx 0 0;
  1546. }
  1547. .jxShop-box-c-list-item-name {
  1548. width: 149rpx;
  1549. text-align: center;
  1550. font-size: 28rpx;
  1551. color: #1A1A1A;
  1552. font-weight: bold;
  1553. margin-top: 10rpx;
  1554. overflow: hidden;
  1555. white-space: nowrap;
  1556. text-overflow: ellipsis;
  1557. padding-left: 10rpx;
  1558. padding-right: 10rpx;
  1559. }
  1560. }
  1561. }
  1562. }
  1563. .huodong {
  1564. width: 100%;
  1565. height: 380rpx;
  1566. // margin-top: 20rpx;
  1567. background-color: #ffffff;
  1568. .huodong-box {
  1569. margin-top: 20rpx;
  1570. width: 686rpx;
  1571. height: 360rpx;
  1572. // background-color: #D4FCE2;
  1573. background-color: #fff8d3;
  1574. border-radius: 24rpx;
  1575. .huodong-box-c {
  1576. width: 646rpx;
  1577. height: 100%;
  1578. }
  1579. .huodong-box-c-title {
  1580. margin-top: 20rpx;
  1581. }
  1582. .huodong-box-c-title-l {
  1583. // color: #34CD40;
  1584. color: rgba(252, 210, 2, 1);
  1585. font-size: 44rpx;
  1586. font-weight: 600;
  1587. image {
  1588. width: 276rpx;
  1589. height: 65rpx;
  1590. }
  1591. // font-style: italic;
  1592. }
  1593. .huodong-box-c-title-r {
  1594. // background: linear-gradient(114deg, rgba(252, 210, 2, 0.2) 0%, rgba(252, 210, 2, 0.5) 50%, rgba(252, 210, 2, 1) 100%);
  1595. background-color: #FFE3C7;
  1596. border-radius: 40rpx;
  1597. color: #FF8D1A;
  1598. font-size: 26rpx;
  1599. font-weight: 600;
  1600. padding: 10rpx 20rpx;
  1601. }
  1602. .huodong-box-c-list {
  1603. width: 100%;
  1604. height: 320rpx;
  1605. margin-top: 10rpx;
  1606. }
  1607. .huodong-box-c-list-l {
  1608. width: 190rpx;
  1609. height: 250rpx;
  1610. background: linear-gradient(0deg, #34CD41 0%, #48DB19 100%);
  1611. border-radius: 24rpx;
  1612. }
  1613. .huodong-box-c-list-l-t {
  1614. width: 180rpx;
  1615. height: 240rpx;
  1616. border-radius: 24rpx;
  1617. background-color: #ffffff;
  1618. margin-top: 5rpx;
  1619. }
  1620. .huodong-box-c-list-l-t>image {
  1621. width: 160rpx;
  1622. height: 170rpx;
  1623. margin-top: 10rpx;
  1624. border-radius: 24rpx;
  1625. }
  1626. .huodong-box-c-list-l-t-b {
  1627. width: 100%;
  1628. height: 56rpx;
  1629. background-color: #E0F7F1;
  1630. color: #36CF3D;
  1631. font-size: 30rpx;
  1632. border-radius: 24rpx;
  1633. }
  1634. .huodong-box-c-list-l-t-t {
  1635. width: 100%;
  1636. text-align: center;
  1637. font-size: 36rpx;
  1638. // font-weight: bold;
  1639. font-weight: 600;
  1640. color: #ffffff;
  1641. }
  1642. .huodong-box-c-list-c {
  1643. width: 220rpx;
  1644. height: 280rpx;
  1645. background: linear-gradient(0deg, #34CD41 0%, #48DB19 100%);
  1646. border-radius: 24rpx;
  1647. }
  1648. .huodong-box-c-list-c-t {
  1649. width: 211rpx;
  1650. height: 270rpx;
  1651. border-radius: 24rpx;
  1652. background-color: #ffffff;
  1653. margin-top: 5rpx;
  1654. }
  1655. .huodong-box-c-list-c-t>image {
  1656. width: 186rpx;
  1657. height: 190rpx;
  1658. margin-top: 10rpx;
  1659. border-radius: 24rpx;
  1660. }
  1661. .huodong-box-c-list-c-b {
  1662. width: 100%;
  1663. height: 70rpx;
  1664. background-color: #E0F7F1;
  1665. color: #36CF3D;
  1666. font-size: 30rpx;
  1667. border-radius: 24rpx;
  1668. }
  1669. .huodong-box-c-list-c-t-t {
  1670. width: 100%;
  1671. text-align: center;
  1672. font-size: 36rpx;
  1673. // font-weight: bold;
  1674. font-weight: 600;
  1675. color: #ffffff;
  1676. }
  1677. }
  1678. }
  1679. .search-btn {
  1680. width: 132rpx;
  1681. height: 80rpx;
  1682. font-size: 28rpx;
  1683. text-align: center;
  1684. line-height: 80rpx;
  1685. background: linear-gradient(90.25deg, #77A69A 0%, #558C83 100%);
  1686. border-radius: 36px;
  1687. color:#fff;
  1688. }
  1689. .address {
  1690. width: 100%;
  1691. background: linear-gradient(135deg, rgba(129, 189, 179, 1) 0%, rgba(236, 246, 206, 1) 100%);
  1692. display: flex;
  1693. align-items: center;
  1694. // #ifndef H5
  1695. position: fixed;
  1696. top: 0;
  1697. height: 180rpx;
  1698. // line-height: 260rpx;
  1699. padding: 80rpx 34rpx 0rpx;
  1700. // #endif
  1701. // #ifdef H5
  1702. height: 80rpx;
  1703. line-height: 80rpx;
  1704. padding: 0 34rpx;
  1705. // #endif
  1706. font-size: 32rpx;
  1707. z-index: 999;
  1708. .address_name {
  1709. max-width: 90%;
  1710. overflow: hidden;
  1711. text-overflow: ellipsis;
  1712. white-space: nowrap;
  1713. }
  1714. }
  1715. .lable {
  1716. border: 1rpx solid #FFE6D9;
  1717. height: 40rpx;
  1718. padding: 0 14rpx;
  1719. background: #FFE6D9;
  1720. border-radius: 4rpx;
  1721. font-weight: 500;
  1722. color: #FD6416;
  1723. font-size: 20rpx;
  1724. margin-right: 10rpx;
  1725. margin-bottom: 10rpx;
  1726. }
  1727. .tabs {
  1728. margin-bottom: 20rpx;
  1729. display: flex;
  1730. justify-content: space-between;
  1731. align-items: center;
  1732. }
  1733. .tabs_name {
  1734. flex: 1;
  1735. /* display: inline-block; */
  1736. text-align: center;
  1737. margin-bottom: 30rpx 0;
  1738. position: relative;
  1739. display: flex;
  1740. /* justify-content: space-between; */
  1741. align-items: center;
  1742. }
  1743. .tabs_name view {
  1744. margin: 0 auto;
  1745. display: flex;
  1746. align-items: center;
  1747. }
  1748. .tabs_2 {
  1749. /* width: 30%; */
  1750. }
  1751. .actives {
  1752. color: #007AFF;
  1753. }
  1754. .tabsicon {
  1755. position: absolute;
  1756. top: 0;
  1757. right: 22rpx;
  1758. width: 20rpx;
  1759. height: 40rpx;
  1760. z-index: 1;
  1761. }
  1762. .tabs_icon {
  1763. width: 12rpx;
  1764. height: 8rpx;
  1765. z-index: 1;
  1766. margin-left: 10rpx;
  1767. }
  1768. .icon1 {
  1769. /* position: absolute; */
  1770. /* top: 6rpx; */
  1771. }
  1772. .icon2 {
  1773. position: absolute;
  1774. bottom: 6rpx;
  1775. }
  1776. .page-box {
  1777. // position: relative;
  1778. // z-index: 0;
  1779. // top: 70px;
  1780. }
  1781. .centre {
  1782. margin: auto;
  1783. height: 400rpx;
  1784. text-align: center;
  1785. font-size: 32rpx;
  1786. }
  1787. .centre image {
  1788. width: 387rpx;
  1789. height: 341rpx;
  1790. margin: 40rpx auto 20rpx;
  1791. }
  1792. .centre .tips {
  1793. font-size: 32rpx;
  1794. color: #2F3044;
  1795. margin: 20rpx 0 40rpx;
  1796. font-weight: 700;
  1797. }
  1798. .hintPopul {
  1799. width: 100%;
  1800. height: 100%;
  1801. position: fixed;
  1802. top: 0;
  1803. background: rgba(0, 0, 0, .4);
  1804. z-index: 999;
  1805. }
  1806. .content_ {
  1807. position: absolute;
  1808. left: 0;
  1809. right: 0;
  1810. top: 0;
  1811. bottom: 0;
  1812. margin: auto;
  1813. text-align: center;
  1814. width: 500rpx;
  1815. height: 400rpx;
  1816. border-radius: 20rpx;
  1817. background-color: #fff;
  1818. padding-top: 120rpx;
  1819. }
  1820. .content_ image {
  1821. position: absolute;
  1822. top: -50rpx;
  1823. left: 0;
  1824. right: 0;
  1825. margin: auto;
  1826. }
  1827. .hintText {
  1828. font-size: 30rpx;
  1829. }
  1830. .skuBtn {
  1831. width: 460rpx;
  1832. height: 60rpx;
  1833. line-height: 60rpx;
  1834. text-align: center;
  1835. background: #FCD202;
  1836. font-size: 28rpx;
  1837. border: 2rpx solid #FCD202;
  1838. color: #333333;
  1839. border-radius: 50rpx;
  1840. font-weight: 700;
  1841. margin: auto;
  1842. }
  1843. .hongbao {
  1844. width: 100%;
  1845. /* height: 100px; */
  1846. /* background: #007AFF; */
  1847. position: fixed;
  1848. top: 34%;
  1849. /* bottom: 50%; */
  1850. left: 0rpx;
  1851. right: 0rpx;
  1852. /* display: none; */
  1853. }
  1854. .hb_img {
  1855. width: 100%;
  1856. height: 535rpx;
  1857. }
  1858. .hb_btn {
  1859. width: 70%;
  1860. height: 72rpx;
  1861. position: absolute;
  1862. top: 315rpx;
  1863. left: 80rpx;
  1864. }
  1865. .serviceBtn{
  1866. position: fixed;
  1867. right: 52rpx;
  1868. bottom: 50rpx;
  1869. display: flex;
  1870. flex-direction: column;
  1871. align-items: center;
  1872. justify-content: center;
  1873. width: 100rpx;
  1874. height: 120rpx;
  1875. color: #fff;
  1876. font-size: 20rpx;
  1877. background-image: url(@/static/images/my/kefu.png);
  1878. background-repeat: no-repeat;
  1879. background-size: contain;
  1880. }
  1881. </style>