mirror of
https://github.com/ascribe/onion.git
synced 2025-01-08 20:55:59 +01:00
solves the issue for textarea_toggable
couldnt reproduce login
This commit is contained in:
parent
61077de3de
commit
e060d39486
@ -39,13 +39,14 @@ let Form = React.createClass({
|
||||
this.setState(this.getInitialState());
|
||||
},
|
||||
submit(event){
|
||||
console.log('submit')
|
||||
if (event) {
|
||||
event.preventDefault();
|
||||
}
|
||||
this.setState({submitted: true});
|
||||
this.clearErrors();
|
||||
let action = (this.httpVerb && this.httpVerb()) || 'post';
|
||||
this[action]();
|
||||
window.setTimeout(() => this[action](), 100);
|
||||
},
|
||||
post(){
|
||||
requests
|
||||
@ -56,9 +57,14 @@ let Form = React.createClass({
|
||||
|
||||
getFormData(){
|
||||
let data = {};
|
||||
console.log('data')
|
||||
for (let ref in this.refs){
|
||||
data[this.refs[ref].props.name] = this.refs[ref].state.value;
|
||||
console.log(this.refs[ref].state.value)
|
||||
console.log(this.refs[ref].refs.input.state.value)
|
||||
}
|
||||
//console.log(data)
|
||||
|
||||
if ('getFormData' in this.props){
|
||||
data = mergeOptionsWithDuplicates(data, this.props.getFormData());
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user