diff --git a/antdsp-admin/pom.xml b/antdsp-admin/pom.xml index 78bdd96a5b89f923ea49a1a3fd7e5a521abe5892..4b4aa58cbd316a4611b60a476e655b0ea77462f3 100644 --- a/antdsp-admin/pom.xml +++ b/antdsp-admin/pom.xml @@ -16,6 +16,10 @@ UTF-8 + 7.2.22 + 1.1.18 + 0.0.1 + 1.3.2 @@ -26,7 +30,7 @@ org.apache.shiro shiro-spring - 1.3.2 + ${shiro-spring.version} @@ -38,12 +42,24 @@ com.qiniu qiniu-java-sdk - 7.2.22 + ${qiniu.version} + + + com.alibaba + druid + ${druid.version} + + + com.alibaba + druid-spring-boot-starter + 1.1.13 + + com.antdsp antdsp-core - 0.0.1 + ${antdsp.core.version} diff --git a/antdsp-admin/src/main/java/com/antdsp/web/rest/operation/SystemLogApi.java b/antdsp-admin/src/main/java/com/antdsp/web/rest/operation/SystemLogApi.java index 8237faf8867ba0e9692f4a250d27eae83eefbe92..18b7b5ef83f02b1b0b1f79f218dcb17f5037c75a 100644 --- a/antdsp-admin/src/main/java/com/antdsp/web/rest/operation/SystemLogApi.java +++ b/antdsp-admin/src/main/java/com/antdsp/web/rest/operation/SystemLogApi.java @@ -39,7 +39,6 @@ public class SystemLogApi { private SystemLogJpa systemLogJpa; @GetMapping - @OperationLog(name="日志信息") public PaginationData list(int page, int count, Long startTime, Long endTime){ Specification specification = new Specification() { diff --git a/antdsp-admin/src/main/resources/application.yml b/antdsp-admin/src/main/resources/application.yml index 865e46479018a5c18d79f66bbe5bf714b64cd998..c63c758deabf3fda369a761c2178b391c8cbfd3d 100644 --- a/antdsp-admin/src/main/resources/application.yml +++ b/antdsp-admin/src/main/resources/application.yml @@ -13,11 +13,36 @@ server: spring: datasource: type: @antdsp.db.datasource@ - driver-class-name: @antdsp.db.driver@ - url: @antdsp.db.url@ - username: @antdsp.db.username@ - password: @antdsp.db.password@ - initial-size: 10 + druid: + driver-class-name: @antdsp.db.driver@ + url: @antdsp.db.url@ + username: @antdsp.db.username@ + password: @antdsp.db.password@ + initial-size: 10 + max-active: 100 + min-idle: 10 + max-wait: 60000 + pool-prepared-statements: true + max-pool-prepared-statement-per-connection-siz: 20 + time-between-eviction-runs-millis: 60000 + min-evictable-idle-time-millis: 300000 + test-while-idle: true + test-on-return: false + test-on-borrow: false + stat-view-servlet: + enabled: true + url-patten: /druid/* + allow: + filter: + stat: + enabled: true + log-slow-sql: true + slow-sql-millis: 10000 + merge-sql: true + + wall: + config: + multi-statement-allow: true jpa: hibernate: ddl-auto: update diff --git a/antdsp-admin/src/main/web/config/router.config.js b/antdsp-admin/src/main/web/config/router.config.js index c0688560cde3f3387a99b60b21ce3354ef7a07c8..46a8329df0c6d8c6a0e0f71773d1d77a561988f1 100644 --- a/antdsp-admin/src/main/web/config/router.config.js +++ b/antdsp-admin/src/main/web/config/router.config.js @@ -3,7 +3,13 @@ export default [ { path: '/login', name: 'login', - component: './Login/Index', + component: '../layouts/BlankLayout', + routes: [ + { + path: '/login', + component: './Login/Index', + } + ] }, // app { @@ -59,6 +65,11 @@ export default [ component: './Operation/Article/Edit' } ] + }, + { + path: '/operation/sqlmonitor', + name: 'sqlmonitor', + component: './Operation/SqlMonitor/Index' } ] }, diff --git a/antdsp-admin/src/main/web/nginx.conf b/antdsp-admin/src/main/web/nginx.conf deleted file mode 100644 index e205d97bacd487564985b1e83fc2d2d28dffe6ef..0000000000000000000000000000000000000000 --- a/antdsp-admin/src/main/web/nginx.conf +++ /dev/null @@ -1,68 +0,0 @@ - -#user nobody; -worker_processes 1; - -#error_log logs/error.log; -#error_log logs/error.log notice; -#error_log logs/error.log info; - -#pid logs/nginx.pid; - - -events { - worker_connections 1024; -} - - -http { - include mime.types; - default_type application/octet-stream; - - #log_format main '$remote_addr - $remote_user [$time_local] "$request" ' - # '$status $body_bytes_sent "$http_referer" ' - # '"$http_user_agent" "$http_x_forwarded_for"'; - - #access_log logs/access.log main; - - sendfile on; - #tcp_nopush on; - - #keepalive_timeout 0; - keepalive_timeout 65; - - #gzip on; - - server { - listen 80; - server_name 192.168.1.223; - - root /usr/share/nginx/antdsp; - - location /antdsp/ { - # 用于配合 browserHistory使用 - try_files $uri $uri/ /index.html; - - } - location /antdsp-api/ { - proxy_pass http://192.168.1.223:8088/antdsp-api/; - - proxy_set_header X-Forwarded-Proto $scheme; - # proxy_set_header Host $http_host; - proxy_set_header X-Real-IP $remote_addr; - } - - - #error_page 404 /404.html; - - # redirect server error pages to the static page /50x.html - # - error_page 500 502 503 504 /50x.html; - location = /50x.html { - root html; - } - - - } - - include servers/*; -} diff --git a/antdsp-admin/src/main/web/src/components/GlobalHeader/RightContent.js b/antdsp-admin/src/main/web/src/components/GlobalHeader/RightContent.js index 3755c0392b66f38bbfb72597448e040ecddf0ea4..660e72f834a642ff5fb84d4d1a8eadcc967b70b7 100644 --- a/antdsp-admin/src/main/web/src/components/GlobalHeader/RightContent.js +++ b/antdsp-admin/src/main/web/src/components/GlobalHeader/RightContent.js @@ -8,6 +8,7 @@ import HeaderSearch from '../HeaderSearch'; import HeaderDropdown from '../HeaderDropdown'; import SelectLang from '../SelectLang'; import styles from './index.less'; +import AntdspConfig from '@/AntdspConfig'; export default class GlobalHeaderRight extends PureComponent { getNoticeData() { @@ -114,10 +115,11 @@ export default class GlobalHeaderRight extends PureComponent { {currentUser.realname} + ) : ( diff --git a/antdsp-admin/src/main/web/src/defaultSettings.js b/antdsp-admin/src/main/web/src/defaultSettings.js index c952cb8712888951b6439d218e60a91c2f4ba258..0252b7af5f18bc90985df835a0ace3635922ad3f 100644 --- a/antdsp-admin/src/main/web/src/defaultSettings.js +++ b/antdsp-admin/src/main/web/src/defaultSettings.js @@ -9,7 +9,7 @@ module.exports = { menu: { disableLocal: false, }, - title: 'Antdsp', + title: 'Antd-Spring', pwa: true, // Your custom iconfont Symbol script Url // eg://at.alicdn.com/t/font_1039637_btcrd5co4w.js diff --git a/antdsp-admin/src/main/web/src/layouts/BlankLayout.js b/antdsp-admin/src/main/web/src/layouts/BlankLayout.js index ef39aa4c2f06804f562bdc6645348a55f61fb022..142830918b98e8c5a5b3ed18de1fa10c6359264a 100644 --- a/antdsp-admin/src/main/web/src/layouts/BlankLayout.js +++ b/antdsp-admin/src/main/web/src/layouts/BlankLayout.js @@ -1,3 +1,9 @@ import React from 'react'; +import DocumentTitle from 'react-document-title'; +import styles from './BlankLayout.less'; -export default ({ children }) =>
{children}
; +export default ({ children }) => { + return ( +
{children}
+
) +} diff --git a/antdsp-admin/src/main/web/src/layouts/BlankLayout.less b/antdsp-admin/src/main/web/src/layouts/BlankLayout.less new file mode 100644 index 0000000000000000000000000000000000000000..3a644138144583e0af9ce3cb9278f6b0b1e29506 --- /dev/null +++ b/antdsp-admin/src/main/web/src/layouts/BlankLayout.less @@ -0,0 +1,9 @@ +@import '~antd/lib/style/themes/default.less'; + +.container{ + display: flex; + height: 100%; + min-height: 600px; + flex-direction: column; + background-color: #20815d; +} \ No newline at end of file diff --git a/antdsp-admin/src/main/web/src/layouts/Footer.js b/antdsp-admin/src/main/web/src/layouts/Footer.js index 693c81721e1c41c93a0de2dee321ea358f9d4455..8ee18aa648c1364ec1f3fa52bddbb008867fcd17 100644 --- a/antdsp-admin/src/main/web/src/layouts/Footer.js +++ b/antdsp-admin/src/main/web/src/layouts/Footer.js @@ -1,37 +1,18 @@ import React, { Fragment } from 'react'; import { Layout, Icon } from 'antd'; import GlobalFooter from '@/components/GlobalFooter'; +import styles from './Footer.less' const { Footer } = Layout; const FooterView = () => ( -