20240517
This commit is contained in:
@@ -125,15 +125,15 @@
|
||||
@confirm="onSubmit"
|
||||
class="form_input_box"
|
||||
>
|
||||
<template slot="suffix">
|
||||
<image
|
||||
:src="isSee ? passShowIcon : passHideIcon"
|
||||
mode="aspectFit"
|
||||
@click="isSee = !isSee"
|
||||
>
|
||||
</image>
|
||||
</template>
|
||||
</u--input>
|
||||
</u--input
|
||||
><u-icon
|
||||
class="active"
|
||||
:name="isSee ? 'eye-fill' : 'eye-off'"
|
||||
@click="isSee = !isSee"
|
||||
:color="isSee ? '#018F89' : '#b0b0b0'"
|
||||
size="30"
|
||||
style="display: block; margin-right: 10rpx"
|
||||
></u-icon>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
@@ -179,7 +179,7 @@
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<view class="youKeL" style="margin-bottom: 80rpx">
|
||||
<!-- <view class="youKeL" style="margin-bottom: 80rpx">
|
||||
<view
|
||||
@click="
|
||||
onPageJump('/pages/user/visitor');
|
||||
@@ -187,7 +187,7 @@
|
||||
"
|
||||
>免登陆体验</view
|
||||
>
|
||||
</view>
|
||||
</view> -->
|
||||
|
||||
<!-- <u-popup :show="HealthOpen" type="center" :round="10" mode="center" :hideOnBlur="false">
|
||||
<view class="popup_box">
|
||||
@@ -249,8 +249,16 @@
|
||||
@close="yhxyShow = false"
|
||||
>
|
||||
<view class="tanchu">
|
||||
<view class="dp_title" v-html="yhxyText.title"></view>
|
||||
<view class="dp_content" v-html="yhxyText.content"></view>
|
||||
<view
|
||||
class="dp_title"
|
||||
v-html="yhxyText.title
|
||||
"
|
||||
></view>
|
||||
<view
|
||||
class="dp_content"
|
||||
v-html="yhxyText.content
|
||||
"
|
||||
></view>
|
||||
<!-- <yhxyPage></yhxyPage> -->
|
||||
</view>
|
||||
</u-popup>
|
||||
@@ -261,9 +269,17 @@
|
||||
:round="10"
|
||||
@close="yszcShow = false"
|
||||
>
|
||||
<view class="tanchu">
|
||||
<view class="dp_title" v-html="yszcText.title"></view>
|
||||
<view class="dp_content" v-html="yszcText.content"></view>
|
||||
<view class="tanchu" >
|
||||
<view
|
||||
class="dp_title"
|
||||
v-html="yszcText.title
|
||||
"
|
||||
></view>
|
||||
<view
|
||||
class="dp_content"
|
||||
v-html="yszcText.content
|
||||
"
|
||||
></view>
|
||||
<!-- <yszcPage></yszcPage> -->
|
||||
</view>
|
||||
</u-popup>
|
||||
@@ -287,8 +303,8 @@ export default {
|
||||
appForm: {
|
||||
// loginName: 18834844847,
|
||||
// loginPwd: '123456',
|
||||
loginName: 18888888888,
|
||||
loginPwd: "123456",
|
||||
loginName: 18834844847,
|
||||
loginPwd: "Zy123456",
|
||||
},
|
||||
passShowIcon: require("@/static/icon/ic_logon_display.png"),
|
||||
passHideIcon: require("@/static/icon/ic_logon_hide.png"),
|
||||
@@ -317,8 +333,11 @@ export default {
|
||||
isSee_H: false,
|
||||
yhxyShow: false,
|
||||
yszcShow: false,
|
||||
yhxyText: {},
|
||||
yszcText: {},
|
||||
yhxyText: {
|
||||
title: "",
|
||||
content: "",
|
||||
},
|
||||
yszcText: { title: "", content: "" },
|
||||
quShow: false,
|
||||
quCodeList: [], // 国家区域码
|
||||
loginForm: {},
|
||||
@@ -355,16 +374,34 @@ export default {
|
||||
pname: "com.tencent.mm",
|
||||
action: "weixin://",
|
||||
});
|
||||
this.type = 2000;
|
||||
this.brand = 3000;
|
||||
|
||||
this.loginForm = {};
|
||||
|
||||
// #endif
|
||||
},
|
||||
created() {
|
||||
this.getCountyCode();
|
||||
},
|
||||
//页面显示
|
||||
onShow() {
|
||||
this.type = 2000;
|
||||
this.brand = 3000;
|
||||
this.loginForm = {};
|
||||
console.log("at line 362:", uni.getStorageSync("userInfo"));
|
||||
this.getSettlement(101,'yszcText');
|
||||
this.getSettlement(100,'yhxyText');
|
||||
//this.closeMusic()
|
||||
this.getCountyCode();
|
||||
this.getSettlement();
|
||||
},
|
||||
onReady() {
|
||||
// if(uni.getStorageSync('userInfo')&&uni.getStorageSync('userInfo').token){
|
||||
// uni.switchTab({
|
||||
// url: "/pages/homePage/index/index",
|
||||
// success: function () {
|
||||
// let page = getCurrentPages()[0];
|
||||
// console.log(page);
|
||||
// page.$vm.requestAll();
|
||||
// },
|
||||
// });
|
||||
// }
|
||||
},
|
||||
//方法
|
||||
methods: {
|
||||
@@ -375,6 +412,11 @@ export default {
|
||||
this.loginForm = {};
|
||||
this.type = 2000;
|
||||
this.type = val;
|
||||
this.isSee = false;
|
||||
this.agree = false;
|
||||
if (val == 2000) {
|
||||
this.loginForm.quCode = this.quCodeList[0].value;
|
||||
}
|
||||
},
|
||||
changeBrand(val) {
|
||||
this.loginForm = {};
|
||||
@@ -390,7 +432,9 @@ export default {
|
||||
console.log("success");
|
||||
},
|
||||
});
|
||||
this.setUserInfo({ playVisible: false });
|
||||
this.setUserInfo({
|
||||
playVisible: false,
|
||||
});
|
||||
},
|
||||
// 获取国家区域编码
|
||||
getCountyCode() {
|
||||
@@ -425,39 +469,39 @@ export default {
|
||||
});
|
||||
},
|
||||
// 获取协议内容
|
||||
getSettlement() {
|
||||
this.$http
|
||||
.post("sys/agreement/getPrivacyDetail")
|
||||
.then((res) => {
|
||||
this.yszcText = res.privacy;
|
||||
this.yszcText.content = this.yszcText.content.replace(
|
||||
/<h5>/g,
|
||||
'<view style="font-weight: bold;font-size: 32rpx;margin-top: 20rpx;margin-bottom: 20rpx;">'
|
||||
);
|
||||
this.yszcText.content = this.yszcText.content.replace(
|
||||
/<\/h5>/g,
|
||||
"</view>"
|
||||
);
|
||||
})
|
||||
.catch((e) => {
|
||||
console.log(e, "e");
|
||||
});
|
||||
this.$http
|
||||
.post("sys/agreement/getUserDetail")
|
||||
.then((res) => {
|
||||
this.yhxyText = res.user;
|
||||
this.yhxyText.content = this.yhxyText.content.replace(
|
||||
/<h5>/g,
|
||||
'<view style="font-weight: bold;font-size: 32rpx;margin-top: 20rpx;margin-bottom: 20rpx;">'
|
||||
);
|
||||
this.yhxyText.content = this.yhxyText.content.replace(
|
||||
/<\/h5>/g,
|
||||
"</view>"
|
||||
);
|
||||
})
|
||||
.catch((e) => {
|
||||
console.log(e, "e");
|
||||
});
|
||||
async getSettlement(id,type) {
|
||||
//隐私策略
|
||||
var data = await this.$commonJS.getAgreement(id);
|
||||
if (data.content) {
|
||||
data.content = data.content.replace(
|
||||
/<h5>/g,
|
||||
'<view style="font-weight: bold;font-size: 32rpx;margin-top: 20rpx;margin-bottom: 20rpx;">'
|
||||
);
|
||||
data.content = data.content.replace(
|
||||
/<\/h5>/g,
|
||||
"</view>"
|
||||
);
|
||||
}
|
||||
if(type=='yszcText'){
|
||||
this.yszcText=data
|
||||
}
|
||||
if(type=='yhxyText'){
|
||||
this.yhxyText=data
|
||||
}
|
||||
|
||||
|
||||
//用户协议
|
||||
// this.yhxyText = await this.$commonJS.getAgreement(108);
|
||||
// if (this.yhxyText) {
|
||||
// this.yhxyText.content = this.yhxyText.content.replace(
|
||||
// /<h5>/g,
|
||||
// '<view style="font-weight: bold;font-size: 32rpx;margin-top: 20rpx;margin-bottom: 20rpx;">'
|
||||
// );
|
||||
// this.yhxyText.content = this.yhxyText.content.replace(
|
||||
// /<\/h5>/g,
|
||||
// "</view>"
|
||||
// );
|
||||
// }
|
||||
},
|
||||
|
||||
quChange(e) {
|
||||
@@ -599,19 +643,21 @@ export default {
|
||||
duration: 1000,
|
||||
});
|
||||
setTimeout(() => {
|
||||
uni.switchTab({
|
||||
url: "/pages/homePage/index/index",
|
||||
uni.navigateTo({
|
||||
url: "/pages/curriculum/order/curriculum/videoDetail",
|
||||
});
|
||||
}, 1000);
|
||||
});
|
||||
return;
|
||||
},
|
||||
// 手机密码登录
|
||||
onSubmit() {
|
||||
this.loginForm = {
|
||||
phoneEmail: "2227572976@qq.com",
|
||||
password: "zm123456",
|
||||
};
|
||||
async onSubmit() {
|
||||
// this.loginForm = {
|
||||
// // phoneEmail: "2227572976@qq.com",
|
||||
// // password: "zm123456",
|
||||
// phoneEmail: "13110039505",
|
||||
// password: "123456",
|
||||
// };
|
||||
|
||||
if (!this.agree) {
|
||||
this.$commonJS.showToast("请先同意《用户协议》和《隐私协议》");
|
||||
@@ -657,23 +703,30 @@ export default {
|
||||
}
|
||||
httpData.code = this.loginForm.code;
|
||||
|
||||
this.$http.get(this.urlList.registerOrLogin, httpData).then((res) => {
|
||||
console.log("res.userInfo at line 593:", res.token);
|
||||
res.userInfo.token = res.token.token;
|
||||
this.setUserInfo(res.userInfo);
|
||||
await this.$http
|
||||
.get(this.urlList.registerOrLogin, httpData)
|
||||
.then(async (res) => {
|
||||
console.log("res.userInfo at line 593:", res.token);
|
||||
res.userInfo.token = res.token.token;
|
||||
await this.setUserInfo(res.userInfo);
|
||||
|
||||
// socket.init();
|
||||
uni.showToast({
|
||||
title: "登录成功",
|
||||
duration: 1000,
|
||||
});
|
||||
|
||||
setTimeout(() => {
|
||||
uni.switchTab({
|
||||
url: "/pages/homePage/index/index",
|
||||
// socket.init();
|
||||
uni.showToast({
|
||||
title: "登录成功",
|
||||
});
|
||||
}, 1000);
|
||||
});
|
||||
|
||||
setTimeout(() => {
|
||||
uni.setStorageSync('isJump', 'false')
|
||||
uni.switchTab({
|
||||
url: "/pages/homePage/index/index",
|
||||
success: function () {
|
||||
let page = getCurrentPages()[0];
|
||||
console.log(page);
|
||||
page.$vm.requestAll();
|
||||
},
|
||||
});
|
||||
}, 100);
|
||||
});
|
||||
} else {
|
||||
if (!this.loginForm.phoneEmail) {
|
||||
uni.showToast({
|
||||
@@ -692,21 +745,27 @@ export default {
|
||||
// httpData.password = md5(this.password);
|
||||
httpData.password = this.loginForm.password;
|
||||
httpData.phone = this.loginForm.phoneEmail;
|
||||
this.$http.post(this.urlList.passwordLogin, httpData).then((res) => {
|
||||
console.log("res.userInfo at line 593:", res.token);
|
||||
res.userInfo.token = res.token.token;
|
||||
this.setUserInfo(res.userInfo);
|
||||
// socket.init();
|
||||
uni.showToast({
|
||||
title: "登录成功",
|
||||
duration: 1000,
|
||||
});
|
||||
setTimeout(() => {
|
||||
uni.switchTab({
|
||||
url: "/pages/homePage/index/index",
|
||||
await this.$http
|
||||
.post(this.urlList.passwordLogin, httpData)
|
||||
.then(async (res) => {
|
||||
console.log("res.userInfo at line 593:", res.token);
|
||||
res.userInfo.token = res.token.token;
|
||||
await this.setUserInfo(res.userInfo);
|
||||
// socket.init();
|
||||
uni.showToast({
|
||||
title: "登录成功",
|
||||
});
|
||||
}, 1000);
|
||||
});
|
||||
setTimeout(() => {
|
||||
uni.switchTab({
|
||||
url: "/pages/homePage/index/index",
|
||||
success: function () {
|
||||
let page = getCurrentPages()[0];
|
||||
console.log(page);
|
||||
page.$vm.requestAll();
|
||||
},
|
||||
});
|
||||
}, 500);
|
||||
});
|
||||
}
|
||||
},
|
||||
|
||||
@@ -735,13 +794,17 @@ export default {
|
||||
this.setUserInfo(res.userInfo);
|
||||
uni.showToast({
|
||||
title: "登录成功",
|
||||
duration: 1000,
|
||||
});
|
||||
setTimeout(() => {
|
||||
uni.switchTab({
|
||||
url: "/pages/homePage/index/index",
|
||||
success: function () {
|
||||
let page = getCurrentPages()[0];
|
||||
console.log(page);
|
||||
page.$vm.requestAll();
|
||||
},
|
||||
});
|
||||
}, 1000);
|
||||
}, 500);
|
||||
} else {
|
||||
setTimeout(() => {
|
||||
uni.navigateTo({
|
||||
@@ -821,13 +884,17 @@ export default {
|
||||
socket.init();
|
||||
uni.showToast({
|
||||
title: "登录成功",
|
||||
duration: 2000,
|
||||
});
|
||||
setTimeout(() => {
|
||||
uni.switchTab({
|
||||
url: "/pages/home/home",
|
||||
url: "/pages/homePage/index/index",
|
||||
success: function () {
|
||||
let page = getCurrentPages()[0];
|
||||
console.log(page);
|
||||
page.$vm.requestAll();
|
||||
},
|
||||
});
|
||||
}, 2000);
|
||||
}, 500);
|
||||
} else {
|
||||
uni.showModal({
|
||||
title: "提示",
|
||||
@@ -884,9 +951,14 @@ export default {
|
||||
});
|
||||
setTimeout(() => {
|
||||
uni.switchTab({
|
||||
url: "/pages/home/home",
|
||||
url: "/pages/homePage/index/index",
|
||||
success: function () {
|
||||
let page = getCurrentPages()[0];
|
||||
console.log(page);
|
||||
page.$vm.requestAll();
|
||||
},
|
||||
});
|
||||
}, 2000);
|
||||
}, 500);
|
||||
} else {
|
||||
uni.showModal({
|
||||
title: "提示",
|
||||
@@ -1078,7 +1150,7 @@ export default {
|
||||
|
||||
.input_tit {
|
||||
margin-top: 20rpx;
|
||||
font-size: 34rpx;
|
||||
font-size: 38rpx;
|
||||
font-weight: bold;
|
||||
color: #3ab3ae;
|
||||
}
|
||||
@@ -1182,17 +1254,17 @@ export default {
|
||||
}
|
||||
|
||||
.protocol_box {
|
||||
margin-top: 40rpx;
|
||||
margin-top: 60rpx;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
width: 100%;
|
||||
font-size: 28rpx;
|
||||
font-size: 30rpx;
|
||||
color: #333333;
|
||||
|
||||
.select {
|
||||
width: 36rpx;
|
||||
height: 36rpx;
|
||||
width: 40rpx;
|
||||
height: 40rpx;
|
||||
background-image: url("@/static/icon/ic_gender_unselected.png");
|
||||
background-position: center center;
|
||||
background-repeat: no-repeat;
|
||||
@@ -1334,8 +1406,8 @@ export default {
|
||||
}
|
||||
|
||||
.qie_huan {
|
||||
font-size: 26rpx;
|
||||
margin: 20rpx 0 0 0;
|
||||
font-size: 30rpx;
|
||||
margin: 40rpx 0 0 0;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
@@ -1348,8 +1420,8 @@ export default {
|
||||
.youKeL {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
margin: 30rpx 0 0 0;
|
||||
font-size: 26rpx;
|
||||
margin: 50rpx 0 0 0;
|
||||
font-size: 30rpx;
|
||||
color: #3ab3ae;
|
||||
|
||||
view {
|
||||
|
||||
Reference in New Issue
Block a user