Ist es in Sailsjs möglich, komplexere Modelle zu bauen?

Ich möchte Arrays oder Sammlungen in meinem Modell haben. Ist dies mit waterline (mongoDB) noch möglich? Gibt es Alternativen?

Beispiel:

{
   name: Bundle,
   col1 : {
      name : anOtherModel,
      subCol: {
         text: aString,
         ...
      }
   },
   col2 : {
      name : anOtherModel,
      subCol: {
         text: aString,
         ...
      }
   }
}

zu:

module.exports = {

    attributes : {

        name : {
            type : 'STRING',
            required : true
        },
        basicModules: {
            type : 'ARRAY', // or 'COLLECTION'
            required : false
        }
    }

};

Antworten auf die Frage(2)

Ihre Antwort auf die Frage