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


module.exports = {
    tableName: 'eleves',

    attributes: {
       /* id: {
        type: 'number',
        //columnName: 'id',
        unique: true,
        autoIncrement: true,
        primaryKey: true,
        //required: true,
        columnType: 'integer',
    },*/
        matricule: {
            type: 'string',
            columnName: 'matricule',
            required: true,

        },
        nom: {
            type: 'string',
            columnName: 'nom',
            required: true,

        },
        prenom: {
            type: 'string',
            columnName: 'prenom',
            allowNull: true

        },
        sexe: {
            type: 'string',
            columnName: 'sexe',
            allowNull: true
        },
        dateNaissance: {
            type: 'string',
            columnName: 'date_naissance',
            //columnType:'datetime',
            //allowNull: true

        },
        lieuNaissance: {
            type: 'string',
            columnName: 'lieu_naissance',
            allowNull: true

        },
        indicatif: {
            type: 'string',
            columnName: 'indicatif',
            allowNull: true,
            //columnType: 'bigint'


        },
        telephone: {
            type: 'string',
            columnName: 'telephone',
            allowNull: true,
            //columnType: 'bigint'


        },
        email: {
            type: 'string',
            columnName: 'email',
            allowNull: true

        },
        codeEcole: {
            type: 'string',
            columnName: 'code_ecole',
            required: true,

        }, 

      
    },

};

