作者 zhangFan

analysis_imf for station version 1.0

... ... @@ -22,6 +22,7 @@
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
<java.version>1.8</java.version>
<spring-cloud.version>Greenwich.M1</spring-cloud.version>
</properties>
<dependencies>
... ... @@ -34,6 +35,10 @@
<artifactId>spring-boot-starter-web</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-netflix-eureka-client</artifactId>
</dependency>
<dependency>
<groupId>org.mybatis.spring.boot</groupId>
<artifactId>mybatis-spring-boot-starter</artifactId>
<version>1.3.2</version>
... ... @@ -68,18 +73,6 @@
</dependency>
<dependency>
<groupId>com.thoughtworks.xstream</groupId>
<artifactId>xstream</artifactId>
<version>1.4.7</version>
</dependency>
<dependency>
<groupId>net.sf.sociaal</groupId>
<artifactId>xmlpull-xpp3</artifactId>
<version>3.0.0.20130526</version>
</dependency>
<dependency>
<groupId>com.github.pagehelper</groupId>
<artifactId>pagehelper-spring-boot-starter</artifactId>
<version>1.2.3</version>
... ... @@ -96,9 +89,18 @@
<artifactId>log4j</artifactId>
<version>1.2.17</version>
</dependency>
</dependencies>
<dependencyManagement>
<dependencies>
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-dependencies</artifactId>
<version>${spring-cloud.version}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
</dependencies>
</dependencyManagement>
<build>
<plugins>
<plugin>
... ... @@ -118,6 +120,16 @@
</plugin>
</plugins>
</build>
<repositories>
<repository>
<id>spring-milestones</id>
<name>Spring Milestones</name>
<url>https://repo.spring.io/milestone</url>
<snapshots>
<enabled>false</enabled>
</snapshots>
</repository>
</repositories>
</project>
... ...
... ... @@ -3,10 +3,12 @@ package com.sy;
import org.mybatis.spring.annotation.MapperScan;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cloud.netflix.eureka.EnableEurekaClient;
import org.springframework.scheduling.annotation.EnableScheduling;
@SpringBootApplication
@EnableScheduling
@EnableEurekaClient
@MapperScan(value = "com.sy.mapper")
public class AnalysisImfApplication {
... ...
... ... @@ -21,7 +21,7 @@ public class KAKO_Reader extends Thread{
if (IMF_Tesk.LOGIN_OK) synchronized (this) {
String message = this.client.getMSG();
if (message != null) {
logger.info(message);
// logger.info(message);
AnalysisRoute route = new AnalysisRoute();
route.analysis(message);
}
... ... @@ -31,7 +31,7 @@ public class KAKO_Reader extends Thread{
}
try {
Thread.sleep(100L);
Thread.sleep(5000L);
} catch (InterruptedException var3) {
var3.printStackTrace();
... ...
... ... @@ -46,7 +46,7 @@ public class GatherInfoAnalysis {
bean.setIcesealid(info.getIc().getIcEsealId());
bean.setIcbusstype(info.getIc().getIcBussType());
bean.setIcexdata(info.getIc().getIcExData());
bean.setGrosswt((info.getWeight().getGrossWt()).toString());
bean.setGrosswt((info.getWeight().getGrossWt()));
bean.setTrecno(info.getTrailer().getTrEcNo());
bean.setTrname(info.getTrailer().getTrName());
bean.setTrwt((info.getTrailer().getTrWt()));
... ...
... ... @@ -2,17 +2,19 @@ package com.sy.bwAssist;
import com.thoughtworks.xstream.annotations.XStreamAlias;
import java.math.BigDecimal;
@XStreamAlias("WEIGHT")
public class Weight {
@XStreamAlias("GROSS_WT")
private Double GrossWt;
private BigDecimal GrossWt;
public Double getGrossWt() {
public BigDecimal getGrossWt() {
return GrossWt;
}
public void setGrossWt(Double grossWt) {
public void setGrossWt(BigDecimal grossWt) {
GrossWt = grossWt;
}
... ...
... ... @@ -9,6 +9,11 @@ server.port=8082
#spring.thymeleaf.mode=HTML5
#spring.thymeleaf.encoding=UTF-8
#spring.thymeleaf.servlet.content-type=text/html
#eureka注册中心服务器地址
eureka.client.service-url.defaultZone=http://10.50.3.82:19527/eureka/
#服务名
spring.application.name=AnalysisForStation
#设置热部署
#开启热部署
spring.devtools.restart.enabled=true
... ...