This is a learn project about book blog.
- Node js
- Mongodb
- POST /auth/login
- POST /auth/register / TEMP
-
GET /admin/contents Get all contents
-
GET /admin/contents/:content_id Get content by id
-
POST /admin/contents/ Create new content
-
DELETE /admin/contents/:content_id Delete content by id
-
PATCH /admin/contents/:content_id Update content by id
-
POST /admin/contents/sections/:content_id Create new section
-
GET /admin/contents/sections/:section_id Get section by id
-
DELETE /admin/contents/sections/:content_id Delete section
-
PATCH /admin/contents/sections/:section_id Update section
- GET /contents Get all published contents
- GET /contents/:content_id Get content by id
- GET /sections/:section_id Get section by id //Note: paginate content field by word
{
"_id": "61fac67094a24ed5485ef730",
"title": "Selam",
"desc": "<p>Selam</p>",
"published": false,
"sections": [
{
"title": "Bolum 1",
"content:"<p>blabla</p>",
"published": false,
"_id": "61fac67094a24ed5485ef72e",
"createdAt": "2022-02-02T17:59:12.207Z",
"updatedAt": "2022-02-02T17:59:12.207Z"
}
],
"createdAt": "2022-02-02T17:59:12.207Z",
"updatedAt": "2022-02-02T17:59:12.207Z"
}
- Her içerik yaratılırken 1 adet bölümü olucak
- Her bölüm oluştuğunda bir adet sayfası olucak
- Her sayfaya kelime limiti konucak
- Yeni sayfa oluşturmak için butona basılıcak
- Errorları logger ile handle et
- Sectionlar kendi içinde update olcak
- Her section oluştuğunda yeni sayfa eklencek
- Delete conntected sections with content