immediatelyList.vue 23 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851
  1. <template>
  2. <view class="container commodity-list-wrapper" :style="{'overflow':(showSkeleton? 'hidden' : 'auto'),'height': (showSkeleton? windowHeight + 'px' : 'auto')}">
  3. <view class="good-search clearfix" v-if="searchStatus">
  4. <view class="nav-tab-bar u-f-ajc">
  5. <block v-for="(tab,index) in tabBars" :key='tab.id' :class="{ current: tabIndex === index }">
  6. <view class="tabstyle u-f-ajc" :class="{'addstyle':tabIndex==index}" @tap="changeTab(index)">{{tab.name}}
  7. <i v-if='(tabIndex==index)' class='nav-tab-line iconfont icon-gou'></i>
  8. </view>
  9. </block>
  10. </view>
  11. <view class="search-from name">
  12. <text class="iconfont icon-iconfonticonfontsousuo1"></text>
  13. <input class="input"
  14. type="text"
  15. focus
  16. confirm-type="search"
  17. v-model="searchInputVal"
  18. placeholder="请输入商品关键词"
  19. @input="onShowClose"
  20. @confirm="searchOpertor(tabIndex)"
  21. maxlength="20"/>
  22. <text class="iconfont icon-shanchu1" v-if="isShowClose" @click="delInputText(tabIndex)"></text>
  23. </view>
  24. <view class="search-btn" :class="tabIndex">
  25. <button class="search-btn" type="default" @click.stop="searchOpertor(tabIndex)" >搜索</button>
  26. </view>
  27. </view>
  28. <list-skeleton v-if="showSkeleton"></list-skeleton>
  29. <view class="empty-container" v-if="isShowEmpty" >
  30. <image class="empty-container-image" src="https://img.caimei365.com/group1/M00/03/71/Cmis2F3wna6AY2ZjAABpmnBICH4247.png"></image>
  31. <text class="error-text">{{isShowEmptyText}}</text>
  32. </view>
  33. <!-- 单一商品 -->
  34. <view class="product-container" v-else :style="{paddingTop:searchStatus?'112rpx':''}" >
  35. <view :class="tabIndex" v-if="tabIndex === 0">
  36. <scroll-view :style="{'height':scrollHeight+'px'}" @scrolltolower="scrolltolower(tabIndex)" scroll-y v-if="productList.length > 0">
  37. <view v-for="(item,index) in productList" :key="index" :id="item.id" class="all-type-list-content commodity-list" @click.stop="navToDetailPage(item.productID)">
  38. <image mode='widthFix' :src="item.mainImage" class="list-img" alt="list-img"></image>
  39. <view class="list-details-info">
  40. <text class="list-details-title">{{item.name}}</text>
  41. <text class="list-details-specs">规格:{{item.unit?item.unit:''}}</text>
  42. <text class="list-details-miniQuantity list-details-specs">起订量:{{item.minBuyNumber}}</text>
  43. <view class="list-details-specs" v-if="item.productCode!=''&&item.productCode!=null">
  44. <view>商品编码:{{item.productCode}}</view>
  45. </view>
  46. <view class="list-details-price">
  47. <view class="list-shop">
  48. <view class="list-price" >
  49. <text class="price-view activity" v-if="item.isShowActFlg">活动价</text>
  50. <text class="price-larger" >¥{{item.retailPrice.toFixed(2)}}</text>
  51. <text class="price-view ladder" v-if="item.ladderPriceFlag == '1'" @click.stop="alertjieti(item)">阶</text>
  52. </view>
  53. <view class="list-price-none" v-if="item.repurchasePriceState">
  54. <text class="price-none">¥{{item.discountPrice}}</text>
  55. <text class="iconfont icon-wenhao" @click.stop="repurchModel"></text>
  56. </view>
  57. </view>
  58. <button class="add-cart-btn" @click.stop="operationHanld(item)">数量</button>
  59. </view>
  60. </view>
  61. </view>
  62. <view v-if="showLoading && productList.length > 4 && !showRegularBtn">
  63. <view class="loading-wrapper loading-wrapper-now" v-if="loadingNow">{{loadingText}}<text v-if="loadingText === '已至底部'">‧ ‧ ‧</text></view>
  64. <view class="loading-wrapper loading-wrapper-btm" v-else>———<text class="btm-text">已至底部</text>———</view>
  65. </view>
  66. </scroll-view>
  67. </view>
  68. <!-- 组合商品 -->
  69. <view :class="tabIndex" v-if="tabIndex === 1">
  70. <scroll-view :style="{'height':scrollHeight+'px'}" @scrolltolower="scrolltolower" scroll-y>
  71. <view class="all-zuhe-list" v-for="(item,index) in combinationProduct" :key="index" :id="item.id">
  72. <view class="zuhe_title" :class="index%2==0 ? 'active' : ''">{{item.name}}</view>
  73. <view v-for="(pros,proIndex) in item.combinationProductList" :class="index%2==0 ? 'stylecontent' : ''" :key="proIndex" :id="pros.productID" class="zuhe-list-content commodity-list" >
  74. <view class="list-details-info" >
  75. <text class="list-details-title zuhe_list_text">商品编码:{{pros.productCode}}</text>
  76. <text class="list-details-specs zuhe_list_text" @click.stop="navToDetailPage(pros.productID)">{{pros.name}}</text>
  77. <view class="list-details-price zuhe_list_price">
  78. <view class="list-shop">
  79. <view class="list-price zuhe_list_price" >
  80. <view class="zuhe_price-larger zuhe_list_text" >价格:¥{{pros.retailPrice.toFixed(2)}}</view>
  81. <view :style="{'overflow':'hidden'}">
  82. <view class="price-two zuhe_list_text" >总价:<text class="zuhe_list_zj">¥ {{pros.totalPrice.toFixed(2)}}</text></view>
  83. <text class="price-view ladder zuhe-price-ladder" v-if="pros.ladderPriceFlag == '1'" @click.stop="alertjieti(pros)">阶</text>
  84. <text class="price-view activity" v-if="pros.actStatus == '1'">活动价</text>
  85. </view>
  86. </view>
  87. <view class="list-price-none" v-if="pros.repurchasePriceState">
  88. <text class="price-none">价格:¥{{pros.discountPrice}}</text>
  89. <text class="iconfont icon-wenhao" @click.stop="repurchModel"></text>
  90. </view>
  91. <view class="count">
  92. <view class="number-box">
  93. <view class="iconfont icon-jianhao" @click.stop="changeCountSub(item,pros)"></view>
  94. <input class="btn-input" type="number" maxlength='6' v-model="pros.initProductNum" @blur="changeNnmber($event,item,pros)">
  95. <view class="iconfont icon-jiahao" @click.stop="changeCountAdd(item,pros)"></view>
  96. </view>
  97. </view>
  98. </view>
  99. </view>
  100. </view>
  101. </view>
  102. <view class="foot_conten" >
  103. <view class="zuhe_foot-box">
  104. <view class="">
  105. <text>种类:{{item.productKind}}</text>
  106. <text >总数:{{item.productTotalNum}}</text>
  107. </view>
  108. <text>总额:<text class="foot_text">{{item.productTotalAmount.toFixed(2)}}</text></text>
  109. </view>
  110. <button type="default" class="buycart" @click.stop="operationHanld(item)">加入购物车</button>
  111. </view>
  112. </view>
  113. </scroll-view>
  114. </view>
  115. </view>
  116. <view class="cart-icon" @click="toCartPage">
  117. <text v-if="cartQuantity > 0" class="uni-badge uni-badge-error uni-small uni-badge--small icon-num">
  118. {{cartQuantity >= 100 ? '99+' : cartQuantity}}
  119. </text>
  120. <image src='../../../static/icon-cart-active@3x.png' mode="widthFix"></image>
  121. </view>
  122. <!-- 透明模态层 -->
  123. <modal-layer v-if='isModallayer'></modal-layer>
  124. </view>
  125. </template>
  126. <script>
  127. import listSkeleton from '@/components/cm-module/listTemplate/listSkeleton'
  128. import modalLayer from "@/components/modal-layer"
  129. import uniStars from '@/components/uni-stars/uni-stars.vue'
  130. import { getSellerProduct,getcombinationProduct } from "@/api/seller.js"
  131. import { mapState,mapMutations } from 'vuex';
  132. export default{
  133. name:'productList',
  134. components:{
  135. listSkeleton,
  136. modalLayer,
  137. uniStars
  138. },
  139. props: {
  140. searchStatus:{
  141. type:Boolean,
  142. default:false
  143. }
  144. },
  145. data(){
  146. return{
  147. isShowClose:false,
  148. searchInputVal:'',
  149. isModallayer:false,
  150. windowHeight: '',
  151. showSkeleton: false,
  152. isShowEmpty: false,
  153. isShowEmptyText: '搜索相关商品',
  154. clubUserId: '',
  155. scrollHeight: '',
  156. productList: [],
  157. combinationProduct:[],
  158. zuheProductList:[],//组合商品列表
  159. showLoading: false,
  160. loadingNow: true,
  161. loadingText: '上拉加载更多',
  162. pageSize: 10,
  163. zuhepageSize:5,
  164. pageNum: 1,
  165. hasNextPage: false,
  166. pullFlag: true,
  167. fromRegularPurchasePage: false,
  168. cartQuantity: 0,
  169. showRegularBtn: false,
  170. isPrecedence:false,
  171. ladderPriceList:[],//是否 阶梯,
  172. tabIndex:0,
  173. goodsList:[],
  174. tabBars:[
  175. {name:'单一',id:'danyi'},
  176. {name:'组合',id:'zuhe'}
  177. ],
  178. isShow: false,
  179. }
  180. },
  181. created() {
  182. this.setScrollHeight();
  183. this.$api.getComStorage('orderUserInfo').then((resolve) =>{
  184. this.clubUserId = resolve.userID
  185. })
  186. },
  187. computed: {
  188. ...mapState(['hasLogin','userInfo'])
  189. },
  190. methods:{
  191. scrolltolower(tabIndex) {
  192. if(this.hasNextPage && this.pullFlag) {
  193. if(tabIndex ==0){
  194. this.getProductAgainInfo(true);
  195. }else if(tabIndex==1){
  196. this.getcombinationProduct(true);
  197. }
  198. }
  199. },
  200. setScrollHeight() {
  201. const {windowHeight, pixelRatio} = wx.getSystemInfoSync();
  202. this.windowHeight = windowHeight - 1;
  203. this.scrollHeight = windowHeight - 1;
  204. },
  205. getProductAgainInfo(loadMore) {
  206. this.showLoading = true;
  207. this.loadingNow = true;
  208. this.loadingText = '加载中';
  209. this.isShowEmpty = false;
  210. if(loadMore) {this.pageNum += 1;}
  211. let params = {clubUserId:this.clubUserId,pageNum:this.pageNum,pageSize:this.pageSize,searchWord:this.searchInputVal}
  212. getSellerProduct(params).then(response =>{
  213. this.isShowWrapper = true
  214. const responseData = response.data;
  215. if(responseData.results && responseData.results.length > 0){
  216. this.hasNextPage = responseData.hasNextPage;
  217. this.isShowEmpty = false;
  218. if(loadMore) {
  219. this.productList = [...this.productList,...responseData.results];
  220. } else {
  221. this.productList = [...responseData.results];
  222. this.showSkeleton = false;
  223. }
  224. //价格显示处理
  225. let isActFlg,newProductList=[];
  226. this.productList.map((item, index)=> {
  227. if(item.actStatus == 1){
  228. isActFlg = true
  229. }else if(item.actStatus == 1 && item.ladderPriceFlag == '1'){
  230. isActFlg = true
  231. }else{
  232. isActFlg = false
  233. }
  234. newProductList.push(Object.assign({},item,{isShowActFlg:isActFlg}))
  235. })
  236. this.productList = newProductList
  237. // 防上拉暴滑
  238. this.pullFlag = false;
  239. setTimeout(()=>{
  240. this.pullFlag = true;
  241. },500)
  242. // 底部提示文案
  243. if(this.hasNextPage) {
  244. this.loadingText = '上拉加载更多';
  245. } else {
  246. this.showLoading = true;
  247. this.loadingNow = false;
  248. }
  249. } else {
  250. this.isShowEmpty = true;
  251. this.isShowEmptyText ='暂无相关商品'
  252. }
  253. }).catch(error =>{
  254. this.$util.msg(error.msg,2000);
  255. })
  256. },
  257. searchOpertor(tabIndex){//搜索商品
  258. if(tabIndex == 0){
  259. if(this.searchInputVal == ''){
  260. this.$util.msg('请输入商品关键词',2000)
  261. }else{
  262. this.pageNum = 1
  263. this.showSkeleton = true;
  264. this.getProductAgainInfo();
  265. }
  266. }else{
  267. this.pageNum = 1
  268. this.showSkeleton = true;
  269. this.getcombinationProduct();
  270. }
  271. },
  272. getcombinationProduct(loadMore){//组合搜索商品
  273. this.showLoading = true;
  274. this.loadingNow = true;
  275. this.loadingText = '加载中';
  276. this.isShowEmpty = false;
  277. if(loadMore) {this.pageNum += 1;}
  278. let params = {clubUserId:this.clubUserId,pageNum:this.pageNum,pageSize:this.zuhepageSize,searchWord:this.searchInputVal}
  279. getcombinationProduct(params).then(response =>{
  280. this.isShowWrapper = true
  281. const responseData = response.data;
  282. if(responseData.results && responseData.results.length > 0){
  283. this.hasNextPage = responseData.hasNextPage;
  284. this.isShowEmpty = false;
  285. if(loadMore) {
  286. this.combinationProduct = [...this.combinationProduct,...responseData.results];
  287. } else {
  288. this.combinationProduct = [...responseData.results];
  289. this.showSkeleton = false;
  290. }
  291. // 防上拉暴滑
  292. this.pullFlag = false;
  293. setTimeout(()=>{
  294. this.pullFlag = true;
  295. },500)
  296. // 底部提示文案
  297. if(this.hasNextPage) {
  298. this.loadingText = '上拉加载更多';
  299. } else {
  300. this.showLoading = true;
  301. this.loadingNow = false;
  302. }
  303. } else {
  304. this.isShowEmpty = true;
  305. this.isShowEmptyText ='暂无相关商品'
  306. }
  307. }).catch(error =>{
  308. this.$util.msg(error.msg,2000);
  309. })
  310. },
  311. changeCountAdd(item,pros){//商品数量加加
  312. if(pros.initProductNum == 0){
  313. pros.initProductNum = pros.minBuyNumber
  314. this.processActivityPrice(pros)
  315. }else if(pros.initProductNum >= pros.minBuyNumber){
  316. pros.initProductNum++
  317. this.processActivityPrice(pros)
  318. }
  319. this.totalPeice(item)
  320. this.totalCount(item)
  321. this.totalKind(item)
  322. },
  323. changeCountSub(item,pros){//商品数量减减
  324. if(pros.initProductNum==0){
  325. this.$util.msg(`采购数量不能小于0`,2000);
  326. return
  327. }else if(pros.initProductNum == pros.minBuyNumber){
  328. pros.initProductNum = 0;
  329. this.processActivityPrice(pros);
  330. }else{
  331. pros.initProductNum--
  332. this.processActivityPrice(pros)
  333. }
  334. this.totalPeice(item)
  335. this.totalCount(item)
  336. this.totalKind(item)
  337. },
  338. changeNnmber(e,item,pros){//输入商品数量更新
  339. let _value = e.detail.value;
  340. if(!this.$api.isNumber(_value)){
  341. pros.initProductNum = pros.minBuyNumber
  342. }else if(_value < pros.minBuyNumber){
  343. this.$util.msg(`该商品最小起订量为${pros.minBuyNumber}`,2000);
  344. pros.initProductNum = pros.minBuyNumber
  345. }else{
  346. pros.initProductNum = e.detail.value
  347. this.processActivityPrice(pros)
  348. }
  349. this.totalPeice(item)
  350. this.totalCount(item)
  351. this.totalKind(item)
  352. },
  353. totalPeice(item){ //计算总价格,每次调用此方法,将初始值为0,遍历价格并累加
  354. let prosPrice=0;
  355. let productsList =[];
  356. productsList=item.combinationProductList;
  357. productsList.forEach(pros=>{
  358. prosPrice+=pros.retailPrice*pros.initProductNum;
  359. item.productTotalAmount = prosPrice;
  360. })
  361. // console.log(prosPrice)
  362. },
  363. totalCount(item){//计算总数量
  364. let prosAllCount=0
  365. let productsList =[];
  366. productsList = item.combinationProductList
  367. productsList.forEach(pros=>{
  368. prosAllCount+=parseInt(pros.initProductNum);
  369. item.productTotalNum = prosAllCount
  370. })
  371. // console.log(prosAllCount)
  372. },
  373. totalKind(item){//计算商品种类
  374. let productsList =[];
  375. let checkList = [];
  376. productsList=item.combinationProductList;
  377. productsList.forEach(pros=>{
  378. if(pros.initProductNum>0){
  379. checkList.push(pros)
  380. item.productKind = checkList.length;
  381. }else{
  382. item.productKind = checkList.length;
  383. }
  384. })
  385. },
  386. processActivityPrice(pros){//单独处理活动价格和阶梯价格
  387. let ladderPriceList = pros.ladderPriceList;
  388. if(pros.ladderPriceFlag == '0' || pros.actStatus == 1){
  389. pros.totalPrice = pros.initProductNum*pros.retailPrice
  390. }else{
  391. ladderPriceList.forEach((item,index)=>{
  392. if(pros.initProductNum>=item.buyNum){
  393. pros.retailPrice = item.buyPrice
  394. pros.totalPrice = pros.initProductNum*item.buyPrice
  395. }
  396. })
  397. }
  398. },
  399. operationHanld(prop){
  400. this.$emit('operationConfim',prop);
  401. },
  402. alertjieti(pros){
  403. this.$emit('alertjietiConfim',pros);
  404. },
  405. changeTab(index){
  406. this.tabIndex = index;
  407. if(index == 0){
  408. this.loadingNow = false;
  409. }
  410. this.$emit('changetab',index);
  411. },
  412. navToDetailPage(id) {
  413. this.isModallayer = true;
  414. this.$api.navigateTo(`/pages/goods/product?id=${id}`);
  415. this.isModallayer = false;
  416. },
  417. toCartPage() {
  418. this.$emit('goCartPage')
  419. },
  420. repurchModel(){
  421. this.$util.modal('','此商品的价格有变化,原来的购买价已不适用','知道了','',false,() =>{})
  422. },
  423. onShowClose () {//输入框失去焦点时触发
  424. if(this.searchInputVal != ''){
  425. this.isShowClose = true
  426. }else{
  427. this.isShowClose = false
  428. }
  429. },
  430. delInputText(tabIndex){//清除输入框内容
  431. this.searchInputVal = '';
  432. this.isShowClose = false;
  433. this.getcombinationProduct();
  434. if(tabIndex==0){
  435. this.isShowClose = false;
  436. this.loadingNow = false;
  437. }
  438. }
  439. }
  440. }
  441. </script>
  442. <style lang="scss">
  443. .all-zuhe-list{
  444. background: #FFFFFF;
  445. }
  446. .foot_conten{
  447. width: 655rpx;
  448. background: #fff;
  449. font-size: 28rpx;
  450. height: 80rpx;
  451. // line-height: 80rpx;
  452. display: inherit;
  453. padding: 10px;
  454. overflow: hidden;
  455. margin: 20rpx auto;
  456. }
  457. .zuhe_foot-box{
  458. float: left;
  459. overflow: hidden;
  460. white-space: nowrap;
  461. // text-overflow: ellipsis;
  462. width: 490rpx;
  463. }
  464. .zuhe_foot-box text{
  465. margin-right: 36rpx;
  466. }
  467. .foot_text{
  468. color: #FF2A2A;
  469. }
  470. .foot_conten .buycart{
  471. width: 162rpx;
  472. height: 64rpx;
  473. background: #EFAF00 !important;
  474. color: #fff;
  475. font-size: 28rpx;
  476. border-radius: 36rpx;
  477. text-align: center;
  478. line-height: 64rpx;
  479. float: right;
  480. }
  481. .price-none{
  482. font-size: 24rpx;
  483. color: #666666;
  484. }
  485. .zuhe_title{
  486. background:#FFFFFF;
  487. height: 76rpx;
  488. font-size: 28rpx;
  489. color: #1675E1;
  490. border-bottom: 4rpx solid #1675E1 ;
  491. line-height: 76rpx;
  492. padding-left: 30rpx;
  493. &.active{
  494. color: #E15616;
  495. border-bottom: 4rpx solid #E15616;
  496. }
  497. }
  498. .icon-gou{
  499. color: #E15616;
  500. position: absolute;
  501. top: 30rpx;
  502. right: 0rpx;
  503. font-weight: bold
  504. }
  505. .addstyle{
  506. background: linear-gradient(-42deg, transparent 28rpx, #E15616 0) top right;
  507. color: #FFFFFF;
  508. }
  509. .tabstyle{
  510. width: 128rpx;
  511. height: 76rpx;
  512. font-size: 26rpx;
  513. display: inline-block;
  514. border-radius: 10rpx;
  515. text-align: center;
  516. line-height: 76rpx;
  517. border: 2rpx solid #EEEEEE;
  518. position: relative;
  519. margin-right: 12rpx;
  520. }
  521. .commodity-list-wrapper {
  522. scroll-view {
  523. height: 100%;
  524. }
  525. .show-more-btn {
  526. width: 276rpx;
  527. height: 52rpx;
  528. line-height: 52rpx;
  529. border: 2rpx solid #D8D8D8;
  530. background: #F7F7F7;
  531. font-size: 26rpx;
  532. margin: 26rpx 0;
  533. position: absolute;
  534. left: 50%;
  535. margin-left: -138rpx;
  536. }
  537. }
  538. .good-search{
  539. height: 80rpx;
  540. width: 702rpx;
  541. padding: 24rpx;
  542. background: #FFFFFF;
  543. display: flex;
  544. align-items: center;
  545. margin-bottom: 20rpx;
  546. position: fixed;
  547. top: 0;
  548. left: 0;
  549. z-index: 999;
  550. .search-from{
  551. width: 326rpx;
  552. height: 80rpx;
  553. background: #F7F7F7;
  554. border-radius: 14rpx;
  555. float: left;
  556. position: relative;
  557. .input{
  558. // width: 500rpx;
  559. height: 80rpx;
  560. float: left;
  561. line-height: 80rpx;
  562. color: $text-color;
  563. font-size: $font-size-24;
  564. }
  565. .icon-iconfonticonfontsousuo1{
  566. width: 64rpx;
  567. height: 80rpx;
  568. line-height: 80rpx;
  569. text-align: center;
  570. display: block;
  571. font-size: $font-size-38;
  572. float: left;
  573. color: #999999;
  574. }
  575. .icon-shanchu1{
  576. font-size: $font-size-32;
  577. color: #999999;
  578. position: absolute;
  579. width: 120rpx;
  580. height: 80rpx;
  581. line-height: 80rpx;
  582. top: 0;
  583. right: 0;
  584. text-align: center;
  585. z-index: 10;
  586. }
  587. }
  588. .search-btn{
  589. // width: 120rpx;
  590. line-height: 64rpx;
  591. text-align: center;
  592. font-size: $font-size-28;
  593. color: $color-system;
  594. float: left;
  595. background: #FFFFFF;
  596. margin-left: 10rpx;
  597. }
  598. }
  599. .all-type-list-content {
  600. // height: 240rpx;
  601. padding: 24rpx;
  602. background: #fff;
  603. margin-bottom: 2rpx;
  604. display: flex;
  605. flex-direction: row;
  606. box-sizing: content-box;
  607. .list-img {
  608. width: 312rpx;
  609. height: 207rpx !important;
  610. margin-right: 26rpx;
  611. border-radius: 10rpx;
  612. border: 2rpx solid #f3f3f3;
  613. }
  614. }
  615. .zuhe-list-content{
  616. width: 655rpx;
  617. // height: 214rpx;
  618. background: #fff;
  619. border: 2rpx solid #DEF4FF;
  620. display: flex;
  621. flex-direction: row;
  622. box-sizing: content-box;
  623. margin-top: 10rpx;
  624. border-radius: 14rpx;
  625. margin: 10rpx auto;
  626. padding: 20rpx;
  627. &.stylecontent{
  628. border: 2rpx solid #FFF0DE;
  629. }
  630. }
  631. .list-details-info {
  632. width: 100%;
  633. flex-direction: column;
  634. font-size: 26rpx;
  635. position: relative;
  636. .list-details-title {
  637. line-height: 38rpx;
  638. text-overflow: ellipsis;
  639. overflow: hidden;
  640. display: -webkit-box;
  641. -webkit-line-clamp: 2;
  642. line-clamp: 2;
  643. -webkit-box-orient: vertical;
  644. }
  645. .list-details-specs {
  646. width: 100%;
  647. display: inline-block;
  648. margin-top: 8rpx;
  649. color: #666666;
  650. }
  651. .list-details-miniQuantity {
  652. width: 100%;
  653. display: inline-block;
  654. margin-top: 7rpx;
  655. }
  656. }
  657. .list-details-price {
  658. width: 100%;
  659. display: flex;
  660. flex-direction: row;
  661. justify-content: space-between;
  662. .price-icon {
  663. width: 22rpx;
  664. height: 28rpx;
  665. vertical-align: middle;
  666. margin-right: 10rpx;
  667. }
  668. .price-icon + text {
  669. font-size: 25rpx;
  670. vertical-align: middle;
  671. }
  672. .list-login-now {
  673. width: 375rpx;
  674. color: #F8C499;
  675. position: absolute;
  676. bottom: 0;
  677. .p-no{
  678. float: left;
  679. font-size: $font-size-24;
  680. color: $color-system;
  681. margin-right: 10rpx;
  682. }
  683. }
  684. .login-now {
  685. padding: 10rpx 10rpx 10rpx 0;
  686. }
  687. .list-none{
  688. margin-top: 15rpx;
  689. .price-small{
  690. font-size:$font-size-24;
  691. line-height: 40rpx;
  692. color: #FF2A2A;
  693. }
  694. }
  695. .list-shop{
  696. width: 100%;
  697. height: auto;
  698. flex: 6;
  699. overflow: hidden;
  700. .list-price {
  701. // width: 100%;
  702. color: #FF2A2A;
  703. float: left;
  704. line-height:36rpx ;
  705. align-items: center;
  706. justify-content: center;
  707. .price-larger {
  708. margin-top: 20rpx;
  709. font-size: $font-size-30;
  710. display: inline-block;
  711. margin-right: 20rpx;
  712. }
  713. .zuhe_price-larger{
  714. color: #666666;
  715. // float: left;
  716. // margin-right: 85rpx;
  717. }
  718. .price-two{
  719. color: #666666;
  720. float: left;
  721. }
  722. .zuhe_list_zj{
  723. color: #FF2A2A;
  724. }
  725. .price-view{
  726. display: inline-block;
  727. width: 40rpx;
  728. border-radius: 10rpx;
  729. font-size: $font-size-24;
  730. text-align: center;
  731. color: #FFFFFF;
  732. height: 36rpx;
  733. line-height: 36rpx;
  734. margin-right: 8rpx;
  735. &.ladder{
  736. background: linear-gradient(135deg,rgba(255,0,0,1) 0%,rgba(242,143,49,1) 100%);
  737. }
  738. &.activity{
  739. background: linear-gradient(135deg,rgba(128,0,255,1) 0%,rgba(242,49,153,1) 100%);
  740. }
  741. }
  742. }
  743. .zuhe_list_price .price-view{
  744. margin-left:20rpx;
  745. float: left;
  746. margin-top: 5rpx;
  747. }
  748. .zuhe_list_price{
  749. width: 400rpx;
  750. overflow: hidden;
  751. margin-top: 10rpx;
  752. }
  753. .count{
  754. margin-top: 50rpx;
  755. float: right;
  756. border: 1px solid #EEEEEE;
  757. border-radius: 10rpx;
  758. .number-box{
  759. display: flex;
  760. justify-content: center;
  761. align-items: center;
  762. .iconfont{
  763. font-size: $font-size-24;
  764. padding:0 16rpx;
  765. color: $text-color;
  766. text-align: center;
  767. line-height: 48rpx;
  768. font-weight: bold;
  769. }
  770. .btn-input{
  771. width: 100rpx;
  772. height: 48rpx;
  773. line-height: 48rpx;
  774. background: #F8F8F8;
  775. border-radius: 4rpx;
  776. text-align: center;
  777. font-size: $font-size-24;
  778. border-right: 1px solid #EEEEEE;
  779. border-left: 1px solid #EEEEEE;
  780. }
  781. }
  782. }
  783. .list-price-none{
  784. width: 100%;
  785. .price-none{
  786. text-decoration: line-through;
  787. color: #999999;
  788. display: inline-block;
  789. }
  790. .icon-wenhao{
  791. font-size: $font-size-32;
  792. color: #0091FF;
  793. margin-left: 6rpx;
  794. }
  795. }
  796. }
  797. .add-cart-btn {
  798. flex: 4;
  799. width: 156rpx;
  800. height: 64rpx;
  801. line-height: 64rpx;
  802. border-radius: 32rpx;
  803. color: #333333;
  804. font-size: 26rpx;
  805. margin-right: 0;
  806. // background:linear-gradient(135deg,rgba(242,143,49,1) 0%,rgba(225,86,22,1) 100%);
  807. background: #FFFFFF;
  808. border: 2rpx solid #C9C9C9;
  809. }
  810. .zuhe_btn{
  811. float: right;
  812. }
  813. }
  814. .zuhe_list_price{
  815. display: block !important;
  816. }
  817. .cart-icon {
  818. width: 92rpx;
  819. height: 92rpx;
  820. border-radius: 50%;
  821. background: rgba(255, 147, 0, 0.5);
  822. position: fixed;
  823. right: 24rpx;
  824. bottom: 37%;
  825. display: flex;
  826. align-items: center;
  827. justify-content: center;
  828. cursor: pointer;
  829. image {
  830. width: 58rpx;
  831. height: 58rpx;
  832. }
  833. text {
  834. font-size: 28rpx;
  835. position: absolute;
  836. top: -10rpx;
  837. right: 0;
  838. }
  839. }
  840. .zuhe_list_text{
  841. margin-top: 10rpx;
  842. }
  843. </style>