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.
529 lines
23 KiB
529 lines
23 KiB
"use strict";
|
|
(self["webpackChunk"] = self["webpackChunk"] || []).push([[8999],{
|
|
|
|
/***/ 49235:
|
|
/*!***********************************************!*\
|
|
!*** ./src/pages/Three/index.tsx + 5 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 */ pages_Three; }
|
|
});
|
|
|
|
// EXTERNAL MODULE: ./node_modules/_react@17.0.2@react/index.js
|
|
var _react_17_0_2_react = __webpack_require__(59301);
|
|
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/menu/index.js + 11 modules
|
|
var menu = __webpack_require__(20834);
|
|
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/layout/index.js
|
|
var layout = __webpack_require__(44000);
|
|
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/message/index.js + 4 modules
|
|
var message = __webpack_require__(8591);
|
|
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/modal/index.js + 16 modules
|
|
var modal = __webpack_require__(43418);
|
|
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/popover/index.js
|
|
var popover = __webpack_require__(60324);
|
|
// EXTERNAL MODULE: ./src/utils/env.ts + 1 modules
|
|
var env = __webpack_require__(21873);
|
|
;// CONCATENATED MODULE: ./src/pages/Three/index.less?modules
|
|
// extracted by mini-css-extract-plugin
|
|
/* harmony default export */ var Threemodules = ({"flex_box_center":"flex_box_center___GfbI9","flex_space_between":"flex_space_between___m14JJ","flex_box_vertical_center":"flex_box_vertical_center___IKGDg","flex_box_center_end":"flex_box_center_end___JZxvM","flex_box_column":"flex_box_column___WnVa8","SubMentItem":"SubMentItem___P0LXo","MenuItem":"MenuItem___p91mQ","wrp":"wrp___kMQ4i","classroomInfo":"classroomInfo___rb1qC","title":"title___AQndp","titleLeft":"titleLeft___K7c9u","titleRight":"titleRight___BUODH","classroomUser":"classroomUser___NkYxe","headPic":"headPic___RD_it","teacherInfo":"teacherInfo___Gyj_W","classroomDesc":"classroomDesc___ng_AB","classroomDescBg":"classroomDescBg___Dz_DM","joinCouses":"joinCouses___U2D0G","bg":"bg___IcypX","leftMenus":"leftMenus___fF5qD","titleSelected":"titleSelected___Rqtd8","menuText":"menuText___jhrfq","totalCount":"totalCount___fqkbl","actions":"actions___NAYZl","task_count":"task_count___a1sYB","container":"container___djeCS","leftMenuActions":"leftMenuActions___lRhBF"});
|
|
// EXTERNAL MODULE: ./src/utils/fetch.ts
|
|
var fetch = __webpack_require__(51165);
|
|
// EXTERNAL MODULE: ./src/.umi-production/exports.ts + 15 modules
|
|
var _umi_production_exports = __webpack_require__(67866);
|
|
// EXTERNAL MODULE: ./node_modules/_@ant-design_icons@5.3.7@@ant-design/icons/es/icons/ExclamationCircleOutlined.js + 1 modules
|
|
var ExclamationCircleOutlined = __webpack_require__(88289);
|
|
// EXTERNAL MODULE: ./node_modules/_@ant-design_icons@5.3.7@@ant-design/icons/es/icons/PlusSquareOutlined.js + 1 modules
|
|
var PlusSquareOutlined = __webpack_require__(38391);
|
|
// EXTERNAL MODULE: ./src/utils/authority.ts
|
|
var authority = __webpack_require__(88141);
|
|
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/input/index.js + 5 modules
|
|
var input = __webpack_require__(98135);
|
|
;// CONCATENATED MODULE: ./src/pages/Three/Model/AddModel.tsx
|
|
var __async = (__this, __arguments, generator) => {
|
|
return new Promise((resolve, reject) => {
|
|
var fulfilled = (value) => {
|
|
try {
|
|
step(generator.next(value));
|
|
} catch (e) {
|
|
reject(e);
|
|
}
|
|
};
|
|
var rejected = (value) => {
|
|
try {
|
|
step(generator.throw(value));
|
|
} catch (e) {
|
|
reject(e);
|
|
}
|
|
};
|
|
var step = (x) => x.done ? resolve(x.value) : Promise.resolve(x.value).then(fulfilled, rejected);
|
|
step((generator = generator.apply(__this, __arguments)).next());
|
|
});
|
|
};
|
|
|
|
|
|
|
|
|
|
function Addmodel({ user, CategoryId, IsShow, setIsShow, dispatch, init }) {
|
|
const [CategoryName, setCategoryName] = (0,_react_17_0_2_react.useState)();
|
|
return /* @__PURE__ */ _react_17_0_2_react.createElement(
|
|
modal["default"],
|
|
{
|
|
title: CategoryId ? "\u65B0\u5EFA\u4E09\u7EA7\u7C7B\u76EE" : "\u65B0\u5EFA\u4E8C\u7EA7\u7C7B\u76EE",
|
|
width: 424,
|
|
onCancel: () => {
|
|
setIsShow(false);
|
|
},
|
|
onOk: () => __async(this, null, function* () {
|
|
if (!CategoryName) {
|
|
message/* default */.ZP.error("\u680F\u76EE\u540D\u4E0D\u80FD\u4E3A\u7A7A");
|
|
return;
|
|
}
|
|
const res = yield (0,fetch/* default */.ZP)(
|
|
`/api/programas.json`,
|
|
{
|
|
method: "post",
|
|
body: {
|
|
name: CategoryName,
|
|
parent_id: CategoryId
|
|
}
|
|
}
|
|
);
|
|
if (res.status === 0) {
|
|
message/* default */.ZP.info("\u521B\u5EFA\u6210\u529F");
|
|
setIsShow(false);
|
|
setCategoryName("");
|
|
init();
|
|
}
|
|
}),
|
|
open: IsShow
|
|
},
|
|
/* @__PURE__ */ _react_17_0_2_react.createElement(input["default"], { value: CategoryName, onChange: (e) => setCategoryName(e.target.value), placeholder: "\u8BF7\u8F93\u5165\u4E0D\u8D85\u8FC710\u4E2A\u6C49\u5B57\u7684\u540D\u79F0", maxLength: 10 })
|
|
);
|
|
}
|
|
/* harmony default export */ var AddModel = ((0,_umi_production_exports.connect)(
|
|
({
|
|
user
|
|
}) => ({
|
|
user
|
|
})
|
|
)(Addmodel));
|
|
|
|
;// CONCATENATED MODULE: ./src/pages/Three/Model/UpdateNameModel.tsx
|
|
var UpdateNameModel_async = (__this, __arguments, generator) => {
|
|
return new Promise((resolve, reject) => {
|
|
var fulfilled = (value) => {
|
|
try {
|
|
step(generator.next(value));
|
|
} catch (e) {
|
|
reject(e);
|
|
}
|
|
};
|
|
var rejected = (value) => {
|
|
try {
|
|
step(generator.throw(value));
|
|
} catch (e) {
|
|
reject(e);
|
|
}
|
|
};
|
|
var step = (x) => x.done ? resolve(x.value) : Promise.resolve(x.value).then(fulfilled, rejected);
|
|
step((generator = generator.apply(__this, __arguments)).next());
|
|
});
|
|
};
|
|
|
|
|
|
|
|
|
|
function UpdateNameModel_Addmodel({ user, CategoryId, name, IsShow, setIsShow, dispatch, init }) {
|
|
const [CategoryName, setCategoryName] = (0,_react_17_0_2_react.useState)();
|
|
(0,_react_17_0_2_react.useEffect)(() => {
|
|
setCategoryName(name);
|
|
}, [name]);
|
|
return /* @__PURE__ */ _react_17_0_2_react.createElement(
|
|
modal["default"],
|
|
{
|
|
title: "\u76EE\u5F55\u91CD\u547D\u540D",
|
|
width: 424,
|
|
onCancel: () => {
|
|
setIsShow(false);
|
|
},
|
|
onOk: () => UpdateNameModel_async(this, null, function* () {
|
|
if (!CategoryName) {
|
|
message/* default */.ZP.error("\u680F\u76EE\u540D\u4E0D\u80FD\u4E3A\u7A7A");
|
|
return;
|
|
}
|
|
const res = yield (0,fetch/* default */.ZP)(
|
|
`/api/programas/${CategoryId}/rename.json`,
|
|
{
|
|
method: "put",
|
|
body: {
|
|
name: CategoryName,
|
|
id: CategoryId
|
|
}
|
|
}
|
|
);
|
|
if (res.status === 0) {
|
|
message/* default */.ZP.info("\u4FEE\u6539\u6210\u529F");
|
|
setIsShow(false);
|
|
setCategoryName("");
|
|
init();
|
|
}
|
|
}),
|
|
open: IsShow
|
|
},
|
|
/* @__PURE__ */ _react_17_0_2_react.createElement(input["default"], { value: CategoryName, onChange: (e) => setCategoryName(e.target.value), placeholder: "\u8BF7\u8F93\u5165\u4E0D\u8D85\u8FC710\u4E2A\u6C49\u5B57\u7684\u540D\u79F0", maxLength: 10 })
|
|
);
|
|
}
|
|
/* harmony default export */ var UpdateNameModel = ((0,_umi_production_exports.connect)(
|
|
({
|
|
user
|
|
}) => ({
|
|
user
|
|
})
|
|
)(UpdateNameModel_Addmodel));
|
|
|
|
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/button/index.js
|
|
var es_button = __webpack_require__(3113);
|
|
// EXTERNAL MODULE: ./src/components/RenderHtml/index.tsx
|
|
var RenderHtml = __webpack_require__(16921);
|
|
;// CONCATENATED MODULE: ./src/pages/Three/Item/SeeItem.tsx
|
|
|
|
|
|
|
|
|
|
|
|
function Seeitem({ user, ItemData, setIssee, dispatch, init }) {
|
|
var _a, _b, _c, _d;
|
|
return /* @__PURE__ */ _react_17_0_2_react.createElement("div", null, /* @__PURE__ */ _react_17_0_2_react.createElement("div", { style: { textAlign: "right" } }, (0,authority/* isSuperAdmins */.Ny)() && /* @__PURE__ */ _react_17_0_2_react.createElement(es_button/* default */.ZP, { onClick: () => setIssee(false) }, "\u7F16\u8F91")), /* @__PURE__ */ _react_17_0_2_react.createElement(RenderHtml/* default */.Z, { value: ItemData.content }), ((_a = ItemData == null ? void 0 : ItemData.attachment) == null ? void 0 : _a.id) && /* @__PURE__ */ _react_17_0_2_react.createElement("div", null, /* @__PURE__ */ _react_17_0_2_react.createElement("a", { href: (_b = ItemData == null ? void 0 : ItemData.attachment) == null ? void 0 : _b.url, target: "_self", download: (_c = ItemData == null ? void 0 : ItemData.attachment) == null ? void 0 : _c.title }, /* @__PURE__ */ _react_17_0_2_react.createElement("i", { style: { color: "#29BD8B" }, className: "font-14 color-green iconfont icon-fujian mr8" }), /* @__PURE__ */ _react_17_0_2_react.createElement("span", { style: { color: "#000000" } }, (_d = ItemData == null ? void 0 : ItemData.attachment) == null ? void 0 : _d.title))));
|
|
}
|
|
/* harmony default export */ var SeeItem = ((0,_umi_production_exports.connect)(
|
|
({
|
|
user
|
|
}) => ({
|
|
user
|
|
})
|
|
)(Seeitem));
|
|
|
|
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/upload/index.js + 24 modules
|
|
var upload = __webpack_require__(46651);
|
|
// EXTERNAL MODULE: ./src/components/markdown-editor/index.tsx + 15 modules
|
|
var markdown_editor = __webpack_require__(96180);
|
|
// EXTERNAL MODULE: ./src/service/competitions.ts
|
|
var competitions = __webpack_require__(87472);
|
|
;// CONCATENATED MODULE: ./src/pages/Three/Item/UpdateItem.tsx
|
|
var __defProp = Object.defineProperty;
|
|
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
var __spreadValues = (a, b) => {
|
|
for (var prop in b || (b = {}))
|
|
if (__hasOwnProp.call(b, prop))
|
|
__defNormalProp(a, prop, b[prop]);
|
|
if (__getOwnPropSymbols)
|
|
for (var prop of __getOwnPropSymbols(b)) {
|
|
if (__propIsEnum.call(b, prop))
|
|
__defNormalProp(a, prop, b[prop]);
|
|
}
|
|
return a;
|
|
};
|
|
var UpdateItem_async = (__this, __arguments, generator) => {
|
|
return new Promise((resolve, reject) => {
|
|
var fulfilled = (value) => {
|
|
try {
|
|
step(generator.next(value));
|
|
} catch (e) {
|
|
reject(e);
|
|
}
|
|
};
|
|
var rejected = (value) => {
|
|
try {
|
|
step(generator.throw(value));
|
|
} catch (e) {
|
|
reject(e);
|
|
}
|
|
};
|
|
var step = (x) => x.done ? resolve(x.value) : Promise.resolve(x.value).then(fulfilled, rejected);
|
|
step((generator = generator.apply(__this, __arguments)).next());
|
|
});
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
function UpItem({ user, ItemData, setIssee, CategoryId, dispatch, init }) {
|
|
let [defaultFileList, setDefaultFileList] = (0,_react_17_0_2_react.useState)([]);
|
|
const [defaultcontent, setDefaultcontent] = (0,_react_17_0_2_react.useState)(ItemData.content);
|
|
function getdata() {
|
|
var _a;
|
|
let data = [];
|
|
(_a = ItemData == null ? void 0 : ItemData.attachments) == null ? void 0 : _a.map((item) => {
|
|
let tt = { uid: item == null ? void 0 : item.id, name: item.title, response: { id: item.id } };
|
|
data.push(tt);
|
|
});
|
|
return data;
|
|
}
|
|
const uploadProps = {
|
|
name: "file",
|
|
multiple: true,
|
|
action: env/* default */.Z.API_SERVER + "/api/attachments.json",
|
|
defaultFileList: getdata(),
|
|
onRemove(e) {
|
|
(0,competitions/* deletAttachments */.y8)({ id: e.uid });
|
|
},
|
|
onChange(info) {
|
|
console.log("info", info);
|
|
const { status } = info.file;
|
|
if (status !== "uploading") {
|
|
}
|
|
if (status === "removed") {
|
|
setDefaultFileList(info.fileList);
|
|
}
|
|
if (status === "done") {
|
|
setDefaultFileList(info.fileList);
|
|
message/* default */.ZP.success(`${info.file.name} \u6587\u4EF6\u4E0A\u4F20\u6210\u529F`);
|
|
} else if (status === "error") {
|
|
message/* default */.ZP.error(`${info.file.name} \u6587\u4EF6\u4E0A\u4F20\u5931\u8D25`);
|
|
}
|
|
},
|
|
beforeUpload: (file) => {
|
|
const isLt150M = file.size / 1024 / 1024 < 150;
|
|
if (!isLt150M) {
|
|
message/* default */.ZP.info("\u6587\u4EF6\u5927\u5C0F\u5FC5\u987B\u5C0F\u4E8E150MB");
|
|
}
|
|
return isLt150M;
|
|
}
|
|
};
|
|
function updateItem() {
|
|
return UpdateItem_async(this, null, function* () {
|
|
const res = yield (0,fetch/* default */.ZP)(
|
|
`/api/programas/${CategoryId}/update_content.json`,
|
|
{
|
|
method: "put",
|
|
body: {
|
|
id: CategoryId,
|
|
content: defaultcontent,
|
|
attachment_id: getitemid(defaultFileList)
|
|
}
|
|
}
|
|
);
|
|
if (res) {
|
|
message/* default */.ZP.info("\u63D0\u4EA4\u6210\u529F");
|
|
setIssee(true);
|
|
}
|
|
});
|
|
}
|
|
function getitemid(itemlist) {
|
|
let data;
|
|
itemlist && itemlist.map((item) => {
|
|
data = item.response.id;
|
|
});
|
|
return data;
|
|
}
|
|
return /* @__PURE__ */ _react_17_0_2_react.createElement("div", null, /* @__PURE__ */ _react_17_0_2_react.createElement(markdown_editor/* default */.Z, { defaultValue: defaultcontent, onChange: (e) => setDefaultcontent(e) }), /* @__PURE__ */ _react_17_0_2_react.createElement(upload["default"], __spreadValues({}, uploadProps), /* @__PURE__ */ _react_17_0_2_react.createElement(es_button/* default */.ZP, { className: "uploadBtn" }, "\u4E0A\u4F20\u9644\u4EF6"), "(\u5355\u4E2A\u6587\u4EF6150M\u4EE5\u5185)"), /* @__PURE__ */ _react_17_0_2_react.createElement("p", { style: { marginTop: "10px" } }, /* @__PURE__ */ _react_17_0_2_react.createElement(es_button/* default */.ZP, { style: { width: "90px" }, onClick: () => updateItem() }, "\u63D0\u4EA4"), /* @__PURE__ */ _react_17_0_2_react.createElement(es_button/* default */.ZP, { style: { marginLeft: "30px", width: "90px" }, type: "primary", onClick: () => setIssee(true) }, "\u53D6\u6D88")));
|
|
}
|
|
/* harmony default export */ var UpdateItem = ((0,_umi_production_exports.connect)(
|
|
({
|
|
user
|
|
}) => ({
|
|
user
|
|
})
|
|
)(UpItem));
|
|
|
|
;// CONCATENATED MODULE: ./src/pages/Three/index.tsx
|
|
var Three_async = (__this, __arguments, generator) => {
|
|
return new Promise((resolve, reject) => {
|
|
var fulfilled = (value) => {
|
|
try {
|
|
step(generator.next(value));
|
|
} catch (e) {
|
|
reject(e);
|
|
}
|
|
};
|
|
var rejected = (value) => {
|
|
try {
|
|
step(generator.throw(value));
|
|
} catch (e) {
|
|
reject(e);
|
|
}
|
|
};
|
|
var step = (x) => x.done ? resolve(x.value) : Promise.resolve(x.value).then(fulfilled, rejected);
|
|
step((generator = generator.apply(__this, __arguments)).next());
|
|
});
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
const { SubMenu } = menu["default"];
|
|
const { Content, Sider } = layout["default"];
|
|
function Three({ user, dispatch, globalSetting }) {
|
|
var _a;
|
|
const [LeftMenuList, setLeftMenuList] = (0,_react_17_0_2_react.useState)();
|
|
const [IsShowModel, setIsShowModel] = (0,_react_17_0_2_react.useState)(false);
|
|
const [CategoryList, setCategoryList] = (0,_react_17_0_2_react.useState)();
|
|
let [CategoryId, setCategoryId] = (0,_react_17_0_2_react.useState)();
|
|
const [UpdateShow, setUpdateShow] = (0,_react_17_0_2_react.useState)(false);
|
|
const [UpdateName, setUpdateName] = (0,_react_17_0_2_react.useState)("");
|
|
const [ItemCount, setItemCount] = (0,_react_17_0_2_react.useState)("");
|
|
const [IsSee, setIsSee] = (0,_react_17_0_2_react.useState)(true);
|
|
(0,_react_17_0_2_react.useEffect)(() => {
|
|
init();
|
|
}, []);
|
|
console.log("globalSetting", globalSetting);
|
|
function init() {
|
|
return Three_async(this, null, function* () {
|
|
const result = yield (0,fetch/* default */.ZP)(
|
|
`/api/programas.json`,
|
|
{
|
|
method: "get"
|
|
}
|
|
);
|
|
if (result) {
|
|
setCategoryList(result == null ? void 0 : result.programas);
|
|
}
|
|
});
|
|
}
|
|
const actionClick = (key, val, type) => Three_async(this, null, function* () {
|
|
switch (key) {
|
|
case 1:
|
|
setCategoryId(val == null ? void 0 : val.id);
|
|
setIsShowModel(true);
|
|
break;
|
|
case 2:
|
|
setCategoryId(val == null ? void 0 : val.id);
|
|
setUpdateShow(true);
|
|
setUpdateName(val == null ? void 0 : val.name);
|
|
break;
|
|
case 3:
|
|
let res = yield (0,fetch/* default */.ZP)(
|
|
`/api/programas/${val == null ? void 0 : val.id}/top.json`,
|
|
{
|
|
method: "post",
|
|
body: {
|
|
id: val == null ? void 0 : val.id
|
|
}
|
|
}
|
|
);
|
|
if (res.status === 0) {
|
|
init();
|
|
}
|
|
break;
|
|
case 4:
|
|
confirm(/* @__PURE__ */ _react_17_0_2_react.createElement("p", null, "\u5220\u9664\u4E4B\u540E\u4E0D\u80FD\u6062\u590D,", /* @__PURE__ */ _react_17_0_2_react.createElement("br", null), "\u662F\u5426\u786E\u8BA4\u5220\u9664?"), () => Three_async(this, null, function* () {
|
|
let res2 = yield (0,fetch/* default */.ZP)(
|
|
`/api/programas/${val == null ? void 0 : val.id}.json`,
|
|
{
|
|
method: "delete",
|
|
body: {
|
|
id: val == null ? void 0 : val.id
|
|
}
|
|
}
|
|
);
|
|
if (res2.status === 0) {
|
|
message/* default */.ZP.info("\u5220\u9664\u6210\u529F");
|
|
init();
|
|
}
|
|
}));
|
|
break;
|
|
}
|
|
});
|
|
const confirm = (content2, okCb) => {
|
|
modal["default"].confirm({
|
|
centered: true,
|
|
title: "\u63D0\u793A",
|
|
icon: /* @__PURE__ */ _react_17_0_2_react.createElement(ExclamationCircleOutlined/* default */.Z, null),
|
|
content: content2,
|
|
okText: "\u786E\u8BA4",
|
|
onOk: () => okCb(),
|
|
cancelText: "\u53D6\u6D88"
|
|
});
|
|
};
|
|
const content = (val, type) => {
|
|
return /* @__PURE__ */ _react_17_0_2_react.createElement("div", { className: Threemodules.leftMenuActions }, type === 1 && /* @__PURE__ */ _react_17_0_2_react.createElement("p", { className: "current", onClick: () => actionClick(1, val, type) }, "\u65B0\u5EFA"), /* @__PURE__ */ _react_17_0_2_react.createElement("p", { className: "current", onClick: () => actionClick(2, val, type) }, "\u91CD\u547D\u540D"), /* @__PURE__ */ _react_17_0_2_react.createElement("p", { className: "current", onClick: () => actionClick(3, val, type) }, "\u7F6E\u9876"), /* @__PURE__ */ _react_17_0_2_react.createElement("p", { className: "current", onClick: () => actionClick(4, val, type) }, "\u5220\u9664"));
|
|
};
|
|
function getItem2() {
|
|
return Three_async(this, null, function* () {
|
|
const result = yield (0,fetch/* default */.ZP)(
|
|
`/api/programas/${CategoryId}/content.json`,
|
|
{
|
|
method: "get",
|
|
params: {
|
|
id: CategoryId
|
|
}
|
|
}
|
|
);
|
|
if (result) {
|
|
setItemCount(result);
|
|
}
|
|
});
|
|
}
|
|
return /* @__PURE__ */ _react_17_0_2_react.createElement("div", { style: { marginBottom: "40px" } }, /* @__PURE__ */ _react_17_0_2_react.createElement("img", { style: { width: "100%" }, src: env/* default */.Z.IMG_SERVER + `/${(_a = globalSetting == null ? void 0 : globalSetting.setting) == null ? void 0 : _a.shixun_banner_url}` }), /* @__PURE__ */ _react_17_0_2_react.createElement("div", { className: "edu-container minH500", style: { display: "flex", width: "1200px" } }, /* @__PURE__ */ _react_17_0_2_react.createElement(
|
|
Sider,
|
|
{
|
|
width: 244,
|
|
className: Threemodules.leftMenus,
|
|
style: { background: "none", marginTop: "20px", height: "auto" }
|
|
},
|
|
/* @__PURE__ */ _react_17_0_2_react.createElement(
|
|
menu["default"],
|
|
{
|
|
mode: "inline"
|
|
},
|
|
CategoryList == null ? void 0 : CategoryList.map((item, index) => {
|
|
var _a2, _b;
|
|
if ((item == null ? void 0 : item.children.length) > 0) {
|
|
return /* @__PURE__ */ _react_17_0_2_react.createElement(SubMenu, { title: /* @__PURE__ */ _react_17_0_2_react.createElement("span", { className: "font16" }, /* @__PURE__ */ _react_17_0_2_react.createElement("span", null, item.name), !(0,authority/* isSuperAdmins */.Ny)() && /* @__PURE__ */ _react_17_0_2_react.createElement("span", null), (0,authority/* isSuperAdmins */.Ny)() && /* @__PURE__ */ _react_17_0_2_react.createElement(popover/* default */.Z, { placement: "right", content: () => content(item, 1), trigger: "hover" }, /* @__PURE__ */ _react_17_0_2_react.createElement("span", { className: ["iconfont icon-sandian", Threemodules.actions].join(" ") }))) }, (_a2 = item == null ? void 0 : item.children) == null ? void 0 : _a2.map((val, k) => {
|
|
var _a3;
|
|
return /* @__PURE__ */ _react_17_0_2_react.createElement(menu["default"].Item, { className: (_a3 = Threemodules) == null ? void 0 : _a3.SubMentItem, onClick: () => {
|
|
setCategoryId(val == null ? void 0 : val.id);
|
|
CategoryId = val == null ? void 0 : val.id;
|
|
getItem2();
|
|
} }, /* @__PURE__ */ _react_17_0_2_react.createElement("span", { style: { "flex": "1" } }, val == null ? void 0 : val.name), (0,authority/* isSuperAdmins */.Ny)() && /* @__PURE__ */ _react_17_0_2_react.createElement(popover/* default */.Z, { placement: "right", content: () => content(val, 2), trigger: "hover" }, /* @__PURE__ */ _react_17_0_2_react.createElement("span", { className: ["iconfont icon-sandian", Threemodules.actions].join(" ") })));
|
|
}));
|
|
} else {
|
|
return /* @__PURE__ */ _react_17_0_2_react.createElement(menu["default"].Item, { className: (_b = Threemodules) == null ? void 0 : _b.SubMentItem, onClick: () => {
|
|
setCategoryId(item == null ? void 0 : item.id);
|
|
CategoryId = item == null ? void 0 : item.id;
|
|
getItem2();
|
|
} }, /* @__PURE__ */ _react_17_0_2_react.createElement("span", { style: { "flex": "1" } }, item == null ? void 0 : item.name), (0,authority/* isSuperAdmins */.Ny)() && /* @__PURE__ */ _react_17_0_2_react.createElement(popover/* default */.Z, { placement: "right", content: () => content(item, 1), trigger: "hover" }, /* @__PURE__ */ _react_17_0_2_react.createElement("span", { className: ["iconfont icon-sandian", Threemodules.actions].join(" ") })));
|
|
}
|
|
}),
|
|
/* @__PURE__ */ _react_17_0_2_react.createElement(menu["default"].Item, { onClick: () => {
|
|
setCategoryId("");
|
|
CategoryId = "";
|
|
setIsShowModel(true);
|
|
}, style: { color: "#0152d9", fontSize: "16px", height: "40px", display: "flex", alignItems: "center" }, icon: /* @__PURE__ */ _react_17_0_2_react.createElement(PlusSquareOutlined/* default */.Z, { style: { color: "#0152d9", fontSize: "16px" } }) }, "\u65B0\u589E\u4E8C\u7EA7\u7C7B\u76EE")
|
|
)
|
|
), /* @__PURE__ */ _react_17_0_2_react.createElement("div", { style: { width: "937px", marginLeft: "17px", background: "#fff", padding: "20px" } }, IsSee && /* @__PURE__ */ _react_17_0_2_react.createElement(SeeItem, { ItemData: ItemCount, setIssee: setIsSee }), IsSee === false && /* @__PURE__ */ _react_17_0_2_react.createElement(UpdateItem, { ItemData: ItemCount, setIssee: setIsSee, CategoryId }))), /* @__PURE__ */ _react_17_0_2_react.createElement(AddModel, { CategoryId, IsShow: IsShowModel, setIsShow: setIsShowModel, init }), /* @__PURE__ */ _react_17_0_2_react.createElement(UpdateNameModel, { CategoryId, name: UpdateName, IsShow: UpdateShow, setIsShow: setUpdateShow, init }));
|
|
}
|
|
/* harmony default export */ var pages_Three = ((0,_umi_production_exports.connect)(
|
|
({
|
|
user,
|
|
globalSetting
|
|
}) => ({
|
|
user,
|
|
globalSetting
|
|
})
|
|
)(Three));
|
|
|
|
|
|
/***/ })
|
|
|
|
}]); |