Ver código fonte

first commit

15810770710@163.com 3 anos atrás
pai
commit
9156e4aaca

+ 52 - 0
pom.xml

@@ -0,0 +1,52 @@
+<?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>
+
+    <parent>
+        <groupId>org.springframework.boot</groupId>
+        <artifactId>spring-boot-starter-parent</artifactId>
+        <version>2.2.2.RELEASE</version>
+        <relativePath/> <!-- lookup parent from repository -->
+    </parent>
+
+
+    <groupId>info.aspirecn.iov.sjjh</groupId>
+    <artifactId>iov-sjjh-servicenode-supplier-10000001-interface</artifactId>
+    <version>1.0.0</version>
+
+    <dependencies>
+        <dependency>
+            <groupId>org.springframework.cloud</groupId>
+            <artifactId>spring-cloud-starter-openfeign</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>io.springfox</groupId>
+            <artifactId>springfox-swagger-ui</artifactId>
+            <version>2.9.2</version>
+        </dependency>
+        <dependency>
+            <groupId>io.springfox</groupId>
+            <artifactId>springfox-swagger2</artifactId>
+            <version>2.9.2</version>
+        </dependency>
+        <!--常量-->
+        <dependency>
+            <groupId>info.aspirecn.iov.sjjh</groupId>
+            <artifactId>iov-sjjh-commons-lang</artifactId>
+            <version>1.0.0</version>
+        </dependency>
+    </dependencies>
+    <dependencyManagement>
+        <dependencies>
+            <dependency>
+                <groupId>org.springframework.cloud</groupId>
+                <artifactId>spring-cloud-dependencies</artifactId>
+                <version>Hoxton.RELEASE</version>
+                <type>pom</type>
+                <scope>import</scope>
+            </dependency>
+        </dependencies>
+    </dependencyManagement>
+</project>

+ 61 - 0
src/main/java/info/aspirecn/rdc/iov/sjjh/servicenode/supplier/jk_interface/action/JKChannelAction.java

@@ -0,0 +1,61 @@
+package info.aspirecn.rdc.iov.sjjh.servicenode.supplier.jk_interface.action;
+
+import info.aspirecn.iov.sjjh.commons.lang.ChannelTypeHandleResponseObject;
+import info.aspirecn.rdc.iov.sjjh.servicenode.supplier.jk_interface.vo.EncryptionResponseObject;
+import info.aspirecn.rdc.iov.sjjh.servicenode.supplier.jk_interface.vo.ResponseObject;
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiOperation;
+import io.swagger.annotations.ApiParam;
+import org.springframework.cloud.openfeign.FeignClient;
+import org.springframework.web.bind.annotation.PostMapping;
+import org.springframework.web.bind.annotation.RequestHeader;
+import org.springframework.web.bind.annotation.RequestParam;
+
+/**
+ * @Auther jianggang
+ * @Date 2018/10/24 14:12:49
+ * @Description
+ */
+@Api(value = "交科通道接口")
+@FeignClient(name = "iov-sjjh-servicenode-supplier-10000001")
+public interface JKChannelAction {
+
+    /**
+     *
+     * @param channelId
+     * @param outTime
+     * @param customBody
+     * @return
+     */
+    @ApiOperation(value = "交科身份证二要素验证通道")
+    @PostMapping(value = "/checkIdCardForJK.do")
+    ResponseObject TwoParamIdCard(
+            @ApiParam(name = "通道id", required = true)
+            @RequestHeader(name = "channelId", required = true) String channelId,
+            @ApiParam(name = "超时时间", required = false)
+            @RequestParam(name = "outTime", required = false) Integer outTime,
+            @ApiParam(name = "身份证二要素验证", value = "传入JSON字符串", required = true)
+            @RequestParam(name = "customBody", required = true) String customBody
+    );
+
+    @ApiOperation(value = "移动三要素加密版接口" , notes = "")
+    @PostMapping(value = "/encryptionMobileCheck.do")
+    EncryptionResponseObject encryptionMobileCheck(
+            @RequestHeader(name = "channelId") String channelId,
+            @RequestParam(name = "outTime", required = true) int outTime,
+            @RequestParam(name = "customBody", required = true) String customBody);
+
+    @ApiOperation(value = "测试移动三要素加密版测试接口" , notes = "")
+    @PostMapping(value = "/encryptionMobileCheckNew.do")
+    ChannelTypeHandleResponseObject encryptionMobileCheckNew(
+            @RequestHeader(name = "channelId") String channelId,
+            @RequestParam(name = "outTime", required = true) int outTime,
+            @RequestParam(name = "customBody", required = true) String customBody);
+
+    @ApiOperation(value = "车辆抵押接口" , notes = "")
+    @PostMapping(value = "/vehicleMortgage.do")
+    ChannelTypeHandleResponseObject vehicleMortgage(
+            @RequestHeader(name = "channelId") String channelId,
+            @RequestParam(name = "outTime", required = true) int outTime,
+            @RequestParam(name = "customBody", required = true) String customBody);
+}

+ 1 - 0
src/main/java/info/aspirecn/rdc/iov/sjjh/servicenode/supplier/jk_interface/package-info.java

@@ -0,0 +1 @@
+package info.aspirecn.rdc.iov.sjjh.servicenode.supplier.jk_interface;

+ 26 - 0
src/main/java/info/aspirecn/rdc/iov/sjjh/servicenode/supplier/jk_interface/vo/CustomBodyObject.java

@@ -0,0 +1,26 @@
+package info.aspirecn.rdc.iov.sjjh.servicenode.supplier.jk_interface.vo;
+
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Data;
+
+import java.io.Serializable;
+
+/**
+ * @Auther jianggang
+ * @Date 2018/10/24 14:07:58
+ * @Description
+ */
+
+
+@ApiModel(value = "身份证二要素通道请求参数")
+@Data
+public class CustomBodyObject implements Serializable {
+
+    @ApiModelProperty(value = "姓名" , required = true)
+    private String name;
+
+    @ApiModelProperty(value = "身份证号" , required = true)
+    private String idCode;
+
+}

+ 27 - 0
src/main/java/info/aspirecn/rdc/iov/sjjh/servicenode/supplier/jk_interface/vo/EncryptionMobileCheckResponseObject.java

@@ -0,0 +1,27 @@
+package info.aspirecn.rdc.iov.sjjh.servicenode.supplier.jk_interface.vo;
+
+import com.fasterxml.jackson.annotation.JsonProperty;
+
+import lombok.Data;
+import lombok.ToString;
+
+/**
+ * 三要素核验加密版接口返回对象
+ * @author minmin
+ *
+ */
+@Data
+@ToString(callSuper = true, includeFieldNames = true)
+public class EncryptionMobileCheckResponseObject {
+	/**检验结果码:0和1时扣费*/
+	@JsonProperty(value = "data")
+	private String data;
+	/**接口返回码*/
+	@JsonProperty(value = "code")
+	private String code;
+	/**检验结果信息*/
+	@JsonProperty(value = "msg")
+	private String msg;
+	/**流水号*/
+	private String requestid;
+}

+ 27 - 0
src/main/java/info/aspirecn/rdc/iov/sjjh/servicenode/supplier/jk_interface/vo/EncryptionResponseObject.java

@@ -0,0 +1,27 @@
+package info.aspirecn.rdc.iov.sjjh.servicenode.supplier.jk_interface.vo;
+
+import com.fasterxml.jackson.annotation.JsonInclude;
+import com.fasterxml.jackson.annotation.JsonInclude.Include;
+import lombok.Data;
+import lombok.ToString;
+
+/**
+ * 返回对象
+ * @author minmin
+ *
+ */
+@Data
+@ToString(callSuper = false, includeFieldNames = true)
+public class EncryptionResponseObject {
+	/**返回码:0错误;1成功;2超时*/
+    private Integer code;
+    @JsonInclude(value = Include.NON_NULL)
+    /**返回说明*/
+    private String message;
+    /**接口返回的字符串*/
+    private Object resultBody;
+    /**是否收费:0不收,1收费*/
+    private int isCharge;
+    /**通道ID*/
+    private String channelId;
+}

+ 22 - 0
src/main/java/info/aspirecn/rdc/iov/sjjh/servicenode/supplier/jk_interface/vo/ResponseObject.java

@@ -0,0 +1,22 @@
+package info.aspirecn.rdc.iov.sjjh.servicenode.supplier.jk_interface.vo;
+
+import lombok.Data;
+
+import java.io.Serializable;
+
+/**
+ * @Auther jianggang
+ * @Date 2018/10/24 14:03:38
+ * @Description
+ */
+
+@Data
+public class ResponseObject implements Serializable {
+
+    private Integer isCharge;
+
+    private Integer code;
+
+    private Object resultBody;
+
+}