提交 6c26bef9 authored 作者: 徐立's avatar 徐立
...@@ -26,7 +26,7 @@ export default class ChildForm extends React.Component { ...@@ -26,7 +26,7 @@ export default class ChildForm extends React.Component {
// Should be a controlled component. // Should be a controlled component.
if ('value' in nextProps) { if ('value' in nextProps) {
const value = nextProps.value; const value = nextProps.value;
this.setState(value); this.state=value
} }
} }
componentDidMount = () => { componentDidMount = () => {
...@@ -98,12 +98,12 @@ export default class ChildForm extends React.Component { ...@@ -98,12 +98,12 @@ export default class ChildForm extends React.Component {
render() { render() {
const objs = this.state; const objs = this.state;
const { form, mapData, sqlData, defaultValues, datas, base52, isEdit, addName, deleteName, obj, isMobile, json,modalInit } = this.props const { form, mapData, sqlData, defaultValues, datas, base52, isEdit, addName, deleteName, obj, isMobile, json,modalInit } = this.props
const span = json.span || 24 const span = json.span || 24
const gutter = json.gutter != null ? json.gutter : 0 const gutter = json.gutter != null ? json.gutter : 0
const rights = this.props.rights const rights = this.props.rights
const xx = form.getFieldValue(base52) const xx = form.getFieldValue(base52)
if(objs!=null&&xx!=null){ if(objs!=null&&xx!=null){
for(var x in objs){ for(var x in objs){
if(xx[x]!=null)objs[x]=xx[x] if(xx[x]!=null)objs[x]=xx[x]
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论