| | |
| | | documentType: res.documentType || 'DT00002' |
| | | }, |
| | | loading: false, |
| | | fileList: res.attachmentList && res.attachmentList.map((a) => ({ ...a, key: a.id, uid: a.id, name: a.fileName + '.' + a.suffix, })) || [] |
| | | fileList: res.attachmentList && res.attachmentList.map((a) => ({ ...a, key: a.id, uid: a.id, name: a.fileName + '.' + a.suffix, status: 'done' })) || [] |
| | | }); |
| | | }); |
| | | } |
| | |
| | | header: { |
| | | Authorization: window.localStorage.getItem('token') |
| | | }, |
| | | showUploadList: { |
| | | showDownloadIcon: true, |
| | | showRemoveIcon: false, |
| | | showPreviewIcon: true |
| | | }, |
| | | onDownload: (file) => { |
| | | console.log('file', file) |
| | | }, |
| | | onChange: ({ file, fileList }) => { |
| | | fileList = fileList.slice(-2); |
| | | fileList = fileList.map(file => { |
| | |
| | | onPreview: (file) => { |
| | | window.open(file.url); |
| | | }, |
| | | showUploadList: { showPreviewIcon: true, showDownloadIcon: true, showRemoveIcon: false } |
| | | }; |
| | | |
| | | return ( |