diff --git a/src/controllers/games/gift.js b/src/controllers/games/gift.js index 5b4186b..be6e6c1 100644 --- a/src/controllers/games/gift.js +++ b/src/controllers/games/gift.js @@ -145,6 +145,7 @@ router.post('/list', async (req, res, next) => { type: body.type, time: body.time, cfg: cfg, + extraData: body.extraData }) const result = await list.save() res.send({ @@ -183,6 +184,7 @@ router.put('/list', async (req, res, next) => { type: body.type, time: body.time, cfg: cfg, + extraData: body.extraData } ) res.send({ diff --git a/src/models/admin/GameGift.js b/src/models/admin/GameGift.js index a4808f2..047aa9f 100644 --- a/src/models/admin/GameGift.js +++ b/src/models/admin/GameGift.js @@ -38,6 +38,7 @@ const GiftListSchema = new mongoose.Schema( time: {type: String}, // 填写的发放配置 cfg: {type: Array, default: []}, // 生成的配置 deleted: {type: Boolean, default: false}, + extraData: {type: String, default: ''} //用于扩展 }, { collection: 'gift_list',