|
|
|
|
@ -20010,7 +20010,7 @@ var knowledge_Atlas = function Atlas(_ref) {
|
|
|
|
|
})(knowledge_Atlas));
|
|
|
|
|
;// CONCATENATED MODULE: ./src/pages/Paths/Detail/components/LearnPath/index.less?modules
|
|
|
|
|
// extracted by mini-css-extract-plugin
|
|
|
|
|
/* harmony default export */ var LearnPathmodules = ({"pathWrap":"pathWrap___jfkaP","errorStatus":"errorStatus___Isj1L","successStatus":"successStatus___zwDAO","nameSty":"nameSty___ilLoy","iconSty":"iconSty___xRU86","iconSty2":"iconSty2___DEXqI"});
|
|
|
|
|
/* harmony default export */ var LearnPathmodules = ({"Onerow":"Onerow___SgNuO","pathWrap":"pathWrap___jfkaP","errorStatus":"errorStatus___Isj1L","successStatus":"successStatus___zwDAO","nameSty":"nameSty___ilLoy","iconSty":"iconSty___xRU86","iconSty2":"iconSty2___DEXqI","detailWrap":"detailWrap___pcT2p","itemWrap":"itemWrap___FQv9Y","titleWrap":"titleWrap___rGR33","lineSty":"lineSty___qKNvs","imgWrap":"imgWrap___APzGK","chatTitle":"chatTitle___PkEhe"});
|
|
|
|
|
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/breadcrumb/index.js + 6 modules
|
|
|
|
|
var breadcrumb = __webpack_require__(66104);
|
|
|
|
|
// EXTERNAL MODULE: ./node_modules/_@ant-design_icons@5.5.1@@ant-design/icons/es/icons/CloseCircleFilled.js + 1 modules
|
|
|
|
|
@ -20048,7 +20048,7 @@ var NewLearnPathPage = function NewLearnPathPage(_ref) {
|
|
|
|
|
form = _Form$useForm2[0];
|
|
|
|
|
var _useState = (0,_react_17_0_2_react.useState)({
|
|
|
|
|
mode: 1,
|
|
|
|
|
status: 0
|
|
|
|
|
status: 1
|
|
|
|
|
}),
|
|
|
|
|
_useState2 = slicedToArray_default()(_useState, 2),
|
|
|
|
|
formValue = _useState2[0],
|
|
|
|
|
@ -20811,7 +20811,7 @@ var NewLearnPathPage = function NewLearnPathPage(_ref) {
|
|
|
|
|
,
|
|
|
|
|
initialValues: {
|
|
|
|
|
mode: 1,
|
|
|
|
|
status: 0
|
|
|
|
|
status: 1
|
|
|
|
|
},
|
|
|
|
|
onFinish: handleFinish,
|
|
|
|
|
onValuesChange: function onValuesChange() {
|
|
|
|
|
@ -21561,7 +21561,6 @@ var AsyncButton = __webpack_require__(56229);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var LearnPath_excluded = ["pathsDetail", "globalSetting", "loading", "dispatch"];
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@ -21575,7 +21574,9 @@ var LearnPath_excluded = ["pathsDetail", "globalSetting", "loading", "dispatch"]
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var LearnPath = function LearnPath(_ref) {
|
|
|
|
|
var _learnModes$subject_l;
|
|
|
|
|
var pathsDetail = _ref.pathsDetail,
|
|
|
|
|
globalSetting = _ref.globalSetting,
|
|
|
|
|
loading = _ref.loading,
|
|
|
|
|
@ -21604,7 +21605,7 @@ var LearnPath = function LearnPath(_ref) {
|
|
|
|
|
setLearnPathId = _useState10[1];
|
|
|
|
|
|
|
|
|
|
//学生端
|
|
|
|
|
var _useState11 = (0,_react_17_0_2_react.useState)([]),
|
|
|
|
|
var _useState11 = (0,_react_17_0_2_react.useState)({}),
|
|
|
|
|
_useState12 = slicedToArray_default()(_useState11, 2),
|
|
|
|
|
learnModes = _useState12[0],
|
|
|
|
|
setLearnModes = _useState12[1];
|
|
|
|
|
@ -21663,6 +21664,17 @@ var LearnPath = function LearnPath(_ref) {
|
|
|
|
|
return _ref3.apply(this, arguments);
|
|
|
|
|
};
|
|
|
|
|
}();
|
|
|
|
|
|
|
|
|
|
// 将后端返回的小结数据转化为树形结构需要的格式
|
|
|
|
|
function transformData(stages) {
|
|
|
|
|
return stages.map(function (stage) {
|
|
|
|
|
return {
|
|
|
|
|
title: stage === null || stage === void 0 ? void 0 : stage.text,
|
|
|
|
|
key: (stage === null || stage === void 0 ? void 0 : stage.stage_id) || (stage === null || stage === void 0 ? void 0 : stage.stage_shixun_id),
|
|
|
|
|
children: stage !== null && stage !== void 0 && stage.children ? transformData(stage === null || stage === void 0 ? void 0 : stage.children) : []
|
|
|
|
|
};
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
(0,_react_17_0_2_react.useEffect)(function () {
|
|
|
|
|
getPathData();
|
|
|
|
|
}, []);
|
|
|
|
|
@ -21711,7 +21723,7 @@ var LearnPath = function LearnPath(_ref) {
|
|
|
|
|
className: "ml10",
|
|
|
|
|
type: "primary",
|
|
|
|
|
onClick: /*#__PURE__*/asyncToGenerator_default()( /*#__PURE__*/regeneratorRuntime_default()().mark(function _callee3() {
|
|
|
|
|
var res, _res$data2;
|
|
|
|
|
var res;
|
|
|
|
|
return regeneratorRuntime_default()().wrap(function _callee3$(_context3) {
|
|
|
|
|
while (1) switch (_context3.prev = _context3.next) {
|
|
|
|
|
case 0:
|
|
|
|
|
@ -21723,7 +21735,8 @@ var LearnPath = function LearnPath(_ref) {
|
|
|
|
|
case 2:
|
|
|
|
|
res = _context3.sent;
|
|
|
|
|
if ((res === null || res === void 0 ? void 0 : res.status) === 0) {
|
|
|
|
|
setLearnModes(toConsumableArray_default()(res === null || res === void 0 || (_res$data2 = res.data) === null || _res$data2 === void 0 ? void 0 : _res$data2.subject_learning_modes));
|
|
|
|
|
setLearnModes(res === null || res === void 0 ? void 0 : res.data);
|
|
|
|
|
console.log('data--', res.data);
|
|
|
|
|
setDetailVis(true);
|
|
|
|
|
}
|
|
|
|
|
case 4:
|
|
|
|
|
@ -21797,6 +21810,117 @@ var LearnPath = function LearnPath(_ref) {
|
|
|
|
|
},
|
|
|
|
|
children: "\u786E\u8BA4\u8981\u5220\u9664\u8FD9\u4E2A\u5B66\u4E60\u8DEF\u5F84\u5417\uFF1F"
|
|
|
|
|
})
|
|
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsx)(modal/* default */.Z, {
|
|
|
|
|
centered: true,
|
|
|
|
|
width: 720,
|
|
|
|
|
keyboard: false,
|
|
|
|
|
maskClosable: false,
|
|
|
|
|
destroyOnClose: true,
|
|
|
|
|
title: "\u8BE6\u60C5",
|
|
|
|
|
open: detailVis,
|
|
|
|
|
onOk: function onOk() {
|
|
|
|
|
setDetailVis(false);
|
|
|
|
|
},
|
|
|
|
|
onCancel: function onCancel() {
|
|
|
|
|
setDetailVis(false);
|
|
|
|
|
},
|
|
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)("div", {
|
|
|
|
|
className: LearnPathmodules.detailWrap,
|
|
|
|
|
children: learnModes === null || learnModes === void 0 || (_learnModes$subject_l = learnModes.subject_learning_modes) === null || _learnModes$subject_l === void 0 ? void 0 : _learnModes$subject_l.map(function (item, index) {
|
|
|
|
|
var _item$shixuns, _item$shixuns2;
|
|
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsxs)("div", {
|
|
|
|
|
className: LearnPathmodules.itemWrap,
|
|
|
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsxs)("div", {
|
|
|
|
|
className: LearnPathmodules.titleWrap,
|
|
|
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsx)("span", {
|
|
|
|
|
className: LearnPathmodules.lineSty
|
|
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsx)("span", {
|
|
|
|
|
children: item === null || item === void 0 ? void 0 : item.name
|
|
|
|
|
})]
|
|
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsx)("div", {
|
|
|
|
|
children: (learnModes === null || learnModes === void 0 ? void 0 : learnModes.mode) === 1 ? /*#__PURE__*/(0,jsx_runtime.jsx)("div", {
|
|
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)(tree/* default */.Z, {
|
|
|
|
|
style: {
|
|
|
|
|
color: '#333'
|
|
|
|
|
},
|
|
|
|
|
checkable: false,
|
|
|
|
|
selectable: false,
|
|
|
|
|
defaultExpandAll: true,
|
|
|
|
|
treeData: transformData(item === null || item === void 0 ? void 0 : item.subject_learning_assocs),
|
|
|
|
|
blockNode: true
|
|
|
|
|
})
|
|
|
|
|
}) : /*#__PURE__*/(0,jsx_runtime.jsxs)("div", {
|
|
|
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsx)("div", {
|
|
|
|
|
className: LearnPathmodules.imgWrap,
|
|
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)("img", {
|
|
|
|
|
src: env/* default */.Z.API_SERVER + '/api/attachments/' + (item === null || item === void 0 ? void 0 : item.cover_id),
|
|
|
|
|
alt: "avatar",
|
|
|
|
|
style: {
|
|
|
|
|
width: '100%',
|
|
|
|
|
height: '100%'
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
}), (item === null || item === void 0 ? void 0 : item.mode_type) === 2 && /*#__PURE__*/(0,jsx_runtime.jsxs)("div", {
|
|
|
|
|
className: LearnPathmodules.shixunWrap,
|
|
|
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsxs)("div", {
|
|
|
|
|
className: LearnPathmodules.chatTitle,
|
|
|
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsx)("i", {
|
|
|
|
|
className: "iconfont icon-lianjie3 mr5 font14",
|
|
|
|
|
style: {
|
|
|
|
|
color: '#5F6368'
|
|
|
|
|
}
|
|
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsx)("span", {
|
|
|
|
|
style: {
|
|
|
|
|
fontWeight: 500,
|
|
|
|
|
fontSize: '14px',
|
|
|
|
|
color: '#232B40'
|
|
|
|
|
},
|
|
|
|
|
children: "\u5173\u8054\u9879\u76EE"
|
|
|
|
|
})]
|
|
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsx)("div", {
|
|
|
|
|
children: item === null || item === void 0 || (_item$shixuns = item.shixuns) === null || _item$shixuns === void 0 ? void 0 : _item$shixuns.map(function (item, index) {
|
|
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsx)("div", {
|
|
|
|
|
className: LearnPathmodules.nameSty,
|
|
|
|
|
children: item === null || item === void 0 ? void 0 : item.shixun_name
|
|
|
|
|
}, index);
|
|
|
|
|
})
|
|
|
|
|
})]
|
|
|
|
|
}), (item === null || item === void 0 ? void 0 : item.mode_type) === 1 && /*#__PURE__*/(0,jsx_runtime.jsxs)("div", {
|
|
|
|
|
className: LearnPathmodules.shixunWrap,
|
|
|
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsxs)("div", {
|
|
|
|
|
className: LearnPathmodules.chatTitle,
|
|
|
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsx)("i", {
|
|
|
|
|
className: "iconfont icon-lianjie3 mr5 font14"
|
|
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsx)("span", {
|
|
|
|
|
style: {
|
|
|
|
|
fontWeight: 500,
|
|
|
|
|
fontSize: '14px',
|
|
|
|
|
color: '#232B40'
|
|
|
|
|
},
|
|
|
|
|
children: "\u5173\u8054\u7AE0\u8282"
|
|
|
|
|
})]
|
|
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsx)("div", {
|
|
|
|
|
children: item === null || item === void 0 || (_item$shixuns2 = item.shixuns) === null || _item$shixuns2 === void 0 ? void 0 : _item$shixuns2.map(function (item, index) {
|
|
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsx)("div", {
|
|
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)(tree/* default */.Z, {
|
|
|
|
|
style: {
|
|
|
|
|
color: '#333'
|
|
|
|
|
},
|
|
|
|
|
checkable: false,
|
|
|
|
|
selectable: false,
|
|
|
|
|
defaultExpandAll: true,
|
|
|
|
|
treeData: transformData(item === null || item === void 0 ? void 0 : item.subject_learning_assocs),
|
|
|
|
|
blockNode: true
|
|
|
|
|
})
|
|
|
|
|
}, index);
|
|
|
|
|
})
|
|
|
|
|
})]
|
|
|
|
|
})]
|
|
|
|
|
})
|
|
|
|
|
})]
|
|
|
|
|
}, index);
|
|
|
|
|
})
|
|
|
|
|
})
|
|
|
|
|
})]
|
|
|
|
|
});
|
|
|
|
|
};
|