Outils pour utilisateurs

Outils du site


web:javascript:nodejs:db-migrate

db-migrate

Dans la table Projects:

    portfolioId: {
      type: 'string',
      foreignKey: {
        name: 'project_portfolio_id_fk',
        table: 'portfolios',
        mapping: 'id',
        rules: {
          onDelete: 'CASCADE'
        },
      }
    },
    updatedAt: {
      type: 'timestamp',
      defaultValue: new String('CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP')
    },
    createdAt: {
      type: 'timestamp',
      defaultValue: new String('CURRENT_TIMESTAMP')
    }
web/javascript/nodejs/db-migrate.txt · Dernière modification : 2022/02/02 00:42 de 127.0.0.1