21
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
zpc 2026-03-24 02:05:42 +08:00
parent 8f8353f17a
commit 5f5501dd0d
3 changed files with 20 additions and 3 deletions

View File

@ -654,6 +654,7 @@ public class AssessmentService : IAssessmentService
3 => "生成中",
4 => "已完成",
5 => "生成失败",
6 => "报告生成中",
_ => "未知"
};
}

View File

@ -735,6 +735,8 @@ public class OrderService : IOrderService
2 => "测评中",
3 => "测评生成中",
4 => "已测评",
5 => "生成失败",
6 => "报告生成中",
_ => GetOrderStatusText(orderStatus)
};
}
@ -755,6 +757,8 @@ public class OrderService : IOrderService
2 => "测评中",
3 => "生成中",
4 => "已完成",
5 => "生成失败",
6 => "报告生成中",
_ => "未知"
};
}

View File

@ -19,7 +19,9 @@ const ASSESSMENT_STATUS = {
PENDING: 1, //
TESTING: 2, //
GENERATING: 3, //
COMPLETED: 4 //
COMPLETED: 4, //
FAILED: 5, //
DATA_READY: 6 // PDF
}
//
@ -42,7 +44,9 @@ function getStatusClass(status) {
[ASSESSMENT_STATUS.PENDING]: 'status-pending',
[ASSESSMENT_STATUS.TESTING]: 'status-testing',
[ASSESSMENT_STATUS.GENERATING]: 'status-generating',
[ASSESSMENT_STATUS.COMPLETED]: 'status-completed'
[ASSESSMENT_STATUS.COMPLETED]: 'status-completed',
[ASSESSMENT_STATUS.FAILED]: 'status-failed',
[ASSESSMENT_STATUS.DATA_READY]: 'status-generating'
}
return classMap[status] || ''
}
@ -127,6 +131,14 @@ function viewResult(record) {
return
}
// PDF-
if (record.status === ASSESSMENT_STATUS.DATA_READY) {
uni.navigateTo({
url: `/pages/assessment/result/index?recordId=${record.id}`
})
return
}
// -
if (record.status === ASSESSMENT_STATUS.GENERATING) {
uni.showToast({
@ -197,7 +209,7 @@ onMounted(() => {
</view>
<!-- 卡片底部已完成显示查看报告 -->
<view class="card-footer" v-if="record.status === ASSESSMENT_STATUS.COMPLETED">
<view class="card-footer" v-if="record.status === ASSESSMENT_STATUS.COMPLETED || record.status === ASSESSMENT_STATUS.DATA_READY">
<view class="view-btn">
<text>查看报告</text>
<view class="arrow-icon"></view>