|
|
@@ -0,0 +1,63 @@
|
|
|
+<template>
|
|
|
+ <div>
|
|
|
+ <a-typography-title :level="4">各级审核意见</a-typography-title>
|
|
|
+ <div v-for="sec in sections" :key="sec.key" class="mb-6">
|
|
|
+ <a-typography-text strong>{{ sec.title }}</a-typography-text>
|
|
|
+ <a-space class="mt-2 ml-2" wrap>
|
|
|
+ <a-radio-group
|
|
|
+ :value="currentForm[sec.opinionField]"
|
|
|
+ :disabled="readonly"
|
|
|
+ @update:value="(v: number) => updateField(sec.opinionField, v)"
|
|
|
+ >
|
|
|
+ <a-radio v-for="opt in opinionOptions" :key="opt.value" :value="opt.value">{{ opt.label }}</a-radio>
|
|
|
+ </a-radio-group>
|
|
|
+ </a-space>
|
|
|
+ <div class="mt-2 flex items-center gap-2">
|
|
|
+ <a-typography-text>评分:</a-typography-text>
|
|
|
+ <a-input-number
|
|
|
+ v-if="currentForm[sec.pointsField]"
|
|
|
+ :value="currentForm[sec.pointsField]"
|
|
|
+ :disabled="readonly"
|
|
|
+ :min="0"
|
|
|
+ :max="200"
|
|
|
+ placeholder="请输入评分"
|
|
|
+ @update:value="(v: number | null) => updateField(sec.pointsField, v ?? 0)"
|
|
|
+ />
|
|
|
+ <span v-else>(待审核填写)</span>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+</template>
|
|
|
+
|
|
|
+<script setup lang="ts">
|
|
|
+import type { SelfAssessmentDetail } from '@/api/collect/AssessmentContent';
|
|
|
+
|
|
|
+type OpinionField = 'ichUnit' | 'county' | 'district' | 'province';
|
|
|
+type PointsField = 'unitPoints' | 'countyPoints' | 'districtPoints' | 'provincePoints';
|
|
|
+
|
|
|
+const props = withDefaults(defineProps<{
|
|
|
+ currentForm: SelfAssessmentDetail;
|
|
|
+ readonly?: boolean;
|
|
|
+}>(), {
|
|
|
+ readonly: true,
|
|
|
+});
|
|
|
+
|
|
|
+const opinionOptions = [
|
|
|
+ { label: '优秀', value: 1 },
|
|
|
+ { label: '合格', value: 2 },
|
|
|
+ { label: '不合格', value: 3 },
|
|
|
+ { label: '丧失传承能力', value: 4 },
|
|
|
+ { label: '取消资格', value: 5 },
|
|
|
+];
|
|
|
+
|
|
|
+const sections: { key: string; title: string; opinionField: OpinionField; pointsField: PointsField }[] = [
|
|
|
+ { key: 'ichUnit', title: '1. 项目保护单位意见', opinionField: 'ichUnit', pointsField: 'unitPoints' },
|
|
|
+ { key: 'county', title: '2. 县(区)文旅部门审核意见', opinionField: 'county', pointsField: 'countyPoints' },
|
|
|
+ { key: 'district', title: '3. 设区市文旅部门、省非遗中心审核意见', opinionField: 'district', pointsField: 'districtPoints' },
|
|
|
+ { key: 'province', title: '4. 省文化和旅游厅意见', opinionField: 'province', pointsField: 'provincePoints' },
|
|
|
+];
|
|
|
+
|
|
|
+function updateField(field: OpinionField | PointsField, value: number) {
|
|
|
+ (props.currentForm as any)[field] = value;
|
|
|
+}
|
|
|
+</script>
|