Commit d12527ec authored by 武广's avatar 武广

fix: 修改上传图片样式

parent 47dd5aad
...@@ -142,6 +142,7 @@ const FormRuleVPictures = forwardRef((props, ref) => { ...@@ -142,6 +142,7 @@ const FormRuleVPictures = forwardRef((props, ref) => {
> >
<UploadImage <UploadImage
disabled={customer.isService} disabled={customer.isService}
multiple={false}
name="commonImageList" name="commonImageList"
limit={imgConfig.commonImageList.limit} limit={imgConfig.commonImageList.limit}
pictures={commonImageList} pictures={commonImageList}
......
...@@ -192,21 +192,25 @@ const UploadImage = forwardRef((props, ref) => { ...@@ -192,21 +192,25 @@ const UploadImage = forwardRef((props, ref) => {
</ReactSortable> </ReactSortable>
)} )}
</div> </div>
<Upload {limit !== null && fileList.length >= limit ? (
{...uploadParams} ''
disabled={Boolean(disabled)} ) : (
multiple={multiple} <Upload
name={name} {...uploadParams}
customRequest={() => {}} disabled={Boolean(disabled)}
listType="picture-card" multiple={multiple}
beforeUpload={defaultBeforeUpload} name={name}
fileList={fileList} customRequest={() => {}}
onPreview={handlePreview} listType="picture-card"
onRemove={handleRemove} beforeUpload={defaultBeforeUpload}
showUploadList={false} fileList={fileList}
> onPreview={handlePreview}
{limit !== null && fileList.length >= limit ? null : UploadButton} onRemove={handleRemove}
</Upload> showUploadList={false}
>
{UploadButton}
</Upload>
)}
<Modal visible={previewVisible} title={previewTitle} footer={null} onCancel={handleCancel}> <Modal visible={previewVisible} title={previewTitle} footer={null} onCancel={handleCancel}>
<img alt="example" style={{ width: '100%' }} src={previewImage} /> <img alt="example" style={{ width: '100%' }} src={previewImage} />
</Modal> </Modal>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment