const Sequelize = require("sequelize");
const db = require("../../db");

module.exports = db.sequelize.define("lists", {
  id: {
    type: Sequelize.INTEGER,
    primaryKey: true,
    autoIncrement: true
  },
  name: {
    type: Sequelize.STRING
  },
  price: {
    type: Sequelize.INTEGER
  },
  time: {
    type: Sequelize.INTEGER
  },
  shop: {
    type: Sequelize.INTEGER,
    references: 'shops',
    referencesKey: 'id'

  },
  userId:{
    type: Sequelize.INTEGER,
    references: 'users',
    referencesKey: 'id'
  }
});
