[FEAT] Displays decimal amount #13
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
User description
Now the
Numscriptex.Posting{}andNumscriptex.Balance{}also displays the decimal amount/balances for a better user experience.PR Type
Enhancement, Tests, Documentation
Description
Added decimal representation for balances and postings.
Introduced utility functions for decimal conversions.
Updated tests to cover new decimal fields.
Enhanced documentation with examples of decimal usage.
Changes walkthrough 📝
balance.ex
Add decimal fields and conversion in Balance modulelib/numscriptex/balance.ex
decimal_final_balanceanddecimal_initial_balancefields.put_decimal_valuesfunction for decimal conversion.posting.ex
Add decimal field and conversion in Posting modulelib/numscriptex/posting.ex
decimal_amountfield to postings.put_decimal_amountfunction for conversion.utilities.ex
Add utility functions for decimal conversionlib/numscriptex/utilities.ex
integer_to_decimalfunction for conversion.decimal_places_from_assetfunction.balance_test.exs
Update Balance tests for decimal fieldstest/numscriptex/balance_test.exs
posting_tests.exs
Update Posting tests for decimal fieldtest/numscriptex/posting_tests.exs
numscriptex_test.exs
Update integration tests for decimal fieldstest/numscriptex_test.exs
README.md
Update README with decimal field examplesREADME.md