14 lines
379 B
TypeScript
14 lines
379 B
TypeScript
import { Schema, model } from "mongoose";
|
|
|
|
import { IContract } from "./Abstraction/IContract";
|
|
|
|
const ContractSchema = new Schema<IContract>(
|
|
{
|
|
content: { type: String, required: true },
|
|
},
|
|
{ timestamps: true, toJSON: { virtuals: true, versionKey: false }, id: false },
|
|
);
|
|
const ContractModel = model<IContract>("Contract", ContractSchema);
|
|
|
|
export { ContractModel };
|