修改功能
This commit is contained in:
@@ -130,6 +130,7 @@ export default {
|
|||||||
times:'Time',
|
times:'Time',
|
||||||
address:'Address',
|
address:'Address',
|
||||||
emailerr:'Email cannot be empty',
|
emailerr:'Email cannot be empty',
|
||||||
|
emailerr1:'Email format error',
|
||||||
passworerr:'Password cannot be empty',
|
passworerr:'Password cannot be empty',
|
||||||
passworerr1:'Password inconsistency',
|
passworerr1:'Password inconsistency',
|
||||||
agreementarr:'Please first check and agree to the User Service Agreement and Privacy Policy',
|
agreementarr:'Please first check and agree to the User Service Agreement and Privacy Policy',
|
||||||
|
|||||||
@@ -129,6 +129,7 @@ export default {
|
|||||||
times:'时间',
|
times:'时间',
|
||||||
address:'地址',
|
address:'地址',
|
||||||
emailerr:'邮箱不能为空',
|
emailerr:'邮箱不能为空',
|
||||||
|
emailerr1:'邮箱格式错误',
|
||||||
passworerr:'密码不能为空',
|
passworerr:'密码不能为空',
|
||||||
passworerr1:'密码不一致',
|
passworerr1:'密码不一致',
|
||||||
agreementarr:'请先勾选同意用户服务协议以及隐私政策',
|
agreementarr:'请先勾选同意用户服务协议以及隐私政策',
|
||||||
|
|||||||
+3
-10
@@ -3,7 +3,7 @@
|
|||||||
<uni-nav-bar leftText=" " :fixed="true" :border="false" leftIcon="back" @clickLeft="leftClick" color="#000000" backgroundColor="#fff" :statusBar="true" :title="$t('navbar.customerinfo')"></uni-nav-bar>
|
<uni-nav-bar leftText=" " :fixed="true" :border="false" leftIcon="back" @clickLeft="leftClick" color="#000000" backgroundColor="#fff" :statusBar="true" :title="$t('navbar.customerinfo')"></uni-nav-bar>
|
||||||
<view class="content">
|
<view class="content">
|
||||||
<view class="cell">
|
<view class="cell">
|
||||||
<view class="item">{{$t('customer.CustomerChannel')}}</view>
|
<view class="item">{{$t('customer.CustomerChannel')}} <text class="red">*</text></view>
|
||||||
<view class="right select" @click="showchannel = true">
|
<view class="right select" @click="showchannel = true">
|
||||||
<view class="" :class="['content2', { placeholder: !channel_name }]">{{channel_name || $t('customer.CustomerChannelinput')}}</view>
|
<view class="" :class="['content2', { placeholder: !channel_name }]">{{channel_name || $t('customer.CustomerChannelinput')}}</view>
|
||||||
<!-- <input :placeholder="$t('customer.CustomerChannelinput')" disabled v-model="channel_name" /> -->
|
<!-- <input :placeholder="$t('customer.CustomerChannelinput')" disabled v-model="channel_name" /> -->
|
||||||
@@ -60,7 +60,7 @@
|
|||||||
</view>
|
</view>
|
||||||
<u-line></u-line>
|
<u-line></u-line>
|
||||||
<view class="cell">
|
<view class="cell">
|
||||||
<view class="item">{{$t('customer.Customerph')}}</view>
|
<view class="item">{{$t('customer.Customerph')}} <text class="red">*</text></view>
|
||||||
<view class="right select" @click="showcartype = true">
|
<view class="right select" @click="showcartype = true">
|
||||||
<view class="" :class="['content2', { placeholder: !car_type_name }]">{{car_type_name || $t('customer.Customerphinput')}}</view>
|
<view class="" :class="['content2', { placeholder: !car_type_name }]">{{car_type_name || $t('customer.Customerphinput')}}</view>
|
||||||
<!-- <input :placeholder="$t('customer.Customerphinput')" disabled v-model="car_type_name" /> -->
|
<!-- <input :placeholder="$t('customer.Customerphinput')" disabled v-model="car_type_name" /> -->
|
||||||
@@ -312,14 +312,7 @@
|
|||||||
saveFn(){
|
saveFn(){
|
||||||
if(this.form.contacts==''){
|
if(this.form.contacts==''){
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
title:'客户名称不能为空',
|
title:this.$t('customer.CustomerNameinput'),
|
||||||
icon: 'none'
|
|
||||||
});
|
|
||||||
return false
|
|
||||||
}
|
|
||||||
if(this.form.phone==''){
|
|
||||||
uni.showToast({
|
|
||||||
title:'联系方式不能为空',
|
|
||||||
icon: 'none'
|
icon: 'none'
|
||||||
});
|
});
|
||||||
return false
|
return false
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
<uni-nav-bar leftText=" " :fixed="true" :border="false" leftIcon="back" @clickLeft="leftClick" color="#000000" backgroundColor="#fff" :statusBar="true" :title="$t('navbar.customerinfo')"></uni-nav-bar>
|
<uni-nav-bar leftText=" " :fixed="true" :border="false" leftIcon="back" @clickLeft="leftClick" color="#000000" backgroundColor="#fff" :statusBar="true" :title="$t('navbar.customerinfo')"></uni-nav-bar>
|
||||||
<view class="content">
|
<view class="content">
|
||||||
<view class="cell">
|
<view class="cell">
|
||||||
<view class="item">{{$t('customer.CustomerChannel')}}</view>
|
<view class="item">{{$t('customer.CustomerChannel')}} <text class="red">*</text></view>
|
||||||
<view class="right select" @click="showchannel = true">
|
<view class="right select" @click="showchannel = true">
|
||||||
<!-- <input :placeholder="$t('customer.CustomerChannelinput')" disabled v-model="channel_name" /> -->
|
<!-- <input :placeholder="$t('customer.CustomerChannelinput')" disabled v-model="channel_name" /> -->
|
||||||
<view class="" :class="['content2', { placeholder: !channel_name }]">{{channel_name || $t('customer.CustomerChannelinput')}}</view>
|
<view class="" :class="['content2', { placeholder: !channel_name }]">{{channel_name || $t('customer.CustomerChannelinput')}}</view>
|
||||||
@@ -60,7 +60,7 @@
|
|||||||
</view>
|
</view>
|
||||||
<u-line></u-line>
|
<u-line></u-line>
|
||||||
<view class="cell">
|
<view class="cell">
|
||||||
<view class="item">{{$t('customer.Customerph')}}</view>
|
<view class="item">{{$t('customer.Customerph')}} <text class="red">*</text></view>
|
||||||
<view class="right select" @click="showcartype = true">
|
<view class="right select" @click="showcartype = true">
|
||||||
<!-- <input :placeholder="$t('customer.Customerphinput')" disabled v-model="car_type_name" /> -->
|
<!-- <input :placeholder="$t('customer.Customerphinput')" disabled v-model="car_type_name" /> -->
|
||||||
<view class="" :class="['content2', { placeholder: !car_type_name }]">{{car_type_name || $t('customer.Customerphinput')}}</view>
|
<view class="" :class="['content2', { placeholder: !car_type_name }]">{{car_type_name || $t('customer.Customerphinput')}}</view>
|
||||||
|
|||||||
@@ -435,7 +435,7 @@
|
|||||||
url: 'http://219.157.255.213:9007/upload/uploadImage',
|
url: 'http://219.157.255.213:9007/upload/uploadImage',
|
||||||
filePath: imgUrl,
|
filePath: imgUrl,
|
||||||
name: 'files',
|
name: 'files',
|
||||||
// header:{'content-type': 'application/x-www-form-urlencoded','Authorization': 'Bearer ' + uni.getStorageSync('token')},
|
header:{'Authorization': 'Bearer ' + uni.getStorageSync('token')},
|
||||||
success: (uploadFileRes) => {
|
success: (uploadFileRes) => {
|
||||||
const path=JSON.parse(uploadFileRes.data)
|
const path=JSON.parse(uploadFileRes.data)
|
||||||
if(path.code==-1){
|
if(path.code==-1){
|
||||||
|
|||||||
@@ -7,7 +7,7 @@
|
|||||||
<view class="content">
|
<view class="content">
|
||||||
<view class="contop">
|
<view class="contop">
|
||||||
<view class="">
|
<view class="">
|
||||||
<image class="userimg" :src="userinfo.avatar==''||userinfo.avatar==null||userinfo.avatar=='null'?'/static/image/mine/user.png':userinfo.avatar" mode=""></image>
|
<image class="userimg" :src="userinfo.avatar" mode=""></image>
|
||||||
<!-- <image class="userimg" src="/static/image/mine/user.png" mode=""></image> -->
|
<!-- <image class="userimg" src="/static/image/mine/user.png" mode=""></image> -->
|
||||||
</view>
|
</view>
|
||||||
<view class="right">
|
<view class="right">
|
||||||
|
|||||||
@@ -36,6 +36,11 @@
|
|||||||
url:'feishu/getinfo',
|
url:'feishu/getinfo',
|
||||||
method:'post',
|
method:'post',
|
||||||
}).then(res => {
|
}).then(res => {
|
||||||
|
uni.showToast({
|
||||||
|
title: res.data.message,
|
||||||
|
icon: 'none'
|
||||||
|
});
|
||||||
|
if(res.data.code ==0){
|
||||||
var data = res.data.data;
|
var data = res.data.data;
|
||||||
this.datas = data
|
this.datas = data
|
||||||
console.log(data)
|
console.log(data)
|
||||||
@@ -49,6 +54,14 @@
|
|||||||
console.log(code_url)
|
console.log(code_url)
|
||||||
// return;
|
// return;
|
||||||
window.location.href = code_url;
|
window.location.href = code_url;
|
||||||
|
}else{
|
||||||
|
setTimeout(() => {
|
||||||
|
uni.reLaunch({
|
||||||
|
url: '/pages/index/mine',// 替换为你要跳转的页面路径
|
||||||
|
});
|
||||||
|
}, 1000);
|
||||||
|
}
|
||||||
|
|
||||||
})
|
})
|
||||||
} else {
|
} else {
|
||||||
this.getOpenId(code,state)
|
this.getOpenId(code,state)
|
||||||
|
|||||||
@@ -78,7 +78,13 @@
|
|||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
leftClick(){
|
leftClick(){
|
||||||
uni.navigateBack({})
|
uni.reLaunch({
|
||||||
|
url: '/pages/login/index',// 替换为你要跳转的页面路径
|
||||||
|
});
|
||||||
|
},
|
||||||
|
validateEmail(email) {
|
||||||
|
const regex = /^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$/;
|
||||||
|
return regex.test(email);
|
||||||
},
|
},
|
||||||
login() {
|
login() {
|
||||||
if(this.email==''){
|
if(this.email==''){
|
||||||
@@ -141,6 +147,13 @@
|
|||||||
});
|
});
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
|
if (!this.validateEmail(this.email)) {
|
||||||
|
uni.showToast({
|
||||||
|
title:this.$t('emailerr1'),
|
||||||
|
icon: 'none'
|
||||||
|
});
|
||||||
|
return false;
|
||||||
|
}
|
||||||
this.vcodeTime = 60
|
this.vcodeTime = 60
|
||||||
this.vcodeTimer = setInterval(() => {
|
this.vcodeTimer = setInterval(() => {
|
||||||
if (this.vcodeTime > 0) {
|
if (this.vcodeTime > 0) {
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
<view class="content">
|
<view class="content">
|
||||||
<view class="topimg">
|
<view class="topimg">
|
||||||
<uni-file-picker fileMediatype="image" limit="1" :list-styles="imageStyles" :del-icon="false" disable-preview @select="select" @delete="delfn('picture')">
|
<uni-file-picker fileMediatype="image" limit="1" :list-styles="imageStyles" :del-icon="false" disable-preview @select="select" @delete="delfn('picture')">
|
||||||
<image class="user" :src="userinfo.avatar==''||userinfo.avatar==null||userinfo.avatar=='null'?'/static/image/mine/user.png':userinfo.avatar"mode=""></image>
|
<image class="user" :src="userinfo.avatar"mode=""></image>
|
||||||
<!-- <image class="xj" src="/static/image/mine/xiangji.png" mode=""></image> -->
|
<!-- <image class="xj" src="/static/image/mine/xiangji.png" mode=""></image> -->
|
||||||
</uni-file-picker>
|
</uni-file-picker>
|
||||||
<view>{{$t('mine.changeavatar')}}</view>
|
<view>{{$t('mine.changeavatar')}}</view>
|
||||||
@@ -105,7 +105,11 @@
|
|||||||
url:'user/getInfo',
|
url:'user/getInfo',
|
||||||
method:'get',
|
method:'get',
|
||||||
}).then(res => {
|
}).then(res => {
|
||||||
|
if(res.data.data.position=='null'){
|
||||||
|
res.data.data.position=''
|
||||||
|
}
|
||||||
that.userinfo = res.data.data;
|
that.userinfo = res.data.data;
|
||||||
|
|
||||||
that.select1()
|
that.select1()
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
@@ -166,7 +170,7 @@
|
|||||||
url: 'http://219.157.255.213:9007/upload/uploadImage',
|
url: 'http://219.157.255.213:9007/upload/uploadImage',
|
||||||
filePath: imgUrl,
|
filePath: imgUrl,
|
||||||
name: 'files',
|
name: 'files',
|
||||||
// header:{'content-type': 'application/x-www-form-urlencoded','Authorization': 'Bearer ' + uni.getStorageSync('token')},
|
header:{'Authorization': 'Bearer ' + uni.getStorageSync('token')},
|
||||||
success: (uploadFileRes) => {
|
success: (uploadFileRes) => {
|
||||||
const path=JSON.parse(uploadFileRes.data)
|
const path=JSON.parse(uploadFileRes.data)
|
||||||
if(path.code==-1){
|
if(path.code==-1){
|
||||||
|
|||||||
@@ -80,6 +80,10 @@
|
|||||||
leftClick(){
|
leftClick(){
|
||||||
uni.navigateBack({})
|
uni.navigateBack({})
|
||||||
},
|
},
|
||||||
|
validateEmail(email) {
|
||||||
|
const regex = /^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$/;
|
||||||
|
return regex.test(email);
|
||||||
|
},
|
||||||
login() {
|
login() {
|
||||||
if(this.email==''){
|
if(this.email==''){
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
@@ -134,6 +138,13 @@
|
|||||||
});
|
});
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
|
if (!this.validateEmail(this.email)) {
|
||||||
|
uni.showToast({
|
||||||
|
title:this.$t('emailerr1'),
|
||||||
|
icon: 'none'
|
||||||
|
});
|
||||||
|
return false;
|
||||||
|
}
|
||||||
this.vcodeTime = 60
|
this.vcodeTime = 60
|
||||||
this.vcodeTimer = setInterval(() => {
|
this.vcodeTimer = setInterval(() => {
|
||||||
if (this.vcodeTime > 0) {
|
if (this.vcodeTime > 0) {
|
||||||
|
|||||||
Reference in New Issue
Block a user