summaryrefslogtreecommitdiff
path: root/www/js/ImportantMessageCtrl.js
blob: e4a3b86dc0735b3831c1cac8aefcb54a07ce09f5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
/* jshint -W041 */
/* jslint browser: true*/
/* global cordova,StatusBar,angular,console */

angular.module('zmApp.controllers').controller('zmApp.ImportantMessageCtrl', ['$scope', '$ionicSideMenuDelegate', 'zm', '$stateParams', '$timeout', '$rootScope', function($scope, $ionicSideMenuDelegate, zm, $stateParams, $timeout, $rootScope)
{
    $scope.openMenu = function()
    {
        $ionicSideMenuDelegate.toggleLeft();
    };

    //-------------------------------------------------------------------------
    // Controller Main
    //------------------------------------------------------------------------
    $scope.$on('$ionicView.enter', function()
    {
       // console.log("**VIEW ** LowVersion Ctrl Entered");
        $ionicSideMenuDelegate.canDragContent(true);
        $scope.requiredVersion = zm.minAppVersion;
        $scope.currentVersion = $stateParams.ver;
        $scope.recommendedVersion = zm.recommendedAppVersion;

    });

    $scope.openMenu = function()
    {
        $timeout(function()
        {
            $rootScope.stateofSlide = $ionicSideMenuDelegate.isOpen();
        }, 500);

        $ionicSideMenuDelegate.toggleLeft();
    };

}]);