mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-01-24 20:36:49 +00:00
rounding decimal quantities in shopfront
This commit is contained in:
@@ -2,5 +2,4 @@ Darkswarm.directive "integer", ->
|
||||
restrict: 'A'
|
||||
link: (scope, elem, attr) ->
|
||||
elem.bind 'input', ->
|
||||
digits = elem.val().replace(/\D/g, "")
|
||||
elem.val digits
|
||||
elem.val Math.round(elem.val())
|
||||
|
||||
Reference in New Issue
Block a user