Built motion from commit 1038d87.|0.0.141
[motion.git] / server / models / square_project.js
index 1aa07c0..7834e00 100644 (file)
@@ -1 +1,31 @@
-var _0x21d4=["\x75\x73\x65\x20\x73\x74\x72\x69\x63\x74","\x65\x78\x70\x6F\x72\x74\x73","\x53\x71\x75\x61\x72\x65\x50\x72\x6F\x6A\x65\x63\x74","\x53\x54\x52\x49\x4E\x47","\x54\x45\x58\x54","\x6C\x6F\x6E\x67","\x73\x71\x75\x61\x72\x65\x5F\x70\x72\x6F\x6A\x65\x63\x74\x73","\x64\x65\x66\x69\x6E\x65"];_0x21d4[0];module[_0x21d4[1]]=function(_0xb608x1,_0xb608x2){var _0xb608x3=_0xb608x1[_0x21d4[7]](_0x21d4[2],{name:{type:_0xb608x2[_0x21d4[3]],unique:true,validate:{notEmpty:true}},description:_0xb608x2[_0x21d4[3]],preproduction:{type:_0xb608x2[_0x21d4[4]],length:_0x21d4[5]},production:{type:_0xb608x2[_0x21d4[4]],length:_0x21d4[5]}},{tableName:_0x21d4[6]});return _0xb608x3;};
\ No newline at end of file
+'use strict';
+
+
+module.exports = function(sequelize, DataTypes) {
+
+  var SquareProject = sequelize.define('SquareProject', {
+    name: {
+      type: DataTypes.STRING,
+      unique: true,
+      allowNull: false,
+      validate: {
+        notEmpty: true
+      }
+    },
+    description: DataTypes.STRING,
+    notes: DataTypes.TEXT,
+    preproduction: {
+      type: DataTypes.TEXT,
+      length: 'long'
+    },
+    production: {
+      type: DataTypes.TEXT,
+      length: 'long'
+    }
+  }, {
+    tableName: 'square_projects'
+  });
+
+  return SquareProject;
+
+};