if (storage.data.videoCall) {
$scope.callTemplate = 'partials/video_call.html';
}
+
+ $rootScope.$on('call.conference', function(event, data) {
+ $timeout(function() {
+ if($scope.chatStatus) {
+ $scope.openChat();
+ }
+ });
+ });
$rootScope.$on('call.video', function(event, data) {
$timeout(function() {
}
]);
-})();
\ No newline at end of file
+})();
$scope.verto = verto;
$scope.storage = storage;
$scope.call_history = angular.element("#call_history").hasClass('active');
- $scope.chatStatus = angular.element('#wrapper').hasClass('toggled');
+ $rootScope.chatStatus = angular.element('#wrapper').hasClass('toggled');
/**
* (explanation) scope in another controller extends rootScope (singleton)
};
$scope.toggleChat = function() {
- if ($scope.chatStatus && $rootScope.activePane === 'chat') {
+ if ($rootScope.chatStatus && $rootScope.activePane === 'chat') {
$rootScope.chat_counter = 0;
}
angular.element('#wrapper').toggleClass('toggled');
- $scope.chatStatus = angular.element('#wrapper').hasClass('toggled');
+ $rootScope.chatStatus = angular.element('#wrapper').hasClass('toggled');
};
- $scope.openChat = function() {
- $scope.chatStatus = false;
+ $rootScope.openChat = function() {
+ $rootScope.chatStatus = false;
angular.element('#wrapper').removeClass('toggled');
};
$scope.closeChat = function() {
- $scope.chatStatus = true;
+ $rootScope.chatStatus = true;
angular.element('#wrapper').addClass('toggled');
};
Fullscreen.cancel();
}
-
- console.log($scope.chatStatus);
- if (!$scope.chatStatus) {
+ if (!$rootScope.chatStatus) {
angular.element('#wrapper').toggleClass('toggled');
- $scope.chatStatus = angular.element('#wrapper').hasClass('toggled');
+ $rootScope.chatStatus = angular.element('#wrapper').hasClass('toggled');
}
$rootScope.dialpadNumber = '';