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

Workflow - Assigning decimal values always round to two decimals #9894

Open
SinergiaCRM opened this issue Jan 11, 2023 · 0 comments · May be fixed by #9461
Open

Workflow - Assigning decimal values always round to two decimals #9894

SinergiaCRM opened this issue Jan 11, 2023 · 0 comments · May be fixed by #9461
Labels
Area: Workflow Issues & PRs related to all things regarding workflow Priority:Important Issues & PRs that are important; broken functions, errors - there are workarounds Status:Fix Proposed A issue that has a PR related to it that provides a possible resolution Type: Bug Bugs within the core SuiteCRM codebase

Comments

@SinergiaCRM
Copy link
Contributor

In a Workflow action that modifies a record adding the decimal value of a field to another decimal field, the result is always rounded to two decimals

DecimalsRound

Issue

Some of the decimals are lost during the execution of the action.

Expected Behavior

All the decimals should be transfered.

Actual Behavior

The system isn't taking into account the decimal precision defined in the vardef.

Possible Fix

Use the vardef precision in the workflow action.

Steps to Reproduce

  1. Create two decimals fields in Accounts (fielda_c, fieldb_c)
  2. Create a workflow with an action that modified the record, adding the value the "fielda_c" to "fieldb_c"
  3. Save an Account record adding the value 12.345678 to fielda_c
  4. Check that, with the result of the WF action, fieldb_c contains 12.350000

Context

This is losing information, or valuable data.

Your Environment

  • SuiteCRM Version used: 7.12.8
  • Browser name and version: Versión 107.0.5304.121 (Build oficial) (64 bits)
  • Environment name and version: MariaDB 10.6.5, PHP 7.4
  • Operating System and version : KDE Neon 5.26
AlbertoSTIC pushed a commit to SinergiaTIC/SuiteCRM that referenced this issue Jan 11, 2023
AlbertoSTIC pushed a commit to SinergiaTIC/SuiteCRM that referenced this issue Jan 11, 2023
@johnM2401 johnM2401 added Type: Bug Bugs within the core SuiteCRM codebase Status:Fix Proposed A issue that has a PR related to it that provides a possible resolution Priority:Important Issues & PRs that are important; broken functions, errors - there are workarounds Area: Workflow Issues & PRs related to all things regarding workflow labels Jan 17, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area: Workflow Issues & PRs related to all things regarding workflow Priority:Important Issues & PRs that are important; broken functions, errors - there are workarounds Status:Fix Proposed A issue that has a PR related to it that provides a possible resolution Type: Bug Bugs within the core SuiteCRM codebase
Projects
None yet
2 participants