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.
224 lines
9.8 KiB
224 lines
9.8 KiB
"use strict";
|
|
(self["webpackChunk"] = self["webpackChunk"] || []).push([[9922],{
|
|
|
|
/***/ 42970:
|
|
/*!*******************************************************************************!*\
|
|
!*** ./src/pages/Classrooms/Lists/Statistics/StudentVideo/index.less?modules ***!
|
|
\*******************************************************************************/
|
|
/***/ (function(__unused_webpack_module, __webpack_exports__) {
|
|
|
|
// extracted by mini-css-extract-plugin
|
|
/* harmony default export */ __webpack_exports__.Z = ({"divback":"divback___ntOaK","title":"title___YscwY","divstyle":"divstyle___ZqCpS","studentListTable":"studentListTable___Ft0kg"});
|
|
|
|
/***/ }),
|
|
|
|
/***/ 87526:
|
|
/*!*****************************************!*\
|
|
!*** ./src/components/NoData/index.tsx ***!
|
|
\*****************************************/
|
|
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
|
|
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! react */ 59301);
|
|
/* harmony import */ var _assets_images_icons_nodata_png__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @/assets/images/icons/nodata.png */ 93314);
|
|
/* harmony import */ var antd__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! antd */ 3113);
|
|
var __defProp = Object.defineProperty;
|
|
var __defProps = Object.defineProperties;
|
|
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
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 __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
|
|
|
|
|
const noData = ({
|
|
img,
|
|
buttonProps = {},
|
|
styles = {},
|
|
customText,
|
|
ButtonText,
|
|
ButtonClick,
|
|
Buttonclass,
|
|
ButtonTwo,
|
|
imgStyles,
|
|
loading = false
|
|
}) => {
|
|
return /* @__PURE__ */ react__WEBPACK_IMPORTED_MODULE_0__.createElement(
|
|
"section",
|
|
{
|
|
className: "tc animated fadeIn",
|
|
style: __spreadValues(__spreadValues({}, { color: "#999", margin: "100px auto", visibility: loading ? "hidden" : "visible" }), styles)
|
|
},
|
|
/* @__PURE__ */ react__WEBPACK_IMPORTED_MODULE_0__.createElement("img", { src: img || _assets_images_icons_nodata_png__WEBPACK_IMPORTED_MODULE_1__, style: __spreadProps(__spreadValues({}, imgStyles), { pointerEvents: "none", userSelect: "none" }) }),
|
|
/* @__PURE__ */ react__WEBPACK_IMPORTED_MODULE_0__.createElement("p", { className: "mt20 font14" }, customText || "\u6682\u65F6\u8FD8\u6CA1\u6709\u76F8\u5173\u6570\u636E\u54E6!"),
|
|
ButtonText && /* @__PURE__ */ react__WEBPACK_IMPORTED_MODULE_0__.createElement(antd__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .ZP, __spreadValues({ className: Buttonclass, onClick: ButtonClick }, buttonProps), ButtonText),
|
|
ButtonTwo && ButtonTwo
|
|
);
|
|
};
|
|
/* harmony default export */ __webpack_exports__.Z = (noData);
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 86051:
|
|
/*!**********************************************************************!*\
|
|
!*** ./src/pages/Classrooms/Lists/Statistics/StudentVideo/index.tsx ***!
|
|
\**********************************************************************/
|
|
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
|
|
__webpack_require__.r(__webpack_exports__);
|
|
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! react */ 59301);
|
|
/* harmony import */ var antd__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! antd */ 28103);
|
|
/* harmony import */ var antd__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! antd */ 14491);
|
|
/* harmony import */ var antd__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! antd */ 53864);
|
|
/* harmony import */ var _utils_fetch__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @/utils/fetch */ 51165);
|
|
/* harmony import */ var _components_NoData__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @/components/NoData */ 87526);
|
|
/* harmony import */ var _index_less_modules__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./index.less?modules */ 42970);
|
|
/* harmony import */ var _utils_util__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @/utils/util */ 13462);
|
|
/* harmony import */ var umi__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! umi */ 67866);
|
|
/* harmony import */ var _ant_design_icons__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @ant-design/icons */ 11407);
|
|
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 StudentDetail({ user, dispatch }) {
|
|
const params = (0,umi__WEBPACK_IMPORTED_MODULE_5__.useParams)();
|
|
const [StudentDetails, setStudentDetails] = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)();
|
|
const [page, setPage] = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)();
|
|
(0,react__WEBPACK_IMPORTED_MODULE_0__.useEffect)(() => {
|
|
getStudentdetail(1);
|
|
}, []);
|
|
function getStudentdetail(limit) {
|
|
return __async(this, null, function* () {
|
|
setPage(limit);
|
|
const result = yield (0,_utils_fetch__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .ZP)(
|
|
`/api/courses/${params == null ? void 0 : params.coursesId}/video_study_detail.json`,
|
|
{
|
|
method: "get",
|
|
params: {
|
|
page: limit,
|
|
per_page: 10,
|
|
course_id: params == null ? void 0 : params.coursesId,
|
|
uid: params == null ? void 0 : params.studentid
|
|
}
|
|
}
|
|
);
|
|
if (result) {
|
|
setStudentDetails(result);
|
|
}
|
|
});
|
|
}
|
|
const columns = [
|
|
{
|
|
title: "\u89C6\u9891\u540D\u79F0",
|
|
dataIndex: "title",
|
|
width: 80,
|
|
align: "center",
|
|
render: (text, record, index) => /* @__PURE__ */ react__WEBPACK_IMPORTED_MODULE_0__.createElement("span", null, text)
|
|
},
|
|
{
|
|
title: "\u89C2\u770B\u65F6\u957F",
|
|
width: 120,
|
|
align: "center",
|
|
dataIndex: "total_duration",
|
|
render: (text) => /* @__PURE__ */ react__WEBPACK_IMPORTED_MODULE_0__.createElement("span", { className: "c-black" }, (0,_utils_util__WEBPACK_IMPORTED_MODULE_4__/* .toTimeFormat */ .li)(parseInt(text)) || "--")
|
|
},
|
|
{
|
|
title: "\u5B66\u4E60\u8FDB\u5EA6",
|
|
width: 130,
|
|
align: "center",
|
|
dataIndex: "rate",
|
|
render: (text) => {
|
|
return /* @__PURE__ */ react__WEBPACK_IMPORTED_MODULE_0__.createElement("span", { className: "c-black" }, text ? text + "%" : "0%");
|
|
}
|
|
},
|
|
{
|
|
title: "\u5F00\u59CB\u5B66\u4E60\u65F6\u95F4",
|
|
width: 140,
|
|
align: "center",
|
|
dataIndex: "start_at",
|
|
render: (text, record) => {
|
|
return /* @__PURE__ */ react__WEBPACK_IMPORTED_MODULE_0__.createElement("span", { className: "c-black" }, text || "--");
|
|
}
|
|
},
|
|
{
|
|
title: "\u6700\u540E\u5B66\u4E60\u65F6\u95F4",
|
|
width: 150,
|
|
align: "center",
|
|
dataIndex: "end_at",
|
|
render: (text, record) => {
|
|
return /* @__PURE__ */ react__WEBPACK_IMPORTED_MODULE_0__.createElement("span", { className: "c-black" }, text || "--");
|
|
}
|
|
}
|
|
].filter((item) => !!item);
|
|
return /* @__PURE__ */ react__WEBPACK_IMPORTED_MODULE_0__.createElement("div", { className: _index_less_modules__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z.divback }, /* @__PURE__ */ react__WEBPACK_IMPORTED_MODULE_0__.createElement("div", { className: _index_less_modules__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z.title }, /* @__PURE__ */ react__WEBPACK_IMPORTED_MODULE_0__.createElement(_ant_design_icons__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .Z, { style: { cursor: "pointer" }, onClick: () => {
|
|
history.back();
|
|
} }), " ", StudentDetails == null ? void 0 : StudentDetails.user_name, "\u7684\u89C6\u9891\u5B66\u4E60\u60C5\u51B5"), /* @__PURE__ */ react__WEBPACK_IMPORTED_MODULE_0__.createElement(antd__WEBPACK_IMPORTED_MODULE_7__/* ["default"] */ .Z, { className: _index_less_modules__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z.divstyle }), (StudentDetails == null ? void 0 : StudentDetails.count) === 0 && /* @__PURE__ */ react__WEBPACK_IMPORTED_MODULE_0__.createElement(_components_NoData__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .Z, null), (StudentDetails == null ? void 0 : StudentDetails.count) > 0 && /* @__PURE__ */ react__WEBPACK_IMPORTED_MODULE_0__.createElement(
|
|
antd__WEBPACK_IMPORTED_MODULE_8__["default"],
|
|
{
|
|
dataSource: StudentDetails == null ? void 0 : StudentDetails.student,
|
|
pagination: false,
|
|
columns
|
|
}
|
|
), /* @__PURE__ */ react__WEBPACK_IMPORTED_MODULE_0__.createElement("aside", { className: "tc mb50 mt30 mb20" }, /* @__PURE__ */ react__WEBPACK_IMPORTED_MODULE_0__.createElement(
|
|
antd__WEBPACK_IMPORTED_MODULE_9__/* ["default"] */ .Z,
|
|
{
|
|
hideOnSinglePage: true,
|
|
showSizeChanger: false,
|
|
onChange: (current, pageSize) => {
|
|
getStudentdetail(current);
|
|
},
|
|
current: page || 1,
|
|
defaultPageSize: 10,
|
|
total: StudentDetails == null ? void 0 : StudentDetails.count
|
|
}
|
|
)));
|
|
}
|
|
/* harmony default export */ __webpack_exports__["default"] = ((0,umi__WEBPACK_IMPORTED_MODULE_5__.connect)(
|
|
({
|
|
user
|
|
}) => ({
|
|
user
|
|
})
|
|
)(StudentDetail));
|
|
|
|
|
|
/***/ })
|
|
|
|
}]); |