Refactoring gruppe und rolle

This commit is contained in:
2026-05-28 20:24:27 +02:00
parent 52c0991545
commit 6810196226
20 changed files with 176 additions and 20 deletions

View File

@@ -0,0 +1,21 @@
use super::Service;
use anyhow::Error;
use crate::domain::rolle::{
entity,
model::{self, RolleLoeschenInput},
};
impl Service {
pub async fn rolle_loeschen(&self, input: RolleLoeschenInput) -> Result<model::Rolle, Error> {
let rolle_input = entity::Rolle {
id: input.id,
rollenname: String::new(),
erstellt_am: None,
geaendert_am: None,
};
let deleted = self.repo.rolle_loeschen(&self.db, &rolle_input).await?;
Ok(deleted)
}
}