|
|
|
|
@ -28562,7 +28562,7 @@ var VideoDetailModel = {
|
|
|
|
|
put = _ref8.put,
|
|
|
|
|
select = _ref8.select;
|
|
|
|
|
return /*#__PURE__*/regeneratorRuntime_default()().mark(function _callee4() {
|
|
|
|
|
var response, responseSeq, _yield$select, queryParams, _response$stages, stages, video, Attachment, active;
|
|
|
|
|
var response, responseSeq, _yield$select, queryParams, _response$stages, stages, video, Attachment, active, processItems;
|
|
|
|
|
return regeneratorRuntime_default()().wrap(function _callee4$(_context4) {
|
|
|
|
|
while (1) switch (_context4.prev = _context4.next) {
|
|
|
|
|
case 0:
|
|
|
|
|
@ -28586,9 +28586,32 @@ var VideoDetailModel = {
|
|
|
|
|
_response$stages = response.stages, stages = _response$stages === void 0 ? [] : _response$stages;
|
|
|
|
|
video = []; // word/excel/ppt/pdf
|
|
|
|
|
Attachment = [];
|
|
|
|
|
active = {};
|
|
|
|
|
stages === null || stages === void 0 || stages.forEach(function (element) {
|
|
|
|
|
element.items.forEach(function (e) {
|
|
|
|
|
active = {}; // stages?.forEach((element: any) => {
|
|
|
|
|
// element.items.forEach((e: any) => {
|
|
|
|
|
// if (String(e.id) === String(queryParams.videoId)) {
|
|
|
|
|
// active = e;
|
|
|
|
|
// }
|
|
|
|
|
// if (e.item_type === 'VideoItem') {
|
|
|
|
|
// video.push(e);
|
|
|
|
|
// } else if (e.item_type === 'Attachment') {
|
|
|
|
|
// Attachment.push(e);
|
|
|
|
|
// }
|
|
|
|
|
// if (e.children && !!e.children.length) {
|
|
|
|
|
// e.children.forEach((el: any) => {
|
|
|
|
|
// if (String(el.id) === String(queryParams.videoId)) {
|
|
|
|
|
// active = el;
|
|
|
|
|
// }
|
|
|
|
|
// if (el.item_type === 'VideoItem') {
|
|
|
|
|
// video.push(el);
|
|
|
|
|
// } else if (el.item_type === 'Attachment') {
|
|
|
|
|
// Attachment.push(el);
|
|
|
|
|
// }
|
|
|
|
|
// });
|
|
|
|
|
// }
|
|
|
|
|
// });
|
|
|
|
|
// });
|
|
|
|
|
processItems = function processItems(items) {
|
|
|
|
|
items.forEach(function (e) {
|
|
|
|
|
if (String(e.id) === String(queryParams.videoId)) {
|
|
|
|
|
active = e;
|
|
|
|
|
}
|
|
|
|
|
@ -28597,22 +28620,16 @@ var VideoDetailModel = {
|
|
|
|
|
} else if (e.item_type === 'Attachment') {
|
|
|
|
|
Attachment.push(e);
|
|
|
|
|
}
|
|
|
|
|
if (e.children && !!e.children.length) {
|
|
|
|
|
e.children.forEach(function (el) {
|
|
|
|
|
if (String(el.id) === String(queryParams.videoId)) {
|
|
|
|
|
active = el;
|
|
|
|
|
}
|
|
|
|
|
if (el.item_type === 'VideoItem') {
|
|
|
|
|
video.push(el);
|
|
|
|
|
} else if (el.item_type === 'Attachment') {
|
|
|
|
|
Attachment.push(el);
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
if (e.children && e.children.length) {
|
|
|
|
|
processItems(e.children);
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
};
|
|
|
|
|
stages === null || stages === void 0 || stages.forEach(function (element) {
|
|
|
|
|
processItems(element.items);
|
|
|
|
|
});
|
|
|
|
|
window.filterVideoSign = [].concat(video); //全局标记使用,勿删
|
|
|
|
|
_context4.next = 18;
|
|
|
|
|
_context4.next = 19;
|
|
|
|
|
return put({
|
|
|
|
|
type: 'save',
|
|
|
|
|
payload: {
|
|
|
|
|
@ -28623,7 +28640,7 @@ var VideoDetailModel = {
|
|
|
|
|
attachmentList: Attachment
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
case 18:
|
|
|
|
|
case 19:
|
|
|
|
|
case "end":
|
|
|
|
|
return _context4.stop();
|
|
|
|
|
}
|