调整裁判管理报名列表
This commit is contained in:
parent
43ee4a89ed
commit
af26f55e9b
@ -54,3 +54,12 @@ export function getIsSignUp(raceId) {
|
||||
});
|
||||
}
|
||||
|
||||
/** 分页查询竞赛报名人员 */
|
||||
export function getRaceUserList(params) {
|
||||
return request({
|
||||
url: `/api/race/${params.raceId}/raceUser`,
|
||||
method: 'get',
|
||||
params
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -81,5 +81,6 @@ export default {
|
||||
refereeJManage: '仿真管理',
|
||||
homeJsxt: '首页',
|
||||
examDetail: '考试详情',
|
||||
raceManage: '竞赛管理'
|
||||
raceManage: '竞赛管理',
|
||||
recaList: '报名列表'
|
||||
};
|
||||
|
@ -132,6 +132,7 @@ const JsxtApply = () => import('@/views/jsxt/apply/index');
|
||||
// const theoryManage = () => import('@/views/jsxt/competition/theory/index');
|
||||
const RefereeList = () => import('@/views/jsxt/refereeList/index');
|
||||
const homeJsxt = () => import('@/views/jsxt/home/index');
|
||||
const RecaList = () => import('@/views/jsxt/reca/list');
|
||||
|
||||
import { GenerateRouteProjectList } from '@/scripts/ProjectConfig';
|
||||
import { getSessionStorage } from '@/utils/auth';
|
||||
@ -304,6 +305,16 @@ export const publicAsyncRoute = [
|
||||
component: Jlmap3d,
|
||||
hidden: true
|
||||
},
|
||||
{ // 运行图编辑
|
||||
path: '/plan/usertool',
|
||||
component: PlanMonitorEditUserTool,
|
||||
hidden: true
|
||||
},
|
||||
{ // 运行图编辑
|
||||
path: '/plan/tool',
|
||||
component: PlanMonitorEditTool,
|
||||
hidden: true
|
||||
},
|
||||
{
|
||||
path: '/displayIscs/system',
|
||||
component: IscsSystem,
|
||||
@ -505,20 +516,6 @@ export const asyncRouter = [
|
||||
}
|
||||
]
|
||||
},
|
||||
{ // 运行图编辑
|
||||
path: '/plan/usertool',
|
||||
component: PlanMonitorEditUserTool,
|
||||
meta: {
|
||||
},
|
||||
hidden: true
|
||||
},
|
||||
{ // 运行图编辑
|
||||
path: '/plan/tool',
|
||||
component: PlanMonitorEditTool,
|
||||
meta: {
|
||||
},
|
||||
hidden: true
|
||||
},
|
||||
{ // 发布内容管理
|
||||
path: '/publish',
|
||||
component: Layout,
|
||||
@ -1058,6 +1055,26 @@ export const JSXT = [
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
path: '/referee',
|
||||
component: Layout,
|
||||
meta: {
|
||||
i18n: 'router.recaList',
|
||||
roles: [user, admin]
|
||||
},
|
||||
hidden: getSessionStorage('project') ? !getSessionStorage('project').endsWith('refereeJsxt') && !window.document.location.pathname.includes('refereeJsxt') : !window.document.location.pathname.includes('refereeJsxt'),
|
||||
children: [
|
||||
{
|
||||
path: 'recaList',
|
||||
component: RecaList,
|
||||
meta: {
|
||||
i18n: 'router.recaList',
|
||||
icon: 'design',
|
||||
hidden: true
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
];
|
||||
const createRouter = () => new Router({
|
||||
|
@ -300,7 +300,6 @@ export default {
|
||||
},
|
||||
handleApply() {
|
||||
this.$refs.dataform.validateForm(() => {
|
||||
console.log(this.formModel, '内容');
|
||||
const param = {
|
||||
department: this.formModel.department,
|
||||
idNumber: this.formModel.numberId,
|
||||
|
143
src/views/jsxt/reca/list.vue
Normal file
143
src/views/jsxt/reca/list.vue
Normal file
@ -0,0 +1,143 @@
|
||||
<template>
|
||||
<div class="">
|
||||
<QueryListPage ref="queryListPage" :pager-config="pagerConfig" :query-form="queryForm" :query-list="queryList" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { getRaceList } from '@/api/race';
|
||||
import { getRaceUserList } from '@/api/competition';
|
||||
import localStore from 'storejs';
|
||||
|
||||
export default {
|
||||
name: '',
|
||||
data() {
|
||||
return {
|
||||
raceList: [],
|
||||
pagerConfig: {
|
||||
pageSize: 'pageSize',
|
||||
pageIndex: 'pageNum'
|
||||
},
|
||||
queryForm: {
|
||||
labelWidth: '80px',
|
||||
reset: true,
|
||||
queryObject: {
|
||||
raceId: {
|
||||
type: 'select',
|
||||
label: '竞赛名称',
|
||||
config: {
|
||||
data: []
|
||||
}
|
||||
},
|
||||
reviewed: {
|
||||
type: 'select',
|
||||
label: '审核状态',
|
||||
config: {
|
||||
data: [
|
||||
{ label: '通过', value: true },
|
||||
{ label: '不通过', value: false }
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
queryList: {
|
||||
query: this.queryFunction,
|
||||
selectCheckShow: false,
|
||||
indexShow: true,
|
||||
columns: [
|
||||
{
|
||||
title: '名字',
|
||||
prop: 'name'
|
||||
},
|
||||
{
|
||||
title: '手机号',
|
||||
prop: 'mobile'
|
||||
},
|
||||
{
|
||||
title: '身份证号',
|
||||
prop: 'idNumber'
|
||||
},
|
||||
{
|
||||
title: '所属组织/企业/学校',
|
||||
prop: 'organization'
|
||||
},
|
||||
{
|
||||
title: '部门/专业',
|
||||
prop: 'department'
|
||||
},
|
||||
{
|
||||
title: '职位',
|
||||
prop: 'position'
|
||||
},
|
||||
// {
|
||||
// title: '竞赛名称',
|
||||
// prop: 'raceId',
|
||||
// type: 'tag',
|
||||
// columnValue: (row) => { return this.$convertField(row.raceId, this.raceList, ['value', 'label']); },
|
||||
// tagType: (row) => { return 'success'; }
|
||||
// },
|
||||
{
|
||||
type: 'button',
|
||||
title: this.$t('global.operate'),
|
||||
buttons: [
|
||||
// {
|
||||
// name: '修改',
|
||||
// handleClick: this.update,
|
||||
// type: ''
|
||||
// }
|
||||
]
|
||||
}
|
||||
],
|
||||
actions: []
|
||||
}
|
||||
};
|
||||
},
|
||||
created() {
|
||||
this.loadInitData();
|
||||
},
|
||||
methods: {
|
||||
async loadInitData() {
|
||||
const params = localStore.get(this.$route.path);
|
||||
const param = {
|
||||
pageSize: 9999,
|
||||
pageIndex: 1
|
||||
};
|
||||
this.raceList = [];
|
||||
const resp = await getRaceList(param);
|
||||
resp.data.list.forEach(elem => {
|
||||
this.queryForm.queryObject.raceId.config.data.push({ value: elem.id, label: elem.name });
|
||||
this.raceList.push({ value: elem.id, label: elem.name });
|
||||
});
|
||||
if (resp.data.list.length) {
|
||||
if (params && params.raceId) {
|
||||
this.queryForm.queryObject.raceId.value = params.raceId;
|
||||
} else {
|
||||
this.queryForm.queryObject.raceId.value = '' + resp.data.list[0].id;
|
||||
}
|
||||
}
|
||||
},
|
||||
// 查询函数
|
||||
queryFunction(params) {
|
||||
return new Promise(async(resolve, reject) => {
|
||||
if (params.raceId) {
|
||||
const res = await getRaceUserList(params);
|
||||
resolve(res);
|
||||
} else {
|
||||
setTimeout(() => {
|
||||
params.raceId = this.queryForm.queryObject.raceId.value;
|
||||
resolve(this.queryFunction(params));
|
||||
}, 500);
|
||||
}
|
||||
});
|
||||
},
|
||||
refresh() {
|
||||
this.$refs.queryListPage.refresh(true);
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
||||
<style rel="stylesheet/scss" lang="scss" scoped>
|
||||
|
||||
</style>
|
@ -335,12 +335,10 @@ export default {
|
||||
this.loading = false;
|
||||
this.tipsMsg = '';
|
||||
removeSessionStorage('againEnter');
|
||||
console.log(this.$route.query, this.$route.query.raceId);
|
||||
if (this.$route.query.raceId) {
|
||||
getIsSignUp(this.$route.query.raceId).then(res => {
|
||||
this.$router.push({ path: this.path });
|
||||
}).catch(error => {
|
||||
console.log(error, '错误');
|
||||
}).catch(() => {
|
||||
this.$messageBox('您未报名该竞赛,所以无法进入竞赛系统');
|
||||
});
|
||||
} else if (!this.$route.path.includes('jsxt/login')) {
|
||||
|
Loading…
Reference in New Issue
Block a user