feat: 增加报告解读

master
xjs 2025-04-15 16:42:58 +08:00
parent a18be1e3be
commit 5d216ccf83
15 changed files with 90 additions and 66 deletions

View File

@ -33,7 +33,6 @@ const handleChildMessage = (event) => {
} }
onLoad((options) => { onLoad((options) => {
console.log(options)
if (options.id) { if (options.id) {
url.value += `&reportId=${options.id}` url.value += `&reportId=${options.id}`
} }

View File

@ -20,7 +20,7 @@
</template> </template>
</Navbar> </Navbar>
<view class="flex-1 overflow-auto pb-[30rpx] relative mt-[40rpx]"> <view class="flex-1 overflow-auto relative mt-[40rpx]">
<!-- 顶部卡片 --> <!-- 顶部卡片 -->
<view <view
class="flex flex-col pt-[32rpx] mx-[24rpx] bg-[#fff] px-[30rpx] pt-[30rpx] border-class" class="flex flex-col pt-[32rpx] mx-[24rpx] bg-[#fff] px-[30rpx] pt-[30rpx] border-class"
@ -34,10 +34,7 @@
<LineReport :echart-data="studyRecord.linChart" :description="studyRecord.description" /> <LineReport :echart-data="studyRecord.linChart" :description="studyRecord.description" />
<AbilityDimension :report-items="studyRecord.reportItems" /> <AbilityDimension :report-items="studyRecord.reportItems" />
<!-- 底部AI智能顾问 --> <!-- 底部AI智能顾问 -->
<!-- <view class="ai-assistant mt-[20rpx] mb-[10rpx] flex items-center justify-center"> <AiFooter :pageId="pageId" :pageType="pageType" />
<image src="" class="w-[32rpx] h-[32rpx] mr-[10rpx]"></image>
<text class="text-[#117CFC] text-[26rpx]">智能AI顾问</text>
</view> -->
</view> </view>
</view> </view>
</template> </template>
@ -45,6 +42,7 @@
import Navbar from '@/pages-evaluation-sub/components/navbar/Navbar.vue' import Navbar from '@/pages-evaluation-sub/components/navbar/Navbar.vue'
import LineReport from '../components/interestChart/LineReport.vue' import LineReport from '../components/interestChart/LineReport.vue'
import AbilityDimension from '../components/AbilityDimension.vue' import AbilityDimension from '../components/AbilityDimension.vue'
import AiFooter from '../components/AiFooter.vue'
import { getAbilityDimension } from '@/service/index/api' import { getAbilityDimension } from '@/service/index/api'

View File

@ -20,7 +20,7 @@
</template> </template>
</Navbar> </Navbar>
<view class="flex-1 overflow-auto pb-[30rpx] relative mt-[40rpx]"> <view class="flex-1 overflow-auto relative mt-[40rpx]">
<!-- 顶部卡片 --> <!-- 顶部卡片 -->
<view class="flex flex-col pt-[32rpx] px-[84rpx] h-[244rpx] mb-[-116rpx] font-700"> <view class="flex flex-col pt-[32rpx] px-[84rpx] h-[244rpx] mb-[-116rpx] font-700">
<image src="https://api.static.ycymedu.com/src/images/evaluate/bg.png" class="header-bg" /> <image src="https://api.static.ycymedu.com/src/images/evaluate/bg.png" class="header-bg" />
@ -37,10 +37,7 @@
/> />
<!-- 底部AI智能顾问 --> <!-- 底部AI智能顾问 -->
<!-- <view class="ai-assistant mt-[20rpx] mb-[10rpx] flex items-center justify-center"> <AiFooter :pageId="pageId" :pageType="pageType" />
<image src="" class="w-[32rpx] h-[32rpx] mr-[10rpx]"></image>
<text class="text-[#117CFC] text-[26rpx]">智能AI顾问</text>
</view> -->
</view> </view>
</view> </view>
</template> </template>
@ -48,7 +45,7 @@
import Navbar from '@/pages-evaluation-sub/components/navbar/Navbar.vue' import Navbar from '@/pages-evaluation-sub/components/navbar/Navbar.vue'
import CharacterChart from '../components/interestChart/CharacterChart.vue' import CharacterChart from '../components/interestChart/CharacterChart.vue'
import DependenciesChart from '../components/interestChart/DependenciesChart.vue' import DependenciesChart from '../components/interestChart/DependenciesChart.vue'
import AiFooter from '../components/AiFooter.vue'
import { getMBTIDimension } from '@/service/index/api' import { getMBTIDimension } from '@/service/index/api'
const pageType = ref(0) const pageType = ref(0)

View File

@ -38,20 +38,7 @@
<InterestingThings :tag="studyRecord.hTag" :description="studyRecord.description" /> <InterestingThings :tag="studyRecord.hTag" :description="studyRecord.description" />
<!-- 底部AI智能顾问 --> <!-- 底部AI智能顾问 -->
<!-- <view <AiFooter :pageId="pageId" :pageType="pageType" />
class="pt-[16rpx] px-[32rpx] mt-[20rpx] flex items-center justify-center bg-[#fff] pb-safe"
@click="toAiAssistant"
>
<view
class="rounded-[8rpx] border-[#1580FF] border-[2rpx] border-solid w-full pt-[22rpx] pb-[20rpx] flex items-center justify-center"
>
<image
src="https://api.static.ycymedu.com/images/btn-bottom.png"
class="w-[52rpx] h-[52rpx] mr-[10rpx]"
></image>
<text class="text-[#1580FF] text-[32rpx] font-700">智能AI顾问</text>
</view>
</view> -->
</view> </view>
</view> </view>
</template> </template>
@ -63,6 +50,7 @@ import IntroMajor from '../components/IntroMajor.vue'
import { getHollandDimensionInfo } from '@/service/index/api' import { getHollandDimensionInfo } from '@/service/index/api'
import InterestingThings from '../components/InterestingThings.vue' import InterestingThings from '../components/InterestingThings.vue'
import AiFooter from '../components/AiFooter.vue'
const pageType = ref(0) const pageType = ref(0)
const pageId = ref(0) const pageId = ref(0)
@ -73,12 +61,6 @@ const handleBack = () => {
const studyRecord = ref({ description: '', title: '', picCharts: {}, reportItems: [], hTag: '' }) const studyRecord = ref({ description: '', title: '', picCharts: {}, reportItems: [], hTag: '' })
const toAiAssistant = () => {
uni.navigateTo({
url: `/aiService-sub/index/index?id=${pageId.value}&type=${pageType.value}`,
})
}
onLoad((options) => { onLoad((options) => {
pageType.value = +options.type pageType.value = +options.type
pageId.value = options.id pageId.value = options.id

View File

@ -20,7 +20,7 @@
</template> </template>
</Navbar> </Navbar>
<view class="flex-1 overflow-auto pb-[30rpx] relative mt-[40rpx]"> <view class="flex-1 overflow-auto relative mt-[40rpx]">
<!-- 顶部卡片 --> <!-- 顶部卡片 -->
<view class="flex flex-col pt-[32rpx] px-[84rpx] h-[244rpx] mb-[-116rpx] font-700"> <view class="flex flex-col pt-[32rpx] px-[84rpx] h-[244rpx] mb-[-116rpx] font-700">
<image src="https://api.static.ycymedu.com/src/images/evaluate/bg.png" class="header-bg" /> <image src="https://api.static.ycymedu.com/src/images/evaluate/bg.png" class="header-bg" />
@ -30,10 +30,7 @@
<OpinionChart :pic-charts="studyRecord.picCharts" /> <OpinionChart :pic-charts="studyRecord.picCharts" />
<AbilityDimension :report-items="studyRecord.reportItems" /> <AbilityDimension :report-items="studyRecord.reportItems" />
<!-- 底部AI智能顾问 --> <!-- 底部AI智能顾问 -->
<!-- <view class="ai-assistant mt-[20rpx] mb-[10rpx] flex items-center justify-center"> <AiFooter :pageId="pageId" :pageType="pageType" />
<image src="" class="w-[32rpx] h-[32rpx] mr-[10rpx]"></image>
<text class="text-[#117CFC] text-[26rpx]">智能AI顾问</text>
</view> -->
</view> </view>
</view> </view>
</template> </template>
@ -41,6 +38,7 @@
import Navbar from '@/pages-evaluation-sub/components/navbar/Navbar.vue' import Navbar from '@/pages-evaluation-sub/components/navbar/Navbar.vue'
import OpinionChart from '../components/interestChart/OpinionChart.vue' import OpinionChart from '../components/interestChart/OpinionChart.vue'
import AbilityDimension from '../components/AbilityDimension.vue' import AbilityDimension from '../components/AbilityDimension.vue'
import AiFooter from '../components/AiFooter.vue'
import { getOpinionAbout } from '@/service/index/api' import { getOpinionAbout } from '@/service/index/api'

View File

@ -0,0 +1,36 @@
<template>
<!-- 底部AI智能顾问 -->
<view
class="pt-[16rpx] px-[32rpx] mt-[20rpx] flex items-center justify-center bg-[#fff] pb-safe"
@click="toAiAssistant"
>
<view
class="rounded-[8rpx] border-[#1580FF] border-[2rpx] border-solid w-full pt-[22rpx] pb-[20rpx] flex items-center justify-center"
>
<image
src="https://api.static.ycymedu.com/images/btn-bottom.png"
class="w-[52rpx] h-[52rpx] mr-[10rpx]"
></image>
<text class="text-[#1580FF] text-[32rpx] font-700">智能AI顾问</text>
</view>
</view>
</template>
<script setup lang="ts">
const props = defineProps({
pageId: {
type: Number,
default: 0,
},
pageType: {
type: Number,
default: 0,
},
})
const toAiAssistant = () => {
uni.navigateTo({
url: `/aiService-sub/index/index?id=${props.pageId}&type=${props.pageType}`,
})
}
</script>

View File

@ -20,12 +20,11 @@
</template> </template>
</Navbar> </Navbar>
<view class="flex-1 overflow-auto pb-safe relative mx-[24rpx]"> <view class="flex-1 overflow-auto relative">
<!-- 顶部卡片 --> <!-- 顶部卡片 -->
<view class="mt-[30rpx]"> <view class="mt-[30rpx] mx-[24rpx]">
<StatusCard /> <StatusCard />
</view> </view>
<view class="mt-[30rpx]"></view>
</view> </view>
</view> </view>
</template> </template>

View File

@ -20,9 +20,9 @@
</template> </template>
</Navbar> </Navbar>
<view class="flex-1 overflow-auto pb-safe relative mx-[24rpx]"> <view class="flex-1 overflow-auto relative">
<!-- 顶部卡片 --> <!-- 顶部卡片 -->
<view class="mt-[30rpx]"> <view class="mt-[30rpx] mx-[24rpx]">
<StatusCard <StatusCard
:score="score" :score="score"
:rules="anxietyRules" :rules="anxietyRules"
@ -32,9 +32,12 @@
:tagName="studyRecord.tagName" :tagName="studyRecord.tagName"
/> />
</view> </view>
<view class="mt-[30rpx]"> <view class="mt-[30rpx] mx-[24rpx]">
<SuggestionCard /> <SuggestionCard />
</view> </view>
<!-- 底部AI智能顾问 -->
<AiFooter :pageId="pageId" :pageType="pageType" />
</view> </view>
</view> </view>
</template> </template>
@ -42,7 +45,7 @@
import Navbar from '@/pages-evaluation-sub/components/navbar/Navbar.vue' import Navbar from '@/pages-evaluation-sub/components/navbar/Navbar.vue'
import StatusCard from '../components/StatusCard.vue' import StatusCard from '../components/StatusCard.vue'
import SuggestionCard from '../components/SuggestionCard.vue' import SuggestionCard from '../components/SuggestionCard.vue'
import AiFooter from '../components/AiFooter.vue'
import { getCustomScaleExplains } from '@/service/index/api' import { getCustomScaleExplains } from '@/service/index/api'
const pageType = ref(0) const pageType = ref(0)

View File

@ -20,9 +20,9 @@
</template> </template>
</Navbar> </Navbar>
<view class="flex-1 overflow-auto pb-safe relative mx-[24rpx]"> <view class="flex-1 overflow-auto relative">
<!-- 顶部卡片 --> <!-- 顶部卡片 -->
<view class="mt-[30rpx]"> <view class="mt-[30rpx] mx-[24rpx]">
<StatusCard <StatusCard
:score="score" :score="score"
:rules="depressionRules" :rules="depressionRules"
@ -32,9 +32,12 @@
:tagName="studyRecord.tagName" :tagName="studyRecord.tagName"
/> />
</view> </view>
<view class="mt-[30rpx]"> <view class="mt-[30rpx] mx-[24rpx]">
<SuggestionCard /> <SuggestionCard />
</view> </view>
<!-- 底部AI智能顾问 -->
<AiFooter :pageId="pageId" :pageType="pageType" />
</view> </view>
</view> </view>
</template> </template>
@ -42,9 +45,8 @@
import Navbar from '@/pages-evaluation-sub/components/navbar/Navbar.vue' import Navbar from '@/pages-evaluation-sub/components/navbar/Navbar.vue'
import StatusCard from '../components/StatusCard.vue' import StatusCard from '../components/StatusCard.vue'
import SuggestionCard from '../components/SuggestionCard.vue' import SuggestionCard from '../components/SuggestionCard.vue'
import { getCustomScaleExplains } from '@/service/index/api' import { getCustomScaleExplains } from '@/service/index/api'
import AiFooter from '../components/AiFooter.vue'
const pageType = ref(0) const pageType = ref(0)
const pageId = ref(0) const pageId = ref(0)

View File

@ -20,9 +20,9 @@
</template> </template>
</Navbar> </Navbar>
<view class="flex-1 overflow-auto pb-safe relative mx-[24rpx]"> <view class="flex-1 overflow-auto relative">
<!-- 顶部卡片 --> <!-- 顶部卡片 -->
<view class="mt-[60rpx]"> <view class="mt-[60rpx] mx-[24rpx]">
<StatusCard <StatusCard
:score="score" :score="score"
:rules="anxietyRules" :rules="anxietyRules"
@ -32,7 +32,7 @@
:tagName="studyRecord.tagName" :tagName="studyRecord.tagName"
/> />
</view> </view>
<view> <view class="mx-[24rpx]">
<LearnSkillSuggestion <LearnSkillSuggestion
v-for="(item, index) in suggestions" v-for="(item, index) in suggestions"
:key="index" :key="index"
@ -40,6 +40,9 @@
:title="item.title" :title="item.title"
></LearnSkillSuggestion> ></LearnSkillSuggestion>
</view> </view>
<!-- 底部AI智能顾问 -->
<AiFooter :pageId="pageId" :pageType="pageType" />
</view> </view>
</view> </view>
</template> </template>
@ -47,7 +50,7 @@
import Navbar from '@/pages-evaluation-sub/components/navbar/Navbar.vue' import Navbar from '@/pages-evaluation-sub/components/navbar/Navbar.vue'
import StatusCard from '../components/StatusCard.vue' import StatusCard from '../components/StatusCard.vue'
import LearnSkillSuggestion from '../components/LearnSkillSuggestion.vue' import LearnSkillSuggestion from '../components/LearnSkillSuggestion.vue'
import AiFooter from '../components/AiFooter.vue'
import { getCustomScaleExplains } from '@/service/index/api' import { getCustomScaleExplains } from '@/service/index/api'
const pageType = ref(0) const pageType = ref(0)

View File

@ -20,12 +20,12 @@
</template> </template>
</Navbar> </Navbar>
<view class="flex-1 overflow-auto pb-safe relative mx-[24rpx]"> <view class="flex-1 overflow-auto relative">
<!-- 顶部卡片 --> <!-- 顶部卡片 -->
<view class="mt-[60rpx]"> <view class="mt-[60rpx] mx-[24rpx]">
<LearnStyleChart :pic-data="chartData" :parsing="parsing" /> <LearnStyleChart :pic-data="chartData" :parsing="parsing" />
</view> </view>
<view> <view class="mx-[24rpx]">
<LearnStudySuggestion <LearnStudySuggestion
:title="item.name" :title="item.name"
:item="item" :item="item"
@ -33,6 +33,9 @@
:key="index" :key="index"
/> />
</view> </view>
<!-- 底部AI智能顾问 -->
<AiFooter :pageId="pageId" :pageType="pageType" />
</view> </view>
</view> </view>
</template> </template>
@ -40,7 +43,7 @@
import Navbar from '@/pages-evaluation-sub/components/navbar/Navbar.vue' import Navbar from '@/pages-evaluation-sub/components/navbar/Navbar.vue'
import LearnStyleChart from '../components/studyChart/LearnStyleChart.vue' import LearnStyleChart from '../components/studyChart/LearnStyleChart.vue'
import LearnStudySuggestion from '../components/LearnStudySuggestion.vue' import LearnStudySuggestion from '../components/LearnStudySuggestion.vue'
import AiFooter from '../components/AiFooter.vue'
import { getCustomScaleExplains } from '@/service/index/api' import { getCustomScaleExplains } from '@/service/index/api'
const pageType = ref(0) const pageType = ref(0)

View File

@ -20,9 +20,9 @@
</template> </template>
</Navbar> </Navbar>
<view class="flex-1 overflow-auto pb-safe relative mx-[24rpx]"> <view class="flex-1 overflow-auto relative">
<!-- 顶部卡片 --> <!-- 顶部卡片 -->
<view class="mt-[60rpx]"> <view class="mt-[60rpx] mx-[24rpx]">
<StatusCard <StatusCard
:score="score" :score="score"
:rules="anxietyRules" :rules="anxietyRules"
@ -32,7 +32,7 @@
:tagName="studyRecord.tagName" :tagName="studyRecord.tagName"
/> />
</view> </view>
<view> <view class="mx-[24rpx]">
<LearnSkillSuggestion <LearnSkillSuggestion
v-for="(item, index) in suggestions" v-for="(item, index) in suggestions"
:key="index" :key="index"
@ -40,6 +40,9 @@
:title="item.title" :title="item.title"
></LearnSkillSuggestion> ></LearnSkillSuggestion>
</view> </view>
<!-- 底部AI智能顾问 -->
<AiFooter :pageId="pageId" :pageType="pageType" />
</view> </view>
</view> </view>
</template> </template>
@ -47,7 +50,7 @@
import Navbar from '@/pages-evaluation-sub/components/navbar/Navbar.vue' import Navbar from '@/pages-evaluation-sub/components/navbar/Navbar.vue'
import StatusCard from '../components/StatusCard.vue' import StatusCard from '../components/StatusCard.vue'
import LearnSkillSuggestion from '../components/LearnSkillSuggestion.vue' import LearnSkillSuggestion from '../components/LearnSkillSuggestion.vue'
import AiFooter from '../components/AiFooter.vue'
import { getCustomScaleExplains } from '@/service/index/api' import { getCustomScaleExplains } from '@/service/index/api'
const pageType = ref(0) const pageType = ref(0)

View File

@ -248,14 +248,14 @@ const getNvueHwight = (type) => {
// - // -
onMounted(() => { onMounted(() => {
if (!collapseContext) { if (!collapseContext) {
console.error('找不到折叠面板父组件上下文!') // console.error('!')
return return
} }
// nameSync // nameSync
nameSync.value = props.name !== '' ? props.name.toString() : `${collapseContext.childrens.length}` nameSync.value = props.name !== '' ? props.name.toString() : `${collapseContext.childrens.length}`
console.log('折叠项挂载:', nameSync.value) // console.log(':', nameSync.value)
// - // -
collapseContext.register({ collapseContext.register({
@ -277,9 +277,9 @@ onMounted(() => {
nextTick(() => { nextTick(() => {
if (collapseContext.getActiveNames) { if (collapseContext.getActiveNames) {
const activeNames = collapseContext.getActiveNames() const activeNames = collapseContext.getActiveNames()
console.log('当前活动项:', activeNames, '本项:', nameSync.value) // console.log(':', activeNames, ':', nameSync.value)
if (activeNames.includes(nameSync.value.toString())) { if (activeNames.includes(nameSync.value.toString())) {
console.log('默认展开:', nameSync.value) // console.log(':', nameSync.value)
isOpen.value = true isOpen.value = true
// //
init() init()

View File

@ -308,6 +308,7 @@ const handleSubmit = () => {
position: relative; position: relative;
display: flex; display: flex;
flex-direction: column; flex-direction: column;
padding-bottom: calc(20rpx + constant(safe-area-inset-bottom));
padding-bottom: calc(env(safe-area-inset-bottom) + 20rpx); padding-bottom: calc(env(safe-area-inset-bottom) + 20rpx);
// safe-area-inset-bottom 0 padding-bottom 20rpx // safe-area-inset-bottom 0 padding-bottom 20rpx

View File

@ -7,7 +7,7 @@
</route> </route>
<template> <template>
<scroll-view scroll-y class="pb-safe bg-[#f8f8f8] h-screen"> <scroll-view scroll-y class="bg-[#f8f8f8] h-screen">
<view class="px-[32rpx] mt-[32rpx] flex flex-col gap-[16rpx]"> <view class="px-[32rpx] mt-[32rpx] flex flex-col gap-[16rpx]">
<view <view
v-for="(item, index) in list" v-for="(item, index) in list"