seimin hace 2 años
padre
commit
ef33563401
Se han modificado 1 ficheros con 72 adiciones y 72 borrados
  1. 72 72
      assets/js/controllers/mainCtrl.js

+ 72 - 72
assets/js/controllers/mainCtrl.js

@@ -937,16 +937,16 @@ app.controller('AppCtrl', ['$rootScope', '$scope', '$state', '$translate', '$loc
937 937
             // 签入
938 938
             $rootScope.forcedCheckOut(phone);
939 939
           }else{
940
-            new Notification("启动失败1", {
941
-              icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
942
-            });
940
+            // new Notification("启动失败1", {
941
+            //   icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
942
+            // });
943 943
           }
944 944
         }, function(err){
945 945
           console.error('err', err);
946 946
           $rootScope.isMask = false;
947
-          new Notification("启动失败2", {
948
-            icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
949
-          });
947
+          // new Notification("启动失败2", {
948
+          //   icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
949
+          // });
950 950
         })
951 951
     }
952 952
     // 签出
@@ -957,16 +957,16 @@ app.controller('AppCtrl', ['$rootScope', '$scope', '$state', '$translate', '$loc
957 957
           // 签入
958 958
           $rootScope.checkIn(phone);
959 959
         }else{
960
-          new Notification("强制签出失败1", {
961
-            icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
962
-          });
960
+          // new Notification("强制签出失败1", {
961
+          //   icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
962
+          // });
963 963
         }
964 964
       }, function(err){
965 965
         console.error('err', err);
966 966
         $rootScope.isMask = false;
967
-        new Notification("强制签出失败2", {
968
-          icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
969
-        });
967
+        // new Notification("强制签出失败2", {
968
+        //   icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
969
+        // });
970 970
       });
971 971
     }
972 972
     // 签入
@@ -981,16 +981,16 @@ app.controller('AppCtrl', ['$rootScope', '$scope', '$state', '$translate', '$loc
981 981
               $rootScope.reconnect(phone);
982 982
             }
983 983
         } else {
984
-          new Notification("签入失败1!", {
985
-              icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
986
-          });
984
+          // new Notification("签入失败1!", {
985
+          //     icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
986
+          // });
987 987
         }
988 988
       }, function(err){
989 989
         console.error('err', err);
990 990
         $rootScope.isMask = false;
991
-        new Notification("签入失败2!", {
992
-          icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
993
-        });
991
+        // new Notification("签入失败2!", {
992
+        //   icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
993
+        // });
994 994
       })
995 995
     }
996 996
     // 获取状态
@@ -1322,15 +1322,15 @@ app.controller('AppCtrl', ['$rootScope', '$scope', '$state', '$translate', '$loc
1322 1322
               }
1323 1323
           });
1324 1324
         } else {
1325
-          new Notification("获取话单ID状态失败1!", {
1326
-              icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1327
-          });
1325
+          // new Notification("获取话单ID状态失败1!", {
1326
+          //     icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1327
+          // });
1328 1328
         }
1329 1329
       }, function(err){
1330 1330
         console.error('err', err);
1331
-        new Notification("获取话单ID状态失败1!", {
1332
-          icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1333
-        });
1331
+        // new Notification("获取话单ID状态失败1!", {
1332
+        //   icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1333
+        // });
1334 1334
       })
1335 1335
     }
1336 1336
     // 心跳检测
@@ -1398,9 +1398,9 @@ app.controller('AppCtrl', ['$rootScope', '$scope', '$state', '$translate', '$loc
1398 1398
                 $rootScope.callStatus = 1;
1399 1399
                 $rootScope.phone = ""
1400 1400
               } else if (mydata.evttype == 'hookchanged' && $rootScope.callout == 2) {
1401
-                new Notification('呼出'+ (mydata.status == 1?'挂机':'摘机'), {
1402
-                  icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1403
-                });
1401
+                // new Notification('呼出'+ (mydata.status == 1?'挂机':'摘机'), {
1402
+                //   icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1403
+                // });
1404 1404
                 console.log('==================呼出开始=================');
1405 1405
                 console.log('$rootScope.hrzy============', $rootScope.hrzy);
1406 1406
                 console.log('$rootScope.callout============', $rootScope.callout);
@@ -1428,9 +1428,9 @@ app.controller('AppCtrl', ['$rootScope', '$scope', '$state', '$translate', '$loc
1428 1428
                   });
1429 1429
                 }
1430 1430
               } else if (mydata.evttype == 'hookchanged' && $rootScope.callout == 1) {
1431
-                new Notification('呼入'+ (mydata.status == 1?'挂机':'摘机'), {
1432
-                  icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1433
-                });
1431
+                // new Notification('呼入'+ (mydata.status == 1?'挂机':'摘机'), {
1432
+                //   icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1433
+                // });
1434 1434
                 console.log('==================呼入开始=================');
1435 1435
                 console.log('$rootScope.hrzy============', $rootScope.hrzy);
1436 1436
                 console.log('$rootScope.callout============', $rootScope.callout);
@@ -1525,19 +1525,19 @@ app.controller('AppCtrl', ['$rootScope', '$scope', '$state', '$translate', '$loc
1525 1525
         }
1526 1526
         if (data.errno == 0) {
1527 1527
           $rootScope.callStatus = 2;
1528
-          new Notification("示忙成功!", {
1529
-            icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1530
-          });
1528
+          // new Notification("示忙成功!", {
1529
+          //   icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1530
+          // });
1531 1531
         }else{
1532
-          new Notification("示忙失败1!", {
1533
-            icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1534
-          });
1532
+          // new Notification("示忙失败1!", {
1533
+          //   icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1534
+          // });
1535 1535
         }
1536 1536
       }, function(err){
1537 1537
         console.error('err', err);
1538
-        new Notification("示忙失败2!", {
1539
-          icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1540
-        });
1538
+        // new Notification("示忙失败2!", {
1539
+        //   icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1540
+        // });
1541 1541
       })
1542 1542
     }
1543 1543
     // 示闲
@@ -1551,19 +1551,19 @@ app.controller('AppCtrl', ['$rootScope', '$scope', '$state', '$translate', '$loc
1551 1551
         }
1552 1552
         if (data.errno == 0) {
1553 1553
           $rootScope.callStatus = 1;
1554
-          new Notification("示闲成功!", {
1555
-            icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1556
-          });
1554
+          // new Notification("示闲成功!", {
1555
+          //   icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1556
+          // });
1557 1557
         }else{
1558
-          new Notification("示闲失败1!", {
1559
-            icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1560
-          });
1558
+          // new Notification("示闲失败1!", {
1559
+          //   icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1560
+          // });
1561 1561
         }
1562 1562
       }, function(err){
1563 1563
         console.error('err', err);
1564
-        new Notification("示闲失败2!", {
1565
-          icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1566
-        });
1564
+        // new Notification("示闲失败2!", {
1565
+        //   icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1566
+        // });
1567 1567
       })
1568 1568
     }
1569 1569
     // 转移
@@ -1578,16 +1578,16 @@ app.controller('AppCtrl', ['$rootScope', '$scope', '$state', '$translate', '$loc
1578 1578
           $rootScope.callout = 2;
1579 1579
           $rootScope.hrzy = true;
1580 1580
         }else{
1581
-          new Notification("转移失败1!", {
1582
-            icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1583
-          });
1581
+          // new Notification("转移失败1!", {
1582
+          //   icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1583
+          // });
1584 1584
         }
1585 1585
       }, function(err){
1586 1586
         $rootScope.isMask = false;
1587 1587
         console.error('err', err);
1588
-        new Notification("转移失败2!", {
1589
-          icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1590
-        });
1588
+        // new Notification("转移失败2!", {
1589
+        //   icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1590
+        // });
1591 1591
       })
1592 1592
     }
1593 1593
     // 签出
@@ -1602,29 +1602,29 @@ app.controller('AppCtrl', ['$rootScope', '$scope', '$state', '$translate', '$loc
1602 1602
             if (data.errno == 0) {
1603 1603
               callback && callback();
1604 1604
             }else{
1605
-              new Notification("退出失败1!", {
1606
-                icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1607
-              });
1605
+              // new Notification("退出失败1!", {
1606
+              //   icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1607
+              // });
1608 1608
             }
1609 1609
           }, function(err){
1610 1610
             $rootScope.isMask = false;
1611 1611
             console.error('err', err);
1612
-            new Notification("退出失败2!", {
1613
-              icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1614
-            });
1612
+            // new Notification("退出失败2!", {
1613
+            //   icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1614
+            // });
1615 1615
           })
1616 1616
         }else{
1617 1617
           $rootScope.isMask = false;
1618
-          new Notification("签出失败1!", {
1619
-            icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1620
-          });
1618
+          // new Notification("签出失败1!", {
1619
+          //   icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1620
+          // });
1621 1621
         }
1622 1622
       }, function(err){
1623 1623
         $rootScope.isMask = false;
1624 1624
         console.error('err', err);
1625
-        new Notification("签出失败2!", {
1626
-          icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1627
-        });
1625
+        // new Notification("签出失败2!", {
1626
+        //   icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1627
+        // });
1628 1628
       })
1629 1629
     }
1630 1630
     //呼叫
@@ -1639,16 +1639,16 @@ app.controller('AppCtrl', ['$rootScope', '$scope', '$state', '$translate', '$loc
1639 1639
           $rootScope.callStatus = 4;
1640 1640
           $rootScope.callout = 2;
1641 1641
         }else{
1642
-          new Notification("呼叫失败1!", {
1643
-            icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1644
-          });
1642
+          // new Notification("呼叫失败1!", {
1643
+          //   icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1644
+          // });
1645 1645
         }
1646 1646
       }, function(err){
1647 1647
         $rootScope.isMask = false;
1648 1648
         console.error('err', err);
1649
-        new Notification("呼叫失败2!", {
1650
-          icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1651
-        });
1649
+        // new Notification("呼叫失败2!", {
1650
+        //   icon: './bower_components/HTML5-Desktop-Notifications/alert.ico',
1651
+        // });
1652 1652
       })
1653 1653
     }
1654 1654
     // 牛逼