Authored by xwx

Merge branch 'master' of http://113.200.75.45:82/monitor_v3/hg-monitor-web into master-v32-xwx

@@ -452,7 +452,7 @@ layui.extend({ @@ -452,7 +452,7 @@ layui.extend({
452 } 452 }
453 453
454 //判断是否为故障诊断的三种类型 454 //判断是否为故障诊断的三种类型
455 - if(toastType=='faultinfo'||toastType=='faultover'){ 455 + if(toastType=='faultinfo'||toastType=='faultover'||toastType=='faultprogress'){
456 var imgUrl=""; 456 var imgUrl="";
457 if(toastType=='faultinfo'){ 457 if(toastType=='faultinfo'){
458 imgUrl="/src/style/img/fault.png"; 458 imgUrl="/src/style/img/fault.png";
@@ -461,17 +461,21 @@ layui.extend({ @@ -461,17 +461,21 @@ layui.extend({
461 if(toastType=='faultover'){ 461 if(toastType=='faultover'){
462 imgUrl="/src/style/img/faultprogress.png"; 462 imgUrl="/src/style/img/faultprogress.png";
463 } 463 }
  464 +
  465 + if(toastType=='faultprogress'){
  466 + imgUrl="/src/style/img/faultover.png";
  467 + }
464 setTimeout(function () { 468 setTimeout(function () {
465 new msgTips({ 469 new msgTips({
466 dom: ".right-bottom-tips", 470 dom: ".right-bottom-tips",
467 title: title, 471 title: title,
468 - message: `<p style="line-height: 24px;background: url(${imgUrl}) no-repeat;background-size: 100%;height: 160px;background-position-x: right;padding-left: 25px;padding-top: 145px;"><span >${content}</span><span class="title closeFault" style="position: relative;top: -126px;left: 22px;">X</span><span style="position: relative;left: -89px;top: -96px; font-weight: bold;float: right;">${title}</span></p>`, 472 + message: `<p style="line-height: 20px;background: url(${imgUrl}) no-repeat;background-size: 100%;height: 160px;background-position-x: right;padding-left: 25px;padding-top: 145px;" ><span style=" overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 5; -webkit-box-orient: vertical;margin-left: -11px;" lay-tips="${content}">${content}</span><span class="title closeFault" style="position: absolute;top: 72px;left: 213px;">X</span><span style="position: absolute;left: 87px;top: 124px; font-weight: bold;float: right;">${title}</span></p>`,
469 duration: 10000, 473 duration: 10000,
470 space: 10, 474 space: 10,
471 firstSpace: 8, 475 firstSpace: 8,
472 limit: 8, 476 limit: 8,
473 margin: 15, 477 margin: 15,
474 - direction: 'right bottom', 478 + direction: 'right top',
475 timingFun: 'ease', 479 timingFun: 'ease',
476 width: '300px', 480 width: '300px',
477 toastType: toastType, 481 toastType: toastType,
@@ -479,40 +483,11 @@ layui.extend({ @@ -479,40 +483,11 @@ layui.extend({
479 action: function () { 483 action: function () {
480 //if (hash) { 484 //if (hash) {
481 // location.hash = hash; 485 // location.hash = hash;
482 - location.hash = "/faultDiagnosis/list/faultNo="+content.split(",")[0].split(":")[1]; 486 + location.hash = "/faultDiagnosis/list/faultNo="+content.split(",")[0].split(":")[1];
483 //} 487 //}
484 } 488 }
485 }) 489 })
486 }, delay); 490 }, delay);
487 - }else if(toastType=='faultprogress'){  
488 - var imgUrl="";  
489 - if(toastType=='faultprogress'){  
490 - imgUrl="/src/style/img/faultover.png";  
491 - }  
492 - setTimeout(function () {  
493 - new msgTips({  
494 - dom: ".right-bottom-tips",  
495 - title: title,  
496 - message: `<p style="line-height: 24px;background: url(${imgUrl}) no-repeat;background-size: 100%;height: 160px;background-position-x: right;padding-left: 25px;padding-top: 145px;"><span >${content}</span><span class="title closeFault" style="position: relative;top: -175px;left: 179px;">X</span><span style="position: relative;left: -90px;top: -117px; font-weight: bold;float: right;">${title}</span></p>`,  
497 - duration: 10000,  
498 - space: 10,  
499 - firstSpace: 8,  
500 - limit: 8,  
501 - margin: 15,  
502 - direction: 'right bottom',  
503 - timingFun: 'ease',  
504 - width: '300px',  
505 - toastType: toastType,  
506 - type: 'click',  
507 - action: function () {  
508 - //if (hash) {  
509 - // location.hash = hash;  
510 - location.hash = "/faultDiagnosis/list/faultNo="+content.split(",")[0].split(":")[1];  
511 - //}  
512 - }  
513 - })  
514 - }, delay);  
515 -  
516 }else{ 491 }else{
517 setTimeout(function () { 492 setTimeout(function () {
518 new msgTips({ 493 new msgTips({
@@ -65,7 +65,8 @@ layui.define(['layer', 'laytpl', 'form'], function (exports) { @@ -65,7 +65,8 @@ layui.define(['layer', 'laytpl', 'form'], function (exports) {
65 $(newContainer).addClass('active length1'); 65 $(newContainer).addClass('active length1');
66 break; 66 break;
67 } else if (!$('.ez_tips').hasClass('length'+ (i+1))) { 67 } else if (!$('.ez_tips').hasClass('length'+ (i+1))) {
68 - $(newContainer).css(lastDirection,i * height + options.space * i + options.firstSpace + 'px'); 68 + $(newContainer).css(lastDirection,10 + options.space * i + options.firstSpace + 'px');
  69 + // $(newContainer).css('right',20 *i + 'px');
69 $(newContainer).addClass('active length'+(i+1)); 70 $(newContainer).addClass('active length'+(i+1));
70 break; // break一定要加,否则每次点击都会循环到结束,导致一个目标div可能同时有length1 length2.....等多个类名 71 break; // break一定要加,否则每次点击都会循环到结束,导致一个目标div可能同时有length1 length2.....等多个类名
71 } 72 }
@@ -118,7 +119,7 @@ layui.define(['layer', 'laytpl', 'form'], function (exports) { @@ -118,7 +119,7 @@ layui.define(['layer', 'laytpl', 'form'], function (exports) {
118 $(newContainer).removeClass('active'); 119 $(newContainer).removeClass('active');
119 setTimeout(function () { 120 setTimeout(function () {
120 $(newContainer).remove(); 121 $(newContainer).remove();
121 - }, 700) 122 + }, 500)
122 }; 123 };
123 timer = setTimeout(timeOut, options.duration); 124 timer = setTimeout(timeOut, options.duration);
124 var newTimes; 125 var newTimes;
@@ -127,24 +128,27 @@ layui.define(['layer', 'laytpl', 'form'], function (exports) { @@ -127,24 +128,27 @@ layui.define(['layer', 'laytpl', 'form'], function (exports) {
127 'transition-timing-function':options.timingFun, 128 'transition-timing-function':options.timingFun,
128 // 'width':options.width, 129 // 'width':options.width,
129 'width':'226px', 130 'width':'226px',
130 - 'bottom':'620px' 131 + 'bottom':'350px'
131 }); 132 });
132 var height = $(newContainer).outerHeight(true); 133 var height = $(newContainer).outerHeight(true);
133 var len = $('.fault_ez_tips').size(); 134 var len = $('.fault_ez_tips').size();
134 if (len >= 2) { 135 if (len >= 2) {
135 for (var i = 1; i < len; i++) { 136 for (var i = 1; i < len; i++) {
136 if (!$('.fault_ez_tips').hasClass('length1')) { 137 if (!$('.fault_ez_tips').hasClass('length1')) {
137 - $(newContainer).css(lastDirection,options.firstSpace + 'px'); 138 + $(newContainer).css(lastDirection,options.firstSpace +50+ 'px');
138 $(newContainer).addClass('active length1'); 139 $(newContainer).addClass('active length1');
139 break; 140 break;
140 } else if (!$('.fault_ez_tips').hasClass('length'+ (i+1))) { 141 } else if (!$('.fault_ez_tips').hasClass('length'+ (i+1))) {
141 - $(newContainer).css(lastDirection,i * height + options.space * i + options.firstSpace + 'px'); 142 + $(newContainer).css(lastDirection,10 + options.space * i + options.firstSpace +50+'px');
  143 + var rightVal=parseInt($(newContainer).css('right').split('px')[0]);
  144 + // $(newContainer).css('right',30 + rightVal + 'px');
  145 + // $(newContainer).css('right',30 *i + 'px');
142 $(newContainer).addClass('active length'+(i+1)); 146 $(newContainer).addClass('active length'+(i+1));
143 break; // break一定要加,否则每次点击都会循环到结束,导致一个目标div可能同时有length1 length2.....等多个类名 147 break; // break一定要加,否则每次点击都会循环到结束,导致一个目标div可能同时有length1 length2.....等多个类名
144 } 148 }
145 } 149 }
146 } else { 150 } else {
147 - $(newContainer).css(lastDirection,options.firstSpace + 'px'); 151 + $(newContainer).css(lastDirection,options.firstSpace +50+'px');
148 $(newContainer).addClass('active length1'); 152 $(newContainer).addClass('active length1');
149 } 153 }
150 $(newContainer).on('mouseenter', function (event) { 154 $(newContainer).on('mouseenter', function (event) {