2 var moment = require('moment');
4 module.exports = function(sequelize, DataTypes) {
5 var VoiceRecording = sequelize.define('VoiceRecording', {
7 type: DataTypes.STRING,
11 type: DataTypes.STRING
14 type: DataTypes.STRING
17 type: DataTypes.STRING
20 type: DataTypes.STRING
23 type: DataTypes.STRING
26 type: DataTypes.STRING
29 type: DataTypes.STRING
32 type: DataTypes.STRING
35 type: DataTypes.STRING
38 type: DataTypes.STRING
41 type: DataTypes.STRING
44 type: DataTypes.INTEGER,
54 // 'this' allows you to access attributes of the instance
55 return moment(this.getDataValue('agentconnectAt')).format("MM-DD-YYYY HH:mm");
61 // 'this' allows you to access attributes of the instance
62 return moment(this.getDataValue('agentconnectAt')).format("MM-DD-YYYY HH:mm");
66 tableName: 'voice_recordings',
67 associate: function(models) {
68 // VoiceRecording.belongsTo(models.ReportCall, {
69 // foreignKey: 'uniqueid'
74 return VoiceRecording;