/**
* Campagne.js
*
* @description :: TODO: You might write a short summary of how this model works and what it represents here.
* @docs        :: http://sailsjs.org/#!documentation/models
*/

module.exports = {

  attributes: {

    name: {
      type: 'string',
      required: true
    },

    dateSend: {
      type: 'date'
    },

    groups: {
      collection: 'group',
      via: 'campaigns'
    }

  }
};


/**
* Campagne.js
*
* @description :: TODO: You might write a short summary of how this model works and what it represents here.
* @docs        :: http://sailsjs.org/#!documentation/models
*/

module.exports = {

  attributes: {

    name: {
      type: 'string',
      required: true
    },

    dateSend: {
      type: 'date'
    },

    message: {
      type: 'string',
      size: 140,
      required: true
    },

    groups: {
      collection: 'group',
      via: 'campaigns'
    }

  }
};


Add attribute message for model campaign
Add attribute message for model campaign
