|
@@ -12,6 +12,7 @@ import WbwDetailAdvance from "./WbwDetailAdvance";
|
|
|
import { LockIcon, UnLockIcon } from "../../../assets/icon";
|
|
import { LockIcon, UnLockIcon } from "../../../assets/icon";
|
|
|
import { UploadFile } from "antd/es/upload/interface";
|
|
import { UploadFile } from "antd/es/upload/interface";
|
|
|
import { IAttachmentResponse } from "../../api/Attachments";
|
|
import { IAttachmentResponse } from "../../api/Attachments";
|
|
|
|
|
+import WbwDetailAttachment from "./WbwDetailAttachment";
|
|
|
|
|
|
|
|
interface IWidget {
|
|
interface IWidget {
|
|
|
data: IWbw;
|
|
data: IWbw;
|
|
@@ -134,6 +135,20 @@ const Widget = ({ data, onClose, onSave }: IWidget) => {
|
|
|
onChange={(e: IWbwField) => {
|
|
onChange={(e: IWbwField) => {
|
|
|
fieldChanged(e.field, e.value);
|
|
fieldChanged(e.field, e.value);
|
|
|
}}
|
|
}}
|
|
|
|
|
+ />
|
|
|
|
|
+ </div>
|
|
|
|
|
+ ),
|
|
|
|
|
+ },
|
|
|
|
|
+ {
|
|
|
|
|
+ label: `attachments`,
|
|
|
|
|
+ key: "attachments",
|
|
|
|
|
+ children: (
|
|
|
|
|
+ <div>
|
|
|
|
|
+ <WbwDetailAttachment
|
|
|
|
|
+ data={currWbwData}
|
|
|
|
|
+ onChange={(e: IWbwField) => {
|
|
|
|
|
+ fieldChanged(e.field, e.value);
|
|
|
|
|
+ }}
|
|
|
onUpload={(fileList: UploadFile<IAttachmentResponse>[]) => {
|
|
onUpload={(fileList: UploadFile<IAttachmentResponse>[]) => {
|
|
|
let mData = currWbwData;
|
|
let mData = currWbwData;
|
|
|
mData.attachments = fileList.map((item) => {
|
|
mData.attachments = fileList.map((item) => {
|