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

PIREP from flight/bid; orig: Bid not removed after flight accepted #406

Closed
nabeelio opened this issue Sep 21, 2019 · 0 comments
Closed

PIREP from flight/bid; orig: Bid not removed after flight accepted #406

nabeelio opened this issue Sep 21, 2019 · 0 comments

Comments

@nabeelio
Copy link
Owner

nabeelio commented Sep 21, 2019

Solve this in a more generic way:

  1. Add a link from the flight to file a PIREP (/pireps/new?flight_id=XYZ)
    • On the PIREP form, look up/pre-populate from that flight (set a PIREP object?)
  2. When submitting:
    • Look up the flight_id and see if a bid exists, attach to the PIREP if there is a bid (user_id+flight_id)
      • Add a bid_id column to the pireps table to keep track
    • According to the config (below), close or keep the bid
    • Do it in App\Listeners\BidEvents

Add config:

  • bids.close_bid_on_file - if set, it'll close the bid when filed, otherwise, when the admin accepts it
@nabeelio nabeelio added the bug label Sep 21, 2019
@nabeelio nabeelio added this to the beta milestone Sep 21, 2019
@nabeelio nabeelio modified the milestones: beta, beta-2 Oct 23, 2019
@nabeelio nabeelio changed the title Bid not removed after flight accepted PIREP from flight/bid; orig: Bid not removed after flight accepted Oct 30, 2019
nabeelio added a commit that referenced this issue Nov 5, 2019
* Add flight_id column to pireps table

* Refactor PIREPs and bids closes 406

* Formatting
@nabeelio nabeelio closed this as completed Nov 5, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant