Skip to content

Backend - News model #145

@minhngo3818

Description

@minhngo3818

Create a Mongoose data model for news

Collection name: news
Schema object name: newsSchema

Directory: root/backend/models/news/*, add news-model.js file

For reference, see tags-model.js

Fields:

  • title: string
  • detail: string
  • created_at: Date, immutable, use the current time as the default value
  • updated_at: Date, use the current time as the default value

Metadata

Metadata

Labels

Backendtask relates to backendData Modeldata model tasksGood First IssueEasy tasks for first timers

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions