You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Users need a UI that allows them to mark the their items as purchased, so they can track what on their list they do and do not need to buy.
Acceptance criteria
The ListItem component renders a checkbox with a semantic <label>.
Checking off the item in the UI also updates the dateLastPurchased and totalPurchases properties on the corresponding Firestore document
The item is shown as checked for 24 hours after the purchase is made (i.e. we assume the user does not need to buy the item again for at least 1 day). After 24 hours, the item unchecks itself so the user can buy it again.
The updateItem function in firebase.js has been filled out, and sends updates to the firestore database when an item is checked
Notes:
While you will need to update multiple parts of the Firestore document for this feature, do not worry about dateNextPurchased yet. That will be addressed in a future issue.
You can use the Firestore console to test that this feature is working correctly, e.g., by manipulating the value of dateLastPurchased
The text was updated successfully, but these errors were encountered:
jeremiahfallin
changed the title
8. As a user, I want to mark an item on my shopping list as purchased so the app can learn how often I buy different items.
9. As a user, I want to mark an item on my shopping list as purchased so the app can learn how often I buy different items.
Dec 29, 2023
Summary
Users need a UI that allows them to mark the their items as purchased, so they can track what on their list they do and do not need to buy.
Acceptance criteria
ListItem
component renders a checkbox with a semantic<label>
.dateLastPurchased
andtotalPurchases
properties on the corresponding Firestore documentupdateItem
function infirebase.js
has been filled out, and sends updates to the firestore database when an item is checkedNotes:
dateNextPurchased
yet. That will be addressed in a future issue.dateLastPurchased
The text was updated successfully, but these errors were encountered: