This commit is contained in:
lanzhihui 2024-11-13 09:16:45 +08:00
parent 31d6a9f499
commit fd9da9e895
10 changed files with 68 additions and 22 deletions

View File

@ -35,7 +35,7 @@ wepy.app({
}
},
globalData: {
versions: 'v5.5.77', // 版本号
versions: 'v5.5.78', // 版本号
navBarHeight: 0, // 导航栏高度
navRight: 0, // 胶囊距右方间距(方保持左、右间距一致)
navTop: 0, // 胶囊距顶部间距

View File

@ -204,7 +204,7 @@ scroll-view {
<template>
<block v-for="(item,index) in list" :key="index">
<view class="~f-fl ~ui-pl-30 ~ui-pr-30 ~ui-pt-30 ~ui-relative" @tap="jumpPath(from == 'myDynamic' ? `/pages/users/myDynamicDetail?id=${item.id}` : `/pages/dynamic/dynamicDetail?id=${item.id}`)">
<view class="ui-user-pic" style="{{'background-image:url(' + (item.user.photo || 'https://image.fulllinkai.com/202203/09/cc1c73eb1a4941fef25a15cd1ff2f9df.png') + ')'}}" @tap.stop="jumpPath(`/pages/home/information?id=${item.user_id}`)"></view>
<view class="ui-user-pic" style="{{'background-image:url(' + (item.user.photo || 'https://image.fulllinkai.com/202203/09/cc1c73eb1a4941fef25a15cd1ff2f9df.png') + ')'}}" @tap.stop="jumpPathV2(`/pages/home/information?id=${item.user_id}`)"></view>
<view class="~color999 ~font_24 ui-time">{{ item.create_time }}</view>
<view class="~ui-pl-16">
<view class="~f-fc">
@ -417,7 +417,22 @@ scroll-view {
}
console.log('333--')
wx.navigateTo({url: url})
}
},
jumpPathV2(url, type) {
let vm = this
// 校验是否完成注册资料
if (!vm.$signInVerify()) {
vm.$emit('signInVerify')
return
}
console.log(vm.from, url, type, '7777')
if (vm.from != 'dynamicDetail') {
console.log('44---')
return
}
console.log(vm.from, '333-13-')
wx.navigateTo({url: url})
}
},
created() {}
})

View File

@ -358,6 +358,7 @@ wepy.page({
}
if (!vm.value) {
vm.$showToast('请输入动态内容')
return
}
if (vm.throttle) {
vm.throttle = false

View File

@ -304,7 +304,7 @@ wepy.page({
if (!vm.belief) {
return vm.$showToast('请选择你的信仰')
}
vm.$showLoading('')
vm.$showLoading('注册中')
let data = {
photo: vm.photo,
nickname: vm.name,
@ -326,10 +326,13 @@ wepy.page({
let userInfo = wx.getStorageSync('userInfo')
console.log(userInfo, '===')
userInfo.is_base_profile = true
wx.setStorageSync('userInfo', userInfo)
wx.switchTab({url: '/pages/tabBar/home'})
wx.setStorageSync('userInfo', userInfo)
vm.$showToast('注册成功')
setTimeout(() => {
wx.hideLoading()
wx.switchTab({url: '/pages/tabBar/home'})
}, 1200)
}
wx.hideLoading()
}).catch(err => {
wx.hideLoading()
console.log(err)

View File

@ -262,10 +262,10 @@ wepy.page({
getPhoneNumber({$wx: e}) { // 获取手机号
let vm = this
if (e.detail.iv) {
getPhoneNumber(e).then(({mobile}) => {
console.log(mobile, '11111')
if (mobile) {
vm.mobile = mobile
getPhoneNumber(e).then(({phone}) => {
console.log(phone, '11111')
if (phone) {
vm.mobile = phone
console.log(vm.mobile)
vm.bindMobile()
}

View File

@ -525,10 +525,12 @@
url: `${service.user}/center`,
data
}).then(({code, data}) => {
// var repTime = (data.user.created_at).replace(/-/g, '/')// 用正则兼容ios
// var recordTime = String(parseFloat(new Date(repTime).getTime()) / 1000)
// self.UID = recordTime.substring(recordTime.length - 5) + String(data.id)
wx.setStorageSync('UID', self.UID)
console.log(wx.getStorageSync('userInfo'), 'wx.getStorageSync(\'userInfo\')=')
let repTime = (wx.getStorageSync('userInfo').create_time).replace(/-/g, '/')// 用正则兼容ios
let recordTime = String(parseFloat(new Date(repTime).getTime()) / 1000)
console.log(recordTime, 'recordTime')
self.UID = recordTime.substring(recordTime.length - 5) + String(data.user.id)
wx.setStorageSync('UID', self.user.UID)
self.shareConfig.images[1].url = data.share_qrcode
self.posterConfig = self.shareConfig
console.log(self.posterConfig, '333===0999')
@ -640,11 +642,12 @@
wx.hideLoading()
},
getPhoneNumber(e) { // 获取手机号
getPhoneNumber({$wx: e}) { // 获取手机号
let vm = this
if (e.$wx.detail.iv) {
getPhoneNumber(e).then(({phoneNumber}) => {
if (phoneNumber) {
console.log(e, 'e==')
if (e.detail.iv) {
getPhoneNumber(e).then(({phone}) => {
if (phone) {
vm.isShowIphoneBtn = false
vm.$showToast('绑定成功')
}

View File

@ -195,7 +195,7 @@ import {getPhoneNumber} from '../../utils/util'
getPhoneNumber(e).then((data) => {
if (data.phone) {
vm.mobile = data.phone
}
}
})
}
},

View File

@ -75,7 +75,18 @@
<view class="mainTitle bold font_28 color-999">个人资料</view>
<view class="m_section">
<view class="u_section">
<picker mode="date" value="1990-01-01" end="{{endDate}}" @change="typing('birthday',$event)">
<block v-if="realApproved">
<view class="m_basLst f-fbc" @tap="bindTips('认证后出生日期无法修改哦,如有需要请联系客服')">
<view>
<span class="font_28 color-333 bold">出生日期</span>
</view>
<view class="f-fc">
<text class="font_28 color-333">{{birthday}}</text>
<image class="tips_icon" src="https://image.fulllinkai.com/202108/19/1e592d8cc35396e3142d9bd40093abe9.png" mode="aspectFit"></image>
</view>
</view>
</block>
<picker v-else mode="date" value="1990-01-01" end="{{endDate}}" @change="typing('birthday',$event)">
<view class="m_secLst f-fbc">
<span class="font_28 color-333 bold">出生日期</span>
<view class="font_28 f-fc">
@ -227,6 +238,7 @@
CITY_INDEX: 0,
photos: [],
CITY_INDEX1: 1,
realApproved: false,
birthday: '',
name: '',
nickname: '',
@ -385,6 +397,12 @@
if (result.birthday) {
that.birthday = result.birthday
}
if (wx.getStorageSync('userInfo')) {
console.log(wx.getStorageSync('userInfo').is_real_approved, '09')
if (wx.getStorageSync('userInfo').is_real_approved == 1) {
that.realApproved = true
}
}
if (result.province) {
that.region = [result.country, result.province, result.city]
}

View File

@ -1100,6 +1100,9 @@
that._approveList[0].active = true
}
if (data.is_real_approved == '1') { // 真人
let userInfo = wx.getStorageSync('userInfo') // 真人认证更新后存入
userInfo.is_real_approved = data.is_real_approved
wx.setStorageSync('userInfo', userInfo)
that._approveList[1].active = true
}
if (data.is_educate_approved == '1') { // 学历

View File

@ -69,7 +69,8 @@ const wx_login = () => {
rank_id: data.user.rank_id,
sex: data.user.sex,
id: data.user.id,
type: data.user.type
type: data.user.type,
create_time: data.user.create_time
}
console.log(userInfo, '7777------')
wx.setStorageSync('userInfo', userInfo) // 用户基本信息
@ -109,8 +110,10 @@ const getPhoneNumber = ({detail}) => {
method: 'get',
success: ({data: res}) => {
let {code, data} = res
console.log(data, 'data=')
switch (code) {
case 0:
wx.setStorageSync('mobile', data.phone)
resolve(data) // 返回参数
break
case 1: