21 changed files with 711 additions and 498 deletions
Unified View
Diff Options
-
87colorui/main.wxss
-
96pages/agent/ability/index.js
-
14pages/agent/ability/index.json
-
32pages/agent/ability/index.wxml
-
63pages/agent/ability/index.wxss
-
151pages/agent/factory-fragment/index.js
-
14pages/agent/factory-fragment/index.json
-
32pages/agent/factory-fragment/index.wxml
-
1pages/agent/factory-fragment/index.wxss
-
141pages/agent/focus-fragment/index.js
-
15pages/agent/focus-fragment/index.json
-
41pages/agent/focus-fragment/index.wxml
-
60pages/agent/focus-fragment/index.wxss
-
233pages/agent/index/index.js
-
12pages/agent/index/index.json
-
138pages/agent/index/index.wxml
-
6pages/article/newInfo/index.js
-
6pages/article/newInfo/index.wxml
-
64pages/home/attentionPaperList/index.js
-
1pages/index/index.js
-
2pages/message/index/index.js
@ -0,0 +1,96 @@ |
|||||
|
// pages/agent/index/index.js
|
||||
|
import { getFactoryPrice } from "../../api/ztb" |
||||
|
const app = getApp() |
||||
|
|
||||
|
Page({ |
||||
|
/** |
||||
|
* 页面的初始数据 |
||||
|
*/ |
||||
|
data: { |
||||
|
height: app.globalData.fragmentHeight, |
||||
|
kg: app.globalData.kg, |
||||
|
loading: true, |
||||
|
requesting: false, |
||||
|
finished: false, |
||||
|
scrolled: false, |
||||
|
top: 0, |
||||
|
orderList: [], |
||||
|
form: { |
||||
|
cityId: '', |
||||
|
enableSalesAgent: 1, |
||||
|
pageNum: 1, |
||||
|
listType: 0 |
||||
|
} |
||||
|
}, |
||||
|
/** |
||||
|
* 生命周期函数--监听页面加载 |
||||
|
*/ |
||||
|
onLoad: function (options) { |
||||
|
this.setData({ height: app.globalData.fragmentHeight }) |
||||
|
this.fetchPapersList() |
||||
|
}, |
||||
|
// 下拉刷新...
|
||||
|
onRefreshList: function () { |
||||
|
this.setData({ |
||||
|
orderList: [], |
||||
|
['form.pageNum']: 1, |
||||
|
loading: true, |
||||
|
finished: false |
||||
|
}) |
||||
|
this.fetchPapersList() |
||||
|
}, |
||||
|
// 获取特价列表
|
||||
|
fetchPapersList: function () { |
||||
|
if (this.data.requesting || this.data.finished) { |
||||
|
return |
||||
|
} |
||||
|
if (this.data.loading) { |
||||
|
this.data.requesting = true |
||||
|
} else { |
||||
|
this.setData({ requesting: true }) |
||||
|
} |
||||
|
getFactoryPrice(this.data.form).then(result => { |
||||
|
if (result.data.records.length) { |
||||
|
var respList = result.data.records |
||||
|
let nowList = `orderList[${this.data.orderList.length}]` |
||||
|
var num = result.data.current |
||||
|
var finished = result.data.current >= result.data.pages |
||||
|
if (this.data.form.pageNum == 1) { |
||||
|
this.setData({ |
||||
|
[nowList]: respList, |
||||
|
total: result.data.total, |
||||
|
['form.pageNum']: (num + 1), |
||||
|
top: 0, |
||||
|
finished, |
||||
|
requesting: false, |
||||
|
loading: false |
||||
|
}) |
||||
|
} else { |
||||
|
this.setData({ |
||||
|
[nowList]: respList, |
||||
|
total: result.data.total, |
||||
|
['form.pageNum']: (num + 1), |
||||
|
finished, |
||||
|
requesting: false, |
||||
|
loading: false |
||||
|
}) |
||||
|
} |
||||
|
} else { |
||||
|
this.setData({ |
||||
|
finished: true, |
||||
|
requesting: false, |
||||
|
loading: false, |
||||
|
pageNum: 1 |
||||
|
}) |
||||
|
} |
||||
|
}).catch(err => { |
||||
|
//异常回调
|
||||
|
this.setData({ |
||||
|
requesting: false, |
||||
|
finished: true, |
||||
|
loading: false, |
||||
|
}) |
||||
|
}) |
||||
|
} |
||||
|
|
||||
|
}) |
||||
@ -0,0 +1,14 @@ |
|||||
|
{ |
||||
|
"usingComponents": { |
||||
|
"wux-skeleton": "/components/skeleton/index", |
||||
|
"wux-skeleton-avatar": "/components/skeleton-avatar/index", |
||||
|
"wux-skeleton-paragraph": "/components/skeleton-paragraph/index", |
||||
|
"wux-button": "/components/button/index", |
||||
|
"refresh-view": "/components/refresher/index", |
||||
|
"wux-tabi": "/components/tabi/index", |
||||
|
"wux-image": "/components/image/index", |
||||
|
"wux-divider": "/components/divider/index", |
||||
|
"agent-item": "/pages/agent/agent-item/index", |
||||
|
"wux-dialog": "/components/dialog/index" |
||||
|
} |
||||
|
} |
||||
@ -0,0 +1,32 @@ |
|||||
|
<!--pages/agent/index/index.wxml--> |
||||
|
<wxs module="formate" src="../../../pages/formate.wxs"></wxs> |
||||
|
<cu-custom bgColor="bg-white" isBack="{{true}}"> |
||||
|
<view slot="content">代卖活动</view> |
||||
|
</cu-custom> |
||||
|
|
||||
|
<refresh-view bind:refresh="onRefreshList" height="{{height}}" triggered="{{requesting}}" scrollTop="{{top}}" bind:scrolltolower="fetchPapersList"> |
||||
|
<view class="bg-white list-empty" style="height:{{height}}rpx" wx:if="{{!orderList.length}}"> |
||||
|
<view class="load-spinner text-gray" style="margin-bottom:24px" wx:if="{{loading}}" /> |
||||
|
<image class="img-empty" src="/assets/image/list_empty.png" wx:else></image> |
||||
|
<view class="text-empty">{{loading? '正在加载' : '暂无数据'}}</view> |
||||
|
</view> |
||||
|
<view wx:else> |
||||
|
<view wx:for-item="pageItem" wx:for-index="pageIndex" wx:for="{{orderList}}" wx:key="pageIndex"> |
||||
|
<view wx:for="{{pageItem}}" wx:key="index"> |
||||
|
<view style="height:16rpx" wx:if="{{pageIndex != 0 || index != 0 }}"></view> |
||||
|
<agent-item item="{{item}}"></agent-item> |
||||
|
</view> |
||||
|
</view> |
||||
|
<!--加载更多的UI--> |
||||
|
<view wx:if="{{form.pageNum>1}}" style="padding:20rpx"> |
||||
|
<wux-divider> |
||||
|
<view class="loadmore"> |
||||
|
<text class="icon--refresher" wx:if="{{!finished}}"></text> |
||||
|
<text class="text-sm" style="margin-left:8rpx">{{finished?'到底啦~':'加载中...'}}</text> |
||||
|
</view> |
||||
|
</wux-divider> |
||||
|
</view> |
||||
|
</view> |
||||
|
</refresh-view> |
||||
|
|
||||
|
<wux-dialog id="wux-dialog" /> |
||||
@ -0,0 +1,63 @@ |
|||||
|
/* pages/agent/index/index.wxss */ |
||||
|
.bj{ |
||||
|
height: 1300rpx; |
||||
|
background-color: white; |
||||
|
} |
||||
|
.bgImgView { |
||||
|
width: 100%; |
||||
|
height: 548rpx; |
||||
|
padding: 160rpx 186rpx 94rpx 186rpx; |
||||
|
background-color: white; |
||||
|
} |
||||
|
|
||||
|
.imgsj { |
||||
|
height: 294rpx; |
||||
|
width: 378rpx; |
||||
|
} |
||||
|
|
||||
|
.midText { |
||||
|
width: 100%; |
||||
|
height: 67rpx; |
||||
|
padding: 0rpx 279rpx 0rpx 279rpx; |
||||
|
} |
||||
|
|
||||
|
.midText2 { |
||||
|
font-size: 48rpx; |
||||
|
color: #000000; |
||||
|
letter-spacing: 0; |
||||
|
text-align: left; |
||||
|
} |
||||
|
|
||||
|
.midText3 { |
||||
|
width: 100%; |
||||
|
height: 45px; |
||||
|
padding: 0rpx 199rpx 0rpx 199rpx; |
||||
|
margin-top: 12rpx; |
||||
|
} |
||||
|
|
||||
|
.midText4 { |
||||
|
font-size: 32rpx; |
||||
|
color: rgba(0, 0, 0, 0.75); |
||||
|
letter-spacing: 0; |
||||
|
text-align: left; |
||||
|
} |
||||
|
.bg-blue{ |
||||
|
color: #FFFFFF; |
||||
|
background-color: #008AFF; |
||||
|
} |
||||
|
|
||||
|
.offer-btn { |
||||
|
width: 480rpx; |
||||
|
height: 88rpx; |
||||
|
background: linear-gradient(312deg, rgba(38, 125, 214, 1) 0%, rgba(0, 138, 255, 1) 100%); |
||||
|
box-shadow: 0px 10px 13px -8px rgba(35, 126, 217, 0.53); |
||||
|
border-radius: 10rpx; |
||||
|
color: white; |
||||
|
font-size: 32rpx; |
||||
|
margin-left: 32rpx; |
||||
|
} |
||||
|
.bottomBtn{ |
||||
|
width: 100%; |
||||
|
height: 88rpx; |
||||
|
padding:0rpx 135rpx 0rpx 135rpx; |
||||
|
} |
||||
@ -0,0 +1,151 @@ |
|||||
|
// pages/agent/index/index.js
|
||||
|
import { getFactoryPrice, getFactoryCity } from "../../api/ztb" |
||||
|
const app = getApp() |
||||
|
|
||||
|
Component({ |
||||
|
options: { |
||||
|
addGlobalClass: true, |
||||
|
multipleSlots: true |
||||
|
}, |
||||
|
/** |
||||
|
* 页面的初始数据 |
||||
|
*/ |
||||
|
data: { |
||||
|
height: app.globalData.fragmentHeight - 90, |
||||
|
CustomBar: app.globalData.CustomBar, |
||||
|
kg: app.globalData.kg, |
||||
|
loading: true, |
||||
|
requesting: false, |
||||
|
finished: false, |
||||
|
tabList: [], |
||||
|
tabIndex: 0, |
||||
|
cateList: [], |
||||
|
scrolled: false, |
||||
|
top: 0, |
||||
|
orderList: [], |
||||
|
form: { |
||||
|
cityId: '', |
||||
|
enableSalesAgent: 1, |
||||
|
pageNum: 1, |
||||
|
listType: 0 |
||||
|
} |
||||
|
}, |
||||
|
lifetimes: { |
||||
|
// 生命周期函数,可以为函数,或一个在methods段中定义的方法名
|
||||
|
attached: function () { |
||||
|
this.setData({ height: app.globalData.fragmentHeight - 90, kg: app.globalData.kg }) |
||||
|
this.fetchRegionList() |
||||
|
this.fetchPapersList() |
||||
|
} |
||||
|
}, |
||||
|
methods: { |
||||
|
onEvent: function (message) { |
||||
|
if (message.what == 1100 || message.what == 1101) { |
||||
|
this.data.form = { |
||||
|
cityId: '', |
||||
|
enableSalesAgent: 1, |
||||
|
pageNum: 1, |
||||
|
listType: 1 |
||||
|
} |
||||
|
this.setData({ bidType: 2 }) |
||||
|
this.data.orderList = [] |
||||
|
this.fetchPapersList() |
||||
|
} |
||||
|
}, |
||||
|
onRestart: function(){ |
||||
|
|
||||
|
}, |
||||
|
fetchRegionList: function () { |
||||
|
getFactoryCity().then(result => { |
||||
|
//成功回调
|
||||
|
this.data.cateList = [{ |
||||
|
cityId: '', |
||||
|
cityName: '全部' |
||||
|
}].concat(result.data) |
||||
|
for (let index = 0; index < this.data.cateList.length; index++) { |
||||
|
this.data.tabList.push(this.data.cateList[index].cityName) |
||||
|
} |
||||
|
this.setData({ |
||||
|
tabList: this.data.tabList, |
||||
|
scrolled: this.data.cateList.length >= 5 |
||||
|
}) |
||||
|
}) |
||||
|
}, |
||||
|
onTabChange: function ({ detail }) { |
||||
|
if (this.data.tabIndex == Number(detail.index)) { |
||||
|
return |
||||
|
} |
||||
|
this.data.tabIndex = Number(detail.index) |
||||
|
this.data.form.cityId = this.data.cateList[this.data.tabIndex].cityId |
||||
|
this.onRefreshList() |
||||
|
}, |
||||
|
// 下拉刷新...
|
||||
|
onRefreshList: function () { |
||||
|
this.setData({ |
||||
|
orderList: [], |
||||
|
tabIndex: this.data.tabIndex, |
||||
|
['form.pageNum']: 1, |
||||
|
loading: true, |
||||
|
finished: false |
||||
|
}) |
||||
|
this.fetchPapersList() |
||||
|
}, |
||||
|
// 获取特价列表
|
||||
|
fetchPapersList: function () { |
||||
|
if (this.data.requesting || this.data.finished) { |
||||
|
return |
||||
|
} |
||||
|
if (this.data.loading) { |
||||
|
this.data.requesting = true |
||||
|
} else { |
||||
|
this.setData({ requesting: true }) |
||||
|
} |
||||
|
getFactoryPrice(this.data.form).then(result => { |
||||
|
if (result.data.records.length) { |
||||
|
var respList = result.data.records |
||||
|
let nowList = `orderList[${this.data.orderList.length}]` |
||||
|
var num = result.data.current |
||||
|
var finished = result.data.current >= result.data.pages |
||||
|
if (this.data.form.pageNum == 1) { |
||||
|
this.setData({ |
||||
|
[nowList]: respList, |
||||
|
total: result.data.total, |
||||
|
['form.pageNum']: (num + 1), |
||||
|
top: 0, |
||||
|
finished, |
||||
|
requesting: false, |
||||
|
loading: false |
||||
|
}) |
||||
|
} else { |
||||
|
this.setData({ |
||||
|
[nowList]: respList, |
||||
|
total: result.data.total, |
||||
|
['form.pageNum']: (num + 1), |
||||
|
finished, |
||||
|
requesting: false, |
||||
|
loading: false |
||||
|
}) |
||||
|
} |
||||
|
} else { |
||||
|
this.setData({ |
||||
|
finished: true, |
||||
|
requesting: false, |
||||
|
loading: false, |
||||
|
pageNum: 1 |
||||
|
}) |
||||
|
} |
||||
|
}).catch(err => { |
||||
|
//异常回调
|
||||
|
this.setData({ |
||||
|
requesting: false, |
||||
|
finished: true, |
||||
|
loading: false, |
||||
|
}) |
||||
|
}) |
||||
|
}, |
||||
|
goattentionIndex: function () { |
||||
|
wx.navigateTo({ url: '/pages/home/attentionPaperList/index' }) |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
}) |
||||
@ -0,0 +1,14 @@ |
|||||
|
{ |
||||
|
"component": true, |
||||
|
"usingComponents": { |
||||
|
"wux-skeleton": "/components/skeleton/index", |
||||
|
"wux-skeleton-avatar": "/components/skeleton-avatar/index", |
||||
|
"wux-skeleton-paragraph": "/components/skeleton-paragraph/index", |
||||
|
"wux-button": "/components/button/index", |
||||
|
"refresh-view": "/components/refresher/index", |
||||
|
"wux-tabi": "/components/tabi/index", |
||||
|
"wux-image": "/components/image/index", |
||||
|
"wux-divider": "/components/divider/index", |
||||
|
"agent-item": "/pages/agent/agent-item/index" |
||||
|
} |
||||
|
} |
||||
@ -0,0 +1,32 @@ |
|||||
|
<!--pages/agent/index/index.wxml--> |
||||
|
<wxs module="formate" src="../../../pages/formate.wxs"></wxs> |
||||
|
|
||||
|
<view class="nav bg-white fixed" style="top:{{CustomBar}}px;height:90rpx;" wx:if="{{tabList.length}}"> |
||||
|
<wux-tabi scroll="{{scrolled}}" tab-data="{{tabList}}" tab-index="{{tabIndex}}" bind:change="onTabChange"></wux-tabi> |
||||
|
</view> |
||||
|
<view class="bg-white" style="height:90rpx;width:100%" wx:if="{{tabList.length}}"></view> |
||||
|
|
||||
|
<refresh-view bind:refresh="onRefreshList" height="{{height}}" triggered="{{requesting}}" scrollTop="{{top}}" bind:scrolltolower="fetchPapersList"> |
||||
|
<view class="bg-white list-empty" style="height:{{height}}rpx" wx:if="{{!orderList.length}}"> |
||||
|
<view class="load-spinner text-gray" style="margin-bottom:24px" wx:if="{{loading}}" /> |
||||
|
<image class="img-empty" src="/assets/image/list_empty.png" wx:else></image> |
||||
|
<view class="text-empty">{{loading? '正在加载' : '暂无数据'}}</view> |
||||
|
</view> |
||||
|
<view wx:else> |
||||
|
<view wx:for-item="pageItem" wx:for-index="pageIndex" wx:for="{{orderList}}" wx:key="pageIndex"> |
||||
|
<view wx:for="{{pageItem}}" wx:key="index"> |
||||
|
<view style="height:16rpx" wx:if="{{pageIndex != 0 || index != 0 }}"></view> |
||||
|
<agent-item item="{{item}}"></agent-item> |
||||
|
</view> |
||||
|
</view> |
||||
|
<!--加载更多的UI--> |
||||
|
<view wx:if="{{form.pageNum>1}}" style="padding:20rpx"> |
||||
|
<wux-divider> |
||||
|
<view class="loadmore"> |
||||
|
<text class="icon--refresher" wx:if="{{!finished}}"></text> |
||||
|
<text class="text-sm" style="margin-left:8rpx">{{finished?'到底啦~':'加载中...'}}</text> |
||||
|
</view> |
||||
|
</wux-divider> |
||||
|
</view> |
||||
|
</view> |
||||
|
</refresh-view> |
||||
@ -0,0 +1 @@ |
|||||
|
/* pages/agent/index/index.wxss */ |
||||
@ -0,0 +1,141 @@ |
|||||
|
// pages/agent/index/index.js
|
||||
|
import { getFactoryPrice, getBaseInfo, updateUserInfo } from "../../api/ztb" |
||||
|
const event = require('../../../utils/event') |
||||
|
const app = getApp() |
||||
|
|
||||
|
Component({ |
||||
|
options: { |
||||
|
addGlobalClass: true, |
||||
|
multipleSlots: true |
||||
|
}, |
||||
|
/** |
||||
|
* 页面的初始数据 |
||||
|
*/ |
||||
|
data: { |
||||
|
height: app.globalData.fragmentHeight - 90, |
||||
|
CustomBar: app.globalData.CustomBar, |
||||
|
kg: app.globalData.kg, |
||||
|
loading: true, |
||||
|
requesting: false, |
||||
|
finished: false, |
||||
|
tabList: [], |
||||
|
tabIndex: 0, |
||||
|
cateList: [], |
||||
|
scrolled: false, |
||||
|
top: 0, |
||||
|
orderList: [], |
||||
|
form: { |
||||
|
cityId: '', |
||||
|
enableSalesAgent: 1, |
||||
|
pageNum: 1, |
||||
|
listType: 1 |
||||
|
} |
||||
|
}, |
||||
|
lifetimes: { |
||||
|
// 生命周期函数,可以为函数,或一个在methods段中定义的方法名
|
||||
|
attached: function () { |
||||
|
this.setData({ height: app.globalData.fragmentHeight, kg: app.globalData.kg }) |
||||
|
this.fetchPapersList() |
||||
|
event.on('factoryDetails', this, this.onEvent) |
||||
|
event.on('attentionPaperList', this, this.onEvent) |
||||
|
}, |
||||
|
detached: function () { |
||||
|
event.remove('factoryDetails', this) |
||||
|
event.remove('attentionPaperList', this) |
||||
|
} |
||||
|
}, |
||||
|
methods: { |
||||
|
onEvent: function (message) { |
||||
|
if (message.what == 1100 || message.what == 1101) { |
||||
|
this.onRefreshList() |
||||
|
} |
||||
|
}, |
||||
|
onRestart: function () { |
||||
|
getBaseInfo().then(result => { |
||||
|
if (result.data.isSetProxyTag == false) { |
||||
|
updateUserInfo({ isSetProxyTag: true }).then(result => {}) |
||||
|
this.wuxDialog = this.wuxDialog || this.selectComponent('#wux-dialog') |
||||
|
this.wuxDialog.open({ |
||||
|
resetOnClose: true, |
||||
|
title: '温馨提示', |
||||
|
content: '是否选择关注您常卖的纸厂?', |
||||
|
buttons: [{ |
||||
|
text: '取消' |
||||
|
}, { |
||||
|
text: '确定', |
||||
|
type: 'primary', |
||||
|
onTap(e) { |
||||
|
wx.navigateTo({ |
||||
|
url: '/pages/home/attentionPaperList/index' |
||||
|
}) |
||||
|
} |
||||
|
}] |
||||
|
}) |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
// 下拉刷新...
|
||||
|
onRefreshList: function () { |
||||
|
this.setData({ |
||||
|
orderList: [], |
||||
|
['form.pageNum']: 1, |
||||
|
loading: true, |
||||
|
finished: false |
||||
|
}) |
||||
|
this.fetchPapersList() |
||||
|
}, |
||||
|
// 获取特价列表
|
||||
|
fetchPapersList: function () { |
||||
|
if (this.data.requesting || this.data.finished) { |
||||
|
return |
||||
|
} |
||||
|
if (this.data.loading) { |
||||
|
this.data.requesting = true |
||||
|
} else { |
||||
|
this.setData({ requesting: true }) |
||||
|
} |
||||
|
getFactoryPrice(this.data.form).then(result => { |
||||
|
if (result.data.records.length) { |
||||
|
var respList = result.data.records |
||||
|
let nowList = `orderList[${this.data.orderList.length}]` |
||||
|
var num = result.data.current |
||||
|
var finished = result.data.current >= result.data.pages |
||||
|
if (this.data.form.pageNum == 1) { |
||||
|
this.setData({ |
||||
|
[nowList]: respList, |
||||
|
total: result.data.total, |
||||
|
['form.pageNum']: (num + 1), |
||||
|
top: 0, |
||||
|
finished, |
||||
|
requesting: false, |
||||
|
loading: false |
||||
|
}) |
||||
|
} else { |
||||
|
this.setData({ |
||||
|
[nowList]: respList, |
||||
|
total: result.data.total, |
||||
|
['form.pageNum']: (num + 1), |
||||
|
finished, |
||||
|
requesting: false, |
||||
|
loading: false |
||||
|
}) |
||||
|
} |
||||
|
} else { |
||||
|
this.setData({ |
||||
|
finished: true, |
||||
|
requesting: false, |
||||
|
loading: false, |
||||
|
pageNum: 1 |
||||
|
}) |
||||
|
} |
||||
|
}).catch(err => { |
||||
|
//异常回调
|
||||
|
this.setData({ requesting: false, finished: true, loading: false }) |
||||
|
}) |
||||
|
}, |
||||
|
goattentionIndex: function () { |
||||
|
wx.navigateTo({ url: '/pages/home/attentionPaperList/index' }) |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
}) |
||||
@ -0,0 +1,15 @@ |
|||||
|
{ |
||||
|
"component": true, |
||||
|
"usingComponents": { |
||||
|
"wux-skeleton": "/components/skeleton/index", |
||||
|
"wux-skeleton-avatar": "/components/skeleton-avatar/index", |
||||
|
"wux-skeleton-paragraph": "/components/skeleton-paragraph/index", |
||||
|
"wux-button": "/components/button/index", |
||||
|
"refresh-view": "/components/refresher/index", |
||||
|
"wux-tabi": "/components/tabi/index", |
||||
|
"wux-image": "/components/image/index", |
||||
|
"wux-divider": "/components/divider/index", |
||||
|
"agent-item": "/pages/agent/agent-item/index", |
||||
|
"wux-dialog": "/components/dialog/index" |
||||
|
} |
||||
|
} |
||||
@ -0,0 +1,41 @@ |
|||||
|
<!--pages/agent/index/index.wxml--> |
||||
|
<wxs module="formate" src="../../../pages/formate.wxs"></wxs> |
||||
|
<refresh-view bind:refresh="onRefreshList" height="{{height}}" triggered="{{requesting}}" scrollTop="{{top}}" bind:scrolltolower="fetchPapersList"> |
||||
|
<view class="bg-white list-empty" style="height:{{height}}rpx" wx:if="{{!orderList.length && loading}}"> |
||||
|
<view class="load-spinner text-gray" style="margin-bottom:24px" /> |
||||
|
<view class="text-empty">正在加载</view> |
||||
|
</view> |
||||
|
<view class="bg-white" style="height:{{height}}rpx" wx:elif="{{!orderList.length}}"> |
||||
|
<view class="bgImgView"> |
||||
|
<image class="imgsj" src="/assets/image/noattention.png" /> |
||||
|
</view> |
||||
|
<view class="midText"> |
||||
|
<text class="midText2">暂无关注</text> |
||||
|
</view> |
||||
|
<view class="midText3"> |
||||
|
<text class="midText4">可前往纸厂列表添加关注</text> |
||||
|
</view> |
||||
|
<view class="bottomBtn"> |
||||
|
<wux-button block type="positive" data-page="{{pageIndex}}" data-index="{{index}}" bind:click="goattentionIndex">添加关注</wux-button> |
||||
|
</view> |
||||
|
</view> |
||||
|
<view wx:else> |
||||
|
<view wx:for-item="pageItem" wx:for-index="pageIndex" wx:for="{{orderList}}" wx:key="pageIndex"> |
||||
|
<view wx:for="{{pageItem}}" wx:key="index"> |
||||
|
<view style="height:16rpx" wx:if="{{pageIndex != 0 || index != 0 }}"></view> |
||||
|
<agent-item item="{{item}}"></agent-item> |
||||
|
</view> |
||||
|
</view> |
||||
|
<!-- 加载更多的UI --> |
||||
|
<view wx:if="{{form.pageNum>1}}" style="padding:20rpx"> |
||||
|
<wux-divider> |
||||
|
<view class="loadmore"> |
||||
|
<text class="icon--refresher" wx:if="{{!finished}}"></text> |
||||
|
<text class="text-sm" style="margin-left:8rpx">{{finished?'到底啦~':'加载中...'}}</text> |
||||
|
</view> |
||||
|
</wux-divider> |
||||
|
</view> |
||||
|
</view> |
||||
|
</refresh-view> |
||||
|
|
||||
|
<wux-dialog id="wux-dialog" /> |
||||
@ -0,0 +1,60 @@ |
|||||
|
/* pages/agent/index/index.wxss */ |
||||
|
|
||||
|
.bgImgView { |
||||
|
width: 100%; |
||||
|
height: 548rpx; |
||||
|
padding: 160rpx 186rpx 94rpx 186rpx; |
||||
|
background-color: white; |
||||
|
} |
||||
|
|
||||
|
.imgsj { |
||||
|
height: 294rpx; |
||||
|
width: 378rpx; |
||||
|
} |
||||
|
|
||||
|
.midText { |
||||
|
width: 100%; |
||||
|
height: 67rpx; |
||||
|
padding: 0rpx 279rpx 0rpx 279rpx; |
||||
|
} |
||||
|
|
||||
|
.midText2 { |
||||
|
font-size: 48rpx; |
||||
|
color: #000000; |
||||
|
letter-spacing: 0; |
||||
|
text-align: left; |
||||
|
} |
||||
|
|
||||
|
.midText3 { |
||||
|
width: 100%; |
||||
|
height: 45px; |
||||
|
padding: 0rpx 199rpx 0rpx 199rpx; |
||||
|
margin-top: 12rpx; |
||||
|
} |
||||
|
|
||||
|
.midText4 { |
||||
|
font-size: 32rpx; |
||||
|
color: rgba(0, 0, 0, 0.75); |
||||
|
letter-spacing: 0; |
||||
|
text-align: left; |
||||
|
} |
||||
|
.bg-blue{ |
||||
|
color: #FFFFFF; |
||||
|
background-color: #008AFF; |
||||
|
} |
||||
|
|
||||
|
.offer-btn { |
||||
|
width: 480rpx; |
||||
|
height: 88rpx; |
||||
|
background: linear-gradient(312deg, rgba(38, 125, 214, 1) 0%, rgba(0, 138, 255, 1) 100%); |
||||
|
box-shadow: 0px 10px 13px -8px rgba(35, 126, 217, 0.53); |
||||
|
border-radius: 10rpx; |
||||
|
color: white; |
||||
|
font-size: 32rpx; |
||||
|
margin-left: 32rpx; |
||||
|
} |
||||
|
.bottomBtn{ |
||||
|
width: 100%; |
||||
|
height: 88rpx; |
||||
|
padding:0rpx 135rpx 0rpx 135rpx; |
||||
|
} |
||||
@ -1,14 +1,6 @@ |
|||||
{ |
{ |
||||
"usingComponents": { |
"usingComponents": { |
||||
"wux-skeleton": "/components/skeleton/index", |
|
||||
"wux-skeleton-avatar": "/components/skeleton-avatar/index", |
|
||||
"wux-skeleton-paragraph": "/components/skeleton-paragraph/index", |
|
||||
"wux-button": "/components/button/index", |
|
||||
"refresh-view": "/components/refresher/index", |
|
||||
"wux-tabi": "/components/tabi/index", |
|
||||
"wux-image": "/components/image/index", |
|
||||
"wux-divider": "/components/divider/index", |
|
||||
"agent-item": "/pages/agent/agent-item/index", |
|
||||
"wux-dialog": "/components/dialog/index" |
|
||||
|
"focus": "/pages/agent/focus-fragment/index", |
||||
|
"factory": "/pages/agent/factory-fragment/index" |
||||
} |
} |
||||
} |
} |
||||
@ -1,124 +1,28 @@ |
|||||
<!--pages/agent/index/index.wxml--> |
<!--pages/agent/index/index.wxml--> |
||||
<wxs module="formate" src="../../../pages/formate.wxs"></wxs> |
<wxs module="formate" src="../../../pages/formate.wxs"></wxs> |
||||
<cu-custom bgColor="bg-white" isBack="{{true}}"> |
|
||||
<view slot="content">纸厂代卖</view> |
|
||||
</cu-custom> |
|
||||
|
|
||||
<view class="nav bg-white fixed" style="top:{{CustomBar}}px;height:{{bidTypeHight}}rpx;" wx:if="{{tabList.length}}"> |
|
||||
<view class="flex bg-white" style="height:80rpx;padding:6rpx 6rpx 0rpx 6rpx;border-bottom: 2rpx solid #eee"> |
|
||||
<view data-index="2" class="flex flex-center flex-column" style="flex:1;" bindtap="onTabChangeTop"> |
|
||||
<view class="text-bold" style="font-size:24rpx;color:{{bidType == 2 ? '#008AFF' : '#333'}}">关注</view> |
|
||||
</view> |
|
||||
<view data-index="1" class="flex flex-center flex-column" style="flex:1;" bindtap="onTabChangeTop"> |
|
||||
<view class="text-bold" style="font-size:24rpx;color:{{bidType == 1 ? '#008AFF' : '#333'}}">全部</view> |
|
||||
|
<view class="cu-custom bg-white" style="height:{{CustomBar}}px;z-index: 99;"> |
||||
|
<view class="cu-bar fixed {{bgColor}}" |
||||
|
style="height:{{CustomBar}}px;padding-top:{{StatusBar}}rpx;{{shadow?'box-shadow: none': ''}};{{shadow?'border-bottom: none': ''}}"> |
||||
|
<view class="action" bindtap="backspace"> |
||||
|
<text class="weui_goback"></text> |
||||
|
</view> |
||||
|
<view class="flex" style="top:{{StatusBar}}rpx;color:black;font-size:36rpx;width:340rpx;height:80rpx"> |
||||
|
<view data-index="0" class="flex flex-center flex-column" style="flex:1;" catchtap="onTabChangeTop"> |
||||
|
<view class="text-sg text-bold" style="color:{{pageIndex == 0 ? '#008AFF' : '#333'}}">关注</view> |
||||
|
</view> |
||||
|
<view data-index="1" class="flex flex-center flex-column" style="flex:1;" catchtap="onTabChangeTop"> |
||||
|
<view class="text-sg text-bold" style="color:{{pageIndex == 1 ? '#008AFF' : '#333'}}">全部</view> |
||||
|
</view> |
||||
</view> |
</view> |
||||
</view> |
</view> |
||||
<wux-tabi wx:if="{{bidType == 1}}" scroll="{{scrolled}}" tab-data="{{tabList}}" tab-index="{{tabIndex}}" bind:change="onTabChange"></wux-tabi> |
|
||||
</view> |
</view> |
||||
<view class="bg-white" style="height:{{bidTypeHight}}rpx;width:100%"></view> |
|
||||
|
|
||||
<refresh-view wx:if="{{bidType == 1}}" bind:refresh="onRefreshList" height="{{height}}" triggered="{{requesting}}" scrollTop="{{top}}" bind:scrolltolower="fetchPapersList"> |
|
||||
<view class="bg-white list-empty" style="height:{{height}}rpx" wx:if="{{!orderList.length}}"> |
|
||||
<view class="load-spinner text-gray" style="margin-bottom:24px" wx:if="{{loading}}" /> |
|
||||
<image class="img-empty" src="/assets/image/list_empty.png" wx:else></image> |
|
||||
<view class="text-empty">{{loading? '正在加载' : '暂无数据'}}</view> |
|
||||
</view> |
|
||||
<view wx:else> |
|
||||
<view wx:for-item="pageItem" wx:for-index="pageIndex" wx:for="{{orderList}}" wx:key="pageIndex"> |
|
||||
<view wx:for="{{pageItem}}" wx:key="index"> |
|
||||
<view style="height:16rpx" wx:if="{{pageIndex != 0 || index != 0 }}"></view> |
|
||||
<!-- <wux-divider show-text="{{ false }}" wx:if="{{pageIndex != 0 || index != 0 }}"></wux-divider> --> |
|
||||
<agent-item item="{{item}}"></agent-item> |
|
||||
<!-- <view class="flex flex-justify item-content" data-page="{{pageIndex}}" data-index="{{index}}" bindtap="lookItem"> |
|
||||
<wux-image width="{{50}}" height="{{50}}" shape="rounded" lazyLoad="true" src="{{item.logoImg}}" mode="aspectFill"> |
|
||||
<image class="image-load" slot="loading" src="/assets/image/def_image.png"></image> |
|
||||
<image class="image-load" slot="error" src="/assets/image/def_image.png"></image> |
|
||||
<image class="image-load" slot="empty" src="/assets/image/def_image.png"></image> |
|
||||
</wux-image> |
|
||||
<view style="margin-left:24rpx;flex:1"> |
|
||||
<view class="flex flex-justify"> |
|
||||
<view class="text-lg text-cut" style="max-width:320rpx">{{item.name}}</view> |
|
||||
<view class="flex flex-center" data-page="{{pageIndex}}" data-index="{{index}}" catchtap="unflodItem" wx:if="{{item.paperCategoryList.length > 3}}"> |
|
||||
<text class="text-blue text-df">{{item.fold ? '点击收起' : '查看全部' }}({{item.paperCategoryList.length}})</text> |
|
||||
<text class="cuIcon-{{item.fold ? 'fold' : 'unfold'}} text-blue" style="font-size:16px;margin-left:4rpx;padding-top:8rpx"></text> |
|
||||
</view> |
|
||||
</view> |
|
||||
<view class="text-sm" style="margin-top:8rpx">{{item.locProvinceName + item.locCityName + item.locDistrictName}}</view> |
|
||||
</view> |
|
||||
</view> --> |
|
||||
<!-- <view class="bg-white" style="padding:0rpx 32rpx 10rpx 32rpx"> |
|
||||
<view class="flex" wx:for-item="cateItem" wx:for-index="ck" wx:for="{{item.paperCategoryList}}" wx:key="ck" |
|
||||
wx:if="{{item.fold || ck < 3}}" style="margin-bottom: 20rpx"> |
|
||||
<view class="flex flex-justify item-cate {{item.cateIndex == ck ? 'cate-tag' : ''}}" data-page="{{pageIndex}}" data-index="{{index}}" data-ck="{{ck}}" catchtap="checkTag"> |
|
||||
<text class="text-sg">{{cateItem.categoryName}}</text> |
|
||||
<view class="flex flex-center"> |
|
||||
<text class="text-sg">{{formate.formatePrice(cateItem.unitPrice)}}元/吨</text> |
|
||||
<view class="flex flex-center" style="margin-left:40rpx" wx:if="{{cateItem.floatingPrice > 0}}"> |
|
||||
<text class="cuIcon-refresharrow text-red transform" style="font-size:28rpx;padding-top:2rpx;"></text> |
|
||||
<text class="text-red">{{formate.formatePrice(cateItem.floatingPrice)}}</text> |
|
||||
</view> |
|
||||
<view class="flex flex-center" style="margin-left:40rpx" wx:elif="{{cateItem.floatingPrice < 0}}"> |
|
||||
<text class="cuIcon-refresharrow text-green" style="font-size:28rpx;padding-top:2rpx;"></text> |
|
||||
<text class="text-green">{{formate.formatePrice(-cateItem.floatingPrice)}}</text> |
|
||||
</view> |
|
||||
<view class="flex flex-center" style="margin-left:40rpx" wx:else> |
|
||||
<text class="text-xl text-gray">-</text> |
|
||||
<text class="text-xl text-gray" style="margin-left:4rpx">-</text> |
|
||||
</view> |
|
||||
</view> |
|
||||
</view> |
|
||||
</view> |
|
||||
<view style="padding: 2rpx 10% 0rpx 10%;" wx:if="{{item.paperCategoryList.length > 0}}"> |
|
||||
<wux-button block type="positive" size="sale" data-page="{{pageIndex}}" data-index="{{index}}" bind:click="saleGood">我要卖货</wux-button> |
|
||||
</view> |
|
||||
</view> --> |
|
||||
</view> |
|
||||
</view> |
|
||||
<!--加载更多的UI--> |
|
||||
<view wx:if="{{form.pageNum>1}}" style="padding:20rpx"> |
|
||||
<wux-divider> |
|
||||
<view class="loadmore"> |
|
||||
<text class="icon--refresher" wx:if="{{!finished}}"></text> |
|
||||
<text class="text-sm" style="margin-left:8rpx">{{finished?'到底啦~':'加载中...'}}</text> |
|
||||
</view> |
|
||||
</wux-divider> |
|
||||
</view> |
|
||||
</view> |
|
||||
</refresh-view> |
|
||||
|
|
||||
<refresh-view wx:if="{{bidType == 2}}" bind:refresh="onRefreshList" height="{{height}}" triggered="{{requesting}}" scrollTop="{{top}}" bind:scrolltolower="fetchPapersList"> |
|
||||
<view class="bj" wx:if="{{!orderList.length}}"> |
|
||||
<view class="bgImgView"> |
|
||||
<image class="imgsj" src="/assets/image/noattention.png" /> |
|
||||
</view> |
|
||||
<view class="midText"> |
|
||||
<text class="midText2">暂无关注</text> |
|
||||
</view> |
|
||||
<view class="midText3"> |
|
||||
<text class="midText4">可前往纸厂列表添加关注</text> |
|
||||
</view> |
|
||||
<view class="bottomBtn"> |
|
||||
<wux-button block type="positive" data-page="{{pageIndex}}" data-index="{{index}}" bind:click="goattentionIndex">添加关注</wux-button> |
|
||||
</view> |
|
||||
</view> |
|
||||
<view wx:else> |
|
||||
<view wx:for-item="pageItem" wx:for-index="pageIndex" wx:for="{{orderList}}" wx:key="pageIndex"> |
|
||||
<view wx:for="{{pageItem}}" wx:key="index"> |
|
||||
<view style="height:16rpx" wx:if="{{pageIndex != 0 || index != 0 }}"></view> |
|
||||
|
|
||||
<agent-item item="{{item}}"></agent-item> |
|
||||
</view> |
|
||||
</view> |
|
||||
加载更多的UI |
|
||||
<view wx:if="{{form.pageNum>1}}" style="padding:20rpx"> |
|
||||
<wux-divider> |
|
||||
<view class="loadmore"> |
|
||||
<text class="icon--refresher" wx:if="{{!finished}}"></text> |
|
||||
<text class="text-sm" style="margin-left:8rpx">{{finished?'到底啦~':'加载中...'}}</text> |
|
||||
</view> |
|
||||
</wux-divider> |
|
||||
</view> |
|
||||
</view> |
|
||||
</refresh-view> |
|
||||
|
|
||||
<wux-dialog id="wux-dialog" /> |
|
||||
|
<swiper current="{{pageIndex}}" duration="0" style="height:{{height}}rpx"> |
||||
|
<swiper-item catchtouchmove="stopTouchMove"> |
||||
|
<focus id="{{TabList[0].value}}" /> |
||||
|
</swiper-item> |
||||
|
<swiper-item catchtouchmove="stopTouchMove"> |
||||
|
<factory id="{{TabList[1].value}}" /> |
||||
|
</swiper-item> |
||||
|
</swiper> |
||||
Write
Preview
Loading…
Cancel
Save