Attachment
附件展示
API
编辑态
IAttachmentEditableProps
| 参数 | 类型 | 说明 | 默认值 |
|---|---|---|---|
| showInlineTips | boolean | 是否展示内联提示 | - |
| customFilePath | string | 自定义上传路径 | - |
| tip | string | 自定义提示文案,可支持模版字符串,例如tip=“最多支持${countLimit}个文件${allowedTypeString},单个文件不大于${maxSizeString}” countLimit:最大文件个数;allowedTypeString:支持的文件类型;maxSizeString: 文件最大Size | - |
| removeConfirmText | string | 自定义删除上传文件的文案,配置后在删除文件时会弹出二次确认框 | - |
| maxSize | number | 指定文件最大体积 | - |
| allowedTypes | string[] | 限制上传文件类型 | - |
| countLimit | number | 限制上传数量 | - |
展示态
IAttachmentReadonlyProps
| 参数 | 类型 | 说明 | 默认值 |
|---|---|---|---|
| listType | ’text’ | ‘picture-card’ | 展示方式 | - |
| isProgressiveUploadList | boolean | 是否渐进式展示 | - |
示例图

示例代码
<View title="Attachment" version="2"> <Form model="trantor_doc_Person"> <Fields> <Field name="avatar"> <RenderType> <Attachment showInlineTips="#{false}" /> </RenderType> </Field> </Form></View>注意:当前例子为0.17.x 版本