mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-21 20:47:08 -05:00
Merge pull request #23 from sharelatex/add-mysql-indexes
add indexes to mysql db
This commit is contained in:
commit
3dec42be2a
1 changed files with 10 additions and 1 deletions
|
@ -16,11 +16,20 @@ module.exports =
|
|||
url: Sequelize.STRING
|
||||
project_id: Sequelize.STRING
|
||||
lastModified: Sequelize.DATE
|
||||
}, {
|
||||
indexes: [
|
||||
{fields: ['url', 'project_id']},
|
||||
{fields: ['project_id']}
|
||||
]
|
||||
})
|
||||
|
||||
Project: sequelize.define("Project", {
|
||||
project_id: Sequelize.STRING
|
||||
project_id: {type: Sequelize.STRING, primaryKey: true}
|
||||
lastAccessed: Sequelize.DATE
|
||||
}, {
|
||||
indexes: [
|
||||
{fields: ['lastAccessed']}
|
||||
]
|
||||
})
|
||||
|
||||
sync: () -> sequelize.sync()
|
||||
|
|
Loading…
Reference in a new issue