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

COMCL-770: Fix Line Item Creations #193

Merged
merged 1 commit into from
Sep 9, 2024

Conversation

shahrukh-compuco
Copy link
Contributor

@shahrukh-compuco shahrukh-compuco commented Sep 8, 2024

Overview

This pr fixes the creation of line item that gets created without price field values as with newer civicrm version it is mandatory for a line items to have price field values.

Technical Details

This pr adds a post hook that runs every time a line item is created without price field values and it updates the line item with price field value from default price set(the price set by the name of default_contribution_amount), this price set is created with civicrm installation. Secondly this pr also adds an upgrader which will fill price field values for existing line items.

@jamienovick
Copy link
Contributor

Can you clarify what do we mean by "default" here? @shahrukh-compuco

@shahrukh-compuco
Copy link
Contributor Author

Can you clarify what do we mean by "default" here? @shahrukh-compuco

done

@jamienovick
Copy link
Contributor

Thanks. Are we sure that all clients will have this price set? Do you know from which version of civicrm it gets added/installed? @shahrukh-compuco

@shahrukh-compuco
Copy link
Contributor Author

Thanks. Are we sure that all clients will have this price set? Do you know from which version of civicrm it gets added/installed? @shahrukh-compuco

@jamienovick it is from this commit compucorp/civicrm-core@6a48803 which I think was in civicrm 4.3 and it is a reserved price set which means it can only be deleted through a direct query in database so imo it should be there for each client db

@jamienovick
Copy link
Contributor

Thanks. Are we sure that all clients will have this price set? Do you know from which version of civicrm it gets added/installed? @shahrukh-compuco

@jamienovick it is from this commit compucorp/civicrm-core@6a48803 which I think was in civicrm 4.3 and it is a reserved price set which means it can only be deleted through a direct query in database so imo it should be there for each client db

Great perfect thanks

@shahrukh-compuco shahrukh-compuco merged commit 934a546 into master Sep 9, 2024
2 checks passed
@shahrukh-compuco shahrukh-compuco deleted the comcl-770-fix-line-item-creations branch September 9, 2024 09:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants