information.vue 25 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994
  1. <template name="sale">
  2. <view class="container">
  3. <view :style="statusBarHeight" class="status_bar">
  4. </view>
  5. <!-- 小程序头部兼容 -->
  6. <!-- #ifdef MP -->
  7. <!-- <view class="mp-search-box">
  8. <input @click="naviageToPage('/pages/product/search')" class="ser-input" type="text" value="输入关键字搜索" disabled />
  9. </view> -->
  10. <!-- #endif -->
  11. <!-- 头部轮播 -->
  12. <view class="carousel-section">
  13. <swiper class="screen-swiper header-swiper" ::class="dotStyle?'square-dot':'round-dot'" :indicator-dots="true" :circular="true"
  14. :autoplay="true" interval="3000" duration="500" @change="swiperChange" indicator-color="#8799a3"
  15. indicator-active-color="#0081ff">
  16. <swiper-item class="swiper-item" v-for="(item,index) in carouselList" :key="index" :class="cardCur==index?'text-white':''" @click="naviageToPage(item.url)">
  17. <image :src="item.imgUrl"></image>
  18. <!-- <view style='position:absolute;top:50%;left:50%;transform: translate(-50%,-50%);'>11111</view> -->
  19. </swiper-item>
  20. </swiper>
  21. <!-- <view class="swiper-dots">
  22. <text class="num">{{swiperCurrent+1}}</text>
  23. <text class="sign">/</text>
  24. <text class="num">{{swiperLength}}</text>
  25. </view> -->
  26. </view>
  27. <swiper-up :list="infoList" ></swiper-up>
  28. <!-- <scroll-view style='margin-top:12px;padding:0 20px;' scroll-x class="nav">
  29. <view class="flex text-center">
  30. <view style='position:relative;' class="cu-item flex-sub" :class="item.value==TabCur?'text-white':''" v-for="item in categoryList"@tap="tabSelect" :data-id="item.value">
  31. <image v-if='item.value==TabCur' style='width:100%;height:100%;position: absolute;z-index:1;left:0;' src='https://taohaoliang.oss-cn-beijing.aliyuncs.com/tmp/bg.png'></image>
  32. <text style='position:relative;z-index:2;'>{{item.label}}</text>
  33. </view>
  34. </view>
  35. </scroll-view> -->
  36. <view class="guess-section-wrap">
  37. <view class='flex justify-between'>
  38. <view class='title'>工厂价格</view>
  39. <view style='color:#B2B3BB;' @click='more("/pages/sale/plant")'>更多</view>
  40. </view>
  41. <scroll-view :scroll-x="true">
  42. <view class='guess-section-wrap-content'>
  43. <view class='guess-section-wrap-item clearfix' v-for='item in plantList'>
  44. <view class='factory'>{{item.factory}}</view>
  45. <view class='wrap'>{{item.city}} {{item.factoryType}}</view>
  46. <view class='price'>
  47. <text class='currectprice'>{{item.price}}</text>
  48. 较昨日
  49. <image v-if='item.comparePrice>0' style="width:7.5px;height:9px;" src='../../static/img/homepage/shangsheng.png'></image>
  50. <image v-if='item.comparePrice<0' style="width:7.5px;height:9px;" src='../../static/img/homepage/xiajiang.png'></image>
  51. <text v-if='item.comparePrice>0' class='yesterday up'>{{item.comparePrice}}</text>
  52. <text v-if='item.comparePrice<0' class='yesterday down'>{{-item.comparePrice}}</text>
  53. <text v-if='item.comparePrice==0' class='yesterday'>-</text>
  54. </view>
  55. </view>
  56. </view>
  57. </scroll-view>
  58. </view>
  59. <view class="guess-section-wrap">
  60. <view class='flex justify-between'>
  61. <view class='title'>港口价格</view>
  62. <view style='color:#B2B3BB;' @click='more("/pages/sale/portprice")'>更多</view>
  63. </view>
  64. <scroll-view :scroll-x="true">
  65. <view class='guess-section-wrap-content port'>
  66. <view class='guess-section-wrap-item clearfix' v-for='item in portList'>
  67. <view class='factory'>{{item.port}}</view>
  68. <view class='wrap'>{{item.goodsName}}</view>
  69. <view class='price'>
  70. <text class='currectprice'>{{item.price}}</text>
  71. 较昨日
  72. <image v-if='item.comparePrice>0' style="width:7.5px;height:9px;" src='../../static/img/homepage/shangsheng.png'></image>
  73. <image v-if='item.comparePrice<0' style="width:7.5px;height:9px;" src='../../static/img/homepage/xiajiang.png'></image>
  74. <text v-if='item.comparePrice>0' class='yesterday up'>{{item.comparePrice}}</text>
  75. <text v-if='item.comparePrice<0' class='yesterday down'>{{-item.comparePrice}}</text>
  76. <text v-if='item.comparePrice==0' class='yesterday'>-</text>
  77. </view>
  78. <view style='color:#B2B3BB;' class='flex'>
  79. <view style='margin-right:10px;'>
  80. <image style='width:11px;height:11px;' src='../../static/img/homepage/water@3x.png'></image>
  81. <={{item.waterContent}}
  82. </view>
  83. <view>
  84. <image style='width:11px;height:11px;' src='../../static/img/homepage/unitweight@3x.png'></image>
  85. >={{item.bulkDensity}}
  86. </view>
  87. </view>
  88. </view>
  89. </view>
  90. </scroll-view>
  91. </view>
  92. <view class="guess-section-wrap1">
  93. <view style='padding:15px;' class='flex justify-between'>
  94. <view class='title'>行业新闻</view>
  95. <view style='color:#B2B3BB;' @click="more('/pages/sale/newsinfo')">更多</view>
  96. </view>
  97. <view style='border-bottom:1px solid #EEEEEE;' class='guess-section-wrap-content1'>
  98. <view style='border-bottom:1px solid #eee;padding:15px;' class='flex justify-between' v-for='(item, index) in newsInfo' :key="index" @click="navToDetailPage(item.id)">
  99. <view>
  100. <view class="list-row-titel">{{item.title}}</view>
  101. <view style='color:#B2B3BB;font-size:12px;'><text style='margin-right:5px;'>{{item.from}}</text>{{item.gmtUpdate}}</view>
  102. </view>
  103. <view><image style='width:100px;height:72px;border-radius:5px;' :src='item.titleImg'></image></view>
  104. </view>
  105. </view>
  106. </view>
  107. </view>
  108. </template>
  109. <script>
  110. import { formatDate } from '@/common/date.js';
  111. import dragButton from "@/components/drag-button/drag-button.vue";
  112. import swiperUp from "@/components/swiperup.vue";
  113. import {
  114. mapState
  115. } from 'vuex';
  116. export default {
  117. components: {
  118. dragButton,
  119. swiperUp
  120. },
  121. name: "sale",
  122. data() {
  123. return {
  124. titleNViewBackground: '',
  125. swiperCurrent: 0,
  126. swiperLength: 0,
  127. carouselList: [],
  128. windowSpuList: [],
  129. categoryPickList: [],
  130. categoryButtomList: [],
  131. salesTop: [],
  132. saleInfo: [],
  133. portInfo: [],
  134. plantList:[],
  135. portList:[],
  136. banner: undefined,
  137. isVip: false,
  138. pages: 1, //页数
  139. limit: 10, //每次取条目数
  140. loadStatus: 'loading', //加载样式:more-加载前样式,loading-加载中样式,nomore-没有数据样式
  141. isLoadMore: false, //是否加载中
  142. showTran:true,
  143. list: [],
  144. scrollTop: 0,
  145. cardCur: 0,
  146. dotStyle: false,
  147. newsInfo: [],
  148. categoryList:[],
  149. pages:1,//页数
  150. limit:10 ,//每次取条目数
  151. loadStatus:'loading', //加载样式:more-加载前样式,loading-加载中样式,nomore-没有数据样式
  152. TabCur: 0,
  153. category:0,
  154. current: 0,
  155. infoList1:[],
  156. statusBarHeight:"height:"
  157. };
  158. },
  159. onReady() {
  160. },
  161. onShow() {
  162. uni.showTabBar()
  163. this.pages = 1
  164. this.isLoadMore = false
  165. this.loadStatus = 'more'
  166. this.loadData()
  167. var userInfo = uni.getStorageSync("userInfo")
  168. var that = this
  169. this.$api.doRequest('get', '/salePlanInfo/getTips', {phone:userInfo.phone}).then(res => {
  170. if (res.data.data) {
  171. let name = 'myTip';
  172. let value = res.data.data.myTip;
  173. that.$store.commit('$uStore', {
  174. name,
  175. value
  176. });
  177. if(value != 0){
  178. uni.setTabBarBadge({
  179. index:3,
  180. text:value+""
  181. })
  182. }
  183. name = 'taskTip';
  184. value = res.data.data.taskTip;
  185. that.$store.commit('$uStore', {
  186. name,
  187. value
  188. });
  189. name = 'contractTip';
  190. value = res.data.data.contractTip;
  191. that.$store.commit('$uStore', {
  192. name,
  193. value
  194. });
  195. }
  196. })
  197. },
  198. onLoad(options) {
  199. var that = this
  200. uni.getSystemInfo({
  201. success: function(res) {
  202. console.log("statusBarHeight",res.statusBarHeight)
  203. that.statusBarHeight += res.statusBarHeight + "px"; //这就是状态栏的高度
  204. },
  205. });
  206. var infoList = [];
  207. uni.request({
  208. url: "https://hq.sinajs.cn/list=C0,C2109,C2111,C2201,C2203,C2205,C2207,A0,A2109,A2111,A2201,A2203,A2205,A2207",
  209. // url: "https://hq.sinajs.cn/list=C2109",
  210. header: {
  211. 'content-type': 'application/x-www-form-urlencoded'
  212. },
  213. success: function(result) {
  214. // resolve调用后,即可传递到调用方使用then或者async+await同步方式进行处理逻辑
  215. var tmp = result.data.split('"')
  216. for(var i = 1; i<tmp.length;i=i+2){
  217. var list = tmp[i].split(",")
  218. var data = {
  219. goodsName:list[0],
  220. newPrice:list[6],
  221. openPrice:list[2]
  222. }
  223. if(data.goodsName){
  224. infoList.push(data)
  225. }
  226. }
  227. let name = 'infoList';
  228. let value = infoList;
  229. that.$store.commit('$uStore', {
  230. name,
  231. value
  232. });
  233. // console.log("infoList",infoList)
  234. },
  235. fail: function(e) {
  236. console.log('error in...')
  237. // reject调用后,即可传递到调用方使用catch或者async+await同步方式进行处理逻辑
  238. reject(e)
  239. },
  240. })
  241. },
  242. onPageScroll(e) {
  243. this.scrollTop = e.scrollTop;
  244. },
  245. onReachBottom() { //上拉触底函数
  246. // if (!this.isLoadMore) { //此处判断,上锁,防止重复请求
  247. // this.isLoadMore = true
  248. // this.pages += 1
  249. // this.getIndexSaleData()
  250. // }
  251. },
  252. onPullDownRefresh() {
  253. this.pages = 1
  254. this.isLoadMore = false
  255. this.loadStatus = 'loading'
  256. this.loadData()
  257. setTimeout(function () {
  258. uni.stopPullDownRefresh();
  259. }, 1000);
  260. },
  261. computed: {
  262. ...mapState(['hasLogin', 'userInfo'])
  263. },
  264. methods: {
  265. more(url){
  266. console.log(url)
  267. uni.navigateTo({
  268. url: url
  269. })
  270. },
  271. DotStyle(e) {
  272. this.dotStyle = e.detail.value
  273. },
  274. cardSwiper(e) {
  275. this.cardCur = e.detail.current
  276. },
  277. hangqing() {
  278. uni.navigateTo({
  279. url: `/pageB/news/news`
  280. })
  281. },
  282. tabSelect(e) {
  283. this.TabCur = e.currentTarget.dataset.id;
  284. this.category = this.TabCur
  285. this.pages = 1
  286. this.loadData()
  287. },
  288. //回到顶部
  289. goTop(e) { // 一键回到顶部
  290. console.log(e)
  291. if (wx.pageScrollTo) {
  292. wx.pageScrollTo({
  293. scrollTop: 0
  294. })
  295. } else {
  296. wx.showModal({
  297. title: '提示',
  298. content: '当前微信版本过低,无法使用该功能,请升级到最新微信版本后重试。'
  299. })
  300. }
  301. },
  302. async loadData() {
  303. console.log("sale loadData pages " + this.pages)
  304. const that = this
  305. // 新闻类型
  306. uni.showLoading({
  307. title: '正在加载',
  308. })
  309. that.$api.request('dict', 'getDictDataList',{
  310. dictType: "news_type"
  311. }, failres => {
  312. that.$api.msg(failres.errmsg)
  313. uni.hideLoading()
  314. }).then(res => {
  315. let data = res.data
  316. that.categoryList = data
  317. uni.hideLoading()
  318. })
  319. uni.showLoading({
  320. title: '正在加载',
  321. })
  322. // 工厂价格
  323. that.$api.request('news', 'getFactoryPriceInfo',{
  324. category:this.category,
  325. page: 1,
  326. limit:2
  327. }, failres => {
  328. that.$api.msg(failres.errmsg)
  329. this.isLoadMore = false
  330. this.loadStatus = 'nomore'
  331. if(this.pages>1){this.pages=1}
  332. uni.hideLoading()
  333. }).then(res => {
  334. let data = res.data
  335. that.plantList = data
  336. uni.hideLoading()
  337. })
  338. // 港口价格
  339. that.$api.request('news', 'getPortPriceInfo',{
  340. category:this.category,
  341. page: 1,
  342. limit:2
  343. }, failres => {
  344. that.$api.msg(failres.errmsg)
  345. this.isLoadMore = false
  346. this.loadStatus = 'nomore'
  347. if(this.pages>1){this.pages=1}
  348. uni.hideLoading()
  349. }).then(res => {
  350. let data = res.data
  351. that.portList = data
  352. uni.hideLoading()
  353. })
  354. // 新闻内容
  355. that.$api.request('news', 'getNewsInfo',{
  356. category:2,
  357. page: 1,
  358. limit:10
  359. }, failres => {
  360. that.$api.msg(failres.errmsg)
  361. this.isLoadMore = false
  362. this.loadStatus = 'nomore'
  363. if(this.pages>1){this.pages=1}
  364. uni.hideLoading()
  365. }).then(res => {
  366. let data = res.data
  367. that.newsInfo = data
  368. uni.hideLoading()
  369. })
  370. uni.showLoading({
  371. title: '正在加载',
  372. })
  373. that.$api.request('integral', 'getIndexData', failres => {
  374. that.$api.msg(failres.errmsg)
  375. this.isLoadMore = false
  376. this.loadStatus = 'nomore'
  377. if (this.pages > 1) {
  378. this.pages = 1
  379. }
  380. uni.hideLoading()
  381. uni.stopPullDownRefresh()
  382. }).then(res => {
  383. let data = res.data
  384. //橱窗
  385. that.windowSpuList = data.windowRecommend
  386. //轮播
  387. data.advertisement.t1.forEach(item => {
  388. if (!item.color) {
  389. item.color = 'rgb(205, 215, 218)'
  390. }
  391. })
  392. that.carouselList = data.advertisement.t1
  393. that.swiperLength = data.advertisement.t1.length
  394. that.titleNViewBackground = data.advertisement.t1[0].color
  395. //分类精选
  396. if (data.advertisement.t2) {
  397. that.categoryPickList = data.advertisement.t2
  398. }
  399. //横幅
  400. if (data.advertisement.t3 && data.advertisement.t3.length > 0) {
  401. that.banner = data.advertisement.t3[0]
  402. }
  403. //热销
  404. if (data.salesTop) {
  405. that.salesTop = data.salesTop
  406. }
  407. //销售信息
  408. if (data.saleInfo) {
  409. that.saleInfo = data.saleInfo
  410. }
  411. //价格简报
  412. if (data.portInfo) {
  413. that.portInfo = data.portInfo
  414. console.log("portInfo",that.portInfo)
  415. }
  416. //分类5Buttom
  417. if (data.advertisement.t4) {
  418. that.categoryButtomList = data.advertisement.t4
  419. }
  420. that.showTran = data.showTran
  421. that.list = data.message
  422. uni.setStorageSync("message", data.message);
  423. uni.setStorageSync("task", data.task);
  424. uni.setStorageSync('showTran', data.showTran);
  425. uni.hideLoading()
  426. uni.stopPullDownRefresh()
  427. })
  428. },
  429. //轮播图切换修改背景色
  430. swiperChange(e) {
  431. const index = e.detail.current;
  432. this.swiperCurrent = index;
  433. // this.titleNViewBackground = this.carouselList[index].color;
  434. },
  435. //详情
  436. navToDetailPage(item) {
  437. let id = item;
  438. uni.navigateTo({
  439. url: `/pageB/news/news_detail?id=${id}`
  440. })
  441. },
  442. naviageToPage(page) {
  443. uni.navigateTo({
  444. url: page,
  445. fail() {
  446. uni.switchTab({
  447. url: page
  448. })
  449. }
  450. })
  451. },
  452. getIndexSaleData() {
  453. // const that = this
  454. // var pages = that.pages
  455. // var limit = that.limit
  456. // uni.showLoading({
  457. // title: '正在加载'
  458. // })
  459. // that.$api.request('integral', 'getIndexSaleData', {
  460. // page: pages,
  461. // limit: limit
  462. // }, failres => {
  463. // that.$api.msg(failres.errmsg)
  464. // that.isLoadMore = false
  465. // that.loadStatus = 'nomore'
  466. // if (that.pages > 1) {
  467. // that.pages -= 1
  468. // }
  469. // uni.hideLoading()
  470. // }).then(res => {
  471. // let data = res.data
  472. // //销售信息
  473. // if (data.saleInfo.length > 0 ) {
  474. // that.saleInfo = that.saleInfo.concat(data.saleInfo)
  475. // that.isLoadMore = false
  476. // } else {
  477. // if (that.pages > 1) {
  478. // that.pages -= 1
  479. // }
  480. // that.isLoadMore = true
  481. // that.loadStatus = 'nomore'
  482. // }
  483. // if(data.saleInfo.length < that.limit){
  484. // if (that.pages > 1) {
  485. // that.pages -= 1
  486. // }
  487. // that.isLoadMore = true
  488. // that.loadStatus = 'nomore'
  489. // }
  490. // uni.hideLoading()
  491. // })
  492. const that = this
  493. var pages=that.pages
  494. var limit=that.limit
  495. uni.showLoading({
  496. title: '正在加载',
  497. })
  498. that.$api.request('news', 'getNewsInfo', {
  499. category:2,
  500. page: 1,
  501. limit:10
  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. that.newsInfo = data
  511. that.isLoadMore=false
  512. uni.hideLoading()
  513. })
  514. }
  515. },
  516. // #ifndef MP
  517. // 标题栏input搜索框点击
  518. onNavigationBarSearchInputClicked: async function(e) {
  519. uni.navigateTo({
  520. url: '/pageA/product/search'
  521. })
  522. },
  523. //点击导航栏 buttons 时触发
  524. // onNavigationBarButtonTap(e) {
  525. // const index = e.index;
  526. // if (index === 0) {
  527. // this.$api.msg('点击了扫描');
  528. // } else if (index === 1) {
  529. // // #ifdef APP-PLUS
  530. // const pages = getCurrentPages();
  531. // const page = pages[pages.length - 1];
  532. // const currentWebview = page.$getAppWebview();
  533. // currentWebview.hideTitleNViewButtonRedDot({
  534. // index
  535. // });
  536. // // #endif
  537. // uni.navigateTo({
  538. // url: '/pages/notice/notice'
  539. // })
  540. // }
  541. // }
  542. // #endif
  543. }
  544. </script>
  545. <style lang="scss" scoped>
  546. .container{
  547. margin: 10rpx 10rpx 10rpx 10rpx;
  548. }
  549. .cu-tag.badge {
  550. right: 26rpx;
  551. }
  552. .up,.down{
  553. width: 8px;
  554. height: 5px;
  555. vertical-align: middle;
  556. margin-left: 2px;
  557. }
  558. .gird-left,.gird-right{
  559. }
  560. .cu-tag.radius[class*="line"]::after {
  561. border-radius: 66rpx;
  562. }
  563. .goTop{
  564. height: 32px;
  565. width: 32px;
  566. position: fixed;
  567. bottom: 200rpx;
  568. right: 30rpx;
  569. border-radius: 50%;
  570. }
  571. .goTop image{
  572. width:32px;
  573. height:32px;
  574. }
  575. .flex{
  576. display:flex;
  577. }
  578. .text-white{
  579. color:#fff;
  580. }
  581. .cu-card{
  582. border-bottom:1rpx solid #f8f8f8;
  583. text-align: center;
  584. }
  585. .factorytitle view{
  586. border-right: 1px solid #F8F8F8;
  587. }
  588. .factorytitle view:last-child{
  589. border-right: 1px solid transparent;
  590. }
  591. .factory{
  592. font-size:26rpx;
  593. font-weight:900;
  594. }
  595. .currectprice{
  596. color:rgba(253, 113, 79, 1);
  597. font-size:18px;
  598. font-weight:600;
  599. vertical-align: middle;
  600. margin-right:10px;
  601. }
  602. .yesterday{
  603. font-size:14px;
  604. font-weight:600;
  605. vertical-align: middle;
  606. }
  607. .yesterday.up{
  608. color:rgba(253, 113, 79, 1);
  609. }
  610. .yesterday.down{
  611. color:#22C572;
  612. }
  613. .positive{
  614. color:#E63113;
  615. font-size:26rpx;
  616. font-weight:900;
  617. }
  618. .negative{
  619. color:#229453;
  620. font-size:26rpx;
  621. font-weight:900;
  622. }
  623. .wrap{
  624. font-size:20rpx;
  625. color: rgba(0,0,0,0.5);
  626. }
  627. .align-center{
  628. align-items: center;
  629. }
  630. .flex-direction-row{
  631. flex-direction:row;
  632. }
  633. .factoryItem{
  634. padding: 20rpx 0;
  635. }
  636. /* #ifdef MP */
  637. .mp-search-box {
  638. // position:relative;
  639. left: 0;
  640. top: 30upx;
  641. z-index: 9999;
  642. width: 100%;
  643. padding: 0 80upx;
  644. background: rgba(255, 170, 0, 0.6);
  645. .ser-input {
  646. flex: 1;
  647. height: 56upx;
  648. line-height: 56upx;
  649. text-align: center;
  650. font-size: 28upx;
  651. color: $font-color-base;
  652. border-radius: 10px;
  653. background: rgba(255, 255, 255, .6);
  654. }
  655. }
  656. .desc{
  657. width:73%;
  658. margin-right:2%;
  659. }
  660. .justify-between{
  661. justify-content: space-between;
  662. }
  663. page {
  664. .cate-section {
  665. position: relative;
  666. z-index: 5;
  667. border-radius: 16upx 16upx 0 0;
  668. margin-top: -20upx;
  669. }
  670. .carousel-section {
  671. padding: 0;
  672. .titleNview-placing {
  673. padding-top: 0;
  674. height: 0;
  675. }
  676. .carousel {
  677. .carousel-item {
  678. padding: 0;
  679. }
  680. }
  681. .swiper-dots {
  682. left: 50%;
  683. bottom: 5upx;
  684. transform: translateX(-50%);
  685. }
  686. }
  687. }
  688. /* #endif */
  689. .cuIcon-notification::before{
  690. color:#f37b1;
  691. }
  692. .cu-card.article>.cu-item .content>image {
  693. height: 3.4em;
  694. margin-right: 0rpx;
  695. margin-top: 24rpx;
  696. }
  697. .screen-swiper.price-swiper{
  698. height:70rpx;
  699. min-height: 70rpx;
  700. background: #fff;
  701. margin-bottom: 10px;
  702. }
  703. .swiper-item{
  704. border-radius: 5%;
  705. }
  706. .guess-section-wrap {
  707. padding:15px;
  708. margin:10px 5px;
  709. border-radius:5px;
  710. background:#fff;
  711. overflow:hidden;
  712. }
  713. .guess-section-wrap1 {
  714. margin:10px 5px;
  715. border-radius:5px;
  716. background:#fff;
  717. overflow:hidden;
  718. height:366px;
  719. }
  720. .guess-section-wrap-content{
  721. width:1500px;
  722. // display:flex;
  723. }
  724. .guess-section-wrap-content.port{
  725. width:3000px;
  726. }
  727. .guess-section-wrap-item{
  728. float:left;
  729. width:40vw;
  730. background:#F9F9FA;
  731. padding:10px;
  732. margin:10px;
  733. border-radius:3px;
  734. // width:50%;
  735. }
  736. .guess-section-wrap-item:first-child{
  737. // margin-left:2px;
  738. }
  739. .clearfix:after{
  740. content:"";
  741. display:block;
  742. clear:both;
  743. }
  744. .guess-section-wrap .price{
  745. color:#B2B3BB;
  746. }
  747. page {
  748. background: #f5f5f5;
  749. }
  750. .m-t {
  751. margin-top: 16upx;
  752. }
  753. .header-swiper{
  754. min-height: 300rpx;
  755. }
  756. /* 头部 轮播图 */
  757. .carousel-section {
  758. position: relative;
  759. // padding-top: 10px;
  760. .titleNview-placing {
  761. height: var(--status-bar-height);
  762. padding-top: 44px;
  763. box-sizing: content-box;
  764. }
  765. .titleNview-background {
  766. position: absolute;
  767. top: 0;
  768. left: 0;
  769. width: 100%;
  770. height: 426upx;
  771. transition: .4s;
  772. }
  773. }
  774. .tab-scroll-view {
  775. width: 750rpx;
  776. height: 300rpx;
  777. flex-direction: row;
  778. white-space: nowrap;
  779. .tab-item {
  780. display: inline-block;
  781. width: 350rpx;
  782. height: 250rpx;
  783. font-size: 16px;
  784. -moz-box-shadow: 2px 2px 5px #ccc;
  785. -webkit-box-shadow: 2px 2px 5px #ccc;
  786. box-shadow: 2px 2px 5px #ccc;
  787. color: #555;
  788. margin: 10rpx;
  789. }
  790. }
  791. .carousel {
  792. width: 100%;
  793. height: 350upx;
  794. .carousel-item {
  795. width: 100%;
  796. height: 100%;
  797. // padding: 0 28upx;
  798. overflow: hidden;
  799. }
  800. image {
  801. width: 100%;
  802. height: 100%;
  803. // border-radius: 10upx;
  804. }
  805. }
  806. .swiper-dots {
  807. display: flex;
  808. position: absolute;
  809. left: 60upx;
  810. bottom: 15upx;
  811. width: 72upx;
  812. height: 36upx;
  813. background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAMgAAABkCAYAAADDhn8LAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyZpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuNi1jMTMyIDc5LjE1OTI4NCwgMjAxNi8wNC8xOS0xMzoxMzo0MCAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wTU09Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9tbS8iIHhtbG5zOnN0UmVmPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvc1R5cGUvUmVzb3VyY2VSZWYjIiB4bWxuczp4bXA9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC8iIHhtcE1NOkRvY3VtZW50SUQ9InhtcC5kaWQ6OTk4MzlBNjE0NjU1MTFFOUExNjRFQ0I3RTQ0NEExQjMiIHhtcE1NOkluc3RhbmNlSUQ9InhtcC5paWQ6OTk4MzlBNjA0NjU1MTFFOUExNjRFQ0I3RTQ0NEExQjMiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENDIDIwMTcgKFdpbmRvd3MpIj4gPHhtcE1NOkRlcml2ZWRGcm9tIHN0UmVmOmluc3RhbmNlSUQ9InhtcC5paWQ6Q0E3RUNERkE0NjExMTFFOTg5NzI4MTM2Rjg0OUQwOEUiIHN0UmVmOmRvY3VtZW50SUQ9InhtcC5kaWQ6Q0E3RUNERkI0NjExMTFFOTg5NzI4MTM2Rjg0OUQwOEUiLz4gPC9yZGY6RGVzY3JpcHRpb24+IDwvcmRmOlJERj4gPC94OnhtcG1ldGE+IDw/eHBhY2tldCBlbmQ9InIiPz4Gh5BPAAACTUlEQVR42uzcQW7jQAwFUdN306l1uWwNww5kqdsmm6/2MwtVCp8CosQtP9vg/2+/gY+DRAMBgqnjIp2PaCxCLLldpPARRIiFj1yBbMV+cHZh9PURRLQNhY8kgWyL/WDtwujjI8hoE8rKLqb5CDJaRMJHokC6yKgSCR9JAukmokIknCQJpLOIrJFwMsBJELFcKHwM9BFkLBMKFxNcBCHlQ+FhoocgpVwwnv0Xn30QBJGMC0QcaBVJiAMiec/dcwKuL4j1QMsVCXFAJE4s4NQA3K/8Y6DzO4g40P7UcmIBJxbEesCKWBDg8wWxHrAiFgT4fEGsB/CwIhYE+AeBAAdPLOcV8HRmWRDAiQVcO7GcV8CLM8uCAE4sQCDAlHcQ7x+ABQEEAggEEAggEEAggEAAgQACASAQQCCAQACBAAIBBAIIBBAIIBBAIABe4e9iAe/xd7EAJxYgEGDeO4j3EODp/cOCAE4sYMyJ5cwCHs4rCwI4sYBxJ5YzC84rCwKcXxArAuthQYDzC2JF0H49LAhwYUGsCFqvx5EF2T07dMaJBetx4cRyaqFtHJ8EIhK0i8OJBQxcECuCVutxJhCRoE0cZwMRyRcFefa/ffZBVPogePihhyCnbBhcfMFFEFM+DD4m+ghSlgmDkwlOgpAl4+BkkJMgZdk4+EgaSCcpVX7bmY9kgXQQU+1TgE0c+QJZUUz1b2T4SBbIKmJW+3iMj2SBVBWz+leVfCQLpIqYbp8b85EskIxyfIOfK5Sf+wiCRJEsllQ+oqEkQfBxmD8BBgA5hVjXyrBNUQAAAABJRU5ErkJggg==);
  814. background-size: 100% 100%;
  815. .num {
  816. width: 36upx;
  817. height: 36upx;
  818. border-radius: 50px;
  819. font-size: 24upx;
  820. color: #fff;
  821. text-align: center;
  822. line-height: 36upx;
  823. }
  824. .sign {
  825. position: absolute;
  826. top: 0;
  827. left: 50%;
  828. line-height: 36upx;
  829. font-size: 12upx;
  830. color: #fff;
  831. transform: translateX(-50%);
  832. }
  833. }
  834. /* 分类 */
  835. .cate-section {
  836. display: flex;
  837. justify-content: space-around;
  838. align-items: center;
  839. flex-wrap: wrap;
  840. padding: 30upx 22upx;
  841. background: #fff;
  842. .cate-item {
  843. display: flex;
  844. flex-direction: column;
  845. align-items: center;
  846. font-size: $font-sm + 2upx;
  847. color: $font-color-dark;
  848. }
  849. /* 原图标颜色太深,不想改图了,所以加了透明度 */
  850. image {
  851. width: 68upx;
  852. height: 68upx;
  853. margin-bottom: 14upx;
  854. // border-radius: 50%;
  855. opacity: .7;
  856. // box-shadow: 4upx 4upx 20upx rgba(250, 67, 106, 0.3);
  857. }
  858. .grid_icon{
  859. font-size: 48upx;
  860. margin-bottom: 18upx;
  861. color: #fa436a;
  862. }
  863. }
  864. .ad-1 {
  865. width: 100%;
  866. height: 210upx;
  867. padding: 10upx 0;
  868. background: #fff;
  869. image {
  870. width: 100%;
  871. height: 100%;
  872. }
  873. }
  874. /* 销售信息 */
  875. .introduce-section {
  876. background: #fff;
  877. padding: 20upx 30upx;
  878. padding-bottom: 100upx;
  879. .guess-item {
  880. padding-bottom: 20upx;
  881. border-bottom: 1px solid #ccc;
  882. }
  883. .title {
  884. font-size: 28upx;
  885. color: $font-color-dark;
  886. font-weight:bold;
  887. height: 50upx;
  888. line-height: 50upx;
  889. flex:2.5;
  890. }
  891. .title-tip {
  892. flex:1;
  893. }
  894. .price-box {
  895. display: flex;
  896. align-items: baseline;
  897. height: 70upx;
  898. padding: 10upx 0;
  899. font-size: 26upx;
  900. color: $uni-color-primary;
  901. }
  902. .price {
  903. font-size: $font-lg + 2upx;
  904. }
  905. .m-price {
  906. margin: 0 12upx;
  907. color: $font-color-light;
  908. text-decoration: line-through;
  909. }
  910. .coupon-tip {
  911. align-items: center;
  912. padding: 4upx 10upx;
  913. background: $uni-color-primary;
  914. font-size: $font-sm;
  915. color: #fff;
  916. border-radius: 6upx;
  917. line-height: 1;
  918. transform: translateY(-4upx);
  919. }
  920. .bot-row {
  921. display: flex;
  922. align-items: center;
  923. height: 50upx;
  924. font-size: $font-sm;
  925. color: $font-color-light;
  926. view {
  927. flex: 1;
  928. }
  929. }
  930. .status_bar {
  931. width: 100%;
  932. }
  933. }
  934. .title{
  935. font-size: 34rpx;
  936. font-weight: 700;
  937. color: #333333;
  938. }
  939. .list-row-titel{
  940. text-overflow: -o-ellipsis-lastline;
  941. overflow: hidden;
  942. text-overflow: ellipsis;display:
  943. -webkit-box;-webkit-line-clamp: 2;
  944. -webkit-box-orient: vertical;
  945. font-size:16px;
  946. height:45px;
  947. padding-right: 40rpx;
  948. margin-bottom: 26rpx;
  949. }
  950. </style>