aboutsummaryrefslogtreecommitdiffstats
path: root/models
diff options
context:
space:
mode:
Diffstat (limited to 'models')
-rw-r--r--models/transaction.js17
1 files changed, 17 insertions, 0 deletions
diff --git a/models/transaction.js b/models/transaction.js
new file mode 100644
index 00000000..f4b696a7
--- /dev/null
+++ b/models/transaction.js
@@ -0,0 +1,17 @@
+'use strict';
+module.exports = (sequelize, DataTypes) => {
+ var Transaction = sequelize.define('Transaction', {
+ hash: DataTypes.STRING,
+ address: DataTypes.STRING,
+ date: DataTypes.DATE,
+ amount: DataTypes.FLOAT,
+ rate: DataTypes.FLOAT
+ }, {
+ classMethods: {
+ associate: function(models) {
+ // associations can be defined here
+ }
+ }
+ });
+ return Transaction;
+}; \ No newline at end of file