Browse Source

Merge remote-tracking branch 'origin/dev_czc' into dev

master
congzc 1 year ago
parent
commit
096a3fb11d
2 changed files with 19 additions and 4 deletions
  1. +16
    -2
      src/pages/login/index.vue
  2. +3
    -2
      src/pages/uploadPhoto/uploadPhoto.vue

+ 16
- 2
src/pages/login/index.vue View File

@@ -20,6 +20,16 @@
</view>
<view class="bottomBox">
<button
v-if="!checkboxValue[0]"
class="bottomBtn"
type="default"
id="getPhoneNumber"
@click="toCreate"
>
开始制作我的数字分身
</button>
<button
v-if="checkboxValue[0]"
class="bottomBtn"
open-type="getPhoneNumber"
type="default"
@@ -32,7 +42,7 @@
<u-checkbox-group
v-model="checkboxValue"
placement="row"
@change="changed"
@change="changedCheckbox"
>
<u-checkbox
labelColor="white"
@@ -75,6 +85,9 @@ const checkboxList = ref([
name: "同意智像相机用户使用协议",
},
]);
function changedCheckbox(e) {
console.log(e);
}

async function getphonenumber(e) {
console.log(e);
@@ -112,6 +125,7 @@ async function getphonenumber(e) {
}

async function toCreate(e) {
console.log();
if (checkboxValue.value[0]) {
// await handleLogin();
await getphonenumber(e);
@@ -121,7 +135,7 @@ async function toCreate(e) {
content: "同意慧图相机用户使用协议?",
success: function (res) {
if (res.confirm) {
checkboxValue.value[0] = true;
checkboxValue.value = ["同意智像相机用户使用协议"];
// handleLogin();
getphonenumber(e);
} else if (res.cancel) {


+ 3
- 2
src/pages/uploadPhoto/uploadPhoto.vue View File

@@ -183,6 +183,7 @@ async function toCloseStyle() {
title: "请先上传图片",
icon: "none",
});
chooseImage();
return;
}
uploadState.value = 3;
@@ -263,7 +264,7 @@ async function toCloseStyle() {
}
//#endregion ---------------------
//#region 页面传参
//#region 页面初始化
onLoad((options) => {
// showImgUrl.value = userInfoModulesPinia.myAvatar;
// 微信登录授权
@@ -286,7 +287,7 @@ onLoad((options) => {
const res2 = await loginApi(data);
userInfoModulesPinia.openId = res2.data.openId;
if (res2.data.token) {
userInfoModulesPinia.token = res2.data.token;
// userInfoModulesPinia.token = res2.data.token;
console.log(userInfoModulesPinia.openId, "获取openid");
// 获取头像和金币
const res3 = await findImageApi();


Loading…
Cancel
Save