Use f64 for money

This commit is contained in:
Sam Samai 2021-07-03 21:21:35 +10:00
parent 86bfcba083
commit 76d2cbb955
2 changed files with 2 additions and 2 deletions

View File

@ -13,7 +13,7 @@ impl EntityName for Entity {
pub struct Model { pub struct Model {
pub id: i32, pub id: i32,
pub name: String, pub name: String,
pub price: f32, pub price: f64,
pub bakery_id: Option<i32>, pub bakery_id: Option<i32>,
pub gluten_free: bool, pub gluten_free: bool,
} }

View File

@ -12,7 +12,7 @@ impl EntityName for Entity {
#[derive(Clone, Debug, PartialEq, DeriveModel, DeriveActiveModel)] #[derive(Clone, Debug, PartialEq, DeriveModel, DeriveActiveModel)]
pub struct Model { pub struct Model {
pub id: i32, pub id: i32,
pub price: f32, pub price: f64,
pub quantity: i32, pub quantity: i32,
pub order_id: Option<i32>, pub order_id: Option<i32>,
} }