/**
 * Documentation.js
 *
 * @description :: A model definition represents a database table/collection.
 * @docs        :: https://sailsjs.com/docs/concepts/models-and-orm/models
 */

module.exports = {

  attributes: {

    //  ╔═╗╦═╗╦╔╦╗╦╔╦╗╦╦  ╦╔═╗╔═╗
    //  ╠═╝╠╦╝║║║║║ ║ ║╚╗╔╝║╣ ╚═╗
    //  ╩  ╩╚═╩╩ ╩╩ ╩ ╩ ╚╝ ╚═╝╚═╝

    name: {
      type: 'string', description: 'The name of the document.', required: true
    },

    fileExtension: {
      type: 'string', description: 'The file extension of the document.', required: true
    },

    fileUrl: {
      type: 'string', description: 'The URL where the document can be accessed.', required: true
    },

    blob: {
      type: 'ref', columnType: 'blob', required: true
    },

    height: {
      type: 'number', description: 'The height of the document.'
    },

    weight: {
      type: 'number', description: 'The weight of the document.'
    },

    //  ╔═╗╔╦╗╔╗ ╔═╗╔╦╗╔═╗
    //  ║╣ ║║║╠╩╗║╣  ║║╚═╗
    //  ╚═╝╩ ╩╚═╝╚═╝═╩╝╚═╝


    //  ╔═╗╔═╗╔═╗╔═╗╔═╗╦╔═╗╔╦╗╦╔═╗╔╗╔╔═╗
    //  ╠═╣╚═╗╚═╗║ ║║  ║╠═╣ ║ ║║ ║║║║╚═╗
    //  ╩ ╩╚═╝╚═╝╚═╝╚═╝╩╩ ╩ ╩ ╩╚═╝╝╚╝╚═╝

    financial: {
      model: `Financial`
    }

  },

  tableName: `finacialdocumentEclesia`

};

