Invoice.js 277 B

123456789
  1. const mongoose = require('mongoose');
  2. const invoiceSchema = new mongoose.Schema({
  3. client: { type: String, required: true },
  4. dueDate: { type: Date, required: true },
  5. paid: { type: Boolean, default: false },
  6. });
  7. module.exports = mongoose.model('Invoice', invoiceSchema);