提交 10f13ac6 authored 作者: tb53863844's avatar tb53863844

修改bug

上级 8254b4ba
...@@ -2,7 +2,6 @@ import React from 'react' ...@@ -2,7 +2,6 @@ import React from 'react'
import { Tree,Upload,Icon,Button,message } from 'antd'; import { Tree,Upload,Icon,Button,message } from 'antd';
import { queryApiActionPath } from "../utils/queryConfig"; import { queryApiActionPath } from "../utils/queryConfig";
import config from '@/webPublic/one_stop_public/config' import config from '@/webPublic/one_stop_public/config'
const TreeNode = Tree.TreeNode;
export default class UploadCom extends React.Component { export default class UploadCom extends React.Component {
...@@ -62,9 +61,11 @@ export default class UploadCom extends React.Component { ...@@ -62,9 +61,11 @@ export default class UploadCom extends React.Component {
} }
render() { render() {
const {files}= this.state const {files}= this.state
const{isMultiple,accept,btnName} = this.props
const props = { const props = {
name: 'file', name: 'file',
multiple:isMultiple,
accept:accept,
action: config.uploadUrl, action: config.uploadUrl,
showUploadList:false, showUploadList:false,
onChange:this.changeUrl onChange:this.changeUrl
...@@ -73,7 +74,7 @@ export default class UploadCom extends React.Component { ...@@ -73,7 +74,7 @@ export default class UploadCom extends React.Component {
return ( return (
<div> <Upload {...props}> <div> <Upload {...props}>
<Button> <Button>
<Icon type="upload" />上传附件 <Icon type="upload" />{btnName?btnName:"上传附件"}
</Button> </Button>
</Upload> </Upload>
<ul style={{paddingLeft:8}}> <ul style={{paddingLeft:8}}>
......
...@@ -2944,7 +2944,7 @@ export default class tableCom extends Component { ...@@ -2944,7 +2944,7 @@ export default class tableCom extends Component {
message: '请选择附件', message: '请选择附件',
}, },
], ],
})(<UploadCom />); })(<UploadCom isMultiple={json.isMultiple} accept={json.accept} btnName={json.btnName}/>);
if ( if (
get === 'mobile' && get === 'mobile' &&
((json.isMobileLabel != null && json.isMobileLabel) || ((json.isMobileLabel != null && json.isMobileLabel) ||
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论