Commit e5a79462 authored by 李文光's avatar 李文光

fix: 移除评估卡冻结的能力锚点前置要求

parent ff10a62c
......@@ -58,9 +58,6 @@ const coveredMatchSurfaceCount = computed(
const competencyAnchorCount = computed(() =>
competencyRulers.reduce((sum, item) => sum + (card.value?.competencyCriteria?.[item.key]?.length || 0), 0)
)
const coveredCompetencyCount = computed(
() => competencyRulers.filter((item) => (card.value?.competencyCriteria?.[item.key]?.length || 0) > 0).length
)
const gateCount = computed(() => card.value?.hardGates?.length || 0)
const highlightCount = computed(() => card.value?.highlights?.length || 0)
const requiredChecks = computed(() => [
......@@ -72,15 +69,6 @@ const requiredChecks = computed(() => [
: '至少添加一条可复核判据',
ready: matchCriterionCount.value > 0,
},
{
key: 'competency',
label: '四把能力尺子',
detail:
coveredCompetencyCount.value === competencyRulers.length
? `${competencyAnchorCount.value} 条锚点 · 四个尺子均已配置`
: `${coveredCompetencyCount.value}/4 个尺子已有锚点,冻结前需补齐`,
ready: coveredCompetencyCount.value === competencyRulers.length,
},
])
const requiredReadyCount = computed(() => requiredChecks.value.filter((item) => item.ready).length)
const readinessPercent = computed(() => Math.round((requiredReadyCount.value / requiredChecks.value.length) * 100))
......@@ -93,15 +81,11 @@ const readinessHint = computed(() => {
if (stale.value) return '岗位信息已经变化,请基于当前岗位重新生成并冻结标准。'
if (!editable.value) return '当前冻结版本正在用于该岗位所有候选人的正式 AI 评估。'
if (standardReady.value) return '当前标准已满足冻结条件,冻结后将用于所有候选人的正式 AI 评估。'
return '补齐岗位匹配判据和四把能力尺子后即可冻结。'
return '至少添加一条岗位匹配判据后即可冻结。'
})
const canFreeze = computed(() => {
if (!editable.value) return false
const matchCount = matchSurfaces.reduce((sum, item) => sum + (card.value?.matchCriteria?.[item.key]?.length || 0), 0)
const competencyReady = competencyRulers.every(
(item) => (card.value?.competencyCriteria?.[item.key]?.length || 0) > 0
)
return matchCount > 0 && competencyReady
return matchCriterionCount.value > 0
})
const sourceLabel = (value) =>
......@@ -221,7 +205,7 @@ function saveDraft() {
async function freezeCard() {
if (!card.value || !canFreeze.value) {
showToast('至少需要一条岗位匹配判据,且四把能力尺子都要配置锚点', 'warning')
showToast('至少需要一条岗位匹配判据', 'warning')
return
}
try {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment