保存进度!
This commit is contained in:
		
							
								
								
									
										0
									
								
								code/cpicxim-XMNHSA-repeater/.mvn/jvm.config
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										0
									
								
								code/cpicxim-XMNHSA-repeater/.mvn/jvm.config
									
									
									
									
									
										Normal file
									
								
							
							
								
								
									
										0
									
								
								code/cpicxim-XMNHSA-repeater/.mvn/maven.config
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										0
									
								
								code/cpicxim-XMNHSA-repeater/.mvn/maven.config
									
									
									
									
									
										Normal file
									
								
							
							
								
								
									
										3
									
								
								code/cpicxim-XMNHSA-repeater/.vscode/settings.json
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										3
									
								
								code/cpicxim-XMNHSA-repeater/.vscode/settings.json
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,3 @@
 | 
			
		||||
{
 | 
			
		||||
    "java.configuration.updateBuildConfiguration": "automatic"
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										200
									
								
								code/cpicxim-XMNHSA-repeater/pom.xml
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										200
									
								
								code/cpicxim-XMNHSA-repeater/pom.xml
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,200 @@
 | 
			
		||||
<?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.cpic.xim</groupId>
 | 
			
		||||
  <artifactId>cpicxim-XMNHSA-repeater</artifactId>
 | 
			
		||||
  <version>1.0-SNAPSHOT</version>
 | 
			
		||||
 | 
			
		||||
  <name>cpicxim-XMNHSA-repeater</name>
 | 
			
		||||
  <!-- FIXME change it to the project's website -->
 | 
			
		||||
  <url>http://www.example.com</url>
 | 
			
		||||
 | 
			
		||||
  <properties>
 | 
			
		||||
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
 | 
			
		||||
    <maven.compiler.release>18</maven.compiler.release>
 | 
			
		||||
  </properties>
 | 
			
		||||
 | 
			
		||||
  <dependencyManagement>
 | 
			
		||||
    <dependencies>
 | 
			
		||||
      <dependency>
 | 
			
		||||
        <groupId>org.junit</groupId>
 | 
			
		||||
        <artifactId>junit-bom</artifactId>
 | 
			
		||||
        <version>5.11.0</version>
 | 
			
		||||
        <type>pom</type>
 | 
			
		||||
        <scope>import</scope>
 | 
			
		||||
      </dependency>
 | 
			
		||||
    </dependencies>
 | 
			
		||||
  </dependencyManagement>
 | 
			
		||||
 | 
			
		||||
  <dependencies>
 | 
			
		||||
    <dependency>
 | 
			
		||||
      <groupId>org.junit.jupiter</groupId>
 | 
			
		||||
      <artifactId>junit-jupiter-api</artifactId>
 | 
			
		||||
      <scope>test</scope>
 | 
			
		||||
    </dependency>
 | 
			
		||||
    <!-- Optionally: parameterized tests support -->
 | 
			
		||||
    <dependency>
 | 
			
		||||
      <groupId>org.junit.jupiter</groupId>
 | 
			
		||||
      <artifactId>junit-jupiter-params</artifactId>
 | 
			
		||||
      <scope>test</scope>
 | 
			
		||||
    </dependency>
 | 
			
		||||
 | 
			
		||||
    <!--jackson-->
 | 
			
		||||
    <dependency>
 | 
			
		||||
      <groupId>com.fasterxml.jackson.core</groupId>
 | 
			
		||||
      <artifactId>jackson-databind</artifactId>
 | 
			
		||||
      <version>2.14.2</version>
 | 
			
		||||
    </dependency>
 | 
			
		||||
    <!-- https://mvnrepository.com/artifact/com.fasterxml.jackson.core/jackson-core -->
 | 
			
		||||
    <dependency>
 | 
			
		||||
      <groupId>com.fasterxml.jackson.core</groupId>
 | 
			
		||||
      <artifactId>jackson-core</artifactId>
 | 
			
		||||
      <version>2.13.4</version>
 | 
			
		||||
    </dependency>
 | 
			
		||||
    <!-- https://mvnrepository.com/artifact/com.fasterxml.jackson.core/jackson-annotations -->
 | 
			
		||||
    <dependency>
 | 
			
		||||
      <groupId>com.fasterxml.jackson.core</groupId>
 | 
			
		||||
      <artifactId>jackson-annotations</artifactId>
 | 
			
		||||
      <version>2.13.4</version>
 | 
			
		||||
    </dependency>
 | 
			
		||||
 | 
			
		||||
    <!-- log-4j -->
 | 
			
		||||
    <dependency>
 | 
			
		||||
      <groupId>org.apache.logging.log4j</groupId>
 | 
			
		||||
      <artifactId>log4j-core</artifactId>
 | 
			
		||||
      <version>2.20.0</version>
 | 
			
		||||
    </dependency>
 | 
			
		||||
    <dependency>
 | 
			
		||||
      <groupId>org.apache.logging.log4j</groupId>
 | 
			
		||||
      <artifactId>log4j-slf4j2-impl</artifactId>
 | 
			
		||||
      <version>2.20.0</version>
 | 
			
		||||
    </dependency>
 | 
			
		||||
    <dependency>
 | 
			
		||||
      <groupId>org.apache.logging.log4j</groupId>
 | 
			
		||||
      <artifactId>log4j-api</artifactId>
 | 
			
		||||
      <version>2.20.0</version>
 | 
			
		||||
    </dependency>
 | 
			
		||||
 | 
			
		||||
    <!-- POI -->
 | 
			
		||||
    <dependency>
 | 
			
		||||
      <groupId>org.apache.poi</groupId>
 | 
			
		||||
      <artifactId>poi</artifactId>
 | 
			
		||||
      <version>5.2.3</version>
 | 
			
		||||
    </dependency>
 | 
			
		||||
    <dependency>
 | 
			
		||||
      <groupId>org.apache.poi</groupId>
 | 
			
		||||
      <artifactId>poi-ooxml</artifactId>
 | 
			
		||||
      <version>5.2.3</version>
 | 
			
		||||
    </dependency>
 | 
			
		||||
 | 
			
		||||
    <!-- mybatis -->
 | 
			
		||||
    <dependency>
 | 
			
		||||
      <groupId>org.mybatis</groupId>
 | 
			
		||||
      <artifactId>mybatis</artifactId>
 | 
			
		||||
      <version>3.5.19</version>
 | 
			
		||||
    </dependency>
 | 
			
		||||
 | 
			
		||||
    <dependency>
 | 
			
		||||
      <groupId> cn.hsa.zephyr</groupId>
 | 
			
		||||
      <artifactId>zephyr-api-sdk</artifactId>
 | 
			
		||||
      <version>2.0.1</version>
 | 
			
		||||
      <scope>system</scope>
 | 
			
		||||
      <systemPath>${project.basedir}/lib/zephyr-api-sdk.jar</systemPath>
 | 
			
		||||
    </dependency>
 | 
			
		||||
 | 
			
		||||
    <dependency>
 | 
			
		||||
      <groupId>com.alibaba</groupId>
 | 
			
		||||
      <artifactId>fastjson</artifactId>
 | 
			
		||||
      <!-- <version>1.2.83</version> -->
 | 
			
		||||
      <version>2.0.56</version>
 | 
			
		||||
    </dependency>
 | 
			
		||||
 | 
			
		||||
    <dependency>
 | 
			
		||||
      <groupId>com.mysql</groupId>
 | 
			
		||||
      <artifactId>mysql-connector-j</artifactId>
 | 
			
		||||
      <version>9.2.0</version>
 | 
			
		||||
    </dependency>
 | 
			
		||||
 | 
			
		||||
  </dependencies>
 | 
			
		||||
 | 
			
		||||
  <build>
 | 
			
		||||
  <defaultGoal>compile</defaultGoal>
 | 
			
		||||
    <pluginManagement><!-- lock down plugins versions to avoid using Maven defaults (may be moved to
 | 
			
		||||
      parent pom) -->
 | 
			
		||||
      <plugins>
 | 
			
		||||
        <!-- clean lifecycle, see
 | 
			
		||||
        https://maven.apache.org/ref/current/maven-core/lifecycles.html#clean_Lifecycle -->
 | 
			
		||||
        <plugin>
 | 
			
		||||
          <artifactId>maven-clean-plugin</artifactId>
 | 
			
		||||
          <version>3.4.0</version>
 | 
			
		||||
        </plugin>
 | 
			
		||||
        <!-- default lifecycle, jar packaging: see
 | 
			
		||||
        https://maven.apache.org/ref/current/maven-core/default-bindings.html#Plugin_bindings_for_jar_packaging -->
 | 
			
		||||
        <plugin>
 | 
			
		||||
          <artifactId>maven-resources-plugin</artifactId>
 | 
			
		||||
          <version>3.3.1</version>
 | 
			
		||||
        </plugin>
 | 
			
		||||
        <plugin>
 | 
			
		||||
          <artifactId>maven-compiler-plugin</artifactId>
 | 
			
		||||
          <version>3.13.0</version>
 | 
			
		||||
          <configuration>
 | 
			
		||||
            <compilerArguments>
 | 
			
		||||
              <extdirs>${project.basedir}\lib</extdirs>
 | 
			
		||||
            </compilerArguments>
 | 
			
		||||
          </configuration>
 | 
			
		||||
        </plugin>
 | 
			
		||||
        <plugin>
 | 
			
		||||
          <artifactId>maven-surefire-plugin</artifactId>
 | 
			
		||||
          <version>3.3.0</version>
 | 
			
		||||
          <configuration>
 | 
			
		||||
            <skip>true</skip>
 | 
			
		||||
          </configuration>
 | 
			
		||||
        </plugin>
 | 
			
		||||
        <plugin>
 | 
			
		||||
          <artifactId>maven-install-plugin</artifactId>
 | 
			
		||||
          <version>3.1.2</version>
 | 
			
		||||
        </plugin>
 | 
			
		||||
        <plugin>
 | 
			
		||||
          <artifactId>maven-deploy-plugin</artifactId>
 | 
			
		||||
          <version>3.1.2</version>
 | 
			
		||||
        </plugin>
 | 
			
		||||
        <!-- site lifecycle, see
 | 
			
		||||
        https://maven.apache.org/ref/current/maven-core/lifecycles.html#site_Lifecycle -->
 | 
			
		||||
        <plugin>
 | 
			
		||||
          <artifactId>maven-site-plugin</artifactId>
 | 
			
		||||
          <version>3.12.1</version>
 | 
			
		||||
        </plugin>
 | 
			
		||||
        <plugin>
 | 
			
		||||
          <artifactId>maven-project-info-reports-plugin</artifactId>
 | 
			
		||||
          <version>3.6.1</version>
 | 
			
		||||
        </plugin>
 | 
			
		||||
        <plugin>
 | 
			
		||||
          <groupId>org.apache.maven.plugins</groupId>
 | 
			
		||||
          <artifactId>maven-assembly-plugin</artifactId>
 | 
			
		||||
          <configuration>
 | 
			
		||||
            <descriptorRefs>
 | 
			
		||||
              <descriptorRef>jar-with-dependencies</descriptorRef>
 | 
			
		||||
            </descriptorRefs>
 | 
			
		||||
            <archive>
 | 
			
		||||
              <manifest>
 | 
			
		||||
                <mainClass>AppMain</mainClass>
 | 
			
		||||
              </manifest>
 | 
			
		||||
            </archive>
 | 
			
		||||
          </configuration>
 | 
			
		||||
          <executions>
 | 
			
		||||
            <execution>
 | 
			
		||||
              <id>make-assmenbly</id>
 | 
			
		||||
              <phase>package</phase>
 | 
			
		||||
              <goals>
 | 
			
		||||
                <goal>single</goal>
 | 
			
		||||
              </goals>
 | 
			
		||||
            </execution>
 | 
			
		||||
          </executions>
 | 
			
		||||
        </plugin>
 | 
			
		||||
      </plugins>
 | 
			
		||||
    </pluginManagement>
 | 
			
		||||
  </build>
 | 
			
		||||
</project>
 | 
			
		||||
@@ -0,0 +1,25 @@
 | 
			
		||||
/*
 | 
			
		||||
 * @Author: Kane
 | 
			
		||||
 * @Date: 2025-03-11 09:27:40
 | 
			
		||||
 * @LastEditors: Kane
 | 
			
		||||
 * @FilePath: /cpicxim-XMNHSA-repeater/src/main/java/com/cpic/xim/huixiabao/AppMain.java
 | 
			
		||||
 * @Description: 
 | 
			
		||||
 * 
 | 
			
		||||
 * Copyright (c) ${2023} by Kane, All Rights Reserved. 
 | 
			
		||||
 */
 | 
			
		||||
package com.cpic.xim.huixiabao;
 | 
			
		||||
 | 
			
		||||
import com.cpic.xim.huixiabao.data.config.HuixiabaoConfig;
 | 
			
		||||
import cn.hsa.zephyr.apisdk.internal.util.encrypt.EncryptionModeEnum;
 | 
			
		||||
import cn.hsa.zephyr.apisdk.internal.util.encrypt.SignTypeEnum;
 | 
			
		||||
 | 
			
		||||
public class AppMain
 | 
			
		||||
{
 | 
			
		||||
    public static void main( String[] args )
 | 
			
		||||
    {
 | 
			
		||||
        EncryptionModeEnum encType = EncryptionModeEnum.SM4;
 | 
			
		||||
        SignTypeEnum signType = SignTypeEnum.SM3;
 | 
			
		||||
        
 | 
			
		||||
        System.out.println( "Hello World!" );
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
@@ -0,0 +1,38 @@
 | 
			
		||||
/*
 | 
			
		||||
 * @Author: Kane
 | 
			
		||||
 * @Date: 2025-03-11 09:30:38
 | 
			
		||||
 * @LastEditors: Kane
 | 
			
		||||
 * @FilePath: /cpicxim-XMNHSA-repeater/src/main/java/com/cpic/xim/huixiabao/data/config/HuixiabaoConfig.java
 | 
			
		||||
 * @Description: 存放惠厦保相关的配置文件,以后要改成json文件存放。
 | 
			
		||||
 * 
 | 
			
		||||
 * Copyright (c) ${2023} by Kane, All Rights Reserved. 
 | 
			
		||||
 */
 | 
			
		||||
 | 
			
		||||
package com.cpic.xim.huixiabao.data.config;
 | 
			
		||||
 | 
			
		||||
public class HuixiabaoConfig
 | 
			
		||||
{
 | 
			
		||||
 | 
			
		||||
    public String getAppid()
 | 
			
		||||
    {
 | 
			
		||||
        return appid;
 | 
			
		||||
    }
 | 
			
		||||
    public String getAppSecret()
 | 
			
		||||
    {
 | 
			
		||||
        return appSecret;
 | 
			
		||||
    }
 | 
			
		||||
    public String getSignKey()
 | 
			
		||||
    {
 | 
			
		||||
        return signKey;
 | 
			
		||||
    }
 | 
			
		||||
    public String getEncKey()
 | 
			
		||||
    {
 | 
			
		||||
        return encKey;
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    private String url = "https://172.18.1.150:9040";
 | 
			
		||||
    private String appid = "hxb-tb";
 | 
			
		||||
    private String appSecret = "60F468FB46170DD4CF6CBECE215DBFC0";
 | 
			
		||||
    private String signKey = "1A2F447BD0F930798D8031B137EC6E25";
 | 
			
		||||
    private String encKey = "08307695B1668EB9FD6210250FED874F";
 | 
			
		||||
}
 | 
			
		||||
@@ -0,0 +1,86 @@
 | 
			
		||||
/*
 | 
			
		||||
 * @Author: Kane
 | 
			
		||||
 * @Date: 2025-03-06 14:33:27
 | 
			
		||||
 * @LastEditors: Kane
 | 
			
		||||
 * @FilePath: /Cpicxim-XMNHSA-Repeater/src/main/java/com/cpicxim/huixiabao/data/pojo/HmbListItem.java
 | 
			
		||||
 * @Description: 
 | 
			
		||||
 * 
 | 
			
		||||
 * Copyright (c) ${2023} by Kane, All Rights Reserved. 
 | 
			
		||||
 */
 | 
			
		||||
package com.cpic.xim.huixiabao.data.pojo;
 | 
			
		||||
 | 
			
		||||
import com.fasterxml.jackson.annotation.JsonInclude;
 | 
			
		||||
import com.fasterxml.jackson.annotation.JsonProperty;
 | 
			
		||||
import com.fasterxml.jackson.annotation.JsonPropertyOrder;
 | 
			
		||||
 | 
			
		||||
@JsonInclude( JsonInclude.Include.NON_EMPTY )
 | 
			
		||||
@JsonPropertyOrder( alphabetic = true )
 | 
			
		||||
public class HmbListItem
 | 
			
		||||
{
 | 
			
		||||
    
 | 
			
		||||
    public String getPsnName()
 | 
			
		||||
    {
 | 
			
		||||
        return psnName;
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    public void setPsnName( String psnName )
 | 
			
		||||
    {
 | 
			
		||||
        this.psnName = psnName;
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    public String getCertNo()
 | 
			
		||||
    {
 | 
			
		||||
        return certNo;
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    public void setCertNo( String certNo )
 | 
			
		||||
    {
 | 
			
		||||
        this.certNo = certNo;
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    public String getServiceId()
 | 
			
		||||
    {
 | 
			
		||||
        return serviceId;
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    public void setServiceId( String serviceId )
 | 
			
		||||
    {
 | 
			
		||||
        this.serviceId = serviceId;
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    public String getStatus()
 | 
			
		||||
    {
 | 
			
		||||
        return status;
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    public void setStatus( String status )
 | 
			
		||||
    {
 | 
			
		||||
        this.status = status;
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    public String getXyxNo()
 | 
			
		||||
    {
 | 
			
		||||
        return xyxNo;
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    public void setXyxNo( String xyxNo )
 | 
			
		||||
    {
 | 
			
		||||
        this.xyxNo = xyxNo;
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    @JsonProperty("psnName")
 | 
			
		||||
    private String psnName;
 | 
			
		||||
 | 
			
		||||
    @JsonProperty("certno")
 | 
			
		||||
    private String certNo;
 | 
			
		||||
 | 
			
		||||
    @JsonProperty("serviceId")
 | 
			
		||||
    private String serviceId;
 | 
			
		||||
 | 
			
		||||
    @JsonProperty("status")
 | 
			
		||||
    private String status;
 | 
			
		||||
 | 
			
		||||
    @JsonProperty("xyxNo")
 | 
			
		||||
    private String xyxNo;
 | 
			
		||||
 | 
			
		||||
}
 | 
			
		||||
@@ -0,0 +1,59 @@
 | 
			
		||||
/*
 | 
			
		||||
 * @Author: Kane
 | 
			
		||||
 * @Date: 2025-03-06 14:27:05
 | 
			
		||||
 * @LastEditors: Kane
 | 
			
		||||
 * @FilePath: /Cpicxim-XMNHSA-Repeater/src/main/java/com/cpicxim/huixiabao/data/pojo/HmbXyxInfoRequest.java
 | 
			
		||||
 * @Description: 
 | 
			
		||||
 * 
 | 
			
		||||
 * Copyright (c) ${2023} by Kane, All Rights Reserved. 
 | 
			
		||||
 */
 | 
			
		||||
package com.cpic.xim.huixiabao.data.pojo;
 | 
			
		||||
 | 
			
		||||
import java.util.Vector;
 | 
			
		||||
import com.fasterxml.jackson.annotation.JsonInclude;
 | 
			
		||||
import com.fasterxml.jackson.annotation.JsonProperty;
 | 
			
		||||
import com.fasterxml.jackson.annotation.JsonPropertyOrder;
 | 
			
		||||
 | 
			
		||||
@JsonInclude( JsonInclude.Include.NON_EMPTY )
 | 
			
		||||
@JsonPropertyOrder( alphabetic = true )
 | 
			
		||||
public class HmbXyxInfoRequest
 | 
			
		||||
{
 | 
			
		||||
    public HmbXyxInfoRequest()
 | 
			
		||||
    {
 | 
			
		||||
        this.topic = "hmbXyxInfo";
 | 
			
		||||
        this.hmbList = new Vector<>();
 | 
			
		||||
    }
 | 
			
		||||
    
 | 
			
		||||
    public HmbXyxInfoRequest( String topic, Vector<HmbListItem> hmbList )
 | 
			
		||||
    {
 | 
			
		||||
        this.topic = topic;
 | 
			
		||||
        this.topic = "hmbXyxInfo";
 | 
			
		||||
        this.hmbList = hmbList;
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    public String getTopic()
 | 
			
		||||
    {
 | 
			
		||||
        return topic;
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    public void setTopic( String topic )
 | 
			
		||||
    {
 | 
			
		||||
        this.topic = topic;
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    public Vector<HmbListItem> getHmbList()
 | 
			
		||||
    {
 | 
			
		||||
        return hmbList;
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    public void setHmbList( Vector<HmbListItem> hmbList )
 | 
			
		||||
    {
 | 
			
		||||
        this.hmbList = hmbList;
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    @JsonProperty("topic")
 | 
			
		||||
    private String topic; // 业务类型
 | 
			
		||||
 | 
			
		||||
    @JsonProperty("hmbList")
 | 
			
		||||
    private Vector<HmbListItem> hmbList;
 | 
			
		||||
}
 | 
			
		||||
@@ -0,0 +1,82 @@
 | 
			
		||||
/*
 | 
			
		||||
 * @Author: Kane
 | 
			
		||||
 * @Date: 2025-03-06 14:17:24
 | 
			
		||||
 * @LastEditors: Kane
 | 
			
		||||
 * @FilePath: /cpicxim-XMNHSA-repeater/src/main/java/com/cpic/xim/huixiabao/data/pojo/NHACommenRequestBody.java
 | 
			
		||||
 * @Description: 易联众请求共通报文结构
 | 
			
		||||
 *
 | 
			
		||||
 * Copyright (c) ${2023} by Kane, All Rights Reserved.
 | 
			
		||||
 */
 | 
			
		||||
package com.cpic.xim.huixiabao.data.pojo;
 | 
			
		||||
 | 
			
		||||
import com.fasterxml.jackson.annotation.JsonProperty;
 | 
			
		||||
 | 
			
		||||
public class NHACommenRequestBody
 | 
			
		||||
{
 | 
			
		||||
   
 | 
			
		||||
   public String getChs_fjs_appid()
 | 
			
		||||
   {
 | 
			
		||||
      return chs_fjs_appid;
 | 
			
		||||
   }
 | 
			
		||||
   public void setChs_fjs_appid( String chs_fjs_appid )
 | 
			
		||||
   {
 | 
			
		||||
      this.chs_fjs_appid = chs_fjs_appid;
 | 
			
		||||
   }
 | 
			
		||||
   public String getChs_fjs_appsecret()
 | 
			
		||||
   {
 | 
			
		||||
      return chs_fjs_appsecret;
 | 
			
		||||
   }
 | 
			
		||||
   public void setChs_fjs_appsecret( String chs_fjs_appsecret )
 | 
			
		||||
   {
 | 
			
		||||
      this.chs_fjs_appsecret = chs_fjs_appsecret;
 | 
			
		||||
   }
 | 
			
		||||
   public String getChs_fjs_token()
 | 
			
		||||
   {
 | 
			
		||||
      return chs_fjs_token;
 | 
			
		||||
   }
 | 
			
		||||
   public void setChs_fjs_token( String chs_fjs_token )
 | 
			
		||||
   {
 | 
			
		||||
      this.chs_fjs_token = chs_fjs_token;
 | 
			
		||||
   }
 | 
			
		||||
   public String getChs_fjs_funid()
 | 
			
		||||
   {
 | 
			
		||||
      return chs_fjs_funid;
 | 
			
		||||
   }
 | 
			
		||||
   public void setChs_fjs_funid( String chs_fjs_funid )
 | 
			
		||||
   {
 | 
			
		||||
      this.chs_fjs_funid = chs_fjs_funid;
 | 
			
		||||
   }
 | 
			
		||||
   public String getChs_fjs_encdata()
 | 
			
		||||
   {
 | 
			
		||||
      return chs_fjs_encdata;
 | 
			
		||||
   }
 | 
			
		||||
   public void setChs_fjs_encdata( String chs_fjs_encdata )
 | 
			
		||||
   {
 | 
			
		||||
      this.chs_fjs_encdata = chs_fjs_encdata;
 | 
			
		||||
   }
 | 
			
		||||
   public String getChs_fjs_sign()
 | 
			
		||||
   {
 | 
			
		||||
      return chs_fjs_sign;
 | 
			
		||||
   }
 | 
			
		||||
   public void setChs_fjs_sign( String chs_fjs_sign )
 | 
			
		||||
   {
 | 
			
		||||
      this.chs_fjs_sign = chs_fjs_sign;
 | 
			
		||||
   }
 | 
			
		||||
   public int getChs_fjs_timestamp()
 | 
			
		||||
   {
 | 
			
		||||
      return chs_fjs_timestamp;
 | 
			
		||||
   }
 | 
			
		||||
   public void setChs_fjs_timestamp( int chs_fjs_timestamp )
 | 
			
		||||
   {
 | 
			
		||||
      this.chs_fjs_timestamp = chs_fjs_timestamp;
 | 
			
		||||
   }
 | 
			
		||||
 | 
			
		||||
   private String chs_fjs_appid; // 渠道id
 | 
			
		||||
   private String chs_fjs_appsecret; // 渠道私钥
 | 
			
		||||
   private String chs_fjs_token; // 请求时携带的动态令牌
 | 
			
		||||
   private String chs_fjs_funid; // 服务编号
 | 
			
		||||
   private String chs_fjs_encdata; // 加密后的数据
 | 
			
		||||
   private String chs_fjs_sign; // 签名数据串
 | 
			
		||||
   private String data; // 未加密的数据
 | 
			
		||||
   private int chs_fjs_timestamp; // 时间戳
 | 
			
		||||
}
 | 
			
		||||
@@ -0,0 +1,28 @@
 | 
			
		||||
/*
 | 
			
		||||
 * @Author: Kane
 | 
			
		||||
 * @Date: 2025-03-11 11:10:09
 | 
			
		||||
 * @LastEditors: Kane
 | 
			
		||||
 * @FilePath: /cpicxim-XMNHSA-repeater/src/main/java/com/cpic/xim/huixiabao/nhs/CpicximToXMNHS.java
 | 
			
		||||
 * @Description: 
 | 
			
		||||
 * 
 | 
			
		||||
 * Copyright (c) ${2023} by Kane, All Rights Reserved. 
 | 
			
		||||
 */
 | 
			
		||||
package com.cpic.xim.huixiabao.nhs;
 | 
			
		||||
 | 
			
		||||
import java.util.Vector;
 | 
			
		||||
import com.cpic.xim.huixiabao.data.pojo.*;
 | 
			
		||||
import org.slf4j.Logger;
 | 
			
		||||
import org.slf4j.LoggerFactory;
 | 
			
		||||
 | 
			
		||||
public class CpicximToXMNHS
 | 
			
		||||
{
 | 
			
		||||
    private static Logger logger = LoggerFactory.getLogger( CpicximToXMNHS.class );
 | 
			
		||||
 | 
			
		||||
    public Vector<HmbListItem> getNeverTransHmbList()
 | 
			
		||||
    {
 | 
			
		||||
 | 
			
		||||
        Vector<HmbListItem> items = new Vector<HmbListItem>();
 | 
			
		||||
 | 
			
		||||
        return items;
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										40
									
								
								code/cpicxim-XMNHSA-repeater/src/main/resources/log4j2.xml
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										40
									
								
								code/cpicxim-XMNHSA-repeater/src/main/resources/log4j2.xml
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,40 @@
 | 
			
		||||
<Configuration status="WARN" monitorInterval="300">
 | 
			
		||||
    <Appenders>
 | 
			
		||||
        <Console name="Console" target="SYSTEM_OUT">
 | 
			
		||||
            <PatternLayout pattern="%d{HH:mm:ss.SSS} [%t] %-5level %logger{36} ### %msg%n" />
 | 
			
		||||
            <ThresholdFilter level="trace" onMatch="ACCEPT" onMismatch="DENY" />
 | 
			
		||||
        </Console>
 | 
			
		||||
        <RollingFile name="rolling_file_win" 
 | 
			
		||||
            filePattern="./logs/huixiabao/$${date:yyyy-MM}/huixiabao-%d{MM-dd-yyyy}-%i.log.gz">
 | 
			
		||||
            <PatternLayout>
 | 
			
		||||
                <Pattern>[%t][%level][%d{HH:mm:ss.SSS}][%logger.%M{36}#%L] %msg%n</Pattern>
 | 
			
		||||
            </PatternLayout>
 | 
			
		||||
            <Policies>
 | 
			
		||||
                <TimeBasedTriggeringPolicy interval="1" />
 | 
			
		||||
                <SizeBasedTriggeringPolicy size="20MB" />
 | 
			
		||||
                <DefaultRolloverStrategy max="20" />
 | 
			
		||||
            </Policies>
 | 
			
		||||
        </RollingFile>
 | 
			
		||||
        <RollingFile name="rolling_file_linux"
 | 
			
		||||
            filePattern="/logs/huixiabao/$${date:yyyy-MM}/app-%d{MM-dd-yyyy}-%i.log.gz">
 | 
			
		||||
            <PatternLayout>
 | 
			
		||||
                <Pattern>[%t][%level][%d{HH:mm:ss.SSS}][%logger.%M{36}#%L] %msg%n</Pattern>
 | 
			
		||||
            </PatternLayout>
 | 
			
		||||
            <Policies>
 | 
			
		||||
                <TimeBasedTriggeringPolicy interval="1" />
 | 
			
		||||
                <SizeBasedTriggeringPolicy size="20MB" />
 | 
			
		||||
                <DefaultRolloverStrategy max="20" />
 | 
			
		||||
            </Policies>
 | 
			
		||||
        </RollingFile>
 | 
			
		||||
    </Appenders>
 | 
			
		||||
    <Loggers>
 | 
			
		||||
        <!-- <Logger name="mylog" level="info">
 | 
			
		||||
            <AppenderRef ref="rolling_file" />
 | 
			
		||||
        </Logger> -->
 | 
			
		||||
        <Root level="debug">
 | 
			
		||||
            <AppenderRef ref="rolling_file_linux" />
 | 
			
		||||
            <AppenderRef ref="rolling_file_win" />
 | 
			
		||||
            <AppenderRef ref="Console" />
 | 
			
		||||
        </Root>
 | 
			
		||||
    </Loggers>
 | 
			
		||||
</Configuration>
 | 
			
		||||
@@ -0,0 +1,84 @@
 | 
			
		||||
/*
 | 
			
		||||
 * @Author: Kane
 | 
			
		||||
 * @Date: 2025-03-11 09:27:40
 | 
			
		||||
 * @LastEditors: Kane
 | 
			
		||||
 * @FilePath: /cpicxim-XMNHSA-repeater/src/test/java/com/cpic/xim/huixiabao/AppTest.java
 | 
			
		||||
 * @Description: 
 | 
			
		||||
 * 
 | 
			
		||||
 * Copyright (c) ${2023} by Kane, All Rights Reserved. 
 | 
			
		||||
 */
 | 
			
		||||
package com.cpic.xim.huixiabao;
 | 
			
		||||
 | 
			
		||||
import static org.junit.jupiter.api.Assertions.assertTrue;
 | 
			
		||||
 | 
			
		||||
import org.junit.jupiter.api.Test;
 | 
			
		||||
import org.slf4j.Logger;
 | 
			
		||||
import org.slf4j.LoggerFactory;
 | 
			
		||||
import com.alibaba.fastjson.JSONObject;
 | 
			
		||||
import cn.hsa.zephyr.apisdk.DefaultZephyrClient;
 | 
			
		||||
import cn.hsa.zephyr.apisdk.internal.exception.ZephyrApiException;
 | 
			
		||||
import cn.hsa.zephyr.apisdk.internal.util.encrypt.EncryptionModeEnum;
 | 
			
		||||
import cn.hsa.zephyr.apisdk.internal.util.encrypt.SignTypeEnum;
 | 
			
		||||
import cn.hsa.zephyr.apisdk.request.DefaultZephyrRequest;
 | 
			
		||||
import cn.hsa.zephyr.apisdk.response.DefaultZephyrResponse;
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * Unit test for simple App.
 | 
			
		||||
 */
 | 
			
		||||
public class AppTest
 | 
			
		||||
{
 | 
			
		||||
    private Logger logger = LoggerFactory.getLogger( AppTest.class );
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Rigorous Test :-)
 | 
			
		||||
     */
 | 
			
		||||
    @Test
 | 
			
		||||
    public void shouldAnswerWithTrue()
 | 
			
		||||
    {
 | 
			
		||||
        assertTrue( true );
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    @Test
 | 
			
		||||
    public void testLog()
 | 
			
		||||
    {
 | 
			
		||||
        for ( int i = 0; i < 10000; i++ )
 | 
			
		||||
        {
 | 
			
		||||
            // System.out.print("test!");
 | 
			
		||||
            logger.error( "test!!!!" );
 | 
			
		||||
        }
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    public void nhsTest()
 | 
			
		||||
    {
 | 
			
		||||
        String url = "";
 | 
			
		||||
        String appId = "待定";
 | 
			
		||||
        String appSecret = "待定";
 | 
			
		||||
        String funId = "xxx";
 | 
			
		||||
        String encKey = "A5B6E00DA599G56C41ABFE23A74E6E60";
 | 
			
		||||
        String signKey = "待定";
 | 
			
		||||
 | 
			
		||||
        SignTypeEnum signType = SignTypeEnum.SM3;
 | 
			
		||||
        EncryptionModeEnum encType = EncryptionModeEnum.SM4;
 | 
			
		||||
        
 | 
			
		||||
        try
 | 
			
		||||
        {
 | 
			
		||||
            DefaultZephyrClient client = new DefaultZephyrClient( url, funId, appId, appSecret,
 | 
			
		||||
                    signType, signKey, encType, encKey );
 | 
			
		||||
            DefaultZephyrRequest req = new DefaultZephyrRequest();
 | 
			
		||||
            JSONObject jsonObject1 = new JSONObject();
 | 
			
		||||
            DefaultZephyrResponse resp = null;
 | 
			
		||||
 | 
			
		||||
            jsonObject1.put( "code", "XXXXXXXXXXXXXXXXXX" );
 | 
			
		||||
            jsonObject1.put( "scene_code", "XXX" );
 | 
			
		||||
 | 
			
		||||
            req.setData( jsonObject1 );
 | 
			
		||||
            resp = client.execute( req );
 | 
			
		||||
            
 | 
			
		||||
            System.out.println( resp.getData() );
 | 
			
		||||
        }
 | 
			
		||||
        catch ( ZephyrApiException e )
 | 
			
		||||
        {
 | 
			
		||||
            e.printStackTrace();
 | 
			
		||||
        }
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										
											BIN
										
									
								
								文档/地址.xlsx
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										
											BIN
										
									
								
								文档/地址.xlsx
									
									
									
									
									
										Normal file
									
								
							
										
											Binary file not shown.
										
									
								
							
							
								
								
									
										23
									
								
								文档/接口/医保局接口sdk与示例/java-sdk使用例子.txt
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										23
									
								
								文档/接口/医保局接口sdk与示例/java-sdk使用例子.txt
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,23 @@
 | 
			
		||||
 public static void main(String[] args) {
 | 
			
		||||
        String url = "";
 | 
			
		||||
        String appId = "待定";
 | 
			
		||||
        String appSecret = "待定";
 | 
			
		||||
        String funId = "xxx";
 | 
			
		||||
        SignTypeEnum signType = SignTypeEnum.SM3;
 | 
			
		||||
        String signKey = "待定";
 | 
			
		||||
        EncryptionModeEnum encType = EncryptionModeEnum.SM4;
 | 
			
		||||
        String encKey = "A5B6E00DA599G56C41ABFE23A74E6E60";
 | 
			
		||||
        try {
 | 
			
		||||
            DefaultZephyrClient client = new DefaultZephyrClient(url, funId, appId, appSecret,
 | 
			
		||||
                    signType, signKey, encType, encKey);
 | 
			
		||||
            DefaultZephyrRequest req = new DefaultZephyrRequest();
 | 
			
		||||
            JSONObject jsonObject1 = new JSONObject();
 | 
			
		||||
            jsonObject1.put("code", "XXXXXXXXXXXXXXXXXX");
 | 
			
		||||
            jsonObject1.put("scene_code", "XXX");
 | 
			
		||||
            req.setData(jsonObject1);
 | 
			
		||||
            DefaultZephyrResponse resp = client.execute(req);
 | 
			
		||||
            System.out.println(resp.getData());
 | 
			
		||||
        } catch (ZephyrApiException e) {
 | 
			
		||||
            e.printStackTrace();
 | 
			
		||||
        }
 | 
			
		||||
    }
 | 
			
		||||
							
								
								
									
										6
									
								
								文档/接口/医保局接口sdk与示例/测试环境配置说明.txt
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										6
									
								
								文档/接口/医保局接口sdk与示例/测试环境配置说明.txt
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,6 @@
 | 
			
		||||
 | 
			
		||||
appid:hxb-tb
 | 
			
		||||
appSecret:60F468FB46170DD4CF6CBECE215DBFC0
 | 
			
		||||
signKey:1A2F447BD0F930798D8031B137EC6E25
 | 
			
		||||
encKey:08307695B1668EB9FD6210250FED874F
 | 
			
		||||
 | 
			
		||||
		Reference in New Issue
	
	Block a user