kba / models /Asset.js
ShieldX's picture
Upload 24 files
e14bacb verified
raw
history blame contribute delete
601 Bytes
const mongoose = require('mongoose');
const assetSchema = new mongoose.Schema({
owner_id: { type: mongoose.Schema.Types.ObjectId, ref: 'User' },
kus_id: { type: String, unique: true }, // The KoshX Unique Serial (e.g., AG171225W0000001)
tier: { type: String, enum: ['Silver', 'Gold', 'Platinum'], required: true },
purchase_date: { type: Date, default: Date.now },
status: { type: String, enum: ['Pending', 'Held', 'Liquidated', 'Burned'], default: 'Pending' },
hash: { type: String } // Cryptographic signature for premium feel
});
module.exports = mongoose.model('Asset', assetSchema);