JLBA202505130001_关于吉林银行新建AI智能培训系统的需求_修改关键词知识点样式

This commit is contained in:
田岩
2026-01-15 14:49:09 +08:00
parent a56957db7e
commit 0da6bb0d1f
9 changed files with 91 additions and 51 deletions
+3 -3
View File
@@ -4,10 +4,10 @@ ENV = 'development'
#VITE_APP_BASE_API_Url = 'https://aits.jlbank.com.cn:7001'
#VITE_APP_BASE_API_Url = 'https://aits.jlbank.com.cn:7002'
#VITE_APP_BASE_API_Url = 'https://aitstest.jlbank.com.cn:7003'
VITE_APP_BASE_API_Url = 'https://aitstest.jlbank.com.cn:7002'
# VITE_APP_BASE_API_Url = 'https://aitstest.jlbank.com.cn:7002'
# VITE_APP_BASE_API_Url = 'http://192.168.247.200'
@@ -21,7 +21,7 @@ ENV = 'development'
# sit
VITE_APP_BASE_API_Url = 'http://25.18.122.91:9786'
#VITE_APP_BASE_API_Url = 'http://25.18.122.91:9786'
# UAT
+41 -35
View File
@@ -7,15 +7,17 @@
<image :src="select_status_icon" class="img"></image>
</view>
</view>
<view class="dimension-line" v-for="item in evalSettingVos">
<text class="tr">{{ item.gradeDimens }}</text>
<text class="td">{{ item.anlyGrade }}</text>
<view class="dimension-max" v-for="(item,index) in evalSettingVos">
<view class="dimension-div">
<image class="icon-img" :src="index % 2 === 1 ?li2:li1" mode=""></image>
<text class="tr">{{ item.gradeDimens }}</text>
<text class="td">{{ item.anlyGrade }}</text>
</view>
<view class="your_answer" v-if="item.dimensCode === '01'">
<rich-text v-if="missingKeywords.length !== keywordsLength" :nodes="highlightedText" class="content" />
<rich-text v-if="missingKeywords.length !== keywordsLength" :nodes="highlightedText" class="content" />
<view class="mt-10" v-if="missingKeywords.length">
<text class="">未命中</text>
<text v-for="(keyword, index) in missingKeywords" :key="index" class="miss-keyword-item">
<!-- 关键词红色 -->
<text class="keyword-text">{{ keyword }}</text>
<text class="separator" v-if="index < missingKeywords.length - 1"></text>
</text>
@@ -28,7 +30,8 @@
<script setup>
import { ref, reactive, onMounted, nextTick, computed, watch } from 'vue';
import { optionErrorIcon, optionSuccessIcon } from '@/common/imgSvg';
import li1 from '@/static/images/examination/li-1.png'
import li2 from '@/static/images/examination/li-2.png'
const emit = defineEmits(['click_option']);
const props = defineProps({
value: {
@@ -56,7 +59,7 @@
return optionErrorIcon();
}
});
const keywords = computed(() => {
if (!props.value?.relKeyword) return [];
return props.value.relKeyword.split(/[,、/]/).map((key) => key.trim());
@@ -129,7 +132,7 @@
if (!props.anserResult) {
return [];
}
// 步骤1:按顿号拆分关键词组
const keywordGroups = relKeyword.split('、');
const missing = [];
@@ -138,7 +141,7 @@
// 拆分同关键词的不同说法(/ 分隔)
const keywordVariants = group.split('/');
let isFound = false;
// 检查答案中是否包含任意一种说法
for (const variant of keywordVariants) {
// 可选:增加 trim() 忽略首尾空格,提升匹配容错
@@ -147,13 +150,13 @@
break;
}
}
// 未找到则加入缺失列表
if (isFound) {
missing.push(group);
}
});
return missing;
});
const click_option = () => {
@@ -167,17 +170,17 @@
}
.analysis_div {
:deep(.highlight) {
color: #15b859;
color: #333333;
}
}
.success {
background-color: #e7f8ed;
background-color: #f5f5f5;
.td {
color: #15b859;
}
}
.error {
background-color: #fce8e9;
background-color: #f5f5f5;
.td {
color: #f5212d;
}
@@ -188,19 +191,19 @@
text-decoration: underline;
}
}
.hit-keyword-item{
.hit-keyword-item {
.keyword-text {
color: #15b859;
text-decoration: underline;
}
}
.miss-keyword-item{
.miss-keyword-item {
.keyword-text {
color: #d70c18;
text-decoration: underline;
color: #666666;
// text-decoration: underline;
}
}
.separator {
}
.analysis_div {
@@ -212,24 +215,26 @@
margin: 12rpx 0;
position: relative;
}
.dimension-line {
.dimension-max {
// margin: 12rpx 0;
// position: relative;
// padding-left: 1.5em;
// display: flex;
// align-items: center;
}
.dimension-div {
margin: 12rpx 0;
position: relative;
padding-left: 1.5em;
}
.dimension-line::before {
content: '';
position: absolute;
left: 0.5rem; /* 对齐padding-left的起始位置 */
top: 0.5rem;
// transform: translateY(-50%);
width: 16rpx; /* 圆点大小(默认是4px左右,调大到8px) */
height: 16rpx; /* 和宽度一致,保证圆形 */
border-radius: 50%; /* 圆形 */
background-color: #333; /* 圆点颜色,可自定义 */
// padding-left: 48rpx;
display: flex;
align-items: center;
}
.icon-img {
width: 28rpx;
height: 28rpx;
margin-right: 14rpx;
}
.tr {
font-weight: 600;
font-size: 30rpx;
@@ -240,9 +245,10 @@
font-size: 30rpx;
}
.your_answer {
padding-left: 42rpx;
font-weight: 500;
font-size: 30rpx;
color: #333333;
font-size: 26rpx;
color: #666666;
line-height: 46rpx;
text-align: left;
margin-top: 12rpx;
@@ -59,7 +59,7 @@
line-height: 48rpx;
text-align: left;
:deep(.highlight) {
color: #15b859;
color: #333333;
text-decoration: underline;
}
}
+3 -7
View File
@@ -141,7 +141,7 @@
import { markIcon, feedbackIcon } from '@/common/imgSvg';
import { SUBJECT_TYPE } from '@/enum.js';
import common from '@/common/common';
import {ANSWER_METHOD_MAP} from '@/enum'
// 多选的确定按钮的样式
const customStyle = {
borderRadius: '16rpx',
@@ -149,12 +149,8 @@
backgroundColor: '#0066FF',
border: '1rpx solid rgb(12, 123, 245)'
};
const answerMethodMap = {
'01': '不限制回答方式',
'02': '仅文字回答',
'03': '仅语音回答'
};
const answerMethod = computed(() => answerMethodMap[props.item?.answerMethod || ''] || '');
const answerMethod = computed(() => ANSWER_METHOD_MAP[props.item?.answerMethod || ''] || '');
const emit = defineEmits(['subject_click', 'update:modelValue']);
const props = defineProps({
modelValue: {
+8
View File
@@ -32,6 +32,14 @@ export const SUBJECT_TYPE = [{
label: "问答题",
}
]
// 回答方式
export const ANSWER_METHOD_MAP = {
'01': '不限制回答方式',
'02': '仅文字回答',
'03': '仅语音回答'
};
export const defaultAvatar = '/static/images/me/default_user_avatar.png'
export const defaultAnonymousAvatar = '/static/images/competition/competition_default_avatar.png'
export const styleButton = {
@@ -14,6 +14,7 @@
<view class="fz-30 fw-600 mb-8">更新时间</view>
<view class="fz-30 fw-400 color-666">{{ (modelValue.mtTime || '').substr(0, 16) }}</view>
</view>
<view class="info-bottom">
<view class="bottom-left">
<view class="mb-64">
@@ -37,10 +38,14 @@
<image src="/src/static/images/courseDetail/ditu.png" class="right-img" mode="widthFix"></image>
</view>
</view>
<view class="info-middle font_pf">
<view class="fz-30 fw-600 mb-8">回答方式</view>
<view class="fz-30 fw-400 color-666">{{answerMethod}}</view>
</view>
<view class="mb-64">
<view class="fz-30 font_pf fw-600 mb-4">课程核心</view>
<view class="examination_core color-666">
{{ modelValue.crsCore }}
{{ modelValue.crsCore || '无' }}
</view>
</view>
<view class="mb-64 file-items" v-if="(modelValue.fileList || []).length>0">
@@ -53,12 +58,16 @@
</template>
<script setup>
import {computed} from 'vue'
import {
previewFileFnc
} from '@/common/common'
const props = defineProps({
modelValue: Object
});
import {ANSWER_METHOD_MAP} from '@/enum.js'
const answerMethod = computed(() => ANSWER_METHOD_MAP[props.item?.answerMethod || ''] || ANSWER_METHOD_MAP['01']);
const previewFile = info => {
previewFileFnc({
fileId: info.fileId,
+25 -4
View File
@@ -31,13 +31,16 @@
<view class="line-progress-div">
<view class="text-1">{{ form.styParaGraphNum || 0 }}</view>
<uv-line-progress
<view class="progress-div">
<view class="progress-line"></view>
</view>
<!-- <uv-line-progress
:percentage="progress"
:showText="false"
activeColor="#0066FF"
inactiveColor="#D9DEE8"
:height="8"
></uv-line-progress>
></uv-line-progress> -->
<view class="text-2">{{ form.pgrphNum || 0 }}</view>
</view>
@@ -143,9 +146,9 @@
const progress = computed(() => {
// 计算进度百分比(保留两位小数)
const total = form.value.pgrphNum;
if (total === 0) return 0;
if (total === 0) return '0%';
const completed = form.value.styParaGraphNum;
return Math.min(Math.round((completed / total) * 10000) / 100, 100);
return Math.min(Math.round((completed / total) * 10000) / 100, 100)+'%';
});
const tabSwitch = (item) => {
tabAct.value = item.index;
@@ -557,6 +560,24 @@
font-size: 30rpx;
margin: 0 16rpx;
}
.progress-div{
position: relative;
background-color: #D9DEE8;
width: 100%;
height: 16rpx;
border-radius: 10rpx;
overflow: hidden;
.progress-line{
position: absolute;
top: 0;
left: 0;
background-color: #0066FF;
// width: 100%;
width: v-bind(progress);
height: 100%;
border-radius: 10rpx;
}
}
}
.learn {
color: #1dd17a;
Binary file not shown.

After

Width:  |  Height:  |  Size: 855 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 KiB