somewhere

This commit is contained in:
Swift
2023-08-17 13:05:51 +03:30
parent 30c7eb0e7b
commit 53843207cc
429 changed files with 117489 additions and 1 deletions
+42
View File
@@ -0,0 +1,42 @@
const mongoose = require('mongoose')
const GuaranteeReportSchema = mongoose.Schema({
// system structure
_openedBy: { type: mongoose.ObjectId, ref: 'User' },
_updatedBy: { type: mongoose.ObjectId, ref: 'User' },
user_id: { type: mongoose.ObjectId, ref: 'User' },
agent_id: { type: mongoose.ObjectId, ref: 'Representation' },
// form info
description: String,
createDate: String,
sendDate: String,
trackingCode: String,
items: [
{
// customer info
customerName: String,
customerTel: String,
// product info
ItemName: String,
SerialNo1: String,
ItemID: String,
ItemCode: String,
// product issue
productIssue: String,
usedPieces: String,
// dates
recieveDate: String,
deliverDate: String
}
],
// admin operations
seen: { type: Boolean, default: false },
archived: { type: Boolean, default: false },
status: { type: String, enum: ['temp', 'sent'], default: 'temp' }
})
module.exports = mongoose.model('GuaranteeReport', GuaranteeReportSchema)