merchantdetail.vue 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875
  1. <template>
  2. <view style="background-color: whitesmoke;">
  3. <customNav :shownav="true" :title="posName" titledetl=""></customNav>
  4. <view style="width: 100%;height: 80rpx;background-color: #40AE36;"></view>
  5. <view class="nodetail">
  6. <view class="contentInRowS" style="width: 100%;" @click="gengduozx">
  7. <netImage style="margin-left: 12rpx;margin-top: -20rpx;" width="140" height="140" bradius="70" :mysrc="mendianMs.logo" mymode="scaleToFill"></netImage>
  8. <view class="contentColumn" style="width: 500rpx;margin-right: 20rpx;margin-top: 4rpx;">
  9. <view class="contentColumn">
  10. <text class="dianpuming">{{mendianMs.posName}}</text>
  11. <text class="peisongsuoming">{{$t('index.manX')}} {{$formPr(mendianMs.posPrice)}} {{$t('locale.huobidw')}}</text>
  12. <text v-if="mendianMs.state==1" style="margin-top: 10rpx;color: darkgreen;font-size: 28rpx;padding-right: 40rpx;">{{$t('mend.statedy')}}</text>
  13. </view>
  14. </view>
  15. </view>
  16. <view class="contentInRowL" style="margin-left: 40rpx;margin-top: 10rpx;margin-right: 40rpx;">
  17. <view class="contentColumnC" style="width: 24%;">
  18. <image class="actimge" :src="shouchangIcon" mode="aspectFit" @click="shouchang"></image>
  19. <text class="textfontS3">{{$t('index.shouchang')}}</text>
  20. </view>
  21. <view class="contentColumnC" style="width: 24%;">
  22. <image class="actimge" src="/static/images/daipinglun@3x.png" mode="aspectFit" @click="pinglunList"></image>
  23. <text class="textfontS3">{{$t('index.pinglun')}}</text>
  24. </view>
  25. <view class="contentColumnC" style="width: 24%;">
  26. <image class="actimge" src="/static/images/kefufuwu.png" mode="aspectFit" @click="callPhone"></image>
  27. <text class="textfontS3">{{$t('mend.kefudianhua')}}</text>
  28. </view>
  29. </view>
  30. <view style="height: 20rpx;"></view>
  31. </view>
  32. <view v-if="cuxiaoImge.length==0">
  33. <netImage style="margin-top:20rpx;margin-left: 25rpx;" width="700" height="400" bradius="6" :mysrc="mendianMs.image" mymode="scaleToFill"></netImage>
  34. </view>
  35. <view v-if="cuxiaoImge.length>0"><!-- 促销活动 -->
  36. <swiperImgs style="margin-top: 20rpx;" width="750" height="400" :imageList="cuxiaoImge"></swiperImgs>
  37. </view>
  38. <view style="margin-top: 40rpx;" >
  39. <view class="menuBox" :style="{height: statickH+'rpx'}">
  40. <view class="menuContent" :style="{height: statickH-120+'rpx'}">
  41. <scroll-view scroll-y="true" class="menuLeft">
  42. <view class="menuType" @click="changeCurrent(index)" v-for="(item,index) in prdList"
  43. :class="{currentMenu:currentIndex==index}">
  44. <text class="text2row">{{item.name}}</text>
  45. </view>
  46. <view class="line" :style="{top:currentIndex*100 +'rpx'}"></view>
  47. <view style="height: 120rpx;"></view>
  48. </scroll-view>
  49. <scroll-view :scroll-top="scrollTop" @scroll="scrollRight" class="menuRight" scroll-y="true">
  50. <div class="menuDetailBox" v-for="(item,index) in prdList" :key="index">
  51. <div class="title">{{item.name}}</div>
  52. <div class="menu" v-for="(menu,index) in item.children" :key="index">
  53. <div class="d2" @click="shangpinsl(menu.shangpin.id)">
  54. <netImage style="margin-top: 10rpx;" width="180" height="180" :mysrc="menu.shangpin.image" mymode="scaleToFill"></netImage>
  55. </div>
  56. <div class="menuName" >
  57. <view class="contentColumnS" style="height: 200rpx;">
  58. <view class="contentColumn" style="width: 100%;" @click="shangpinsl(menu.shangpin.id)">
  59. <text class="pdName text2row">{{menu.shangpin.name}}</text>
  60. <text class="pdDetail text2row">{{menu.shangpin.introduce}}</text>
  61. </view>
  62. <view class="contentColumn" style="width: 100%;">
  63. <!-- <view class="contentInRowL">
  64. <text class="redktext">特价</text>
  65. <text class="greedKtext" style="margin-left: 10rpx;">24H发货</text>
  66. </view> -->
  67. <view class="contentInRowS">
  68. <view class="">
  69. <text class="pricetext">{{menu.shangpin.price}}</text>
  70. <text class="pricedw">{{$t("locale.huobidw")}}</text>
  71. <text class="yuanjia">{{menu.shangpin.price}}{{$t("locale.huobidw")}}</text>
  72. </view>
  73. <image style="width: 50rpx;height: 50rpx;margin-bottom: 6rpx;" src="/static/meishi/BuyS@3x.png" mode="" @click="editSKU(menu)"></image>
  74. </view>
  75. </view>
  76. </view>
  77. </div>
  78. </div>
  79. </div>
  80. <view style="height: 120rpx;"></view>
  81. </scroll-view>
  82. </view>
  83. </view>
  84. </view>
  85. <view class="bottomfloatV">
  86. <view class="buyBT">
  87. <image class="gouwuche" :src="gouwcheimg" mode="aspectFit" @click="gotoGouwuche"></image>
  88. <text class="peisongsuoming">{{notext}}</text>
  89. <text class="qjs" :style="{backgroundColor:gwbcolor,color:gwbTcolor}" @click="gotojiesuan">{{$t('comp.qujiesuan')}}</text>
  90. </view>
  91. </view>
  92. <popViewGG :show="showpop" :showbotom="false" :maskClosable="true" :isCancel="true" @chooseCancel="chooseCancel">
  93. <pdPurchase style="width:100%;max-height: 70vh" :food="spindexSP" v-on:Ejiagouwuche="jiagouwuche"></pdPurchase>
  94. </popViewGG>
  95. </view>
  96. </template>
  97. <script>
  98. import api from "@/pages/api/api.js";
  99. export default {
  100. data() {
  101. return {
  102. //------------------------------
  103. newData:[], // 拿到右侧所有的商品列表元素
  104. scrollTop: 0,
  105. currentIndex: 0,
  106. prdList:[],
  107. //-----========
  108. cuxiaoImge:[],
  109. id:1,
  110. userid:0,
  111. mendianMs:[],
  112. posName:'',
  113. isfirstShow:0,
  114. isShouchang:0,
  115. shouchangIcon:'/static/images/faver@3x.png',
  116. option: {},
  117. login:false,
  118. showpop:false,
  119. gouwuche:[],
  120. shangpinfenlei:[],
  121. spindexSP:'',//当前分类商品操作商品
  122. gouwcheimg:'/static/meishi/BuyS@3x.png',
  123. notext:this.$t('comp.weixgsp'),
  124. goumaijine:0,
  125. gwbcolor:'darkgray',
  126. gwbTcolor:'black',
  127. startX:0,
  128. startY:0,
  129. lang:'3',
  130. statickH:0,
  131. }
  132. },
  133. onShow() {
  134. if(0==this.isfirstShow){
  135. this.getmendianDetail(this.id);
  136. this.isfirstShow=1;
  137. }
  138. else{
  139. this.refreshPurchase();
  140. }
  141. var that =this;
  142. try {//读取
  143. that.token = uni.getStorageSync("token");
  144. //console.log('2222',that.token)
  145. if(that.token == '' || that.token == undefined || that.token == null){
  146. that.login=false;
  147. return;
  148. }
  149. else{
  150. that.login=true;
  151. return;
  152. }
  153. } catch(e){//错误
  154. return;
  155. }
  156. },
  157. onLoad(option) {
  158. var language = uni.getStorageSync('language');
  159. if(language=='yuenan'){
  160. this.lang='0';
  161. }
  162. if(language=='zh-Hans'){
  163. this.lang='2';
  164. }
  165. if(language=='zh-Hant'){
  166. this.lang='3';
  167. }
  168. this.id=option.id;
  169. this.jiagouwuche();
  170. uni.pageScrollTo({
  171. scrollTop:0,
  172. duration:0
  173. })
  174. var info = uni.getSystemInfoSync();
  175. var isAndroid = info.platform.toLowerCase() === 'android';
  176. console.log(info);
  177. if(isAndroid){
  178. this.statickH=info.screenHeight*2-140-60;
  179. }
  180. else{
  181. this.statickH=info.screenHeight*2-180-60;
  182. }
  183. },
  184. methods: {
  185. //----------------------------------
  186. changeCurrent(index) {
  187. this.currentIndex = index
  188. this.scrollTop = this.newData[index-1]?.offsetHeight || 0
  189. },
  190. scrollRight(e) {
  191. // console.log(e.detail.scrollTop,'scrollRight');
  192. const query = uni.createSelectorQuery().in(this);
  193. for (let i = 0; i < this.newData.length; i++) {
  194. let el = this.newData[i]
  195. if (e.detail.scrollTop < el.offsetHeight) {
  196. this.currentIndex = i
  197. return true
  198. }
  199. }
  200. },
  201. getmendianshangpinFL(id){
  202. api('getmendianshangpinFL',{
  203. id:id,
  204. language:this.lang
  205. },res=>{
  206. this.shangpinfenlei=res.data.data;
  207. console.log(this.shangpinfenlei)
  208. this.initFenlei();
  209. },failc=>{
  210. uni.hideLoading();
  211. //console.log('getadvertis----',failc)
  212. })
  213. },
  214. initFenlei(){
  215. this.prdList=[];
  216. if(this.shangpinfenlei&&this.shangpinfenlei.length>0){
  217. for (var i = 0; i < this.shangpinfenlei.length; i++) {
  218. var el = this.shangpinfenlei[i];
  219. var temp = {
  220. "id": el.id,
  221. "index": i+1,
  222. "name": el.name,
  223. "children": [
  224. ]
  225. }
  226. this.prdList.push(temp);
  227. }
  228. }
  229. this.initproduct();
  230. },
  231. initproduct(){
  232. if(this.prdList.length==0){
  233. uni.hideLoading();
  234. return;
  235. }
  236. this.getmendianshangpinList(0);
  237. },
  238. getmendianshangpinList(index){
  239. var obj = this.prdList[index];
  240. api('getmendianshangpinList',{
  241. id:obj.id,
  242. language:this.lang
  243. },r=>{
  244. console.log(r);
  245. this.prdList[index].children= this.dowithshangpinList(r.data.data);
  246. if(index+1<this.prdList.length){
  247. this.getmendianshangpinList(index+1);
  248. }
  249. else{
  250. console.log(this.prdList);
  251. this.initNewData();
  252. uni.hideLoading();
  253. }
  254. },failc=>{
  255. uni.hideLoading();
  256. //console.log('getadvertis----',failc)
  257. })
  258. },
  259. dowithshangpinList(shangpinlist){
  260. var tempList = [];
  261. if(shangpinlist){
  262. for(var j=0;j<shangpinlist.length;j++){
  263. var shuliang = this.tongbugouwuchexinxi(shangpinlist[j]);
  264. var otherPrice = this.getotherPrice(shangpinlist[j].foodSku);
  265. var tempSKU = this.gettempSKU(shangpinlist[j].foodSku);
  266. var tempsp={
  267. "shangpin":shangpinlist[j],
  268. "sku":tempSKU,
  269. "otherPrice":otherPrice,
  270. "shuliang":shuliang
  271. }
  272. tempList.push(tempsp);
  273. }
  274. }
  275. return tempList;
  276. },
  277. initNewData(){
  278. const query = uni.createSelectorQuery().in(this);
  279. query.selectAll('.menuDetailBox').boundingClientRect(data => {
  280. console.log('所有分类项:', data);
  281. this.newData = data.map((item, index) => {
  282. function fgfg(total) {
  283. let sum = 0
  284. for (var i = 0; i <= total; i++) {
  285. sum += data[i].height
  286. }
  287. return sum
  288. }
  289. item.offsetHeight = fgfg(index)
  290. return item
  291. })
  292. }).exec();
  293. },
  294. refreshPurchase(){
  295. if(this.prdList.length<=0){
  296. return;
  297. }
  298. for(var j=0;j<this.prdList.length;j++){
  299. var children = this.prdList[j].children;
  300. var tempList = [];
  301. for(var i=0;i<children.length;i++){
  302. var obj = children[i];
  303. var shuliang = this.tongbugouwuchexinxi(obj.shangpin);
  304. var otherPrice = this.getotherPrice(obj.shangpin.foodSku);
  305. var tempSKU = this.gettempSKU(obj.shangpin.foodSku);
  306. obj.sku = tempSKU;
  307. obj.otherPrice = otherPrice;
  308. obj.shuliang = shuliang;
  309. tempList.push(obj);
  310. }
  311. this.prdList[j].children = tempList;
  312. }
  313. },
  314. //------------------------------------------------------------------------------
  315. fanhui(){
  316. uni.navigateBack();
  317. },
  318. shareToggle() {
  319. this.$refs.share.open()
  320. },
  321. chooseCancel(){
  322. this.showpop=false;
  323. },
  324. fenxiang(item,index){
  325. this.option={
  326. //绘制海报内容
  327. //codeUrl: 'https://pic1.zhimg.com/80/v2-2714df42147132464a71af391ed04be4_720w.jpg', //小程序太阳码
  328. codeUrl: '/static/defimages/erweim.png', //小程序太阳码
  329. coverUrl: '/static/defimages/ddd.png', //题库图片
  330. headUrl: '/static/logo.png', //头像
  331. //bgUrl: 'https://pic3.zhimg.com/v2-8fbde0f9ac6a19a23aa839e73394618a_b.jpg', //图片背景填充,和 fillStyle 只能传一个,bgUrl 优先级高于 fillStyle
  332. fillStyle: '#00A6FF', //纯色背景填充颜色
  333. nickName: '美食达', //授权登录的用户名
  334. miniName: '不出门吃遍全世界', //小程序名称
  335. tkName:this.posName, //题库名称
  336. tkAuthor:'门店介绍', //题库作者
  337. tkType: '外送', //题库类型
  338. cost: '自取', //是否需要收费 免费/付费
  339. isPub: '堂食' //公开 还是 私有
  340. };
  341. this.$refs.draw.share_qrcode(this.option);
  342. },
  343. shouchang(){
  344. this.addcollect();
  345. },
  346. callPhone(){
  347. var that = this;
  348. uni.showModal({
  349. title: that.$t('api.message'),
  350. content: that.$t('api.nqdbddh'),
  351. cancelText:that.$t('order.quxiao'),
  352. confirmText:that.$t('comp.queren'),
  353. success: function (res) {
  354. if (res.confirm) { //这里是点击了确定以后
  355. console.log(that.mendianMs.telephone)
  356. plus.device.dial(that.mendianMs.telephone, false );
  357. } else { //这里是点击了取消以后
  358. console.log('用户点击取消')
  359. }
  360. }
  361. })
  362. },
  363. gengduozx(){
  364. uni.navigateTo({
  365. url:'/pages/shanpinxungou/shangjia/gengduozhixun?mendid='+this.id
  366. })
  367. },
  368. pinglunList(){
  369. uni.navigateTo({
  370. url:'/pages/pinglun/pingLunList?mendid='+this.id
  371. })
  372. },
  373. shangpinsl(id){
  374. //选择商品
  375. uni.navigateTo({
  376. url:'/pages/shanpinxungou/shangpin/shangpinxiangqing?id='+id
  377. })
  378. },
  379. gotoGouwuche(){
  380. if(!this.showbt){
  381. uni.showToast({
  382. title: this.$t('comp.qingxzsp'),
  383. icon: 'none',
  384. duration: 2500
  385. })
  386. return;
  387. }
  388. //跳转购物车
  389. uni.navigateTo({
  390. url:'/pages/shanpinxungou/shangjia/shoppingCart'
  391. })
  392. },
  393. gotojiesuan(){
  394. if(this.mendianMs.state==1){
  395. uni.showToast({
  396. title: this.$t('mend.statedy'),
  397. icon: 'none',
  398. duration: 2500
  399. })
  400. return;
  401. }
  402. if(!this.showbt){
  403. uni.showToast({
  404. title: this.$t('comp.qingxzsp'),
  405. icon: 'none',
  406. duration: 2500
  407. })
  408. return;
  409. }
  410. var token = uni.getStorageSync("token");
  411. //console.log('2222',token)
  412. if(token == '' || token == undefined || token == null){
  413. uni.navigateTo({
  414. url:'/pages/UserCenter/LoginView'
  415. })
  416. return;
  417. }
  418. uni.navigateTo({
  419. url:'/pages/OrderList/buy/dingdanjiesuan'
  420. })
  421. },
  422. //------------------------------------
  423. addcollect(){
  424. if(!this.login){
  425. uni.navigateTo({
  426. url:'/pages/UserCenter/LoginView'
  427. })
  428. }
  429. console.log('addcollect:id',this.id);
  430. api('addcollect',{
  431. mdid:this.id
  432. },res=>{
  433. console.log(res)
  434. if(this.isShouchang==0){
  435. this.isShouchang=1;
  436. this.shouchangIcon='/static/images/faverr@3x.png'
  437. }
  438. else{
  439. this.isShouchang=0;
  440. this.shouchangIcon='/static/images/faver@3x.png'
  441. }
  442. },failc=>{
  443. //console.log('getadvertis----',failc)
  444. })
  445. },
  446. getmendianDetail(id){
  447. //console.log('getmendianDetail:id',id);
  448. uni.showLoading({
  449. mask:true
  450. })
  451. api('getmendianDetail',{
  452. id:id
  453. },r=>{
  454. console.log(r.data.data);
  455. this.mendianMs=r.data.data;
  456. this.userid=this.mendianMs.userId;
  457. this.posName=this.mendianMs.posName;
  458. this.isShouchang=this.mendianMs.Collect;
  459. if(this.isShouchang==1){
  460. this.shouchangIcon='/static/images/faverr@3x.png'
  461. }
  462. else{
  463. this.shouchangIcon='/static/images/faver@3x.png'
  464. }
  465. this.getmendianshangpinFL(id);
  466. this.cuxiaoList();
  467. },failc=>{
  468. uni.hideLoading();
  469. //console.log('getadvertis----',failc)
  470. })
  471. },
  472. cuxiaoList(){
  473. api('cuxiaoList',{
  474. mdId:this.id,
  475. price:''
  476. },r=>{
  477. //console.log('-----------',r)
  478. if(r.data.code==200){
  479. this.cuxiaoImge=[];
  480. var objs = r.data.data;
  481. for(var i=0;i<objs.length;i++){
  482. var obj=objs[i];
  483. if(obj.poster&&obj.poster.length>0){
  484. this.cuxiaoImge.push(obj.poster);
  485. }
  486. }
  487. }
  488. },failc=>{
  489. //console.log('getadvertis----',failc)
  490. })
  491. },
  492. //--------------------------------------
  493. tongjigouwuche(){
  494. this.goumaijine = 0;
  495. for(var i=0;i<this.gouwuche.length;i++){
  496. var item = this.gouwuche[i];
  497. var yidongjine=item.amount;
  498. this.goumaijine = this.goumaijine+yidongjine;
  499. }
  500. this.jinger();
  501. },
  502. tongbugouwuchexinxi(sp){
  503. var tempshuliang = 0;
  504. for(var i=0;i<this.gouwuche.length;i++){
  505. var item = this.gouwuche[i];
  506. for(var j=0;j<item.food.length;j++){
  507. if(item.food[j].id == sp.id){
  508. tempshuliang = tempshuliang + item.food[j].number;
  509. }
  510. }
  511. }
  512. return tempshuliang;
  513. },
  514. jiagouwuche(){
  515. var gwc = uni.getStorageSync('gouwuche');
  516. if(''==gwc||null==gwc||undefined==gwc){
  517. this.gouwuche=[];
  518. }
  519. else{
  520. this.gouwuche = JSON.parse(gwc);
  521. }
  522. this.refreshPurchase();
  523. this.tongjigouwuche();
  524. this.showpop=false;
  525. },
  526. jinger(){
  527. if(this.goumaijine>0){
  528. this.notext=this.$formPr(this.goumaijine)+this.$t('locale.huobidw');
  529. console.log(this.notext);
  530. this.gwbcolor='green';
  531. this.gwbTcolor='white';
  532. this.gouwcheimg='/static/meishi/BuyS@3x.png';
  533. this.showbt=true;
  534. }
  535. if(this.goumaijine==0){
  536. this.gwbcolor='darkgray';
  537. this.gwbTcolor='black';
  538. this.notext=this.$t('comp.weixgsp');
  539. this.gouwcheimg='/static/meishi/BuyS@3x.png';
  540. this.showbt=false;
  541. }
  542. },
  543. editSKU(sp){
  544. console.log(sp);
  545. this.spindexSP = sp;
  546. this.showpop=true;
  547. //this.$refs.popup.open();
  548. },
  549. gettempSKU(foodSku){
  550. var selectsku=[];
  551. for(var i=0;i<foodSku.length;i++){
  552. if(foodSku[i].objects.length>0){
  553. for(var j=0;j<foodSku[i].objects.length;j++){
  554. if(foodSku[i].objects[j].state==1){
  555. selectsku.push(foodSku[i].objects[j].name);
  556. }
  557. }
  558. }
  559. }
  560. return selectsku;
  561. },
  562. getotherPrice(foodSku){
  563. var jiner=0;
  564. for(var i=0;i<foodSku.length;i++){
  565. if(foodSku[i].objects.length>0){
  566. for(var j=0;j<foodSku[i].objects.length;j++){
  567. if(foodSku[i].objects[j].state==1){
  568. jiner=jiner+parseFloat(foodSku[i].objects[j].price);
  569. }
  570. }
  571. }
  572. }
  573. return parseFloat(jiner);
  574. },
  575. }
  576. }
  577. </script>
  578. <style lang="scss" scoped>
  579. page{
  580. background-color: #F2F3F7;
  581. }
  582. .box{
  583. height: 100upx;
  584. line-height: 100upx;
  585. text-align: center;
  586. background-color:white;
  587. }
  588. .fixedTop{
  589. position: fixed;
  590. top:140rpx;
  591. left: 0;
  592. right: 0;
  593. z-index: 9999999;
  594. }
  595. .fixedTopios{
  596. position: fixed;
  597. top:180rpx;
  598. left: 0;
  599. right: 0;
  600. z-index: 9999999;
  601. }
  602. //-----------------------------
  603. .nodetail{
  604. width: 94%;
  605. margin-left: 3%;
  606. margin-top: -40rpx;
  607. background-color: white;
  608. border-radius: 10rpx;
  609. }
  610. .fenleiTitle{
  611. padding-left: 16rpx;
  612. padding-right: 16rpx;
  613. line-height: 36rpx;
  614. font-size: 28rpx;
  615. border-radius: 20rpx;
  616. color: darkgray;
  617. background-color: white;
  618. border: 1rpx solid darkgray;
  619. }
  620. .page-view {
  621. background-color:#F2F3F7;
  622. }
  623. .actimgeCT{
  624. position: fixed;
  625. width: 94%;
  626. left: 3%;
  627. top: 100rpx;
  628. z-index: 9;
  629. }
  630. .actimge{
  631. width: 60rpx;
  632. height: 60rpx;
  633. }
  634. .buyBT{
  635. display:flex;
  636. flex-direction: row;
  637. justify-content:left;
  638. align-items: center;
  639. width: 100%;
  640. margin-top: 10rpx;
  641. }
  642. .gouwuche{
  643. margin-left: 20rpx;
  644. width: 80rpx;
  645. height: 80rpx;
  646. }
  647. .dianpuming{
  648. font-size: 30rpx;
  649. line-height: 32rpx;
  650. height: 32rpx;
  651. font-weight: bold;
  652. overflow: hidden;
  653. text-overflow: ellipsis;
  654. /* #ifndef APP-PLUS-NVUE */
  655. display: -webkit-box;
  656. -webkit-line-clamp: 1;
  657. -webkit-box-orient: vertical;
  658. /* #endif */
  659. }
  660. .peisongsuoming{
  661. font-size: 26rpx;
  662. line-height: 38rpx;
  663. height: 38rpx;
  664. color: dimgray;
  665. }
  666. .bottomfloatV{
  667. position: fixed;
  668. flex-direction: row;
  669. align-items: center;
  670. left: 0;
  671. right: 0;
  672. bottom: 0;
  673. z-index: 999;
  674. background-color: whitesmoke;
  675. height: 120rpx;
  676. }
  677. .qjs{
  678. border-radius: 30rpx;
  679. padding-left: 26rpx;
  680. padding-right: 26rpx;
  681. margin-left: auto;
  682. margin-right: 30rpx;
  683. font-size: 32rpx;
  684. height: 60rpx;
  685. line-height: 60rpx;
  686. }
  687. .fenleiitem{
  688. text-align:center;
  689. margin-top: 12rpx;
  690. margin-bottom: 12rpx;
  691. width:660upx;
  692. border-radius: 10rpx;
  693. color: darkblue;
  694. line-height: 54rpx;
  695. font-size: 28rpx;
  696. border: solid lavender;
  697. border-width: 0px 0px 1rpx 0px;
  698. }
  699. //-----------------------------
  700. .menuBox {
  701. // height: calc(100vh);
  702. display: flex;
  703. flex-direction: column;
  704. // border: 1px solid #ccc;
  705. margin: 0 10rpx;
  706. .menuContent {
  707. height: 100%;
  708. overflow: auto;
  709. position: relative;
  710. display: flex;
  711. position: sticky;
  712. top: 0rpx;
  713. .menuLeft {
  714. float: left;
  715. position: relative;
  716. width: 200rpx;
  717. background-color: #f5f5f5;
  718. .menuType {
  719. transition: all 0.4s;
  720. position: relative;
  721. z-index: 999999999;
  722. height: 100rpx;
  723. display: flex;
  724. align-items: center;
  725. padding-left: 20rpx;
  726. &.currentMenu {
  727. font-weight: 700;
  728. }
  729. }
  730. }
  731. .menuRight {
  732. flex: 1;
  733. background-color:lavender;
  734. .menuDetailBox {
  735. .title {
  736. height: 60rpx;
  737. display: flex;
  738. align-items: center;
  739. }
  740. .menu {
  741. background-color: #fff;
  742. height: 200rpx;
  743. display: flex;
  744. justify-content: center;
  745. &:not(:nth-last-of-type(1)) {
  746. margin-bottom: 20rpx;
  747. }
  748. .d2 {
  749. width: 180rpx;
  750. height: 180rpx;
  751. }
  752. .menuName {
  753. flex: 1;
  754. margin-left: 20rpx;
  755. }
  756. }
  757. }
  758. }
  759. }
  760. }
  761. .line {
  762. position: absolute;
  763. left: 0;
  764. top: 0;
  765. height: 100rpx;
  766. width: 100%;
  767. background-color: #fff;
  768. z-index: 999;
  769. transition: all 0.4s;
  770. &::before {
  771. content: '';
  772. position: absolute;
  773. left: 0;
  774. top: 0;
  775. height: 100rpx;
  776. width: 4rpx;
  777. background-color: red;
  778. z-index: 999;
  779. transition: all 0.4s
  780. }
  781. }
  782. .pdName{
  783. font-size: 30rpx;
  784. font-weight: bold;
  785. color: black;
  786. }
  787. .pdDetail{
  788. font-size: 26rpx;
  789. color: darkgray;
  790. }
  791. .redktext{
  792. color: brown;
  793. border-radius: 4rpx;
  794. border: 1px solid brown;
  795. font-size: 26rpx;
  796. }
  797. .greedKtext{
  798. color: darkgreen;
  799. border-radius: 4rpx;
  800. border: 1px solid darkgreen;
  801. font-size: 26rpx;
  802. }
  803. .pricetext{
  804. color: firebrick;
  805. font-size: 28rpx;
  806. font-weight: bold;
  807. }
  808. .pricedw{
  809. font-size: 24rpx;
  810. color: darkgray;
  811. }
  812. .yuanjia{
  813. font-size: 24rpx;
  814. color: darkgray;
  815. text-decoration: line-through;
  816. }
  817. </style>