immediatelyList.vue 25 KB

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