三人交互、四人交互去掉规定项
This commit is contained in:
parent
05d0328228
commit
16cb7a4aeb
@ -51,6 +51,7 @@ const checks = [
|
||||
['超级管理员具有秩序册菜单授权', roleMenuSeed, '"MenuId": 1088'],
|
||||
['工作台动态评分列', workbench, 'v-for="col in detailColumns"'],
|
||||
['规定赛隐藏难度', scoreScreen, "includes('PRESCRIBED')"],
|
||||
['交互绳成绩大屏隐藏规定', scoreScreen, "item.key!=='required'||!wire"],
|
||||
['评分卡列数随规则动态调整', scoreScreen, 'Math.max(scoreCards.length,1)'],
|
||||
['成绩轮询防重入', scoreScreen, 'castRequesting'],
|
||||
['检录轮询防重入', checkinScreen, 'requesting=false'],
|
||||
|
||||
@ -29,6 +29,7 @@ import { useRoute } from 'vue-router';
|
||||
import { DocumentChecked, Flag, Location, Medal, Setting, Trophy, User, UserFilled } from '@element-plus/icons-vue';
|
||||
import { useTagsViewRoutes } from '/@/stores/tagsViewRoutes';
|
||||
import { workbenchScreenCastCurrentGet } from '/@/api/match/workbench';
|
||||
import { isWireRule } from '../score-format.mjs';
|
||||
|
||||
const route=useRoute(),storesTagsViewRoutes=useTagsViewRoutes();
|
||||
let savedContext={};try{savedContext=JSON.parse(sessionStorage.getItem('scoring-context')||'{}')}catch{savedContext={}}
|
||||
@ -55,7 +56,13 @@ const sessionVenue=computed(()=>[formatScreenSession(effectiveCast.value?.sessio
|
||||
const singleName=computed(()=>displayKind.value==='team'?(payload.value.teamName||payload.value.participantName||'未命名队伍'):(payload.value.participantName||payload.value.teamName||'未命名选手'));
|
||||
const singleAffiliation=computed(()=>displayKind.value==='team'?(payload.value.unitName||''):(payload.value.teamName&&payload.value.teamName!==singleName.value?payload.value.teamName:(payload.value.unitName||'')));
|
||||
const scoreIconComponents={difficulty:Setting,performance:Medal,required:DocumentChecked,deduction:Flag};
|
||||
const scoreCards=computed(()=>[{key:'difficulty',label:'难度',en:'DIFFICULTY',field:'difficultyScore'},{key:'performance',label:'表现',en:'PERFORMANCE',field:'performanceScore'},{key:'required',label:'规定',en:'REQUIRED',field:'requiredScore'},{key:'deduction',label:payload.value.deductionFactor!=null?'得分系数 M':'扣分',en:'DEDUCTION',field:payload.value.deductionFactor!=null?'deductionFactor':'deductionScore'}].filter(item=>item.key!=='difficulty'||!String(effectiveCast.value?.scoreRuleCode||'').toUpperCase().includes('PRESCRIBED')));
|
||||
const scoreCards=computed(()=>{
|
||||
const scoreRuleCode=effectiveCast.value?.scoreRuleCode;
|
||||
const prescribed=String(scoreRuleCode||'').toUpperCase().includes('PRESCRIBED');
|
||||
const wire=isWireRule(scoreRuleCode);
|
||||
return [{key:'difficulty',label:'难度',en:'DIFFICULTY',field:'difficultyScore'},{key:'performance',label:'表现',en:'PERFORMANCE',field:'performanceScore'},{key:'required',label:'规定',en:'REQUIRED',field:'requiredScore'},{key:'deduction',label:payload.value.deductionFactor!=null?'得分系数 M':'扣分',en:'DEDUCTION',field:payload.value.deductionFactor!=null?'deductionFactor':'deductionScore'}]
|
||||
.filter(item=>(item.key!=='difficulty'||!prescribed)&&(item.key!=='required'||!wire));
|
||||
});
|
||||
const rankingAll=computed(()=>Array.isArray(payload.value)?payload.value:[]),rankingTotal=computed(()=>rankingAll.value.length),rankingPageCount=computed(()=>Math.max(1,Math.ceil(rankingTotal.value/6))),rankingPageIndex=computed(()=>rankPage.value%rankingPageCount.value),rankingRows=computed(()=>rankingAll.value.slice(rankingPageIndex.value*6,rankingPageIndex.value*6+6)),maxRankScore=computed(()=>Math.max(...rankingAll.value.map(row=>Number(row.totalScore??row.score)||0),1));
|
||||
function displayName(row){return displayKind.value==='team'?(row.teamName||row.participantName||'未命名队伍'):(row.participantName||row.teamName||'未命名选手')}
|
||||
function displaySubName(row){if(displayKind.value==='team')return row.unitName||'';return row.teamName&&row.teamName!==displayName(row)?row.teamName:(row.unitName||'')}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user