You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
182 lines
7.3 KiB
182 lines
7.3 KiB
"use strict";
|
|
(self["webpackChunk"] = self["webpackChunk"] || []).push([[4766],{
|
|
|
|
/***/ 30592:
|
|
/*!********************************************************!*\
|
|
!*** ./src/pages/Administration/index.tsx + 3 modules ***!
|
|
\********************************************************/
|
|
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
|
|
// ESM COMPAT FLAG
|
|
__webpack_require__.r(__webpack_exports__);
|
|
|
|
// EXPORTS
|
|
__webpack_require__.d(__webpack_exports__, {
|
|
"default": function() { return /* binding */ Administration; }
|
|
});
|
|
|
|
// EXTERNAL MODULE: ./node_modules/_react@17.0.2@react/index.js
|
|
var _react_17_0_2_react = __webpack_require__(59301);
|
|
// EXTERNAL MODULE: ./src/.umi-production/exports.ts + 15 modules
|
|
var _umi_production_exports = __webpack_require__(67866);
|
|
;// CONCATENATED MODULE: ./src/pages/Administration/Menus/index.less?modules
|
|
// extracted by mini-css-extract-plugin
|
|
/* harmony default export */ var Menusmodules = ({"flex_box_center":"flex_box_center___TmpWE","flex_space_between":"flex_space_between___Bjf8w","flex_box_vertical_center":"flex_box_vertical_center___nuFqj","flex_box_center_end":"flex_box_center_end___RYxm7","flex_box_column":"flex_box_column___syP9g","menuWrap":"menuWrap___dJHW2","crumbs":"crumbs____3ctW","info":"info___Hujtz","avatar":"avatar___dZUkn","name":"name___P95aR","approve":"approve___s79Kr","number":"number___hl4qV","attendance":"attendance___o1MZq","btn":"btn___I4UFW","nav":"nav___nxA0m","active":"active___e5byT"});
|
|
;// CONCATENATED MODULE: ./src/pages/Administration/Menus/index.tsx
|
|
/* provided dependency */ var React = __webpack_require__(/*! react */ 59301);
|
|
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
var __objRest = (source, exclude) => {
|
|
var target = {};
|
|
for (var prop in source)
|
|
if (__hasOwnProp.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
target[prop] = source[prop];
|
|
if (source != null && __getOwnPropSymbols)
|
|
for (var prop of __getOwnPropSymbols(source)) {
|
|
if (exclude.indexOf(prop) < 0 && __propIsEnum.call(source, prop))
|
|
target[prop] = source[prop];
|
|
}
|
|
return target;
|
|
};
|
|
|
|
|
|
|
|
var NavType = /* @__PURE__ */ ((NavType2) => {
|
|
NavType2["College"] = "college";
|
|
NavType2["Student"] = "student";
|
|
NavType2["Profession"] = "profession";
|
|
return NavType2;
|
|
})(NavType || {});
|
|
const Banner = (_a) => {
|
|
var _b = _a, {
|
|
userDetail,
|
|
user,
|
|
globalSetting,
|
|
loading,
|
|
dispatch
|
|
} = _b, props = __objRest(_b, [
|
|
"userDetail",
|
|
"user",
|
|
"globalSetting",
|
|
"loading",
|
|
"dispatch"
|
|
]);
|
|
const location = (0,_umi_production_exports.useLocation)();
|
|
const [activeKey, setActiveKey] = (0,_react_17_0_2_react.useState)();
|
|
(0,_react_17_0_2_react.useEffect)(() => {
|
|
var _a2;
|
|
const active = (_a2 = location.pathname.split("/")) == null ? void 0 : _a2[2];
|
|
setActiveKey(active || "college" /* College */);
|
|
}, [location.pathname]);
|
|
return /* @__PURE__ */ React.createElement("div", { className: Menusmodules.menuWrap }, /* @__PURE__ */ React.createElement("div", { className: Menusmodules.nav }, /* @__PURE__ */ React.createElement(
|
|
_umi_production_exports.Link,
|
|
{
|
|
to: `/administration/college`,
|
|
onClick: () => setActiveKey("college" /* College */),
|
|
className: activeKey === "college" /* College */ ? Menusmodules.active : ""
|
|
},
|
|
/* @__PURE__ */ React.createElement("i", { className: "iconfont icon-xueyuanguanli" }),
|
|
"\u5B66\u9662\u7BA1\u7406"
|
|
), /* @__PURE__ */ React.createElement(
|
|
_umi_production_exports.Link,
|
|
{
|
|
to: `/administration/profession`,
|
|
onClick: () => setActiveKey("profession" /* Profession */),
|
|
className: activeKey === "profession" /* Profession */ ? Menusmodules.active : ""
|
|
},
|
|
/* @__PURE__ */ React.createElement("i", { className: "iconfont icon-zhuanyeguanli" }),
|
|
"\u4E13\u4E1A\u7BA1\u7406"
|
|
), /* @__PURE__ */ React.createElement(
|
|
_umi_production_exports.Link,
|
|
{
|
|
to: `/administration/student`,
|
|
onClick: () => setActiveKey("student" /* Student */),
|
|
className: activeKey === "student" /* Student */ ? Menusmodules.active : ""
|
|
},
|
|
/* @__PURE__ */ React.createElement("i", { className: "iconfont icon-xueshengguanli" }),
|
|
"\u5B66\u751F\u7BA1\u7406"
|
|
)));
|
|
};
|
|
/* harmony default export */ var Menus = ((0,_umi_production_exports.connect)(
|
|
({
|
|
user,
|
|
userDetail,
|
|
loading,
|
|
globalSetting
|
|
}) => ({
|
|
user,
|
|
userDetail,
|
|
globalSetting,
|
|
loading: loading.models.index
|
|
})
|
|
)(Banner));
|
|
|
|
;// CONCATENATED MODULE: ./src/pages/Administration/index.less?modules
|
|
// extracted by mini-css-extract-plugin
|
|
/* harmony default export */ var Administrationmodules = ({"flex_box_center":"flex_box_center___trUXH","flex_space_between":"flex_space_between___rHQmt","flex_box_vertical_center":"flex_box_vertical_center___sEm8i","flex_box_center_end":"flex_box_center_end___S8dYj","flex_box_column":"flex_box_column___HtszC","content":"content___QG_E5","leftBox":"leftBox___aL8K5","leftWrap":"leftWrap___ga_2r","rightBox":"rightBox___i71jY","rightWrap":"rightWrap___ov0Lw","hiddenBar":"hiddenBar___iIalG"});
|
|
;// CONCATENATED MODULE: ./src/pages/Administration/index.tsx
|
|
|
|
|
|
|
|
|
|
const UserDetailPage = ({
|
|
userDetail,
|
|
globalSetting,
|
|
loading,
|
|
dispatch
|
|
}) => {
|
|
const params = (0,_umi_production_exports.useParams)();
|
|
const username = (0,_react_17_0_2_react.useRef)();
|
|
const [overflow, setOverflow] = (0,_react_17_0_2_react.useState)(false);
|
|
(0,_react_17_0_2_react.useEffect)(() => {
|
|
if ((location == null ? void 0 : location.pathname) === "/administration") {
|
|
_umi_production_exports.history.replace("/administration/college");
|
|
}
|
|
document.title = "\u9AD8\u6821\u7BA1\u7406";
|
|
}, [location == null ? void 0 : location.pathname]);
|
|
(0,_react_17_0_2_react.useEffect)(() => {
|
|
username.current = params.username;
|
|
dispatch({
|
|
type: "globalSetting/footerToggle",
|
|
payload: false
|
|
});
|
|
return () => {
|
|
dispatch({
|
|
type: "globalSetting/footerToggle",
|
|
payload: true
|
|
});
|
|
};
|
|
}, [params]);
|
|
const handleMouseEnter = (event) => {
|
|
const element = event.currentTarget;
|
|
if (element.scrollHeight > element.clientHeight) {
|
|
setOverflow(true);
|
|
}
|
|
};
|
|
return /* @__PURE__ */ _react_17_0_2_react.createElement("div", { className: Administrationmodules.content }, /* @__PURE__ */ _react_17_0_2_react.createElement("div", { className: Administrationmodules.leftBox }, /* @__PURE__ */ _react_17_0_2_react.createElement(
|
|
"div",
|
|
{
|
|
className: `${Administrationmodules.leftWrap} ${overflow ? "" : Administrationmodules.hiddenBar}`,
|
|
onMouseEnter: handleMouseEnter,
|
|
onMouseLeave: () => setOverflow(false)
|
|
},
|
|
/* @__PURE__ */ _react_17_0_2_react.createElement(Menus, null)
|
|
)), /* @__PURE__ */ _react_17_0_2_react.createElement("div", { className: Administrationmodules.rightBox }, /* @__PURE__ */ _react_17_0_2_react.createElement("div", { className: Administrationmodules.rightWrap }, /* @__PURE__ */ _react_17_0_2_react.createElement(_umi_production_exports.Outlet, null))));
|
|
};
|
|
/* harmony default export */ var Administration = ((0,_umi_production_exports.connect)(
|
|
({
|
|
userDetail,
|
|
loading,
|
|
globalSetting
|
|
}) => ({
|
|
userDetail,
|
|
globalSetting,
|
|
loading: loading.models.index
|
|
})
|
|
)(UserDetailPage));
|
|
|
|
|
|
/***/ })
|
|
|
|
}]); |