fixed: 课程课件组价的缓存

This commit is contained in:
xxx 2023-08-03 09:07:44 +08:00
parent c0af8d165e
commit 354bd23fc9

View File

@ -152,70 +152,72 @@ export const CourseAttachmentUpdate: React.FC<PropInterface> = ({
return (
<>
<Drawer
title="课件管理"
onClose={onCancel}
maskClosable={false}
open={open}
width={634}
>
<div className={styles["top-content"]}>
<p>1.线</p>
</div>
<div className="float-left mt-24">
<SelectAttachment
defaultKeys={attachments}
open={attachmentVisible}
onCancel={() => {
setAttachmentVisible(false);
}}
onSelected={(arr: any, videos: any) => {
selectAttachmentData(arr, videos);
}}
></SelectAttachment>
<Form
form={form}
name="attachment-update-basic"
labelCol={{ span: 5 }}
wrapperCol={{ span: 19 }}
initialValues={{ remember: true }}
onFinish={onFinish}
onFinishFailed={onFinishFailed}
autoComplete="off"
>
<div className="c-flex">
<Form.Item>
<div className="ml-42">
<Button
onClick={() => setAttachmentVisible(true)}
type="primary"
>
</Button>
{open ? (
<Drawer
title="课件管理"
onClose={onCancel}
maskClosable={false}
open={true}
width={634}
>
<div className={styles["top-content"]}>
<p>1.线</p>
</div>
<div className="float-left mt-24">
<SelectAttachment
defaultKeys={attachments}
open={attachmentVisible}
onCancel={() => {
setAttachmentVisible(false);
}}
onSelected={(arr: any, videos: any) => {
selectAttachmentData(arr, videos);
}}
></SelectAttachment>
<Form
form={form}
name="attachment-update-basic"
labelCol={{ span: 5 }}
wrapperCol={{ span: 19 }}
initialValues={{ remember: true }}
onFinish={onFinish}
onFinishFailed={onFinishFailed}
autoComplete="off"
>
<div className="c-flex">
<Form.Item>
<div className="ml-42">
<Button
onClick={() => setAttachmentVisible(true)}
type="primary"
>
</Button>
</div>
</Form.Item>
<div className={styles["hous-box"]}>
{attachmentData.length === 0 && (
<span className={styles["no-hours"]}>
</span>
)}
{attachmentData.length > 0 && (
<TreeAttachments
data={attachmentData}
onRemoveItem={(id: number) => {
delAttachments(id);
}}
onUpdate={(arr: any[]) => {
transAttachments(arr);
}}
/>
)}
</div>
</Form.Item>
<div className={styles["hous-box"]}>
{attachmentData.length === 0 && (
<span className={styles["no-hours"]}>
</span>
)}
{attachmentData.length > 0 && (
<TreeAttachments
data={attachmentData}
onRemoveItem={(id: number) => {
delAttachments(id);
}}
onUpdate={(arr: any[]) => {
transAttachments(arr);
}}
/>
)}
</div>
</div>
</Form>
</div>
</Drawer>
</Form>
</div>
</Drawer>
) : null}
</>
);
};