Skip to content

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

@wanhoyinjoshua

Description

@wanhoyinjoshua

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>

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions