Browse Source

no message

featrue/v.4.0
xpz2018 5 years ago
parent
commit
9785d6262a
10 changed files with 34 additions and 39 deletions
  1. 6
      colorui/components/cu-custom.wxml
  2. 2
      colorui/main.wxss
  3. 6
      pages/agent/factory/index.js
  4. 4
      pages/article/point-index/index.js
  5. 7
      pages/home/index/index.js
  6. 23
      pages/home/index/index.wxml
  7. 13
      pages/login/index.js
  8. 7
      pages/mall/detail/index.js
  9. 2
      pages/mall/detail/index.wxml
  10. 3
      utils/util.js

6
colorui/components/cu-custom.wxml

@ -1,10 +1,12 @@
<view class="cu-custom" 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': ''}}">
<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" wx:if="{{isBack}}">
<text class="weui_goback"></text>
<slot name="backText"></slot>
</view>
<view class="action border-custom" wx:if="{{isCustom}}" style="width:{{Custom.width}}px;height:{{Custom.height}}px;margin-left:calc(750rpx - {{Custom.right}}px)">
<view class="action border-custom" wx:if="{{isCustom}}"
style="width:{{Custom.width}}px;height:{{Custom.height}}px;margin-left:calc(750rpx - {{Custom.right}}px)">
<text class="cuIcon-back" bindtap="backspace"></text>
<text class="cuIcon-homefill" bindtap="toHome"></text>
</view>

2
colorui/main.wxss

@ -778,7 +778,7 @@ button.icon.lg {
top: 0;
z-index: 19;
/* box-shadow: 0 1rpx 6rpx rgba(0, 0, 0, 0.1); */
border-bottom: 2rpx solid #eee;
border-bottom: 1rpx solid #f3f3f3;
}
.cu-bar.foot {

6
pages/agent/factory/index.js

@ -103,6 +103,10 @@ Page({
this.setData({cateIndex : e.currentTarget.dataset.index})
},
saleGood: function(e){
if(!app.globalData.userInfo){
wx.navigateTo({ url: '/pages/login/index' })
return
}
var item = this.data.factoryDetail.paperCategoryList[this.data.cateIndex]
if(util.isEmpty(item.unitPrice)){
util.showToast('该纸品暂无报价,无法卖货')
@ -111,7 +115,7 @@ Page({
wx.navigateTo({ url: '/pages/agent/edit/index?id=' + this.data.factoryDetail.paperMillId + '&categoryId=' + item.categoryId })
},
postMoment: function(){
wx.navigateTo({ url: '/pages/article/publish/index?factoryId=' + this.data.factoryDetail.paperMillId + '&name=' + this.data.factoryDetail.name })
util.navigateTo('/pages/article/publish/index?factoryId=' + this.data.factoryDetail.paperMillId + '&name=' + this.data.factoryDetail.name)
},
//*************************************************momentList************************************************//
onRefreshList: function () {

4
pages/article/point-index/index.js

@ -45,7 +45,7 @@ Component({
if (message.what == 573) {
// 帖子发布刷新
this.onRefreshList()
} else if(message.what == 200){
} else if(message.what == 200 || message.what == 888){
// Vip的变化
this.setData({ userInfo: app.globalData.userInfo })
this.onRefreshList()
@ -53,7 +53,7 @@ Component({
},
//*************************************************momentList************************************************//
onRefreshList: function () {
if(!this.data.vip){
if(!app.globalData.userInfo || !app.globalData.userInfo.isVIP){
this.setData({ requesting: false })
return
}

7
pages/home/index/index.js

@ -97,10 +97,11 @@ Component({
util.navigateTo('/pages/home/setting/index')
}
},
checkout: function () {
wx.navigateTo({ url: '/pages/withdrawal/checkout/index' })
},
toUserInfo: function () {
if(!app.globalData.userInfo){
wx.navigateTo({ url: '/pages/login/index' })
return
}
if (app.globalData.userInfo.isAuth != 1) {
wx.navigateTo({ url: '/pages/home/idcard/index' })
} else {

23
pages/home/index/index.wxml

@ -1,11 +1,13 @@
<wxs module="formate" src="../../../pages/formate.wxs"></wxs>
<cu-custom bgColor="bg-blue" isBack="{{false}}">
<cu-custom bgColor="bg-blue" isBack="{{false}}" shadow="{{true}}">
<view slot="content" style="color:white;font-size:18px">我的</view>
</cu-custom>
<scroll-view scroll-y style="height: {{height}}rpx;">
<view class="bg-white flex flex-justify" style="padding:32rpx" wx:if="{{userInfo}}" bindtap="toUserInfo">
<view class="flex">
<view style="height:80rpx;background-color:#008AFF;border-radius: 0px 0px 100px 100px"></view>
<view style="padding:0rpx 32rpx 32rpx 32rpx;margin-top:-48rpx" >
<view class="flex bg-white" style="padding:24rpx 32rpx;border-radius: 6px;" bindtap="toUserInfo">
<view style="position: relative">
<wux-image width="{{60}}" height="{{60}}" wux-class="image" shape="circle" src="{{avatarUrl}}">
<image style="width:60px;height:60px;border-radio:30px" slot="loading" src="/assets/image/ygImg.png"></image>
@ -14,27 +16,26 @@
</view>
</view>
<view class="flex flex-column flex-center" style="margin-left:24rpx;align-items:flex-start">
<view class="flex flex-center">
<text style="white-space: nowrap">{{userName || ''}}</text>
<view class="flex flex-center" wx:if="{{userInfo}}">
<text class="text-bold text-sg" style="white-space: nowrap">{{userName || ''}}</text>
<view class="flex flex-center" style="font-size:12px" catchtap="toAuthor">
<image class="img-auth2"
src="{{userInfo.isAuth == 1 ? '/assets/image/icon_author.png' : '/assets/image/icon_unauthor.png'}}">
</image>
<text
class="{{userInfo.isAuth == 1 ? 'text-blue' : 'text-gray'}}">{{userInfo.isAuth == 1 ? '已认证' : '未实名认证'}}</text>
<text class="text-yellow" style="font-size:14px;padding:4px;"
wx:if="{{userInfo.isAuth != 1 && userInfo.userType == 1}}">去认证</text>
<text class="{{userInfo.isAuth == 1 ? 'text-blue' : 'text-gray'}}">{{userInfo.isAuth == 1 ? '已认证' : '未实名认证'}}</text>
<text class="text-yellow" style="font-size:12px;padding:4px;" wx:if="{{userInfo.isAuth != 1}}">去认证</text>
</view>
</view>
<view style="margin-top:12rpx" wx:else>
<text class="text-gray" style="font-size:14px">您还没有登录,去登录</text>
</view>
<view class="flex flex-center" style="font-size:12px;margin-top:12rpx" catchtap="toAuthor">
<text class="text-black" style="font-size:14px">{{userInfo.mobile||''}}</text>
</view>
</view>
</view>
<text class="cuIcon-right text-gray" style="font-size:18px"></text>
</view>
<view style="height:16rpx"></view>
<wux-cell-group>
<wux-cell title="纸通宝会员" is-link url="/pages/ztbvip/index">
<image slot="header" style="width:32rpx;height:32rpx;margin:6rpx 12rpx 0rpx 0rpx"

13
pages/login/index.js

@ -23,23 +23,12 @@ Page({
},
loging: false,
wxflag: false,
userInfo: null,
version15: false,
path: null
userInfo: null
},
onLoad: function (options) {
if (options.mobile) {
this.setData({ ['form.mobile']: options.mobile })
}
if (options.version) {
this.data.version15 = parseInt(options.version)
}
if(options.url){
this.data.path = options.url
if(options.key && options.value){
this.data.path += '?' + options.key + '=' + options.value
}
}
var check = wx.getStorageSync('AgreeCheck')
app.globalData.kg = wx.getStorageSync('ztb-kg')
if (check) {

7
pages/mall/detail/index.js

@ -138,15 +138,12 @@ Page({
//成功回调
for (let index = 0; index < result.data.records.length; index++) {
const element = result.data.records[index]
if(element.isMine){
if(element.isMine && app.globalData.userInfo){
this.data.offered = element.biddingUnitPrice
break
}
}
this.setData({
recordList: result.data.records,
offered: this.data.offered
})
this.setData({ recordList: result.data.records, offered: this.data.offered })
})
},
isVideoUrl: function (url) {

2
pages/mall/detail/index.wxml

@ -106,7 +106,7 @@
</view>
<view style="height:{{136 + safeBottom}}rpx"></view>
<view class="cu-bar bg-white tabbar foot" style="height:{{120 + safeBottom}}rpx;padding: 32rpx 32rpx {{safeBottom + 32}}rpx 16rpx;" wx:if="{{orderInfo.isOwner == 0}}">
<view class="cu-bar bg-white tabbar foot" style="height:{{120 + safeBottom}}rpx;padding: 32rpx 32rpx {{safeBottom + 32}}rpx 16rpx;" wx:if="{{orderInfo.isOwner != 1}}">
<view class="action" style="width: 100rpx" bindtap="toShopInfo">
<view class="cuIcon-shop" style="font-size:24px"></view> 店铺
</view>

3
utils/util.js

@ -185,7 +185,8 @@ const tokenList = [
'/pages/withdrawal/balance/index',
'/pages/agent/order/index',
'/pages/home/idcard/index',
'/pages/shop/detail/index'
'/pages/shop/detail/index',
'/pages/article/publish/index'
]
function navigateTo(url){

Loading…
Cancel
Save