welcome_setting.js 662 B

1234567891011121314151617181920212223242526
  1. /**
  2. * Created by zhang on 2020/2/14.
  3. */
  4. let mongoose = require("mongoose");
  5. let Schema = mongoose.Schema;
  6. let collectionName = 'welcome_setting';
  7. let modelSchema = {
  8. // ID
  9. ID: {
  10. type: String,
  11. index: true
  12. },
  13. compilationId: String,
  14. normal:{
  15. showType:{type:Number,default:0},// 1 每天一次 2 每次登录显示,0 关闭
  16. context:String
  17. },
  18. // 专业用户
  19. professional: {
  20. showType:{type:Number,default:0},// 1 每天一次 2 每次登录显示,0 关闭
  21. context:String
  22. }
  23. };
  24. mongoose.model(collectionName, new Schema(modelSchema, {versionKey: false, collection: collectionName}));