|
|
|
|
@ -7946,7 +7946,7 @@ var informationPage = function informationPage(_ref) {
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
} else if ((params === null || params === void 0 ? void 0 : params.identifier) != form.getFieldValue('identifier')) {
|
|
|
|
|
_umi_production_exports.history.push("/competitions/detaol/".concat(form.getFieldValue('identifier'), "?type=4"));
|
|
|
|
|
_umi_production_exports.history.push("/competitions/detail/".concat(form.getFieldValue('identifier'), "?type=4"));
|
|
|
|
|
}
|
|
|
|
|
} else {
|
|
|
|
|
// message.error(res?.message)
|
|
|
|
|
@ -12476,17 +12476,17 @@ var Ranking_competitionsPage = function competitionsPage(_ref) {
|
|
|
|
|
return _getdatas.apply(this, arguments);
|
|
|
|
|
}
|
|
|
|
|
function _getdatas() {
|
|
|
|
|
_getdatas = asyncToGenerator_default()( /*#__PURE__*/regeneratorRuntime_default()().mark(function _callee3() {
|
|
|
|
|
_getdatas = asyncToGenerator_default()( /*#__PURE__*/regeneratorRuntime_default()().mark(function _callee2() {
|
|
|
|
|
var res, _res$data, _res$data$, _res$data2, _res$data2$, _res$data3, list;
|
|
|
|
|
return regeneratorRuntime_default()().wrap(function _callee3$(_context3) {
|
|
|
|
|
while (1) switch (_context3.prev = _context3.next) {
|
|
|
|
|
return regeneratorRuntime_default()().wrap(function _callee2$(_context2) {
|
|
|
|
|
while (1) switch (_context2.prev = _context2.next) {
|
|
|
|
|
case 0:
|
|
|
|
|
_context3.next = 2;
|
|
|
|
|
_context2.next = 2;
|
|
|
|
|
return (0,fetch/* default */.ZP)("/api/competitions/".concat(identifier, "/competition_questions.json"), {
|
|
|
|
|
method: 'get'
|
|
|
|
|
});
|
|
|
|
|
case 2:
|
|
|
|
|
res = _context3.sent;
|
|
|
|
|
res = _context2.sent;
|
|
|
|
|
if ((res === null || res === void 0 ? void 0 : res.status) === 0) {
|
|
|
|
|
setselectedKeys(res === null || res === void 0 ? void 0 : (_res$data = res.data) === null || _res$data === void 0 ? void 0 : (_res$data$ = _res$data[0]) === null || _res$data$ === void 0 ? void 0 : _res$data$.identifier);
|
|
|
|
|
getrank(res === null || res === void 0 ? void 0 : (_res$data2 = res.data) === null || _res$data2 === void 0 ? void 0 : (_res$data2$ = _res$data2[0]) === null || _res$data2$ === void 0 ? void 0 : _res$data2$.identifier);
|
|
|
|
|
@ -12495,24 +12495,10 @@ var Ranking_competitionsPage = function competitionsPage(_ref) {
|
|
|
|
|
label: item === null || item === void 0 ? void 0 : item.name,
|
|
|
|
|
key: item === null || item === void 0 ? void 0 : item.identifier,
|
|
|
|
|
className: Rankingmodules.muitem,
|
|
|
|
|
onClick: function () {
|
|
|
|
|
var _onClick = asyncToGenerator_default()( /*#__PURE__*/regeneratorRuntime_default()().mark(function _callee2() {
|
|
|
|
|
return regeneratorRuntime_default()().wrap(function _callee2$(_context2) {
|
|
|
|
|
while (1) switch (_context2.prev = _context2.next) {
|
|
|
|
|
case 0:
|
|
|
|
|
setselectedKeys(item.identifier);
|
|
|
|
|
getrank(item.identifier);
|
|
|
|
|
case 2:
|
|
|
|
|
case "end":
|
|
|
|
|
return _context2.stop();
|
|
|
|
|
}
|
|
|
|
|
}, _callee2);
|
|
|
|
|
}));
|
|
|
|
|
function onClick() {
|
|
|
|
|
return _onClick.apply(this, arguments);
|
|
|
|
|
}
|
|
|
|
|
return onClick;
|
|
|
|
|
}()
|
|
|
|
|
onClick: function onClick() {
|
|
|
|
|
setselectedKeys(item.identifier);
|
|
|
|
|
getrank(item.identifier);
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
});
|
|
|
|
|
setitems(list);
|
|
|
|
|
@ -12521,9 +12507,9 @@ var Ranking_competitionsPage = function competitionsPage(_ref) {
|
|
|
|
|
}
|
|
|
|
|
case 4:
|
|
|
|
|
case "end":
|
|
|
|
|
return _context3.stop();
|
|
|
|
|
return _context2.stop();
|
|
|
|
|
}
|
|
|
|
|
}, _callee3);
|
|
|
|
|
}, _callee2);
|
|
|
|
|
}));
|
|
|
|
|
return _getdatas.apply(this, arguments);
|
|
|
|
|
}
|
|
|
|
|
@ -12534,14 +12520,14 @@ var Ranking_competitionsPage = function competitionsPage(_ref) {
|
|
|
|
|
return _getrank.apply(this, arguments);
|
|
|
|
|
}
|
|
|
|
|
function _getrank() {
|
|
|
|
|
_getrank = asyncToGenerator_default()( /*#__PURE__*/regeneratorRuntime_default()().mark(function _callee4(id) {
|
|
|
|
|
_getrank = asyncToGenerator_default()( /*#__PURE__*/regeneratorRuntime_default()().mark(function _callee3(id) {
|
|
|
|
|
var url, res, _res$data4;
|
|
|
|
|
return regeneratorRuntime_default()().wrap(function _callee4$(_context4) {
|
|
|
|
|
while (1) switch (_context4.prev = _context4.next) {
|
|
|
|
|
return regeneratorRuntime_default()().wrap(function _callee3$(_context3) {
|
|
|
|
|
while (1) switch (_context3.prev = _context3.next) {
|
|
|
|
|
case 0:
|
|
|
|
|
// question _identifier
|
|
|
|
|
url = Header !== null && Header !== void 0 && Header.personal ? "/api/competitions/".concat(identifier, "/competition_charts/person_ranking.json") : "/api/competitions/".concat(identifier, "/competition_charts/team_ranking.json");
|
|
|
|
|
_context4.next = 3;
|
|
|
|
|
_context3.next = 3;
|
|
|
|
|
return (0,fetch/* default */.ZP)(url, {
|
|
|
|
|
method: 'get',
|
|
|
|
|
params: objectSpread2_default()(objectSpread2_default()({}, param), {}, {
|
|
|
|
|
@ -12549,16 +12535,16 @@ var Ranking_competitionsPage = function competitionsPage(_ref) {
|
|
|
|
|
})
|
|
|
|
|
});
|
|
|
|
|
case 3:
|
|
|
|
|
res = _context4.sent;
|
|
|
|
|
res = _context3.sent;
|
|
|
|
|
if ((res === null || res === void 0 ? void 0 : res.status) === 0) {
|
|
|
|
|
setRanKingList(res === null || res === void 0 ? void 0 : res.data);
|
|
|
|
|
setDefaultcontent(res === null || res === void 0 ? void 0 : (_res$data4 = res.data) === null || _res$data4 === void 0 ? void 0 : _res$data4.description);
|
|
|
|
|
}
|
|
|
|
|
case 5:
|
|
|
|
|
case "end":
|
|
|
|
|
return _context4.stop();
|
|
|
|
|
return _context3.stop();
|
|
|
|
|
}
|
|
|
|
|
}, _callee4);
|
|
|
|
|
}, _callee3);
|
|
|
|
|
}));
|
|
|
|
|
return _getrank.apply(this, arguments);
|
|
|
|
|
}
|
|
|
|
|
@ -12566,10 +12552,10 @@ var Ranking_competitionsPage = function competitionsPage(_ref) {
|
|
|
|
|
return _getexerport.apply(this, arguments);
|
|
|
|
|
}
|
|
|
|
|
function _getexerport() {
|
|
|
|
|
_getexerport = asyncToGenerator_default()( /*#__PURE__*/regeneratorRuntime_default()().mark(function _callee5(id) {
|
|
|
|
|
_getexerport = asyncToGenerator_default()( /*#__PURE__*/regeneratorRuntime_default()().mark(function _callee4(id) {
|
|
|
|
|
var url;
|
|
|
|
|
return regeneratorRuntime_default()().wrap(function _callee5$(_context5) {
|
|
|
|
|
while (1) switch (_context5.prev = _context5.next) {
|
|
|
|
|
return regeneratorRuntime_default()().wrap(function _callee4$(_context4) {
|
|
|
|
|
while (1) switch (_context4.prev = _context4.next) {
|
|
|
|
|
case 0:
|
|
|
|
|
url = Header !== null && Header !== void 0 && Header.personal ? "/api/competitions/".concat(identifier, "/competition_charts/person_ranking.xlsx") : "/api/competitions/".concat(identifier, "/competition_charts/team_ranking.xlsx");
|
|
|
|
|
(0,util/* downLoadFile */.FH)('', (0,util/* setUrlQuery */.NY)({
|
|
|
|
|
@ -12580,9 +12566,9 @@ var Ranking_competitionsPage = function competitionsPage(_ref) {
|
|
|
|
|
}));
|
|
|
|
|
case 2:
|
|
|
|
|
case "end":
|
|
|
|
|
return _context5.stop();
|
|
|
|
|
return _context4.stop();
|
|
|
|
|
}
|
|
|
|
|
}, _callee5);
|
|
|
|
|
}, _callee4);
|
|
|
|
|
}));
|
|
|
|
|
return _getexerport.apply(this, arguments);
|
|
|
|
|
}
|
|
|
|
|
@ -12836,9 +12822,7 @@ var Ranking_competitionsPage = function competitionsPage(_ref) {
|
|
|
|
|
className: Rankingmodules.left,
|
|
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)(menu/* default */.Z, {
|
|
|
|
|
style: {
|
|
|
|
|
border: 'none',
|
|
|
|
|
width: 200,
|
|
|
|
|
overflow: 'auto'
|
|
|
|
|
border: 'none'
|
|
|
|
|
},
|
|
|
|
|
mode: "horizontal",
|
|
|
|
|
selectedKeys: ["".concat(selectedKeys)],
|
|
|
|
|
@ -13580,19 +13564,17 @@ var Team_competitionsPage = function competitionsPage(_ref) {
|
|
|
|
|
children: "\u5BFC\u51FA"
|
|
|
|
|
})]
|
|
|
|
|
})]
|
|
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsx)(ui_customization/* CustomTable */.Gi, {
|
|
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)(table/* default */.Z, {
|
|
|
|
|
loading: isloading,
|
|
|
|
|
style: {
|
|
|
|
|
marginTop: 20
|
|
|
|
|
},
|
|
|
|
|
scroll: {
|
|
|
|
|
y: 300
|
|
|
|
|
},
|
|
|
|
|
columns: params.isteam === 'mine' ? columns1 : columns,
|
|
|
|
|
dataSource: params.isteam === 'mine' ? userList === null || userList === void 0 ? void 0 : userList.competition_teams : userList === null || userList === void 0 ? void 0 : userList.data,
|
|
|
|
|
pagination: false
|
|
|
|
|
})
|
|
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsx)(table/* default */.Z, {
|
|
|
|
|
loading: isloading,
|
|
|
|
|
style: {
|
|
|
|
|
marginTop: 20
|
|
|
|
|
},
|
|
|
|
|
scroll: {
|
|
|
|
|
y: 300
|
|
|
|
|
},
|
|
|
|
|
columns: params.isteam === 'mine' ? columns1 : columns,
|
|
|
|
|
dataSource: params.isteam === 'mine' ? userList === null || userList === void 0 ? void 0 : userList.competition_teams : userList === null || userList === void 0 ? void 0 : userList.data,
|
|
|
|
|
pagination: false
|
|
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsx)("div", {
|
|
|
|
|
className: Teammodules.countWrap,
|
|
|
|
|
style: {
|
|
|
|
|
@ -13697,7 +13679,6 @@ var StudentTeam_excluded = ["competitions", "globalSetting", "loading", "dispatc
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var StudentTeam_competitionsPage = function competitionsPage(_ref) {
|
|
|
|
|
var _Header$permission, _Header$permission2, _competition_team$my_, _competition_team$my_2, _competition_team$my_3, _competition_team$my_4, _competition_team$com, _competition_team$my_5, _competition_team$com2, _TeamItem$team_member, _Team$name, _Team$name2;
|
|
|
|
|
var competitions = _ref.competitions,
|
|
|
|
|
@ -14455,111 +14436,109 @@ var StudentTeam_competitionsPage = function competitionsPage(_ref) {
|
|
|
|
|
className: "iconfont icon-danchuangguanbi"
|
|
|
|
|
})
|
|
|
|
|
})]
|
|
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsx)(ui_customization/* CustomTable */.Gi, {
|
|
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsx)(table/* default */.Z, {
|
|
|
|
|
dataSource: TeamItem === null || TeamItem === void 0 ? void 0 : TeamItem.team_members,
|
|
|
|
|
pagination: false,
|
|
|
|
|
style: {
|
|
|
|
|
marginTop: 30
|
|
|
|
|
},
|
|
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)(table/* default */.Z, {
|
|
|
|
|
dataSource: TeamItem === null || TeamItem === void 0 ? void 0 : TeamItem.team_members,
|
|
|
|
|
pagination: false,
|
|
|
|
|
scroll: {
|
|
|
|
|
y: 300
|
|
|
|
|
scroll: {
|
|
|
|
|
y: 300
|
|
|
|
|
},
|
|
|
|
|
columns: [{
|
|
|
|
|
title: '头像',
|
|
|
|
|
align: 'left',
|
|
|
|
|
dataIndex: 'image_url',
|
|
|
|
|
render: function render(text, item) {
|
|
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsx)("img", {
|
|
|
|
|
className: Teammodules.loaderimg,
|
|
|
|
|
src: env/* default.IMG_SERVER */.Z.IMG_SERVER + "/images/" + "".concat(text)
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
title: '姓名',
|
|
|
|
|
align: 'left',
|
|
|
|
|
dataIndex: 'name',
|
|
|
|
|
render: function render(text) {
|
|
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsx)(tooltip/* default */.Z, {
|
|
|
|
|
title: text,
|
|
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)("span", {
|
|
|
|
|
children: (text === null || text === void 0 ? void 0 : text.length) > 6 ? (text === null || text === void 0 ? void 0 : text.substring(0, 6)) + '...' : text || '- -'
|
|
|
|
|
})
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
title: '手机',
|
|
|
|
|
align: 'left',
|
|
|
|
|
dataIndex: 'phone',
|
|
|
|
|
ellipsis: {
|
|
|
|
|
showTitle: true
|
|
|
|
|
},
|
|
|
|
|
columns: [{
|
|
|
|
|
title: '头像',
|
|
|
|
|
align: 'left',
|
|
|
|
|
dataIndex: 'image_url',
|
|
|
|
|
render: function render(text, item) {
|
|
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsx)("img", {
|
|
|
|
|
className: Teammodules.loaderimg,
|
|
|
|
|
src: env/* default.IMG_SERVER */.Z.IMG_SERVER + "/images/" + "".concat(text)
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
title: '姓名',
|
|
|
|
|
align: 'left',
|
|
|
|
|
dataIndex: 'name',
|
|
|
|
|
render: function render(text) {
|
|
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsx)(tooltip/* default */.Z, {
|
|
|
|
|
title: text,
|
|
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)("span", {
|
|
|
|
|
children: (text === null || text === void 0 ? void 0 : text.length) > 6 ? (text === null || text === void 0 ? void 0 : text.substring(0, 6)) + '...' : text || '- -'
|
|
|
|
|
})
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
title: '手机',
|
|
|
|
|
align: 'left',
|
|
|
|
|
dataIndex: 'phone',
|
|
|
|
|
ellipsis: {
|
|
|
|
|
showTitle: true
|
|
|
|
|
},
|
|
|
|
|
render: function render(text) {
|
|
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsx)("span", {
|
|
|
|
|
children: text || '- -'
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
title: '学校/单位',
|
|
|
|
|
align: 'left',
|
|
|
|
|
dataIndex: 'school_name',
|
|
|
|
|
render: function render(text, item) {
|
|
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsx)(tooltip/* default */.Z, {
|
|
|
|
|
title: text,
|
|
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)("span", {
|
|
|
|
|
children: (text === null || text === void 0 ? void 0 : text.length) > 6 ? (text === null || text === void 0 ? void 0 : text.substring(0, 6)) + '...' : text || '- -'
|
|
|
|
|
})
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
title: '职业',
|
|
|
|
|
align: 'left',
|
|
|
|
|
ellipsis: {
|
|
|
|
|
showTitle: true
|
|
|
|
|
},
|
|
|
|
|
dataIndex: 'identity',
|
|
|
|
|
render: function render(text, item) {
|
|
|
|
|
return text || '- -';
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
title: '学号',
|
|
|
|
|
align: 'left',
|
|
|
|
|
ellipsis: {
|
|
|
|
|
showTitle: true
|
|
|
|
|
},
|
|
|
|
|
dataIndex: 'student_id',
|
|
|
|
|
render: function render(text, item) {
|
|
|
|
|
return text || '- -';
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
title: '角色',
|
|
|
|
|
align: 'left',
|
|
|
|
|
dataIndex: 'role',
|
|
|
|
|
render: function render(text, item) {
|
|
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsxs)("span", {
|
|
|
|
|
render: function render(text) {
|
|
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsx)("span", {
|
|
|
|
|
children: text || '- -'
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
title: '学校/单位',
|
|
|
|
|
align: 'left',
|
|
|
|
|
dataIndex: 'school_name',
|
|
|
|
|
render: function render(text, item) {
|
|
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsx)(tooltip/* default */.Z, {
|
|
|
|
|
title: text,
|
|
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)("span", {
|
|
|
|
|
children: (text === null || text === void 0 ? void 0 : text.length) > 6 ? (text === null || text === void 0 ? void 0 : text.substring(0, 6)) + '...' : text || '- -'
|
|
|
|
|
})
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
title: '职业',
|
|
|
|
|
align: 'left',
|
|
|
|
|
ellipsis: {
|
|
|
|
|
showTitle: true
|
|
|
|
|
},
|
|
|
|
|
dataIndex: 'identity',
|
|
|
|
|
render: function render(text, item) {
|
|
|
|
|
return text || '- -';
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
title: '学号',
|
|
|
|
|
align: 'left',
|
|
|
|
|
ellipsis: {
|
|
|
|
|
showTitle: true
|
|
|
|
|
},
|
|
|
|
|
dataIndex: 'student_id',
|
|
|
|
|
render: function render(text, item) {
|
|
|
|
|
return text || '- -';
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
title: '角色',
|
|
|
|
|
align: 'left',
|
|
|
|
|
dataIndex: 'role',
|
|
|
|
|
render: function render(text, item) {
|
|
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsxs)("span", {
|
|
|
|
|
style: {
|
|
|
|
|
color: text === 'leader' ? '#3061D0' : '#01795D'
|
|
|
|
|
},
|
|
|
|
|
children: [text === "leader" ? '队长' : '队员', (item === null || item === void 0 ? void 0 : item.creator) && /*#__PURE__*/(0,jsx_runtime.jsx)("span", {
|
|
|
|
|
style: {
|
|
|
|
|
color: text === 'leader' ? '#3061D0' : '#01795D'
|
|
|
|
|
color: '#FA6400',
|
|
|
|
|
display: 'inline-flex',
|
|
|
|
|
width: 48,
|
|
|
|
|
height: 22,
|
|
|
|
|
borderRadius: 4,
|
|
|
|
|
lineHeight: '22px',
|
|
|
|
|
background: '#FEEADC',
|
|
|
|
|
textAlign: 'center',
|
|
|
|
|
marginLeft: 10,
|
|
|
|
|
justifyContent: 'center',
|
|
|
|
|
fontSize: 12
|
|
|
|
|
},
|
|
|
|
|
children: [text === "leader" ? '队长' : '队员', (item === null || item === void 0 ? void 0 : item.creator) && /*#__PURE__*/(0,jsx_runtime.jsx)("span", {
|
|
|
|
|
style: {
|
|
|
|
|
color: '#FA6400',
|
|
|
|
|
display: 'inline-flex',
|
|
|
|
|
width: 48,
|
|
|
|
|
height: 22,
|
|
|
|
|
borderRadius: 4,
|
|
|
|
|
lineHeight: '22px',
|
|
|
|
|
background: '#FEEADC',
|
|
|
|
|
textAlign: 'center',
|
|
|
|
|
marginLeft: 10,
|
|
|
|
|
justifyContent: 'center',
|
|
|
|
|
fontSize: 12
|
|
|
|
|
},
|
|
|
|
|
children: "\u521B\u5EFA\u8005"
|
|
|
|
|
})]
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}]
|
|
|
|
|
})
|
|
|
|
|
children: "\u521B\u5EFA\u8005"
|
|
|
|
|
})]
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}]
|
|
|
|
|
})]
|
|
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsx)(modal/* default */.Z, {
|
|
|
|
|
title: false,
|
|
|
|
|
@ -14940,150 +14919,148 @@ var StudentTeam_competitionsPage = function competitionsPage(_ref) {
|
|
|
|
|
children: [Staff && Staff.member_staff.minimum, "-", Staff && Staff.member_staff.maximum, "\u540D\u5B66\u751F"]
|
|
|
|
|
}) : '']
|
|
|
|
|
})
|
|
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsx)(ui_customization/* CustomTable */.Gi, {
|
|
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsx)(table/* default */.Z, {
|
|
|
|
|
dataSource: EditTeamItem,
|
|
|
|
|
pagination: false,
|
|
|
|
|
style: {
|
|
|
|
|
marginTop: '-10px',
|
|
|
|
|
padding: '0 8px'
|
|
|
|
|
},
|
|
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)(table/* default */.Z, {
|
|
|
|
|
dataSource: EditTeamItem,
|
|
|
|
|
pagination: false,
|
|
|
|
|
scroll: {
|
|
|
|
|
y: 300
|
|
|
|
|
},
|
|
|
|
|
columns: [{
|
|
|
|
|
title: '头像',
|
|
|
|
|
align: 'left',
|
|
|
|
|
width: 60,
|
|
|
|
|
dataIndex: 'image_url',
|
|
|
|
|
render: function render(text, item) {
|
|
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsx)("img", {
|
|
|
|
|
className: Teammodules.loaderimg,
|
|
|
|
|
src: env/* default.IMG_SERVER */.Z.IMG_SERVER + "/images/" + "".concat(text)
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
title: '姓名',
|
|
|
|
|
align: 'left',
|
|
|
|
|
dataIndex: 'name',
|
|
|
|
|
render: function render(text) {
|
|
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsx)(tooltip/* default */.Z, {
|
|
|
|
|
title: text,
|
|
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)("span", {
|
|
|
|
|
children: (text === null || text === void 0 ? void 0 : text.length) > 6 ? (text === null || text === void 0 ? void 0 : text.substring(0, 6)) + '...' : text || '- -'
|
|
|
|
|
})
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
title: '手机',
|
|
|
|
|
align: 'left',
|
|
|
|
|
width: 130,
|
|
|
|
|
dataIndex: 'phone',
|
|
|
|
|
render: function render(text) {
|
|
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsx)(tooltip/* default */.Z, {
|
|
|
|
|
title: text,
|
|
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)("span", {
|
|
|
|
|
children: text || '- -'
|
|
|
|
|
})
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
title: '学校/单位',
|
|
|
|
|
align: 'left',
|
|
|
|
|
dataIndex: 'school_name',
|
|
|
|
|
render: function render(text, item) {
|
|
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsx)(tooltip/* default */.Z, {
|
|
|
|
|
title: text,
|
|
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)("span", {
|
|
|
|
|
children: (text === null || text === void 0 ? void 0 : text.length) > 6 ? (text === null || text === void 0 ? void 0 : text.substring(0, 6)) + '...' : text || '- -'
|
|
|
|
|
})
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
title: '职业',
|
|
|
|
|
align: 'left',
|
|
|
|
|
dataIndex: 'identity',
|
|
|
|
|
render: function render(text, item) {
|
|
|
|
|
return text || '- -';
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
title: '学号',
|
|
|
|
|
align: 'left',
|
|
|
|
|
dataIndex: 'student_id',
|
|
|
|
|
render: function render(text, item) {
|
|
|
|
|
return text || '- -';
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
title: '角色',
|
|
|
|
|
align: 'left',
|
|
|
|
|
dataIndex: 'role',
|
|
|
|
|
render: function render(text, item) {
|
|
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsxs)("span", {
|
|
|
|
|
scroll: {
|
|
|
|
|
y: 300
|
|
|
|
|
},
|
|
|
|
|
columns: [{
|
|
|
|
|
title: '头像',
|
|
|
|
|
align: 'left',
|
|
|
|
|
width: 60,
|
|
|
|
|
dataIndex: 'image_url',
|
|
|
|
|
render: function render(text, item) {
|
|
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsx)("img", {
|
|
|
|
|
className: Teammodules.loaderimg,
|
|
|
|
|
src: env/* default.IMG_SERVER */.Z.IMG_SERVER + "/images/" + "".concat(text)
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
title: '姓名',
|
|
|
|
|
align: 'left',
|
|
|
|
|
dataIndex: 'name',
|
|
|
|
|
render: function render(text) {
|
|
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsx)(tooltip/* default */.Z, {
|
|
|
|
|
title: text,
|
|
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)("span", {
|
|
|
|
|
children: (text === null || text === void 0 ? void 0 : text.length) > 6 ? (text === null || text === void 0 ? void 0 : text.substring(0, 6)) + '...' : text || '- -'
|
|
|
|
|
})
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
title: '手机',
|
|
|
|
|
align: 'left',
|
|
|
|
|
width: 130,
|
|
|
|
|
dataIndex: 'phone',
|
|
|
|
|
render: function render(text) {
|
|
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsx)(tooltip/* default */.Z, {
|
|
|
|
|
title: text,
|
|
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)("span", {
|
|
|
|
|
children: text || '- -'
|
|
|
|
|
})
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
title: '学校/单位',
|
|
|
|
|
align: 'left',
|
|
|
|
|
dataIndex: 'school_name',
|
|
|
|
|
render: function render(text, item) {
|
|
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsx)(tooltip/* default */.Z, {
|
|
|
|
|
title: text,
|
|
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)("span", {
|
|
|
|
|
children: (text === null || text === void 0 ? void 0 : text.length) > 6 ? (text === null || text === void 0 ? void 0 : text.substring(0, 6)) + '...' : text || '- -'
|
|
|
|
|
})
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
title: '职业',
|
|
|
|
|
align: 'left',
|
|
|
|
|
dataIndex: 'identity',
|
|
|
|
|
render: function render(text, item) {
|
|
|
|
|
return text || '- -';
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
title: '学号',
|
|
|
|
|
align: 'left',
|
|
|
|
|
dataIndex: 'student_id',
|
|
|
|
|
render: function render(text, item) {
|
|
|
|
|
return text || '- -';
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
title: '角色',
|
|
|
|
|
align: 'left',
|
|
|
|
|
dataIndex: 'role',
|
|
|
|
|
render: function render(text, item) {
|
|
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsxs)("span", {
|
|
|
|
|
style: {
|
|
|
|
|
color: text === 'leader' ? '#3061D0' : '#01795D'
|
|
|
|
|
},
|
|
|
|
|
children: [text === "leader" ? '队长' : '队员', (item === null || item === void 0 ? void 0 : item.creator) && /*#__PURE__*/(0,jsx_runtime.jsx)("span", {
|
|
|
|
|
style: {
|
|
|
|
|
color: text === 'leader' ? '#3061D0' : '#01795D'
|
|
|
|
|
color: '#FA6400',
|
|
|
|
|
display: 'inline-flex',
|
|
|
|
|
width: 48,
|
|
|
|
|
height: 22,
|
|
|
|
|
borderRadius: 4,
|
|
|
|
|
lineHeight: '22px',
|
|
|
|
|
background: '#FEEADC',
|
|
|
|
|
textAlign: 'center',
|
|
|
|
|
marginLeft: 10,
|
|
|
|
|
justifyContent: 'center',
|
|
|
|
|
fontSize: 12
|
|
|
|
|
},
|
|
|
|
|
children: "\u521B\u5EFA\u8005"
|
|
|
|
|
})]
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
title: '操作',
|
|
|
|
|
align: 'right',
|
|
|
|
|
width: 150,
|
|
|
|
|
dataIndex: 'role',
|
|
|
|
|
render: function render(text, items, index) {
|
|
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsxs)("span", {
|
|
|
|
|
style: {
|
|
|
|
|
color: '#3061D0'
|
|
|
|
|
},
|
|
|
|
|
children: [text != "leader" && /*#__PURE__*/(0,jsx_runtime.jsx)("a", {
|
|
|
|
|
onClick: function onClick() {
|
|
|
|
|
var data = EditTeamItem;
|
|
|
|
|
var leaderindex = EditTeamItem && EditTeamItem.findIndex(function (item) {
|
|
|
|
|
return item.role === 'leader';
|
|
|
|
|
});
|
|
|
|
|
data[index].role = 'leader';
|
|
|
|
|
data[leaderindex].role = data && data[leaderindex].is_teacher ? 'teacher' : 'member';
|
|
|
|
|
//排序 规则为 队长永远只第一位 创建者只第二位
|
|
|
|
|
var datas = data.sort(function (item, item1) {
|
|
|
|
|
return item.creator ? -1 : 1;
|
|
|
|
|
}).sort(function (item, item1) {
|
|
|
|
|
return item.role === 'leader' ? -1 : 1;
|
|
|
|
|
});
|
|
|
|
|
setEditTeamItem(toConsumableArray_default()(datas));
|
|
|
|
|
leaderidRef.current = items.id;
|
|
|
|
|
},
|
|
|
|
|
children: "\u8BBE\u7F6E\u961F\u957F"
|
|
|
|
|
}), text != "leader" && /*#__PURE__*/(0,jsx_runtime.jsx)("a", {
|
|
|
|
|
onClick: function onClick() {
|
|
|
|
|
var data = EditTeamItem && EditTeamItem.filter(function (item) {
|
|
|
|
|
return item.id != items.id;
|
|
|
|
|
});
|
|
|
|
|
setEditTeamItem(toConsumableArray_default()(data));
|
|
|
|
|
},
|
|
|
|
|
children: [text === "leader" ? '队长' : '队员', (item === null || item === void 0 ? void 0 : item.creator) && /*#__PURE__*/(0,jsx_runtime.jsx)("span", {
|
|
|
|
|
style: {
|
|
|
|
|
color: '#FA6400',
|
|
|
|
|
display: 'inline-flex',
|
|
|
|
|
width: 48,
|
|
|
|
|
height: 22,
|
|
|
|
|
borderRadius: 4,
|
|
|
|
|
lineHeight: '22px',
|
|
|
|
|
background: '#FEEADC',
|
|
|
|
|
textAlign: 'center',
|
|
|
|
|
marginLeft: 10,
|
|
|
|
|
justifyContent: 'center',
|
|
|
|
|
fontSize: 12
|
|
|
|
|
},
|
|
|
|
|
children: "\u521B\u5EFA\u8005"
|
|
|
|
|
})]
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
title: '操作',
|
|
|
|
|
align: 'right',
|
|
|
|
|
width: 150,
|
|
|
|
|
dataIndex: 'role',
|
|
|
|
|
render: function render(text, items, index) {
|
|
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsxs)("span", {
|
|
|
|
|
style: {
|
|
|
|
|
color: '#3061D0'
|
|
|
|
|
marginLeft: 20
|
|
|
|
|
},
|
|
|
|
|
children: [text != "leader" && /*#__PURE__*/(0,jsx_runtime.jsx)("a", {
|
|
|
|
|
onClick: function onClick() {
|
|
|
|
|
var data = EditTeamItem;
|
|
|
|
|
var leaderindex = EditTeamItem && EditTeamItem.findIndex(function (item) {
|
|
|
|
|
return item.role === 'leader';
|
|
|
|
|
});
|
|
|
|
|
data[index].role = 'leader';
|
|
|
|
|
data[leaderindex].role = data && data[leaderindex].is_teacher ? 'teacher' : 'member';
|
|
|
|
|
//排序 规则为 队长永远只第一位 创建者只第二位
|
|
|
|
|
var datas = data.sort(function (item, item1) {
|
|
|
|
|
return item.creator ? -1 : 1;
|
|
|
|
|
}).sort(function (item, item1) {
|
|
|
|
|
return item.role === 'leader' ? -1 : 1;
|
|
|
|
|
});
|
|
|
|
|
setEditTeamItem(toConsumableArray_default()(datas));
|
|
|
|
|
leaderidRef.current = items.id;
|
|
|
|
|
},
|
|
|
|
|
children: "\u8BBE\u7F6E\u961F\u957F"
|
|
|
|
|
}), text != "leader" && /*#__PURE__*/(0,jsx_runtime.jsx)("a", {
|
|
|
|
|
onClick: function onClick() {
|
|
|
|
|
var data = EditTeamItem && EditTeamItem.filter(function (item) {
|
|
|
|
|
return item.id != items.id;
|
|
|
|
|
});
|
|
|
|
|
setEditTeamItem(toConsumableArray_default()(data));
|
|
|
|
|
},
|
|
|
|
|
style: {
|
|
|
|
|
marginLeft: 20
|
|
|
|
|
},
|
|
|
|
|
children: "\u5220\u9664"
|
|
|
|
|
})]
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}]
|
|
|
|
|
})
|
|
|
|
|
children: "\u5220\u9664"
|
|
|
|
|
})]
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}]
|
|
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsxs)("div", {
|
|
|
|
|
className: Teammodules.bottom,
|
|
|
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsx)(es_button/* default */.Z, {
|
|
|
|
|
@ -15467,7 +15444,7 @@ var Edit_Team_competitionsPage = function competitionsPage(_ref) {
|
|
|
|
|
}, [Header]);
|
|
|
|
|
var columns = [{
|
|
|
|
|
title: '序号',
|
|
|
|
|
align: 'center',
|
|
|
|
|
align: 'left',
|
|
|
|
|
dataIndex: 'name',
|
|
|
|
|
width: 80,
|
|
|
|
|
render: function render(text, item, index) {
|
|
|
|
|
@ -15477,7 +15454,7 @@ var Edit_Team_competitionsPage = function competitionsPage(_ref) {
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
title: '参赛人',
|
|
|
|
|
align: 'center',
|
|
|
|
|
align: 'left',
|
|
|
|
|
dataIndex: 'name',
|
|
|
|
|
width: 120,
|
|
|
|
|
ellipsis: {
|
|
|
|
|
@ -15492,7 +15469,7 @@ var Edit_Team_competitionsPage = function competitionsPage(_ref) {
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
title: '个人成绩',
|
|
|
|
|
align: 'center',
|
|
|
|
|
align: 'left',
|
|
|
|
|
width: 100,
|
|
|
|
|
dataIndex: 'score',
|
|
|
|
|
render: function render(text) {
|
|
|
|
|
@ -15502,7 +15479,7 @@ var Edit_Team_competitionsPage = function competitionsPage(_ref) {
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
title: '角色',
|
|
|
|
|
align: 'center',
|
|
|
|
|
align: 'left',
|
|
|
|
|
width: 100,
|
|
|
|
|
dataIndex: 'identity',
|
|
|
|
|
render: function render(text) {
|
|
|
|
|
@ -15512,7 +15489,7 @@ var Edit_Team_competitionsPage = function competitionsPage(_ref) {
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
title: '手机号',
|
|
|
|
|
align: 'center',
|
|
|
|
|
align: 'left',
|
|
|
|
|
width: 120,
|
|
|
|
|
dataIndex: 'phone',
|
|
|
|
|
render: function render(text) {
|
|
|
|
|
@ -15522,7 +15499,7 @@ var Edit_Team_competitionsPage = function competitionsPage(_ref) {
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
title: '学号/工号',
|
|
|
|
|
align: 'center',
|
|
|
|
|
align: 'left',
|
|
|
|
|
dataIndex: 'student_id',
|
|
|
|
|
width: 120,
|
|
|
|
|
ellipsis: {
|
|
|
|
|
@ -15537,7 +15514,7 @@ var Edit_Team_competitionsPage = function competitionsPage(_ref) {
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
title: '学校/单位',
|
|
|
|
|
align: 'center',
|
|
|
|
|
align: 'left',
|
|
|
|
|
dataIndex: 'school',
|
|
|
|
|
ellipsis: {
|
|
|
|
|
showTitle: false
|
|
|
|
|
@ -15551,7 +15528,7 @@ var Edit_Team_competitionsPage = function competitionsPage(_ref) {
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
title: '地区',
|
|
|
|
|
align: 'center',
|
|
|
|
|
align: 'left',
|
|
|
|
|
dataIndex: 'province',
|
|
|
|
|
width: 100,
|
|
|
|
|
ellipsis: {
|
|
|
|
|
@ -15566,7 +15543,7 @@ var Edit_Team_competitionsPage = function competitionsPage(_ref) {
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
title: '操作',
|
|
|
|
|
align: 'center',
|
|
|
|
|
align: 'right',
|
|
|
|
|
dataIndex: 'is_cancel_score',
|
|
|
|
|
width: 100,
|
|
|
|
|
render: function render(text, item) {
|
|
|
|
|
@ -15715,7 +15692,7 @@ var Edit_Team_competitionsPage = function competitionsPage(_ref) {
|
|
|
|
|
},
|
|
|
|
|
children: [Header !== null && Header !== void 0 && Header.personal ? /*#__PURE__*/(0,jsx_runtime.jsxs)("div", {
|
|
|
|
|
style: {
|
|
|
|
|
padding: '20px 30px',
|
|
|
|
|
padding: '20px',
|
|
|
|
|
width: '100%'
|
|
|
|
|
},
|
|
|
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsxs)("div", {
|
|
|
|
|
@ -15763,6 +15740,7 @@ var Edit_Team_competitionsPage = function competitionsPage(_ref) {
|
|
|
|
|
marginTop: 20
|
|
|
|
|
},
|
|
|
|
|
columns: columns,
|
|
|
|
|
bordered: false,
|
|
|
|
|
dataSource: userList === null || userList === void 0 ? void 0 : userList.data,
|
|
|
|
|
pagination: false
|
|
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsx)("div", {
|
|
|
|
|
|