list.vue 22 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919
  1. <template>
  2. <view class="content">
  3. <scroll-view scroll-x class="bg-white nav">
  4. <view class="flex text-center">
  5. <view class="cu-item flex-sub" :class="0==TabCur?'text-orange cur':''" @tap="tabSelect" data-id="0">
  6. <text class="cuIcon-text"></text> 销售信息
  7. </view>
  8. <view class="cu-item flex-sub" :class="1==TabCur?'text-orange cur':''" @tap="tabSelect" data-id="1">
  9. <text class="cuIcon-cartfill"></text> 采购信息
  10. </view>
  11. <view v-if="showTran" class="cu-item flex-sub" :class="2==TabCur?'text-orange cur':''" @tap="tabSelect" data-id="2">
  12. <text class="cuIcon-deliver"></text> 货源信息
  13. </view>
  14. <view v-if="showTran" class="cu-item flex-sub" :class="3==TabCur?'text-orange cur':''" @tap="tabSelect" data-id="3">
  15. <text class="cuIcon-group"></text> 车辆信息
  16. </view>
  17. </view>
  18. </scroll-view>
  19. <swiper :current="TabCur" class="swiper-box" duration="300" @change="tabSelect">
  20. <swiper-item class="tab-content" data-id="1">
  21. <scroll-view class="list-scroll-content" scroll-y @scrolltolower="onReachBottomTmp">
  22. <block v-if="TabCur==0">
  23. <view class="introduce-section">
  24. <view v-for="(item, index) in saleInfo" :key="index" class="guess-item" @click="navToDetailPage(item)">
  25. <view class="price-box">
  26. <view class="title">{{item.title}}</view>
  27. <view class="title-tip" v-if='item.isFutures==0'>
  28. <text class="price-tip">¥</text>
  29. <text class="price">{{item.price}}</text>
  30. <text class="price-tip">元/吨</text>
  31. </view>
  32. <view class="title-tip" v-if='item.isFutures==1'>
  33. <text class="price-tip">今日基差</text>&nbsp;
  34. <text class="price-tip">¥</text>
  35. <text class="price">{{item.basis}}</text>
  36. </view>
  37. </view>
  38. <view class='cu-tag radius line-pink' v-if='item.isFutures==0'>现货</view>
  39. <view class='cu-tag radius line-pink' v-if='item.isFutures==1'>期货</view>
  40. <view class='cu-tag radius line-green'>{{item.goodsName}}</view>
  41. <view class='cu-tag radius line-yellow'>易粮易运</view>
  42. </view>
  43. <view v-show="isLoadMore">
  44. <uni-load-more :status="loadStatus"></uni-load-more>
  45. </view>
  46. </view>
  47. </block>
  48. </scroll-view>
  49. </swiper-item>
  50. <swiper-item class="tab-content" data-id="2">
  51. <scroll-view class="list-scroll-content" scroll-y @scrolltolower="onReachBottomTmp">
  52. <block v-if="TabCur==1">
  53. <view class="introduce-section">
  54. <view v-for="(item, index) in buyInfo" :key="index" class="guess-item" @click="navToDetailPage(item)">
  55. <view class="price-box">
  56. <view class="title">{{item.title}}</view>
  57. <template v-if='item.isFutures==0'>
  58. <view v-if="item.price !== 0" class="title-tip">
  59. <text class="price-tip">¥</text>
  60. <text class="price">{{item.price}}</text>
  61. <text class="price-tip">元/吨</text>
  62. </view>
  63. <view v-else class="title-tip">
  64. <text>市场价</text>
  65. </view>
  66. </template>
  67. <view class="title-tip" v-if='item.isFutures==1'>
  68. <text class="price-tip">今日基差</text>&nbsp;
  69. <text class="price-tip">¥</text>
  70. <text class="price">{{item.basis}}</text>
  71. </view>
  72. </view>
  73. <view class='cu-tag radius line-pink' v-if='item.isFutures==0'>现货</view>
  74. <view class='cu-tag radius line-pink' v-if='item.isFutures==1'>期货</view>
  75. <view class='cu-tag radius line-green'>{{item.goodsName}}</view>
  76. <view class='cu-tag radius line-yellow'>易粮易运</view>
  77. </view>
  78. <view v-show="isLoadMore">
  79. <uni-load-more :status="loadStatus"></uni-load-more>
  80. </view>
  81. </view>
  82. </block>
  83. </scroll-view>
  84. </swiper-item>
  85. <swiper-item class="tab-content" data-id="3">
  86. <scroll-view class="list-scroll-content" scroll-y @scrolltolower="onReachBottomTmp">
  87. <block v-if="TabCur==2">
  88. <view class="guess-section">
  89. <view
  90. v-for="(item, index) in tranInfo" :key="index"
  91. class="guess-item"
  92. @click="navToDetailPage(item)"
  93. >
  94. <view class="flex justify-between padding-xs ">
  95. <view class="flex-sub padding-xs">
  96. <view class="cu-capsule radius">
  97. <view class="cu-tag bg-blue">
  98. {{item.startPlace }}
  99. </view>
  100. <view class="cu-tag line-blue">
  101. {{item.endPlace }}
  102. </view>
  103. </view>
  104. </view>
  105. <view class=" padding-xs">
  106. <view v-if="item.status == 0" class="cu-capsule radius">
  107. <view class="cu-tag bg-green">
  108. 可承运
  109. </view>
  110. <view class="cu-tag line-green">
  111. <text class="text-price">{{item.price }}</text>
  112. </view>
  113. </view>
  114. <view v-else class="cu-capsule radius">
  115. <view class="cu-tag bg-red">
  116. 已结束
  117. </view>
  118. <view class="cu-tag line-red">
  119. <text class="text-price">{{item.price }}</text>
  120. </view>
  121. </view>
  122. </view>
  123. </view>
  124. <view class="flex justify-between padding-xs">
  125. <view class="flex-sub padding-xs">
  126. <view class="cu-capsule radius">
  127. <view class="cu-tag bg-orange">
  128. {{item.goodsName}}
  129. </view>
  130. <view class="cu-tag line-orange">
  131. {{numFilter(item.total - item.tranCount) }}吨
  132. </view>
  133. </view>
  134. </view>
  135. <view class=" text-sm padding-xs">
  136. <view class=" text-sm padding-xs">
  137. <text class="text-gray text-sm text-right padding-xs-tmp ">{{item.gmtUpdate}}</text>
  138. </view>
  139. </view>
  140. </view>
  141. </view>
  142. <view v-show="isLoadMore">
  143. <uni-load-more :status="loadStatus" ></uni-load-more>
  144. </view>
  145. </view>
  146. </block>
  147. </scroll-view>
  148. </swiper-item>
  149. <swiper-item class="tab-content" data-id="0">
  150. <scroll-view class="list-scroll-content" scroll-y @scrolltolower="onReachBottomTmp">
  151. <block v-if="TabCur==3">
  152. <view class="guess-section">
  153. <view
  154. v-for="(item, index) in carInfo" :key="index"
  155. class="guess-item"
  156. @click="navToDetailPage(item)"
  157. >
  158. <view class="flex justify-between padding-xs ">
  159. <view class="flex-sub padding-xs">
  160. <view class="cu-capsule radius">
  161. <view class="cu-tag bg-blue">
  162. {{item.startPlace }}
  163. </view>
  164. <view class="cu-tag line-blue">
  165. {{item.endPlace }}
  166. </view>
  167. </view>
  168. </view>
  169. <view class=" padding-xs">
  170. <view v-if="item.status == 2" class="cu-capsule radius">
  171. <view class="cu-tag bg-green">
  172. 可委托
  173. </view>
  174. <view class="cu-tag line-green">
  175. <text class="text-price">{{item.price }}</text>
  176. </view>
  177. </view>
  178. <view v-else class="cu-capsule radius">
  179. <view class="cu-tag bg-red">
  180. 已承运
  181. </view>
  182. <view class="cu-tag line-red">
  183. <text class="text-price">{{item.price }}</text>
  184. </view>
  185. </view>
  186. </view>
  187. </view>
  188. <view class="flex justify-between padding-xs">
  189. <view class="flex-sub padding-xs">
  190. <view class="cu-capsule radius">
  191. <view class="cu-tag bg-orange">
  192. {{item.driver}}
  193. </view>
  194. <view class="cu-tag line-orange">
  195. {{item.carNo}}
  196. </view>
  197. </view>
  198. </view>
  199. <view class=" text-sm padding-xs">
  200. <view class=" text-sm padding-xs">
  201. <text class="text-gray text-sm text-right padding-xs-tmp ">{{item.gmtUpdate}}</text>
  202. </view>
  203. </view>
  204. </view>
  205. </view>
  206. <view v-show="isLoadMore">
  207. <uni-load-more :status="loadStatus" ></uni-load-more>
  208. </view>
  209. </view>
  210. </block>
  211. </scroll-view>
  212. </swiper-item>
  213. </swiper>
  214. </view>
  215. </template>
  216. <script>
  217. export default {
  218. data() {
  219. return {
  220. titleNViewBackground: '',
  221. swiperCurrent: 0,
  222. swiperLength: 0,
  223. carouselList: [],
  224. windowSpuList: [],
  225. categoryPickList: [],
  226. categoryButtomList: [],
  227. salesTop: [],
  228. saleInfo: [],
  229. buyInfo: [],
  230. tranInfo:[],
  231. carInfo:[],
  232. banner: undefined,
  233. isVip: false,
  234. pages:1,//页数
  235. limit:10 ,//每次取条目数
  236. loadStatus:'loading', //加载样式:more-加载前样式,loading-加载中样式,nomore-没有数据样式
  237. isLoadMore:false ,//是否加载中
  238. TabCur: 0,
  239. swiperHeight:'',
  240. showTran:true
  241. };
  242. },
  243. onShow() {
  244. this.showTran = uni.getStorageSync("showTran")
  245. },
  246. //下拉刷新
  247. onPullDownRefresh() {
  248. this.pages = 1
  249. this.isLoadMore = false
  250. this.loadStatus = 'loading'
  251. this.loadData()
  252. },
  253. onLoad(options) {
  254. // #ifdef H5
  255. this.headerTop = document.getElementsByTagName('uni-page-head')[0].offsetHeight + 'px';
  256. // #endif
  257. this.cateId = options.tid ? options.tid : 0;
  258. this.keywords = options.keywords ? options.keywords : ''
  259. this.TabCur = options.TabCur
  260. this.loadData();
  261. },
  262. onPageScroll(e) {
  263. //兼容iOS端下拉时顶部漂移
  264. if (e.scrollTop >= 0) {
  265. this.headerPosition = "fixed";
  266. } else {
  267. this.headerPosition = "absolute";
  268. }
  269. },
  270. //下拉刷新
  271. onPullDownRefresh() {
  272. this.pages = 1
  273. this.isLoadMore = false
  274. this.loadStatus = 'loading'
  275. this.loadData()
  276. },
  277. onReachBottom(){ //上拉触底函数
  278. if(!this.isLoadMore){ //此处判断,上锁,防止重复请求
  279. this.isLoadMore=true
  280. this.pages += 1
  281. this.getIndexSaleData()
  282. }
  283. },
  284. methods: {
  285. numFilter (value) {
  286. if(!value){
  287. return 0
  288. }
  289. // 截取当前数据到小数点后两位
  290. let realVal = parseFloat(value).toFixed(2)
  291. return realVal
  292. },
  293. tabSelect(e) {
  294. if(e.currentTarget.dataset.id){
  295. this.TabCur = e.currentTarget.dataset.id;
  296. }
  297. else{
  298. this.TabCur = e.target.current;
  299. }
  300. this.pages = 1
  301. this.isLoadMore = false
  302. this.loadData()
  303. },
  304. //加载商品 ,带下拉刷新和上滑加载
  305. async loadData() {
  306. uni.setNavigationBarTitle({
  307. title:"搜索关键字:"+this.keywords
  308. });
  309. const that = this
  310. uni.showLoading({
  311. title: '正在加载',
  312. mask:true
  313. })
  314. if(this.TabCur == 0){
  315. that.$api.request('goods', 'getSaleInfo',{
  316. keywords: this.keywords,
  317. page: this.pages,
  318. limit:this.limit
  319. }, failres => {
  320. that.$api.msg(failres.errmsg)
  321. this.isLoadMore = false
  322. this.loadStatus = 'nomore'
  323. if(this.pages>1){this.pages=1}
  324. uni.hideLoading()
  325. uni.stopPullDownRefresh()
  326. }).then(res => {
  327. let data = res.data
  328. //销售信息
  329. if(data.saleInfo){
  330. that.saleInfo = data.saleInfo
  331. }
  332. uni.hideLoading()
  333. uni.stopPullDownRefresh()
  334. })
  335. }
  336. else if(this.TabCur == 1){
  337. that.$api.request('buy', 'getBuyListInfo',{
  338. keywords: this.keywords,
  339. page: this.pages,
  340. limit:this.limit
  341. }, failres => {
  342. that.$api.msg(failres.errmsg)
  343. this.isLoadMore = false
  344. this.loadStatus = 'nomore'
  345. if(this.pages>1){this.pages=1}
  346. uni.hideLoading()
  347. uni.stopPullDownRefresh()
  348. }).then(res => {
  349. let data = res.data
  350. //销售信息
  351. if(data){
  352. that.buyInfo = data
  353. }
  354. uni.hideLoading()
  355. uni.stopPullDownRefresh()
  356. })
  357. }
  358. else if(this.TabCur == 2){
  359. that.$api.request('tran', 'getTranListInfo',{
  360. keywords: this.keywords,
  361. page: this.pages,
  362. limit:this.limit
  363. }, failres => {
  364. that.$api.msg(failres.errmsg)
  365. this.isLoadMore = false
  366. this.loadStatus = 'nomore'
  367. if(this.pages>1){this.pages=1}
  368. uni.hideLoading()
  369. uni.stopPullDownRefresh()
  370. }).then(res => {
  371. let data = res.data
  372. console.log(data.tranInfo)
  373. //销售信息
  374. if(data.tranInfo){
  375. that.tranInfo = data.tranInfo
  376. }
  377. uni.hideLoading()
  378. uni.stopPullDownRefresh()
  379. })
  380. }
  381. else if(this.TabCur == 3){
  382. that.$api.request('tran', 'getCarListInfo',{
  383. keywords: this.keywords,
  384. page: this.pages,
  385. limit:this.limit
  386. }, failres => {
  387. that.$api.msg(failres.errmsg)
  388. this.isLoadMore = false
  389. this.loadStatus = 'nomore'
  390. if(this.pages>1){this.pages=1}
  391. uni.hideLoading()
  392. uni.stopPullDownRefresh()
  393. }).then(res => {
  394. let data = res.data
  395. console.log(data.carInfo)
  396. //销售信息
  397. if(data.carInfo){
  398. that.carInfo = data.carInfo
  399. }
  400. uni.hideLoading()
  401. uni.stopPullDownRefresh()
  402. })
  403. }
  404. },
  405. //详情
  406. navToDetailPage(item) {
  407. //测试数据没有写id,用title代替
  408. let id = item.id;
  409. if(this.TabCur == 0){
  410. uni.navigateTo({
  411. url: `/pageA/product/detail?id=${id}`
  412. })
  413. }
  414. else if(this.TabCur == 1){
  415. uni.navigateTo({
  416. url: `/pageA/product/detail_buy?id=${id}`
  417. })
  418. }
  419. else if(this.TabCur == 2){
  420. uni.navigateTo({
  421. url: `/pages/tran/tran_detail?id=${id}`
  422. })
  423. }
  424. else if(this.TabCur == 3){
  425. uni.navigateTo({
  426. url: `/pages/tran/car_detail?id=${id}`
  427. })
  428. }
  429. },
  430. onReachBottomTmp(){ //上拉触底函数
  431. if(!this.isLoadMore){ //此处判断,上锁,防止重复请求
  432. this.isLoadMore=true
  433. this.pages += 1
  434. this.getIndexSaleData()
  435. }
  436. },
  437. getIndexSaleData(){
  438. const that = this
  439. var pages=that.pages
  440. var limit=that.limit
  441. uni.showLoading({
  442. title: '正在加载',
  443. mask:true
  444. })
  445. if(this.TabCur == 0){
  446. that.$api.request('goods', 'getSaleListInfo', {
  447. keywords: this.keywords,
  448. page: pages,
  449. limit:limit
  450. },failres => {
  451. that.$api.msg(failres.errmsg)
  452. that.isLoadMore=false
  453. that.loadStatus = 'nomore'
  454. if(that.pages>1){that.pages-=1}
  455. uni.hideLoading()
  456. }).then(res => {
  457. let data = res.data
  458. //销售信息
  459. if(data.saleInfo.length > 0){
  460. that.saleInfo = that.saleInfo.concat(data.saleInfo)
  461. that.isLoadMore=false
  462. }
  463. else{
  464. if(that.pages>1){that.pages-=1}
  465. that.isLoadMore=true
  466. that.loadStatus = 'nomore'
  467. }
  468. uni.hideLoading()
  469. })
  470. }
  471. else if(this.TabCur == 1){
  472. that.$api.request('buy', 'getBuyListInfo', {
  473. keywords: this.keywords,
  474. page: pages,
  475. limit:limit
  476. },failres => {
  477. that.$api.msg(failres.errmsg)
  478. that.isLoadMore=false
  479. that.loadStatus = 'nomore'
  480. if(that.pages>1){that.pages-=1}
  481. uni.hideLoading()
  482. }).then(res => {
  483. let data = res.data
  484. //销售信息
  485. if(data.length > 0){
  486. that.buyInfo = that.buyInfo.concat(data)
  487. that.isLoadMore=false
  488. }
  489. else{
  490. if(that.pages>1){that.pages-=1}
  491. that.isLoadMore=true
  492. that.loadStatus = 'nomore'
  493. }
  494. uni.hideLoading()
  495. })
  496. }
  497. else if(this.TabCur == 2){
  498. that.$api.request('tran', 'getTranListInfo', {
  499. keywords: this.keywords,
  500. page: pages,
  501. limit:limit
  502. },failres => {
  503. that.$api.msg(failres.errmsg)
  504. that.isLoadMore=false
  505. that.loadStatus = 'nomore'
  506. if(that.pages>1){that.pages-=1}
  507. uni.hideLoading()
  508. }).then(res => {
  509. let data = res.data
  510. //销售信息
  511. if(data.tranInfo.length > 0){
  512. that.tranInfo = that.tranInfo.concat(data.tranInfo)
  513. that.isLoadMore=false
  514. }
  515. else{
  516. if(that.pages>1){that.pages-=1}
  517. that.isLoadMore=true
  518. that.loadStatus = 'nomore'
  519. }
  520. uni.hideLoading()
  521. })
  522. }
  523. else if(this.TabCur == 3){
  524. that.$api.request('tran', 'getCarListInfo', {
  525. keywords: this.keywords,
  526. page: pages,
  527. limit:limit
  528. },failres => {
  529. that.$api.msg(failres.errmsg)
  530. that.isLoadMore=false
  531. that.loadStatus = 'nomore'
  532. if(that.pages>1){that.pages-=1}
  533. uni.hideLoading()
  534. }).then(res => {
  535. let data = res.data
  536. //销售信息
  537. if(data.carInfo.length > 0){
  538. that.carInfo = that.carInfo.concat(data.carInfo)
  539. that.isLoadMore=false
  540. }
  541. else{
  542. if(that.pages>1){that.pages-=1}
  543. that.isLoadMore=true
  544. that.loadStatus = 'nomore'
  545. }
  546. uni.hideLoading()
  547. })
  548. }
  549. }
  550. },
  551. }
  552. </script>
  553. <style lang="scss" scoped>
  554. page,
  555. .content {
  556. background: $page-color-base;
  557. height: 100%;
  558. }
  559. .navbar {
  560. position: fixed;
  561. left: 0;
  562. top: var(--window-top);
  563. display: flex;
  564. width: 100%;
  565. height: 80upx;
  566. background: #fff;
  567. box-shadow: 0 2upx 10upx rgba(0, 0, 0, .06);
  568. z-index: 10;
  569. .nav-item {
  570. flex: 1;
  571. display: flex;
  572. justify-content: center;
  573. align-items: center;
  574. height: 100%;
  575. font-size: 30upx;
  576. color: $font-color-dark;
  577. position: relative;
  578. &.current {
  579. color: $base-color;
  580. &:after {
  581. content: '';
  582. position: absolute;
  583. left: 50%;
  584. bottom: 0;
  585. transform: translateX(-50%);
  586. width: 120upx;
  587. height: 0;
  588. border-bottom: 4upx solid $base-color;
  589. }
  590. }
  591. }
  592. .p-box {
  593. display: flex;
  594. flex-direction: column;
  595. .yticon {
  596. display: flex;
  597. align-items: center;
  598. justify-content: center;
  599. width: 30upx;
  600. height: 14upx;
  601. line-height: 1;
  602. margin-left: 4upx;
  603. font-size: 26upx;
  604. color: #888;
  605. &.active {
  606. color: $base-color;
  607. }
  608. }
  609. .xia {
  610. transform: scaleY(-1);
  611. }
  612. }
  613. .cate-item {
  614. display: flex;
  615. justify-content: center;
  616. align-items: center;
  617. height: 100%;
  618. width: 80upx;
  619. position: relative;
  620. font-size: 44upx;
  621. &:after {
  622. content: '';
  623. position: absolute;
  624. left: 0;
  625. top: 50%;
  626. transform: translateY(-50%);
  627. border-left: 1px solid #ddd;
  628. width: 0;
  629. height: 36upx;
  630. }
  631. }
  632. }
  633. /* 分类 */
  634. .cate-mask {
  635. position: fixed;
  636. left: 0;
  637. top: var(--window-top);
  638. bottom: 0;
  639. width: 100%;
  640. background: rgba(0, 0, 0, 0);
  641. z-index: 95;
  642. transition: .3s;
  643. .cate-content {
  644. width: 630upx;
  645. height: 100%;
  646. background: #fff;
  647. float: right;
  648. transform: translateX(100%);
  649. transition: .3s;
  650. }
  651. &.none {
  652. display: none;
  653. }
  654. &.show {
  655. background: rgba(0, 0, 0, .4);
  656. .cate-content {
  657. transform: translateX(0);
  658. }
  659. }
  660. }
  661. .cate-list {
  662. display: flex;
  663. flex-direction: column;
  664. height: 100%;
  665. .cate-item {
  666. display: flex;
  667. align-items: center;
  668. height: 90upx;
  669. padding-left: 30upx;
  670. font-size: 28upx;
  671. color: #555;
  672. position: relative;
  673. }
  674. .two {
  675. height: 64upx;
  676. color: #303133;
  677. font-size: 30upx;
  678. background: #f8f8f8;
  679. }
  680. .active {
  681. color: $base-color;
  682. }
  683. }
  684. /* 商品列表 */
  685. .goods-list {
  686. display: flex;
  687. flex-wrap: wrap;
  688. padding: 0 30upx;
  689. background: #fff;
  690. .goods-item {
  691. display: flex;
  692. flex-direction: column;
  693. width: 48%;
  694. padding-bottom: 40upx;
  695. &:nth-child(2n+1) {
  696. margin-right: 4%;
  697. }
  698. }
  699. .image-wrapper {
  700. width: 100%;
  701. height: 330upx;
  702. border-radius: 3px;
  703. overflow: hidden;
  704. image {
  705. width: 100%;
  706. height: 100%;
  707. opacity: 1;
  708. }
  709. }
  710. .title {
  711. font-size: $font-lg;
  712. color: $font-color-dark;
  713. line-height: 80upx;
  714. }
  715. .price-box {
  716. display: flex;
  717. align-items: center;
  718. justify-content: space-between;
  719. padding-right: 10upx;
  720. font-size: 24upx;
  721. color: $font-color-light;
  722. }
  723. .price {
  724. font-size: $font-lg;
  725. color: $uni-color-primary;
  726. line-height: 1;
  727. &:before {
  728. content: '¥';
  729. font-size: 26upx;
  730. }
  731. }
  732. }
  733. .guess-section{
  734. display:flex;
  735. flex-wrap:wrap;
  736. padding: 0 30upx;
  737. background: #fff;
  738. .guess-item{
  739. display:flex;
  740. flex-direction: column;
  741. width: 98%;
  742. border-bottom:1px solid #ccc;
  743. }
  744. .image-wrapper{
  745. width: 100%;
  746. height: 330upx;
  747. border-radius: 3px;
  748. overflow: hidden;
  749. image{
  750. width: 100%;
  751. height: 100%;
  752. opacity: 1;
  753. }
  754. }
  755. .title{
  756. font-size: $font-lg;
  757. color: #121212;
  758. }
  759. .price-orther{
  760. font-size: $font-sm;
  761. color:$font-color-base;
  762. }
  763. .price{
  764. font-size: 64rpx;
  765. color: #39b54a;
  766. line-height: 1;
  767. padding-right: 10upx;
  768. }
  769. .goods1{
  770. font-size: $font-sm;
  771. color: $font-color-base;
  772. }
  773. .goods2{
  774. font-size: $font-sm;
  775. color: $font-color-base;
  776. padding-left: 10%;
  777. }
  778. .goods3{
  779. font-size: $font-sm;
  780. color: $font-color-base;
  781. padding-left: 10%;
  782. }
  783. .goods4{
  784. font-size: $font-sm;
  785. color: #ff5500;
  786. }
  787. .goods5{
  788. font-size: $font-sm;
  789. color: $font-color-base;
  790. }
  791. .view-item{
  792. width: 100%;
  793. // line-height: 40upx;
  794. padding-top: 10upx;
  795. }
  796. .confirm-btn {
  797. margin-left: 20%;
  798. }
  799. .date-time {
  800. margin-left: 30%;
  801. }
  802. .padding-xs-tmp {
  803. padding: 15upx 10upx 10upx 10upx;
  804. }
  805. }
  806. .swiper-box {
  807. height: calc(100% - 40px);
  808. }
  809. .list-scroll-content {
  810. height: 100%;
  811. }
  812. .uni-swiper-item {
  813. height: auto;
  814. }
  815. /* 销售信息 */
  816. .introduce-section {
  817. background: #fff;
  818. padding: 20upx 30upx;
  819. padding-bottom: 100upx;
  820. .guess-item {
  821. padding-bottom: 20upx;
  822. border-bottom: 1px solid #ccc;
  823. }
  824. .title {
  825. font-size: 28upx;
  826. color: $font-color-dark;
  827. font-weight:bold;
  828. height: 50upx;
  829. line-height: 50upx;
  830. flex:2.5;
  831. }
  832. .title-tip {
  833. flex:1;
  834. }
  835. .price-box {
  836. display: flex;
  837. align-items: baseline;
  838. height: 70upx;
  839. padding: 10upx 0;
  840. font-size: 26upx;
  841. color: $uni-color-primary;
  842. }
  843. .price {
  844. font-size: $font-lg + 2upx;
  845. }
  846. .m-price {
  847. margin: 0 12upx;
  848. color: $font-color-light;
  849. text-decoration: line-through;
  850. }
  851. .coupon-tip {
  852. align-items: center;
  853. padding: 4upx 10upx;
  854. background: $uni-color-primary;
  855. font-size: $font-sm;
  856. color: #fff;
  857. border-radius: 6upx;
  858. line-height: 1;
  859. transform: translateY(-4upx);
  860. }
  861. .bot-row {
  862. display: flex;
  863. align-items: center;
  864. height: 50upx;
  865. font-size: $font-sm;
  866. color: $font-color-light;
  867. view {
  868. flex: 1;
  869. }
  870. }
  871. }
  872. </style>