diff --git a/components/bubble-popup/index.js b/components/bubble-popup/index.js index 738c24d..869ec6c 100644 --- a/components/bubble-popup/index.js +++ b/components/bubble-popup/index.js @@ -40,7 +40,7 @@ Component({ //背景颜色 backgroundColor: { type: String, - value: '#4c4c4c' + value: '#fff' }, //字体颜色 color: { @@ -91,7 +91,7 @@ Component({ }, maskBgColor: { type: String, - value: 'rgba(0, 0, 0, 0.4)' + value: 'rgba(0, 0, 0, 0)' }, //控制显示 show: { diff --git a/components/bubble-popup/index.wxss b/components/bubble-popup/index.wxss index 7a572e7..0655f67 100644 --- a/components/bubble-popup/index.wxss +++ b/components/bubble-popup/index.wxss @@ -1,2 +1,2 @@ /* components/bubble-popup.wxss */ -.tui-popup-list{z-index:1;-webkit-transition:all .3s ease-in-out;transition:all .3s ease-in-out;opacity:0;visibility:hidden}.tui-flex-end{width:100%;display:-webkit-box;display:-webkit-flex;display:flex;-webkit-box-pack:end;-webkit-justify-content:flex-end;justify-content:flex-end}.tui-triangle{position:absolute;width:0;height:0;border-style:solid;z-index:997}.tui-popup-mask{position:fixed;top:0;left:0;right:0;bottom:0;z-index:995;-webkit-transition:all .3s ease-in-out;transition:all .3s ease-in-out;opacity:0;visibility:hidden}.tui-popup-show{opacity:1;visibility:visible}.tui-z_index{z-index:996} \ No newline at end of file +.tui-popup-list{z-index:1;-webkit-transition:all .3s ease-in-out;transition:all .3s ease-in-out;opacity:0;visibility:hidden;box-shadow: 0 0 10px rgba(100, 100, 100, .5)}.tui-flex-end{width:100%;display:-webkit-box;display:-webkit-flex;display:flex;-webkit-box-pack:end;-webkit-justify-content:flex-end;justify-content:flex-end}.tui-triangle{position:absolute;width:0;height:0;border-style:solid;z-index:997}.tui-popup-mask{position:fixed;top:0;left:0;right:0;bottom:0;z-index:995;-webkit-transition:all .3s ease-in-out;transition:all .3s ease-in-out;opacity:0;visibility:hidden}.tui-popup-show{opacity:1;visibility:visible}.tui-z_index{z-index:9} \ No newline at end of file diff --git a/components/tabi/index.js b/components/tabi/index.js index 599077e..817eb07 100644 --- a/components/tabi/index.js +++ b/components/tabi/index.js @@ -17,6 +17,10 @@ Component({ type: Boolean, value: false }, + lineHeight: { + type: Number, + value: 4, + }, // view宽度 padding: { type: Number, diff --git a/components/tabi/index.wxml b/components/tabi/index.wxml index eeb9d7b..0b85b78 100644 --- a/components/tabi/index.wxml +++ b/components/tabi/index.wxml @@ -4,7 +4,7 @@ {{item}} - + \ No newline at end of file diff --git a/pages/article/newInfo/index.js b/pages/article/newInfo/index.js new file mode 100644 index 0000000..085e007 --- /dev/null +++ b/pages/article/newInfo/index.js @@ -0,0 +1,134 @@ +// pages/stock/index.js +const util = require('../../../utils/util') +const math = require('../../../utils/math') //导入模块 +const app = getApp() + +import { getPaperMillOfInformationList } from "../../../api/ztb" +import { getPreferList } from "../../../api/moment" +Component({ + options: { + addGlobalClass: true, + multipleSlots: true + }, + /** + * 页面的初始数据 + */ + data: { + height: app.globalData.safeFragmentHeight - 190, + safeBottom: app.globalData.safeBottom, + orderList: [], + tableSgin: null, + loading:false, + pximg:'/assets/info/px-sx.png', + curDate: util.formatDate(new Date(), 'Y-M-D'), + querFrom:{ + curDate: util.formatDate(new Date(), 'Y-M-D'), + queryWay: 0, + priceSort:1 + }, + factoryList:[], + scorllHeight:app.globalData.safeFragmentHeight + }, + methods: { + onRestart: function () { + this.setData({ + StatusBar: app.globalData.StatusBar || 40, + CustomBar: app.globalData.CustomBar || (app.globalData.isIos ? 64 : 80), + scorllHeight:app.globalData.safeFragmentHeight - 100 + }) + this.data.querFrom.queryWay=0 + this.getPaperMillOfInformationListFct(this.data.querFrom) + this.fetchMomentList() + }, + toPage: function (e) { + if (e.currentTarget.id == 'toqb') { + util.navigateTo('/pakageInfo/pages/article/index/index') + } + if (e.currentTarget.id == 'toAllFactory') { + util.navigateTo('/pakageInfo/pages/article/allNewInfo/index') + } + if(e.currentTarget.id == 'toAttentionFactory'){ + util.navigateTo('/pages/home/attentionPaperList/index') + } + if(e.currentTarget.id == 'tofeedback'){ + util.navigateTo('/pakageInfo/pages/article/feedback/index') + } + if(e.currentTarget.id == 'toFactoryDetails'){ + util.navigateTo('/pages/agent/factory/index?id='+e.currentTarget.dataset.factoryid) + } + if(e.currentTarget.id == 'toDmai'){ + if (!app.globalData.userInfo) { + wx.navigateTo({ url: '/pages/login/index' }) + return + } + if(!e.currentTarget.dataset.operations){ + util.showToast(e.currentTarget.dataset.msg) + return + } + util.navigateTo('/pages/agent/edit/index?id='+e.currentTarget.dataset.fcid+'&categoryId='+e.currentTarget.dataset.paperid) + } + }, + toPageDetails:function(e){ + util.navigateTo('/pakageInfo/pages/article/detail/index?id='+e.currentTarget.id) + }, + changeTable: function (e) { + if (e.currentTarget.id === this.data.tableSgin) { + this.setData({ tableSgin: null }) + } else { + this.setData({ tableSgin: e.currentTarget.id }) + } + }, + getPaperMillOfInformationListFct:function(model) { + this.setData({ + loading:true + }) + getPaperMillOfInformationList(model).then(res => { + this.setData({ + orderList: res.data + }) + this.setData({ + loading:false + }) + }) + }, + changeSort:function(){ + if(this.data.pximg=='/assets/info/px-jx.png'){ + this.setData({ + pximg:'/assets/info/px-sx.png' + }) + this.data.querFrom.priceSort=1 + this.getPaperMillOfInformationListFct(this.data.querFrom) + return + } + if(this.data.pximg=='/assets/info/px-sx.png'){ + this.setData({ + pximg:'/assets/info/px-jx.png' + }) + this.data.querFrom.priceSort=0 + this.getPaperMillOfInformationListFct(this.data.querFrom) + return + } + }, + curDateChange(e) { + this.setData({ + curDate: e.detail.value + }) + this.data.querFrom.curDate=e.detail.value + this.getPaperMillOfInformationListFct(this.data.querFrom) + }, + fetchMomentList: function(){ + getPreferList().then(result => { + this.setData({ factoryList: result.data.records.slice(0, 3) }) + }) + }, + toMill(e){ + util.navigateTo('/pages/agent/factory/index?id=' + e.currentTarget.id) + }, + + mathTimesRtrun:function(text){ + return math.times(text, 1000) + }, + + } + +}) \ No newline at end of file diff --git a/pages/article/newInfo/index.json b/pages/article/newInfo/index.json new file mode 100644 index 0000000..8cef1c0 --- /dev/null +++ b/pages/article/newInfo/index.json @@ -0,0 +1,8 @@ +{ + "component": true, + "usingComponents": { + "wux-tabi": "/components/tabi/index", + "wux-accordion-group": "/components/accordion-group/index", + "wux-accordion": "/components/accordion/index" + } +} \ No newline at end of file diff --git a/pages/article/newInfo/index.wxml b/pages/article/newInfo/index.wxml new file mode 100644 index 0000000..94ac096 --- /dev/null +++ b/pages/article/newInfo/index.wxml @@ -0,0 +1,177 @@ + + + + + + + + + 纸厂情报 + 全部纸厂> + + + + + + + + {{curDate}} + + + + + + + + + + + 反馈情报 + + + + + + + + 纸厂名称 + + 价格涨跌 + + + 纸厂排队 + 最近扣点 + + + + + + + {{loading? '正在加载' : '暂无关注'}} + 可前往纸厂列表添加关注 + 添加关注 + + + + + {{m2.newString(item.shortName)}} + + {{ formate.formateDrice(item.unitPrice)}}{{item.biggestFloatPrice>0?'↑':(item.biggestFloatPrice<0?'↓':'')}} + {{ item.biggestFloatPrice > 0 ? '+' : '' }}{{ formate.formateDrice(item.biggestFloatPrice)}} + + {{item.yesterdayTotalQuantity || 0}}辆 + + + + + {{formate.formateDescripe(item.minimumDeductionPoint)}} + + {{formate.substring(item.priceDate, 0, 10)}} + + + + + + + + + + + + + 品类 + 价格 + 涨跌 + 最近扣点 + 操作 + + + {{cell.categoryName|| '---'}} + + {{formate.formatePrice(cell.unitPrice)}}{{cell.floatPrice>0?'↑':(cell.floatPrice<0?'↓':'')}} + + {{cell.floatPrice>0?'+':''}}{{formate.formatePrice(cell.floatPrice)}} + + {{formate.formateDescripe(cell.curDeductionPoint)}} + + 代卖 + + + + + + + + + 行业情报 + 更多资讯> + + + + + + + + + # + {{m1.newString(item.millPaperName)}} + + {{item.title}} + + + + {{item.creatorName}} + + {{item.updateTime}} + + + + + + + + + + + + var newString = function (string) { + var newString = string.substring(0, 4) + + return newString + '...'; + } + + module.exports.newString = newString; + + + var newString = function (string) { + if (string.length > 4) { + var newString = string.substring(0, 4) + + return newString + '...'; + }else{ + return string + } + + } + + module.exports.newString = newString; + \ No newline at end of file diff --git a/pages/article/newInfo/index.wxss b/pages/article/newInfo/index.wxss new file mode 100644 index 0000000..e4cd6d9 --- /dev/null +++ b/pages/article/newInfo/index.wxss @@ -0,0 +1,243 @@ +/* pages/main/index.wxss */ +page { + background-color: white; +} + +.booking-tool { + width: calc(100% - 20px); + background-color: #008AFF; + position: fixed; + left: 25px; +} + +.roder-add { + display: flex; + justify-content: center; + align-items: center; + width: 100rpx; + height: 100rpx; + background-color: #008AFF; + border-radius: 50rpx; + position: absolute; + top: 24px; + right: 24px; + box-shadow: 0px 3px 6px rgba(0, 0, 0, 0.16); +} + +.boderLine { + width: 100%; + height: 50rpx; + background-color: #f3f3f3; +} + +.midTietle { + height: 100rpx; + width: 100%; + background-color: white; + display: flex; + justify-content: space-between; + padding: 0rpx 40rpx 0rpx 40rpx; +} + +.midTietleText1 { + height: 100rpx; + line-height: 100rpx; + font-family: PingFangSC-Medium; + font-size: 36rpx; + color: rgba(0, 0, 0, 0.85); + letter-spacing: 0; + text-align: left; +} + +.midTietleText2 { + height: 100rpx; + line-height: 100rpx; + font-family: PingFangSC-Regular; + font-size: 28rpx; + color: rgba(0, 0, 0, 0.65); + letter-spacing: 0; + text-align: right; +} + +.zt { + background-color: white; +} + +.topTitle { + display: flex; + justify-content: space-between; +} + +.topRight { + width: 50%; + height: 70rpx; +} + +.topLeft { + width: 50%; + height: 80rpx; + display: flex; + justify-content: space-between; +} + +.topLeftText { + font-family: PingFangSC-Medium; + font-size: 36rpx; + color: #FFFFFF; + letter-spacing: 0; + height: 60rpx; + line-height: 60rpx; + padding-left: 32rpx; +} + +.topLeftTime { + font-family: PingFangSC-Medium; + font-size: 28rpx; + color: #FFFFFF; + letter-spacing: 0; + height: 60rpx; + line-height: 60rpx; + padding-left: 32rpx; +} + +.topRightText { + font-family: PingFangSC-Medium; + font-size: 28rpx; + color: #FFFFFF; + letter-spacing: 0; + height: 60rpx; + line-height: 60rpx; +} + +.topRight-text{ + height: 80rpx; + width: 200rpx; + text-align: right; + line-height: 80rpx; +} +.topRight-icon{ + float: right; + height: 70rpx; + display: flex; + align-items: center; + margin-right: 35rpx; +} + +.topRightIcon { + height: 60rpx; + float: right; + display: flex; + align-items: center; + margin-right: 36.3rpx; +} + +.onDataImg { + width: 320rpx; + height: 249rpx; +} + +.img-nodata { + width: 100%; + height: 548rpx; + display: flex; + flex-direction: column; + align-items: center; + margin-top: 30rpx; +} + +.top-nodata-text1 { + font-family: PingFangSC-Medium; + font-size: 30rpx; + color: rgba(0, 0, 0, 0.75); + letter-spacing: 0; + text-align: left; + margin-top: 16rpx; +} + +.top-nodata-text2 { + width: 480rpx; + height: 88rpx; + background: #007AFF; + border-radius: 10rpx; + border-radius: 10rpx; + font-family: PingFangSC-Medium; + font-size: 36rpx; + color: #FFFFFF; + letter-spacing: 0; + text-align: left; + line-height: 88rpx; + text-align: center; + margin-top: 41rpx; +} + +.bottomView { + width: 750rpx; + height: 228rpx; + padding: 24rpx 32rpx 24rpx 32rpx; + border-bottom: 1px solid #f3f3f3; +} + +.bottomViewleft { + width: 423rpx; + height: 180rpx; + + float: left; +} + +.bottomViewRight { + width: 240rpx; + height: 180rpx; + float: right; + overflow: hidden; +} + +.tableStyle { + width: 100%; + line-height: 100rpx; + font-size: 34rpx; + color: rgba(0, 0, 0, 0.85); + letter-spacing: 0; +} + +.son-table-btn { + width: 120rpx; + height: 56rpx; + line-height: 56rpx; + font-size: 26rpx; + color: #007AFF; + letter-spacing: 0; + text-align: left; + background: #FFFFFF; + border: 1rpx solid #007AFF; + border-radius: 28rpx; + border-radius: 28rpx; + text-align: center; +} + +.bottomViewleft-top { + width: 100%; + height: 90rpx; + +} + +.bottomViewleft-bottem { + width: 100%; + height: 33rpx; + + margin-top: 57rpx; +} + +.bottomViewRightImg { + width: 240rpx; + height: 180rpx; +} + +.piker { + height: 80rpx; + line-height: 80rpx; + font-family: PingFangSC-Medium; + font-size: 28rpx; + color: rgba(0, 0, 0, 0.40); + letter-spacing: 0; + padding-left: 20rpx; +} \ No newline at end of file diff --git a/pages/mall/fragment/index.wxml b/pages/mall/fragment/index.wxml index 9db933c..3566caa 100644 --- a/pages/mall/fragment/index.wxml +++ b/pages/mall/fragment/index.wxml @@ -64,19 +64,21 @@ 价格比一比 - 更多 - + 排序 + - 菜单一 - 菜单二 - 菜单三 + width="240rpx" right="4rpx" bottom="-480rpx" translateY="-100%" triangleRight="50rpx" triangleTop="-22rpx" bind:close="topBubble"> + 更新时间 + 价格升序 + 价格降序 + 排队升序 + 排队降序 - + diff --git a/pages/mall/fragment/index.wxss b/pages/mall/fragment/index.wxss index 334ff3a..ecc2547 100644 --- a/pages/mall/fragment/index.wxss +++ b/pages/mall/fragment/index.wxss @@ -39,7 +39,10 @@ } .tui-menu-item { - width: 100%; - padding: 30rpx 20rpx; + width: 100%; + text-align: center; + color: #555; + padding: 16rpx 24rpx; + border-bottom: 1rpx solid rgba(0,0,0,0.05); box-sizing: border-box } \ No newline at end of file