mirror of
https://github.com/ascribe/onion.git
synced 2024-06-28 00:28:00 +02:00
problem with loanForm
This commit is contained in:
parent
ab97fa420c
commit
6530149971
|
@ -64,11 +64,16 @@ let LoanRequestAnswerForm = React.createClass({
|
||||||
this.setState(state);
|
this.setState(state);
|
||||||
},
|
},
|
||||||
|
|
||||||
|
handleLoanSuccess() {},
|
||||||
|
|
||||||
|
|
||||||
render() {
|
render() {
|
||||||
|
let startDate = null;
|
||||||
|
let endDate = null;
|
||||||
|
|
||||||
if (this.state.loanRequest) {
|
if (this.state.loanRequest) {
|
||||||
let startDate = new Moment(this.state.loanRequest.datetime_from, Moment.ISO_8601),
|
startDate = new Moment(this.state.loanRequest.datetime_from, Moment.ISO_8601);
|
||||||
endDate = new Moment(this.state.loanRequest.datetime_to, Moment.ISO_8601);
|
endDate = new Moment(this.state.loanRequest.datetime_to, Moment.ISO_8601);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<LoanForm
|
<LoanForm
|
||||||
|
@ -76,16 +81,18 @@ let LoanRequestAnswerForm = React.createClass({
|
||||||
message={''}
|
message={''}
|
||||||
id={this.props.id}
|
id={this.props.id}
|
||||||
url={this.props.url}
|
url={this.props.url}
|
||||||
email={this.state.loanRequest.new_owner}
|
email={this.state.loanRequest ? this.state.loanRequest.new_owner : null}
|
||||||
gallery={this.state.loanRequest.gallery}
|
gallery={this.state.loanRequest ? this.state.loanRequest.gallery : null}
|
||||||
startdate={startDate}
|
startdate={startDate}
|
||||||
enddate={endDate}
|
enddate={endDate}
|
||||||
|
//showStartDate={false}
|
||||||
|
//showEndDate={false}
|
||||||
showPassword={true}
|
showPassword={true}
|
||||||
showPersonalMessage={false}
|
showPersonalMessage={false}
|
||||||
handleSuccess={this.handleLoanSuccess}/>
|
handleSuccess={this.handleLoanSuccess}/>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
return null;
|
return <span/>;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user