lsc 2 years ago
parent
commit
60a5f2d232
2 changed files with 10 additions and 6 deletions
  1. 1 1
      css/gm/Desktop.css
  2. 9 5
      js/Desktop/Onload.js

+ 1 - 1
css/gm/Desktop.css

@@ -403,7 +403,7 @@ body div ::-webkit-scrollbar-resizer:vertical {
 }
 
 .U_MD_D_BD_notice {
-    /* display: none; */
+    display: none;
     /* padding: 5px 10px; */
     background-color: #00000085;
     position: absolute;

+ 9 - 5
js/Desktop/Onload.js

@@ -482,16 +482,18 @@ U.MD.D.stopSafari = function () {
         event.preventDefault();
     });
 }
+U.MD.D.noticeBlock = '1'
 
-U.MD.D.OpenNotice = function(){
+U.MD.D.OpenNotice = function () {
     let box = $('.U_MD_D_BD_notice')[0]
     box.style.display = 'block'
 }
 
-U.MD.D.cancelNotice = function(){
+U.MD.D.cancelNotice = function () {
     U.UF.EV.stopBubble();
     let box = $('.U_MD_D_BD_notice')[0]
     box.style.display = 'none'
+    U.MD.D.noticeBlock = '2'
 }
 
 U.MD.D.getNotice = function () {
@@ -503,7 +505,9 @@ U.MD.D.getNotice = function () {
         if (res.value && res.value[0].length > 0) {
             let box = $('.U_MD_D_BD_noticeBox_box')[0]
             let _res = res.value[0]
-            // $('.U_MD_D_BD_notice')[0].style.display = 'block'
+            if (U.MD.D.noticeBlock == '1') {
+                $('.U_MD_D_BD_notice')[0].style.display = 'block'
+            }
             $('.U_MD_D_BD_notice_img')[0].style.display = 'block'
             box.innerHTML = ''
             var num = _res.length > 3 ? 3 : _res.length
@@ -513,9 +517,9 @@ U.MD.D.getNotice = function () {
                 // $$('span', { innerHTML: '消息通知' }, _title)
                 $$('span', { innerHTML: _res[i].title }, _title)
                 var _content = $$('div', { className: 'U_MD_D_BD_noticeBox_content' }, _box)
-                $$('span', { innerHTML:  _res[i].content.replace(/<[^>]*>/g, "") }, _content)
+                $$('span', { innerHTML: _res[i].content.replace(/<[^>]*>/g, "") }, _content)
                 var _time = $$('div', { className: 'U_MD_D_BD_noticeBox_time' }, _box)
-                $$('span', { innerHTML:  _res[i].creatTime }, _time)
+                $$('span', { innerHTML: _res[i].creatTime }, _time)
             }
         } else {
             $('.U_MD_D_BD_notice')[0].style.display = 'none'