2017-01-02 70 views
0

使用JHipster(和招搖的UI 2.1.5)我想訪問「API」選項卡。揚鞭UI無法正常顯示

然而,它似乎並沒有正常顯示,我得到以下錯誤控制檯:

index.html:8 GET http://localhost:8080/swagger-ui/css/typography.css 
index.html:10 GET http://localhost:8080/swagger-ui/css/screen.css 
index.html:15 GET http://localhost:8080/swagger-ui/lib/jquery.slideto.min.js 
index.html:14 GET http://localhost:8080/swagger-ui/lib/jquery-1.8.0.min.js 
index.html:16 GET http://localhost:8080/swagger-ui/lib/jquery.wiggle.min.js 
index.html:18 GET http://localhost:8080/swagger-ui/lib/handlebars-2.0.0.js 
index.html:17 GET http://localhost:8080/swagger-ui/lib/jquery.ba-bbq.min.js 
index.html:19 GET http://localhost:8080/swagger-ui/lib/lodash.min.js 
index.html:21 GET http://localhost:8080/swagger-ui/lib/swagger-ui.min.js 
index.html:13 GET http://localhost:8080/swagger-ui/lib/object-assign-pollyfill.js 
index.html:22 GET http://localhost:8080/swagger-ui/lib/highlight.9.1.0.pack.js 
index.html:20 GET http://localhost:8080/swagger-ui/lib/backbone-min.js 
index.html:24 GET http://localhost:8080/swagger-ui/lib/jsoneditor.min.js 
index.html:25 GET http://localhost:8080/swagger-ui/lib/marked.js 
index.html:23 GET http://localhost:8080/swagger-ui/lib/highlight.9.1.0.pack_extended.js 
index.html:26 GET http://localhost:8080/swagger-ui/lib/swagger-oauth.js 
index.html:9 GET http://localhost:8080/swagger-ui/css/reset.css 
index.html:12 GET http://localhost:8080/swagger-ui/css/print.css 
index.html:14 GET http://localhost:8080/swagger-ui/lib/jquery-1.8.0.min.js 
index.html:15 GET http://localhost:8080/swagger-ui/lib/jquery.slideto.min.js 
index.html:16 GET http://localhost:8080/swagger-ui/lib/jquery.wiggle.min.js 
index.html:17 GET http://localhost:8080/swagger-ui/lib/jquery.ba-bbq.min.js 
index.html:18 GET http://localhost:8080/swagger-ui/lib/handlebars-2.0.0.js 
index.html:19 GET http://localhost:8080/swagger-ui/lib/lodash.min.js 
index.html:20 GET http://localhost:8080/swagger-ui/lib/backbone-min.js 
index.html:21 GET http://localhost:8080/swagger-ui/lib/swagger-ui.min.js 
index.html:22 GET http://localhost:8080/swagger-ui/lib/highlight.9.1.0.pack.js 
index.html:23 GET http://localhost:8080/swagger-ui/lib/highlight.9.1.0.pack_extended.js 
index.html:24 GET http://localhost:8080/swagger-ui/lib/jsoneditor.min.js 
index.html:25 GET http://localhost:8080/swagger-ui/lib/marked.js 
index.html:26 GET http://localhost:8080/swagger-ui/lib/swagger-oauth.js 
index.html:34 Uncaught ReferenceError: $ is not defined 
    at index.html:34 

enter image description here

我使用Eclipse(STS分佈),我擔心它可能是一個項目配置的問題,而是因爲我是相當新的它,我一直沒能確定問題的來源。

編輯:

我使用Maven和仍然出現錯誤閹我通過STS或命令行啓動應用程序。

該項目是隻是我想測試出一個服務的產生。

而且我剛剛生成一個新的JHipster應用程序和錯誤依然存在。

編輯「:

顯示的確是更好的邊緣,我有機會獲得服務。

我還注意到,不變的應用表現不錯的邊緣。

enter image description here

+0

您的控制檯日誌很奇怪,我的顯示的http://本地主機:8080 /招搖的UI /距離/ lib中/ jQuery的1.8.0.min.js,不同的是「DIST」子文件夾,但我跑在JHipster 4(主)上。您是否嘗試在其他瀏覽器中運行?通過最新的JHipster 3生成示例應用程序 –

+0

看着昂首闊步的UI/index.html的,你應該看到bower_components文件夾引用:https://github.com/jhipster/jhipster-sample-app/blob/master/src/main/ Web應用程序/招搖的UI/index.html的#L14所以我不知道你用 –

+0

哪個版本我使用JHipster發電機v3.12.2和亭子v1.8.0 – Vark

回答

0

我用另一種應用程序來模仿它的服務,它可能是運行舊版本JHipster,招搖......這讓問題再次出現,但這次在邊緣。

刪除瀏覽器的緩存文件固定的邊緣和Chrome中的錯誤。