From c345ffde6b014fe109e3d5da422ea137511bf150 Mon Sep 17 00:00:00 2001 From: Paul-Christian Volkmer Date: Wed, 1 Jan 2025 20:15:10 +0100 Subject: [PATCH] chore: allow clippy linter warnings on some structs This allows using original field names if they contain the struct name --- src/model/data_catalogue.rs | 2 ++ src/model/other.rs | 6 ++++++ src/model/property_catalogue.rs | 2 ++ src/profile.rs | 1 + 4 files changed, 11 insertions(+) diff --git a/src/model/data_catalogue.rs b/src/model/data_catalogue.rs index ca34846..6cdc003 100644 --- a/src/model/data_catalogue.rs +++ b/src/model/data_catalogue.rs @@ -152,6 +152,8 @@ pub struct Entries { entry: Vec, } +#[allow(clippy::struct_excessive_bools)] +#[allow(clippy::struct_field_names)] #[derive(Serialize, Deserialize, Debug)] #[serde(deny_unknown_fields)] pub struct Entry { diff --git a/src/model/other.rs b/src/model/other.rs index 7547c92..f417360 100644 --- a/src/model/other.rs +++ b/src/model/other.rs @@ -22,6 +22,7 @@ use crate::model::{Ansicht, Filter, FormEntry, Ordner, RefEntries, Script, Sorta use serde::{Deserialize, Serialize}; // Ablaufschema ... +#[allow(clippy::struct_field_names)] #[derive(Debug, Deserialize, Serialize)] pub struct Ablaufschema { #[serde(rename = "Name")] @@ -106,6 +107,7 @@ pub struct AblaufschemaElement { pub end_element_guid: String, } +#[allow(clippy::struct_field_names)] #[derive(Debug, Deserialize, Serialize)] pub struct Akte { #[serde(rename = "Name")] @@ -152,6 +154,7 @@ pub struct AkteRolle { pub modul_berechtigung: Vec, } +#[allow(clippy::struct_field_names)] #[derive(Debug, Deserialize, Serialize)] pub struct RecordLinkage { #[serde(rename = "ID")] @@ -262,6 +265,7 @@ pub struct Modul { pub aufgabenliste_aktiv: Option, } +#[allow(clippy::struct_excessive_bools)] #[derive(Debug, Deserialize, Serialize)] pub struct ModulBerechtigung { #[serde(rename = "ModulName")] @@ -287,6 +291,8 @@ pub struct ModulFormular { pub guid: String, } +#[allow(clippy::struct_excessive_bools)] +#[allow(clippy::struct_field_names)] #[derive(Serialize, Deserialize, Debug)] #[serde(deny_unknown_fields)] pub struct Entry { diff --git a/src/model/property_catalogue.rs b/src/model/property_catalogue.rs index d8310ff..2f4a926 100644 --- a/src/model/property_catalogue.rs +++ b/src/model/property_catalogue.rs @@ -105,6 +105,7 @@ pub struct Versions { entry: Option>, } +#[allow(clippy::struct_field_names)] #[derive(Serialize, Deserialize, Debug)] #[serde(deny_unknown_fields)] pub struct Version { @@ -219,6 +220,7 @@ pub struct Categories { content: Vec, } +#[allow(clippy::struct_field_names)] #[derive(Serialize, Deserialize, Debug)] #[serde(deny_unknown_fields)] pub struct Category { diff --git a/src/profile.rs b/src/profile.rs index 9b5d8ed..a95eb20 100644 --- a/src/profile.rs +++ b/src/profile.rs @@ -56,6 +56,7 @@ impl FromStr for Profile { } } +#[allow(clippy::struct_field_names)] #[derive(Deserialize)] pub struct Form { pub name: String,