线上课tab切换

This commit is contained in:
禺狨
2023-04-24 11:11:18 +08:00
parent b897dfffac
commit 18f6056dc9
7 changed files with 12 additions and 25 deletions

View File

@@ -12,7 +12,6 @@ interface Option {
interface PropInterface {
type: string;
text: string;
refresh: boolean;
onUpdate: (keys: any, title: any) => void;
}
@@ -38,10 +37,6 @@ export const TreeCategory = (props: PropInterface) => {
});
}, []);
useEffect(() => {
setSelectKey([]);
}, [props.refresh]);
const checkArr = (categories: any[], id: number) => {
const arr = [];
for (let i = 0; i < categories[id].length; i++) {

View File

@@ -24,7 +24,6 @@ export const TreeDepartment = (props: PropInterface) => {
useEffect(() => {
setLoading(true);
setSelectKey([])
department.departmentList().then((res: any) => {
const departments = res.data.departments;
const departCount = res.data.dep_user_count;

View File

@@ -110,7 +110,6 @@ export const UploadImageButton = (props: PropsInterface) => {
<Row style={{ width: 752, minHeight: 520, marginTop: 24 }}>
<Col span={7}>
<TreeCategory
refresh={false}
type="no-cate"
text={"图片"}
onUpdate={(keys: any) => {

View File

@@ -173,7 +173,6 @@ export const UploadVideoSub = (props: PropsInterface) => {
<Row style={{ width: 752, minHeight: 520 }}>
<Col span={7}>
<TreeCategory
refresh={false}
type="no-cate"
text={props.label}
onUpdate={(keys: any) => setCategoryIds(keys)}