diff --git a/src/views/scoring/workbench/index.vue b/src/views/scoring/workbench/index.vue index f47744a..f30ec4b 100644 --- a/src/views/scoring/workbench/index.vue +++ b/src/views/scoring/workbench/index.vue @@ -436,8 +436,8 @@ function formatSessionName(session, index) { (session.projectName && rawName.includes(session.projectName)) ); if (rawName && !isAutoCompound) { - const numericMatch = rawName.match(/^(?:第\s*)?(\d+)(?:\s*场)?$/); - if (numericMatch) return `第 ${parseInt(numericMatch[1], 10)} 场`; + const numericMatch = rawName.match(/^(?:第\s*)?(\d+)\s*(\+?)(?:\s*场)?$/); + if (numericMatch) return `第 ${parseInt(numericMatch[1], 10)}${numericMatch[2] || ''} 场`; return rawName; } const no = String(session.sessionNo || '').trim(); @@ -476,6 +476,9 @@ function formatSessionText(sessionNo) { return String(sessionNo).replace(/^EP/i, '场次 '); } function rowSessionDisplay(row){ + const sessionName=String(row?._session?.sessionName??'').trim(); + const importedSession=sessionName.match(/^(?:第\s*)?(\d+)\s*(\+?)(?:\s*场)?$/); + if(importedSession)return `第${importedSession[1]}${importedSession[2]}场`; const sessionOrder=Number(row?.sessionOrder); if(Number.isInteger(sessionOrder)&&sessionOrder>0)return `第${sessionOrder}场`; const session=row?._session;if(!session)return '—';return formatSessionName(session,session._sourceIndex).replace(/\s+/g,'');