Skip to content

Commit

Permalink
values added
Browse files Browse the repository at this point in the history
  • Loading branch information
MalinduPanchala committed Oct 19, 2020
1 parent 683f4e5 commit 95b2523
Showing 1 changed file with 15 additions and 4 deletions.
19 changes: 15 additions & 4 deletions src/components/AssignDriverForm.component.js
Original file line number Diff line number Diff line change
Expand Up @@ -94,26 +94,37 @@ export default function AssignVehicleForm(props) {
<div class="form-group">
<label for="selectoption">Select Driver</label>
<br />
<input type="text" class="form-control" id="location" placeholder="Enter a Driver" onChange={(e) => setDriver(e.target.value)} />
<input type="text" class="form-control" id="location" placeholder="Enter a Driver" value={Driver} onChange={(e) => setDriver(e.target.value)} />
</div>

<div class="form-group">
<label for="selectoption">Select Vehicle</label>
<br />
<input type="text" class="form-control" id="location" placeholder="Enter a Vehicle" onChange={(e) => setVehicle(e.target.value)} />
<input type="text" class="form-control" id="location" placeholder="Enter a Vehicle" value={Vehicle} onChange={(e) => setVehicle(e.target.value)} />
</div>

<div class="form-group">
<label for="brand">Select Time</label>
<input type="time" class="form-control" id="city" placeholder="" onChange={(e) => setDeleveryTime(e.target.value)}/>
<input type="time" class="form-control" id="city" placeholder="" value={DeleveryTime} onChange={(e) => setDeleveryTime(e.target.value)}/>
</div>

<div class="form-group">
<label for="brand">Select Date</label>
<input type="date" class="form-control" id="city" placeholder="" onChange={(e) => setDeleveryDate(e.target.value)} />
<input type="date" class="form-control" id="city" placeholder="" value={DeleveryDate} onChange={(e) => setDeleveryDate(e.target.value)} />
</div>

<button type="submit" class="btn btn-primary">Submit</button>
<div className="form-group">
<button className="demo" onClick={(e) => {
e.preventDefault();
setVehicle("Dolphin");
setDriver("Rehan Fernando")
setDeleveryDate("2015-03-13");
setDeleveryTime("05:30 PM")
}}>
Demo
</button>
</div>

</form>
</div>
Expand Down

0 comments on commit 95b2523

Please sign in to comment.