Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <GridItem xs={12} sm={12} md={12}>
- <TextField
- id="sp_Inhouse"
- label="Number of Pilots Available "
- type="number"
- fullWidth
- className={classes.textField}
- value={this.state.sp_Inhousecount}
- error={!!this.state.sp_InhouseError}
- helperText={this.state.sp_InhouseError}
- onChange={this.handleChangeInhouse}
- margin="normal"
- required
- />
- </GridItem>
- <GridItem xs={12} sm={12} md={12}>
- <Button color="primary" onClick={this.handleCreatePilots}>
- <AddIcon /> Add Pilots
- </Button>
- {this.state.inhouse.map((index) => {
- return (
- <div key={index}>
- <TextField
- id="sp_Name"
- label="Name "
- type="number"
- fullWidth
- />
- <TextField
- id="sp_Mobile"
- label="Name "
- type="number"
- fullWidth
- />
- </div>
- )
- })
- }
- </GridItem>
- handleCreatePilots=()=>{
- this.setState({
- inhouse:[...this.state.inhouse,'']
- })
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement