Fix markets price precision

This commit is contained in:
Svilen Markov
2025-03-28 14:11:17 +00:00
parent 233de7fc37
commit bd020c93f5
3 changed files with 15 additions and 8 deletions
+3
View File
@@ -27,6 +27,9 @@ var globalTemplateFunctions = template.FuncMap{
"formatPrice": func(price float64) string {
return intl.Sprintf("%.2f", price)
},
"formatPriceWithPrecision": func(precision int, price float64) string {
return intl.Sprintf("%."+strconv.Itoa(precision)+"f", price)
},
"dynamicRelativeTimeAttrs": dynamicRelativeTimeAttrs,
"formatServerMegabytes": func(mb uint64) template.HTML {
var value string