1 | 'use strict';
|
2 |
|
3 | var dbm;
|
4 | var type;
|
5 | var seed;
|
6 |
|
7 |
|
8 |
|
9 |
|
10 |
|
11 | exports.setup = function(options, seedLink) {
|
12 | dbm = options.dbmigrate;
|
13 | type = dbm.dataType;
|
14 | seed = seedLink;
|
15 | };
|
16 |
|
17 | exports.up = function(db) {
|
18 | return db.createTable('ally_object', {
|
19 | id: { type: 'int', autoIncrement: true, primaryKey: true},
|
20 | experience: {type: 'int', defaultValue: 0},
|
21 | uid: {type: 'int', defaultValue: 0},
|
22 | Name: {type: 'string', length: 50},
|
23 | Energy: {type: 'int', defaultValue: 0},
|
24 | Target: {type: 'int', defaultValue: 0},
|
25 | BattleGrade: {type: 'int', defaultValue: 0},
|
26 | aSetting: {type: 'int', defaultValue: 0},
|
27 | Users: {type: 'string', length:8000},
|
28 | sloganInner: {type: 'string', length: 500},
|
29 | sloganOuter: {type: 'string', length: 500}
|
30 | });
|
31 | };
|
32 |
|
33 | exports.down = function(db) {
|
34 | return db.dropTable('ally_object').then(
|
35 | function(result) {
|
36 | },
|
37 | function(err) {
|
38 | }
|
39 | );
|
40 | };
|
41 |
|
42 | exports._meta = {
|
43 | "version": 1
|
44 | };
|