mirror of
https://github.com/PlayEdu/backend
synced 2025-12-23 05:23:18 +08:00
选择视频、课件组件重构
This commit is contained in:
@@ -1,16 +1,9 @@
|
||||
import { useEffect, useState } from "react";
|
||||
import { Button, Row, Modal, message, Tabs } from "antd";
|
||||
import { Row, Modal, Tabs } from "antd";
|
||||
import styles from "./index.module.less";
|
||||
import { UploadVideoSub } from "../../compenents";
|
||||
import type { TabsProps } from "antd";
|
||||
|
||||
interface VideoItem {
|
||||
id: number;
|
||||
category_id: number;
|
||||
name: string;
|
||||
duration: number;
|
||||
}
|
||||
|
||||
interface PropsInterface {
|
||||
defaultKeys: any[];
|
||||
open: boolean;
|
||||
@@ -24,6 +17,10 @@ export const SelectResource = (props: PropsInterface) => {
|
||||
const [selectKeys, setSelectKeys] = useState<any>([]);
|
||||
const [selectVideos, setSelectVideos] = useState<any>([]);
|
||||
|
||||
useEffect(() => {
|
||||
setRefresh(!refresh);
|
||||
}, [props.open]);
|
||||
|
||||
const items: TabsProps["items"] = [
|
||||
{
|
||||
key: "1",
|
||||
|
||||
Reference in New Issue
Block a user