Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- render() {
- const { tripCost, options, setOrderOption, address, tripName, tripId, countryCode } = this.props;
- console.log('address ', address)
- const { name, contact } = options
- const isFormValid = this.isFormValid(options)
- return (
- <Grid>
- <Row>
- {pricing.map(option =>
- <Col md={4} key={option.id}>
- <OrderOption {...option} currentValue={options[option.id]} setOrderOption={setOrderOption} />
- </Col>
- )}
- <Col xs={12}>
- <OrderSummary tripCost={tripCost} options={options} />
- {
- isFormValid ? (
- <p>Please provide name and contact to submit order</p>
- ) : (
- <Button onClick={() => sendOrder(options, tripCost, address, tripName, tripId, countryCode)}>Order now!</Button>
- )
- }
- </Col>
- </Row>
- </Grid>
- );
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement