您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

123456789101112131415161718
  1. const Schwifty = require('@hapipal/schwifty')
  2. const Joi = require('joi')
  3. const config = require('../../db/data-generator/config.json')
  4. const aspects = { aspect_id: Joi.number() }
  5. const possible_combinations = Math.pow(config.scoreVals.length, 2)
  6. for(let i = 1; i <= possible_combinations; i++) {
  7. aspects[i] = Joi.number()
  8. }
  9. module.exports = class Aspect extends Schwifty.Model {
  10. static get tableName() {
  11. return 'prescored_aspects'
  12. }
  13. static get joiSchema() {
  14. return Joi.object(aspects)
  15. }
  16. }