feat(notes): accept and return description field through service and routes
create_note service accepts a new description kwarg and forwards it to the Note constructor. PUT/PATCH/POST routes include description in the field whitelist. update_note already passed **fields through setattr, so the new column is reachable without touching that signature.
This commit is contained in:
@@ -76,6 +76,7 @@ async def create_note(
|
||||
user_id: int,
|
||||
title: str = "",
|
||||
body: str = "",
|
||||
description: str | None = None,
|
||||
tags: list[str] | None = None,
|
||||
parent_id: int | None = None,
|
||||
project_id: int | None = None,
|
||||
@@ -103,6 +104,7 @@ async def create_note(
|
||||
user_id=user_id,
|
||||
title=title,
|
||||
body=body,
|
||||
description=description,
|
||||
tags=_normalize_tags(tags or []),
|
||||
parent_id=parent_id,
|
||||
project_id=project_id,
|
||||
|
||||
Reference in New Issue
Block a user