Przeglądaj źródła

撤回,质检默认置忙

miaofuhao 6 lat temu
rodzic
commit
a4843fdfac

+ 4 - 0
WebUI/CallCenterWeb.UI/js/index.js

@@ -1342,6 +1342,10 @@ function logout() {
1342 1342
         dataType: "json",
1343 1343
         success: function (res) {
1344 1344
             if (res.state) {
1345
+            	window.localStorage.removeItem('token');
1346
+				window.localStorage.removeItem('extno');
1347
+				window.localStorage.removeItem('zx_user');
1348
+				window.localStorage.removeItem('socket_state');
1345 1349
                 location.href = "./login.html";
1346 1350
             }
1347 1351
         }

+ 12 - 50
WebUI/CallCenterWeb.UI/js/main.js

@@ -219,26 +219,7 @@ function LoginBack() {
219 219
     $(".fwzt").removeClass("br").addClass("bl");
220 220
     $(".hwzt").text('');
221 221
     $('.Consult').addClass("active");
222
-    if ($("#RoleCode").val()=='ZJZY') {
223
-		$(".SayBusy").removeClass("active");
224
-		$(".SayFree").addClass("active");
225
-		$(".zxzt").removeClass("bl").removeClass("br").addClass("by");
226
-		$(".hwzt").text('忙碌');
227
-		$("#isml").val(1);
228
-	    SetStateCookie(1);
229
-	    obj.Type = "SayBusy";
230
-	    Send();
231
-    };
232
-    if ($.cookie("socket_state") == null&&$("#RoleCode").val()=='ZJZY') {
233
-		$(".SayBusy").removeClass("active");
234
-		$(".SayFree").addClass("active");
235
-		$(".zxzt").removeClass("bl").removeClass("br").addClass("by");
236
-		$(".hwzt").text('忙碌');
237
-		$("#isml").val(1);
238
-        SetStateCookie(1);
239
-        obj.Type = "SayBusy";
240
-        Send();
241
-    }else if($.cookie("socket_state") == null){
222
+    if($.cookie("socket_state") == null){
242 223
     	SetStateCookie(0);
243 224
     }
244 225
 }
@@ -508,22 +489,12 @@ function SetState(obj) {
508 489
         SetStateCookie(1);
509 490
     }
510 491
     if (obj.State == '2') {
511
-        
512
-        if ($("#RoleCode").val()=='ZJZY') {
513
-			$(".SayBusy").removeClass("active");
514
-			$(".SayFree").addClass("active");
515
-			$(".zxzt").removeClass("bl").removeClass("br").addClass("by");
516
-			$(".hwzt").text('忙碌');
517
-			$("#isml").val(1);
518
-		    SetStateCookie(1);
519
-	    }else{
520
-	    	$(".SayBusy").addClass("active");
521
-	        $(".SayFree").removeClass("active");
522
-	        $(".zxzt").removeClass("br").removeClass("by").addClass("bl");
523
-	        $(".hwzt").text('空闲');
524
-	        $("#isml").val(0);
525
-	        SetStateCookie(0);
526
-	    }
492
+    	$(".SayBusy").addClass("active");
493
+        $(".SayFree").removeClass("active");
494
+        $(".zxzt").removeClass("br").removeClass("by").addClass("bl");
495
+        $(".hwzt").text('空闲');
496
+        $("#isml").val(0);
497
+        SetStateCookie(0);
527 498
     }
528 499
 }
529 500
 
@@ -559,20 +530,11 @@ function SayBusyBack() {
559 530
 }
560 531
 //置闲
561 532
 function SayFreeBack() {
562
-	if ($("#RoleCode").val()=='ZJZY') {
563
-		$(".SayBusy").removeClass("active");
564
-    	$(".SayFree").addClass("active");
565
-    	$(".zxzt").removeClass("bl").removeClass("br").addClass("by");
566
-		$(".hwzt").text('忙碌');
567
-        $("#isml").val(1)
568
-    }else{
569
-    	$(".SayBusy").addClass("active");
570
-	    $(".SayFree").removeClass("active");
571
-	    $(".zxzt").removeClass("br").addClass("bl"); //坐席状态指示
572
-		$(".hwzt").text('空闲');// 增加坐席状态指示
573
-		$("#isml").val(0)
574
-    }
575
-    
533
+	$(".SayBusy").addClass("active");
534
+    $(".SayFree").removeClass("active");
535
+    $(".zxzt").removeClass("br").addClass("bl"); //坐席状态指示
536
+	$(".hwzt").text('空闲');// 增加坐席状态指示
537
+	$("#isml").val(0)
576 538
 }
577 539
 //多方通话
578 540
 function MeetingBack() {