diff --git a/editoast/editoast_schemas/src/rolling_stock/mod.rs b/editoast/editoast_schemas/src/rolling_stock/mod.rs index 9019f189c06..70190543bbe 100644 --- a/editoast/editoast_schemas/src/rolling_stock/mod.rs +++ b/editoast/editoast_schemas/src/rolling_stock/mod.rs @@ -60,6 +60,8 @@ editoast_common::schemas! { RollingStockLiveryMetadata, } +pub const ROLLING_STOCK_RAILJSON_VERSION: &str = "3.2"; + #[derive(Debug, Clone, PartialEq, Deserialize, Serialize, ToSchema)] pub struct RollingStock { pub id: i64, diff --git a/editoast/src/schema/rolling_stock/mod.rs b/editoast/src/schema/rolling_stock/mod.rs index 82f2a79f12e..d498fbae988 100644 --- a/editoast/src/schema/rolling_stock/mod.rs +++ b/editoast/src/schema/rolling_stock/mod.rs @@ -4,5 +4,3 @@ editoast_common::schemas! { editoast_schemas::rolling_stock::schemas(), light_rolling_stock::schemas(), } - -pub const ROLLING_STOCK_RAILJSON_VERSION: &str = "3.2"; diff --git a/editoast/src/views/rolling_stocks/rolling_stock_form.rs b/editoast/src/views/rolling_stocks/rolling_stock_form.rs index 432e108beb2..e09e545b020 100644 --- a/editoast/src/views/rolling_stocks/rolling_stock_form.rs +++ b/editoast/src/views/rolling_stocks/rolling_stock_form.rs @@ -1,6 +1,7 @@ use derivative::Derivative; use editoast_schemas::rolling_stock::RollingStockCommon; use editoast_schemas::rolling_stock::RollingStockMetadata; +use editoast_schemas::rolling_stock::ROLLING_STOCK_RAILJSON_VERSION; use serde_derive::Deserialize; use serde_derive::Serialize; use utoipa::ToSchema; @@ -11,7 +12,6 @@ use crate::modelsv2::rolling_stock_model::validate_rolling_stock; use crate::modelsv2::Changeset; use crate::modelsv2::Model; use crate::modelsv2::RollingStockModel; -use crate::schema::rolling_stock::ROLLING_STOCK_RAILJSON_VERSION; #[derive(Debug, Clone, Deserialize, Serialize, ToSchema, Validate, Derivative)] #[derivative(PartialEq)]