Foundry and discord bot
All checks were successful
Build and Deploy Nuxt / build (push) Successful in 1m51s

This commit is contained in:
2026-10-11 22:26:29 +02:00
parent a2b512699a
commit 1402045001
65 changed files with 5962 additions and 144 deletions

View File

@@ -0,0 +1,28 @@
const mongoose = require('mongoose');
const Schema = mongoose.Schema;
const ItemSchema = new Schema({
name: { type: String, required: true, trim: true },
category: {
type: String,
enum: ['weapon', 'armor', 'shield', 'adventuring-gear', 'magic-item', 'consumable', 'tool', 'treasure', 'other'],
default: 'adventuring-gear'
},
rarity: {
type: String,
enum: ['common', 'uncommon', 'rare', 'very-rare', 'legendary', 'artifact'],
default: 'common'
},
quantity: { type: Number, min: 1, default: 1 },
weight: { type: Number, min: 0 },
properties: { type: String, default: '' },
description: { type: String, default: '' },
campaign: {
type: Schema.Types.ObjectId,
ref: 'Campaign',
required: true
},
date: { type: Date, default: Date.now }
});
module.exports = mongoose.model('Item', ItemSchema);