Pārlūkot izejas kodu

刪除BIM程式庫專案、修改BIM元件庫選擇全部bug

nate 3 gadi atpakaļ
vecāks
revīzija
6af3b5e369
2 mainītis faili ar 18 papildinājumiem un 12 dzēšanām
  1. 18 2
      component-favorite.php
  2. 0 10
      script/js/global.js

+ 18 - 2
component-favorite.php

@@ -78,7 +78,7 @@ include($_SERVER['DOCUMENT_ROOT'] . "/Authorization/script/php/permission/check_
 	<script>
 		/*Vue */
 		vm.mount('.body');
-addUserImage(userName.charAt(0),role);
+		addUserImage(userName.charAt(0), role);
 	</script>
 	<?php include("bim-support-body.html"); ?>
 
@@ -164,6 +164,23 @@ addUserImage(userName.charAt(0),role);
 			}
 		});
 
+		$('#mgSelectAll').on('click', function(ev) {
+			ev.preventDefault();
+			var $this = $(this),
+				$label = $this.find('> span');
+			$checks = $("input[name='delCheck']")
+
+			if ($this.attr('data-all-selected')) {
+				$this.removeAttr('data-all-selected');
+				$checks.prop('checked', false).trigger('change');
+				$label.html($label.data('all-text'));
+			} else {
+				$this.attr('data-all-selected', 'true');
+				$checks.prop('checked', true).trigger('change');
+				$label.html($label.data('none-text'));
+			}
+		});
+
 		function DelFavorite() {
 			$.ajax({
 				url: "./script/php/addFavorite.php",
@@ -178,7 +195,6 @@ addUserImage(userName.charAt(0),role);
 				console.log(error);
 			});
 		}
-
 	</script>
 	<script src="script/js/3Dpic-favorite.js" type="module"></script>
 

+ 0 - 10
script/js/global.js

@@ -497,16 +497,6 @@ vm.component('api-list', {
         </ul>
     </div>
     <hr class="separator" />
-    <div class="widget-header clearfix">
-        <h6 class="title pull-left mt-xs">專案</h6>                    
-    </div>
-    <div class="widget-content">
-        <ul class="mg-folders">
-            <inner-menu-li href="api-list.php?type=專案(果林地下汙水管線建置系統)" name="菓林地下汙水管線建置系統"></inner-menu-li>
-            <inner-menu-li href="api-list.php?type=專案(CF管線點位調查)" name="CF管線點位調查"></inner-menu-li>                                       
-        </ul>
-    </div>
-    <hr class="separator" />
     <div class="widget-header clearfix">
         <h6 class="title pull-left mt-xs">其他</h6>                    
     </div>