|
@@ -141,26 +141,26 @@
|
|
|
</span>
|
|
</span>
|
|
|
</template>
|
|
</template>
|
|
|
</el-table-column>
|
|
</el-table-column>
|
|
|
- <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
|
|
|
|
|
- <template #default="scope">
|
|
|
|
|
- <el-dropdown trigger="click" placement="bottom">
|
|
|
|
|
- <span style="color: #303133; cursor: pointer; font-size: 14px; font-weight: 500;">
|
|
|
|
|
- 操作 <span style="font-size: 14px; margin-left: 2px;">▼</span>
|
|
|
|
|
- </span>
|
|
|
|
|
- <template #dropdown>
|
|
|
|
|
- <el-dropdown-menu style="min-width: 100px; padding: 4px 0;">
|
|
|
|
|
- <el-dropdown-item @click="handleUpdate(scope.row)" v-hasPermi="['physical:tournaments:edit']">修改</el-dropdown-item>
|
|
|
|
|
- <el-dropdown-item @click="handleDelete(scope.row)" v-hasPermi="['physical:tournaments:remove']">删除</el-dropdown-item>
|
|
|
|
|
- <el-dropdown-item @click="handleCopy(scope.row)" v-hasPermi="['business:tournaments:query']">复制</el-dropdown-item>
|
|
|
|
|
- <el-dropdown-item @click="handleToggleShow(scope.row)" v-hasPermi="['physical:tournaments:edit']">
|
|
|
|
|
- {{ scope.row.isShow === 1 ? '隐藏' : '展示' }}
|
|
|
|
|
- </el-dropdown-item>
|
|
|
|
|
- <el-dropdown-item @click="handleQueryItem(scope.row)">查询线下报名记录</el-dropdown-item>
|
|
|
|
|
- </el-dropdown-menu>
|
|
|
|
|
- </template>
|
|
|
|
|
- </el-dropdown>
|
|
|
|
|
- </template>
|
|
|
|
|
- </el-table-column>
|
|
|
|
|
|
|
+ <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
|
|
|
|
|
+ <template #default="scope">
|
|
|
|
|
+ <el-dropdown trigger="click" placement="bottom">
|
|
|
|
|
+ <span style="color: #303133; cursor: pointer; font-size: 14px; font-weight: 500">
|
|
|
|
|
+ 操作 <span style="font-size: 14px; margin-left: 2px">▼</span>
|
|
|
|
|
+ </span>
|
|
|
|
|
+ <template #dropdown>
|
|
|
|
|
+ <el-dropdown-menu style="min-width: 100px; padding: 4px 0">
|
|
|
|
|
+ <el-dropdown-item @click="handleUpdate(scope.row)" v-hasPermi="['physical:tournaments:edit']">修改</el-dropdown-item>
|
|
|
|
|
+ <el-dropdown-item @click="handleDelete(scope.row)" v-hasPermi="['physical:tournaments:remove']">删除</el-dropdown-item>
|
|
|
|
|
+ <el-dropdown-item @click="handleCopy(scope.row)" v-hasPermi="['business:tournaments:query']">复制</el-dropdown-item>
|
|
|
|
|
+ <el-dropdown-item @click="handleToggleShow(scope.row)" v-hasPermi="['physical:tournaments:edit']">
|
|
|
|
|
+ {{ scope.row.isShow === 1 ? '隐藏' : '展示' }}
|
|
|
|
|
+ </el-dropdown-item>
|
|
|
|
|
+ <el-dropdown-item @click="handleQueryItem(scope.row)">查询线下报名记录</el-dropdown-item>
|
|
|
|
|
+ </el-dropdown-menu>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ </el-dropdown>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ </el-table-column>
|
|
|
</el-table>
|
|
</el-table>
|
|
|
|
|
|
|
|
<pagination v-show="total > 0" :total="total" v-model:page="queryParams.pageNum" v-model:limit="queryParams.pageSize" @pagination="getList" />
|
|
<pagination v-show="total > 0" :total="total" v-model:page="queryParams.pageNum" v-model:limit="queryParams.pageSize" @pagination="getList" />
|
|
@@ -181,7 +181,7 @@
|
|
|
<el-option v-for="item in competitionZoneOptions" :key="item.id" :label="item.zoneName" :value="item.id" />
|
|
<el-option v-for="item in competitionZoneOptions" :key="item.id" :label="item.zoneName" :value="item.id" />
|
|
|
</el-select>
|
|
</el-select>
|
|
|
</el-form-item>
|
|
</el-form-item>
|
|
|
-<!-- <el-form-item label="所属赛区" prop="leagueTournamentRegion">
|
|
|
|
|
|
|
+ <!-- <el-form-item label="所属赛区" prop="leagueTournamentRegion">
|
|
|
<el-input v-model="form.leagueTournamentRegion" placeholder="请输入赛区" />
|
|
<el-input v-model="form.leagueTournamentRegion" placeholder="请输入赛区" />
|
|
|
</el-form-item>-->
|
|
</el-form-item>-->
|
|
|
<el-form-item label="比赛项目" prop="gameVariant">
|
|
<el-form-item label="比赛项目" prop="gameVariant">
|
|
@@ -549,7 +549,6 @@ const dialog = reactive<{
|
|
|
});
|
|
});
|
|
|
|
|
|
|
|
const initFormData: TournamentsForm = {
|
|
const initFormData: TournamentsForm = {
|
|
|
-
|
|
|
|
|
id: undefined,
|
|
id: undefined,
|
|
|
name: undefined,
|
|
name: undefined,
|
|
|
startTime: undefined,
|
|
startTime: undefined,
|
|
@@ -582,7 +581,7 @@ const initFormData: TournamentsForm = {
|
|
|
qualifierType: undefined,
|
|
qualifierType: undefined,
|
|
|
qualifierValue: undefined,
|
|
qualifierValue: undefined,
|
|
|
tournamentType: 0,
|
|
tournamentType: 0,
|
|
|
- isOffline: 1,
|
|
|
|
|
|
|
+ isOffline: 1
|
|
|
};
|
|
};
|
|
|
const data = reactive<PageData<TournamentsForm, TournamentsQuery>>({
|
|
const data = reactive<PageData<TournamentsForm, TournamentsQuery>>({
|
|
|
form: { ...initFormData },
|
|
form: { ...initFormData },
|
|
@@ -736,23 +735,23 @@ const data = reactive<PageData<TournamentsForm, TournamentsQuery>>({
|
|
|
trigger: 'blur'
|
|
trigger: 'blur'
|
|
|
}
|
|
}
|
|
|
],
|
|
],
|
|
|
- minPlayers: [
|
|
|
|
|
- { required: false, message: '参赛人数不能为空', trigger: 'blur' },
|
|
|
|
|
- {
|
|
|
|
|
- validator: (rule: any, value: any, callback: any) => {
|
|
|
|
|
- const num = Number(value);
|
|
|
|
|
- if (!/^\d+$/.test(value)) {
|
|
|
|
|
- callback(new Error('只能输入正整数'));
|
|
|
|
|
- } else if (num < 0 || num > 999) {
|
|
|
|
|
- callback(new Error('参赛人数必须在0-999之间'));
|
|
|
|
|
- } else {
|
|
|
|
|
- callback();
|
|
|
|
|
- }
|
|
|
|
|
- },
|
|
|
|
|
- trigger: 'blur'
|
|
|
|
|
|
|
+ minPlayers: [
|
|
|
|
|
+ { required: false, message: '参赛人数不能为空', trigger: 'blur' },
|
|
|
|
|
+ {
|
|
|
|
|
+ validator: (rule: any, value: any, callback: any) => {
|
|
|
|
|
+ const num = Number(value);
|
|
|
|
|
+ if (!/^\d+$/.test(value)) {
|
|
|
|
|
+ callback(new Error('只能输入正整数'));
|
|
|
|
|
+ } else if (num < 0 || num > 999) {
|
|
|
|
|
+ callback(new Error('参赛人数必须在0-999之间'));
|
|
|
|
|
+ } else {
|
|
|
|
|
+ callback();
|
|
|
}
|
|
}
|
|
|
- ],
|
|
|
|
|
- isOffline: [{ required: true, message: '是否可以报名不能为空', trigger: 'change' }]
|
|
|
|
|
|
|
+ },
|
|
|
|
|
+ trigger: 'blur'
|
|
|
|
|
+ }
|
|
|
|
|
+ ],
|
|
|
|
|
+ isOffline: [{ required: true, message: '是否可以报名不能为空', trigger: 'change' }]
|
|
|
}
|
|
}
|
|
|
});
|
|
});
|
|
|
// 控制 Dialog 是否显示
|
|
// 控制 Dialog 是否显示
|
|
@@ -815,7 +814,6 @@ const resetQuery = () => {
|
|
|
getList();
|
|
getList();
|
|
|
};
|
|
};
|
|
|
|
|
|
|
|
-
|
|
|
|
|
/** 多选框选中数据 */
|
|
/** 多选框选中数据 */
|
|
|
const handleSelectionChange = (selection: TournamentsVO[]) => {
|
|
const handleSelectionChange = (selection: TournamentsVO[]) => {
|
|
|
ids.value = selection.map((item) => item.id);
|
|
ids.value = selection.map((item) => item.id);
|
|
@@ -1497,7 +1495,8 @@ const loadTargetTournaments = (query: string) => {
|
|
|
return;
|
|
return;
|
|
|
}
|
|
}
|
|
|
// 这里可加模糊搜索逻辑(如 filter)222
|
|
// 这里可加模糊搜索逻辑(如 filter)222
|
|
|
- selectOptions.value = selectOptions.value.filter((item) => item.label.toLowerCase().includes(query.toLowerCase()));};
|
|
|
|
|
|
|
+ selectOptions.value = selectOptions.value.filter((item) => item.label.toLowerCase().includes(query.toLowerCase()));
|
|
|
|
|
+};
|
|
|
const handleCompetitionZoneChange = (value: number) => {
|
|
const handleCompetitionZoneChange = (value: number) => {
|
|
|
const selectedZone = competitionZoneOptions.value.find((item) => item.id === value);
|
|
const selectedZone = competitionZoneOptions.value.find((item) => item.id === value);
|
|
|
if (selectedZone) {
|
|
if (selectedZone) {
|
|
@@ -1533,11 +1532,10 @@ const handleToggleShow = async (row: TournamentsVO) => {
|
|
|
const handleQueryItem = (row: TournamentsVO) => {
|
|
const handleQueryItem = (row: TournamentsVO) => {
|
|
|
// 跳转到线下报名记录页面
|
|
// 跳转到线下报名记录页面
|
|
|
router.push({
|
|
router.push({
|
|
|
- path: '/physical/participants', // 改对路径!
|
|
|
|
|
|
|
+ path: '/physical/participants', // 改对路径!
|
|
|
query: {
|
|
query: {
|
|
|
tournamentId: row.id
|
|
tournamentId: row.id
|
|
|
}
|
|
}
|
|
|
});
|
|
});
|
|
|
};
|
|
};
|
|
|
-
|
|
|
|
|
</script>
|
|
</script>
|