Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

#Issue 7 CONFIRMED TO CANCELLED STATUS FOR RIDES IN PAST #108

Open
wanhoyinjoshua opened this issue Dec 21, 2022 · 0 comments
Open

#Issue 7 CONFIRMED TO CANCELLED STATUS FOR RIDES IN PAST #108

wanhoyinjoshua opened this issue Dec 21, 2022 · 0 comments

Comments

@wanhoyinjoshua
Copy link
Collaborator

Problem:
If a ride is in the past, the only thing that should be editable is changing its status from CONFIRMED to CANCELLED

Proposed solution:

`const confirmstatus= !dateInFuture && this.state.originalRideState?.status === 'CONFIRMED';
`

<option value="OPEN" disabled={cannotReopen||confirmstatus}>
                    Open
                  </option>
                  <option
                    value="CONFIRMED"
                    disabled={!this.state.driver || cannotReopen||confirmstatus}
                  >
                    Confirmed
                  </option>
                  <option
                    value="ENDED"
                    disabled={!this.state.driver || cannotReopen|| confirmstatus}
                  >
                    Ended
                  </option>
                  <option value="CANCELLED">Cancelled</option>
                </select>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant