Commit a7bab3b2190833282dd2b5d05d251cc35145ff05
1 parent
b5e2548f7d
Exists in
master
v0.14.2
Showing
3 changed files
with
37 additions
and
36 deletions
Show diff stats
knexfile.ejemplo.js
1 | // Update with your config settings. | File was deleted | |
2 | |||
3 | module.exports = { | ||
4 | |||
5 | estacion: { | ||
6 | client: 'msslq', | ||
7 | connection: { | ||
8 | host: 'iphost', | ||
9 | database: 'my_db', | ||
10 | user: 'username', | ||
11 | password: 'password' | ||
12 | } | ||
13 | } | ||
14 | }; | ||
15 | 1 | // Update with your config settings. |
migrations/20191003120035_v0.14.2.js
File was created | 1 | exports.up = function(knex) { | |
2 | return knex.schema | ||
3 | .createTable('orden_carga', function(table) { | ||
4 | table.increments(); | ||
5 | table.bigInteger('idHojaRuta'); | ||
6 | table.bigInteger('idCisterna'); | ||
7 | table.decimal('cantidadACargar', 12, 2); | ||
8 | table.integer('estado'); | ||
9 | }) | ||
10 | }; | ||
11 | |||
12 | exports.down = function(knex) { | ||
13 | return knex.schema | ||
14 | .dropTable('orden_carga') | ||
15 | }; |
package.json
1 | { | 1 | { |
2 | "name": "backoffice", | 2 | "name": "backoffice", |
3 | "version": "1.0.0", | 3 | "version": "1.0.0", |
4 | "description": "Paquetes de migraciones", | 4 | "description": "Paquetes de migraciones", |
5 | "main": "knexfile.js", | 5 | "main": "knexfile.js", |
6 | "dependencies": { | 6 | "dependencies": { |
7 | "bluebird": "^3.5.5", | 7 | "bluebird": "^3.5.5", |
8 | "knex": "^0.18.3", | 8 | "knex": "^0.18.3", |
9 | "md5": "^2.2.1", | 9 | "md5": "^2.2.1", |
10 | "mssql": "^5.1.0" | 10 | "mssql": "^5.1.0" |
11 | }, | 11 | }, |
12 | "devDependencies": {}, | 12 | "devDependencies": {}, |
13 | "scripts": { | 13 | "scripts": { |
14 | "test": "echo \"Error: no test specified\" && exit 1", | 14 | "test": "echo \"Error: no test specified\" && exit 1", |
15 | "init": "npm install -g knex && npm install && knex init" | 15 | "init": "npm install -g knex && npm install && knex init" |
16 | }, | 16 | }, |
17 | "repository": { | 17 | "repository": { |
18 | "type": "git", | 18 | "type": "git", |
19 | "url": "http://git.focasoftware.com/deploy/backoffice.git" | 19 | "url": "http://git.focasoftware.com/deploy/backoffice.git" |
20 | }, | 20 | }, |
21 | "author": "Foca Software", | 21 | "author": "Foca Software", |
22 | "license": "ISC" | 22 | "license": "ISC" |
23 | } | 23 | } |
24 |