Front end input changed to text area

This commit is contained in:
VakarisZ 2019-01-30 13:58:15 +02:00
parent e5f908754a
commit 8e78150db4
1 changed files with 13 additions and 0 deletions

View File

@ -152,6 +152,18 @@ class ConfigurePageComponent extends AuthComponent {
render() { render() {
let displayedSchema = {}; let displayedSchema = {};
const uiSchema = {
general: {
post_breach_actions: {
linux: {
"ui:widget": "textarea"
},
windows: {
"ui:widget": "textarea"
}
}
}
};
if (this.state.schema.hasOwnProperty('properties')) { if (this.state.schema.hasOwnProperty('properties')) {
displayedSchema = this.state.schema['properties'][this.state.selectedSection]; displayedSchema = this.state.schema['properties'][this.state.selectedSection];
displayedSchema['definitions'] = this.state.schema['definitions']; displayedSchema['definitions'] = this.state.schema['definitions'];
@ -178,6 +190,7 @@ class ConfigurePageComponent extends AuthComponent {
} }
{ this.state.selectedSection ? { this.state.selectedSection ?
<Form schema={displayedSchema} <Form schema={displayedSchema}
uiSchema={uiSchema}
formData={this.state.configuration[this.state.selectedSection]} formData={this.state.configuration[this.state.selectedSection]}
onSubmit={this.onSubmit} onSubmit={this.onSubmit}
onChange={this.onChange}> onChange={this.onChange}>