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

Deprectate Order->Total() as it conflicts with casting of Total DB field #811

Open
wernerkrauss opened this issue Dec 14, 2023 · 0 comments

Comments

@wernerkrauss
Copy link
Contributor

How about deprecating Order's Total() method and suggest using it's alias instead, GrandTotal()?

It conflicts with casting of Total DB field for e.g. GridField when I want to dispay it with European decimal numbers. (See related #779)

This can be done in the next SS5 main release, as it's a breaking change and I don't know how many modules (or custom installations) use it right now.

Of course we can add a rector for easier upgrading to silverstripe-rector

wernerkrauss added a commit to wernerkrauss/silvershop-core that referenced this issue Jan 2, 2024
See silvershop#811

Can be removed if Total() works like other DB Fields
wernerkrauss added a commit to wernerkrauss/silvershop-core that referenced this issue Jan 2, 2024
wilr pushed a commit that referenced this issue Jan 17, 2024
* Order: helper method for nice formatting of Total in GridFields

See #811

Can be removed if Total() works like other DB Fields

* OrderModifier: disable Amount() method

See #811

* OrderModifier: show short class name in summary fields

* shop reports: format currency values as currency

* fix linting errors
wernerkrauss added a commit that referenced this issue Feb 20, 2024
* Order: helper method for nice formatting of Total in GridFields

See #811

Can be removed if Total() works like other DB Fields

* OrderModifier: disable Amount() method

See #811

* OrderModifier: show short class name in summary fields

* shop reports: format currency values as currency

* fix linting errors
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

No branches or pull requests

1 participant