|
@@ -6,7 +6,7 @@ const metaPlugin = require('naf-framework-mongoose-free/lib/model/meta-plugin');
|
|
const userCoupon = {
|
|
const userCoupon = {
|
|
customer: { type: String, required: false, zh: '顾客', ref: 'User.User' }, //
|
|
customer: { type: String, required: false, zh: '顾客', ref: 'User.User' }, //
|
|
shop: { type: String, required: false, zh: '发行店铺', ref: 'Shop.Shop' }, //
|
|
shop: { type: String, required: false, zh: '发行店铺', ref: 'Shop.Shop' }, //
|
|
- coupon: { type: String, required: false, zh: '优惠券' }, //
|
|
|
|
|
|
+ coupon: { type: Object, required: false, zh: '优惠券' }, //
|
|
status: { type: String, required: false, default: '0', zh: '是否使用' }, //
|
|
status: { type: String, required: false, default: '0', zh: '是否使用' }, //
|
|
};
|
|
};
|
|
const schema = new Schema(userCoupon, { toJSON: { getters: true, virtuals: true } });
|
|
const schema = new Schema(userCoupon, { toJSON: { getters: true, virtuals: true } });
|