Core
Core app reference.
Utils
- salesman.core.utils.format_price(value: Decimal, context: dict[str, Any] = {}) str [source]
Default price format function. Can be overriden by providing a dotted path to a function in
SALESMAN_PRICE_FORMATTER
setting.- Parameters:
value (Decimal) – Number value to be formatted
context (dict, optional) – Format context data. Defaults to {}.
- Returns:
Formatted price as a string
- Return type:
str
Serializers
Typing
Utils
- salesman.core.utils.format_price(value: Decimal, context: dict[str, Any] = {}) str [source]
Default price format function. Can be overriden by providing a dotted path to a function in
SALESMAN_PRICE_FORMATTER
setting.- Parameters:
value (Decimal) – Number value to be formatted
context (dict, optional) – Format context data. Defaults to {}.
- Returns:
Formatted price as a string
- Return type:
str