From fe1f12c3b24df17cee00d91463fab8d1f85603da Mon Sep 17 00:00:00 2001 From: DarkCat09 Date: Fri, 3 Mar 2023 14:27:20 +0400 Subject: [PATCH] Readme: padding in "Note" section --- README.md | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index d8c8e1b..2b3506a 100644 --- a/README.md +++ b/README.md @@ -102,6 +102,7 @@ You can copying the contents of `pages.py` > **Note** +> > In the paths files, FastAPI's decorators are called with `@self.app.`, not just `@app.` @@ -154,12 +155,13 @@ and can be deleted or edited, except: are stored in `app/sql/crud.py` > **Note** +> > As the official FastAPI documentation recommends (the link is above), -there are two schemas — `User` and `UserCreate` — for one `User` SQLAlchemy model. +there are two schemas — `User` and `UserCreate` — for one `User` SQLAlchemy model. > The first one is needed for SELECT requests, -and the second one is for INSERT requests (creating users). +and the second one is for INSERT requests (creating users). > The first one contains all information about user, -but the second one (`UserCreate`) ommits `id` field, +but the second one (`UserCreate`) ommits `id` field, because we don't want to specify an ID when creating a new user, it will be generated automatically by the MariaDB server.