Built motion from commit 4500188.|0.0.141
authorDaniele Cinti <daniele.cinti@xcally.com>
Wed, 14 Sep 2016 15:22:07 +0000 (17:22 +0200)
committerDaniele Cinti <daniele.cinti@xcally.com>
Wed, 14 Sep 2016 15:22:07 +0000 (17:22 +0200)
release-notes/changelog_0.0.141.txt
server/config/ami/action.js
server/config/triggers/index.js

index 513bf82..0705d04 100644 (file)
@@ -1,5 +1,7 @@
 # xCALLY MOTION Changelog
 
+- * 4500188 - 2016-09-14: server config action update 
+- * e5a579d - 2016-09-14: Fixed triggers 
 - * 6436f3a - 2016-09-14: server side config ami update 
 - * 1dd0700 - 2016-09-14: Fixed trunk update 
 - * 23c99a5 - 2016-09-14: Fixed triggers 
index 9d9c1a8..205a934 100644 (file)
@@ -21,28 +21,7 @@ function Action(ami, io) {
   var channels = ['voice', 'chat', 'mail', 'fax', 'sms', 'openchannel'];
 
   Agent.afterUpdate(function(doc, options) {
-    io.to(util.format('%s:%s', doc.role, doc.id)).emit('agent:save', {
-      id: doc.id,
-      name: doc.name,
-      online: doc.online,
-      queueStatus: doc.queueStatus,
-      queueStatusAt: doc.queueStatusAt,
-      voicePause: doc.voicePause,
-      chatPause: doc.chatPause,
-      mailPause: doc.mailPause,
-      faxPause: doc.faxPause,
-      smsPause: doc.smsPause,
-      openchannelPause: doc.openchannelPause,
-      lastPauseAt: doc.lastPauseAt,
-      phoneBarEnableSettings: doc.phoneBarEnableSettings,
-      phoneBarAutoAnswer: doc.phoneBarAutoAnswer,
-      phoneBarUnconditional: doc.phoneBarUnconditional,
-      phoneBarUnconditionalNumber: doc.phoneBarUnconditionalNumber,
-      phoneBarNoReply: doc.phoneBarNoReply,
-      phoneBarNoReplyNumber: doc.phoneBarNoReplyNumber,
-      phoneBarBusy: doc.phoneBarBusy,
-      phoneBarBusyNumber: doc.phoneBarBusyNumber
-    });
+    io.to(util.format('%s:%s', doc.role, doc.id)).emit('agent:save', doc);
   });
 
   process.on('message', function(data) {
index 9b9a1c8..ad2004f 100644 (file)
@@ -103,7 +103,7 @@ module.exports = function(cpAmi) {
             execActions(actions, data, 'voice', 'queue', util, voice, mail, cm, jscripty, integration, urlForward);
             break;
           case 'ReportAgent.afterUpdate':
-            if (data.changed('lastevent')) {
+            if (data.changed.lastevent) {
               actions = util.getActionsByTriggers(data, _.filter(_triggers, {
                 channel: 'voice'
               }));