feat: 增加豆包请求接口
This commit is contained in:
@@ -8,6 +8,7 @@ const props = defineProps({
|
||||
default: '黄一白',
|
||||
},
|
||||
});
|
||||
|
||||
const json = ref( [
|
||||
{
|
||||
type: '0',
|
||||
@@ -34,25 +35,25 @@ const json = ref( [
|
||||
value: '黄黑皮'
|
||||
},
|
||||
])
|
||||
|
||||
|
||||
watch(
|
||||
() => props.skinColor,
|
||||
(newVal) => {
|
||||
// console.log(json.value.find(item => item.value === newVal), '22');
|
||||
if(!json.value.find(item => item.value === newVal)) {
|
||||
// alert(`当前接口返回肤色与UI不一致${newVal}`)
|
||||
}
|
||||
|
||||
json.value = json.value.map(item => ({...item, checked: item.value === newVal}));
|
||||
// console.log('json.value: ', json.value);
|
||||
},
|
||||
{deep: true, immediate: true}
|
||||
);
|
||||
|
||||
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<view class="container">
|
||||
肤色:
|
||||
<template v-for="item of json">
|
||||
<CheckBox :checked="item.checked">{{ item.value }}</CheckBox>
|
||||
</template>
|
||||
<CheckBox :checked="item.checked" :key="index" v-for="(item, index) in json">{{ item.value }}</CheckBox>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
|
||||
@@ -18,6 +18,8 @@ const props = defineProps({
|
||||
},
|
||||
});
|
||||
|
||||
console.log('geneticStyle -------------------------------------', props.gender)
|
||||
|
||||
const styleTypeDesc = ref("");
|
||||
const styleTypeJson = ref();
|
||||
const showPreview = ref(false);
|
||||
@@ -63,21 +65,21 @@ const closePreview = (e) => {
|
||||
</view>
|
||||
</view>
|
||||
<view class="pic-container">
|
||||
<image
|
||||
v-for="(pic, index) in picList"
|
||||
:key="index"
|
||||
:src="pic"
|
||||
<image
|
||||
v-for="(pic, index) in picList"
|
||||
:key="index"
|
||||
:src="pic"
|
||||
class="pic"
|
||||
mode="aspectFill"
|
||||
@click="previewImage(pic)"
|
||||
></image>
|
||||
</view>
|
||||
|
||||
|
||||
<!-- 图片预览遮罩层 -->
|
||||
<view v-if="showPreview" class="preview-mask" @click="closePreview">
|
||||
<view class="preview-container" @click.stop>
|
||||
<image
|
||||
:src="currentPreviewImage"
|
||||
<image
|
||||
:src="currentPreviewImage"
|
||||
class="preview-image"
|
||||
mode="widthFix"
|
||||
@click="closePreview"
|
||||
|
||||
@@ -20,7 +20,7 @@
|
||||
<view class="info-main">
|
||||
<view class="info-basic">
|
||||
<text class="gender">{{ userFaceInfo.sex }}</text>
|
||||
<text class="birthday">| {{ userFaceInfo.createTime }}</text>
|
||||
<text class="birthday">| {{ userFaceInfo.birthday }}</text>
|
||||
</view>
|
||||
<view class="info-desc">
|
||||
{{ userFaceInfo.feature }},
|
||||
@@ -63,17 +63,12 @@ const props = defineProps({
|
||||
},
|
||||
});
|
||||
|
||||
|
||||
// console.log('9999999999999999999999999', props.userFaceInfo)
|
||||
|
||||
|
||||
|
||||
const userFaceInfo = ref({});
|
||||
|
||||
watch(
|
||||
() => props.userFaceInfo,
|
||||
(newVal) => {
|
||||
console.log('newVal: xxxxxxxx', newVal);
|
||||
// console.log('newVal: xxxxxxxx', newVal);
|
||||
userFaceInfo.value = newVal;
|
||||
},
|
||||
{ deep: true, immediate: true }
|
||||
|
||||
Reference in New Issue
Block a user