add amount.mli
This commit is contained in:
parent
58bce4efa2
commit
9b760b436f
5 changed files with 48 additions and 17 deletions
|
|
@ -17,7 +17,7 @@ let pg_amount : Amount.t Caqti_type.t =
|
|||
Caqti_type.custom
|
||||
~encode:(fun amount -> Ok (amount.value, amount.fraction))
|
||||
~decode:(fun (value, fraction) ->
|
||||
Ok { sign= None; currency= `Eur; value; fraction })
|
||||
Amount.make ~sign:None ~currency:Config.currency ~value ~fraction)
|
||||
Caqti_type.(t2 int64 int32)
|
||||
|
||||
(* WIP: minimum db functions for basic /management *)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue