add notes
This commit is contained in:
@ -11,11 +11,18 @@ impl User {
|
||||
&self,
|
||||
db: &SqlitePool,
|
||||
updated_by: &ManageUserUser,
|
||||
user: &User,
|
||||
note: &str,
|
||||
) -> Result<(), String> {
|
||||
let note = note.trim();
|
||||
|
||||
Activity::create(db, note, "relevant_for", None).await;
|
||||
Activity::create(
|
||||
db,
|
||||
&format!("({updated_by}) {note}"),
|
||||
&format!("user-{};", user.id),
|
||||
None,
|
||||
)
|
||||
.await;
|
||||
|
||||
Ok(())
|
||||
}
|
||||
|
Reference in New Issue
Block a user