mirror of
https://github.com/internetee/registry.git
synced 2025-08-05 01:11:43 +02:00
parent
bb108efedd
commit
fa52001be6
141 changed files with 1388 additions and 1664 deletions
|
@ -1,10 +1,10 @@
|
|||
module Type
|
||||
class VATRate < ActiveRecord::Type::Decimal
|
||||
def type_cast_from_database(value)
|
||||
def deserialize(value)
|
||||
super * 100 if value
|
||||
end
|
||||
|
||||
def type_cast_for_database(value)
|
||||
def serialize(value)
|
||||
super / 100.0 if value
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue