|
|
(self["webpackChunk"] = self["webpackChunk"] || []).push([[86541,79250],{
|
|
|
|
|
|
/***/ 72020:
|
|
|
/*!*****************************************!*\
|
|
|
!*** ./src/components/NoData/index.tsx ***!
|
|
|
\*****************************************/
|
|
|
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
|
|
|
|
"use strict";
|
|
|
/* harmony import */ var _root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./node_modules/_@babel_runtime@7.23.2@@babel/runtime/helpers/objectSpread2.js */ 26801);
|
|
|
/* harmony import */ var _root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_0__);
|
|
|
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! react */ 59301);
|
|
|
/* harmony import */ var _assets_images_icons_nodata_png__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @/assets/images/icons/nodata.png */ 4977);
|
|
|
/* harmony import */ var antd__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! antd */ 3113);
|
|
|
/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! react/jsx-runtime */ 37712);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var noData = function noData(_ref) {
|
|
|
var img = _ref.img,
|
|
|
_ref$buttonProps = _ref.buttonProps,
|
|
|
buttonProps = _ref$buttonProps === void 0 ? {} : _ref$buttonProps,
|
|
|
_ref$styles = _ref.styles,
|
|
|
styles = _ref$styles === void 0 ? {} : _ref$styles,
|
|
|
customText = _ref.customText,
|
|
|
ButtonText = _ref.ButtonText,
|
|
|
ButtonClick = _ref.ButtonClick,
|
|
|
Buttonclass = _ref.Buttonclass,
|
|
|
ButtonTwo = _ref.ButtonTwo,
|
|
|
imgStyles = _ref.imgStyles,
|
|
|
_ref$loading = _ref.loading,
|
|
|
loading = _ref$loading === void 0 ? false : _ref$loading;
|
|
|
return /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_3__.jsxs)("section", {
|
|
|
className: "tc animated fadeIn",
|
|
|
style: _root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_0___default()(_root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_0___default()({}, {
|
|
|
color: '#999',
|
|
|
margin: '100px auto',
|
|
|
visibility: loading ? 'hidden' : 'visible'
|
|
|
}), styles),
|
|
|
children: [/*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_3__.jsx)("img", {
|
|
|
src: img || _assets_images_icons_nodata_png__WEBPACK_IMPORTED_MODULE_2__,
|
|
|
style: _root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_0___default()({}, imgStyles)
|
|
|
}), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_3__.jsx)("p", {
|
|
|
className: "mt20 font14",
|
|
|
children: customText || '暂时还没有相关数据哦!'
|
|
|
}), ButtonText && /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_3__.jsx)(antd__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .ZP, _root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_0___default()(_root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_0___default()({
|
|
|
className: Buttonclass,
|
|
|
onClick: ButtonClick
|
|
|
}, buttonProps), {}, {
|
|
|
children: ButtonText
|
|
|
})), ButtonTwo && ButtonTwo]
|
|
|
});
|
|
|
};
|
|
|
/* harmony default export */ __webpack_exports__.Z = (noData);
|
|
|
|
|
|
/***/ }),
|
|
|
|
|
|
/***/ 49581:
|
|
|
/*!*********************************************!*\
|
|
|
!*** ./src/components/UploadFile/index.tsx ***!
|
|
|
\*********************************************/
|
|
|
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
|
|
|
|
"use strict";
|
|
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
|
/* harmony export */ cT: function() { return /* binding */ uploadFile; },
|
|
|
/* harmony export */ pe: function() { return /* binding */ decrypt; }
|
|
|
/* harmony export */ });
|
|
|
/* unused harmony exports reNameFile, UploadFile */
|
|
|
/* harmony import */ var _root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_toConsumableArray_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./node_modules/_@babel_runtime@7.23.2@@babel/runtime/helpers/toConsumableArray.js */ 93923);
|
|
|
/* harmony import */ var _root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_toConsumableArray_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_toConsumableArray_js__WEBPACK_IMPORTED_MODULE_0__);
|
|
|
/* harmony import */ var _root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_slicedToArray_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./node_modules/_@babel_runtime@7.23.2@@babel/runtime/helpers/slicedToArray.js */ 11006);
|
|
|
/* harmony import */ var _root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_slicedToArray_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_slicedToArray_js__WEBPACK_IMPORTED_MODULE_1__);
|
|
|
/* harmony import */ var _root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectWithoutProperties_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./node_modules/_@babel_runtime@7.23.2@@babel/runtime/helpers/objectWithoutProperties.js */ 27161);
|
|
|
/* harmony import */ var _root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectWithoutProperties_js__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectWithoutProperties_js__WEBPACK_IMPORTED_MODULE_2__);
|
|
|
/* harmony import */ var _root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./node_modules/_@babel_runtime@7.23.2@@babel/runtime/helpers/objectSpread2.js */ 26801);
|
|
|
/* harmony import */ var _root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_3__);
|
|
|
/* harmony import */ var _root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_regeneratorRuntime_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./node_modules/_@babel_runtime@7.23.2@@babel/runtime/helpers/regeneratorRuntime.js */ 10574);
|
|
|
/* harmony import */ var _root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_regeneratorRuntime_js__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_regeneratorRuntime_js__WEBPACK_IMPORTED_MODULE_4__);
|
|
|
/* harmony import */ var _root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./node_modules/_@babel_runtime@7.23.2@@babel/runtime/helpers/asyncToGenerator.js */ 39343);
|
|
|
/* harmony import */ var _root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_5__);
|
|
|
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! react */ 59301);
|
|
|
/* harmony import */ var antd__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! antd */ 6557);
|
|
|
/* harmony import */ var antd__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! antd */ 8591);
|
|
|
/* harmony import */ var _utils_fetch__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @/utils/fetch */ 97174);
|
|
|
/* harmony import */ var crypto_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! crypto-js */ 28209);
|
|
|
/* harmony import */ var crypto_js__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(crypto_js__WEBPACK_IMPORTED_MODULE_8__);
|
|
|
/* harmony import */ var uuid__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! uuid */ 1012);
|
|
|
/* harmony import */ var umi__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! umi */ 66660);
|
|
|
/* harmony import */ var ali_oss__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ali-oss */ 75264);
|
|
|
/* harmony import */ var ali_oss__WEBPACK_IMPORTED_MODULE_11___default = /*#__PURE__*/__webpack_require__.n(ali_oss__WEBPACK_IMPORTED_MODULE_11__);
|
|
|
/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! react/jsx-runtime */ 37712);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var _excluded = ["user", "cancelUpload"];
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var Dragger = antd__WEBPACK_IMPORTED_MODULE_10__/* ["default"] */ .Z.Dragger;
|
|
|
|
|
|
|
|
|
var decrypt = function decrypt(word) {
|
|
|
var ENC_KEY = "bf3c199c2470cb477d907b1e0917c17b";
|
|
|
var IV = "5183666c72eec9e4";
|
|
|
var key = crypto_js__WEBPACK_IMPORTED_MODULE_8___default().enc.Utf8.parse(ENC_KEY);
|
|
|
var iv = crypto_js__WEBPACK_IMPORTED_MODULE_8___default().enc.Utf8.parse(IV);
|
|
|
var decrypt = crypto_js__WEBPACK_IMPORTED_MODULE_8___default().AES.decrypt(word, key, {
|
|
|
iv: iv,
|
|
|
mode: (crypto_js__WEBPACK_IMPORTED_MODULE_8___default().mode).CBC
|
|
|
// padding: CryptoJS.pad.ZeroPadding
|
|
|
});
|
|
|
|
|
|
return decrypt.toString((crypto_js__WEBPACK_IMPORTED_MODULE_8___default().enc).Utf8);
|
|
|
};
|
|
|
var tempCheckpoint;
|
|
|
// 重命名
|
|
|
var reNameFile = /*#__PURE__*/(/* unused pure expression or super */ null && (function () {
|
|
|
var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(_ref) {
|
|
|
var _res$data, _res$data2, _res$data3, _res$data4, _res$data5, _res$data6;
|
|
|
var identifier, oldFilename, newFilename, res, client;
|
|
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
|
while (1) switch (_context.prev = _context.next) {
|
|
|
case 0:
|
|
|
identifier = _ref.identifier, oldFilename = _ref.oldFilename, newFilename = _ref.newFilename;
|
|
|
_context.next = 3;
|
|
|
return Fetch('/api/buckets/get_upload_token_for_big_files.json', {
|
|
|
method: "get"
|
|
|
});
|
|
|
case 3:
|
|
|
res = _context.sent;
|
|
|
res.data = JSON.parse(decrypt(res.data));
|
|
|
client = new OSS({
|
|
|
endpoint: res === null || res === void 0 || (_res$data = res.data) === null || _res$data === void 0 ? void 0 : _res$data.end_point,
|
|
|
region: res === null || res === void 0 || (_res$data2 = res.data) === null || _res$data2 === void 0 ? void 0 : _res$data2.region,
|
|
|
accessKeyId: res === null || res === void 0 || (_res$data3 = res.data) === null || _res$data3 === void 0 ? void 0 : _res$data3.access_key_id,
|
|
|
accessKeySecret: res === null || res === void 0 || (_res$data4 = res.data) === null || _res$data4 === void 0 ? void 0 : _res$data4.access_key_secret,
|
|
|
bucket: res === null || res === void 0 || (_res$data5 = res.data) === null || _res$data5 === void 0 ? void 0 : _res$data5.bucket,
|
|
|
stsToken: res === null || res === void 0 || (_res$data6 = res.data) === null || _res$data6 === void 0 ? void 0 : _res$data6.security_token
|
|
|
});
|
|
|
return _context.abrupt("return", new Promise(function (resolve, reject) {
|
|
|
console.log(11111, "".concat(identifier, "/").concat(oldFilename), "".concat(identifier, "/").concat(newFilename), res.data);
|
|
|
client.copy("/".concat(identifier, "/").concat(oldFilename), "/".concat(identifier, "/").concat(newFilename)).then(function (r) {
|
|
|
console.log('拷贝成功', r);
|
|
|
// client
|
|
|
// .delete(`${identifier}/${oldFilename}`)
|
|
|
// .then(r => console.log(r))
|
|
|
// .catch(e => console.log(e));
|
|
|
})["catch"](function (e) {
|
|
|
console.log(e);
|
|
|
// debugger
|
|
|
});
|
|
|
}));
|
|
|
case 7:
|
|
|
case "end":
|
|
|
return _context.stop();
|
|
|
}
|
|
|
}, _callee);
|
|
|
}));
|
|
|
return function reNameFile(_x) {
|
|
|
return _ref2.apply(this, arguments);
|
|
|
};
|
|
|
}()));
|
|
|
var uploadFile = /*#__PURE__*/function () {
|
|
|
var _ref3 = _root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_5___default()( /*#__PURE__*/_root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_regeneratorRuntime_js__WEBPACK_IMPORTED_MODULE_4___default()().mark(function _callee2(file, obj, config) {
|
|
|
var _res$data7, _res$data8, _res$data9, _res$data10, _res$data11, _res$data12;
|
|
|
var res, namearrs, name, client;
|
|
|
return _root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_regeneratorRuntime_js__WEBPACK_IMPORTED_MODULE_4___default()().wrap(function _callee2$(_context2) {
|
|
|
while (1) switch (_context2.prev = _context2.next) {
|
|
|
case 0:
|
|
|
obj.file_name = file.name;
|
|
|
_context2.next = 3;
|
|
|
return (0,_utils_fetch__WEBPACK_IMPORTED_MODULE_7__/* ["default"] */ .ZP)('/api/buckets/get_upload_token.json', {
|
|
|
method: "get"
|
|
|
});
|
|
|
case 3:
|
|
|
res = _context2.sent;
|
|
|
console.log("decrypt(res.data):", decrypt(res.data));
|
|
|
res.data = JSON.parse(decrypt(res.data));
|
|
|
namearrs = file.name.split(".");
|
|
|
namearrs.pop();
|
|
|
name = obj.realFileName ? namearrs.join("") : (0,uuid__WEBPACK_IMPORTED_MODULE_13__/* ["default"] */ .Z)(); // const name = file.name
|
|
|
client = new (ali_oss__WEBPACK_IMPORTED_MODULE_11___default())({
|
|
|
endpoint: res === null || res === void 0 || (_res$data7 = res.data) === null || _res$data7 === void 0 ? void 0 : _res$data7.end_point,
|
|
|
region: res === null || res === void 0 || (_res$data8 = res.data) === null || _res$data8 === void 0 ? void 0 : _res$data8.region,
|
|
|
accessKeyId: res === null || res === void 0 || (_res$data9 = res.data) === null || _res$data9 === void 0 ? void 0 : _res$data9.access_key_id,
|
|
|
accessKeySecret: res === null || res === void 0 || (_res$data10 = res.data) === null || _res$data10 === void 0 ? void 0 : _res$data10.access_key_secret,
|
|
|
bucket: res === null || res === void 0 || (_res$data11 = res.data) === null || _res$data11 === void 0 ? void 0 : _res$data11.bucket,
|
|
|
stsToken: res === null || res === void 0 || (_res$data12 = res.data) === null || _res$data12 === void 0 ? void 0 : _res$data12.security_token
|
|
|
});
|
|
|
return _context2.abrupt("return", new Promise(function (resolve, reject) {
|
|
|
var _res$data13;
|
|
|
client.multipartUpload("".concat(name), new Blob([file], {
|
|
|
type: file.type
|
|
|
}), _root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_3___default()(_root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_3___default()({
|
|
|
timeout: 200 * 1000,
|
|
|
partSize: 102400
|
|
|
}, config), {}, {
|
|
|
callback: {
|
|
|
url: res === null || res === void 0 || (_res$data13 = res.data) === null || _res$data13 === void 0 ? void 0 : _res$data13.callback_url,
|
|
|
host: res === null || res === void 0 ? void 0 : res.data.bucket_host,
|
|
|
body: 'bucket=${bucket}&object=${object}&etag=${etag}&size=${size}&mimeType=${mimeType}&my_var=${x:my_var}&' + (0,_utils_fetch__WEBPACK_IMPORTED_MODULE_7__/* .parseParams */ .rz)(obj)
|
|
|
// body: 'bucket=${bucket}&object=${object}&etag=${etag}&size=${size}&mimeType=${mimeType}&my_var=${x:my_var}&login=' + obj.login + '&container_id=' + obj.container_id + '&container_type='+obj.container_type,
|
|
|
}
|
|
|
})).then(function (result) {
|
|
|
var _result$data;
|
|
|
file.response = (_result$data = result.data) === null || _result$data === void 0 ? void 0 : _result$data.data;
|
|
|
resolve(result === null || result === void 0 ? void 0 : result.data);
|
|
|
})["catch"](function (err) {
|
|
|
reject(err);
|
|
|
console.log("err:", err);
|
|
|
});
|
|
|
}));
|
|
|
case 11:
|
|
|
case "end":
|
|
|
return _context2.stop();
|
|
|
}
|
|
|
}, _callee2);
|
|
|
}));
|
|
|
return function uploadFile(_x2, _x3, _x4) {
|
|
|
return _ref3.apply(this, arguments);
|
|
|
};
|
|
|
}();
|
|
|
var UploadFile = function UploadFile(_ref4) {
|
|
|
var user = _ref4.user,
|
|
|
cancelUpload = _ref4.cancelUpload,
|
|
|
props = _root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectWithoutProperties_js__WEBPACK_IMPORTED_MODULE_2___default()(_ref4, _excluded);
|
|
|
var _useState = (0,react__WEBPACK_IMPORTED_MODULE_6__.useState)([]),
|
|
|
_useState2 = _root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_slicedToArray_js__WEBPACK_IMPORTED_MODULE_1___default()(_useState, 2),
|
|
|
fileList = _useState2[0],
|
|
|
setFileList = _useState2[1];
|
|
|
var _useState3 = (0,react__WEBPACK_IMPORTED_MODULE_6__.useState)(),
|
|
|
_useState4 = _root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_slicedToArray_js__WEBPACK_IMPORTED_MODULE_1___default()(_useState3, 2),
|
|
|
client = _useState4[0],
|
|
|
setClient = _useState4[1];
|
|
|
var _props = {
|
|
|
onRemove: function onRemove(e) {
|
|
|
setFileList(_root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_toConsumableArray_js__WEBPACK_IMPORTED_MODULE_0___default()(fileList.filter(function (item) {
|
|
|
return item.name !== e.name;
|
|
|
})));
|
|
|
props.onChange(fileList.filter(function (item) {
|
|
|
return item.name !== e.name;
|
|
|
}));
|
|
|
},
|
|
|
disabled: props.disabled,
|
|
|
multiple: true,
|
|
|
fileList: fileList === null || fileList === void 0 ? void 0 : fileList.map(function (item) {
|
|
|
return item.file;
|
|
|
}),
|
|
|
customRequest: function customRequest() {},
|
|
|
beforeUpload: function () {
|
|
|
var _beforeUpload = _root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_5___default()( /*#__PURE__*/_root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_regeneratorRuntime_js__WEBPACK_IMPORTED_MODULE_4___default()().mark(function _callee3(file) {
|
|
|
var fileSize;
|
|
|
return _root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_regeneratorRuntime_js__WEBPACK_IMPORTED_MODULE_4___default()().wrap(function _callee3$(_context3) {
|
|
|
while (1) switch (_context3.prev = _context3.next) {
|
|
|
case 0:
|
|
|
fileSize = props.maxSize || 1024 * 1024 * 1024 * 1;
|
|
|
if (!fileList.filter(function (item) {
|
|
|
return item.name === file.name;
|
|
|
}).length) {
|
|
|
_context3.next = 4;
|
|
|
break;
|
|
|
}
|
|
|
antd__WEBPACK_IMPORTED_MODULE_14__/* ["default"] */ .ZP.info("".concat(file.name, "\u5DF2\u5B58\u5728\uFF0C\u8BF7\u91CD\u65B0\u9009\u62E9"));
|
|
|
return _context3.abrupt("return");
|
|
|
case 4:
|
|
|
if (!((file === null || file === void 0 ? void 0 : file.size) > fileSize)) {
|
|
|
_context3.next = 7;
|
|
|
break;
|
|
|
}
|
|
|
antd__WEBPACK_IMPORTED_MODULE_14__/* ["default"] */ .ZP.info("\u6587\u4EF6\u8D85\u8FC7".concat(fileSize / 1024 / 1024 / 1024, "GB\uFF0C\u4E0D\u7B26\u5408\u4E0A\u4F20\u8981\u6C42"));
|
|
|
return _context3.abrupt("return", false);
|
|
|
case 7:
|
|
|
fileList.push({
|
|
|
name: file.name,
|
|
|
file: file
|
|
|
});
|
|
|
setFileList(_root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_toConsumableArray_js__WEBPACK_IMPORTED_MODULE_0___default()(fileList));
|
|
|
props.onChange(fileList);
|
|
|
return _context3.abrupt("return", false);
|
|
|
case 11:
|
|
|
case "end":
|
|
|
return _context3.stop();
|
|
|
}
|
|
|
}, _callee3);
|
|
|
}));
|
|
|
function beforeUpload(_x5) {
|
|
|
return _beforeUpload.apply(this, arguments);
|
|
|
}
|
|
|
return beforeUpload;
|
|
|
}()
|
|
|
};
|
|
|
var _uploadFiles = /*#__PURE__*/function () {
|
|
|
var _ref5 = _root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_5___default()( /*#__PURE__*/_root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_regeneratorRuntime_js__WEBPACK_IMPORTED_MODULE_4___default()().mark(function _callee4(file, obj) {
|
|
|
var _res$data14, _res$data15, _res$data16, _res$data17, _res$data18, _res$data19;
|
|
|
var name, res, namearrs, filename;
|
|
|
return _root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_regeneratorRuntime_js__WEBPACK_IMPORTED_MODULE_4___default()().wrap(function _callee4$(_context4) {
|
|
|
while (1) switch (_context4.prev = _context4.next) {
|
|
|
case 0:
|
|
|
obj.file_name = file.name;
|
|
|
name = file.name;
|
|
|
_context4.next = 4;
|
|
|
return (0,_utils_fetch__WEBPACK_IMPORTED_MODULE_7__/* ["default"] */ .ZP)('/api/buckets/get_upload_token_for_big_files.json', {
|
|
|
method: "get"
|
|
|
});
|
|
|
case 4:
|
|
|
res = _context4.sent;
|
|
|
res.data = JSON.parse(decrypt(res.data));
|
|
|
if (!((res === null || res === void 0 ? void 0 : res.status) !== 0)) {
|
|
|
_context4.next = 12;
|
|
|
break;
|
|
|
}
|
|
|
fileList[fileList.findIndex(function (item) {
|
|
|
return item.name === name;
|
|
|
})]['status'] = 'error';
|
|
|
fileList[fileList.findIndex(function (item) {
|
|
|
return item.name === name;
|
|
|
})]['file']['status'] = 'error';
|
|
|
props.onChange(fileList);
|
|
|
antd__WEBPACK_IMPORTED_MODULE_14__/* ["default"] */ .ZP.warning("上传失败,请重新尝试");
|
|
|
return _context4.abrupt("return");
|
|
|
case 12:
|
|
|
client = new (ali_oss__WEBPACK_IMPORTED_MODULE_11___default())({
|
|
|
endpoint: res === null || res === void 0 || (_res$data14 = res.data) === null || _res$data14 === void 0 ? void 0 : _res$data14.end_point,
|
|
|
region: res === null || res === void 0 || (_res$data15 = res.data) === null || _res$data15 === void 0 ? void 0 : _res$data15.region,
|
|
|
accessKeyId: res === null || res === void 0 || (_res$data16 = res.data) === null || _res$data16 === void 0 ? void 0 : _res$data16.access_key_id,
|
|
|
accessKeySecret: res === null || res === void 0 || (_res$data17 = res.data) === null || _res$data17 === void 0 ? void 0 : _res$data17.access_key_secret,
|
|
|
bucket: res === null || res === void 0 || (_res$data18 = res.data) === null || _res$data18 === void 0 ? void 0 : _res$data18.bucket,
|
|
|
stsToken: res === null || res === void 0 || (_res$data19 = res.data) === null || _res$data19 === void 0 ? void 0 : _res$data19.security_token
|
|
|
});
|
|
|
console.log(file, 'file');
|
|
|
setClient(client);
|
|
|
// const filename = uuidv4()
|
|
|
namearrs = file.name.split(".");
|
|
|
namearrs.pop();
|
|
|
filename = obj.realFileName ? namearrs.join(".") : (0,uuid__WEBPACK_IMPORTED_MODULE_13__/* ["default"] */ .Z)();
|
|
|
return _context4.abrupt("return", new Promise(function (resolve, reject) {
|
|
|
try {
|
|
|
var _res$data20;
|
|
|
client.multipartUpload("".concat(props.identifier, "/").concat(filename).concat(name.indexOf(".") > -1 ? '.' + name.split(".").pop() : ""), new Blob([file.file], {
|
|
|
type: file.file.type
|
|
|
}), {
|
|
|
timeout: 3600 * 1000,
|
|
|
partSize: 1002400,
|
|
|
progress: function progress(p, checkpoint, res) {
|
|
|
try {
|
|
|
console.log("进度", p, checkpoint, res);
|
|
|
var index = fileList.findIndex(function (item) {
|
|
|
return item.name === name;
|
|
|
});
|
|
|
fileList[index]['file']['percent'] = p * 100;
|
|
|
// if (p === 1) {
|
|
|
// fileList[index]['status'] = 'done'
|
|
|
// fileList[index]['file']['status'] = 'done'
|
|
|
// props.onChange(fileList)
|
|
|
// }
|
|
|
fileList[index].tempCheckpoint = checkpoint;
|
|
|
setFileList(_root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_toConsumableArray_js__WEBPACK_IMPORTED_MODULE_0___default()(fileList));
|
|
|
} catch (e) {}
|
|
|
},
|
|
|
checkpoint: fileList[fileList.findIndex(function (item) {
|
|
|
return item.name === name;
|
|
|
})].tempCheckpoint,
|
|
|
callback: {
|
|
|
customValue: {
|
|
|
id: name + ''
|
|
|
},
|
|
|
url: res === null || res === void 0 || (_res$data20 = res.data) === null || _res$data20 === void 0 ? void 0 : _res$data20.callback_url,
|
|
|
host: res === null || res === void 0 ? void 0 : res.data.bucket_host,
|
|
|
body: 'bucket=${bucket}&object=${object}&etag=${etag}&size=${size}&mimeType=${mimeType}&my_var=${x:my_var}&' + (0,_utils_fetch__WEBPACK_IMPORTED_MODULE_7__/* .parseParams */ .rz)(obj)
|
|
|
}
|
|
|
}).then(function (result) {
|
|
|
var _result$data2;
|
|
|
var index = fileList.findIndex(function (item) {
|
|
|
return item.name === name;
|
|
|
});
|
|
|
var status = 'done';
|
|
|
if (((_result$data2 = result.data) === null || _result$data2 === void 0 ? void 0 : _result$data2.status) === 0) {
|
|
|
var _result$data3;
|
|
|
file.response = (_result$data3 = result.data) === null || _result$data3 === void 0 ? void 0 : _result$data3.data;
|
|
|
var _index = fileList.findIndex(function (item) {
|
|
|
return item.name === name;
|
|
|
});
|
|
|
fileList[_index]['status'] = 'done';
|
|
|
fileList[_index]['file']['status'] = 'done';
|
|
|
} else {
|
|
|
var _result$data4;
|
|
|
antd__WEBPACK_IMPORTED_MODULE_14__/* ["default"] */ .ZP.warning((_result$data4 = result.data) === null || _result$data4 === void 0 ? void 0 : _result$data4.message);
|
|
|
status = 'error';
|
|
|
}
|
|
|
fileList[index]['status'] = status;
|
|
|
fileList[index]['file']['status'] = status;
|
|
|
props.onChange(fileList);
|
|
|
resolve(result === null || result === void 0 ? void 0 : result.data);
|
|
|
})["catch"](function (err) {
|
|
|
fileList[fileList.findIndex(function (item) {
|
|
|
return item.name === name;
|
|
|
})]['status'] = 'error';
|
|
|
fileList[fileList.findIndex(function (item) {
|
|
|
return item.name === name;
|
|
|
})]['file']['status'] = 'error';
|
|
|
antd__WEBPACK_IMPORTED_MODULE_14__/* ["default"] */ .ZP.warning("上传失败,请重新尝试");
|
|
|
setFileList(_root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_toConsumableArray_js__WEBPACK_IMPORTED_MODULE_0___default()(fileList));
|
|
|
props.onChange(fileList);
|
|
|
reject(err);
|
|
|
console.log("err:", err);
|
|
|
});
|
|
|
} catch (e) {
|
|
|
// debugger
|
|
|
}
|
|
|
}));
|
|
|
case 19:
|
|
|
case "end":
|
|
|
return _context4.stop();
|
|
|
}
|
|
|
}, _callee4);
|
|
|
}));
|
|
|
return function _uploadFiles(_x6, _x7) {
|
|
|
return _ref5.apply(this, arguments);
|
|
|
};
|
|
|
}();
|
|
|
(0,react__WEBPACK_IMPORTED_MODULE_6__.useEffect)(function () {
|
|
|
if (fileList.every(function (item) {
|
|
|
return item === 'done' || item === 'error';
|
|
|
})) {
|
|
|
props.onComplete(fileList);
|
|
|
}
|
|
|
}, [fileList]);
|
|
|
(0,react__WEBPACK_IMPORTED_MODULE_6__.useEffect)(function () {
|
|
|
if (cancelUpload) {
|
|
|
var _client;
|
|
|
(_client = client) === null || _client === void 0 || _client.cancel();
|
|
|
}
|
|
|
}, [cancelUpload]);
|
|
|
(0,react__WEBPACK_IMPORTED_MODULE_6__.useEffect)(function () {
|
|
|
if (props.uploading) fileList.map( /*#__PURE__*/function () {
|
|
|
var _ref6 = _root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_5___default()( /*#__PURE__*/_root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_regeneratorRuntime_js__WEBPACK_IMPORTED_MODULE_4___default()().mark(function _callee5(item) {
|
|
|
var _user$userInfo, res;
|
|
|
return _root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_regeneratorRuntime_js__WEBPACK_IMPORTED_MODULE_4___default()().wrap(function _callee5$(_context5) {
|
|
|
while (1) switch (_context5.prev = _context5.next) {
|
|
|
case 0:
|
|
|
if (!((!item.status || item.status === 'error') && !cancelUpload)) {
|
|
|
_context5.next = 6;
|
|
|
break;
|
|
|
}
|
|
|
item.status = 'uploading';
|
|
|
item.file.status = 'uploading';
|
|
|
_context5.next = 5;
|
|
|
return _uploadFiles(item, {
|
|
|
login: user === null || user === void 0 || (_user$userInfo = user.userInfo) === null || _user$userInfo === void 0 ? void 0 : _user$userInfo.login,
|
|
|
container_type: props.container_type,
|
|
|
container_id: props.container_id,
|
|
|
description: props.description,
|
|
|
realFileName: props.realFileName
|
|
|
});
|
|
|
case 5:
|
|
|
res = _context5.sent;
|
|
|
case 6:
|
|
|
case "end":
|
|
|
return _context5.stop();
|
|
|
}
|
|
|
}, _callee5);
|
|
|
}));
|
|
|
return function (_x8) {
|
|
|
return _ref6.apply(this, arguments);
|
|
|
};
|
|
|
}());
|
|
|
}, [props.uploading]);
|
|
|
return /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_12__.jsx)(Dragger, _root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_3___default()(_root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_7_23_2_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_3___default()({}, _props), {}, {
|
|
|
height: props.height,
|
|
|
className: props.className,
|
|
|
children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_12__.jsx)("p", {
|
|
|
className: "ant-upload-hint",
|
|
|
children: props.text || '拖拽文件或者点击上传'
|
|
|
})
|
|
|
}));
|
|
|
};
|
|
|
/* harmony default export */ __webpack_exports__.ZP = ((0,umi__WEBPACK_IMPORTED_MODULE_9__.connect)(function (_ref7) {
|
|
|
var loading = _ref7.loading,
|
|
|
globalSetting = _ref7.globalSetting,
|
|
|
user = _ref7.user;
|
|
|
return {
|
|
|
globalSetting: globalSetting,
|
|
|
loading: loading.models.competitions,
|
|
|
user: user
|
|
|
};
|
|
|
})(UploadFile));
|
|
|
|
|
|
/***/ }),
|
|
|
|
|
|
/***/ 52561:
|
|
|
/*!****************************************************************!*\
|
|
|
!*** ./src/pages/Shixuns/Detail/Dataset/index.tsx + 1 modules ***!
|
|
|
\****************************************************************/
|
|
|
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
|
|
|
|
"use strict";
|
|
|
// ESM COMPAT FLAG
|
|
|
__webpack_require__.r(__webpack_exports__);
|
|
|
|
|
|
// EXPORTS
|
|
|
__webpack_require__.d(__webpack_exports__, {
|
|
|
"default": function() { return /* binding */ Detail_Dataset; }
|
|
|
});
|
|
|
|
|
|
// EXTERNAL MODULE: ./node_modules/_@babel_runtime@7.23.2@@babel/runtime/helpers/regeneratorRuntime.js
|
|
|
var regeneratorRuntime = __webpack_require__(10574);
|
|
|
var regeneratorRuntime_default = /*#__PURE__*/__webpack_require__.n(regeneratorRuntime);
|
|
|
// EXTERNAL MODULE: ./node_modules/_@babel_runtime@7.23.2@@babel/runtime/helpers/toConsumableArray.js
|
|
|
var toConsumableArray = __webpack_require__(93923);
|
|
|
var toConsumableArray_default = /*#__PURE__*/__webpack_require__.n(toConsumableArray);
|
|
|
// EXTERNAL MODULE: ./node_modules/_@babel_runtime@7.23.2@@babel/runtime/helpers/asyncToGenerator.js
|
|
|
var asyncToGenerator = __webpack_require__(39343);
|
|
|
var asyncToGenerator_default = /*#__PURE__*/__webpack_require__.n(asyncToGenerator);
|
|
|
// EXTERNAL MODULE: ./node_modules/_@babel_runtime@7.23.2@@babel/runtime/helpers/slicedToArray.js
|
|
|
var slicedToArray = __webpack_require__(11006);
|
|
|
var slicedToArray_default = /*#__PURE__*/__webpack_require__.n(slicedToArray);
|
|
|
// EXTERNAL MODULE: ./node_modules/_@babel_runtime@7.23.2@@babel/runtime/helpers/objectWithoutProperties.js
|
|
|
var objectWithoutProperties = __webpack_require__(27161);
|
|
|
var objectWithoutProperties_default = /*#__PURE__*/__webpack_require__.n(objectWithoutProperties);
|
|
|
// 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 + 8 modules
|
|
|
var _umi_production_exports = __webpack_require__(66660);
|
|
|
// EXTERNAL MODULE: ./src/pages/Shixuns/Detail/components/Right/index.tsx + 4 modules
|
|
|
var Right = __webpack_require__(79250);
|
|
|
// EXTERNAL MODULE: ./node_modules/_dayjs@1.11.10@dayjs/dayjs.min.js
|
|
|
var dayjs_min = __webpack_require__(9498);
|
|
|
var dayjs_min_default = /*#__PURE__*/__webpack_require__.n(dayjs_min);
|
|
|
// EXTERNAL MODULE: ./src/components/NoData/index.tsx
|
|
|
var NoData = __webpack_require__(72020);
|
|
|
// EXTERNAL MODULE: ./node_modules/_react-copy-to-clipboard@5.0.2@react-copy-to-clipboard/lib/index.js
|
|
|
var lib = __webpack_require__(56102);
|
|
|
// 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/checkbox/index.js + 3 modules
|
|
|
var es_checkbox = __webpack_require__(24905);
|
|
|
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/tooltip/index.js + 3 modules
|
|
|
var tooltip = __webpack_require__(6848);
|
|
|
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/button/index.js
|
|
|
var es_button = __webpack_require__(3113);
|
|
|
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/skeleton/index.js + 12 modules
|
|
|
var skeleton = __webpack_require__(59981);
|
|
|
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/table/index.js + 85 modules
|
|
|
var table = __webpack_require__(72315);
|
|
|
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/pagination/index.js + 10 modules
|
|
|
var pagination = __webpack_require__(41867);
|
|
|
// EXTERNAL MODULE: ./src/utils/util.tsx
|
|
|
var util = __webpack_require__(27291);
|
|
|
;// CONCATENATED MODULE: ./src/pages/Shixuns/Detail/Dataset/index.less?modules
|
|
|
// extracted by mini-css-extract-plugin
|
|
|
/* harmony default export */ var Datasetmodules = ({"bg":"bg___NFraa","wrap":"wrap___C_Y44","content":"content___t7bDk","modal":"modal___K3UdK","action":"action___pu6F6","actionButton":"actionButton___fYPEj","grayButton":"grayButton___sbGlB"});
|
|
|
// EXTERNAL MODULE: ./src/pages/Shixuns/Edit/body/Dataset/components/UploadFile/index.tsx + 1 modules
|
|
|
var UploadFile = __webpack_require__(40882);
|
|
|
// EXTERNAL MODULE: ./node_modules/_react@17.0.2@react/jsx-runtime.js
|
|
|
var jsx_runtime = __webpack_require__(37712);
|
|
|
;// CONCATENATED MODULE: ./src/pages/Shixuns/Detail/Dataset/index.tsx
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var _excluded = ["shixunsDetail", "globalSetting", "loading", "user", "dispatch"];
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var Dataset = function Dataset(_ref) {
|
|
|
var _shixunsDetail$detail, _shixunsDetail$detail2, _globalSetting$settin;
|
|
|
var shixunsDetail = _ref.shixunsDetail,
|
|
|
globalSetting = _ref.globalSetting,
|
|
|
loading = _ref.loading,
|
|
|
user = _ref.user,
|
|
|
dispatch = _ref.dispatch,
|
|
|
props = objectWithoutProperties_default()(_ref, _excluded);
|
|
|
var shixunId = (0,_react_17_0_2_react.useRef)();
|
|
|
var _useState = (0,_react_17_0_2_react.useState)([]),
|
|
|
_useState2 = slicedToArray_default()(_useState, 2),
|
|
|
dataList = _useState2[0],
|
|
|
setDataList = _useState2[1];
|
|
|
var _useState3 = (0,_react_17_0_2_react.useState)(0),
|
|
|
_useState4 = slicedToArray_default()(_useState3, 2),
|
|
|
count = _useState4[0],
|
|
|
setCount = _useState4[1];
|
|
|
var _useState5 = (0,_react_17_0_2_react.useState)([]),
|
|
|
_useState6 = slicedToArray_default()(_useState5, 2),
|
|
|
selectList = _useState6[0],
|
|
|
setSelectList = _useState6[1];
|
|
|
var _useState7 = (0,_react_17_0_2_react.useState)(),
|
|
|
_useState8 = slicedToArray_default()(_useState7, 2),
|
|
|
selectAll = _useState8[0],
|
|
|
setSelectAll = _useState8[1];
|
|
|
var _useState9 = (0,_react_17_0_2_react.useState)(false),
|
|
|
_useState10 = slicedToArray_default()(_useState9, 2),
|
|
|
showUploadList = _useState10[0],
|
|
|
setShowUploadList = _useState10[1];
|
|
|
var _useState11 = (0,_react_17_0_2_react.useState)(false),
|
|
|
_useState12 = slicedToArray_default()(_useState11, 2),
|
|
|
showUploadFile = _useState12[0],
|
|
|
setShowUploadFile = _useState12[1];
|
|
|
var _useState13 = (0,_react_17_0_2_react.useState)({
|
|
|
id: null,
|
|
|
page: 1,
|
|
|
limit: 10
|
|
|
}),
|
|
|
_useState14 = slicedToArray_default()(_useState13, 2),
|
|
|
params = _useState14[0],
|
|
|
setParams = _useState14[1];
|
|
|
(0,_react_17_0_2_react.useEffect)(function () {
|
|
|
var _location$pathname;
|
|
|
shixunId.current = (_location$pathname = location.pathname) === null || _location$pathname === void 0 || (_location$pathname = _location$pathname.split('/')) === null || _location$pathname === void 0 ? void 0 : _location$pathname[2];
|
|
|
params.id = shixunId.current;
|
|
|
setParams(params);
|
|
|
getSetData(params);
|
|
|
}, []);
|
|
|
var getSetData = /*#__PURE__*/function () {
|
|
|
var _ref2 = asyncToGenerator_default()( /*#__PURE__*/regeneratorRuntime_default()().mark(function _callee(query) {
|
|
|
var res;
|
|
|
return regeneratorRuntime_default()().wrap(function _callee$(_context) {
|
|
|
while (1) switch (_context.prev = _context.next) {
|
|
|
case 0:
|
|
|
_context.next = 2;
|
|
|
return dispatch({
|
|
|
type: 'shixunsDetail/getSetData',
|
|
|
payload: query
|
|
|
});
|
|
|
case 2:
|
|
|
res = _context.sent;
|
|
|
if (res) {
|
|
|
setDataList(toConsumableArray_default()(res.data_sets));
|
|
|
setCount(res.data_sets_count);
|
|
|
setSelectList([]);
|
|
|
setSelectAll(false);
|
|
|
}
|
|
|
case 4:
|
|
|
case "end":
|
|
|
return _context.stop();
|
|
|
}
|
|
|
}, _callee);
|
|
|
}));
|
|
|
return function getSetData(_x) {
|
|
|
return _ref2.apply(this, arguments);
|
|
|
};
|
|
|
}();
|
|
|
var handleChangePage = function handleChangePage(page) {
|
|
|
params.page = page;
|
|
|
setParams(params);
|
|
|
getSetData(params);
|
|
|
};
|
|
|
var handleChangeCheckbox = function handleChangeCheckbox(id, checked) {
|
|
|
if (checked) {
|
|
|
setSelectList([].concat(toConsumableArray_default()(selectList), [id]));
|
|
|
} else {
|
|
|
setSelectList(selectList.filter(function (item) {
|
|
|
return item !== id;
|
|
|
}));
|
|
|
}
|
|
|
};
|
|
|
var handleSelectAll = function handleSelectAll(checked) {
|
|
|
setSelectAll(checked);
|
|
|
if (checked) {
|
|
|
setSelectList(dataList.map(function (item) {
|
|
|
return item.id;
|
|
|
}));
|
|
|
} else {
|
|
|
setSelectList([]);
|
|
|
}
|
|
|
};
|
|
|
var handleDelete = function handleDelete() {
|
|
|
if (!selectList.length) {
|
|
|
message/* default */.ZP.info('请选择要删除的文件');
|
|
|
return;
|
|
|
}
|
|
|
modal/* default */.Z.confirm({
|
|
|
centered: true,
|
|
|
title: '确定要删除文件吗?',
|
|
|
okText: '确定',
|
|
|
cancelText: '取消',
|
|
|
onOk: function () {
|
|
|
var _onOk = asyncToGenerator_default()( /*#__PURE__*/regeneratorRuntime_default()().mark(function _callee2() {
|
|
|
var res;
|
|
|
return regeneratorRuntime_default()().wrap(function _callee2$(_context2) {
|
|
|
while (1) switch (_context2.prev = _context2.next) {
|
|
|
case 0:
|
|
|
_context2.next = 2;
|
|
|
return dispatch({
|
|
|
type: 'shixunsDetail/deleteDataSet',
|
|
|
payload: {
|
|
|
id: shixunId.current,
|
|
|
deleteId: selectList
|
|
|
}
|
|
|
});
|
|
|
case 2:
|
|
|
res = _context2.sent;
|
|
|
if (res) {
|
|
|
message/* default */.ZP.success('删除成功');
|
|
|
params.page = 1;
|
|
|
setParams(params);
|
|
|
getSetData(params);
|
|
|
}
|
|
|
case 4:
|
|
|
case "end":
|
|
|
return _context2.stop();
|
|
|
}
|
|
|
}, _callee2);
|
|
|
}));
|
|
|
function onOk() {
|
|
|
return _onOk.apply(this, arguments);
|
|
|
}
|
|
|
return onOk;
|
|
|
}()
|
|
|
});
|
|
|
};
|
|
|
var columns = [{
|
|
|
title: "",
|
|
|
dataIndex: "title",
|
|
|
width: 40,
|
|
|
ellipsis: true,
|
|
|
render: function render(add, record) {
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsx)(es_checkbox/* default */.Z, {
|
|
|
checked: selectList.includes(record.id),
|
|
|
onChange: function onChange(e) {
|
|
|
return handleChangeCheckbox(record.id, e.target.checked);
|
|
|
}
|
|
|
});
|
|
|
}
|
|
|
}, {
|
|
|
title: '文件',
|
|
|
dataIndex: 'title',
|
|
|
key: 'title',
|
|
|
align: 'left',
|
|
|
className: "font14",
|
|
|
width: '220px',
|
|
|
render: function render(text, record) {
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsx)("div", {
|
|
|
children: record.title
|
|
|
});
|
|
|
}
|
|
|
}, {
|
|
|
title: '创建时间',
|
|
|
dataIndex: 'created_on',
|
|
|
key: 'created_on',
|
|
|
align: 'center',
|
|
|
className: "font14",
|
|
|
width: '150px',
|
|
|
render: function render(text, record) {
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsx)("div", {
|
|
|
children: dayjs_min_default()(record.created_on).format('YYYY-MM-DD HH:mm')
|
|
|
});
|
|
|
}
|
|
|
}, {
|
|
|
title: '最后修改人',
|
|
|
dataIndex: 'author',
|
|
|
key: 'author',
|
|
|
align: 'center',
|
|
|
className: "font14",
|
|
|
render: function render(text, record) {
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsx)("div", {
|
|
|
children: record.author
|
|
|
});
|
|
|
}
|
|
|
}, {
|
|
|
title: '文件大小',
|
|
|
dataIndex: 'filesize',
|
|
|
key: 'filesize',
|
|
|
align: 'center',
|
|
|
className: "font14",
|
|
|
render: function render(text, record) {
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsx)("div", {
|
|
|
children: record.filesize
|
|
|
});
|
|
|
}
|
|
|
}, {
|
|
|
title: '操作',
|
|
|
dataIndex: 'operation',
|
|
|
key: 'operation',
|
|
|
align: 'center',
|
|
|
className: "font14 current",
|
|
|
render: function render(text, record) {
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsxs)(jsx_runtime.Fragment, {
|
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsx)(lib.CopyToClipboard, {
|
|
|
text: record.file_path,
|
|
|
onCopy: function onCopy() {
|
|
|
return message/* default */.ZP.success('复制成功');
|
|
|
},
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)(tooltip/* default */.Z, {
|
|
|
title: "\u590D\u5236",
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)("i", {
|
|
|
className: "iconfont icon-fuzhi3 font18 ml2"
|
|
|
})
|
|
|
})
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsx)(tooltip/* default */.Z, {
|
|
|
title: "\u4E0B\u8F7D",
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)("span", {
|
|
|
className: "current ml15 iconfont icon-xiazai2",
|
|
|
onClick: function onClick() {
|
|
|
(0,util/* downLoadLink */.Nd)(record.title, record === null || record === void 0 ? void 0 : record.download_url);
|
|
|
}
|
|
|
})
|
|
|
})]
|
|
|
});
|
|
|
}
|
|
|
}];
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsxs)("section", {
|
|
|
className: Datasetmodules.bg,
|
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsx)("div", {
|
|
|
className: Datasetmodules.wrap,
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsxs)("div", {
|
|
|
className: Datasetmodules.content,
|
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsxs)("div", {
|
|
|
className: Datasetmodules.action,
|
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsxs)("div", {
|
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsx)(es_checkbox/* default */.Z, {
|
|
|
checked: selectAll,
|
|
|
onChange: function onChange(e) {
|
|
|
return handleSelectAll(e.target.checked);
|
|
|
}
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsx)("span", {
|
|
|
className: "ml5",
|
|
|
children: "\u5168\u9009"
|
|
|
})]
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsxs)("div", {
|
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsx)(es_button/* default */.ZP, {
|
|
|
type: "primary",
|
|
|
danger: !!selectList.length,
|
|
|
className: "mr5 ".concat(Datasetmodules.actionButton, " ").concat(selectList.length ? '' : Datasetmodules.grayButton),
|
|
|
onClick: handleDelete,
|
|
|
children: "\u5220\u9664"
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsx)(es_button/* default */.ZP, {
|
|
|
type: "primary",
|
|
|
onClick: function onClick() {
|
|
|
return setShowUploadFile(true);
|
|
|
},
|
|
|
children: "\u4E0A\u4F20\u6587\u4EF6"
|
|
|
})]
|
|
|
})]
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsx)(skeleton/* default */.Z, {
|
|
|
loading: loading.effects['shixunsDetail/getSetData'],
|
|
|
active: true,
|
|
|
avatar: {
|
|
|
size: 40
|
|
|
},
|
|
|
paragraph: {
|
|
|
rows: 5
|
|
|
},
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)("div", {
|
|
|
className: "mt20",
|
|
|
children: !!dataList.length ? /*#__PURE__*/(0,jsx_runtime.jsx)(table/* default */.Z, {
|
|
|
columns: columns,
|
|
|
dataSource: dataList,
|
|
|
pagination: false,
|
|
|
loading: loading.effects['shixunsDetail/getSetData']
|
|
|
}) : /*#__PURE__*/(0,jsx_runtime.jsx)(NoData/* default */.Z, {})
|
|
|
})
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsx)("aside", {
|
|
|
className: "tc mt20",
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)(pagination/* default */.Z, {
|
|
|
showQuickJumper: true,
|
|
|
showSizeChanger: false,
|
|
|
total: count,
|
|
|
hideOnSinglePage: true,
|
|
|
onChange: function onChange(page) {
|
|
|
return handleChangePage(page);
|
|
|
},
|
|
|
pageSize: params.limit,
|
|
|
current: params.page
|
|
|
})
|
|
|
})]
|
|
|
})
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsx)(Right/* default */.Z, {}), /*#__PURE__*/(0,jsx_runtime.jsx)(UploadFile/* default */.Z, {
|
|
|
rootIdentifier: shixunsDetail === null || shixunsDetail === void 0 || (_shixunsDetail$detail = shixunsDetail.detail) === null || _shixunsDetail$detail === void 0 ? void 0 : _shixunsDetail$detail.root_identifier,
|
|
|
wrapClassName: Datasetmodules.uploadFileModal,
|
|
|
id: params.id,
|
|
|
containerId: shixunsDetail === null || shixunsDetail === void 0 || (_shixunsDetail$detail2 = shixunsDetail.detail) === null || _shixunsDetail$detail2 === void 0 ? void 0 : _shixunsDetail$detail2.id,
|
|
|
local: globalSetting === null || globalSetting === void 0 || (_globalSetting$settin = globalSetting.setting) === null || _globalSetting$settin === void 0 ? void 0 : _globalSetting$settin.is_local
|
|
|
// local={true}
|
|
|
,
|
|
|
dispatch: dispatch,
|
|
|
visible: showUploadFile,
|
|
|
onClose: function onClose() {
|
|
|
return setShowUploadFile(false);
|
|
|
},
|
|
|
onOK: function onOK() {
|
|
|
return handleChangePage(1);
|
|
|
}
|
|
|
})]
|
|
|
});
|
|
|
};
|
|
|
/* harmony default export */ var Detail_Dataset = ((0,_umi_production_exports.connect)(function (_ref3) {
|
|
|
var shixunsDetail = _ref3.shixunsDetail,
|
|
|
loading = _ref3.loading,
|
|
|
globalSetting = _ref3.globalSetting,
|
|
|
user = _ref3.user;
|
|
|
return {
|
|
|
shixunsDetail: shixunsDetail,
|
|
|
globalSetting: globalSetting,
|
|
|
user: user,
|
|
|
loading: loading
|
|
|
};
|
|
|
})(Dataset));
|
|
|
|
|
|
/***/ }),
|
|
|
|
|
|
/***/ 79250:
|
|
|
/*!*************************************************************************!*\
|
|
|
!*** ./src/pages/Shixuns/Detail/components/Right/index.tsx + 4 modules ***!
|
|
|
\*************************************************************************/
|
|
|
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
|
|
|
|
"use strict";
|
|
|
|
|
|
// EXPORTS
|
|
|
__webpack_require__.d(__webpack_exports__, {
|
|
|
Z: function() { return /* binding */ components_Right; }
|
|
|
});
|
|
|
|
|
|
// EXTERNAL MODULE: ./node_modules/_@babel_runtime@7.23.2@@babel/runtime/helpers/slicedToArray.js
|
|
|
var slicedToArray = __webpack_require__(11006);
|
|
|
var slicedToArray_default = /*#__PURE__*/__webpack_require__.n(slicedToArray);
|
|
|
// EXTERNAL MODULE: ./node_modules/_@babel_runtime@7.23.2@@babel/runtime/helpers/objectWithoutProperties.js
|
|
|
var objectWithoutProperties = __webpack_require__(27161);
|
|
|
var objectWithoutProperties_default = /*#__PURE__*/__webpack_require__.n(objectWithoutProperties);
|
|
|
// 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 + 8 modules
|
|
|
var _umi_production_exports = __webpack_require__(66660);
|
|
|
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/progress/index.js + 13 modules
|
|
|
var progress = __webpack_require__(93948);
|
|
|
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/tooltip/index.js + 3 modules
|
|
|
var tooltip = __webpack_require__(6848);
|
|
|
;// CONCATENATED MODULE: ./src/pages/Shixuns/Detail/components/Right/index.less?modules
|
|
|
// extracted by mini-css-extract-plugin
|
|
|
/* harmony default export */ var Rightmodules = ({"flex_box_center":"flex_box_center___PT9hL","flex_space_between":"flex_space_between___n2Hu5","flex_box_vertical_center":"flex_box_vertical_center___dwn6D","flex_box_center_end":"flex_box_center_end___TwHBO","flex_box_column":"flex_box_column___eAUqU","rightWrap":"rightWrap___Y_2WO","learnWrap":"learnWrap___mca1k","learnTopWrap":"learnTopWrap___cn6Tj","courseWrap":"courseWrap___N3Z6X","pathWrap":"pathWrap___QSdXs","pathImg":"pathImg___VjPqu","pathContentItem":"pathContentItem___sxOSQ","pathContentWrap":"pathContentWrap___WttwX","pathContentName":"pathContentName___evsEv","pathContent":"pathContent___fz4ds","pathContentCount":"pathContentCount___Jlv3G","recommandTrainingWrap":"recommandTrainingWrap___F1gpg","recommandContent":"recommandContent___JZYAA","recommandLevel":"recommandLevel___McDUw","color0152d9":"color0152d9___JWNjt","color999":"color999___npg2L","color888":"color888___l_1AP","color333":"color333___ec_mY","iconDeleteColor":"iconDeleteColor___aZjDG","iconMoveColor":"iconMoveColor___z4k0w","iconEditColor":"iconEditColor___wxNTY","skillWrap":"skillWrap___j6j3B","skillTopWrap":"skillTopWrap___kIJbE","time":"time___dTwAe","titleImg":"titleImg___I8kT9"});
|
|
|
;// CONCATENATED MODULE: ./src/assets/images/icons/learn.svg
|
|
|
function _createForOfIteratorHelper(o, allowArrayLike) { var it = typeof Symbol !== "undefined" && o[Symbol.iterator] || o["@@iterator"]; if (!it) { if (Array.isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") { if (it) o = it; var i = 0; var F = function F() {}; return { s: F, n: function n() { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function e(_e) { throw _e; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var normalCompletion = true, didErr = false, err; return { s: function s() { it = it.call(o); }, n: function n() { var step = it.next(); normalCompletion = step.done; return step; }, e: function e(_e2) { didErr = true; err = _e2; }, f: function f() { try { if (!normalCompletion && it["return"] != null) it["return"](); } finally { if (didErr) throw err; } } }; }
|
|
|
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
|
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
|
var __defProp = Object.defineProperty;
|
|
|
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
|
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
|
var __defNormalProp = function __defNormalProp(obj, key, value) {
|
|
|
return key in obj ? __defProp(obj, key, {
|
|
|
enumerable: true,
|
|
|
configurable: true,
|
|
|
writable: true,
|
|
|
value: value
|
|
|
}) : obj[key] = value;
|
|
|
};
|
|
|
var __spreadValues = function __spreadValues(a, b) {
|
|
|
for (var prop in b || (b = {})) if (__hasOwnProp.call(b, prop)) __defNormalProp(a, prop, b[prop]);
|
|
|
if (__getOwnPropSymbols) {
|
|
|
var _iterator = _createForOfIteratorHelper(__getOwnPropSymbols(b)),
|
|
|
_step;
|
|
|
try {
|
|
|
for (_iterator.s(); !(_step = _iterator.n()).done;) {
|
|
|
var prop = _step.value;
|
|
|
if (__propIsEnum.call(b, prop)) __defNormalProp(a, prop, b[prop]);
|
|
|
}
|
|
|
} catch (err) {
|
|
|
_iterator.e(err);
|
|
|
} finally {
|
|
|
_iterator.f();
|
|
|
}
|
|
|
}
|
|
|
return a;
|
|
|
};
|
|
|
|
|
|
var SvgLearn = function SvgLearn(props) {
|
|
|
return /* @__PURE__ */React.createElement("svg", __spreadValues({
|
|
|
width: 22,
|
|
|
height: 22,
|
|
|
xmlns: "http://www.w3.org/2000/svg"
|
|
|
}, props), /* @__PURE__ */React.createElement("title", null, "\u5B66\u4E60\u8FDB\u5EA6"), /* @__PURE__ */React.createElement("g", {
|
|
|
fill: "none",
|
|
|
fillRule: "evenodd"
|
|
|
}, /* @__PURE__ */React.createElement("path", {
|
|
|
d: "M10 2c.02 0 .03.75.032 1.839l.03 8.16H9.19l-3.932 6.005h.98L10.062 12H20c0 5.523-4.477 10-10 10S0 17.523 0 12 4.477 2 10 2Zm-.348 12.938c-.463 0-.834.147-1.113.443-.279.295-.418.693-.418 1.193 0 .453.13.819.39 1.096.261.277.606.416 1.036.416.458 0 .827-.148 1.105-.443.279-.296.418-.691.418-1.186 0-.482-.124-.855-.373-1.121-.248-.266-.597-.399-1.045-.399Zm-.039.71c.185 0 .333.074.444.221.11.147.166.358.166.631 0 .583-.209.875-.625.875-.414 0-.621-.281-.621-.844 0-.588.212-.883.636-.883Zm-3.715-3.78c-.468 0-.84.148-1.115.446-.275.299-.412.695-.412 1.19 0 .453.13.818.389 1.094.259.276.605.414 1.037.414.46 0 .83-.147 1.105-.442.276-.294.414-.686.414-1.175 0-.477-.124-.85-.373-1.122-.248-.27-.597-.406-1.045-.406Zm-.023.71c.401 0 .602.283.602.848 0 .583-.21.875-.63.875-.41 0-.617-.28-.617-.84 0-.589.215-.883.645-.883Z",
|
|
|
fill: "#1890FF"
|
|
|
}), /* @__PURE__ */React.createElement("path", {
|
|
|
d: "M11 0c5.982 0 10.848 4.774 10.997 10.72L22 11h-3.667c0-3.974-3.16-7.21-7.105-7.33L11 3.667V0Z",
|
|
|
fill: "#B6D0FC",
|
|
|
fillRule: "nonzero"
|
|
|
})));
|
|
|
};
|
|
|
|
|
|
/* harmony default export */ var learn = ("data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjIiIGhlaWdodD0iMjIiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PGcgZmlsbD0ibm9uZSIgZmlsbC1ydWxlPSJldmVub2RkIj48cGF0aCBkPSJNMTAgMmMuMDIgMCAuMDMuNzUuMDMyIDEuODM5bC4wMyA4LjE2SDkuMTlsLTMuOTMyIDYuMDA1aC45OEwxMC4wNjIgMTJIMjBjMCA1LjUyMy00LjQ3NyAxMC0xMCAxMFMwIDE3LjUyMyAwIDEyIDQuNDc3IDIgMTAgMlptLS4zNDggMTIuOTM4Yy0uNDYzIDAtLjgzNC4xNDctMS4xMTMuNDQzLS4yNzkuMjk1LS40MTguNjkzLS40MTggMS4xOTMgMCAuNDUzLjEzLjgxOS4zOSAxLjA5Ni4yNjEuMjc3LjYwNi40MTYgMS4wMzYuNDE2LjQ1OCAwIC44MjctLjE0OCAxLjEwNS0uNDQzLjI3OS0uMjk2LjQxOC0uNjkxLjQxOC0xLjE4NiAwLS40ODItLjEyNC0uODU1LS4zNzMtMS4xMjEtLjI0OC0uMjY2LS41OTctLjM5OS0xLjA0NS0uMzk5Wm0tLjAzOS43MWMuMTg1IDAgLjMzMy4wNzQuNDQ0LjIyMS4xMS4xNDcuMTY2LjM1OC4xNjYuNjMxIDAgLjU4My0uMjA5Ljg3NS0uNjI1Ljg3NS0uNDE0IDAtLjYyMS0uMjgxLS42MjEtLjg0NCAwLS41ODguMjEyLS44ODMuNjM2LS44ODNabS0zLjcxNS0zLjc4Yy0uNDY4IDAtLjg0LjE0OC0xLjExNS40NDYtLjI3NS4yOTktLjQxMi42OTUtLjQxMiAxLjE5IDAgLjQ1My4xMy44MTguMzg5IDEuMDk0LjI1OS4yNzYuNjA1LjQxNCAxLjAzNy40MTQuNDYgMCAuODMtLjE0NyAxLjEwNS0uNDQyLjI3Ni0uMjk0LjQxNC0uNjg2LjQxNC0xLjE3NSAwLS40NzctLjEyNC0uODUtLjM3My0xLjEyMi0uMjQ4LS4yNy0uNTk3LS40MDYtMS4wNDUtLjQwNlptLS4wMjMuNzFjLjQwMSAwIC42MDIuMjgzLjYwMi44NDggMCAuNTgzLS4yMS44NzUtLjYzLjg3NS0uNDEgMC0uNjE3LS4yOC0uNjE3LS44NCAwLS41ODkuMjE1LS44ODMuNjQ1LS44ODNaIiBmaWxsPSIjMTg5MEZGIi8+PHBhdGggZD0iTTExIDBjNS45ODIgMCAxMC44NDggNC43NzQgMTAuOTk3IDEwLjcyTDIyIDExaC0zLjY2N2MwLTMuOTc0LTMuMTYtNy4yMS03LjEwNS03LjMzTDExIDMuNjY3VjBaIiBmaWxsPSIjQjZEMEZDIiBmaWxsLXJ1bGU9Im5vbnplcm8iLz48L2c+PC9zdmc+");
|
|
|
;// CONCATENATED MODULE: ./src/assets/images/icons/course.svg
|
|
|
function course_createForOfIteratorHelper(o, allowArrayLike) { var it = typeof Symbol !== "undefined" && o[Symbol.iterator] || o["@@iterator"]; if (!it) { if (Array.isArray(o) || (it = course_unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") { if (it) o = it; var i = 0; var F = function F() {}; return { s: F, n: function n() { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function e(_e) { throw _e; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var normalCompletion = true, didErr = false, err; return { s: function s() { it = it.call(o); }, n: function n() { var step = it.next(); normalCompletion = step.done; return step; }, e: function e(_e2) { didErr = true; err = _e2; }, f: function f() { try { if (!normalCompletion && it["return"] != null) it["return"](); } finally { if (didErr) throw err; } } }; }
|
|
|
function course_unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return course_arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return course_arrayLikeToArray(o, minLen); }
|
|
|
function course_arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
|
var course_defProp = Object.defineProperty;
|
|
|
var course_getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
|
var course_hasOwnProp = Object.prototype.hasOwnProperty;
|
|
|
var course_propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
|
var course_defNormalProp = function __defNormalProp(obj, key, value) {
|
|
|
return key in obj ? course_defProp(obj, key, {
|
|
|
enumerable: true,
|
|
|
configurable: true,
|
|
|
writable: true,
|
|
|
value: value
|
|
|
}) : obj[key] = value;
|
|
|
};
|
|
|
var course_spreadValues = function __spreadValues(a, b) {
|
|
|
for (var prop in b || (b = {})) if (course_hasOwnProp.call(b, prop)) course_defNormalProp(a, prop, b[prop]);
|
|
|
if (course_getOwnPropSymbols) {
|
|
|
var _iterator = course_createForOfIteratorHelper(course_getOwnPropSymbols(b)),
|
|
|
_step;
|
|
|
try {
|
|
|
for (_iterator.s(); !(_step = _iterator.n()).done;) {
|
|
|
var prop = _step.value;
|
|
|
if (course_propIsEnum.call(b, prop)) course_defNormalProp(a, prop, b[prop]);
|
|
|
}
|
|
|
} catch (err) {
|
|
|
_iterator.e(err);
|
|
|
} finally {
|
|
|
_iterator.f();
|
|
|
}
|
|
|
}
|
|
|
return a;
|
|
|
};
|
|
|
|
|
|
var SvgCourse = function SvgCourse(props) {
|
|
|
return /* @__PURE__ */React.createElement("svg", course_spreadValues({
|
|
|
width: 22,
|
|
|
height: 20,
|
|
|
xmlns: "http://www.w3.org/2000/svg"
|
|
|
}, props), /* @__PURE__ */React.createElement("title", null, "\u6240\u5C5E\u8BFE\u7A0B"), /* @__PURE__ */React.createElement("g", {
|
|
|
fillRule: "nonzero",
|
|
|
fill: "none"
|
|
|
}, /* @__PURE__ */React.createElement("path", {
|
|
|
d: "M1.248.026h2.495c.833 0 1.249.415 1.249 1.243v17.39c0 .829-.416 1.243-1.249 1.243H1.248C.416 19.902 0 19.488 0 18.66V1.27C0 .44.416.025 1.248.025ZM7.488.026h2.496c.832 0 1.248.415 1.248 1.243v17.39c0 .829-.416 1.243-1.248 1.243H7.488c-.832 0-1.248-.414-1.248-1.242V1.27c0-.83.416-1.244 1.248-1.244Z",
|
|
|
fill: "#5091FF"
|
|
|
}), /* @__PURE__ */React.createElement("path", {
|
|
|
d: "m13.404.688 2.412-.646c.32-.085.66-.04.947.124.287.165.496.437.582.755l4.522 16.8a1.242 1.242 0 0 1-.883 1.52l-2.411.644a1.249 1.249 0 0 1-1.528-.879L12.522 2.208a1.238 1.238 0 0 1 .124-.943c.166-.285.439-.494.758-.579v.002Z",
|
|
|
fill: "#B6D0FC"
|
|
|
})));
|
|
|
};
|
|
|
|
|
|
/* harmony default export */ var course = ("data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjIiIGhlaWdodD0iMjAiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PGcgZmlsbC1ydWxlPSJub256ZXJvIiBmaWxsPSJub25lIj48cGF0aCBkPSJNMS4yNDguMDI2aDIuNDk1Yy44MzMgMCAxLjI0OS40MTUgMS4yNDkgMS4yNDN2MTcuMzljMCAuODI5LS40MTYgMS4yNDMtMS4yNDkgMS4yNDNIMS4yNDhDLjQxNiAxOS45MDIgMCAxOS40ODggMCAxOC42NlYxLjI3QzAgLjQ0LjQxNi4wMjUgMS4yNDguMDI1Wk03LjQ4OC4wMjZoMi40OTZjLjgzMiAwIDEuMjQ4LjQxNSAxLjI0OCAxLjI0M3YxNy4zOWMwIC44MjktLjQxNiAxLjI0My0xLjI0OCAxLjI0M0g3LjQ4OGMtLjgzMiAwLTEuMjQ4LS40MTQtMS4yNDgtMS4yNDJWMS4yN2MwLS44My40MTYtMS4yNDQgMS4yNDgtMS4yNDRaIiBmaWxsPSIjNTA5MUZGIi8+PHBhdGggZD0ibTEzLjQwNC42ODggMi40MTItLjY0NmMuMzItLjA4NS42Ni0uMDQuOTQ3LjEyNC4yODcuMTY1LjQ5Ni40MzcuNTgyLjc1NWw0LjUyMiAxNi44YTEuMjQyIDEuMjQyIDAgMCAxLS44ODMgMS41MmwtMi40MTEuNjQ0YTEuMjQ5IDEuMjQ5IDAgMCAxLTEuNTI4LS44NzlMMTIuNTIyIDIuMjA4YTEuMjM4IDEuMjM4IDAgMCAxIC4xMjQtLjk0M2MuMTY2LS4yODUuNDM5LS40OTQuNzU4LS41Nzl2LjAwMloiIGZpbGw9IiNCNkQwRkMiLz48L2c+PC9zdmc+");
|
|
|
;// CONCATENATED MODULE: ./src/assets/images/icons/star.svg
|
|
|
function star_createForOfIteratorHelper(o, allowArrayLike) { var it = typeof Symbol !== "undefined" && o[Symbol.iterator] || o["@@iterator"]; if (!it) { if (Array.isArray(o) || (it = star_unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") { if (it) o = it; var i = 0; var F = function F() {}; return { s: F, n: function n() { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function e(_e) { throw _e; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var normalCompletion = true, didErr = false, err; return { s: function s() { it = it.call(o); }, n: function n() { var step = it.next(); normalCompletion = step.done; return step; }, e: function e(_e2) { didErr = true; err = _e2; }, f: function f() { try { if (!normalCompletion && it["return"] != null) it["return"](); } finally { if (didErr) throw err; } } }; }
|
|
|
function star_unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return star_arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return star_arrayLikeToArray(o, minLen); }
|
|
|
function star_arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
|
var star_defProp = Object.defineProperty;
|
|
|
var star_getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
|
var star_hasOwnProp = Object.prototype.hasOwnProperty;
|
|
|
var star_propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
|
var star_defNormalProp = function __defNormalProp(obj, key, value) {
|
|
|
return key in obj ? star_defProp(obj, key, {
|
|
|
enumerable: true,
|
|
|
configurable: true,
|
|
|
writable: true,
|
|
|
value: value
|
|
|
}) : obj[key] = value;
|
|
|
};
|
|
|
var star_spreadValues = function __spreadValues(a, b) {
|
|
|
for (var prop in b || (b = {})) if (star_hasOwnProp.call(b, prop)) star_defNormalProp(a, prop, b[prop]);
|
|
|
if (star_getOwnPropSymbols) {
|
|
|
var _iterator = star_createForOfIteratorHelper(star_getOwnPropSymbols(b)),
|
|
|
_step;
|
|
|
try {
|
|
|
for (_iterator.s(); !(_step = _iterator.n()).done;) {
|
|
|
var prop = _step.value;
|
|
|
if (star_propIsEnum.call(b, prop)) star_defNormalProp(a, prop, b[prop]);
|
|
|
}
|
|
|
} catch (err) {
|
|
|
_iterator.e(err);
|
|
|
} finally {
|
|
|
_iterator.f();
|
|
|
}
|
|
|
}
|
|
|
return a;
|
|
|
};
|
|
|
|
|
|
var SvgStar = function SvgStar(props) {
|
|
|
return /* @__PURE__ */React.createElement("svg", star_spreadValues({
|
|
|
width: 22,
|
|
|
height: 22,
|
|
|
xmlns: "http://www.w3.org/2000/svg"
|
|
|
}, props), /* @__PURE__ */React.createElement("title", null, "\u63A8\u8350\u5B9E\u8BAD"), /* @__PURE__ */React.createElement("g", {
|
|
|
fillRule: "nonzero",
|
|
|
fill: "none"
|
|
|
}, /* @__PURE__ */React.createElement("path", {
|
|
|
d: "M15.503 21.896a2.067 2.067 0 0 1-.87-.201 451.987 451.987 0 0 1-4.376-2.11c-1.466.69-2.931 1.384-4.396 2.08-.674.299-1.33.26-1.816-.096-.458-.335-.685-.912-.624-1.579.173-1.56.465-3.693.574-4.485a188.029 188.029 0 0 1-3.587-3.922 1.5 1.5 0 0 1-.3-1.51c.213-.574.76-.982 1.472-1.086l4.655-.853A512.95 512.95 0 0 1 8.787 3.73c.717-1.344 1.426-1.344 1.8-1.209.407.134.792.531 1.177 1.223.829 1.433 2.08 3.642 2.504 4.391l4.61.858c.678.1 1.218.507 1.428 1.084a1.507 1.507 0 0 1-.286 1.504 192.808 192.808 0 0 1-3.556 3.944c.104.788.388 2.927.573 4.479.071.685-.152 1.269-.616 1.609a1.55 1.55 0 0 1-.916.284h-.002Z",
|
|
|
fill: "#5091FF"
|
|
|
}), /* @__PURE__ */React.createElement("path", {
|
|
|
d: "M21.706 4.462a.557.557 0 0 1-.247.073c-.45.03-1.122.067-1.397.08l-.778 1.2c-.122.18-.29.265-.464.24-.163-.02-.306-.14-.39-.329a60.81 60.81 0 0 1-.529-1.278 53.009 53.009 0 0 1-1.476-.518.475.475 0 0 1-.3-.36.533.533 0 0 1 .2-.505l1.025-.91c-.011-.516-.02-1.032-.028-1.548-.024-.463.15-.568.264-.585.121-.026.275.024.474.151.419.262 1.06.667 1.277.804l1.27-.448a.49.49 0 0 1 .515.08c.124.11.183.28.155.441-.09.526-.186 1.052-.29 1.574.145.194.536.722.814 1.11.12.172.152.36.088.518a.435.435 0 0 1-.185.21h.002ZM2.859 5.83a.287.287 0 0 1-.093-.091 62.17 62.17 0 0 1-.382-.603 49.99 49.99 0 0 0-.7-.045c-.106-.01-.185-.063-.218-.146a.276.276 0 0 1 .04-.255c.14-.197.334-.46.407-.557a28.397 28.397 0 0 1-.149-.786.243.243 0 0 1 .076-.223.25.25 0 0 1 .264-.037l.64.228c.108-.068.431-.27.644-.398.19-.128.278-.075.314-.03.04.047.059.128.054.25l-.019.768.506.453a.258.258 0 0 1 .095.249.238.238 0 0 1-.147.178c-.245.092-.49.18-.736.265-.047.113-.171.42-.264.64-.044.095-.115.159-.197.168a.208.208 0 0 1-.135-.028Z",
|
|
|
fill: "#B6D0FC"
|
|
|
})));
|
|
|
};
|
|
|
|
|
|
/* harmony default export */ var star = ("data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjIiIGhlaWdodD0iMjIiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PGcgZmlsbC1ydWxlPSJub256ZXJvIiBmaWxsPSJub25lIj48cGF0aCBkPSJNMTUuNTAzIDIxLjg5NmEyLjA2NyAyLjA2NyAwIDAgMS0uODctLjIwMSA0NTEuOTg3IDQ1MS45ODcgMCAwIDEtNC4zNzYtMi4xMWMtMS40NjYuNjktMi45MzEgMS4zODQtNC4zOTYgMi4wOC0uNjc0LjI5OS0xLjMzLjI2LTEuODE2LS4wOTYtLjQ1OC0uMzM1LS42ODUtLjkxMi0uNjI0LTEuNTc5LjE3My0xLjU2LjQ2NS0zLjY5My41NzQtNC40ODVhMTg4LjAyOSAxODguMDI5IDAgMCAxLTMuNTg3LTMuOTIyIDEuNSAxLjUgMCAwIDEtLjMtMS41MWMuMjEzLS41NzQuNzYtLjk4MiAxLjQ3Mi0xLjA4Nmw0LjY1NS0uODUzQTUxMi45NSA1MTIuOTUgMCAwIDEgOC43ODcgMy43M2MuNzE3LTEuMzQ0IDEuNDI2LTEuMzQ0IDEuOC0xLjIwOS40MDcuMTM0Ljc5Mi41MzEgMS4xNzcgMS4yMjMuODI5IDEuNDMzIDIuMDggMy42NDIgMi41MDQgNC4zOTFsNC42MS44NThjLjY3OC4xIDEuMjE4LjUwNyAxLjQyOCAxLjA4NGExLjUwNyAxLjUwNyAwIDAgMS0uMjg2IDEuNTA0IDE5Mi44MDggMTkyLjgwOCAwIDAgMS0zLjU1NiAzLjk0NGMuMTA0Ljc4OC4zODggMi45MjcuNTczIDQuNDc5LjA3MS42ODUtLjE1MiAxLjI2OS0uNjE2IDEuNjA5YTEuNTUgMS41NSAwIDAgMS0uOTE2LjI4NGgtLjAwMloiIGZpbGw9IiM1MDkxRkYiLz48cGF0aCBkPSJNMjEuNzA2IDQuNDYyYS41NTcuNTU3IDAgMCAxLS4yNDcuMDczYy0uNDUuMDMtMS4xMjIuMDY3LTEuMzk3LjA4bC0uNzc4IDEuMmMtLjEyMi4xOC0uMjkuMjY1LS40NjQuMjQtLjE2My0uMDItLjMwNi0uMTQtLjM5LS4zMjlhNjAuODEgNjAuODEgMCAwIDEtLjUyOS0xLjI3OCA1My4wMDkgNTMuMDA5IDAgMCAxLTEuNDc2LS41MTguNDc1LjQ3NSAwIDAgMS0uMy0uMzYuNTMzLjUzMyAwIDAgMSAuMi0uNTA1bDEuMDI1LS45MWMtLjAxMS0uNTE2LS4wMi0xLjAzMi0uMDI4LTEuNTQ4LS4wMjQtLjQ2My4xNS0uNTY4LjI2NC0uNTg1LjEyMS0uMDI2LjI3NS4wMjQuNDc0LjE1MS40MTkuMjYyIDEuMDYuNjY3IDEuMjc3LjgwNGwxLjI3LS40NDhhLjQ5LjQ5IDAgMCAxIC41MTUuMDhjLjEyNC4xMS4xODMuMjguMTU1LjQ0MS0uMDkuNTI2LS4xODYgMS4wNTItLjI5IDEuNTc0LjE0NS4xOTQuNTM2LjcyMi44MTQgMS4xMS4xMi4xNzIuMTUyLjM2LjA4OC41MThhLjQzNS40MzUgMCAwIDEtLjE4NS4yMWguMDAyWk0yLjg1OSA1LjgzYS4yODcuMjg3IDAgMCAxLS4wOTMtLjA5MSA2Mi4xNyA2Mi4xNyAwIDAgMS0uMzgyLS42MDMgNDkuOTkgNDkuOTkgMCAwIDAtLjctLjA0NWMtLjEwNi0uMDEtLjE4NS0uMDYzLS4yMTgtLjE0NmEuMjc2LjI3NiAwIDAgMSAuMDQtLjI1NWMuMTQtLjE5Ny4zMzQtLjQ2LjQwNy0uNTU3YTI4LjM5NyAyOC4zOTcgMCAwIDEtLjE0OS0uNzg2LjI0My4yNDMgMCAwIDEgLjA3Ni0uMjIzLjI1LjI1IDAgMCAxIC4yNjQtLjAzN2wuNjQuMjI4Yy4xMDgtLjA2OC40MzEtLjI3LjY0NC0uMzk4LjE5LS4xMjguMjc4LS4wNzUuMzE0LS4wMy4wNC4wNDcuMDU5LjEyOC4wNTQuMjVsLS4wMTkuNzY4LjUwNi40NTNhLjI1OC4yNTggMCAwIDEgLjA5NS4yNDkuMjM4LjIzOCAwIDAgMS0uMTQ3LjE3OGMtLjI0NS4wOTItLjQ5LjE4LS43MzYuMjY1LS4wNDcuMTEzLS4xNzEuNDItLjI2NC42NC0uMDQ0LjA5NS0uMTE1LjE1OS0uMTk3LjE2OGEuMjA4LjIwOCAwIDAgMS0uMTM1LS4wMjhaIiBmaWxsPSIjQjZEMEZDIi8+PC9nPjwvc3ZnPg==");
|
|
|
// EXTERNAL MODULE: ./node_modules/_echarts-for-react@2.0.16@echarts-for-react/lib/index.js
|
|
|
var lib = __webpack_require__(42441);
|
|
|
// EXTERNAL MODULE: ./src/components/ImagesIcon/index.ts + 32 modules
|
|
|
var ImagesIcon = __webpack_require__(19770);
|
|
|
// EXTERNAL MODULE: ./node_modules/_echarts-wordcloud@1.1.3@echarts-wordcloud/index.js
|
|
|
var _echarts_wordcloud_1_1_3_echarts_wordcloud = __webpack_require__(56047);
|
|
|
// EXTERNAL MODULE: ./node_modules/_react@17.0.2@react/jsx-runtime.js
|
|
|
var jsx_runtime = __webpack_require__(37712);
|
|
|
;// CONCATENATED MODULE: ./src/pages/Shixuns/Detail/components/Right/index.tsx
|
|
|
|
|
|
|
|
|
var _excluded = ["shixunsDetail", "user", "globalSetting", "loading", "dispatch"];
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var Right = function Right(_ref) {
|
|
|
var _shixunsDetail$rightD2, _shixunsDetail$rightD3, _shixunsDetail$rightD4, _shixunsDetail$detail, _shixunsDetail$detail2, _user$userInfo, _shixunsDetail$rightD5, _shixunsDetail$rightD6, _shixunsDetail$rightD7, _shixunsDetail$rightD8, _shixunsDetail$rightD9, _shixunsDetail$rightD10, _shixunsDetail$rightD11, _shixunsDetail$detail3, _shixunsDetail$rightD12, _shixunsDetail$rightD13, _shixunsDetail$rightD14;
|
|
|
var shixunsDetail = _ref.shixunsDetail,
|
|
|
user = _ref.user,
|
|
|
globalSetting = _ref.globalSetting,
|
|
|
loading = _ref.loading,
|
|
|
dispatch = _ref.dispatch,
|
|
|
props = objectWithoutProperties_default()(_ref, _excluded);
|
|
|
var _useState = (0,_react_17_0_2_react.useState)(true),
|
|
|
_useState2 = slicedToArray_default()(_useState, 2),
|
|
|
showExpandAll = _useState2[0],
|
|
|
setShowExpandAll = _useState2[1];
|
|
|
var getOption = function getOption() {
|
|
|
var _shixunsDetail$rightD;
|
|
|
var maskImage = new Image();
|
|
|
// 此为词云图呈现形状的图片base64码,可选,可以自定义图片
|
|
|
maskImage.src = ImagesIcon/* hbIcon */.yt;
|
|
|
// "data:image/svg+xml;utf8;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iaXNvLTg4NTktMSI/Pgo8IS0tIEdlbmVyYXRvcjogQWRvYmUgSWxsdXN0cmF0b3IgMTYuMC4wLCBTVkcgRXhwb3J0IFBsdWctSW4gLiBTVkcgVmVyc2lvbjogNi4wMCBCdWlsZCAwKSAgLS0+CjwhRE9DVFlQRSBzdmcgUFVCTElDICItLy9XM0MvL0RURCBTVkcgMS4xLy9FTiIgImh0dHA6Ly93d3cudzMub3JnL0dyYXBoaWNzL1NWRy8xLjEvRFREL3N2ZzExLmR0ZCI+CjxzdmcgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgdmVyc2lvbj0iMS4xIiBpZD0iQ2FwYV8xIiB4PSIwcHgiIHk9IjBweCIgd2lkdGg9IjI1NnB4IiBoZWlnaHQ9IjI1NnB4IiB2aWV3Qm94PSIwIDAgNTQ4LjE3NiA1NDguMTc2IiBzdHlsZT0iZW5hYmxlLWJhY2tncm91bmQ6bmV3IDAgMCA1NDguMTc2IDU0OC4xNzY7IiB4bWw6c3BhY2U9InByZXNlcnZlIj4KPGc+Cgk8cGF0aCBkPSJNNTI0LjE4MywyOTcuMDY1Yy0xNS45ODUtMTkuODkzLTM2LjI2NS0zMi42OTEtNjAuODE1LTM4LjM5OWM3LjgxLTExLjk5MywxMS43MDQtMjUuMTI2LDExLjcwNC0zOS4zOTkgICBjMC0yMC4xNzctNy4xMzktMzcuNDAxLTIxLjQwOS01MS42NzhjLTE0LjI3My0xNC4yNzItMzEuNDk4LTIxLjQxMS01MS42NzUtMjEuNDExYy0xOC4yNzEsMC0zNC4wNzEsNS45MDEtNDcuMzksMTcuNzAzICAgYy0xMS4yMjUtMjcuMDI4LTI5LjA3NS00OC45MTctNTMuNTI5LTY1LjY2N2MtMjQuNDYtMTYuNzQ2LTUxLjcyOC0yNS4xMjUtODEuODAyLTI1LjEyNWMtNDAuMzQ5LDAtNzQuODAyLDE0LjI3OS0xMDMuMzUzLDQyLjgzICAgYy0yOC41NTMsMjguNTQ0LTQyLjgyNSw2Mi45OTktNDIuODI1LDEwMy4zNTFjMCwyLjg1NiwwLjE5MSw2Ljk0NSwwLjU3MSwxMi4yNzVjLTIyLjA3OCwxMC4yNzktMzkuODc2LDI1LjgzOC01My4zODksNDYuNjg2ICAgQzYuNzU5LDI5OS4wNjcsMCwzMjIuMDU1LDAsMzQ3LjE4YzAsMzUuMjExLDEyLjUxNyw2NS4zMzMsMzcuNTQ0LDkwLjM1OWMyNS4wMjgsMjUuMDMzLDU1LjE1LDM3LjU0OCw5MC4zNjIsMzcuNTQ4aDMxMC42MzYgICBjMzAuMjU5LDAsNTYuMDk2LTEwLjcxNSw3Ny41MTItMzIuMTIxYzIxLjQxMy0yMS40MTIsMzIuMTIxLTQ3LjI0OSwzMi4xMjEtNzcuNTE1ICAgQzU0OC4xNzIsMzM5Ljc1Nyw1NDAuMTc0LDMxNi45NTIsNTI0LjE4MywyOTcuMDY1eiIgZmlsbD0iI0ZGRkZGRiIvPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+Cjwvc3ZnPgo=";
|
|
|
|
|
|
var wordData = (shixunsDetail === null || shixunsDetail === void 0 || (_shixunsDetail$rightD = shixunsDetail.rightData) === null || _shixunsDetail$rightD === void 0 || (_shixunsDetail$rightD = _shixunsDetail$rightD.tags) === null || _shixunsDetail$rightD === void 0 ? void 0 : _shixunsDetail$rightD.map(function (item, key) {
|
|
|
return {
|
|
|
name: item.tag_name,
|
|
|
value: key
|
|
|
};
|
|
|
})) || [];
|
|
|
var option = {
|
|
|
backgroundColor: "#fff",
|
|
|
tooltip: {
|
|
|
pointFormat: "{series.name}</b>"
|
|
|
},
|
|
|
series: [{
|
|
|
type: "wordCloud",
|
|
|
sizeRange: [10, 30],
|
|
|
rotationRange: [-90, 90],
|
|
|
rotationStep: 45,
|
|
|
gridSize: 2,
|
|
|
shape: 'pentagon',
|
|
|
//circle pentagon
|
|
|
maskImage: maskImage,
|
|
|
// 呈现形状图片, 可选
|
|
|
textStyle: {
|
|
|
normal: {
|
|
|
color: function color() {
|
|
|
return "rgb(" + Math.round(Math.random() * 255) + ", " + Math.round(Math.random() * 255) + ", " + Math.round(Math.random() * 255) + ")";
|
|
|
}
|
|
|
}
|
|
|
},
|
|
|
// Folllowing left/top/width/height/right/bottom are used for positioning the word cloud
|
|
|
// Default to be put in the center and has 75% x 80% size.
|
|
|
left: "center",
|
|
|
top: "center",
|
|
|
right: null,
|
|
|
bottom: null,
|
|
|
width: "100%",
|
|
|
height: "100%",
|
|
|
data: wordData
|
|
|
}]
|
|
|
};
|
|
|
return option;
|
|
|
};
|
|
|
console.log('----', shixunsDetail);
|
|
|
var progressPercent = (_shixunsDetail$rightD2 = shixunsDetail.rightData) !== null && _shixunsDetail$rightD2 !== void 0 && _shixunsDetail$rightD2.complete_count ? Number((_shixunsDetail$rightD3 = shixunsDetail.rightData) === null || _shixunsDetail$rightD3 === void 0 ? void 0 : _shixunsDetail$rightD3.complete_count) / Number((_shixunsDetail$rightD4 = shixunsDetail.rightData) === null || _shixunsDetail$rightD4 === void 0 ? void 0 : _shixunsDetail$rightD4.challenge_count) * 100 : 0;
|
|
|
return shixunsDetail.rightData ? /*#__PURE__*/(0,jsx_runtime.jsxs)("section", {
|
|
|
className: Rightmodules.rightWrap,
|
|
|
children: [!((_shixunsDetail$detail = shixunsDetail.detail) !== null && _shixunsDetail$detail !== void 0 && _shixunsDetail$detail.is_jupyter) && ((_shixunsDetail$detail2 = shixunsDetail.detail) === null || _shixunsDetail$detail2 === void 0 || (_shixunsDetail$detail2 = _shixunsDetail$detail2.task_operation) === null || _shixunsDetail$detail2 === void 0 ? void 0 : _shixunsDetail$detail2[2]) && (user === null || user === void 0 || (_user$userInfo = user.userInfo) === null || _user$userInfo === void 0 ? void 0 : _user$userInfo.login) && !!((_shixunsDetail$rightD5 = shixunsDetail.rightData) !== null && _shixunsDetail$rightD5 !== void 0 && _shixunsDetail$rightD5.complete_count) && ((_shixunsDetail$rightD6 = shixunsDetail.rightData) === null || _shixunsDetail$rightD6 === void 0 ? void 0 : _shixunsDetail$rightD6.complete_count) > 0 && /*#__PURE__*/(0,jsx_runtime.jsxs)("div", {
|
|
|
className: Rightmodules.learnWrap,
|
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsxs)("div", {
|
|
|
className: Rightmodules.learnTopWrap,
|
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsxs)("span", {
|
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsx)("img", {
|
|
|
className: Rightmodules.titleImg,
|
|
|
src: learn,
|
|
|
alt: ""
|
|
|
}), "\u5B66\u4E60\u8FDB\u5EA6"]
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsx)("span", {
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsxs)("span", {
|
|
|
className: "".concat(Rightmodules.color888, " font14"),
|
|
|
children: ["\u5DF2\u5B8C\u6210 ", ((_shixunsDetail$rightD7 = shixunsDetail.rightData) === null || _shixunsDetail$rightD7 === void 0 ? void 0 : _shixunsDetail$rightD7.complete_count) || 0, " \u5173 / \u5171", ((_shixunsDetail$rightD8 = shixunsDetail.rightData) === null || _shixunsDetail$rightD8 === void 0 ? void 0 : _shixunsDetail$rightD8.challenge_count) || 0, " \u5173"]
|
|
|
})
|
|
|
})]
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsx)(progress/* default */.Z, {
|
|
|
percent: progressPercent,
|
|
|
showInfo: false,
|
|
|
status: "active",
|
|
|
strokeColor: {
|
|
|
'0%': '#29BD8B',
|
|
|
'100%': '#29BD8B'
|
|
|
}
|
|
|
})]
|
|
|
}), !!((_shixunsDetail$rightD9 = shixunsDetail.rightData) !== null && _shixunsDetail$rightD9 !== void 0 && (_shixunsDetail$rightD9 = _shixunsDetail$rightD9.paths) !== null && _shixunsDetail$rightD9 !== void 0 && _shixunsDetail$rightD9.length) && /*#__PURE__*/(0,jsx_runtime.jsxs)("div", {
|
|
|
className: Rightmodules.courseWrap,
|
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsxs)("p", {
|
|
|
className: "mb20 font16",
|
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsx)("img", {
|
|
|
className: Rightmodules.titleImg,
|
|
|
src: course,
|
|
|
alt: ""
|
|
|
}), "\u6240\u5C5E\u8BFE\u7A0B"]
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsx)("div", {
|
|
|
children: (_shixunsDetail$rightD10 = shixunsDetail.rightData) === null || _shixunsDetail$rightD10 === void 0 ? void 0 : _shixunsDetail$rightD10.paths.map(function (item, key) {
|
|
|
if (key > 2) {
|
|
|
return null;
|
|
|
}
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsxs)("div", {
|
|
|
className: Rightmodules.pathWrap,
|
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsx)("a", {
|
|
|
href: "/paths/".concat(item.id),
|
|
|
target: "_blank",
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)("img", {
|
|
|
alt: "\u5B9E\u8BAD",
|
|
|
src: "".concat(item.image_url),
|
|
|
className: Rightmodules.pathImg
|
|
|
})
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsxs)("div", {
|
|
|
className: Rightmodules.pathContentWrap,
|
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsx)("a", {
|
|
|
href: "/paths/".concat(item.id),
|
|
|
target: "_blank",
|
|
|
className: Rightmodules.pathContentName,
|
|
|
children: item.name
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsxs)("p", {
|
|
|
className: Rightmodules.pathContent,
|
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsx)(tooltip/* default */.Z, {
|
|
|
placement: "bottom",
|
|
|
title: "\u7AE0\u8282",
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsxs)("span", {
|
|
|
className: Rightmodules.pathContentCount,
|
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsx)("i", {
|
|
|
className: "iconfont icon-shixun mr3"
|
|
|
}), item.stages_count]
|
|
|
})
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsx)(tooltip/* default */.Z, {
|
|
|
placement: "bottom",
|
|
|
title: "\u5B66\u4E60\u4EBA\u6570",
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsxs)("span", {
|
|
|
className: Rightmodules.pathContentCount,
|
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsx)("i", {
|
|
|
className: "iconfont icon-chengyuan mr3"
|
|
|
}), item.members_count]
|
|
|
})
|
|
|
})]
|
|
|
})]
|
|
|
})]
|
|
|
}, item.id);
|
|
|
})
|
|
|
})]
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsx)("div", {}), !!((_shixunsDetail$rightD11 = shixunsDetail.rightData) !== null && _shixunsDetail$rightD11 !== void 0 && (_shixunsDetail$rightD11 = _shixunsDetail$rightD11.recommands) !== null && _shixunsDetail$rightD11 !== void 0 && _shixunsDetail$rightD11.length) && user.userInfo.main_site && /*#__PURE__*/(0,jsx_runtime.jsxs)("div", {
|
|
|
className: Rightmodules.recommandTrainingWrap,
|
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsxs)("p", {
|
|
|
className: "mb20 font16",
|
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsx)("img", {
|
|
|
className: Rightmodules.titleImg,
|
|
|
src: star,
|
|
|
alt: ""
|
|
|
}), (shixunsDetail === null || shixunsDetail === void 0 || (_shixunsDetail$detail3 = shixunsDetail.detail) === null || _shixunsDetail$detail3 === void 0 || (_shixunsDetail$detail3 = _shixunsDetail$detail3.disciplines) === null || _shixunsDetail$detail3 === void 0 ? void 0 : _shixunsDetail$detail3.length) > 0 ? '相关推荐' : '热门推荐']
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsx)("div", {
|
|
|
children: (_shixunsDetail$rightD12 = shixunsDetail.rightData) === null || _shixunsDetail$rightD12 === void 0 ? void 0 : _shixunsDetail$rightD12.recommands.map(function (item, key) {
|
|
|
if (key > 2) {
|
|
|
return null;
|
|
|
}
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsxs)("div", {
|
|
|
className: Rightmodules.pathContentItem,
|
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsx)("a", {
|
|
|
href: "/shixuns/".concat(item.identifier, "/challenges"),
|
|
|
target: "_blank",
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)("img", {
|
|
|
src: "".concat(item.pic),
|
|
|
className: Rightmodules.pathImg
|
|
|
})
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsxs)("div", {
|
|
|
className: Rightmodules.pathContentWrap,
|
|
|
style: {
|
|
|
marginBottom: -4
|
|
|
},
|
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsx)(tooltip/* default */.Z, {
|
|
|
placement: "bottom",
|
|
|
title: item.name,
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)("a", {
|
|
|
href: "/shixuns/".concat(item.identifier, "/challenges"),
|
|
|
target: "_blank",
|
|
|
className: Rightmodules.pathContentName,
|
|
|
children: item.name
|
|
|
})
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsxs)("p", {
|
|
|
className: "".concat(Rightmodules.pathContent, " ").concat(Rightmodules.recommandContent),
|
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsxs)("span", {
|
|
|
children: [item.stu_num, " \u4EBA\u5B66\u4E60"]
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsx)("span", {
|
|
|
className: Rightmodules.recommandLevel,
|
|
|
children: item.level
|
|
|
})]
|
|
|
})]
|
|
|
})]
|
|
|
}, key);
|
|
|
})
|
|
|
})]
|
|
|
}), ((_shixunsDetail$rightD13 = shixunsDetail.rightData) === null || _shixunsDetail$rightD13 === void 0 || (_shixunsDetail$rightD13 = _shixunsDetail$rightD13.tags) === null || _shixunsDetail$rightD13 === void 0 ? void 0 : _shixunsDetail$rightD13.length) > 0 && /*#__PURE__*/(0,jsx_runtime.jsxs)("div", {
|
|
|
className: Rightmodules.skillWrap,
|
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsx)("p", {
|
|
|
className: "".concat(Rightmodules.skillTopWrap, " font16 mb20"),
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsxs)("span", {
|
|
|
children: ["\u6280\u80FD\u6807\u7B7E", /*#__PURE__*/(0,jsx_runtime.jsx)("span", {
|
|
|
className: "ml5 c-grey-c",
|
|
|
children: (_shixunsDetail$rightD14 = shixunsDetail.rightData) === null || _shixunsDetail$rightD14 === void 0 || (_shixunsDetail$rightD14 = _shixunsDetail$rightD14.tags) === null || _shixunsDetail$rightD14 === void 0 ? void 0 : _shixunsDetail$rightD14.length
|
|
|
})]
|
|
|
})
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsx)(lib/* default */.Z, {
|
|
|
option: getOption(),
|
|
|
style: {
|
|
|
height: 370
|
|
|
},
|
|
|
opts: {
|
|
|
renderer: 'svg'
|
|
|
} // use svg to render the chart.
|
|
|
})]
|
|
|
})]
|
|
|
}) : null;
|
|
|
};
|
|
|
/* harmony default export */ var components_Right = ((0,_umi_production_exports.connect)(function (_ref2) {
|
|
|
var shixunsDetail = _ref2.shixunsDetail,
|
|
|
user = _ref2.user,
|
|
|
loading = _ref2.loading,
|
|
|
globalSetting = _ref2.globalSetting;
|
|
|
return {
|
|
|
shixunsDetail: shixunsDetail,
|
|
|
user: user,
|
|
|
globalSetting: globalSetting,
|
|
|
loading: loading.models.index
|
|
|
};
|
|
|
})(Right));
|
|
|
|
|
|
/***/ }),
|
|
|
|
|
|
/***/ 40882:
|
|
|
/*!*****************************************************************************************!*\
|
|
|
!*** ./src/pages/Shixuns/Edit/body/Dataset/components/UploadFile/index.tsx + 1 modules ***!
|
|
|
\*****************************************************************************************/
|
|
|
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
|
|
|
|
"use strict";
|
|
|
|
|
|
// EXPORTS
|
|
|
__webpack_require__.d(__webpack_exports__, {
|
|
|
Z: function() { return /* binding */ Dataset_components_UploadFile; }
|
|
|
});
|
|
|
|
|
|
// EXTERNAL MODULE: ./node_modules/_@babel_runtime@7.23.2@@babel/runtime/helpers/objectSpread2.js
|
|
|
var objectSpread2 = __webpack_require__(26801);
|
|
|
var objectSpread2_default = /*#__PURE__*/__webpack_require__.n(objectSpread2);
|
|
|
// EXTERNAL MODULE: ./node_modules/_@babel_runtime@7.23.2@@babel/runtime/helpers/regeneratorRuntime.js
|
|
|
var regeneratorRuntime = __webpack_require__(10574);
|
|
|
var regeneratorRuntime_default = /*#__PURE__*/__webpack_require__.n(regeneratorRuntime);
|
|
|
// EXTERNAL MODULE: ./node_modules/_@babel_runtime@7.23.2@@babel/runtime/helpers/toConsumableArray.js
|
|
|
var toConsumableArray = __webpack_require__(93923);
|
|
|
var toConsumableArray_default = /*#__PURE__*/__webpack_require__.n(toConsumableArray);
|
|
|
// EXTERNAL MODULE: ./node_modules/_@babel_runtime@7.23.2@@babel/runtime/helpers/asyncToGenerator.js
|
|
|
var asyncToGenerator = __webpack_require__(39343);
|
|
|
var asyncToGenerator_default = /*#__PURE__*/__webpack_require__.n(asyncToGenerator);
|
|
|
// EXTERNAL MODULE: ./node_modules/_@babel_runtime@7.23.2@@babel/runtime/helpers/slicedToArray.js
|
|
|
var slicedToArray = __webpack_require__(11006);
|
|
|
var slicedToArray_default = /*#__PURE__*/__webpack_require__.n(slicedToArray);
|
|
|
// EXTERNAL MODULE: ./node_modules/_react@17.0.2@react/index.js
|
|
|
var _react_17_0_2_react = __webpack_require__(59301);
|
|
|
// EXTERNAL MODULE: ./src/utils/env.ts + 1 modules
|
|
|
var env = __webpack_require__(47015);
|
|
|
// EXTERNAL MODULE: ./src/utils/fetch.ts
|
|
|
var fetch = __webpack_require__(97174);
|
|
|
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/upload/index.js + 24 modules
|
|
|
var upload = __webpack_require__(6557);
|
|
|
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/form/index.js + 19 modules
|
|
|
var es_form = __webpack_require__(78241);
|
|
|
// 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/input/index.js + 5 modules
|
|
|
var input = __webpack_require__(1056);
|
|
|
;// CONCATENATED MODULE: ./src/pages/Shixuns/Edit/body/Dataset/components/UploadFile/index.less?modules
|
|
|
// extracted by mini-css-extract-plugin
|
|
|
/* harmony default export */ var UploadFilemodules = ({"wrap":"wrap___EmsVa","colorBlue":"colorBlue___XqtfP","repeatedName":"repeatedName___yMQsm"});
|
|
|
// EXTERNAL MODULE: ./src/components/UploadFile/index.tsx
|
|
|
var components_UploadFile = __webpack_require__(49581);
|
|
|
// EXTERNAL MODULE: ./src/utils/util.tsx
|
|
|
var util = __webpack_require__(27291);
|
|
|
// EXTERNAL MODULE: ./node_modules/_react@17.0.2@react/jsx-runtime.js
|
|
|
var jsx_runtime = __webpack_require__(37712);
|
|
|
;// CONCATENATED MODULE: ./src/pages/Shixuns/Edit/body/Dataset/components/UploadFile/index.tsx
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var Dragger = upload/* default */.Z.Dragger;
|
|
|
var UploadFile = function UploadFile(_ref) {
|
|
|
var _formValue$commitMess;
|
|
|
var dispatch = _ref.dispatch,
|
|
|
id = _ref.id,
|
|
|
onClose = _ref.onClose,
|
|
|
onOK = _ref.onOK,
|
|
|
visible = _ref.visible,
|
|
|
wrapClassName = _ref.wrapClassName,
|
|
|
local = _ref.local,
|
|
|
containerId = _ref.containerId,
|
|
|
rootIdentifier = _ref.rootIdentifier;
|
|
|
var _useState = (0,_react_17_0_2_react.useState)({}),
|
|
|
_useState2 = slicedToArray_default()(_useState, 2),
|
|
|
formValue = _useState2[0],
|
|
|
setFormValue = _useState2[1];
|
|
|
var _useState3 = (0,_react_17_0_2_react.useState)([]),
|
|
|
_useState4 = slicedToArray_default()(_useState3, 2),
|
|
|
repeatedName = _useState4[0],
|
|
|
setRepeatedName = _useState4[1];
|
|
|
var _useState5 = (0,_react_17_0_2_react.useState)([]),
|
|
|
_useState6 = slicedToArray_default()(_useState5, 2),
|
|
|
xhrItems = _useState6[0],
|
|
|
setXhrItems = _useState6[1];
|
|
|
var _useState7 = (0,_react_17_0_2_react.useState)(0),
|
|
|
_useState8 = slicedToArray_default()(_useState7, 2),
|
|
|
disabled = _useState8[0],
|
|
|
setDisabled = _useState8[1];
|
|
|
var _useState9 = (0,_react_17_0_2_react.useState)(false),
|
|
|
_useState10 = slicedToArray_default()(_useState9, 2),
|
|
|
cancelUpload = _useState10[0],
|
|
|
setCancelUpload = _useState10[1];
|
|
|
var _useState11 = (0,_react_17_0_2_react.useState)(false),
|
|
|
_useState12 = slicedToArray_default()(_useState11, 2),
|
|
|
btnLoading = _useState12[0],
|
|
|
setBtnLoading = _useState12[1];
|
|
|
var _Form$useForm = es_form/* default */.Z.useForm(),
|
|
|
_Form$useForm2 = slicedToArray_default()(_Form$useForm, 1),
|
|
|
form = _Form$useForm2[0];
|
|
|
var _useState13 = (0,_react_17_0_2_react.useState)([]),
|
|
|
_useState14 = slicedToArray_default()(_useState13, 2),
|
|
|
fileList = _useState14[0],
|
|
|
setFileList = _useState14[1];
|
|
|
var savedFileList = (0,_react_17_0_2_react.useRef)([]);
|
|
|
(0,_react_17_0_2_react.useEffect)(function () {
|
|
|
if (visible) {
|
|
|
form.resetFields();
|
|
|
setFileList([]);
|
|
|
setXhrItems([]);
|
|
|
setRepeatedName([]);
|
|
|
setDisabled(0);
|
|
|
setBtnLoading(false);
|
|
|
setCancelUpload(false);
|
|
|
}
|
|
|
}, [visible]);
|
|
|
var handleChangeFile = function handleChangeFile(info) {
|
|
|
if (info.file.status === 'done' || info.file.status === "uploading") {
|
|
|
var _info$file$response, _info$file$response2, _info$file$response3;
|
|
|
setFileList(info.fileList);
|
|
|
if (!info.file.response) {
|
|
|
return;
|
|
|
}
|
|
|
if ((_info$file$response = info.file.response) !== null && _info$file$response !== void 0 && _info$file$response.id) {
|
|
|
message/* default */.ZP.success("上传成功!");
|
|
|
return;
|
|
|
}
|
|
|
setFileList(fileList.filter(function (item) {
|
|
|
return item.uid !== info.file.uid;
|
|
|
}));
|
|
|
((_info$file$response2 = info.file.response) === null || _info$file$response2 === void 0 ? void 0 : _info$file$response2.message) && message/* default */.ZP.info((_info$file$response3 = info.file.response) === null || _info$file$response3 === void 0 ? void 0 : _info$file$response3.message);
|
|
|
}
|
|
|
};
|
|
|
var handleRemoveFile = /*#__PURE__*/function () {
|
|
|
var _ref2 = asyncToGenerator_default()( /*#__PURE__*/regeneratorRuntime_default()().mark(function _callee(info) {
|
|
|
var _info$response;
|
|
|
var newFileList, res;
|
|
|
return regeneratorRuntime_default()().wrap(function _callee$(_context) {
|
|
|
while (1) switch (_context.prev = _context.next) {
|
|
|
case 0:
|
|
|
if (disabled) {
|
|
|
_context.next = 8;
|
|
|
break;
|
|
|
}
|
|
|
newFileList = fileList.filter(function (item) {
|
|
|
return item.uid !== info.uid;
|
|
|
});
|
|
|
setFileList(newFileList);
|
|
|
savedFileList.current = toConsumableArray_default()(newFileList);
|
|
|
setRepeatedName(repeatedName.filter(function (item) {
|
|
|
return item !== info.name;
|
|
|
}));
|
|
|
message/* default */.ZP.info("删除成功");
|
|
|
if (!newFileList.length) {
|
|
|
form.setFieldsValue({
|
|
|
file: undefined
|
|
|
});
|
|
|
form.validateFields();
|
|
|
}
|
|
|
return _context.abrupt("return");
|
|
|
case 8:
|
|
|
if (info.response) {
|
|
|
_context.next = 11;
|
|
|
break;
|
|
|
}
|
|
|
message/* default */.ZP.info("还未上传完成,无法进行删除操作!");
|
|
|
return _context.abrupt("return");
|
|
|
case 11:
|
|
|
_context.next = 13;
|
|
|
return (0,fetch/* default */.ZP)("/api/shixuns/".concat(id, "/destroy_data_sets.json"), {
|
|
|
method: 'Delete',
|
|
|
body: {
|
|
|
id: [info === null || info === void 0 || (_info$response = info.response) === null || _info$response === void 0 ? void 0 : _info$response.id]
|
|
|
}
|
|
|
});
|
|
|
case 13:
|
|
|
res = _context.sent;
|
|
|
if (res.status === 0) {
|
|
|
setFileList(fileList.filter(function (item) {
|
|
|
return item.uid !== info.uid;
|
|
|
}));
|
|
|
message/* default */.ZP.info("删除成功");
|
|
|
}
|
|
|
case 15:
|
|
|
case "end":
|
|
|
return _context.stop();
|
|
|
}
|
|
|
}, _callee);
|
|
|
}));
|
|
|
return function handleRemoveFile(_x) {
|
|
|
return _ref2.apply(this, arguments);
|
|
|
};
|
|
|
}();
|
|
|
var handleBeforeUpload = function handleBeforeUpload(info) {
|
|
|
if (fileList !== null && fileList !== void 0 && fileList.some(function (e) {
|
|
|
return e.name === info.name;
|
|
|
})) {
|
|
|
message/* default */.ZP.info("".concat(info.name, "\u6587\u4EF6\u5DF2\u5B58\u5728"));
|
|
|
return false;
|
|
|
}
|
|
|
if (info.size / 1024 / 1024 > 500) {
|
|
|
message/* default */.ZP.info("文件超过500M,不符合上传要求");
|
|
|
return false;
|
|
|
}
|
|
|
var param = {
|
|
|
name: info.name,
|
|
|
uid: info.uid,
|
|
|
file: info,
|
|
|
percent: 0
|
|
|
};
|
|
|
fileList.push(param);
|
|
|
savedFileList.current = toConsumableArray_default()(fileList);
|
|
|
setFileList(toConsumableArray_default()(fileList));
|
|
|
return false;
|
|
|
};
|
|
|
var draggerProps = {
|
|
|
height: 300,
|
|
|
multiple: true,
|
|
|
disabled: disabled > 0,
|
|
|
withCredentials: true,
|
|
|
fileList: fileList,
|
|
|
action: "".concat(env/* default */.Z.API_SERVER, "/api/attachments.json"),
|
|
|
onChange: handleChangeFile,
|
|
|
onRemove: handleRemoveFile,
|
|
|
beforeUpload: handleBeforeUpload
|
|
|
};
|
|
|
var uploadRequest = function uploadRequest(params, url, callback, progressFunction, error) {
|
|
|
var formData = new FormData();
|
|
|
Object.keys(params).forEach(function (key) {
|
|
|
formData.append(key, params[key]);
|
|
|
});
|
|
|
var xhr = new window.XMLHttpRequest();
|
|
|
xhr.withCredentials = true;
|
|
|
xhr.addEventListener('load', function (res) {
|
|
|
var _res$target;
|
|
|
callback(JSON.parse(res === null || res === void 0 || (_res$target = res.target) === null || _res$target === void 0 ? void 0 : _res$target.response));
|
|
|
}, false);
|
|
|
xhr.addEventListener('error', function (err) {
|
|
|
if (error) {
|
|
|
error(err);
|
|
|
}
|
|
|
}, false);
|
|
|
xhr.upload.onprogress = function (e) {
|
|
|
if (progressFunction) {
|
|
|
progressFunction(e);
|
|
|
}
|
|
|
};
|
|
|
// xhr.ontimeout = function () {
|
|
|
// error('超时');
|
|
|
// },
|
|
|
// xhr.timeout = 10 * 1000
|
|
|
xhr.open('POST', url);
|
|
|
xhr.send(formData);
|
|
|
return xhr;
|
|
|
};
|
|
|
var getProgress = function getProgress(event, item) {
|
|
|
if (event.lengthComputable) {
|
|
|
var percent = Math.floor(event.loaded / event.total * 100);
|
|
|
var param = objectSpread2_default()(objectSpread2_default()({}, item), {}, {
|
|
|
percent: percent,
|
|
|
status: percent === 100 ? 'done' : 'uploading'
|
|
|
});
|
|
|
console.log(savedFileList.current, 333);
|
|
|
// ;
|
|
|
savedFileList.current = savedFileList.current.map(function (e) {
|
|
|
return e.uid === item.uid ? param : e;
|
|
|
});
|
|
|
setFileList(savedFileList.current);
|
|
|
}
|
|
|
};
|
|
|
var error = function error(res, item) {
|
|
|
var param = objectSpread2_default()(objectSpread2_default()({}, item), {}, {
|
|
|
status: 'error'
|
|
|
});
|
|
|
message/* default */.ZP.warning("上传失败,请重新尝试");
|
|
|
savedFileList.current = savedFileList.current.map(function (e) {
|
|
|
return e.uid === item.uid ? param : e;
|
|
|
});
|
|
|
if (savedFileList.current.every(function (e) {
|
|
|
return e.status === 'done' || e.status === 'error';
|
|
|
})) {
|
|
|
setBtnLoading(false);
|
|
|
setDisabled(2);
|
|
|
}
|
|
|
setFileList(savedFileList.current);
|
|
|
};
|
|
|
var callback = function callback(res, item) {
|
|
|
var param = objectSpread2_default()(objectSpread2_default()({}, item), {}, {
|
|
|
status: 'done'
|
|
|
});
|
|
|
if (res.status === 0) {
|
|
|
// message.success('上传成功!')
|
|
|
} else {
|
|
|
param = objectSpread2_default()(objectSpread2_default()({}, item), {}, {
|
|
|
status: 'error'
|
|
|
});
|
|
|
message/* default */.ZP.error('上传失败!');
|
|
|
}
|
|
|
savedFileList.current = savedFileList.current.map(function (e) {
|
|
|
return e.uid === item.uid ? param : e;
|
|
|
});
|
|
|
if (savedFileList.current.every(function (e) {
|
|
|
return e.status === 'done';
|
|
|
})) {
|
|
|
message/* default */.ZP.success('上传完成!');
|
|
|
cancelEnd(true);
|
|
|
return;
|
|
|
}
|
|
|
if (savedFileList.current.every(function (e) {
|
|
|
return e.status === 'done' || e.status === 'error';
|
|
|
})) {
|
|
|
setBtnLoading(false);
|
|
|
setDisabled(2);
|
|
|
}
|
|
|
setFileList(savedFileList.current);
|
|
|
};
|
|
|
var isOnLine = function isOnLine() {
|
|
|
var netStatus = true;
|
|
|
if (window.navigator.onLine == true) {
|
|
|
netStatus = true; //网络链接正常
|
|
|
} else {
|
|
|
netStatus = false; //网络连接失败
|
|
|
}
|
|
|
;
|
|
|
return netStatus;
|
|
|
};
|
|
|
var handleFinish = /*#__PURE__*/function () {
|
|
|
var _ref3 = asyncToGenerator_default()( /*#__PURE__*/regeneratorRuntime_default()().mark(function _callee2(values) {
|
|
|
var _ref4, _ref4$commitMessage, commitMessage, _ref4$fileOss, fileOss, filesItems, names, res;
|
|
|
return regeneratorRuntime_default()().wrap(function _callee2$(_context2) {
|
|
|
while (1) switch (_context2.prev = _context2.next) {
|
|
|
case 0:
|
|
|
setBtnLoading(true);
|
|
|
if (!(disabled === 3)) {
|
|
|
_context2.next = 4;
|
|
|
break;
|
|
|
}
|
|
|
setDisabled(2);
|
|
|
return _context2.abrupt("return");
|
|
|
case 4:
|
|
|
if (!(disabled === 2 || disabled === 1)) {
|
|
|
_context2.next = 7;
|
|
|
break;
|
|
|
}
|
|
|
onUploadAgain();
|
|
|
return _context2.abrupt("return");
|
|
|
case 7:
|
|
|
_ref4 = values || {}, _ref4$commitMessage = _ref4.commitMessage, commitMessage = _ref4$commitMessage === void 0 ? '' : _ref4$commitMessage, _ref4$fileOss = _ref4.fileOss, fileOss = _ref4$fileOss === void 0 ? [] : _ref4$fileOss;
|
|
|
filesItems = local ? fileList : fileOss;
|
|
|
names = filesItems.map(function (e) {
|
|
|
return e.name;
|
|
|
});
|
|
|
if (!(names.filter(function (item) {
|
|
|
return item.indexOf('、') != -1 || item.indexOf(' ') != -1;
|
|
|
}).length > 0)) {
|
|
|
_context2.next = 14;
|
|
|
break;
|
|
|
}
|
|
|
message/* default */.ZP.info('数据集名称禁止有空格与、');
|
|
|
setBtnLoading(false);
|
|
|
return _context2.abrupt("return");
|
|
|
case 14:
|
|
|
_context2.next = 16;
|
|
|
return (0,fetch/* default */.ZP)("/api/shixuns/".concat(id, "/check_data_sets"), {
|
|
|
method: 'post',
|
|
|
body: {
|
|
|
files_name: names
|
|
|
}
|
|
|
});
|
|
|
case 16:
|
|
|
res = _context2.sent;
|
|
|
if (!(res.status === -3)) {
|
|
|
_context2.next = 21;
|
|
|
break;
|
|
|
}
|
|
|
setRepeatedName(res === null || res === void 0 ? void 0 : res.exist_files);
|
|
|
setBtnLoading(false);
|
|
|
return _context2.abrupt("return");
|
|
|
case 21:
|
|
|
if (!(JSON.stringify(res) === '{}')) {
|
|
|
_context2.next = 25;
|
|
|
break;
|
|
|
}
|
|
|
// savedFileList.current = savedFileList.current.map((e: any) => ({...e, status: 'error'}))
|
|
|
// setBtnLoading(false);
|
|
|
// setDisabled(2)
|
|
|
// setFileList(savedFileList.current)
|
|
|
setBtnLoading(false);
|
|
|
message/* default */.ZP.error('网络已断开,请稍后重试!');
|
|
|
return _context2.abrupt("return");
|
|
|
case 25:
|
|
|
if (res.status === 0) {
|
|
|
fileList.forEach(function (item) {
|
|
|
var xhr = uploadRequest({
|
|
|
file: item.file,
|
|
|
description: commitMessage
|
|
|
}, "".concat(env/* default */.Z.API_SERVER, "/api/shixuns/").concat(id, "/upload_data_sets.json"), function (e) {
|
|
|
return callback(e, item);
|
|
|
}, function (e) {
|
|
|
return getProgress(e, item);
|
|
|
}, function (e) {
|
|
|
return error(e, item);
|
|
|
});
|
|
|
xhrItems.push(xhr);
|
|
|
});
|
|
|
setDisabled(1);
|
|
|
}
|
|
|
case 26:
|
|
|
case "end":
|
|
|
return _context2.stop();
|
|
|
}
|
|
|
}, _callee2);
|
|
|
}));
|
|
|
return function handleFinish(_x2) {
|
|
|
return _ref3.apply(this, arguments);
|
|
|
};
|
|
|
}();
|
|
|
var onUploadAgain = function onUploadAgain() {
|
|
|
var _ref5 = objectSpread2_default()({}, form.getFieldsValue()) || {},
|
|
|
_ref5$commitMessage = _ref5.commitMessage,
|
|
|
commitMessage = _ref5$commitMessage === void 0 ? '' : _ref5$commitMessage;
|
|
|
var errorFileList = savedFileList.current.filter(function (item) {
|
|
|
return item.status === 'error';
|
|
|
});
|
|
|
var t = savedFileList.current.map(function (e) {
|
|
|
return objectSpread2_default()(objectSpread2_default()({}, e), {}, {
|
|
|
status: e.status === 'error' ? 'uploading' : e.status
|
|
|
});
|
|
|
});
|
|
|
setFileList(t);
|
|
|
errorFileList.forEach(function (item) {
|
|
|
var xhr = uploadRequest({
|
|
|
file: item.file,
|
|
|
description: commitMessage
|
|
|
}, "".concat(env/* default */.Z.API_SERVER, "/api/shixuns/").concat(id, "/upload_data_sets.json"), function (e) {
|
|
|
return callback(e, item);
|
|
|
}, function (e) {
|
|
|
return getProgress(e, item);
|
|
|
}, function (e) {
|
|
|
return error(e, item);
|
|
|
});
|
|
|
xhrItems.push(xhr);
|
|
|
});
|
|
|
};
|
|
|
var handleValuesChange = function handleValuesChange(changedValues) {
|
|
|
console.log(changedValues, 'changedValues');
|
|
|
if ('fileOss' in changedValues) {
|
|
|
var _changedValues$fileOs, _changedValues$fileOs2;
|
|
|
if (changedValues !== null && changedValues !== void 0 && changedValues.fileOss.every(function (e) {
|
|
|
return e.status === 'done';
|
|
|
}) && changedValues !== null && changedValues !== void 0 && (_changedValues$fileOs = changedValues.fileOss) !== null && _changedValues$fileOs !== void 0 && _changedValues$fileOs.length) {
|
|
|
message/* default */.ZP.success('上传完成!');
|
|
|
cancelEnd(true);
|
|
|
return;
|
|
|
}
|
|
|
if (changedValues !== null && changedValues !== void 0 && changedValues.fileOss.every(function (e) {
|
|
|
return e.status === 'done' || e.status === 'error';
|
|
|
}) && changedValues !== null && changedValues !== void 0 && (_changedValues$fileOs2 = changedValues.fileOss) !== null && _changedValues$fileOs2 !== void 0 && _changedValues$fileOs2.length) {
|
|
|
setDisabled(3);
|
|
|
setBtnLoading(false);
|
|
|
return;
|
|
|
}
|
|
|
setRepeatedName(repeatedName.filter(function (item) {
|
|
|
var _changedValues$fileOs3;
|
|
|
return changedValues === null || changedValues === void 0 || (_changedValues$fileOs3 = changedValues.fileOss) === null || _changedValues$fileOs3 === void 0 ? void 0 : _changedValues$fileOs3.some(function (e) {
|
|
|
return e.name === item;
|
|
|
});
|
|
|
}));
|
|
|
}
|
|
|
setFormValue(objectSpread2_default()({}, form.getFieldsValue()));
|
|
|
};
|
|
|
var cancelEnd = function cancelEnd(bool) {
|
|
|
if (!bool) {
|
|
|
setCancelUpload(true);
|
|
|
xhrItems.forEach(function (e) {
|
|
|
e.abort();
|
|
|
});
|
|
|
}
|
|
|
onOK();
|
|
|
onClose();
|
|
|
};
|
|
|
var handleCancel = function handleCancel() {
|
|
|
var _ref6 = objectSpread2_default()({}, form.getFieldsValue()) || {},
|
|
|
_ref6$fileOss = _ref6.fileOss,
|
|
|
fileOss = _ref6$fileOss === void 0 ? [] : _ref6$fileOss;
|
|
|
var fileListItems = fileList === null || fileList === void 0 ? void 0 : fileList.every(function (e) {
|
|
|
return e.status === 'done';
|
|
|
});
|
|
|
var ossItems = fileOss === null || fileOss === void 0 ? void 0 : fileOss.every(function (e) {
|
|
|
return e.status === 'done';
|
|
|
});
|
|
|
if (!fileListItems || !ossItems) {
|
|
|
modal/* default */.Z.confirm({
|
|
|
title: "关闭弹框提示",
|
|
|
content: "有文件未上传,是否确定离开?",
|
|
|
okText: "离开",
|
|
|
cancelText: "取消",
|
|
|
onOk: function onOk() {
|
|
|
cancelEnd();
|
|
|
}
|
|
|
});
|
|
|
return;
|
|
|
}
|
|
|
cancelEnd();
|
|
|
};
|
|
|
var returnDom = function returnDom() {
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsxs)(_react_17_0_2_react.Fragment, {
|
|
|
children: [/*#__PURE__*/(0,jsx_runtime.jsx)("div", {
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)("i", {
|
|
|
className: "iconfont icon-shangchuan font50 ".concat(UploadFilemodules.colorBlue)
|
|
|
})
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsxs)("div", {
|
|
|
className: "font14 mt30",
|
|
|
children: ["\u62D6\u62FD\u6587\u4EF6\u6216", /*#__PURE__*/(0,jsx_runtime.jsx)("span", {
|
|
|
className: "".concat(UploadFilemodules.colorBlue, " ml5"),
|
|
|
children: "\u70B9\u51FB\u6B64\u5904\u4E0A\u4F20"
|
|
|
})]
|
|
|
})]
|
|
|
});
|
|
|
};
|
|
|
var handleComplete = function handleComplete(item) {
|
|
|
console.log(item, 444);
|
|
|
};
|
|
|
|
|
|
// console.log(fileList, 4444)
|
|
|
|
|
|
return /*#__PURE__*/(0,jsx_runtime.jsx)(modal/* default */.Z, {
|
|
|
open: visible
|
|
|
// wrapClassName={wrapClassName}
|
|
|
,
|
|
|
onOk: function onOk() {
|
|
|
(0,util/* trackEvent */.L9)(['实践项目', '设置', '数据集', '上传文件']);
|
|
|
form.submit();
|
|
|
},
|
|
|
centered: true,
|
|
|
okText: disabled === 0 ? '确定' : disabled === 1 ? '上传中' : '重新上传',
|
|
|
okButtonProps: {
|
|
|
loading: btnLoading
|
|
|
},
|
|
|
onCancel: handleCancel,
|
|
|
width: "1000px",
|
|
|
title: "\u4E0A\u4F20\u6587\u4EF6",
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)("div", {
|
|
|
className: UploadFilemodules.wrap,
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsxs)(es_form/* default */.Z, {
|
|
|
className: "mt10",
|
|
|
form: form,
|
|
|
scrollToFirstError: true,
|
|
|
layout: "vertical",
|
|
|
onFinish: handleFinish,
|
|
|
onValuesChange: handleValuesChange,
|
|
|
children: [local ? /*#__PURE__*/(0,jsx_runtime.jsx)(es_form/* default */.Z.Item, {
|
|
|
label: /*#__PURE__*/(0,jsx_runtime.jsxs)("div", {
|
|
|
children: ["\u9009\u62E9\u6587\u4EF6 ", /*#__PURE__*/(0,jsx_runtime.jsx)("span", {
|
|
|
className: "c-light-black",
|
|
|
children: "(\u5355\u4E2A\u6587\u4EF6\u4E0D\u8D85\u8FC7500M)"
|
|
|
})]
|
|
|
}),
|
|
|
name: "file",
|
|
|
rules: [{
|
|
|
required: true,
|
|
|
message: '请选择文件'
|
|
|
}],
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsxs)(Dragger, objectSpread2_default()(objectSpread2_default()({}, draggerProps), {}, {
|
|
|
children: [" ", returnDom()]
|
|
|
}))
|
|
|
}) : /*#__PURE__*/(0,jsx_runtime.jsx)(es_form/* default */.Z.Item, {
|
|
|
label: /*#__PURE__*/(0,jsx_runtime.jsxs)("div", {
|
|
|
children: ["\u9009\u62E9\u6587\u4EF6 ", /*#__PURE__*/(0,jsx_runtime.jsx)("span", {
|
|
|
className: "c-light-black",
|
|
|
children: "(\u5355\u4E2A\u6587\u4EF6\u4E0D\u8D85\u8FC7100GB)"
|
|
|
})]
|
|
|
}),
|
|
|
name: "fileOss",
|
|
|
rules: [{
|
|
|
required: true,
|
|
|
message: '请选择文件'
|
|
|
}],
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)(components_UploadFile/* default */.ZP, {
|
|
|
identifier: rootIdentifier,
|
|
|
cancelUpload: cancelUpload,
|
|
|
container_type: "Shixun",
|
|
|
container_id: containerId,
|
|
|
uploading: disabled < 3 ? disabled : 0,
|
|
|
disabled: disabled > 0,
|
|
|
height: 300,
|
|
|
maxSize: 100 * 1024 * 1024 * 1024 //字节
|
|
|
,
|
|
|
description: formValue.commitMessage || "",
|
|
|
text: returnDom(),
|
|
|
onComplete: handleComplete,
|
|
|
realFileName: true
|
|
|
})
|
|
|
}), !!repeatedName.length && /*#__PURE__*/(0,jsx_runtime.jsxs)("span", {
|
|
|
className: UploadFilemodules.repeatedName,
|
|
|
children: [repeatedName.join('、'), "\u5DF2\u5B58\u5728,\u8BF7\u5220\u9664\u540E\u518D\u4E0A\u4F20"]
|
|
|
}), /*#__PURE__*/(0,jsx_runtime.jsx)(es_form/* default */.Z.Item, {
|
|
|
name: "commitMessage",
|
|
|
label: "\u5907\u6CE8:",
|
|
|
rules: [{
|
|
|
whitespace: true,
|
|
|
message: '请勿输入空格'
|
|
|
}],
|
|
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)(input/* default */.Z, {
|
|
|
bordered: false,
|
|
|
disabled: disabled > 0,
|
|
|
maxLength: 100,
|
|
|
suffix: "".concat(((_formValue$commitMess = formValue.commitMessage) === null || _formValue$commitMess === void 0 ? void 0 : _formValue$commitMess.length) || 0, "/100"),
|
|
|
placeholder: "\u8BF7\u586B\u5199\u5907\u6CE8\u4FE1\u606F"
|
|
|
})
|
|
|
})]
|
|
|
})
|
|
|
})
|
|
|
});
|
|
|
};
|
|
|
/* harmony default export */ var Dataset_components_UploadFile = (UploadFile);
|
|
|
|
|
|
/***/ }),
|
|
|
|
|
|
/***/ 25769:
|
|
|
/*!**************************************************************************!*\
|
|
|
!*** ./node_modules/_copy-to-clipboard@3.3.3@copy-to-clipboard/index.js ***!
|
|
|
\**************************************************************************/
|
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
|
|
"use strict";
|
|
|
|
|
|
|
|
|
var deselectCurrent = __webpack_require__(/*! toggle-selection */ 98040);
|
|
|
|
|
|
var clipboardToIE11Formatting = {
|
|
|
"text/plain": "Text",
|
|
|
"text/html": "Url",
|
|
|
"default": "Text"
|
|
|
}
|
|
|
|
|
|
var defaultMessage = "Copy to clipboard: #{key}, Enter";
|
|
|
|
|
|
function format(message) {
|
|
|
var copyKey = (/mac os x/i.test(navigator.userAgent) ? "⌘" : "Ctrl") + "+C";
|
|
|
return message.replace(/#{\s*key\s*}/g, copyKey);
|
|
|
}
|
|
|
|
|
|
function copy(text, options) {
|
|
|
var debug,
|
|
|
message,
|
|
|
reselectPrevious,
|
|
|
range,
|
|
|
selection,
|
|
|
mark,
|
|
|
success = false;
|
|
|
if (!options) {
|
|
|
options = {};
|
|
|
}
|
|
|
debug = options.debug || false;
|
|
|
try {
|
|
|
reselectPrevious = deselectCurrent();
|
|
|
|
|
|
range = document.createRange();
|
|
|
selection = document.getSelection();
|
|
|
|
|
|
mark = document.createElement("span");
|
|
|
mark.textContent = text;
|
|
|
// avoid screen readers from reading out loud the text
|
|
|
mark.ariaHidden = "true"
|
|
|
// reset user styles for span element
|
|
|
mark.style.all = "unset";
|
|
|
// prevents scrolling to the end of the page
|
|
|
mark.style.position = "fixed";
|
|
|
mark.style.top = 0;
|
|
|
mark.style.clip = "rect(0, 0, 0, 0)";
|
|
|
// used to preserve spaces and line breaks
|
|
|
mark.style.whiteSpace = "pre";
|
|
|
// do not inherit user-select (it may be `none`)
|
|
|
mark.style.webkitUserSelect = "text";
|
|
|
mark.style.MozUserSelect = "text";
|
|
|
mark.style.msUserSelect = "text";
|
|
|
mark.style.userSelect = "text";
|
|
|
mark.addEventListener("copy", function(e) {
|
|
|
e.stopPropagation();
|
|
|
if (options.format) {
|
|
|
e.preventDefault();
|
|
|
if (typeof e.clipboardData === "undefined") { // IE 11
|
|
|
debug && console.warn("unable to use e.clipboardData");
|
|
|
debug && console.warn("trying IE specific stuff");
|
|
|
window.clipboardData.clearData();
|
|
|
var format = clipboardToIE11Formatting[options.format] || clipboardToIE11Formatting["default"]
|
|
|
window.clipboardData.setData(format, text);
|
|
|
} else { // all other browsers
|
|
|
e.clipboardData.clearData();
|
|
|
e.clipboardData.setData(options.format, text);
|
|
|
}
|
|
|
}
|
|
|
if (options.onCopy) {
|
|
|
e.preventDefault();
|
|
|
options.onCopy(e.clipboardData);
|
|
|
}
|
|
|
});
|
|
|
|
|
|
document.body.appendChild(mark);
|
|
|
|
|
|
range.selectNodeContents(mark);
|
|
|
selection.addRange(range);
|
|
|
|
|
|
var successful = document.execCommand("copy");
|
|
|
if (!successful) {
|
|
|
throw new Error("copy command was unsuccessful");
|
|
|
}
|
|
|
success = true;
|
|
|
} catch (err) {
|
|
|
debug && console.error("unable to copy using execCommand: ", err);
|
|
|
debug && console.warn("trying IE specific stuff");
|
|
|
try {
|
|
|
window.clipboardData.setData(options.format || "text", text);
|
|
|
options.onCopy && options.onCopy(window.clipboardData);
|
|
|
success = true;
|
|
|
} catch (err) {
|
|
|
debug && console.error("unable to copy using clipboardData: ", err);
|
|
|
debug && console.error("falling back to prompt");
|
|
|
message = format("message" in options ? options.message : defaultMessage);
|
|
|
window.prompt(message, text);
|
|
|
}
|
|
|
} finally {
|
|
|
if (selection) {
|
|
|
if (typeof selection.removeRange == "function") {
|
|
|
selection.removeRange(range);
|
|
|
} else {
|
|
|
selection.removeAllRanges();
|
|
|
}
|
|
|
}
|
|
|
|
|
|
if (mark) {
|
|
|
document.body.removeChild(mark);
|
|
|
}
|
|
|
reselectPrevious();
|
|
|
}
|
|
|
|
|
|
return success;
|
|
|
}
|
|
|
|
|
|
module.exports = copy;
|
|
|
|
|
|
|
|
|
/***/ }),
|
|
|
|
|
|
/***/ 83145:
|
|
|
/*!**********************************************************************************************!*\
|
|
|
!*** ./node_modules/_react-copy-to-clipboard@5.0.2@react-copy-to-clipboard/lib/Component.js ***!
|
|
|
\**********************************************************************************************/
|
|
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
|
|
|
|
|
"use strict";
|
|
|
|
|
|
|
|
|
Object.defineProperty(exports, "__esModule", ({
|
|
|
value: true
|
|
|
}));
|
|
|
exports.CopyToClipboard = void 0;
|
|
|
|
|
|
var _react = _interopRequireDefault(__webpack_require__(/*! react */ 59301));
|
|
|
|
|
|
var _copyToClipboard = _interopRequireDefault(__webpack_require__(/*! copy-to-clipboard */ 25769));
|
|
|
|
|
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
|
|
|
|
function _typeof(obj) { if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
|
|
|
|
|
|
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }
|
|
|
|
|
|
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(source, true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(source).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
|
|
|
|
|
|
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
|
|
|
|
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
|
|
|
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
|
|
|
|
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
|
|
|
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
|
|
|
|
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
|
|
|
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
|
|
|
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
|
|
|
|
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
|
|
|
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
|
|
|
|
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
|
|
|
|
var CopyToClipboard =
|
|
|
/*#__PURE__*/
|
|
|
function (_React$PureComponent) {
|
|
|
_inherits(CopyToClipboard, _React$PureComponent);
|
|
|
|
|
|
function CopyToClipboard() {
|
|
|
var _getPrototypeOf2;
|
|
|
|
|
|
var _this;
|
|
|
|
|
|
_classCallCheck(this, CopyToClipboard);
|
|
|
|
|
|
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
|
args[_key] = arguments[_key];
|
|
|
}
|
|
|
|
|
|
_this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(CopyToClipboard)).call.apply(_getPrototypeOf2, [this].concat(args)));
|
|
|
|
|
|
_defineProperty(_assertThisInitialized(_this), "onClick", function (event) {
|
|
|
var _this$props = _this.props,
|
|
|
text = _this$props.text,
|
|
|
onCopy = _this$props.onCopy,
|
|
|
children = _this$props.children,
|
|
|
options = _this$props.options;
|
|
|
|
|
|
var elem = _react["default"].Children.only(children);
|
|
|
|
|
|
var result = (0, _copyToClipboard["default"])(text, options);
|
|
|
|
|
|
if (onCopy) {
|
|
|
onCopy(text, result);
|
|
|
} // Bypass onClick if it was present
|
|
|
|
|
|
|
|
|
if (elem && elem.props && typeof elem.props.onClick === 'function') {
|
|
|
elem.props.onClick(event);
|
|
|
}
|
|
|
});
|
|
|
|
|
|
return _this;
|
|
|
}
|
|
|
|
|
|
_createClass(CopyToClipboard, [{
|
|
|
key: "render",
|
|
|
value: function render() {
|
|
|
var _this$props2 = this.props,
|
|
|
_text = _this$props2.text,
|
|
|
_onCopy = _this$props2.onCopy,
|
|
|
_options = _this$props2.options,
|
|
|
children = _this$props2.children,
|
|
|
props = _objectWithoutProperties(_this$props2, ["text", "onCopy", "options", "children"]);
|
|
|
|
|
|
var elem = _react["default"].Children.only(children);
|
|
|
|
|
|
return _react["default"].cloneElement(elem, _objectSpread({}, props, {
|
|
|
onClick: this.onClick
|
|
|
}));
|
|
|
}
|
|
|
}]);
|
|
|
|
|
|
return CopyToClipboard;
|
|
|
}(_react["default"].PureComponent);
|
|
|
|
|
|
exports.CopyToClipboard = CopyToClipboard;
|
|
|
|
|
|
_defineProperty(CopyToClipboard, "defaultProps", {
|
|
|
onCopy: undefined,
|
|
|
options: undefined
|
|
|
});
|
|
|
|
|
|
/***/ }),
|
|
|
|
|
|
/***/ 56102:
|
|
|
/*!******************************************************************************************!*\
|
|
|
!*** ./node_modules/_react-copy-to-clipboard@5.0.2@react-copy-to-clipboard/lib/index.js ***!
|
|
|
\******************************************************************************************/
|
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
|
|
"use strict";
|
|
|
|
|
|
|
|
|
var _require = __webpack_require__(/*! ./Component */ 83145),
|
|
|
CopyToClipboard = _require.CopyToClipboard;
|
|
|
|
|
|
CopyToClipboard.CopyToClipboard = CopyToClipboard;
|
|
|
module.exports = CopyToClipboard;
|
|
|
|
|
|
/***/ }),
|
|
|
|
|
|
/***/ 98040:
|
|
|
/*!************************************************************************!*\
|
|
|
!*** ./node_modules/_toggle-selection@1.0.6@toggle-selection/index.js ***!
|
|
|
\************************************************************************/
|
|
|
/***/ (function(module) {
|
|
|
|
|
|
|
|
|
module.exports = function () {
|
|
|
var selection = document.getSelection();
|
|
|
if (!selection.rangeCount) {
|
|
|
return function () {};
|
|
|
}
|
|
|
var active = document.activeElement;
|
|
|
|
|
|
var ranges = [];
|
|
|
for (var i = 0; i < selection.rangeCount; i++) {
|
|
|
ranges.push(selection.getRangeAt(i));
|
|
|
}
|
|
|
|
|
|
switch (active.tagName.toUpperCase()) { // .toUpperCase handles XHTML
|
|
|
case 'INPUT':
|
|
|
case 'TEXTAREA':
|
|
|
active.blur();
|
|
|
break;
|
|
|
|
|
|
default:
|
|
|
active = null;
|
|
|
break;
|
|
|
}
|
|
|
|
|
|
selection.removeAllRanges();
|
|
|
return function () {
|
|
|
selection.type === 'Caret' &&
|
|
|
selection.removeAllRanges();
|
|
|
|
|
|
if (!selection.rangeCount) {
|
|
|
ranges.forEach(function(range) {
|
|
|
selection.addRange(range);
|
|
|
});
|
|
|
}
|
|
|
|
|
|
active &&
|
|
|
active.focus();
|
|
|
};
|
|
|
};
|
|
|
|
|
|
|
|
|
/***/ }),
|
|
|
|
|
|
/***/ 1012:
|
|
|
/*!**************************************************************************!*\
|
|
|
!*** ./node_modules/_uuid@8.3.0@uuid/dist/esm-browser/v4.js + 4 modules ***!
|
|
|
\**************************************************************************/
|
|
|
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
|
|
|
|
"use strict";
|
|
|
|
|
|
// EXPORTS
|
|
|
__webpack_require__.d(__webpack_exports__, {
|
|
|
Z: function() { return /* binding */ esm_browser_v4; }
|
|
|
});
|
|
|
|
|
|
;// CONCATENATED MODULE: ./node_modules/_uuid@8.3.0@uuid/dist/esm-browser/rng.js
|
|
|
// Unique ID creation requires a high quality random # generator. In the browser we therefore
|
|
|
// require the crypto API and do not support built-in fallback to lower quality random number
|
|
|
// generators (like Math.random()).
|
|
|
// getRandomValues needs to be invoked in a context where "this" is a Crypto implementation. Also,
|
|
|
// find the complete implementation of crypto (msCrypto) on IE11.
|
|
|
var getRandomValues = typeof crypto !== 'undefined' && crypto.getRandomValues && crypto.getRandomValues.bind(crypto) || typeof msCrypto !== 'undefined' && typeof msCrypto.getRandomValues === 'function' && msCrypto.getRandomValues.bind(msCrypto);
|
|
|
var rnds8 = new Uint8Array(16);
|
|
|
function rng() {
|
|
|
if (!getRandomValues) {
|
|
|
throw new Error('crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported');
|
|
|
}
|
|
|
|
|
|
return getRandomValues(rnds8);
|
|
|
}
|
|
|
;// CONCATENATED MODULE: ./node_modules/_uuid@8.3.0@uuid/dist/esm-browser/regex.js
|
|
|
/* harmony default export */ var regex = (/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i);
|
|
|
;// CONCATENATED MODULE: ./node_modules/_uuid@8.3.0@uuid/dist/esm-browser/validate.js
|
|
|
|
|
|
|
|
|
function validate(uuid) {
|
|
|
return typeof uuid === 'string' && regex.test(uuid);
|
|
|
}
|
|
|
|
|
|
/* harmony default export */ var esm_browser_validate = (validate);
|
|
|
;// CONCATENATED MODULE: ./node_modules/_uuid@8.3.0@uuid/dist/esm-browser/stringify.js
|
|
|
|
|
|
/**
|
|
|
* Convert array of 16 byte values to UUID string format of the form:
|
|
|
* XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX
|
|
|
*/
|
|
|
|
|
|
var byteToHex = [];
|
|
|
|
|
|
for (var i = 0; i < 256; ++i) {
|
|
|
byteToHex.push((i + 0x100).toString(16).substr(1));
|
|
|
}
|
|
|
|
|
|
function stringify(arr) {
|
|
|
var offset = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
|
|
|
// Note: Be careful editing this code! It's been tuned for performance
|
|
|
// and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434
|
|
|
var uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID. If this throws, it's likely due to one
|
|
|
// of the following:
|
|
|
// - One or more input array values don't map to a hex octet (leading to
|
|
|
// "undefined" in the uuid)
|
|
|
// - Invalid input values for the RFC `version` or `variant` fields
|
|
|
|
|
|
if (!esm_browser_validate(uuid)) {
|
|
|
throw TypeError('Stringified UUID is invalid');
|
|
|
}
|
|
|
|
|
|
return uuid;
|
|
|
}
|
|
|
|
|
|
/* harmony default export */ var esm_browser_stringify = (stringify);
|
|
|
;// CONCATENATED MODULE: ./node_modules/_uuid@8.3.0@uuid/dist/esm-browser/v4.js
|
|
|
|
|
|
|
|
|
|
|
|
function v4(options, buf, offset) {
|
|
|
options = options || {};
|
|
|
var rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved`
|
|
|
|
|
|
rnds[6] = rnds[6] & 0x0f | 0x40;
|
|
|
rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided
|
|
|
|
|
|
if (buf) {
|
|
|
offset = offset || 0;
|
|
|
|
|
|
for (var i = 0; i < 16; ++i) {
|
|
|
buf[offset + i] = rnds[i];
|
|
|
}
|
|
|
|
|
|
return buf;
|
|
|
}
|
|
|
|
|
|
return esm_browser_stringify(rnds);
|
|
|
}
|
|
|
|
|
|
/* harmony default export */ var esm_browser_v4 = (v4);
|
|
|
|
|
|
/***/ }),
|
|
|
|
|
|
/***/ 3828:
|
|
|
/*!************************!*\
|
|
|
!*** crypto (ignored) ***!
|
|
|
\************************/
|
|
|
/***/ (function() {
|
|
|
|
|
|
/* (ignored) */
|
|
|
|
|
|
/***/ })
|
|
|
|
|
|
}]); |