Skip to content

Commit 851c8dc

Browse files
committed
Accept uid in form renderer and set it in EditorContext
1 parent 65cfda3 commit 851c8dc

File tree

2 files changed

+3
-0
lines changed

2 files changed

+3
-0
lines changed

src/form.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -187,6 +187,7 @@ export default class Form extends React.Component {
187187
fileListEndpoint: this.props.fileListEndpoint,
188188
fieldName: this.props.fieldName,
189189
modelName: this.props.modelName,
190+
uid: this.props.uid,
190191
}}
191192
>
192193
{this.getFields()}

src/renderer.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ export default function JSONForm(config) {
1010
this.fileListEndpoint = config.fileListEndpoint;
1111
this.fieldName = config.fieldName;
1212
this.modelName = config.modelName;
13+
this.uid = config.uid;
1314

1415
this.render = function() {
1516
ReactDOM.render(
@@ -21,6 +22,7 @@ export default function JSONForm(config) {
2122
fileListEndpoint={this.fileListEndpoint}
2223
fieldName={this.fieldName}
2324
modelName={this.modelName}
25+
uid={this.uid}
2426
/>,
2527
document.getElementById(this.containerId)
2628
);

0 commit comments

Comments
 (0)