summaryrefslogtreecommitdiff
path: root/models/result.js
diff options
context:
space:
mode:
Diffstat (limited to 'models/result.js')
-rw-r--r--models/result.js41
1 files changed, 41 insertions, 0 deletions
diff --git a/models/result.js b/models/result.js
new file mode 100644
index 0000000..f7c5f8c
--- /dev/null
+++ b/models/result.js
@@ -0,0 +1,41 @@
+/* jshint indent: 2 */
+
+module.exports = function(sequelize, DataTypes) {
+ return sequelize.define('result', {
+ id: {
+ type: DataTypes.INTEGER(10).UNSIGNED,
+ allowNull: false,
+ primaryKey: true,
+ autoIncrement: true
+ },
+ api_id: {
+ type: DataTypes.STRING(191),
+ allowNull: true
+ },
+ event_id: {
+ type: DataTypes.INTEGER(11),
+ allowNull: false
+ },
+ match_api_id: {
+ type: DataTypes.CHAR(36),
+ allowNull: false
+ },
+ shard_id: {
+ type: DataTypes.CHAR(36),
+ allowNull: false
+ },
+ sequence: {
+ type: DataTypes.INTEGER(3).UNSIGNED,
+ allowNull: true
+ },
+ winner_id: {
+ type: DataTypes.INTEGER(11),
+ allowNull: true
+ }
+ }, {
+ tableName: 'result',
+ timestamps: false,
+ underscored: true,
+ freezeTableName: true
+ });
+};