Logo
Explore Help
Sign In
wcrisman/PetitTeton
1
0
Fork 0
You've already forked PetitTeton
Code Issues Pull Requests Actions Packages Projects Releases Wiki Activity
Files
00f2be30cee2f40e084c2a03ed99e1e86a8eec1f
PetitTeton/migrations/20160602030144-UserIndex.js

14 lines
280 B
JavaScript
Raw Normal View History

Merged PetitTeton webapp with the inventory tracking app; Moved the database configuration out of git and added an example configuration; Added migrations to the mix so that we can easily update the production database and roll back changes to the database (from the command line install migrations [may not be necessary?]: npm install -g sequelize-cli To update the database after updating the app from git (on the command line in the webapp base directory): sequelize db:migrate To undo the last migrations: sequelize db:migrate:undo
2016-06-13 11:54:12 -07:00
'use strict';
module.exports = {
up: function (query, Sequelize) {
var DataTypes = Sequelize; //Allow for more cut and paste :)
return query.addIndex('User', ['login'], {indicesType: 'UNIQUE', indexName: 'LOGIN_INDEX'});
},
down: function (query, Sequelize) {
}
};
Reference in New Issue Copy Permalink
Powered by Gitea Version: 1.25.0 Page: 40ms Template: 2ms
English
Bahasa Indonesia Deutsch English Español Français Gaeilge Italiano Latviešu Magyar nyelv Nederlands Polski Português de Portugal Português do Brasil Suomi Svenska Türkçe Čeština Ελληνικά Български Русский Українська فارسی മലയാളം 日本語 简体中文 繁體中文(台灣) 繁體中文(香港) 한국어
Licenses API