重构控制台首页
This commit is contained in:
@@ -37,7 +37,7 @@
|
|||||||
|
|
||||||
#### 运行方式
|
#### 运行方式
|
||||||
|
|
||||||
1. 创建数据库:zyplayer_doc_manage,执行脚本:[zyplayer_doc_manage.1.0.1.sql](https://gitee.com/zyplayer/zyplayer-doc/blob/master/zyplayer-doc-manage/src/main/resources/sql/zyplayer_doc_manage.1.0.1.sql)
|
1. 创建数据库:zyplayer_doc_manage,执行脚本:[zyplayer_doc_manage.1.0.2.sql](https://gitee.com/zyplayer/zyplayer-doc/blob/master/zyplayer-doc-manage/src/main/resources/sql/zyplayer_doc_manage.1.0.2.sql)
|
||||||
|
|
||||||
2. 修改zyplayer-doc-manage项目的application.yml配置文件里面的数据库账号密码
|
2. 修改zyplayer-doc-manage项目的application.yml配置文件里面的数据库账号密码
|
||||||
|
|
||||||
|
|||||||
3
pom.xml
3
pom.xml
@@ -4,7 +4,7 @@
|
|||||||
|
|
||||||
<groupId>com.zyplayer</groupId>
|
<groupId>com.zyplayer</groupId>
|
||||||
<artifactId>zyplayer-doc</artifactId>
|
<artifactId>zyplayer-doc</artifactId>
|
||||||
<version>1.0.1</version>
|
<version>1.0.2</version>
|
||||||
<packaging>pom</packaging>
|
<packaging>pom</packaging>
|
||||||
|
|
||||||
<name>zyplayer-doc</name>
|
<name>zyplayer-doc</name>
|
||||||
@@ -26,5 +26,6 @@
|
|||||||
<module>zyplayer-doc-wiki</module>
|
<module>zyplayer-doc-wiki</module>
|
||||||
<module>zyplayer-doc-data</module>
|
<module>zyplayer-doc-data</module>
|
||||||
<module>zyplayer-doc-grpc</module>
|
<module>zyplayer-doc-grpc</module>
|
||||||
|
<module>zyplayer-doc-page</module>
|
||||||
</modules>
|
</modules>
|
||||||
</project>
|
</project>
|
||||||
|
|||||||
@@ -6,7 +6,7 @@
|
|||||||
|
|
||||||
<groupId>com.zyplayer</groupId>
|
<groupId>com.zyplayer</groupId>
|
||||||
<artifactId>zyplayer-doc-core</artifactId>
|
<artifactId>zyplayer-doc-core</artifactId>
|
||||||
<version>1.0.1</version>
|
<version>1.0.2</version>
|
||||||
<name>zyplayer-doc-core</name>
|
<name>zyplayer-doc-core</name>
|
||||||
|
|
||||||
<url>http://maven.apache.org</url>
|
<url>http://maven.apache.org</url>
|
||||||
|
|||||||
@@ -6,7 +6,7 @@
|
|||||||
|
|
||||||
<groupId>com.zyplayer</groupId>
|
<groupId>com.zyplayer</groupId>
|
||||||
<artifactId>zyplayer-doc-data</artifactId>
|
<artifactId>zyplayer-doc-data</artifactId>
|
||||||
<version>1.0.1</version>
|
<version>1.0.2</version>
|
||||||
|
|
||||||
<parent>
|
<parent>
|
||||||
<groupId>org.springframework.boot</groupId>
|
<groupId>org.springframework.boot</groupId>
|
||||||
@@ -23,7 +23,7 @@
|
|||||||
<velocity.engine.core.version>2.0</velocity.engine.core.version>
|
<velocity.engine.core.version>2.0</velocity.engine.core.version>
|
||||||
<dozer.core.version>6.1.0</dozer.core.version>
|
<dozer.core.version>6.1.0</dozer.core.version>
|
||||||
<alibaba.druid.version>1.1.9</alibaba.druid.version>
|
<alibaba.druid.version>1.1.9</alibaba.druid.version>
|
||||||
<zyplayer.doc.version>1.0.1</zyplayer.doc.version>
|
<zyplayer.doc.version>1.0.2</zyplayer.doc.version>
|
||||||
</properties>
|
</properties>
|
||||||
|
|
||||||
<dependencies>
|
<dependencies>
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
|
|
||||||
<groupId>com.zyplayer</groupId>
|
<groupId>com.zyplayer</groupId>
|
||||||
<artifactId>zyplayer-doc-db</artifactId>
|
<artifactId>zyplayer-doc-db</artifactId>
|
||||||
<version>1.0.1</version>
|
<version>1.0.2</version>
|
||||||
<packaging>jar</packaging>
|
<packaging>jar</packaging>
|
||||||
<name>zyplayer-doc-db</name>
|
<name>zyplayer-doc-db</name>
|
||||||
<description>数据库文档工具</description>
|
<description>数据库文档工具</description>
|
||||||
@@ -74,8 +74,7 @@
|
|||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.zyplayer</groupId>
|
<groupId>com.zyplayer</groupId>
|
||||||
<artifactId>zyplayer-doc-core</artifactId>
|
<artifactId>zyplayer-doc-core</artifactId>
|
||||||
<version>1.0.1</version>
|
<version>${zyplayer.doc.version}</version>
|
||||||
<scope>compile</scope>
|
|
||||||
</dependency>
|
</dependency>
|
||||||
</dependencies>
|
</dependencies>
|
||||||
|
|
||||||
@@ -83,6 +82,7 @@
|
|||||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||||
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
|
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
|
||||||
<java.version>1.8</java.version>
|
<java.version>1.8</java.version>
|
||||||
|
<zyplayer.doc.version<version>1.0.2</version>zyplayer.doc.version>
|
||||||
<!-- 打包跳过单元测试 -->
|
<!-- 打包跳过单元测试 -->
|
||||||
<skipTests>true</skipTests>
|
<skipTests>true</skipTests>
|
||||||
<destDir>${project.build.outputDirectory}/META-INF/resources/webjars/${project.artifactId}/${project.version}</destDir>
|
<destDir>${project.build.outputDirectory}/META-INF/resources/webjars/${project.artifactId}/${project.version}</destDir>
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
<modelVersion>4.0.0</modelVersion>
|
<modelVersion>4.0.0</modelVersion>
|
||||||
<groupId>com.zyplayer</groupId>
|
<groupId>com.zyplayer</groupId>
|
||||||
<artifactId>zyplayer-doc-dubbo</artifactId>
|
<artifactId>zyplayer-doc-dubbo</artifactId>
|
||||||
<version>1.0.1</version>
|
<version>1.0.2</version>
|
||||||
<packaging>jar</packaging>
|
<packaging>jar</packaging>
|
||||||
<name>zyplayer-doc-dubbo</name>
|
<name>zyplayer-doc-dubbo</name>
|
||||||
|
|
||||||
@@ -36,7 +36,7 @@
|
|||||||
<!-- 打包跳过单元测试 -->
|
<!-- 打包跳过单元测试 -->
|
||||||
<skipTests>true</skipTests>
|
<skipTests>true</skipTests>
|
||||||
<destDir>${project.build.outputDirectory}/META-INF/resources/webjars/${project.artifactId}/${project.version}</destDir>
|
<destDir>${project.build.outputDirectory}/META-INF/resources/webjars/${project.artifactId}/${project.version}</destDir>
|
||||||
<zyplayer.doc.version>1.0.1</zyplayer.doc.version>
|
<zyplayer.doc.version>1.0.2</zyplayer.doc.version>
|
||||||
</properties>
|
</properties>
|
||||||
|
|
||||||
<dependencies>
|
<dependencies>
|
||||||
|
|||||||
@@ -6,7 +6,7 @@
|
|||||||
|
|
||||||
<groupId>com.zyplayer</groupId>
|
<groupId>com.zyplayer</groupId>
|
||||||
<artifactId>zyplayer-doc-grpc</artifactId>
|
<artifactId>zyplayer-doc-grpc</artifactId>
|
||||||
<version>1.0.1</version>
|
<version>1.0.2</version>
|
||||||
|
|
||||||
<parent>
|
<parent>
|
||||||
<groupId>org.springframework.boot</groupId>
|
<groupId>org.springframework.boot</groupId>
|
||||||
@@ -52,7 +52,7 @@
|
|||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.zyplayer</groupId>
|
<groupId>com.zyplayer</groupId>
|
||||||
<artifactId>zyplayer-doc-core</artifactId>
|
<artifactId>zyplayer-doc-core</artifactId>
|
||||||
<version>1.0.1</version>
|
<version>1.0.2</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
</dependencies>
|
</dependencies>
|
||||||
|
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
|
|
||||||
<groupId>com.zyplayer</groupId>
|
<groupId>com.zyplayer</groupId>
|
||||||
<artifactId>zyplayer-doc-manage</artifactId>
|
<artifactId>zyplayer-doc-manage</artifactId>
|
||||||
<version>1.0.1</version>
|
<version>1.0.2</version>
|
||||||
<packaging>war</packaging>
|
<packaging>war</packaging>
|
||||||
|
|
||||||
<name>zyplayer-doc-manage</name>
|
<name>zyplayer-doc-manage</name>
|
||||||
@@ -22,14 +22,14 @@
|
|||||||
<java.version>1.8</java.version>
|
<java.version>1.8</java.version>
|
||||||
<mybatis.plus.boot.starter.version>3.0.6</mybatis.plus.boot.starter.version>
|
<mybatis.plus.boot.starter.version>3.0.6</mybatis.plus.boot.starter.version>
|
||||||
<fastjson.version>1.2.53</fastjson.version>
|
<fastjson.version>1.2.53</fastjson.version>
|
||||||
<zyplayer.doc.swagger.version>1.0.1</zyplayer.doc.swagger.version>
|
<zyplayer.doc.swagger.version>1.0.2</zyplayer.doc.swagger.version>
|
||||||
<velocity.engine.core.version>2.0</velocity.engine.core.version>
|
<velocity.engine.core.version>2.0</velocity.engine.core.version>
|
||||||
<dozer.core.version>6.1.0</dozer.core.version>
|
<dozer.core.version>6.1.0</dozer.core.version>
|
||||||
<alibaba.druid.version>1.1.9</alibaba.druid.version>
|
<alibaba.druid.version>1.1.9</alibaba.druid.version>
|
||||||
<swagger.bootstrap.ui.version>1.8.9</swagger.bootstrap.ui.version>
|
<swagger.bootstrap.ui.version>1.8.9</swagger.bootstrap.ui.version>
|
||||||
<springfox.swagger.ui.version>2.9.2</springfox.swagger.ui.version>
|
<springfox.swagger.ui.version>2.9.2</springfox.swagger.ui.version>
|
||||||
<springfox.swagger.version>2.9.2</springfox.swagger.version>
|
<springfox.swagger.version>2.9.2</springfox.swagger.version>
|
||||||
<zyplayer.doc.version>1.0.1</zyplayer.doc.version>
|
<zyplayer.doc.version>1.0.2</zyplayer.doc.version>
|
||||||
</properties>
|
</properties>
|
||||||
|
|
||||||
<dependencies>
|
<dependencies>
|
||||||
@@ -120,6 +120,12 @@
|
|||||||
<artifactId>zyplayer-doc-swagger</artifactId>
|
<artifactId>zyplayer-doc-swagger</artifactId>
|
||||||
<version>${zyplayer.doc.swagger.version}</version>
|
<version>${zyplayer.doc.swagger.version}</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
<!--zyplayer-doc-swagger-->
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.zyplayer</groupId>
|
||||||
|
<artifactId>doc-console-page</artifactId>
|
||||||
|
<version>${zyplayer.doc.swagger.version}</version>
|
||||||
|
</dependency>
|
||||||
<!--swagger-bootstrap-ui-->
|
<!--swagger-bootstrap-ui-->
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.github.xiaoymin</groupId>
|
<groupId>com.github.xiaoymin</groupId>
|
||||||
|
|||||||
@@ -14,7 +14,7 @@ public class DocSystemController {
|
|||||||
|
|
||||||
@GetMapping("/")
|
@GetMapping("/")
|
||||||
public ModelAndView home() {
|
public ModelAndView home() {
|
||||||
return new ModelAndView("redirect:/static/manage/home.html");
|
return new ModelAndView("/doc-console.html");
|
||||||
}
|
}
|
||||||
|
|
||||||
@GetMapping("/doc-wiki")
|
@GetMapping("/doc-wiki")
|
||||||
|
|||||||
191
zyplayer-doc-page/console-page/pom.xml
Normal file
191
zyplayer-doc-page/console-page/pom.xml
Normal file
@@ -0,0 +1,191 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project xmlns="http://maven.apache.org/POM/4.0.0"
|
||||||
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
|
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||||
|
|
||||||
|
<modelVersion>4.0.0</modelVersion>
|
||||||
|
<groupId>com.zyplayer</groupId>
|
||||||
|
<artifactId>doc-console-page</artifactId>
|
||||||
|
<version>1.0.2</version>
|
||||||
|
<description>管理页面前端</description>
|
||||||
|
<url>https://gitee.com/zyplayer/zyplayer-doc</url>
|
||||||
|
<developers>
|
||||||
|
<developer>
|
||||||
|
<id>zyplayer</id>
|
||||||
|
<name>暮光:城中城</name>
|
||||||
|
<email>806783409@qq.com</email>
|
||||||
|
<roles>
|
||||||
|
<role>Java Development Engineer</role>
|
||||||
|
</roles>
|
||||||
|
<timezone>2018-05-22 16:06:06</timezone>
|
||||||
|
</developer>
|
||||||
|
</developers>
|
||||||
|
|
||||||
|
<properties>
|
||||||
|
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||||
|
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
|
||||||
|
<java.version>1.8</java.version>
|
||||||
|
<zyplayer.doc.version<version>1.0.2</version>zyplayer.doc.version>
|
||||||
|
<!-- 打包跳过单元测试 -->
|
||||||
|
<skipTests>true</skipTests>
|
||||||
|
<destDir>${project.build.outputDirectory}/META-INF/resources/webjars/${project.artifactId}/${project.version}</destDir>
|
||||||
|
</properties>
|
||||||
|
|
||||||
|
<dependencies>
|
||||||
|
|
||||||
|
</dependencies>
|
||||||
|
<licenses>
|
||||||
|
<license>
|
||||||
|
<name>The Apache Software License, Version 2.0</name>
|
||||||
|
<url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
|
||||||
|
</license>
|
||||||
|
</licenses>
|
||||||
|
<scm>
|
||||||
|
<connection>scm:git@git.oschina.net:zyplayer/zyplayer-doc.git</connection>
|
||||||
|
<developerConnection>scm:git@git.oschina.net:zyplayer/zyplayer-doc.git</developerConnection>
|
||||||
|
<url>git@git.oschina.net:zyplayer/zyplayer-doc.git</url>
|
||||||
|
</scm>
|
||||||
|
|
||||||
|
<distributionManagement>
|
||||||
|
<snapshotRepository>
|
||||||
|
<id>snapshots</id>
|
||||||
|
<url>https://oss.sonatype.org/content/repositories/snapshots/</url>
|
||||||
|
</snapshotRepository>
|
||||||
|
<repository>
|
||||||
|
<id>snapshots</id>
|
||||||
|
<url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
|
||||||
|
</repository>
|
||||||
|
</distributionManagement>
|
||||||
|
|
||||||
|
<build>
|
||||||
|
<resources>
|
||||||
|
<resource>
|
||||||
|
<directory>src/main/resources</directory>
|
||||||
|
<targetPath>META-INF/resources/</targetPath>
|
||||||
|
</resource>
|
||||||
|
<resource>
|
||||||
|
<directory>src/main/java</directory>
|
||||||
|
<includes>
|
||||||
|
<include>**/*</include>
|
||||||
|
</includes>
|
||||||
|
<excludes>
|
||||||
|
<exclude>**/*.java</exclude>
|
||||||
|
</excludes>
|
||||||
|
<filtering>false</filtering>
|
||||||
|
</resource>
|
||||||
|
<resource>
|
||||||
|
<directory>src/main/webapp</directory>
|
||||||
|
<includes>
|
||||||
|
<include>**/*</include>
|
||||||
|
</includes>
|
||||||
|
<filtering>false</filtering>
|
||||||
|
</resource>
|
||||||
|
</resources>
|
||||||
|
<plugins>
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-javadoc-plugin</artifactId>
|
||||||
|
<version>2.10.2</version>
|
||||||
|
<configuration>
|
||||||
|
<aggregate>true</aggregate>
|
||||||
|
</configuration>
|
||||||
|
<executions>
|
||||||
|
<execution>
|
||||||
|
<id>attach-javadocs</id>
|
||||||
|
<goals>
|
||||||
|
<goal>jar</goal>
|
||||||
|
</goals>
|
||||||
|
</execution>
|
||||||
|
</executions>
|
||||||
|
</plugin>
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-source-plugin</artifactId>
|
||||||
|
<executions>
|
||||||
|
<execution>
|
||||||
|
<id>attach-sources</id>
|
||||||
|
<goals>
|
||||||
|
<goal>jar</goal>
|
||||||
|
</goals>
|
||||||
|
</execution>
|
||||||
|
</executions>
|
||||||
|
</plugin>
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-compiler-plugin</artifactId>
|
||||||
|
<configuration>
|
||||||
|
<source>1.8</source>
|
||||||
|
<target>1.8</target>
|
||||||
|
<encoding>UTF-8</encoding>
|
||||||
|
</configuration>
|
||||||
|
</plugin>
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-resources-plugin</artifactId>
|
||||||
|
<version>2.6</version>
|
||||||
|
<configuration>
|
||||||
|
<encoding>UTF-8</encoding>
|
||||||
|
</configuration>
|
||||||
|
</plugin>
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-surefire-plugin</artifactId>
|
||||||
|
<version>2.18.1</version>
|
||||||
|
<configuration>
|
||||||
|
<skipTests>${skipTests}</skipTests>
|
||||||
|
</configuration>
|
||||||
|
</plugin>
|
||||||
|
</plugins>
|
||||||
|
</build>
|
||||||
|
<profiles>
|
||||||
|
<profile>
|
||||||
|
<id>release</id>
|
||||||
|
<build>
|
||||||
|
<plugins>
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-source-plugin</artifactId>
|
||||||
|
<version>2.2.1</version>
|
||||||
|
<executions>
|
||||||
|
<execution>
|
||||||
|
<phase>package</phase>
|
||||||
|
<goals>
|
||||||
|
<goal>jar-no-fork</goal>
|
||||||
|
</goals>
|
||||||
|
</execution>
|
||||||
|
</executions>
|
||||||
|
</plugin>
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-javadoc-plugin</artifactId>
|
||||||
|
<version>2.10.2</version>
|
||||||
|
<configuration>
|
||||||
|
<aggregate>true</aggregate>
|
||||||
|
</configuration>
|
||||||
|
<executions>
|
||||||
|
<execution>
|
||||||
|
<id>attach-javadocs</id>
|
||||||
|
<goals>
|
||||||
|
<goal>jar</goal>
|
||||||
|
</goals>
|
||||||
|
</execution>
|
||||||
|
</executions>
|
||||||
|
</plugin>
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-gpg-plugin</artifactId>
|
||||||
|
<version>1.6</version>
|
||||||
|
<executions>
|
||||||
|
<execution>
|
||||||
|
<phase>verify</phase>
|
||||||
|
<goals>
|
||||||
|
<goal>sign</goal>
|
||||||
|
</goals>
|
||||||
|
</execution>
|
||||||
|
</executions>
|
||||||
|
</plugin>
|
||||||
|
</plugins>
|
||||||
|
</build>
|
||||||
|
</profile>
|
||||||
|
</profiles>
|
||||||
|
</project>
|
||||||
Binary file not shown.
Binary file not shown.
File diff suppressed because one or more lines are too long
@@ -0,0 +1,2 @@
|
|||||||
|
!function(e){function n(r){if(t[r])return t[r].exports;var o=t[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}var r=window.webpackJsonp;window.webpackJsonp=function(t,a,c){for(var u,i,f,l=0,s=[];l<t.length;l++)i=t[l],o[i]&&s.push(o[i][0]),o[i]=0;for(u in a)Object.prototype.hasOwnProperty.call(a,u)&&(e[u]=a[u]);for(r&&r(t,a,c);s.length;)s.shift()();if(c)for(l=0;l<c.length;l++)f=n(n.s=c[l]);return f};var t={},o={2:0};n.e=function(e){function r(){u.onerror=u.onload=null,clearTimeout(i);var n=o[e];0!==n&&(n&&n[1](new Error("Loading chunk "+e+" failed.")),o[e]=void 0)}var t=o[e];if(0===t)return new Promise(function(e){e()});if(t)return t[2];var a=new Promise(function(n,r){t=o[e]=[n,r]});t[2]=a;var c=document.getElementsByTagName("head")[0],u=document.createElement("script");u.type="text/javascript",u.charset="utf-8",u.async=!0,u.timeout=12e4,n.nc&&u.setAttribute("nonce",n.nc),u.src=n.p+""+e+".js?"+{0:"9e844afffa202a7aaee1",1:"f364eea49fc3d06c67fd"}[e];var i=setTimeout(r,12e4);return u.onerror=u.onload=r,c.appendChild(u),a},n.m=e,n.c=t,n.i=function(e){return e},n.d=function(e,r,t){n.o(e,r)||Object.defineProperty(e,r,{configurable:!1,enumerable:!0,get:t})},n.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(r,"a",r),r},n.o=function(e,n){return Object.prototype.hasOwnProperty.call(e,n)},n.p="",n.oe=function(e){throw console.error(e),e}}([]);
|
||||||
|
//# sourceMappingURL=manifest.js.map?8d995025d5a44e9c6f92
|
||||||
File diff suppressed because one or more lines are too long
@@ -0,0 +1,17 @@
|
|||||||
|
<!DOCTYPE HTML>
|
||||||
|
<html lang="en">
|
||||||
|
<head>
|
||||||
|
<meta charset="UTF-8">
|
||||||
|
<meta content="text/html; charset=utf-8" http-equiv="Content-Type">
|
||||||
|
<title>wiki文档管理系统</title>
|
||||||
|
</head>
|
||||||
|
|
||||||
|
<body>
|
||||||
|
<div id="app"></div>
|
||||||
|
<script type="text/javascript" src="doc-console-manifest.js?8d995025d5a44e9c6f92"></script>
|
||||||
|
<script type="text/javascript" src="doc-console-vendor.js?9e844afffa202a7aaee1"></script>
|
||||||
|
<script type="text/javascript" src="doc-console-index.js?f364eea49fc3d06c67fd"></script>
|
||||||
|
</body>
|
||||||
|
|
||||||
|
</html>
|
||||||
|
|
||||||
16
zyplayer-doc-page/pom.xml
Normal file
16
zyplayer-doc-page/pom.xml
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project xmlns="http://maven.apache.org/POM/4.0.0"
|
||||||
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
|
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||||
|
|
||||||
|
<groupId>com.zyplayer</groupId>
|
||||||
|
<artifactId>doc-page</artifactId>
|
||||||
|
<version>1.0.2</version>
|
||||||
|
<modelVersion>4.0.0</modelVersion>
|
||||||
|
<packaging>pom</packaging>
|
||||||
|
|
||||||
|
<modules>
|
||||||
|
<module>console-page</module>
|
||||||
|
</modules>
|
||||||
|
|
||||||
|
</project>
|
||||||
@@ -6,7 +6,7 @@
|
|||||||
|
|
||||||
<groupId>com.zyplayer</groupId>
|
<groupId>com.zyplayer</groupId>
|
||||||
<artifactId>zyplayer-doc-swagger</artifactId>
|
<artifactId>zyplayer-doc-swagger</artifactId>
|
||||||
<version>1.0.1</version>
|
<version>1.0.2</version>
|
||||||
<packaging>jar</packaging>
|
<packaging>jar</packaging>
|
||||||
<name>zyplayer-doc-swagger</name>
|
<name>zyplayer-doc-swagger</name>
|
||||||
<description>zyplayer-doc-swagger是swagger-ui的一个前端实现,使用简单、解析速度快、走心的设计,支持多项目同时展示,多种文档目录的展示方案,多种自定义配置,满足各种使用习惯</description>
|
<description>zyplayer-doc-swagger是swagger-ui的一个前端实现,使用简单、解析速度快、走心的设计,支持多项目同时展示,多种文档目录的展示方案,多种自定义配置,满足各种使用习惯</description>
|
||||||
@@ -36,7 +36,7 @@
|
|||||||
<!-- 打包跳过单元测试 -->
|
<!-- 打包跳过单元测试 -->
|
||||||
<skipTests>true</skipTests>
|
<skipTests>true</skipTests>
|
||||||
<destDir>${project.build.outputDirectory}/META-INF/resources/webjars/${project.artifactId}/${project.version}</destDir>
|
<destDir>${project.build.outputDirectory}/META-INF/resources/webjars/${project.artifactId}/${project.version}</destDir>
|
||||||
<zyplayer.doc.version>1.0.1</zyplayer.doc.version>
|
<zyplayer.doc.version>1.0.2</zyplayer.doc.version>
|
||||||
</properties>
|
</properties>
|
||||||
|
|
||||||
<dependencies>
|
<dependencies>
|
||||||
|
|||||||
3
zyplayer-doc-ui/console-ui/.babelrc
Normal file
3
zyplayer-doc-ui/console-ui/.babelrc
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
{
|
||||||
|
"presets": ["vue-app"]
|
||||||
|
}
|
||||||
5
zyplayer-doc-ui/console-ui/.gitignore
vendored
Normal file
5
zyplayer-doc-ui/console-ui/.gitignore
vendored
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
.DS_Store
|
||||||
|
node_modules/
|
||||||
|
dist/
|
||||||
|
npm-debug.log
|
||||||
|
.idea
|
||||||
9
zyplayer-doc-ui/console-ui/Makefile
Normal file
9
zyplayer-doc-ui/console-ui/Makefile
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
.PHONY: dist build
|
||||||
|
install:
|
||||||
|
@npm install
|
||||||
|
|
||||||
|
dev: install
|
||||||
|
@npm run dev
|
||||||
|
|
||||||
|
build:
|
||||||
|
@npm run build
|
||||||
50
zyplayer-doc-ui/console-ui/README.md
Normal file
50
zyplayer-doc-ui/console-ui/README.md
Normal file
@@ -0,0 +1,50 @@
|
|||||||
|
# zyplayer-doc-manage项目的UI
|
||||||
|
|
||||||
|
## 常见问题
|
||||||
|
|
||||||
|
1、命令行要进入这个文件夹才能执行命令:
|
||||||
|
|
||||||
|
zyplayer-doc/zyplayer-doc-ui/manage-ui
|
||||||
|
|
||||||
|
2、增加host,否则run不起来:
|
||||||
|
|
||||||
|
在文件 C:\Windows\System32\drivers\etc\hosts 末尾增加:
|
||||||
|
|
||||||
|
127.0.0.1 local.zyplayer.com
|
||||||
|
|
||||||
|
## 配置文件
|
||||||
|
|
||||||
|
1、这里可以配置接口请求的域名,可使用本地、线上,测试通过后就会打包到zyplayer-doc-wiki项目里面使用
|
||||||
|
|
||||||
|
zyplayer-doc-ui/manage-ui/src/common/config/apimix.js
|
||||||
|
|
||||||
|
2、这里可以配置启动后访问的地址,建议不改
|
||||||
|
|
||||||
|
zyplayer-doc-ui/manage-ui/webpack.config.js
|
||||||
|
|
||||||
|
## 环境要求
|
||||||
|
|
||||||
|
`Node >= 6`
|
||||||
|
|
||||||
|
|
||||||
|
## 开始
|
||||||
|
|
||||||
|
``` bash
|
||||||
|
# 执行下面的命令初始化
|
||||||
|
yarn
|
||||||
|
```
|
||||||
|
|
||||||
|
## 开发环境
|
||||||
|
|
||||||
|
``` bash
|
||||||
|
# 执行下面的命令后即可到 localhost:8010 看到页面
|
||||||
|
npm run dev
|
||||||
|
```
|
||||||
|
|
||||||
|
## 打包
|
||||||
|
|
||||||
|
``` bash
|
||||||
|
# 开发完成后执行打包命令,然后复制dist目录里的文件到zyplayer-doc-manage项目的webjars目录下即可
|
||||||
|
# 打包前记得修改zyplayer-doc-ui/manage-ui/src/common/config/apimix.js里的HOST接口地址
|
||||||
|
npm run build
|
||||||
|
```
|
||||||
7697
zyplayer-doc-ui/console-ui/package-lock.json
generated
Normal file
7697
zyplayer-doc-ui/console-ui/package-lock.json
generated
Normal file
File diff suppressed because it is too large
Load Diff
40
zyplayer-doc-ui/console-ui/package.json
Normal file
40
zyplayer-doc-ui/console-ui/package.json
Normal file
@@ -0,0 +1,40 @@
|
|||||||
|
{
|
||||||
|
"name": "element-starter",
|
||||||
|
"description": "A Vue.js project",
|
||||||
|
"author": "yi.shyang@ele.me",
|
||||||
|
"private": true,
|
||||||
|
"scripts": {
|
||||||
|
"dev": "webpack-dev-server --inline --hot --env.dev",
|
||||||
|
"build": "rimraf dist && webpack -p --progress --hide-modules"
|
||||||
|
},
|
||||||
|
"dependencies": {
|
||||||
|
"axios": "^0.18.0",
|
||||||
|
"element-ui": "^2.3.4",
|
||||||
|
"vue": "^2.5.16",
|
||||||
|
"vue-axios": "^2.1.4",
|
||||||
|
"vue-router": "^3.0.6",
|
||||||
|
"wangeditor": "^3.1.1"
|
||||||
|
},
|
||||||
|
"engines": {
|
||||||
|
"node": ">=6"
|
||||||
|
},
|
||||||
|
"devDependencies": {
|
||||||
|
"autoprefixer": "^6.6.0",
|
||||||
|
"babel-core": "^6.24.1",
|
||||||
|
"babel-loader": "^6.4.0",
|
||||||
|
"babel-preset-vue-app": "^1.2.0",
|
||||||
|
"css-loader": "^0.27.0",
|
||||||
|
"file-loader": "^0.10.1",
|
||||||
|
"html-webpack-plugin": "^2.24.1",
|
||||||
|
"postcss-loader": "^1.3.3",
|
||||||
|
"rimraf": "^2.6.3",
|
||||||
|
"style-loader": "^0.13.2",
|
||||||
|
"url-loader": "^0.5.8",
|
||||||
|
"vue-loader": "^13.3.0",
|
||||||
|
"vue-template-compiler": "^2.5.16",
|
||||||
|
"webpack": "^2.4.1",
|
||||||
|
"webpack-dev-server": "^2.4.2",
|
||||||
|
"axios": "^0.18.0",
|
||||||
|
"vue-axios": "^2.1.4"
|
||||||
|
}
|
||||||
|
}
|
||||||
5
zyplayer-doc-ui/console-ui/postcss.config.js
Normal file
5
zyplayer-doc-ui/console-ui/postcss.config.js
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
module.exports = {
|
||||||
|
plugins: [
|
||||||
|
require('autoprefixer')()
|
||||||
|
]
|
||||||
|
}
|
||||||
129
zyplayer-doc-ui/console-ui/src/App.vue
Normal file
129
zyplayer-doc-ui/console-ui/src/App.vue
Normal file
@@ -0,0 +1,129 @@
|
|||||||
|
<template>
|
||||||
|
<div id="app">
|
||||||
|
<template v-if="global.fullscreen">
|
||||||
|
<router-view></router-view>
|
||||||
|
</template>
|
||||||
|
<el-container v-else>
|
||||||
|
<el-aside>
|
||||||
|
<div style="padding: 10px;height: 100%;box-sizing: border-box;background: #fafafa;">
|
||||||
|
<el-menu default-active="1-4-1" :router="true" class="el-menu-vertical" @open="handleOpen" @close="handleClose" :collapse="isCollapse">
|
||||||
|
<el-menu-item index="/"><i class="el-icon-s-home"></i>控制台</el-menu-item>
|
||||||
|
<el-submenu index="1">
|
||||||
|
<template slot="title">
|
||||||
|
<i class="el-icon-s-platform"></i>
|
||||||
|
<span slot="title">系统管理</span>
|
||||||
|
</template>
|
||||||
|
<el-menu-item index="/console/userList"><i class="el-icon-user-solid"></i>用户管理</el-menu-item>
|
||||||
|
<el-menu-item index="/console/roleList"><i class="el-icon-s-custom"></i>角色管理</el-menu-item>
|
||||||
|
<el-menu-item index="/console/authList"><i class="el-icon-s-claim"></i>权限列表</el-menu-item>
|
||||||
|
</el-submenu>
|
||||||
|
</el-menu>
|
||||||
|
</div>
|
||||||
|
</el-aside>
|
||||||
|
<el-container>
|
||||||
|
<el-header>
|
||||||
|
<el-dropdown @command="userSettingDropdown" trigger="click">
|
||||||
|
<i class="el-icon-setting" style="margin-right: 15px; font-size: 16px;cursor: pointer;color: #fff;"> </i>
|
||||||
|
<el-dropdown-menu slot="dropdown">
|
||||||
|
<el-dropdown-item command="aboutDoc">关于</el-dropdown-item>
|
||||||
|
<el-dropdown-item command="" divided>我的资料</el-dropdown-item>
|
||||||
|
<el-dropdown-item command="userSignOut">退出登录</el-dropdown-item>
|
||||||
|
</el-dropdown-menu>
|
||||||
|
</el-dropdown>
|
||||||
|
</el-header>
|
||||||
|
<el-main style="padding: 0;">
|
||||||
|
<router-view></router-view>
|
||||||
|
</el-main>
|
||||||
|
</el-container>
|
||||||
|
</el-container>
|
||||||
|
<!--关于弹窗-->
|
||||||
|
<el-dialog title="关于zyplayer-doc" :visible.sync="aboutDialogVisible" width="600px">
|
||||||
|
<el-form>
|
||||||
|
<el-form-item label="项目地址:">
|
||||||
|
<a target="_blank" href="https://gitee.com/zyplayer/zyplayer-doc">zyplayer-doc</a>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="开发人员:">
|
||||||
|
<a target="_blank" href="http://zyplayer.com">暮光:城中城</a>
|
||||||
|
</el-form-item>
|
||||||
|
<template v-if="upgradeInfo.lastVersion">
|
||||||
|
<el-form-item label="当前版本:">{{upgradeInfo.nowVersion}}</el-form-item>
|
||||||
|
<el-form-item label="最新版本:">{{upgradeInfo.lastVersion}}</el-form-item>
|
||||||
|
<el-form-item label="升级地址:">
|
||||||
|
<a target="_blank" :href="upgradeInfo.upgradeUrl">{{upgradeInfo.upgradeUrl}}</a>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="升级内容:">{{upgradeInfo.upgradeContent}}</el-form-item>
|
||||||
|
</template>
|
||||||
|
<el-form-item label="">
|
||||||
|
欢迎加群讨论,QQ群号:466363173,欢迎提交需求,欢迎使用和加入开发!
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
</el-dialog>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import global from './common/config/global'
|
||||||
|
import toast from './common/lib/common/toast'
|
||||||
|
|
||||||
|
var app;
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
isCollapse: false,
|
||||||
|
aboutDialogVisible: false,
|
||||||
|
// 升级信息
|
||||||
|
upgradeInfo: {},
|
||||||
|
}
|
||||||
|
},
|
||||||
|
mounted: function () {
|
||||||
|
app = this;
|
||||||
|
global.vue.$app = this;
|
||||||
|
this.checkSystemUpgrade();
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
handleOpen(key, keyPath) {
|
||||||
|
console.log(key, keyPath);
|
||||||
|
},
|
||||||
|
handleClose(key, keyPath) {
|
||||||
|
console.log(key, keyPath);
|
||||||
|
},
|
||||||
|
userSettingDropdown(command) {
|
||||||
|
console.log("command:" + command);
|
||||||
|
if (command == 'userSignOut') {
|
||||||
|
this.userSignOut();
|
||||||
|
} else if (command == 'aboutDoc') {
|
||||||
|
app.aboutDialogVisible = true;
|
||||||
|
} else {
|
||||||
|
toast.notOpen();
|
||||||
|
}
|
||||||
|
},
|
||||||
|
checkSystemUpgrade() {
|
||||||
|
this.common.post(this.apilist1.systemUpgradeInfo, {}, function (json) {
|
||||||
|
if (!!json.data) {
|
||||||
|
app.upgradeInfo = json.data;
|
||||||
|
console.log("zyplayer-doc发现新版本:"
|
||||||
|
+ "\n升级地址:" + json.data.upgradeUrl
|
||||||
|
+ "\n当前版本:" + json.data.nowVersion
|
||||||
|
+ "\n最新版本:" + json.data.lastVersion
|
||||||
|
+ "\n升级内容:" + json.data.upgradeContent
|
||||||
|
);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
},
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style>
|
||||||
|
html, body {
|
||||||
|
margin: 0;
|
||||||
|
padding: 0;
|
||||||
|
height: 100%;
|
||||||
|
}
|
||||||
|
#app, .el-container, .el-menu {
|
||||||
|
height: 100%;
|
||||||
|
}
|
||||||
|
.el-menu-vertical{border-right: 0;background: #fafafa;}
|
||||||
|
.el-menu-vertical .el-menu{background: #fafafa;}
|
||||||
|
.el-header {background-color: #409EFF; color: #333; line-height: 40px; text-align: right;height: 40px !important;}
|
||||||
|
</style>
|
||||||
BIN
zyplayer-doc-ui/console-ui/src/assets/img/dubbo.png
Normal file
BIN
zyplayer-doc-ui/console-ui/src/assets/img/dubbo.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.3 KiB |
39
zyplayer-doc-ui/console-ui/src/common/config/apilist.js
Normal file
39
zyplayer-doc-ui/console-ui/src/common/config/apilist.js
Normal file
@@ -0,0 +1,39 @@
|
|||||||
|
var URL = {
|
||||||
|
userLogin: '/login',
|
||||||
|
userLogout: '/logout',
|
||||||
|
getUserInfo: '/user/getUserInfo',
|
||||||
|
pageUpdate: '/zyplayer-doc-wiki/page/update',
|
||||||
|
pageChangeParent: '/zyplayer-doc-wiki/page/changeParent',
|
||||||
|
pageList: '/zyplayer-doc-wiki/page/list',
|
||||||
|
updatePage: '/zyplayer-doc-wiki/page/update',
|
||||||
|
pageDetail: '/zyplayer-doc-wiki/page/detail',
|
||||||
|
pageDelete: '/zyplayer-doc-wiki/page/delete',
|
||||||
|
pageNews: '/zyplayer-doc-wiki/page/news',
|
||||||
|
pageLock: '/zyplayer-doc-wiki/page/lock',
|
||||||
|
pageUnlock: '/zyplayer-doc-wiki/page/unlock',
|
||||||
|
spaceList: '/zyplayer-doc-wiki/space/list',
|
||||||
|
updateSpace: '/zyplayer-doc-wiki/space/update',
|
||||||
|
getPageUserAuthList: '/zyplayer-doc-wiki/page/auth/list',
|
||||||
|
assignPageUserAuth: '/zyplayer-doc-wiki/page/auth/assign',
|
||||||
|
|
||||||
|
updatePageFile: '/zyplayer-doc-wiki/page/file/update',
|
||||||
|
pageCommentList: '/zyplayer-doc-wiki/page/comment/list',
|
||||||
|
updatePageComment: '/zyplayer-doc-wiki/page/comment/update',
|
||||||
|
pageZanList: '/zyplayer-doc-wiki/page/zan/list',
|
||||||
|
updatePageZan: '/zyplayer-doc-wiki/page/zan/update',
|
||||||
|
|
||||||
|
commonUpload: '/zyplayer-doc-wiki/common/upload',
|
||||||
|
getUserBaseInfo: '/zyplayer-doc-wiki/common/user/base',
|
||||||
|
|
||||||
|
systemUpgradeInfo: '/system/info/upgrade',
|
||||||
|
};
|
||||||
|
|
||||||
|
var URL1 = {};
|
||||||
|
|
||||||
|
export default {
|
||||||
|
URL, URL1
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
52
zyplayer-doc-ui/console-ui/src/common/config/apimix.js
Normal file
52
zyplayer-doc-ui/console-ui/src/common/config/apimix.js
Normal file
@@ -0,0 +1,52 @@
|
|||||||
|
import apilist from './apilist'
|
||||||
|
|
||||||
|
var href = window.location.href;
|
||||||
|
|
||||||
|
var _fn = {
|
||||||
|
href: href,
|
||||||
|
// 本地启动时使用本地接口调试
|
||||||
|
// HOST: 'http://local.zyplayer.com:8083/zyplayer-doc-manage',
|
||||||
|
// HOST1: 'http://local.zyplayer.com:8083/zyplayer-doc-manage',
|
||||||
|
// 也可以直接使用线上的服务调试
|
||||||
|
// HOST: 'http://doc.zyplayer.com/zyplayer-doc-manage',
|
||||||
|
// HOST1: 'http://doc.zyplayer.com/zyplayer-doc-manage',
|
||||||
|
// 打包时使用下面这两行,文件就放在根目录下,所以当前路劲就好
|
||||||
|
HOST: './',
|
||||||
|
HOST1: './',
|
||||||
|
|
||||||
|
mixUrl: function (host, url) {
|
||||||
|
var p;
|
||||||
|
if (!host || !url || _fn.isEmptyObject(url)) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
url.HOST = host;
|
||||||
|
for (p in url) {
|
||||||
|
if (url[p].indexOf('http') == -1) {
|
||||||
|
url[p] = host + url[p];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return url;
|
||||||
|
},
|
||||||
|
//判断是否空对象
|
||||||
|
isEmptyObject: function (obj) { //判断空对象
|
||||||
|
if (typeof obj === "object" && !(obj instanceof Array)) {
|
||||||
|
var hasProp = false;
|
||||||
|
for (var prop in obj) {
|
||||||
|
hasProp = true;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
if (hasProp) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
var apilist1 = _fn.mixUrl(_fn.HOST, apilist.URL);
|
||||||
|
var apilist2 = _fn.mixUrl(_fn.HOST1, apilist.URL1);
|
||||||
|
|
||||||
|
export default {
|
||||||
|
apilist1, apilist2
|
||||||
|
};
|
||||||
|
|
||||||
12
zyplayer-doc-ui/console-ui/src/common/config/global.js
Normal file
12
zyplayer-doc-ui/console-ui/src/common/config/global.js
Normal file
@@ -0,0 +1,12 @@
|
|||||||
|
const user = {
|
||||||
|
isLogin: true,
|
||||||
|
};
|
||||||
|
const vue = {};
|
||||||
|
const fullscreen = false;
|
||||||
|
|
||||||
|
export default {
|
||||||
|
vue,
|
||||||
|
user,
|
||||||
|
fullscreen,
|
||||||
|
}
|
||||||
|
|
||||||
110
zyplayer-doc-ui/console-ui/src/common/lib/common/common.js
Normal file
110
zyplayer-doc-ui/console-ui/src/common/lib/common/common.js
Normal file
@@ -0,0 +1,110 @@
|
|||||||
|
import Qs from 'qs'
|
||||||
|
import global from '../../config/global'
|
||||||
|
import apimix from '../../config/apimix'
|
||||||
|
|
||||||
|
export default {
|
||||||
|
data: {
|
||||||
|
accessToken: '',
|
||||||
|
},
|
||||||
|
setAccessToken: function (token) {
|
||||||
|
this.data.accessToken = token;
|
||||||
|
},
|
||||||
|
getAccessToken: function () {
|
||||||
|
if (!this.data.accessToken) {
|
||||||
|
var arr, reg = new RegExp("(^| )accessToken=([^;]*)(;|$)");
|
||||||
|
if (arr = document.cookie.match(reg)) {
|
||||||
|
this.data.accessToken = unescape(arr[2]);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return this.data.accessToken;
|
||||||
|
},
|
||||||
|
validateResult: function (res, callback) {
|
||||||
|
if (!!res.message) {
|
||||||
|
global.vue.$message('请求错误:' + res.message);
|
||||||
|
} else if (res.data.errCode == 400) {
|
||||||
|
global.vue.$message('请先登录');
|
||||||
|
var href = encodeURIComponent(window.location.href);
|
||||||
|
window.location = apimix.apilist1.HOST + "/static/manage/login.html?redirect=" + href;
|
||||||
|
} else if (res.data.errCode == 402) {
|
||||||
|
global.vue.$router.push("/common/noAuth");
|
||||||
|
} else if (res.data.errCode !== 200) {
|
||||||
|
global.vue.$message(res.data.errMsg || "未知错误");
|
||||||
|
} else {
|
||||||
|
if (typeof callback == 'function') {
|
||||||
|
callback(res.data);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
post: function (url, param, callback) {
|
||||||
|
param = param || {};
|
||||||
|
param.accessToken = this.getAccessToken();
|
||||||
|
global.vue.axios({
|
||||||
|
method: "post",
|
||||||
|
url: url,
|
||||||
|
headers: {'Content-type': 'application/x-www-form-urlencoded'},
|
||||||
|
data: Qs.stringify(param),
|
||||||
|
withCredentials: true,
|
||||||
|
}).then((res) => {
|
||||||
|
console.log("ok", res);
|
||||||
|
this.validateResult(res, callback);
|
||||||
|
}).catch((res) => {
|
||||||
|
console.log("error", res);
|
||||||
|
this.validateResult(res);
|
||||||
|
});
|
||||||
|
},
|
||||||
|
postNonCheck: function (url, param, callback) {
|
||||||
|
param = param || {};
|
||||||
|
param.accessToken = this.getAccessToken();
|
||||||
|
global.vue.axios({
|
||||||
|
method: "post",
|
||||||
|
url: url,
|
||||||
|
headers: {'Content-type': 'application/x-www-form-urlencoded'},
|
||||||
|
data: Qs.stringify(param),
|
||||||
|
withCredentials: true,
|
||||||
|
}).then((res) => {
|
||||||
|
console.log("ok", res);
|
||||||
|
if (typeof callback == 'function') {
|
||||||
|
callback(res.data);
|
||||||
|
}
|
||||||
|
}).catch((res) => {
|
||||||
|
console.log("error", res);
|
||||||
|
if (typeof callback == 'function') {
|
||||||
|
callback(res.data);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
},
|
||||||
|
/**
|
||||||
|
* 返回不为空的字符串,为空返回def
|
||||||
|
*/
|
||||||
|
getNotEmptyStr(str, def) {
|
||||||
|
if (isEmpty(str)) {
|
||||||
|
return isEmpty(def) ? "" : def;
|
||||||
|
}
|
||||||
|
return str;
|
||||||
|
},
|
||||||
|
/**
|
||||||
|
* 是否是空对象
|
||||||
|
* @param obj
|
||||||
|
* @returns
|
||||||
|
*/
|
||||||
|
isEmptyObject(obj) {
|
||||||
|
return isEmpty(obj) || $.isEmptyObject(obj);
|
||||||
|
},
|
||||||
|
/**
|
||||||
|
* 是否是空字符串
|
||||||
|
* @param str
|
||||||
|
* @returns
|
||||||
|
*/
|
||||||
|
isEmpty(str) {
|
||||||
|
return (str == "" || str == null || str == undefined);
|
||||||
|
},
|
||||||
|
/**
|
||||||
|
* 是否不是空字符串
|
||||||
|
* @param str
|
||||||
|
* @returns
|
||||||
|
*/
|
||||||
|
isNotEmpty(str) {
|
||||||
|
return !isEmpty(str);
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
40
zyplayer-doc-ui/console-ui/src/common/lib/common/toast.js
Normal file
40
zyplayer-doc-ui/console-ui/src/common/lib/common/toast.js
Normal file
@@ -0,0 +1,40 @@
|
|||||||
|
import global from '../../config/global'
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 提示工具类
|
||||||
|
* @author
|
||||||
|
* @since 2017年5月7日
|
||||||
|
*/
|
||||||
|
export default {
|
||||||
|
notOpen: function () {
|
||||||
|
global.vue.$message({
|
||||||
|
message: '该功能暂未开放,敬请期待!',
|
||||||
|
type: 'warning',
|
||||||
|
showClose: true
|
||||||
|
});
|
||||||
|
},
|
||||||
|
success: function (msg, time) {
|
||||||
|
global.vue.$message({
|
||||||
|
message: msg,
|
||||||
|
duration: time || 3000,
|
||||||
|
type: 'success',
|
||||||
|
showClose: true
|
||||||
|
});
|
||||||
|
},
|
||||||
|
warn: function (msg, time) {
|
||||||
|
global.vue.$message({
|
||||||
|
message: msg,
|
||||||
|
duration: time || 3000,
|
||||||
|
type: 'warning',
|
||||||
|
showClose: true
|
||||||
|
});
|
||||||
|
},
|
||||||
|
error: function (msg, time) {
|
||||||
|
global.vue.$message({
|
||||||
|
message: msg,
|
||||||
|
duration: time || 3000,
|
||||||
|
type: 'error',
|
||||||
|
showClose: true
|
||||||
|
});
|
||||||
|
},
|
||||||
|
};
|
||||||
4
zyplayer-doc-ui/console-ui/src/common/lib/jquery/jquery-3.1.0.min.js
vendored
Normal file
4
zyplayer-doc-ui/console-ui/src/common/lib/jquery/jquery-3.1.0.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
1
zyplayer-doc-ui/console-ui/src/common/lib/jquery/qrcode.min.js
vendored
Normal file
1
zyplayer-doc-ui/console-ui/src/common/lib/jquery/qrcode.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
14
zyplayer-doc-ui/console-ui/src/index.html
Normal file
14
zyplayer-doc-ui/console-ui/src/index.html
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
<!DOCTYPE HTML>
|
||||||
|
<html lang="en">
|
||||||
|
<head>
|
||||||
|
<meta charset="UTF-8">
|
||||||
|
<meta content="text/html; charset=utf-8" http-equiv="Content-Type">
|
||||||
|
<title>wiki文档管理系统</title>
|
||||||
|
</head>
|
||||||
|
|
||||||
|
<body>
|
||||||
|
<div id="app"></div>
|
||||||
|
</body>
|
||||||
|
|
||||||
|
</html>
|
||||||
|
|
||||||
59
zyplayer-doc-ui/console-ui/src/main.js
Normal file
59
zyplayer-doc-ui/console-ui/src/main.js
Normal file
@@ -0,0 +1,59 @@
|
|||||||
|
import Vue from 'vue'
|
||||||
|
import ElementUI from 'element-ui'
|
||||||
|
import 'element-ui/lib/theme-chalk/index.css'
|
||||||
|
import App from './App.vue'
|
||||||
|
|
||||||
|
import global from './common/config/global'
|
||||||
|
import apimix from './common/config/apimix'
|
||||||
|
import common from './common/lib/common/common'
|
||||||
|
import toast from './common/lib/common/toast'
|
||||||
|
|
||||||
|
import VueRouter from 'vue-router'
|
||||||
|
import routes from './routes'
|
||||||
|
import axios from 'axios'
|
||||||
|
import VueAxios from 'vue-axios'
|
||||||
|
|
||||||
|
Vue.use(ElementUI);
|
||||||
|
Vue.use(VueRouter);
|
||||||
|
Vue.use(VueAxios, axios);
|
||||||
|
|
||||||
|
// 全局参数
|
||||||
|
Vue.prototype.global = global;
|
||||||
|
// 接口列表
|
||||||
|
Vue.prototype.apilist1 = apimix.apilist1;
|
||||||
|
Vue.prototype.apilist2 = apimix.apilist1;
|
||||||
|
// 公用方法
|
||||||
|
Vue.prototype.common = common;
|
||||||
|
Vue.prototype.toast = toast;
|
||||||
|
|
||||||
|
const router = new VueRouter({routes});
|
||||||
|
// 路由跳转时判断处理
|
||||||
|
router.beforeEach((to, from, next) => {
|
||||||
|
if (to.meta.title) {
|
||||||
|
document.title = to.meta.title
|
||||||
|
}
|
||||||
|
global.fullscreen = !!to.meta.fullscreen;
|
||||||
|
/* 判断该路由是否需要登录权限 */
|
||||||
|
if (to.matched.some(record => record.meta.requireAuth)) {
|
||||||
|
if (global.user.isLogin) {
|
||||||
|
next();
|
||||||
|
} else {
|
||||||
|
next({path: '/login'});
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
next();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
new Vue({
|
||||||
|
el: '#app',
|
||||||
|
router,
|
||||||
|
render(h) {
|
||||||
|
var app = h(App);
|
||||||
|
global.vue = app.context;
|
||||||
|
return app;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
50
zyplayer-doc-ui/console-ui/src/routes.js
Normal file
50
zyplayer-doc-ui/console-ui/src/routes.js
Normal file
@@ -0,0 +1,50 @@
|
|||||||
|
import Home from './views/home/Home.vue'
|
||||||
|
|
||||||
|
import UserLogin from './views/user/Login.vue'
|
||||||
|
import UserRouterView from './views/user/RouterView.vue'
|
||||||
|
|
||||||
|
import ConsoleRoleList from './views/console/RoleList.vue'
|
||||||
|
import ConsoleUserList from './views/console/UserList.vue'
|
||||||
|
import ConsoleAuthList from './views/console/AuthList.vue'
|
||||||
|
import ConsoleRouterView from './views/console/RouterView.vue'
|
||||||
|
|
||||||
|
import CommonNoAuth from './views/common/NoAuth.vue'
|
||||||
|
|
||||||
|
let routes = [
|
||||||
|
{
|
||||||
|
path: '/home',
|
||||||
|
component: Home,
|
||||||
|
name: '主页',
|
||||||
|
meta: {
|
||||||
|
requireAuth: true,
|
||||||
|
}
|
||||||
|
}, {
|
||||||
|
path: '/user',
|
||||||
|
name: '用户管理',
|
||||||
|
component: UserRouterView,
|
||||||
|
children: [
|
||||||
|
{path: 'login', name: '系统登录',component: UserLogin, meta: {fullscreen: true}},
|
||||||
|
]
|
||||||
|
}, {
|
||||||
|
path: '/console',
|
||||||
|
name: '系统管理',
|
||||||
|
component: ConsoleRouterView,
|
||||||
|
children: [
|
||||||
|
{path: 'userList', name: '用户管理',component: ConsoleUserList},
|
||||||
|
{path: 'roleList', name: '权限管理',component: ConsoleRoleList},
|
||||||
|
{path: 'authList', name: '角色列表',component: ConsoleAuthList},
|
||||||
|
]
|
||||||
|
}, {
|
||||||
|
path: '/common',
|
||||||
|
name: '',
|
||||||
|
component: UserRouterView,
|
||||||
|
children: [
|
||||||
|
{path: 'noAuth', name: '没有权限',component: CommonNoAuth},
|
||||||
|
]
|
||||||
|
}, {
|
||||||
|
path: '/',
|
||||||
|
redirect: '/home'
|
||||||
|
}
|
||||||
|
];
|
||||||
|
|
||||||
|
export default routes;
|
||||||
2
zyplayer-doc-ui/console-ui/src/vendor.js
Normal file
2
zyplayer-doc-ui/console-ui/src/vendor.js
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
import Vue from 'vue'
|
||||||
|
import ElementUI from 'element-ui'
|
||||||
18
zyplayer-doc-ui/console-ui/src/views/common/NoAuth.vue
Normal file
18
zyplayer-doc-ui/console-ui/src/views/common/NoAuth.vue
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
<template>
|
||||||
|
<div>没有权限访问该模块</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {};
|
||||||
|
},
|
||||||
|
mounted: function () {
|
||||||
|
},
|
||||||
|
methods: {}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
<style>
|
||||||
|
|
||||||
|
</style>
|
||||||
|
|
||||||
73
zyplayer-doc-ui/console-ui/src/views/console/AuthList.vue
Normal file
73
zyplayer-doc-ui/console-ui/src/views/console/AuthList.vue
Normal file
@@ -0,0 +1,73 @@
|
|||||||
|
<template>
|
||||||
|
<div>
|
||||||
|
<div style="border-bottom: 1px solid #eee;padding: 10px;margin-bottom: 10px;">权限列表</div>
|
||||||
|
<div style="padding: 10px;">
|
||||||
|
<el-table :data="searchResultList" border style="width: 100%; margin-bottom: 5px;" max-height="500">
|
||||||
|
<el-table-column prop="id" label="编号" width="60"></el-table-column>
|
||||||
|
<el-table-column prop="name" label="权限名"></el-table-column>
|
||||||
|
<el-table-column prop="spaceExplain" label="权限说明"></el-table-column>
|
||||||
|
<el-table-column prop="createTime" label="创建时间"></el-table-column>
|
||||||
|
</el-table>
|
||||||
|
</div>
|
||||||
|
<div class="page-info-box">
|
||||||
|
<el-pagination
|
||||||
|
@size-change="handleSizeChange"
|
||||||
|
@current-change="handleCurrentChange"
|
||||||
|
:page-sizes="[20, 50, 100]"
|
||||||
|
:page-size="20"
|
||||||
|
:current-page="searchParam.pageNum"
|
||||||
|
layout="prev, pager, next, jumper, sizes, total"
|
||||||
|
:total="totalCount"
|
||||||
|
>
|
||||||
|
</el-pagination>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
var app;
|
||||||
|
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
editUserDialogVisible: false,
|
||||||
|
totalCount: 0,
|
||||||
|
searchParam: {
|
||||||
|
type: 1,
|
||||||
|
keyword: '',
|
||||||
|
pageSize: 20,
|
||||||
|
pageNum: 1,
|
||||||
|
},
|
||||||
|
searchResultList: [
|
||||||
|
{name: '张三'}
|
||||||
|
],
|
||||||
|
roleOptions: [
|
||||||
|
{value: '管理员'}
|
||||||
|
],
|
||||||
|
editUserForm: {},
|
||||||
|
};
|
||||||
|
},
|
||||||
|
mounted: function () {
|
||||||
|
app = this;
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
handleSizeChange(val) {
|
||||||
|
this.searchParam.pageSize = val;
|
||||||
|
},
|
||||||
|
handleCurrentChange(val) {
|
||||||
|
this.searchParam.pageNum = val;
|
||||||
|
},
|
||||||
|
editUserInfo() {
|
||||||
|
this.editUserDialogVisible = true;
|
||||||
|
},
|
||||||
|
resetPassword() {
|
||||||
|
},
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
</script>
|
||||||
|
<style>
|
||||||
|
.search-form-box{padding: 10px;}
|
||||||
|
.page-info-box{text-align: right;margin: 20px 0 50px 0;}
|
||||||
|
</style>
|
||||||
|
|
||||||
125
zyplayer-doc-ui/console-ui/src/views/console/RoleList.vue
Normal file
125
zyplayer-doc-ui/console-ui/src/views/console/RoleList.vue
Normal file
@@ -0,0 +1,125 @@
|
|||||||
|
<template>
|
||||||
|
<div>
|
||||||
|
<div style="border-bottom: 1px solid #eee;padding: 10px;margin-bottom: 10px;">角色管理</div>
|
||||||
|
<el-form :inline="true" :model="searchParam" class="search-form-box">
|
||||||
|
<el-form-item label="搜索类型">
|
||||||
|
<el-select v-model="searchParam.type" placeholder="请选择">
|
||||||
|
<el-option label="角色名" :value="1"></el-option>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="关键字">
|
||||||
|
<el-input v-model="searchParam.keyword" placeholder="输入关键字"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item>
|
||||||
|
<el-button type="primary" @click="">查询</el-button>
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
<div style="padding: 10px;">
|
||||||
|
<el-table :data="searchResultList" border style="width: 100%; margin-bottom: 5px;" max-height="500">
|
||||||
|
<el-table-column prop="id" label="编号" width="60"></el-table-column>
|
||||||
|
<el-table-column prop="name" label="角色名"></el-table-column>
|
||||||
|
<el-table-column prop="spaceExplain" label="CODE"></el-table-column>
|
||||||
|
<el-table-column prop="createTime" label="创建时间"></el-table-column>
|
||||||
|
<el-table-column label="操作">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<el-button size="small" plain type="primary" v-on:click="editUserInfo(scope.row)">修改</el-button>
|
||||||
|
<el-button size="small" plain type="primary" v-on:click="resetPassword(scope.row)">权限管理</el-button>
|
||||||
|
<el-button size="small" plain type="warning" v-on:click="editUserInfo(scope.row)">删除</el-button>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</el-table>
|
||||||
|
</div>
|
||||||
|
<div class="page-info-box">
|
||||||
|
<el-pagination
|
||||||
|
@size-change="handleSizeChange"
|
||||||
|
@current-change="handleCurrentChange"
|
||||||
|
:page-sizes="[20, 50, 100]"
|
||||||
|
:page-size="20"
|
||||||
|
:current-page="searchParam.pageNum"
|
||||||
|
layout="prev, pager, next, jumper, sizes, total"
|
||||||
|
:total="totalCount"
|
||||||
|
>
|
||||||
|
</el-pagination>
|
||||||
|
</div>
|
||||||
|
<!--修改用户弹窗-->
|
||||||
|
<el-dialog title="修改用户" :visible.sync="editUserDialogVisible" width="600px">
|
||||||
|
<el-form ref="form" :model="editUserForm" label-width="80px">
|
||||||
|
<el-form-item label="账号">
|
||||||
|
<el-input v-model="editUserForm.name"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="用户名">
|
||||||
|
<el-input v-model="editUserForm.name"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="手机号">
|
||||||
|
<el-input v-model="editUserForm.name"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="邮箱">
|
||||||
|
<el-input v-model="editUserForm.name"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="性别">
|
||||||
|
<el-radio-group v-model="editUserForm.resource">
|
||||||
|
<el-radio label="男"></el-radio>
|
||||||
|
<el-radio label="女"></el-radio>
|
||||||
|
</el-radio-group>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="角色">
|
||||||
|
<el-select v-model="editUserForm.xx" multiple filterable placeholder="请选择">
|
||||||
|
<el-option v-for="item in roleOptions" :key="item.value" :label="item.label" :value="item.value"></el-option>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item>
|
||||||
|
<el-button type="primary" @click="">确定</el-button>
|
||||||
|
<el-button>取消</el-button>
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
</el-dialog>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
var app;
|
||||||
|
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
editUserDialogVisible: false,
|
||||||
|
totalCount: 0,
|
||||||
|
searchParam: {
|
||||||
|
type: 1,
|
||||||
|
keyword: '',
|
||||||
|
pageSize: 20,
|
||||||
|
pageNum: 1,
|
||||||
|
},
|
||||||
|
searchResultList: [
|
||||||
|
{name: '张三'}
|
||||||
|
],
|
||||||
|
roleOptions: [
|
||||||
|
{value: '管理员'}
|
||||||
|
],
|
||||||
|
editUserForm: {},
|
||||||
|
};
|
||||||
|
},
|
||||||
|
mounted: function () {
|
||||||
|
app = this;
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
handleSizeChange(val) {
|
||||||
|
this.searchParam.pageSize = val;
|
||||||
|
},
|
||||||
|
handleCurrentChange(val) {
|
||||||
|
this.searchParam.pageNum = val;
|
||||||
|
},
|
||||||
|
editUserInfo() {
|
||||||
|
this.editUserDialogVisible = true;
|
||||||
|
},
|
||||||
|
resetPassword() {
|
||||||
|
},
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
</script>
|
||||||
|
<style>
|
||||||
|
.search-form-box{padding: 10px;}
|
||||||
|
.page-info-box{text-align: right;margin: 20px 0 50px 0;}
|
||||||
|
</style>
|
||||||
|
|
||||||
@@ -0,0 +1,4 @@
|
|||||||
|
<template>
|
||||||
|
<router-view></router-view>
|
||||||
|
</template>
|
||||||
|
|
||||||
136
zyplayer-doc-ui/console-ui/src/views/console/UserList.vue
Normal file
136
zyplayer-doc-ui/console-ui/src/views/console/UserList.vue
Normal file
@@ -0,0 +1,136 @@
|
|||||||
|
<template>
|
||||||
|
<div>
|
||||||
|
<div style="border-bottom: 1px solid #fafafa;padding: 10px;margin-bottom: 10px;">用户管理</div>
|
||||||
|
<el-form :inline="true" :model="searchParam" class="search-form-box">
|
||||||
|
<el-form-item label="搜索类型">
|
||||||
|
<el-select v-model="searchParam.type" placeholder="请选择">
|
||||||
|
<el-option label="ID" :value="1"></el-option>
|
||||||
|
<el-option label="账号" :value="2"></el-option>
|
||||||
|
<el-option label="用户名" :value="3"></el-option>
|
||||||
|
<el-option label="手机" :value="4"></el-option>
|
||||||
|
<el-option label="邮箱" :value="5"></el-option>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="关键字">
|
||||||
|
<el-input v-model="searchParam.keyword" placeholder="输入关键字"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item>
|
||||||
|
<el-button type="primary" @click="">查询</el-button>
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
<div style="padding: 10px;">
|
||||||
|
<el-table :data="searchResultList" border style="width: 100%; margin-bottom: 5px;" max-height="500">
|
||||||
|
<el-table-column prop="id" label="编号" width="60"></el-table-column>
|
||||||
|
<el-table-column prop="name" label="账号"></el-table-column>
|
||||||
|
<el-table-column prop="spaceExplain" label="用户名"></el-table-column>
|
||||||
|
<el-table-column prop="createUserName" label="手机号"></el-table-column>
|
||||||
|
<el-table-column prop="createUserName" label="性别"></el-table-column>
|
||||||
|
<el-table-column prop="createTime" label="创建时间"></el-table-column>
|
||||||
|
<el-table-column label="状态">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<el-switch v-model="scope.row.status" active-text="正常" inactive-text="停用">
|
||||||
|
</el-switch>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="操作">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<el-button size="small" plain type="primary" v-on:click="editUserInfo(scope.row)">修改</el-button>
|
||||||
|
<el-button size="small" plain type="warning" v-on:click="resetPassword(scope.row)">重置密码</el-button>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</el-table>
|
||||||
|
</div>
|
||||||
|
<div class="page-info-box">
|
||||||
|
<el-pagination
|
||||||
|
@size-change="handleSizeChange"
|
||||||
|
@current-change="handleCurrentChange"
|
||||||
|
:page-sizes="[20, 50, 100]"
|
||||||
|
:page-size="20"
|
||||||
|
:current-page="searchParam.pageNum"
|
||||||
|
layout="prev, pager, next, jumper, sizes, total"
|
||||||
|
:total="totalCount"
|
||||||
|
>
|
||||||
|
</el-pagination>
|
||||||
|
</div>
|
||||||
|
<!--修改用户弹窗-->
|
||||||
|
<el-dialog title="修改用户" :visible.sync="editUserDialogVisible" width="600px">
|
||||||
|
<el-form ref="form" :model="editUserForm" label-width="80px">
|
||||||
|
<el-form-item label="账号">
|
||||||
|
<el-input v-model="editUserForm.name"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="用户名">
|
||||||
|
<el-input v-model="editUserForm.name"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="手机号">
|
||||||
|
<el-input v-model="editUserForm.name"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="邮箱">
|
||||||
|
<el-input v-model="editUserForm.name"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="性别">
|
||||||
|
<el-radio-group v-model="editUserForm.resource">
|
||||||
|
<el-radio label="男"></el-radio>
|
||||||
|
<el-radio label="女"></el-radio>
|
||||||
|
</el-radio-group>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="角色">
|
||||||
|
<el-select v-model="editUserForm.xx" multiple filterable placeholder="请选择">
|
||||||
|
<el-option v-for="item in roleOptions" :key="item.value" :label="item.label" :value="item.value"></el-option>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item>
|
||||||
|
<el-button type="primary" @click="">确定</el-button>
|
||||||
|
<el-button>取消</el-button>
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
</el-dialog>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
var app;
|
||||||
|
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
editUserDialogVisible: false,
|
||||||
|
totalCount: 0,
|
||||||
|
searchParam: {
|
||||||
|
type: 1,
|
||||||
|
keyword: '',
|
||||||
|
pageSize: 20,
|
||||||
|
pageNum: 1,
|
||||||
|
},
|
||||||
|
searchResultList: [
|
||||||
|
{name: '张三'}
|
||||||
|
],
|
||||||
|
roleOptions: [
|
||||||
|
{value: '管理员'}
|
||||||
|
],
|
||||||
|
editUserForm: {},
|
||||||
|
};
|
||||||
|
},
|
||||||
|
mounted: function () {
|
||||||
|
app = this;
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
handleSizeChange(val) {
|
||||||
|
this.searchParam.pageSize = val;
|
||||||
|
},
|
||||||
|
handleCurrentChange(val) {
|
||||||
|
this.searchParam.pageNum = val;
|
||||||
|
},
|
||||||
|
editUserInfo() {
|
||||||
|
this.editUserDialogVisible = true;
|
||||||
|
},
|
||||||
|
resetPassword() {
|
||||||
|
},
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
</script>
|
||||||
|
<style>
|
||||||
|
.search-form-box{padding: 10px;}
|
||||||
|
.page-info-box{text-align: right;margin: 20px 0 50px 0;}
|
||||||
|
</style>
|
||||||
|
|
||||||
146
zyplayer-doc-ui/console-ui/src/views/home/Home.vue
Normal file
146
zyplayer-doc-ui/console-ui/src/views/home/Home.vue
Normal file
@@ -0,0 +1,146 @@
|
|||||||
|
<template>
|
||||||
|
<div style="padding: 10px;">
|
||||||
|
<div style="max-width: 800px;margin: 20px auto;">
|
||||||
|
<div style="text-align: center;">欢迎使用ヾ(๑╹◡╹)ノ" - 今天也要加油鸭</div>
|
||||||
|
<div style="padding: 20px;">
|
||||||
|
<el-card class="box-card">
|
||||||
|
<div slot="header" class="clearfix">
|
||||||
|
<span>吾家产品线</span>
|
||||||
|
</div>
|
||||||
|
<div class="product-list">
|
||||||
|
<div class="item" v-on:click="jumpToDocPage('doc-swagger')">
|
||||||
|
<div class="logo-text text1">swagger</div>
|
||||||
|
<div>swagger文档</div>
|
||||||
|
</div>
|
||||||
|
<div class="item" v-on:click="jumpToDocPage('doc-db')">
|
||||||
|
<div class="logo-text text2">DB</div>
|
||||||
|
<div>数据库文档</div>
|
||||||
|
</div>
|
||||||
|
<div class="item" v-on:click="jumpToDocPage('doc-wiki')">
|
||||||
|
<div class="logo-text text3">WIKI</div>
|
||||||
|
<div>WIKI文档</div>
|
||||||
|
</div>
|
||||||
|
<div class="item" v-on:click="jumpToDocPage('doc-dubbo')">
|
||||||
|
<div class="logo-img"><img src="../../assets/img/dubbo.png"></div>
|
||||||
|
<div>dubbo文档</div>
|
||||||
|
</div>
|
||||||
|
<el-tooltip effect="dark" content="不成熟,欢迎完善" placement="top-start">
|
||||||
|
<div class="item disabled">
|
||||||
|
<div class="logo-text text4">GRPC</div>
|
||||||
|
<div>GRPC文档</div>
|
||||||
|
</div>
|
||||||
|
</el-tooltip>
|
||||||
|
</div>
|
||||||
|
</el-card>
|
||||||
|
</div>
|
||||||
|
<div style="padding: 20px;">
|
||||||
|
<el-card class="box-card">
|
||||||
|
<div slot="header" class="clearfix">
|
||||||
|
<span>二方库-集成代理版</span>
|
||||||
|
<a target="_blank" href="http://doc.zyplayer.com/zyplayer-doc-manage/doc-wiki#/page/show?spaceId=1&pageId=76"><i class="el-icon-info" style="color: #999;"></i></a>
|
||||||
|
</div>
|
||||||
|
<div class="product-list">
|
||||||
|
<el-tooltip effect="dark" content="swagger的原生官方文档" placement="top-start">
|
||||||
|
<div class="item" v-on:click="jumpToDocPage('swagger-ui.html')">
|
||||||
|
<div class="logo-text text1">swagger</div>
|
||||||
|
<div>原生文档</div>
|
||||||
|
</div>
|
||||||
|
</el-tooltip>
|
||||||
|
<el-tooltip effect="dark" content="swagger-bootstrap-ui文档" placement="top-start">
|
||||||
|
<div class="item" v-on:click="jumpToDocPage('doc.html')">
|
||||||
|
<div class="logo-text text2">swagger</div>
|
||||||
|
<div>二方文档</div>
|
||||||
|
</div>
|
||||||
|
</el-tooltip>
|
||||||
|
</div>
|
||||||
|
</el-card>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import toast from '../../common/lib/common/toast'
|
||||||
|
import global from '../../common/config/global'
|
||||||
|
|
||||||
|
var app;
|
||||||
|
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
totalCount: 0,
|
||||||
|
searchParam: {
|
||||||
|
spaceId: '',
|
||||||
|
newsType: 1,
|
||||||
|
pageNum: 1,
|
||||||
|
pageSize: 20,
|
||||||
|
},
|
||||||
|
spacePageNews:[],
|
||||||
|
newsTypes:["最近更新", "最新创建", "查看最多", "点赞最多", "查看+点赞最多"],
|
||||||
|
};
|
||||||
|
},
|
||||||
|
beforeRouteUpdate(to, from, next) {
|
||||||
|
this.initQueryParam(to);
|
||||||
|
next();
|
||||||
|
},
|
||||||
|
mounted: function () {
|
||||||
|
this.initQueryParam(this.$route);
|
||||||
|
app = this;
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
getSpacePageNews() {
|
||||||
|
this.common.post(this.apilist1.pageNews, this.searchParam, function (json) {
|
||||||
|
app.spacePageNews = json.data || [];
|
||||||
|
app.totalCount = json.total;
|
||||||
|
});
|
||||||
|
},
|
||||||
|
jumpToDocPage(val) {
|
||||||
|
window.open(val);
|
||||||
|
},
|
||||||
|
handleSizeChange(val) {
|
||||||
|
this.searchParam.pageSize = val;
|
||||||
|
this.getSpacePageNews();
|
||||||
|
},
|
||||||
|
showPageDetail(row) {
|
||||||
|
this.nowClickPath = {spaceId: row.spaceId, pageId: row.pageId};
|
||||||
|
this.$router.push({path: '/page/show', query: this.nowClickPath});
|
||||||
|
},
|
||||||
|
handleCurrentChange(val) {
|
||||||
|
this.searchParam.pageNum = val;
|
||||||
|
this.getSpacePageNews();
|
||||||
|
},
|
||||||
|
initQueryParam(to) {
|
||||||
|
this.searchParam = {
|
||||||
|
spaceId: to.query.spaceId,
|
||||||
|
newsType: 1,
|
||||||
|
pageNum: 1,
|
||||||
|
pageSize: 20,
|
||||||
|
};
|
||||||
|
if (!!this.searchParam.spaceId) {
|
||||||
|
this.getSpacePageNews();
|
||||||
|
}
|
||||||
|
},
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
<style>
|
||||||
|
.product-list{text-align: left;}
|
||||||
|
.product-list .item{
|
||||||
|
text-align: center;display: inline-block;padding: 10px;border-radius: 5px;cursor: pointer;
|
||||||
|
width: 110px; height: 100px;color: #666;
|
||||||
|
}
|
||||||
|
.product-list .item:hover{background: #ddd;}
|
||||||
|
.product-list .item.disabled{background: #fff;cursor: auto;}
|
||||||
|
.product-list .item.disabled .logo-text{background: #909399;}
|
||||||
|
.product-list .item .logo-text{
|
||||||
|
width: 80px; height: 80px;line-height: 80px;text-align: center; color: #fff;
|
||||||
|
margin: 0 auto;background: #67C23A; border-radius: 50%;overflow: hidden;
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
.product-list .item .logo-text.text1{background: #67C23A;}
|
||||||
|
.product-list .item .logo-text.text2{background: #E6A23C;}
|
||||||
|
.product-list .item .logo-text.text3{background: #F56C6C;}
|
||||||
|
.product-list .item .logo-img{width: 80px; height: 80px;margin: 0 auto;}
|
||||||
|
.product-list .item .logo-img img{width: 65px; height: 65px; margin: 7px;}
|
||||||
|
</style>
|
||||||
|
|
||||||
86
zyplayer-doc-ui/console-ui/src/views/user/Login.vue
Normal file
86
zyplayer-doc-ui/console-ui/src/views/user/Login.vue
Normal file
@@ -0,0 +1,86 @@
|
|||||||
|
<template>
|
||||||
|
<el-form :model="loginParam" :rules="loginRules" ref="loginParam" label-position="left" label-width="0px"
|
||||||
|
class="demo-ruleForm login-container">
|
||||||
|
<h3 class="title">系统登录</h3>
|
||||||
|
<el-form-item prop="userNo">
|
||||||
|
<el-input type="text" v-model="loginParam.userNo" auto-complete="off" placeholder="账号"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item prop="password">
|
||||||
|
<el-input type="password" v-model="loginParam.password" auto-complete="off" placeholder="密码"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item style="width:100%;">
|
||||||
|
<el-button type="primary" style="width:100%;" @click.native.prevent="loginSubmit" :loading="logining">登录
|
||||||
|
</el-button>
|
||||||
|
<!--<el-button @click.native.prevent="handleReset2">重置</el-button>-->
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
logining: false,
|
||||||
|
loginParam: {
|
||||||
|
userNo: '',
|
||||||
|
password: ''
|
||||||
|
},
|
||||||
|
loginRules: {
|
||||||
|
userNo: [
|
||||||
|
{required: true, message: '请输入账号', trigger: 'blur'},
|
||||||
|
],
|
||||||
|
password: [
|
||||||
|
{required: true, message: '请输入密码', trigger: 'blur'},
|
||||||
|
]
|
||||||
|
},
|
||||||
|
checked: true
|
||||||
|
};
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
loginSubmit(ev) {
|
||||||
|
var that = this;
|
||||||
|
this.$refs.loginParam.validate((valid) => {
|
||||||
|
if (!valid) return;
|
||||||
|
that.common.post(that.apilist1.userLogin, that.loginParam, function (json) {
|
||||||
|
// 设置cookie
|
||||||
|
var token = escape(json.data);
|
||||||
|
var exp = new Date();
|
||||||
|
exp.setTime(exp.getTime() + 30 * 24 * 60 * 60 * 1000);
|
||||||
|
document.cookie = "accessToken=" + token + ";expires=" + exp.toGMTString();
|
||||||
|
that.common.setAccessToken(token);
|
||||||
|
// 跳转
|
||||||
|
that.global.user.isLogin = true;
|
||||||
|
that.$router.push("/user/wxLogin");
|
||||||
|
});
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
</script>
|
||||||
|
<style>
|
||||||
|
.login-container {
|
||||||
|
-webkit-border-radius: 5px;
|
||||||
|
border-radius: 5px;
|
||||||
|
-moz-border-radius: 5px;
|
||||||
|
background-clip: padding-box;
|
||||||
|
margin: 80px auto;
|
||||||
|
width: 350px;
|
||||||
|
padding: 35px 35px 15px 35px;
|
||||||
|
background: #fff;
|
||||||
|
border: 1px solid #eaeaea;
|
||||||
|
box-shadow: 0 0 25px #cac6c6;
|
||||||
|
}
|
||||||
|
|
||||||
|
.title {
|
||||||
|
margin: 0px auto 40px auto;
|
||||||
|
text-align: center;
|
||||||
|
color: #505458;
|
||||||
|
}
|
||||||
|
|
||||||
|
.remember {
|
||||||
|
margin: 0px 0px 35px 0px;
|
||||||
|
}
|
||||||
|
|
||||||
|
</style>
|
||||||
|
|
||||||
4
zyplayer-doc-ui/console-ui/src/views/user/RouterView.vue
Normal file
4
zyplayer-doc-ui/console-ui/src/views/user/RouterView.vue
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
<template>
|
||||||
|
<router-view></router-view>
|
||||||
|
</template>
|
||||||
|
|
||||||
74
zyplayer-doc-ui/console-ui/webpack.config.js
Normal file
74
zyplayer-doc-ui/console-ui/webpack.config.js
Normal file
@@ -0,0 +1,74 @@
|
|||||||
|
const resolve = require('path').resolve;
|
||||||
|
const webpack = require('webpack');
|
||||||
|
const HtmlWebpackPlugin = require('html-webpack-plugin');
|
||||||
|
const url = require('url');
|
||||||
|
const publicPath = '';
|
||||||
|
|
||||||
|
module.exports = (options = {}) => ({
|
||||||
|
entry: {
|
||||||
|
vendor: './src/vendor',
|
||||||
|
index: './src/main.js'
|
||||||
|
},
|
||||||
|
output: {
|
||||||
|
path: resolve(__dirname, 'dist'),
|
||||||
|
filename: options.dev ? '[name].js' : '[name].js?[chunkhash]',
|
||||||
|
chunkFilename: '[id].js?[chunkhash]',
|
||||||
|
publicPath: options.dev ? '/assets/' : publicPath
|
||||||
|
},
|
||||||
|
module: {
|
||||||
|
rules: [{
|
||||||
|
test: /\.vue$/,
|
||||||
|
use: ['vue-loader']
|
||||||
|
},
|
||||||
|
{
|
||||||
|
test: /\.js$/,
|
||||||
|
use: ['babel-loader'],
|
||||||
|
exclude: /node_modules/
|
||||||
|
},
|
||||||
|
{
|
||||||
|
test: /\.css$/,
|
||||||
|
use: ['style-loader', 'css-loader', 'postcss-loader']
|
||||||
|
},
|
||||||
|
{
|
||||||
|
test: /\.(png|jpg|jpeg|gif|eot|ttf|woff|woff2|svg|svgz)(\?.+)?$/,
|
||||||
|
use: [{
|
||||||
|
loader: 'url-loader',
|
||||||
|
options: {
|
||||||
|
limit: 10000
|
||||||
|
}
|
||||||
|
}]
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
plugins: [
|
||||||
|
new webpack.optimize.CommonsChunkPlugin({
|
||||||
|
names: ['vendor', 'manifest']
|
||||||
|
}),
|
||||||
|
new HtmlWebpackPlugin({
|
||||||
|
template: 'src/index.html'
|
||||||
|
})
|
||||||
|
],
|
||||||
|
resolve: {
|
||||||
|
alias: {
|
||||||
|
'~': resolve(__dirname, 'src')
|
||||||
|
},
|
||||||
|
extensions: ['.js', '.vue', '.json', '.css']
|
||||||
|
},
|
||||||
|
devServer: {
|
||||||
|
host: 'local.zyplayer.com',
|
||||||
|
port: 8010,
|
||||||
|
proxy: {
|
||||||
|
'/api/': {
|
||||||
|
target: 'http://local.zyplayer.com:8080',
|
||||||
|
changeOrigin: true,
|
||||||
|
pathRewrite: {
|
||||||
|
'^/api': ''
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
historyApiFallback: {
|
||||||
|
index: url.parse(options.dev ? '/assets/' : publicPath).pathname
|
||||||
|
}
|
||||||
|
},
|
||||||
|
devtool: options.dev ? '#eval-source-map' : '#source-map'
|
||||||
|
});
|
||||||
4071
zyplayer-doc-ui/console-ui/yarn.lock
Normal file
4071
zyplayer-doc-ui/console-ui/yarn.lock
Normal file
File diff suppressed because it is too large
Load Diff
@@ -5,7 +5,7 @@
|
|||||||
|
|
||||||
<groupId>com.zyplayer</groupId>
|
<groupId>com.zyplayer</groupId>
|
||||||
<artifactId>zyplayer-doc-wiki</artifactId>
|
<artifactId>zyplayer-doc-wiki</artifactId>
|
||||||
<version>1.0.1</version>
|
<version>1.0.2</version>
|
||||||
<packaging>jar</packaging>
|
<packaging>jar</packaging>
|
||||||
<name>zyplayer-doc-wiki</name>
|
<name>zyplayer-doc-wiki</name>
|
||||||
<description>wiki文档工具</description>
|
<description>wiki文档工具</description>
|
||||||
@@ -32,7 +32,7 @@
|
|||||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||||
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
|
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
|
||||||
<java.version>1.8</java.version>
|
<java.version>1.8</java.version>
|
||||||
<zyplayer.doc.version>1.0.1</zyplayer.doc.version>
|
<zyplayer.doc.version>1.0.2</zyplayer.doc.version>
|
||||||
<!-- 打包跳过单元测试 -->
|
<!-- 打包跳过单元测试 -->
|
||||||
<skipTests>true</skipTests>
|
<skipTests>true</skipTests>
|
||||||
<destDir>${project.build.outputDirectory}/META-INF/resources/webjars/${project.artifactId}/${project.version}</destDir>
|
<destDir>${project.build.outputDirectory}/META-INF/resources/webjars/${project.artifactId}/${project.version}</destDir>
|
||||||
|
|||||||
@@ -1,14 +1,17 @@
|
|||||||
<!DOCTYPE HTML>
|
<!DOCTYPE HTML>
|
||||||
<html lang="en">
|
<html lang="en">
|
||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8">
|
<meta charset="UTF-8">
|
||||||
<meta content="text/html; charset=utf-8" http-equiv="Content-Type">
|
<meta content="text/html; charset=utf-8" http-equiv="Content-Type">
|
||||||
<title>wiki文档管理系统</title>
|
<title>wiki文档管理系统</title>
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
<body>
|
<body>
|
||||||
<div id="app"></div>
|
<div id="app"></div>
|
||||||
<script type="text/javascript" src="manifest.js?d019d6194cc995a8346a"></script><script type="text/javascript" src="vendor.js?82212d6e35030c02aff9"></script><script type="text/javascript" src="index.js?e0d7e5de80109913da55"></script></body>
|
<script type="text/javascript" src="doc-wiki-manifest.js?d019d6194cc995a8346a"></script>
|
||||||
|
<script type="text/javascript" src="doc-wiki-vendor.js?82212d6e35030c02aff9"></script>
|
||||||
|
<script type="text/javascript" src="doc-wiki-index.js?e0d7e5de80109913da55"></script>
|
||||||
|
</body>
|
||||||
|
|
||||||
</html>
|
</html>
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user