Quellcode durchsuchen

增加zheng-upms-client单点登录客户端工具模块

shuzheng vor 8 Jahren
Ursprung
Commit
1d4c3ef9c2

+ 3 - 2
README.md

@@ -4,10 +4,11 @@
 ``` lua
 zheng
 ├── zheng-common -- 公共模块
-├── zheng-upms -- 通用用户权限系统
+├── zheng-upms -- 用户权限管理系统
 |    ├── zheng-upms-dao -- 数据库MyBatisGenerator操作
 |    ├── zheng-upms-service -- 业务逻辑
-|    └── zheng-upms-admin -- 后台管理
+|    ├── zheng-upms-client -- SSO登录客户端
+|    └── zheng-upms-server -- 系统及SSO服务端
 ├── zheng-cms -- 内容管理系统
 |    ├── zheng-cms-dao -- 数据库MyBatisGenerator操作
 |    ├── zheng-cms-service -- 业务逻辑

+ 1 - 0
zheng-upms/pom.xml

@@ -22,5 +22,6 @@
         <module>zheng-upms-dao</module>
         <module>zheng-upms-service</module>
         <module>zheng-upms-admin</module>
+        <module>zheng-upms-client</module>
     </modules>
 </project>

+ 28 - 0
zheng-upms/zheng-upms-client/pom.xml

@@ -0,0 +1,28 @@
+<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">
+    <parent>
+        <artifactId>zheng-upms</artifactId>
+        <groupId>com.zheng</groupId>
+        <version>1.0.0</version>
+    </parent>
+    <modelVersion>4.0.0</modelVersion>
+
+    <artifactId>zheng-upms-client</artifactId>
+    <packaging>jar</packaging>
+
+    <name>zheng-upms-client</name>
+    <url>http://maven.apache.org</url>
+
+    <properties>
+        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
+    </properties>
+
+    <dependencies>
+        <dependency>
+            <groupId>junit</groupId>
+            <artifactId>junit</artifactId>
+            <version>3.8.1</version>
+            <scope>test</scope>
+        </dependency>
+    </dependencies>
+</project>

+ 13 - 0
zheng-upms/zheng-upms-client/src/main/java/com/zheng/App.java

@@ -0,0 +1,13 @@
+package com.zheng;
+
+/**
+ * Hello world!
+ *
+ */
+public class App 
+{
+    public static void main( String[] args )
+    {
+        System.out.println( "Hello World!" );
+    }
+}

+ 38 - 0
zheng-upms/zheng-upms-client/src/test/java/com/zheng/AppTest.java

@@ -0,0 +1,38 @@
+package com.zheng;
+
+import junit.framework.Test;
+import junit.framework.TestCase;
+import junit.framework.TestSuite;
+
+/**
+ * Unit test for simple App.
+ */
+public class AppTest 
+    extends TestCase
+{
+    /**
+     * Create the test case
+     *
+     * @param testName name of the test case
+     */
+    public AppTest( String testName )
+    {
+        super( testName );
+    }
+
+    /**
+     * @return the suite of tests being tested
+     */
+    public static Test suite()
+    {
+        return new TestSuite( AppTest.class );
+    }
+
+    /**
+     * Rigourous Test :-)
+     */
+    public void testApp()
+    {
+        assertTrue( true );
+    }
+}

+ 108 - 0
zheng-upms/zheng-upms-server/pom.xml

@@ -0,0 +1,108 @@
+<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/maven-v4_0_0.xsd">
+    <modelVersion>4.0.0</modelVersion>
+
+    <parent>
+        <groupId>com.zheng</groupId>
+        <artifactId>zheng-upms</artifactId>
+        <version>1.0.0</version>
+    </parent>
+
+    <artifactId>zheng-upms-server</artifactId>
+    <packaging>war</packaging>
+
+    <name>zheng-upms-server Maven Webapp</name>
+    <url>http://www.zhangshuzheng.cn</url>
+
+    <dependencies>
+        <dependency>
+            <groupId>com.zheng</groupId>
+            <artifactId>zheng-upms-service</artifactId>
+            <version>1.0.0</version>
+            <type>jar</type>
+        </dependency>
+        <dependency>
+            <groupId>junit</groupId>
+            <artifactId>junit</artifactId>
+            <version>4.12</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>javax.servlet</groupId>
+            <artifactId>servlet-api</artifactId>
+            <version>2.5</version>
+            <scope>provided</scope>
+        </dependency>
+        <dependency>
+            <groupId>javax.servlet</groupId>
+            <artifactId>jstl</artifactId>
+            <version>1.2</version>
+        </dependency>
+    </dependencies>
+
+    <profiles>
+        <profile>
+            <id>dev</id>
+            <properties>
+                <env>dev</env>
+            </properties>
+            <activation>
+                <activeByDefault>true</activeByDefault>
+            </activation>
+        </profile>
+        <profile>
+            <id>test</id>
+            <properties>
+                <env>test</env>
+            </properties>
+        </profile>
+        <profile>
+            <id>prod</id>
+            <properties>
+                <env>prod</env>
+            </properties>
+        </profile>
+    </profiles>
+
+    <build>
+        <finalName>zheng-upms-server</finalName>
+        <filters>
+            <filter>src/main/resources/profiles/${env}.properties</filter>
+        </filters>
+        <resources>
+            <resource>
+                <directory>src/main/resources</directory>
+                <filtering>true</filtering>
+            </resource>
+        </resources>
+        <plugins>
+            <!-- jetty插件 -->
+            <plugin>
+                <groupId>org.eclipse.jetty</groupId>
+                <artifactId>jetty-maven-plugin</artifactId>
+                <version>9.0.0.v20130308</version>
+                <configuration>
+                    <scanIntervalSeconds>3</scanIntervalSeconds>
+                    <webApp>
+                        <contextPath>/zheng-upms-server</contextPath>
+                    </webApp>
+                    <httpConnector>
+                        <port>8080</port>
+                    </httpConnector>
+                    <reload>automatic</reload>
+                </configuration>
+            </plugin>
+            <plugin>
+                <groupId>org.apache.maven.plugins</groupId>
+                <artifactId>maven-surefire-plugin</artifactId>
+                <version>2.18.1</version>
+                <configuration>
+                    <!--是否跳过单元测试-->
+                    <skipTests>true</skipTests>
+                    <!--是否忽略单元测试错误-->
+                    <testFailureIgnore>true</testFailureIgnore>
+                </configuration>
+            </plugin>
+        </plugins>
+    </build>
+</project>

+ 15 - 0
zheng-upms/zheng-upms-server/src/main/java/com/zheng/upms/admin/BaseController.java

@@ -0,0 +1,15 @@
+package com.zheng.upms.admin;
+
+/**
+ * 控制器基类
+ * @author shuzheng
+ * @date 2016年7月7日 上午10:08:47
+ */
+public class BaseController {
+	
+	public static final String RESULT = "result";
+	public static final String DATA = "data";
+	public static final String SUCCESS = "success";
+	public static final String FAILED = "failed";
+
+}

+ 0 - 0
zheng-upms/zheng-upms-admin/src/main/resources/applicationContext-threadpool.xml → zheng-upms/zheng-upms-server/src/main/resources/applicationContext-threadpool.xml


+ 0 - 0
zheng-upms/zheng-upms-admin/src/main/resources/config.properties → zheng-upms/zheng-upms-server/src/main/resources/config.properties


+ 0 - 0
zheng-upms/zheng-upms-admin/src/main/resources/log4j.properties → zheng-upms/zheng-upms-server/src/main/resources/log4j.properties


+ 0 - 0
zheng-upms/zheng-upms-admin/src/main/resources/profiles/dev.properties → zheng-upms/zheng-upms-server/src/main/resources/profiles/dev.properties


+ 0 - 0
zheng-upms/zheng-upms-admin/src/main/resources/profiles/prod.properties → zheng-upms/zheng-upms-server/src/main/resources/profiles/prod.properties


+ 0 - 0
zheng-upms/zheng-upms-admin/src/main/resources/profiles/test.properties → zheng-upms/zheng-upms-server/src/main/resources/profiles/test.properties


+ 0 - 0
zheng-upms/zheng-upms-admin/src/main/resources/springMVC-servlet.xml → zheng-upms/zheng-upms-server/src/main/resources/springMVC-servlet.xml


+ 0 - 0
zheng-upms/zheng-upms-admin/src/main/webapp/WEB-INF/jsp/404.jsp → zheng-upms/zheng-upms-server/src/main/webapp/WEB-INF/jsp/404.jsp


+ 0 - 0
zheng-upms/zheng-upms-admin/src/main/webapp/WEB-INF/jsp/500.jsp → zheng-upms/zheng-upms-server/src/main/webapp/WEB-INF/jsp/500.jsp


+ 0 - 0
zheng-upms/zheng-upms-admin/src/main/webapp/WEB-INF/jsp/index.jsp → zheng-upms/zheng-upms-server/src/main/webapp/WEB-INF/jsp/index.jsp


+ 0 - 0
zheng-upms/zheng-upms-admin/src/main/webapp/WEB-INF/web.xml → zheng-upms/zheng-upms-server/src/main/webapp/WEB-INF/web.xml