Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[expression] Add optional language parameter to format_number() to co…
…ntrol locale across different systems (cherry picked from commit cbd3068)
- Loading branch information
1 parent
a1342f5
commit 623c263
Showing
3 changed files
with
18 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,10 @@ | ||
{ | ||
"name": "format_number", | ||
"type": "function", | ||
"description": "Returns a number formatted with the locale separator for thousands. Also truncates the number to the number of supplied places.", | ||
"description": "Returns a number formatted with the locale separator for thousands. Also truncates the decimal places to the number of supplied places.", | ||
"arguments": [ {"arg":"number","description":"number to be formatted"}, | ||
{"arg":"places","description":"integer representing the number of decimal places to truncate the string to."}], | ||
{"arg":"places","description":"integer representing the number of decimal places to truncate the string to."}, | ||
{"arg":"language","optional":true,"description":"language (lowercase, two- or three-letter, ISO 639 language code) used to format the number into a string"}], | ||
"examples": [ { "expression":"format_number(10000000.332,2)", "returns":"'10,000,000.33'"} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters