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

feat(proof): recent proof dialog: add load more button, filter list depending on receipt or price tag #589

Merged
merged 2 commits into from
May 27, 2024

Conversation

odin-h
Copy link
Collaborator

@odin-h odin-h commented May 26, 2024

What

  • Adds a load more button at the bottom of the recent proofs list in the dialog box used when adding prices.
    Also, filters the proof type when fetching proofs based on if you're adding receipts or regular price tags.

Screenshot

Fixes bug(s)

Part of

Copy link
Member

@raphodn raphodn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome !

@@ -33,7 +38,8 @@ export default {
return {
userProofList: [],
userProofTotal: null,
userProofPage: 1,
userProofPage: 0,
userProofType: this.$route.path.endsWith('/receipt') ? 'RECEIPT' : 'PRICE_TAG',
Copy link
Member

@raphodn raphodn May 27, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the issue here is that the component's behavior will rely on the url. it would be better to be an optional parameter (props)

for example this component is used in the AddPriceSingle. but we shouldn't filter proofs there.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I fixed it here :) 97f9852

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice, thanks! 👍

However, if I'm understanding it correctly now that this filter is in place, the 'add a price' button on a specific proof id page with the RECEIPT type won't show the selected proof in the recent proofs dialog box on the add price page anymore. That could maybe be resolved by combining all the 'add price' pages into the add multiple page instead and add a proof type selector on the page to choose between price tag and receipt?

@raphodn raphodn changed the title feat(proof): load more button and type filter for recent proofs dialog box feat(proof): recent proof dialog: add load more button, filter list depending on receipt or price tag May 27, 2024
@raphodn raphodn merged commit c9fd2f4 into master May 27, 2024
4 checks passed
@raphodn raphodn deleted the recent-proof-dialog branch May 27, 2024 15:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

2 participants