Skip to content

[Issue]: Price versioning: schema with effective dates #24

Closed

Description

@MariyaSamrout

Branch Name

feature/24-price-versioning-schema

Task

Description
Each price must have an effective date, so that past donations keep the price that applied at the time. Prices are never overwritten: a new price is added as a new row. For DB schemas we use https://dbdiagram.io/

Scope

  • prices table with unit price and effective date
  • Link between prices and food items
  • Constraints to prevent two prices with the same effective date for one item
  • Migration

Acceptance Criteria

  • Several prices can exist for the same food item
  • Each price has an effective date
  • The migration applies cleanly on an empty database
  • A constraint is preventing two prices

Checklist

  • I have checked for duplicate issues.
  • I have assigned the issue to the correct project board.
  • I have tagged the issue properly.

Code of Conduct

  • I agree to follow this project's Code of Conduct

Activity

  1. added this to the Sprint - 2 milestone on Oct 25, 2026
  2. lauriechammah commented on Oct 26, 2026

    @lauriechammah
    Collaborator

    Review comments:

    • Acceptance criteria should be checkboxes (- [ ]) so progress can be tracked.
    • For DB schemas we use https://dbdiagram.io/, please add the link to the description.
    • The scope mentions a constraint preventing two prices with the same effective date for one item, but no acceptance criterion covers it.
    • How does this relate to the price stored on receipts in [Issue]: Database schema: receipts with price #16? Worth clarifying so prices aren't modeled twice.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

Type

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions