Selaa lähdekoodia

首页轮播图修改

anderx 4 vuotta sitten
vanhempi
commit
dabd7e1cee
1 muutettua tiedostoa jossa 7 lisäystä ja 2 poistoa
  1. 7 2
      src/main/webapp/WEB-INF/views/portal/index.html

+ 7 - 2
src/main/webapp/WEB-INF/views/portal/index.html

@@ -23,9 +23,14 @@
             <!-- 轮播图 -->
             <div class="swiper-container" id="swiper1">
                 <div class="swiper-wrapper" >
-                    <a   th:each="b,bStatus:${banners}"  th:href="${b.jumpUrl}" class="swiper-slide" target="_blank">
+                     <th:block th:each="b,bStatus:${banners}">
+                        <a th:if="${b.jumpUrl != 'javascript:;' && b.jumpUrl != null}" target="_blank"  th:href="${b.jumpUrl}" class="swiper-slide">
                             <img th:title="${b.title}" th:src="|${avatarUploadHost}${b.bannerUrl}" />
-                    </a>
+                        </a>
+                        <span th:if="${b.jumpUrl == 'javascript:;' || b.jumpUrl == null}" class="swiper-slide">
+                            <img th:title="${b.title}" th:src="|${avatarUploadHost}${b.bannerUrl}" />
+                        </span>
+                    </th:block>
                    <!--  <div class="swiper-slide">
                         <img th:src="${portalHost+'/images/banner/bg02.png'}" />
                     </div> -->