34 changed files with 1248 additions and 138 deletions
Split View
Diff Options
-
2app.json
-
BINassets/image/noattention.png
-
52pages/agent/factory/index.js
-
2pages/agent/factory/index.wxml
-
123pages/agent/index/index.js
-
3pages/agent/index/index.json
-
43pages/agent/index/index.wxml
-
64pages/agent/index/index.wxss
-
9pages/agent/order/index.wxml
-
16pages/api/ztb.js
-
129pages/home/attentionPaperList/index.js
-
7pages/home/attentionPaperList/index.json
-
41pages/home/attentionPaperList/index.wxml
-
62pages/home/attentionPaperList/index.wxss
-
114pages/home/businessLicense/index.js
-
5pages/home/businessLicense/index.json
-
32pages/home/businessLicense/index.wxml
-
58pages/home/businessLicense/index.wxss
-
216pages/home/info/index.js
-
3pages/home/info/index.json
-
68pages/home/info/index.wxml
-
79pages/home/tab1/index.js
-
5pages/home/tab1/index.wxml
-
3pages/home/tab1/index.wxss
-
44pages/home/tab2/index.js
-
2pages/home/tab2/index.wxml
-
54pages/home/tab3/index.js
-
4pages/home/tab3/index.wxml
-
77pages/home/tab4/index.js
-
6pages/home/tab4/index.json
-
16pages/home/tab4/index.wxml
-
18pages/home/tab4/index.wxss
-
28pages/index/index.js
-
1pages/login/index.js
@ -1 +1,63 @@ |
|||
/* pages/agent/index/index.wxss */ |
|||
/* 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,129 @@ |
|||
// pages/home/tab4/index.js
|
|||
import { |
|||
getFactoryPrice, |
|||
userPushFollowMill |
|||
} from '../../api/ztb' |
|||
const event = require('../../../utils/event.js') |
|||
const storage = require('../../../utils/storage') |
|||
const app = getApp() |
|||
Page({ |
|||
|
|||
/** |
|||
* 页面的初始数据 |
|||
*/ |
|||
data: { |
|||
loopRequesting:false, |
|||
form: { |
|||
paperMillIds: [], |
|||
|
|||
}, |
|||
model: { |
|||
paperMillIds: [], |
|||
cityId: '', |
|||
enableSalesAgent: 1, |
|||
pageNum: 1, |
|||
listType: 0, |
|||
pageSize:1000 |
|||
}, |
|||
categoryListone: [], |
|||
safeBottom: app.globalData.safeBottom, |
|||
userInfo: null, |
|||
loading:true |
|||
|
|||
}, |
|||
|
|||
/** |
|||
* 生命周期函数--监听页面加载 |
|||
*/ |
|||
onLoad: function (options) { |
|||
this.setData({ safeBottom: app.globalData.safeBottom, userInfo: app.globalData.userInfo }) |
|||
this.getFactoryPriceFct(this.data.model) |
|||
}, |
|||
toMyInfo: function () { |
|||
event.emit('attentionPaperList', { what: 1100, desc: 'attentionPaperList' }) |
|||
wx.navigateBack({ |
|||
}) |
|||
}, |
|||
|
|||
/** |
|||
* 生命周期函数--监听页面初次渲染完成 |
|||
*/ |
|||
onReady: function () { |
|||
|
|||
}, |
|||
|
|||
/** |
|||
* 生命周期函数--监听页面显示 |
|||
*/ |
|||
onShow: function () { |
|||
|
|||
}, |
|||
|
|||
/** |
|||
* 生命周期函数--监听页面隐藏 |
|||
*/ |
|||
onHide: function () { |
|||
|
|||
}, |
|||
|
|||
/** |
|||
* 生命周期函数--监听页面卸载 |
|||
*/ |
|||
onUnload: function () { |
|||
|
|||
}, |
|||
|
|||
/** |
|||
* 页面相关事件处理函数--监听用户下拉动作 |
|||
*/ |
|||
onPullDownRefresh: function () { |
|||
|
|||
}, |
|||
|
|||
/** |
|||
* 页面上拉触底事件的处理函数 |
|||
*/ |
|||
onReachBottom: function () { |
|||
|
|||
}, |
|||
|
|||
/** |
|||
* 用户点击右上角分享 |
|||
*/ |
|||
onShareAppMessage: function () { |
|||
|
|||
}, |
|||
backspace: function () { |
|||
// console.log('点击返回被触发4')
|
|||
wx.redirectTo({ |
|||
url: '/pages/home/tab3/index' |
|||
}) |
|||
|
|||
}, |
|||
getFactoryPriceFct:function(model){ |
|||
getFactoryPrice(model).then(res=>{ |
|||
this.setData({ |
|||
categoryListone:res.data.records, |
|||
loading:false |
|||
}) |
|||
}) |
|||
}, |
|||
checkboxChange: function (e) { |
|||
console.log(e) |
|||
this.setData({ |
|||
'form.paperMillIds':e.detail.value, |
|||
'form.follow':true |
|||
}) |
|||
}, |
|||
bindtap: function (e) { |
|||
console.log(e) |
|||
}, |
|||
submitForm:function(){ |
|||
userPushFollowMill(this.data.form).then(result => { |
|||
this.data.loopRequesting = false |
|||
setTimeout(() => this.toMyInfo(), 1000) |
|||
}).catch(err => { |
|||
this.data.loopRequesting = false |
|||
}) |
|||
} |
|||
}) |
|||
@ -0,0 +1,7 @@ |
|||
{ |
|||
"usingComponents": { |
|||
"wux-cascader": "/components/cascader/index", |
|||
"wux-accordion-group": "/components/accordion-group/index", |
|||
"wux-accordion": "/components/accordion/index" |
|||
} |
|||
} |
|||
@ -0,0 +1,41 @@ |
|||
<!--pages/home/attentionPaperList/index.wxml--> |
|||
<cu-custom bgColor="bg-white" isBack="{{true}}"> |
|||
<view slot="content">关注纸厂</view> |
|||
</cu-custom> |
|||
|
|||
<view class="bj"> |
|||
<view style="width:100%;height:130rpx;padding-top:10rpx;padding-right:10rpx"> |
|||
<button class="cu-btn bg-red round shadow-blur vip-btn" bindtap="toMyInfo">跳出</button> |
|||
</view> |
|||
<view class="top"> |
|||
<view class="topText"> |
|||
<text>HI,\n欢迎使用纸通宝\n开启一站式废纸交易</text> |
|||
</view> |
|||
<view style="width:310rpx;height:258rpx;float:right"> |
|||
<image src="/assets/image/tabBj.png" style="width:310rpx;height:258rpx"></image> |
|||
</view> |
|||
</view> |
|||
<view class="mid"> |
|||
<text>你经常卖的纸厂是?</text> |
|||
</view> |
|||
<scroll-view scroll-y="true" style='height:500rpx;margin-top:15rpx'> |
|||
<view class="bg-white list-empty" style="height:{{height}}rpx" wx:if="{{!categoryListone.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 class="bottom"> |
|||
<view> |
|||
<checkbox-group bindchange="checkboxChange"> |
|||
<checkbox wx:for="{{ categoryListone }}" wx:key="index" style="width:100%;margin-top:15rpx" value="{{item.paperMillId}}" checked="{{item.hasFollowed}}">{{item.name}}</checkbox> |
|||
</checkbox-group> |
|||
</view> |
|||
</view> |
|||
</scroll-view> |
|||
<!-- <view style="width:100%;height:130rpx;padding-top:10rpx;padding-right:10rpx"> |
|||
<button class="cu-btn bg-red round shadow-blur page-btn" disabled="{{loopRequesting}}" bindtap="submitForm">确认</button> |
|||
</view> --> |
|||
<view class="cu-bar bg-white foot" style="height:{{120 + safeBottom}}rpx;padding: 32rpx 32rpx {{safeBottom + 32}}rpx 32rpx;"> |
|||
<button class="cu-btn bg-red round shadow-blur page-btn" bindtap="submitForm">确认</button> |
|||
</view> |
|||
</view> |
|||
@ -0,0 +1,62 @@ |
|||
/* pages/home/attentionPaperList/index.wxss */ |
|||
page{ |
|||
background-color: white; |
|||
} |
|||
.bj { |
|||
background-color: white; |
|||
min-height: 900rpx; |
|||
} |
|||
|
|||
.vip-btn { |
|||
/* height: 90rpx; */ |
|||
width: 180rpx; |
|||
background: #F5F5F5; |
|||
float: right; |
|||
color: rgba(0, 0, 0, 0.45); |
|||
font-size: 28rpx; |
|||
} |
|||
|
|||
.top { |
|||
height: 258rpx; |
|||
width: 100%; |
|||
} |
|||
|
|||
.topText { |
|||
width: 440rpx; |
|||
height: 258rpx; |
|||
float: left; |
|||
padding-left: 48rpx; |
|||
padding-top: 60rpx; |
|||
font-size: 44rpx; |
|||
color: #000000; |
|||
font-family: PingFangSC-Medium; |
|||
} |
|||
|
|||
.mid { |
|||
height: 150rpx; |
|||
padding-top: 100rpx; |
|||
padding-left: 48rpx; |
|||
font-family: PingFangSC-Medium; |
|||
font-size: 36rpx; |
|||
color: #000000; |
|||
letter-spacing: 2px; |
|||
} |
|||
|
|||
.bottom { |
|||
height: 410rpx; |
|||
padding: 48rpx; |
|||
} |
|||
|
|||
.bg-blue{ |
|||
color: #FFFFFF; |
|||
background-color: #008AFF; |
|||
} |
|||
|
|||
.page-btn { |
|||
height: 90rpx; |
|||
width: 100%; |
|||
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); |
|||
color: white; |
|||
font-size: 32rpx; |
|||
} |
|||
@ -0,0 +1,114 @@ |
|||
// pages/home/businessLicense/index.js
|
|||
import { |
|||
updateUserInfo, |
|||
getBaseInfo |
|||
} from '../../api/ztb' |
|||
const util = require('../../../utils/util') |
|||
Page({ |
|||
|
|||
/** |
|||
* 页面的初始数据 |
|||
*/ |
|||
data: { |
|||
fileList:[], |
|||
imgLength:0, |
|||
form:{ |
|||
imgList:'' |
|||
} |
|||
|
|||
}, |
|||
|
|||
/** |
|||
* 生命周期函数--监听页面加载 |
|||
*/ |
|||
onLoad: function (options) { |
|||
this.getUerInfoFct() |
|||
|
|||
}, |
|||
|
|||
/** |
|||
* 生命周期函数--监听页面初次渲染完成 |
|||
*/ |
|||
onReady: function () { |
|||
|
|||
}, |
|||
|
|||
/** |
|||
* 生命周期函数--监听页面显示 |
|||
*/ |
|||
onShow: function () { |
|||
|
|||
}, |
|||
|
|||
/** |
|||
* 生命周期函数--监听页面隐藏 |
|||
*/ |
|||
onHide: function () { |
|||
|
|||
}, |
|||
|
|||
/** |
|||
* 生命周期函数--监听页面卸载 |
|||
*/ |
|||
onUnload: function () { |
|||
|
|||
}, |
|||
|
|||
/** |
|||
* 页面相关事件处理函数--监听用户下拉动作 |
|||
*/ |
|||
onPullDownRefresh: function () { |
|||
|
|||
}, |
|||
|
|||
/** |
|||
* 页面上拉触底事件的处理函数 |
|||
*/ |
|||
onReachBottom: function () { |
|||
|
|||
}, |
|||
|
|||
/** |
|||
* 用户点击右上角分享 |
|||
*/ |
|||
onShareAppMessage: function () { |
|||
|
|||
}, |
|||
onImageChange: function (e) { |
|||
var that=this |
|||
if (e.detail) { |
|||
var list = [] |
|||
e.detail.forEach(element => { |
|||
if (!util.isEmpty(element.url)) { |
|||
list.push(element.url) |
|||
} |
|||
}) |
|||
that.data.form['imgList'] = list |
|||
that.updateUserInfoFct({businessLicenseUrl:e.detail[0].url}) |
|||
that.setData({ |
|||
imgLength: list.length |
|||
}) |
|||
|
|||
} |
|||
}, |
|||
updateUserInfoFct: function (model) { |
|||
console.log(model) |
|||
updateUserInfo(model).then(result => { |
|||
}).catch(err => { |
|||
}) |
|||
}, |
|||
getUerInfoFct: function () { |
|||
var that=this |
|||
getBaseInfo().then(res => { |
|||
that.data.form['imgList'] = res.data.businessLicenseUrl |
|||
var list=[] |
|||
if(res.data.businessLicenseUrl){ |
|||
list.push(res.data.businessLicenseUrl) |
|||
} |
|||
that.setData({ |
|||
imgLength: list.length, |
|||
fileList:[{ url: res.data.businessLicenseUrl, status: 8 }] |
|||
}) |
|||
}) |
|||
} |
|||
}) |
|||
@ -0,0 +1,5 @@ |
|||
{ |
|||
"usingComponents": { |
|||
"wux-uploader": "/components/uploader/index" |
|||
} |
|||
} |
|||
@ -0,0 +1,32 @@ |
|||
<!--pages/home/businessLicense/index.wxml--> |
|||
<cu-custom bgColor="bg-white" isBack="{{true}}"> |
|||
<view slot="content">营业执照</view> |
|||
</cu-custom> |
|||
|
|||
<view class="bj"> |
|||
<view style="width:100%;height:130rpx;padding-top:10rpx;padding-right:10rpx"> |
|||
<button class="cu-btn bg-red round shadow-blur vip-btn" bindtap="toMyInfo">跳出</button> |
|||
</view> |
|||
<view class="top"> |
|||
<view class="topText"> |
|||
<text>HI,\n欢迎使用纸通宝\n开启一站式废纸交易</text> |
|||
</view> |
|||
<view style="width:310rpx;height:258rpx;float:right"> |
|||
<image src="/assets/image/tabBj.png" style="width:310rpx;height:258rpx"></image> |
|||
</view> |
|||
</view> |
|||
<view class="mid"> |
|||
<text>你的营业执照是?</text> |
|||
|
|||
|
|||
<view style="display:{{!focus ? 'block' : 'none'}}"> |
|||
<view class="cu-bar bg-white margin-top"> |
|||
<view class="action text-bold" style="color:#333333">{{!disabled?'营业执照(上传1张)':'营业执照'}}</view> |
|||
<view class="action text-sg">{{imgLength}}{{!disabled? '/1':'张'}}</view> |
|||
</view> |
|||
<wux-uploader count="1" fileList="{{fileList}}" bindcustomevent="onImageChange"></wux-uploader> |
|||
</view> |
|||
|
|||
</view> |
|||
|
|||
</view> |
|||
@ -0,0 +1,58 @@ |
|||
/* pages/home/businessLicense/index.wxss */ |
|||
page{ |
|||
background-color: white; |
|||
} |
|||
.bj { |
|||
background-color: white; |
|||
min-height: 900rpx; |
|||
} |
|||
|
|||
.vip-btn { |
|||
/* height: 90rpx; */ |
|||
width: 180rpx; |
|||
background: #F5F5F5; |
|||
float: right; |
|||
color: rgba(0, 0, 0, 0.45); |
|||
font-size: 28rpx; |
|||
} |
|||
|
|||
.top { |
|||
height: 258rpx; |
|||
width: 100%; |
|||
} |
|||
|
|||
.topText { |
|||
width: 440rpx; |
|||
height: 258rpx; |
|||
float: left; |
|||
padding-left: 48rpx; |
|||
padding-top: 60rpx; |
|||
font-size: 44rpx; |
|||
color: #000000; |
|||
font-family: PingFangSC-Medium; |
|||
} |
|||
|
|||
.mid { |
|||
height: 150rpx; |
|||
padding-top: 100rpx; |
|||
padding-left: 48rpx; |
|||
font-family: PingFangSC-Medium; |
|||
font-size: 36rpx; |
|||
color: #000000; |
|||
letter-spacing: 2px; |
|||
} |
|||
|
|||
.bottom { |
|||
height: 410rpx; |
|||
padding: 48rpx; |
|||
} |
|||
|
|||
.wux-badge { |
|||
position: absolute; |
|||
width: 120px; |
|||
height: 120px; |
|||
opacity: 0.8; |
|||
right: 0; |
|||
bottom: 0; |
|||
z-index: 10; |
|||
} |
|||
@ -1,3 +1,7 @@ |
|||
{ |
|||
"usingComponents": {} |
|||
"usingComponents": { |
|||
"wux-cascader": "/components/cascader/index", |
|||
"wux-accordion-group": "/components/accordion-group/index", |
|||
"wux-accordion": "/components/accordion/index" |
|||
} |
|||
} |
|||
Write
Preview
Loading…
Cancel
Save