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

Add generating with customer_name_id #5958

Merged
merged 4 commits into from
Jan 9, 2025

Conversation

fergie-nz
Copy link
Contributor

Fixes #5951

πŸ‘©πŸ»β€πŸ’» What does this PR do?

Fixes to use customer store name id rather than other party (which could be the supplier) store name id for indicator values.

πŸ’Œ Any notes for the reviewer?

I was struggling to get tests working with time available and removed them here. I wonder if worthwhile adding these in and including tests to cover correct assignment of store_id, name_id, etc.

πŸ§ͺ Testing

  • Generate a request requisition which is part of a program with program indicators
  • Add regimen data to the requisition
  • Check indicator values (probably easiest with database viewer) to see that they customer id refers to the same store as the store id

@github-actions github-actions bot added bug Something is borken needs triage needs daily triage New bug to be triaged by the release team labels Jan 8, 2025
Comment on lines 207 to 211
let customer_name_id = StoreRowRepository::new(connection)
.find_one_by_id(&ctx.user_id.clone())?
.ok_or(RepositoryError::NotFound)?
.name_link_id;

Copy link
Contributor Author

Choose a reason for hiding this comment

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

To ensure merge safety, I'm not entirely clear on if we should be using name_link_id or querying the store repository to find the name_row.id.

@fergie-nz fergie-nz added Severity: Hotfix Extreme user impact. Can't finalise invoices. Needs patch release and installation immediately. and removed needs triage needs daily triage New bug to be triaged by the release team labels Jan 8, 2025
@fergie-nz fergie-nz added this to the V2.5.0-RC1 milestone Jan 8, 2025
@roxy-dao roxy-dao changed the base branch from develop to V2.5.0-RC January 9, 2025 19:42
@github-actions github-actions bot removed this from the V2.5.0-RC2 milestone Jan 9, 2025
Search for name id rather thank link id and search for store correctly
Copy link
Contributor

@roxy-dao roxy-dao left a comment

Choose a reason for hiding this comment

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

LGTM~

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something is borken Severity: Hotfix Extreme user impact. Can't finalise invoices. Needs patch release and installation immediately.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

indicator values are saving customer_name_id as other_party_name_id
3 participants