27 lines
477 B
JavaScript
27 lines
477 B
JavaScript
const { model } = require("mongoose");
|
|
const { Schema } = require("mongoose");
|
|
|
|
const ShafafSchema = Schema(
|
|
{
|
|
title: { type: String },
|
|
icon: { type: String },
|
|
content: { type: String },
|
|
attachment: { type: String },
|
|
},
|
|
{
|
|
timestamps: true,
|
|
}
|
|
);
|
|
|
|
const ShafafCategory = Schema(
|
|
{},
|
|
{
|
|
timestamps: true,
|
|
}
|
|
);
|
|
|
|
module.exports = {
|
|
ShafafModel: model("Shafaf", ShafafSchema),
|
|
ShafafCategoryModel: model("ShafafCategory", ShafafCategory),
|
|
};
|