Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
提交反馈
为 GitLab 提交贡献
登录
切换导航
P
pica-cloud-yunqueyilian
项目
项目
详情
动态
版本
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
计划
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
收起侧边栏
Close sidebar
动态
分支图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
com.pica.cloud.wechat
pica-cloud-yunqueyilian
提交
feaab709
提交
feaab709
编写于
8月 08, 2018
作者:
hujun
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
changes
上级
变更
24
隐藏空白字符变更
内嵌
并排
正在显示
24 个修改的文件
包含
1485 行增加
和
0 行删除
+1485
-0
.gitignore
.gitignore
+77
-0
pom.xml
client/pom.xml
+35
-0
App.java
...com/pica/cloud/wechat/server/yunqueyilian.client/App.java
+9
-0
pom.xml
common/pom.xml
+35
-0
App.java
...n/java/com/pica/cloud/wechat/yunqueyilian.common/App.java
+8
-0
pom.xml
pom.xml
+33
-0
pom.xml
server/pom.xml
+236
-0
App.java
...n/java/com/pica/cloud/wechat/yunqueyilian.server/App.java
+22
-0
IConfigServiceClient.java
...chat/yunqueyilian.server/client/IConfigServiceClient.java
+22
-0
ConfigServerClient.java
...t/yunqueyilian.server/client/impl/ConfigServerClient.java
+12
-0
BeanConfiguration.java
.../yunqueyilian.server/configuration/BeanConfiguration.java
+21
-0
PropertiesConfiguration.java
...eyilian.server/configuration/PropertiesConfiguration.java
+39
-0
DemoController.java
...wechat/yunqueyilian.server/controller/DemoController.java
+73
-0
Hospital.java
...ica/cloud/wechat/yunqueyilian/server/entity/Hospital.java
+266
-0
HospitalMapper.java
...oud/wechat/yunqueyilian/server/mapper/HospitalMapper.java
+18
-0
bootstrap-dev.properties
server/src/main/resources/bootstrap-dev.properties
+33
-0
bootstrap-prod.properties
server/src/main/resources/bootstrap-prod.properties
+34
-0
bootstrap-test1.properties
server/src/main/resources/bootstrap-test1.properties
+34
-0
bootstrap-test2.properties
server/src/main/resources/bootstrap-test2.properties
+34
-0
bootstrap-uat.properties
server/src/main/resources/bootstrap-uat.properties
+34
-0
bootstrap.properties
server/src/main/resources/bootstrap.properties
+1
-0
mybatis-generator.xml
server/src/main/resources/mybatis-generator.xml
+47
-0
HospitalMapper.xml
server/src/main/resources/mybatis/HospitalMapper.xml
+342
-0
AppTest.java
server/src/test/java/pica/cloud/content/AppTest.java
+20
-0
未找到文件。
.gitignore
0 → 100644
浏览文件 @
feaab709
/target/
!.mvn/wrapper/maven-wrapper.jar
.apt_generated
.classpath
.factorypath
.project
.settings
.springBeans
.sts4-cache
.idea
*.iws
*.iml
*.ipr
/nbproject/private/
/build/
/nbbuild/
/dist/
/nbdist/
/.nb-gradle/
*.iml
out
gen
dao/src/main/resources/mybatis_generator.properties
target/
target/*
/client/target/
client/target/
client/target/*
/common/target/
common/target/
common/target/*
server/target/
server/target/*
dao/target/
dao/target/*
pom.xml.tag
pom.xml.releaseBackup
pom.xml.versionsBackup
pom.xml.next
release.properties
dependency-reduced-pom.xml
buildNumber.properties
.mvn/timing.properties
.DS_Store
/.idea/
*.iws
*.iml
*.ipr
*.bak
# IntelliJ
/out/
# mpeltonen/sbt-idea plugin
.idea_modules/
# JIRA plugin
atlassian-ide-plugin.xml
# Crashlytics plugin (for Android Studio and IntelliJ)
com_crashlytics_export_strings.xml
crashlytics.properties
crashlytics-build.properties
fabric.properties
LOG_PATH_IS_UNDEFINED/
/LOG_PATH_IS_UNDEFINED/
\ No newline at end of file
client/pom.xml
0 → 100644
浏览文件 @
feaab709
<?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>
com.pica.cloud.wechat
</groupId>
<artifactId>
pica-cloud-yunqueyilian
</artifactId>
<version>
1.0.0
</version>
</parent>
<groupId>
com.pica.cloud.wechat
</groupId>
<artifactId>
pica-cloud-yunqueyilian-client
</artifactId>
<name>
pica-cloud-yunqueyilian-client
</name>
<packaging>
jar
</packaging>
<properties>
<project.build.sourceEncoding>
UTF-8
</project.build.sourceEncoding>
<maven.compiler.source>
1.8
</maven.compiler.source>
<maven.compiler.target>
1.8
</maven.compiler.target>
<java.version>
1.8
</java.version>
</properties>
<distributionManagement>
<repository>
<id>
nexus
</id>
<name>
Pica 3rdParty Repository
</name>
<url>
http://192.168.110.42:8082/repository/pica-3rdParty/
</url>
</repository>
</distributionManagement>
<build>
<finalName>
pica-cloud-yunqueyilian-client
</finalName>
</build>
</project>
client/src/main/java/com/pica/cloud/wechat/server/yunqueyilian.client/App.java
0 → 100644
浏览文件 @
feaab709
package
com
.
pica
.
cloud
.
wechat
.
server
.
client
;
public
class
App
{
public
static
void
main
(
String
[]
args
)
{
}
}
common/pom.xml
0 → 100644
浏览文件 @
feaab709
<?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>
com.pica.cloud.wechat
</groupId>
<artifactId>
pica-cloud-yunqueyilian
</artifactId>
<version>
1.0.0
</version>
</parent>
<groupId>
com.pica.cloud.wechat
</groupId>
<artifactId>
pica-cloud-yunqueyilian-common
</artifactId>
<name>
pica-cloud-yunqueyilian-common
</name>
<packaging>
jar
</packaging>
<properties>
<project.build.sourceEncoding>
UTF-8
</project.build.sourceEncoding>
<maven.compiler.source>
1.8
</maven.compiler.source>
<maven.compiler.target>
1.8
</maven.compiler.target>
<java.version>
1.8
</java.version>
</properties>
<distributionManagement>
<repository>
<id>
nexus
</id>
<name>
Pica 3rdParty Repository
</name>
<url>
http://192.168.110.42:8082/repository/pica-3rdParty/
</url>
</repository>
</distributionManagement>
<build>
<finalName>
pica-cloud-yunqueyilian-common
</finalName>
</build>
</project>
common/src/main/java/com/pica/cloud/wechat/yunqueyilian.common/App.java
0 → 100644
浏览文件 @
feaab709
package
com
.
pica
.
cloud
.
wechat
.
common
;
public
class
App
{
public
static
void
main
(
String
[]
args
)
{
}
}
pom.xml
0 → 100644
浏览文件 @
feaab709
<?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.pica.cloud.wechat
</groupId>
<artifactId>
pica-cloud-yunqueyilian
</artifactId>
<version>
1.0.0
</version>
<packaging>
pom
</packaging>
<name>
pica-cloud-yunqueyilian
</name>
<build>
<plugins>
<plugin>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-maven-plugin
</artifactId>
<executions>
<execution>
<goals>
<goal>
repackage
</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
<modules>
<module>
server
</module>
<module>
common
</module>
<module>
client
</module>
</modules>
</project>
\ No newline at end of file
server/pom.xml
0 → 100644
浏览文件 @
feaab709
<?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>
com.pica.cloud.wechat
</groupId>
<artifactId>
pica-cloud-yunqueyilian
</artifactId>
<version>
1.0.0
</version>
</parent>
<groupId>
com.pica.cloud.wechat
</groupId>
<artifactId>
pica-cloud-yunqueyilian-server
</artifactId>
<name>
pica-cloud-yunqueyilian-server
</name>
<packaging>
jar
</packaging>
<properties>
<project.build.sourceEncoding>
UTF-8
</project.build.sourceEncoding>
<project.reporting.outputEncoding>
UTF-8
</project.reporting.outputEncoding>
<maven.compiler.source>
1.8
</maven.compiler.source>
<maven.compiler.target>
1.8
</maven.compiler.target>
<java.version>
1.8
</java.version>
<spring-cloud.version>
Edgware.SR4
</spring-cloud.version>
<spring-boot.version>
1.5.14.RELEASE
</spring-boot.version>
</properties>
<dependencies>
<dependency>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-starter-actuator
</artifactId>
<exclusions>
<exclusion>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-starter-logging
</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-starter-web
</artifactId>
<exclusions>
<exclusion>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-starter-logging
</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>
org.mybatis.spring.boot
</groupId>
<artifactId>
mybatis-spring-boot-starter
</artifactId>
<version>
1.3.2
</version>
</dependency>
<dependency>
<groupId>
org.springframework.cloud
</groupId>
<artifactId>
spring-cloud-starter-config
</artifactId>
</dependency>
<dependency>
<groupId>
org.springframework.cloud
</groupId>
<artifactId>
spring-cloud-starter-eureka
</artifactId>
</dependency>
<dependency>
<groupId>
org.springframework.cloud
</groupId>
<artifactId>
spring-cloud-starter-feign
</artifactId>
</dependency>
<dependency>
<groupId>
org.springframework.cloud
</groupId>
<artifactId>
spring-cloud-starter-hystrix
</artifactId>
</dependency>
<dependency>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-devtools
</artifactId>
<scope>
runtime
</scope>
</dependency>
<dependency>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-starter-test
</artifactId>
<scope>
test
</scope>
</dependency>
<dependency>
<groupId>
com.pica.cloud.foundation
</groupId>
<artifactId>
pica-cloud-service-starter
</artifactId>
<version>
1.0.2
</version>
</dependency>
<dependency>
<groupId>
com.pica.cloud.foundation
</groupId>
<artifactId>
pica-cloud-entity
</artifactId>
<version>
1.0.0
</version>
</dependency>
<dependency>
<groupId>
com.pica.cloud.foundation
</groupId>
<artifactId>
pica-cloud-redis
</artifactId>
<version>
1.1.2
</version>
</dependency>
<dependency>
<groupId>
com.pica.cloud.foundation
</groupId>
<artifactId>
pica-cloud-utils
</artifactId>
<version>
1.0.7-SNAPSHOT
</version>
</dependency>
<dependency>
<groupId>
com.zaxxer
</groupId>
<artifactId>
HikariCP
</artifactId>
<version>
3.1.0
</version>
</dependency>
<dependency>
<groupId>
io.springfox
</groupId>
<artifactId>
springfox-swagger2
</artifactId>
<version>
2.8.0
</version>
</dependency>
<dependency>
<groupId>
io.springfox
</groupId>
<artifactId>
springfox-swagger-ui
</artifactId>
<version>
2.8.0
</version>
</dependency>
<dependency>
<groupId>
mysql
</groupId>
<artifactId>
mysql-connector-java
</artifactId>
<version>
5.1.39
</version>
</dependency>
<dependency>
<groupId>
org.springframework.cloud
</groupId>
<artifactId>
spring-cloud-sleuth-zipkin-stream
</artifactId>
</dependency>
<dependency>
<groupId>
org.springframework.cloud
</groupId>
<artifactId>
spring-cloud-starter-stream-rabbit
</artifactId>
</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>
<dependency>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-starter-parent
</artifactId>
<version>
${spring-boot.version}
</version>
<type>
pom
</type>
<scope>
import
</scope>
</dependency>
</dependencies>
</dependencyManagement>
<repositories>
<repository>
<id>
nexus
</id>
<url>
http://192.168.110.42:8082/repository/maven-public/
</url>
<releases>
<enabled>
true
</enabled>
<updatePolicy>
never
</updatePolicy>
</releases>
<snapshots>
<enabled>
true
</enabled>
<updatePolicy>
always
</updatePolicy>
</snapshots>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>
nexus
</id>
<url>
http://192.168.110.42:8082/repository/maven-public/
</url>
<releases>
<enabled>
true
</enabled>
<updatePolicy>
never
</updatePolicy>
</releases>
<snapshots>
<enabled>
true
</enabled>
<updatePolicy>
always
</updatePolicy>
</snapshots>
</pluginRepository>
</pluginRepositories>
<build>
<finalName>
pica-cloud-yunqueyilian-server
</finalName>
<plugins>
<plugin>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-maven-plugin
</artifactId>
<executions>
<execution>
<goals>
<goal>
repackage
</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>
org.mybatis.generator
</groupId>
<artifactId>
mybatis-generator-maven-plugin
</artifactId>
<version>
1.3.5
</version>
<dependencies>
<dependency>
<groupId>
mysql
</groupId>
<artifactId>
mysql-connector-java
</artifactId>
<version>
5.1.39
</version>
</dependency>
<dependency>
<groupId>
org.mybatis.generator
</groupId>
<artifactId>
mybatis-generator-core
</artifactId>
<version>
1.3.2
</version>
</dependency>
</dependencies>
<executions>
<execution>
<id>
Generate MyBatis Artifacts
</id>
<phase>
package
</phase>
<goals>
<goal>
generate
</goal>
</goals>
</execution>
</executions>
<configuration>
<verbose>
true
</verbose>
<overwrite>
true
</overwrite>
<configurationFile>
src/main/resources/mybatis-generator.xml
</configurationFile>
</configuration>
</plugin>
</plugins>
</build>
</project>
server/src/main/java/com/pica/cloud/wechat/yunqueyilian.server/App.java
0 → 100644
浏览文件 @
feaab709
package
com
.
pica
.
cloud
.
wechat
.
yunqueyilian
.
server
;
import
org.mybatis.spring.annotation.MapperScan
;
import
org.springframework.boot.SpringApplication
;
import
org.springframework.boot.autoconfigure.SpringBootApplication
;
import
org.springframework.cloud.client.circuitbreaker.EnableCircuitBreaker
;
import
org.springframework.cloud.client.discovery.EnableDiscoveryClient
;
import
org.springframework.cloud.netflix.feign.EnableFeignClients
;
import
springfox.documentation.swagger2.annotations.EnableSwagger2
;
@EnableCircuitBreaker
@SpringBootApplication
@EnableDiscoveryClient
@EnableSwagger2
@EnableFeignClients
@MapperScan
(
"com.pica.cloud.wechat.yunqueyilian.server.mapper"
)
public
class
App
{
public
static
void
main
(
String
[]
args
)
{
SpringApplication
.
run
(
App
.
class
,
args
);
}
}
server/src/main/java/com/pica/cloud/wechat/yunqueyilian.server/client/IConfigServiceClient.java
0 → 100644
浏览文件 @
feaab709
package
com
.
pica
.
cloud
.
wechat
.
yunqueyilian
.
server
.
client
;
import
org.springframework.cloud.netflix.feign.FeignClient
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RequestMethod
;
/**
* CONFIG-SERVER: 服务名称
* 服务名称可以从eureka(http://192.168.110.120:7891/)上获得
*/
@FeignClient
(
value
=
"CONFIG-SERVER"
)
public
interface
IConfigServiceClient
{
/**
* 被调用服务的签名
*
* 注意,定义此接口时,@RequestParam("xxx")和@ReqeustHead("xxx")必须写value,
* 不同于springmvc自动根据参数名作为默认值,feign必须指定这个参数对应哪个服务提供端的参数
*/
@RequestMapping
(
value
=
"/beans"
,
method
=
RequestMethod
.
GET
)
String
beans
();
}
server/src/main/java/com/pica/cloud/wechat/yunqueyilian.server/client/impl/ConfigServerClient.java
0 → 100644
浏览文件 @
feaab709
package
com
.
pica
.
cloud
.
wechat
.
yunqueyilian
.
server
.
client
.
impl
;
import
org.springframework.stereotype.Component
;
import
com.pica.cloud.wechat.yunqueyilian.server.client.IConfigServiceClient
;
@Component
public
class
ConfigServerClient
implements
IConfigServiceClient
{
@Override
public
String
beans
()
{
return
"Get bean failed!"
;
}
}
server/src/main/java/com/pica/cloud/wechat/yunqueyilian.server/configuration/BeanConfiguration.java
0 → 100644
浏览文件 @
feaab709
package
com
.
pica
.
cloud
.
wechat
.
yunqueyilian
.
server
.
configuration
;
import
org.springframework.beans.factory.annotation.Value
;
import
org.springframework.cloud.context.config.annotation.RefreshScope
;
import
org.springframework.context.annotation.Bean
;
import
org.springframework.context.annotation.Configuration
;
import
com.pica.cloud.foundation.redis.RedisClient
;
@Configuration
@RefreshScope
public
class
BeanConfiguration
{
@Value
(
"${spring.redis.config}"
)
private
String
configStr
;
@Bean
public
RedisClient
redisClient
()
{
System
.
out
.
println
(
configStr
);
return
new
RedisClient
(
configStr
);
}
}
server/src/main/java/com/pica/cloud/wechat/yunqueyilian.server/configuration/PropertiesConfiguration.java
0 → 100644
浏览文件 @
feaab709
package
com
.
pica
.
cloud
.
wechat
.
yunqueyilian
.
server
.
configuration
;
import
org.springframework.beans.factory.annotation.Value
;
import
org.springframework.cloud.context.config.annotation.RefreshScope
;
import
org.springframework.context.annotation.Configuration
;
@Configuration
@RefreshScope
public
class
PropertiesConfiguration
{
@Value
(
"${app.foundation.token.user.expire}"
)
private
String
userExpire
;
@Value
(
"${app.foundation.token.guest.expire}"
)
private
String
guestExpire
;
public
String
getUserExpire
()
{
return
userExpire
;
}
public
void
setUserExpire
(
String
userExpire
)
{
this
.
userExpire
=
userExpire
;
}
public
String
getGuestExpire
()
{
return
guestExpire
;
}
public
void
setGuestExpire
(
String
guestExpire
)
{
this
.
guestExpire
=
guestExpire
;
}
@Override
public
String
toString
()
{
return
"PropertiesConfiguration{"
+
"userExpire='"
+
userExpire
+
'\''
+
", guestExpire='"
+
guestExpire
+
'\''
+
'}'
;
}
}
server/src/main/java/com/pica/cloud/wechat/yunqueyilian.server/controller/DemoController.java
0 → 100644
浏览文件 @
feaab709
package
com
.
pica
.
cloud
.
wechat
.
yunqueyilian
.
server
.
controller
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.cloud.client.loadbalancer.LoadBalancerClient
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RequestMethod
;
import
org.springframework.web.bind.annotation.RestController
;
import
com.pica.cloud.wechat.yunqueyilian.server.client.IConfigServiceClient
;
import
com.pica.cloud.wechat.yunqueyilian.server.configuration.PropertiesConfiguration
;
import
com.pica.cloud.wechat.yunqueyilian.server.mapper.HospitalMapper
;
import
com.pica.cloud.wechat.yunqueyilian.server.entity.Hospital
;
import
com.pica.cloud.foundation.entity.PicaResponse
;
import
com.pica.cloud.foundation.redis.RedisClient
;
@RestController
@RequestMapping
(
"/demo"
)
@Api
(
value
=
"冒烟测试"
,
description
=
"测试 db,redis,读取自定义配置 以及使用 feign 调用微服务"
)
public
class
DemoController
{
@Autowired
private
HospitalMapper
personMapper
;
@Autowired
private
RedisClient
redisClient
;
@Autowired
private
PropertiesConfiguration
properties
;
@Autowired
private
LoadBalancerClient
slb
;
@Autowired
private
IConfigServiceClient
client
;
@ApiOperation
(
value
=
"DB连接测试:更新Person对象"
,
response
=
PicaResponse
.
class
)
@RequestMapping
(
value
=
"/db"
,
method
=
RequestMethod
.
GET
,
produces
=
"application/json;charset=UTF-8"
)
public
PicaResponse
<
Hospital
>
saveToDB
()
{
// 创建一个ResponseBuilder
PicaResponse
.
Builder
<
Hospital
>
builder
=
new
PicaResponse
.
Builder
<>();
builder
.
setData
(
personMapper
.
selectByPrimaryKey
(
1008
));
// 返回Response
return
builder
.
build
();
}
@ApiOperation
(
value
=
"Redis连接测试:插入一个Person对象到Redis"
,
response
=
PicaResponse
.
class
)
@RequestMapping
(
value
=
"/redis"
,
method
=
RequestMethod
.
GET
,
produces
=
"application/json;charset=UTF-8"
)
public
PicaResponse
<
String
>
saveToCache
()
{
PicaResponse
.
Builder
<
String
>
builder
=
new
PicaResponse
.
Builder
<>();
redisClient
.
set
(
"keyname"
,
personMapper
.
selectByPrimaryKey
(
1008
));
return
builder
.
setData
(
redisClient
.
get
(
"keyname"
)).
build
();
}
@ApiOperation
(
value
=
"读取配置测试"
,
response
=
PicaResponse
.
class
)
@RequestMapping
(
value
=
"/config"
,
method
=
RequestMethod
.
GET
,
produces
=
"application/json;charset=UTF-8"
)
public
PicaResponse
<
String
>
readFromConfiguration
()
{
PicaResponse
.
Builder
<
String
>
builder
=
new
PicaResponse
.
Builder
<>();
builder
.
setData
(
properties
.
toString
());
return
builder
.
build
();
}
@ApiOperation
(
value
=
"Feign调用微服务"
,
response
=
PicaResponse
.
class
)
@RequestMapping
(
value
=
"/beans"
,
method
=
RequestMethod
.
GET
,
produces
=
"application/json;charset=UTF-8"
)
public
String
beans
()
{
return
client
.
beans
();
}
}
server/src/main/java/com/pica/cloud/wechat/yunqueyilian/server/entity/Hospital.java
0 → 100644
浏览文件 @
feaab709
package
com
.
pica
.
cloud
.
wechat
.
yunqueyilian
.
server
.
entity
;
import
java.util.Date
;
public
class
Hospital
{
private
Integer
id
;
private
Integer
provinceId
;
private
String
provinceName
;
private
Long
cityId
;
private
String
cityName
;
private
Long
countyId
;
private
String
countyName
;
private
Long
townId
;
private
String
townName
;
private
Long
villageId
;
private
String
villageName
;
private
String
name
;
private
String
hospitalAddress
;
private
Integer
type
;
private
Integer
deleteFlag
;
private
Integer
creatId
;
private
Date
creatTime
;
private
Integer
modifyId
;
private
Date
modifyTime
;
private
Integer
hospitalStatisticsType
;
private
Integer
hospitalRank
;
private
String
hospitalAlias
;
private
Integer
parentId
;
private
String
hospitalClass
;
private
String
hospitalLevel
;
private
String
hospitalGrade
;
public
Integer
getId
()
{
return
id
;
}
public
void
setId
(
Integer
id
)
{
this
.
id
=
id
;
}
public
Integer
getProvinceId
()
{
return
provinceId
;
}
public
void
setProvinceId
(
Integer
provinceId
)
{
this
.
provinceId
=
provinceId
;
}
public
String
getProvinceName
()
{
return
provinceName
;
}
public
void
setProvinceName
(
String
provinceName
)
{
this
.
provinceName
=
provinceName
==
null
?
null
:
provinceName
.
trim
();
}
public
Long
getCityId
()
{
return
cityId
;
}
public
void
setCityId
(
Long
cityId
)
{
this
.
cityId
=
cityId
;
}
public
String
getCityName
()
{
return
cityName
;
}
public
void
setCityName
(
String
cityName
)
{
this
.
cityName
=
cityName
==
null
?
null
:
cityName
.
trim
();
}
public
Long
getCountyId
()
{
return
countyId
;
}
public
void
setCountyId
(
Long
countyId
)
{
this
.
countyId
=
countyId
;
}
public
String
getCountyName
()
{
return
countyName
;
}
public
void
setCountyName
(
String
countyName
)
{
this
.
countyName
=
countyName
==
null
?
null
:
countyName
.
trim
();
}
public
Long
getTownId
()
{
return
townId
;
}
public
void
setTownId
(
Long
townId
)
{
this
.
townId
=
townId
;
}
public
String
getTownName
()
{
return
townName
;
}
public
void
setTownName
(
String
townName
)
{
this
.
townName
=
townName
==
null
?
null
:
townName
.
trim
();
}
public
Long
getVillageId
()
{
return
villageId
;
}
public
void
setVillageId
(
Long
villageId
)
{
this
.
villageId
=
villageId
;
}
public
String
getVillageName
()
{
return
villageName
;
}
public
void
setVillageName
(
String
villageName
)
{
this
.
villageName
=
villageName
==
null
?
null
:
villageName
.
trim
();
}
public
String
getName
()
{
return
name
;
}
public
void
setName
(
String
name
)
{
this
.
name
=
name
==
null
?
null
:
name
.
trim
();
}
public
String
getHospitalAddress
()
{
return
hospitalAddress
;
}
public
void
setHospitalAddress
(
String
hospitalAddress
)
{
this
.
hospitalAddress
=
hospitalAddress
==
null
?
null
:
hospitalAddress
.
trim
();
}
public
Integer
getType
()
{
return
type
;
}
public
void
setType
(
Integer
type
)
{
this
.
type
=
type
;
}
public
Integer
getDeleteFlag
()
{
return
deleteFlag
;
}
public
void
setDeleteFlag
(
Integer
deleteFlag
)
{
this
.
deleteFlag
=
deleteFlag
;
}
public
Integer
getCreatId
()
{
return
creatId
;
}
public
void
setCreatId
(
Integer
creatId
)
{
this
.
creatId
=
creatId
;
}
public
Date
getCreatTime
()
{
return
creatTime
;
}
public
void
setCreatTime
(
Date
creatTime
)
{
this
.
creatTime
=
creatTime
;
}
public
Integer
getModifyId
()
{
return
modifyId
;
}
public
void
setModifyId
(
Integer
modifyId
)
{
this
.
modifyId
=
modifyId
;
}
public
Date
getModifyTime
()
{
return
modifyTime
;
}
public
void
setModifyTime
(
Date
modifyTime
)
{
this
.
modifyTime
=
modifyTime
;
}
public
Integer
getHospitalStatisticsType
()
{
return
hospitalStatisticsType
;
}
public
void
setHospitalStatisticsType
(
Integer
hospitalStatisticsType
)
{
this
.
hospitalStatisticsType
=
hospitalStatisticsType
;
}
public
Integer
getHospitalRank
()
{
return
hospitalRank
;
}
public
void
setHospitalRank
(
Integer
hospitalRank
)
{
this
.
hospitalRank
=
hospitalRank
;
}
public
String
getHospitalAlias
()
{
return
hospitalAlias
;
}
public
void
setHospitalAlias
(
String
hospitalAlias
)
{
this
.
hospitalAlias
=
hospitalAlias
==
null
?
null
:
hospitalAlias
.
trim
();
}
public
Integer
getParentId
()
{
return
parentId
;
}
public
void
setParentId
(
Integer
parentId
)
{
this
.
parentId
=
parentId
;
}
public
String
getHospitalClass
()
{
return
hospitalClass
;
}
public
void
setHospitalClass
(
String
hospitalClass
)
{
this
.
hospitalClass
=
hospitalClass
==
null
?
null
:
hospitalClass
.
trim
();
}
public
String
getHospitalLevel
()
{
return
hospitalLevel
;
}
public
void
setHospitalLevel
(
String
hospitalLevel
)
{
this
.
hospitalLevel
=
hospitalLevel
==
null
?
null
:
hospitalLevel
.
trim
();
}
public
String
getHospitalGrade
()
{
return
hospitalGrade
;
}
public
void
setHospitalGrade
(
String
hospitalGrade
)
{
this
.
hospitalGrade
=
hospitalGrade
==
null
?
null
:
hospitalGrade
.
trim
();
}
}
\ No newline at end of file
server/src/main/java/com/pica/cloud/wechat/yunqueyilian/server/mapper/HospitalMapper.java
0 → 100644
浏览文件 @
feaab709
package
com
.
pica
.
cloud
.
wechat
.
yunqueyilian
.
server
.
mapper
;
import
com.pica.cloud.wechat.yunqueyilian.server.entity.Hospital
;
public
interface
HospitalMapper
{
int
deleteByPrimaryKey
(
Integer
id
);
int
insert
(
Hospital
record
);
int
insertSelective
(
Hospital
record
);
Hospital
selectByPrimaryKey
(
Integer
id
);
int
updateByPrimaryKeySelective
(
Hospital
record
);
int
updateByPrimaryKey
(
Hospital
record
);
}
\ No newline at end of file
server/src/main/resources/bootstrap-dev.properties
0 → 100644
浏览文件 @
feaab709
server.port
=
8080
spring.application.name
=
${server.port}-pica-cloud-yunqueyilian
#config server settings
spring.cloud.config.name
=
com.pica.cloud.wechat
spring.cloud.config.profile
=
dev
spring.cloud.config.label
=
publish
spring.cloud.config.discovery.enabled
=
true
spring.cloud.config.discovery.service-id
=
config-server
#eureka settings
eureka.instance.instance-id
=
${spring.cloud.client.ipAddress}:${server.port}
eureka.client.service-url.defaultZone
=
http://192.168.110.120:7891/eureka/,http://192.168.110.121:7891/eureka/
eureka.instance.status-page-url
=
http://${spring.cloud.client.ipAddress}:${server.port}/swagger-ui.html
eureka.instance.lease-renewal-interval-in-seconds
=
10
eureka.instance.lease-expiration-duration-in-seconds
=
10
eureka.instance.hostname
=
${spring.cloud.client.ipAddress}
eureka.instance.prefer-ip-address
=
true
#rabbitmq settings
spring.rabbitmq.host
=
192.168.110.206
spring.rabbitmq.port
=
5672
spring.rabbitmq.username
=
appuser
spring.rabbitmq.password
=
AqLfvyWOvLQEUzdI
#local settings
feign.hystrix.enabled
=
true
management.security.enabled
=
false
spring.zipkin.base-url
=
http://192.168.110.124:7895
spring.sleuth.sampler.percentage
=
1.0
logging.config
=
classpath:log4j2-dev.xml
server/src/main/resources/bootstrap-prod.properties
0 → 100644
浏览文件 @
feaab709
server.port
=
8080
spring.application.name
=
${server.port}-pica-cloud-yunqueyilian
#config server settings
spring.cloud.config.name
=
com.pica.cloud.wechat
spring.cloud.config.profile
=
prod
spring.cloud.config.label
=
publish
spring.cloud.config.discovery.enabled
=
true
spring.cloud.config.discovery.service-id
=
prd-config-server
#eureka settings
eureka.instance.instance-id
=
${spring.cloud.client.ipAddress}:${server.port}
eureka.client.service-url.defaultZone
=
http://pica-ms-prd:~!QAZ2wsx3331805prd@172.19.137.14:7891/eureka,http://pica-ms-prd:~!QAZ2wsx3331805prd@172.19.137.15:7891/eureka,http://pica-ms-prd:~!QAZ2wsx3331805prd@172.19.137.16:7891/eureka
eureka.instance.status-page-url
=
http://${spring.cloud.client.ipAddress}:${server.port}/swagger-ui.html
eureka.instance.lease-renewal-interval-in-seconds
=
10
eureka.instance.lease-expiration-duration-in-seconds
=
10
eureka.instance.hostname
=
${spring.cloud.client.ipAddress}
eureka.instance.prefer-ip-address
=
true
#rabbitmq settings
spring.rabbitmq.host
=
172.19.137.0
spring.rabbitmq.port
=
5672
spring.rabbitmq.username
=
appuser
spring.rabbitmq.password
=
AqLfvyWOvLQEUzdI
#local setting
feign.hystrix.enabled
=
true
management.security.enabled
=
true
spring.zipkin.base-url
=
http://172.19.137.19:7895
spring.sleuth.sampler.percentage
=
1.0
logging.config
=
classpath:log4j2-prod.xml
\ No newline at end of file
server/src/main/resources/bootstrap-test1.properties
0 → 100644
浏览文件 @
feaab709
server.port
=
8080
spring.application.name
=
${server.port}-pica-cloud-yunqueyilian
#config server settings
spring.cloud.config.name
=
com.pica.cloud.wechat
spring.cloud.config.profile
=
test1
spring.cloud.config.label
=
publish
spring.cloud.config.discovery.enabled
=
true
spring.cloud.config.discovery.service-id
=
config-server
#eureka settings
eureka.instance.instance-id
=
${spring.cloud.client.ipAddress}:${server.port}
eureka.client.service-url.defaultZone
=
http://192.168.110.128:7891/eureka,http://192.168.110.129:7891/eureka
eureka.instance.status-page-url
=
http://${spring.cloud.client.ipAddress}:${server.port}/swagger-ui.html
eureka.instance.lease-renewal-interval-in-seconds
=
10
eureka.instance.lease-expiration-duration-in-seconds
=
10
eureka.instance.hostname
=
${spring.cloud.client.ipAddress}
eureka.instance.prefer-ip-address
=
true
#rabbigmq settings
spring.rabbitmq.host
=
192.168.110.206
spring.rabbitmq.port
=
5672
spring.rabbitmq.username
=
appuser
spring.rabbitmq.password
=
AqLfvyWOvLQEUzdI
#local settings
feign.hystrix.enabled
=
true
management.security.enabled
=
false
spring.zipkin.base-url
=
http://192.168.110.133:7895
spring.sleuth.sampler.percentage
=
1.0
logging.config
=
classpath:log4j2-test1.xml
\ No newline at end of file
server/src/main/resources/bootstrap-test2.properties
0 → 100644
浏览文件 @
feaab709
server.port
=
8080
spring.application.name
=
${server.port}-pica-cloud-yunqueyilian
#config server settings
spring.cloud.config.name
=
com.pica.cloud.wechat
spring.cloud.config.profile
=
test2
spring.cloud.config.label
=
publish
spring.cloud.config.discovery.enabled
=
true
spring.cloud.config.discovery.service-id
=
config-server
#eureka settings
eureka.instance.instance-id
=
${spring.cloud.client.ipAddress}:${server.port}
eureka.client.service-url.defaultZone
=
http://192.168.110.128:7891/eureka,http://192.168.110.129:7891/eureka
eureka.instance.status-page-url
=
http://${spring.cloud.client.ipAddress}:${server.port}/swagger-ui.html
eureka.instance.lease-renewal-interval-in-seconds
=
10
eureka.instance.lease-expiration-duration-in-seconds
=
10
eureka.instance.hostname
=
${spring.cloud.client.ipAddress}
eureka.instance.prefer-ip-address
=
true
#rabbigmq settings
spring.rabbitmq.host
=
192.168.110.206
spring.rabbitmq.port
=
5672
spring.rabbitmq.username
=
appuser
spring.rabbitmq.password
=
AqLfvyWOvLQEUzdI
#local settings
feign.hystrix.enabled
=
true
management.security.enabled
=
false
spring.zipkin.base-url
=
http://192.168.110.133:7895
spring.sleuth.sampler.percentage
=
1.0
logging.config
=
classpath:log4j2-test1.xml
\ No newline at end of file
server/src/main/resources/bootstrap-uat.properties
0 → 100644
浏览文件 @
feaab709
server.port
=
8080
spring.application.name
=
${server.port}-pica-cloud-yunqueyilian
#config server settings
spring.cloud.config.name
=
com.pica.cloud.wechat
spring.cloud.config.profile
=
uat
spring.cloud.config.label
=
publish
spring.cloud.config.discovery.enabled
=
true
spring.cloud.config.discovery.service-id
=
config-server
#eureka settings
eureka.instance.instance-id
=
${spring.cloud.client.ipAddress}:${server.port}
eureka.client.service-url.defaultZone
=
http://pica-ms:~!QAZ2wsx3331805@192.168.110.137:7891/eureka,http://pica-ms:~!QAZ2wsx3331805@192.168.110.138:7891/eureka
eureka.instance.status-page-url
=
http://${spring.cloud.client.ipAddress}:${server.port}/swagger-ui.html
eureka.instance.lease-renewal-interval-in-seconds
=
10
eureka.instance.lease-expiration-duration-in-seconds
=
10
eureka.instance.hostname
=
${spring.cloud.client.ipAddress}
eureka.instance.prefer-ip-address
=
true
#rabbigmq settings
spring.rabbitmq.host
=
192.168.110.174
spring.rabbitmq.port
=
5672
spring.rabbitmq.username
=
picacloud
spring.rabbitmq.password
=
123456
#local settings
feign.hystrix.enabled
=
true
management.security.enabled
=
false
spring.zipkin.base-url
=
http://192.168.110.141:7895
spring.sleuth.sampler.percentage
=
1.0
logging.config
=
classpath:log4j2-uat.xml
\ No newline at end of file
server/src/main/resources/bootstrap.properties
0 → 100644
浏览文件 @
feaab709
spring.profiles.active
=
dev
server/src/main/resources/mybatis-generator.xml
0 → 100644
浏览文件 @
feaab709
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE generatorConfiguration
PUBLIC "-//mybatis.org//DTD MyBatis Generator Configuration 1.0//EN"
"http://mybatis.org/dtd/mybatis-generator-config_1_0.dtd">
<generatorConfiguration>
<!-- 数据库驱动:选择你的本地硬盘上面的数据库驱动包-->
<classPathEntry
location=
"D:/maven/repository/mysql/mysql-connector-java/5.1.39/mysql-connector-java-5.1.39.jar"
/>
<context
id=
"tableEntity"
targetRuntime=
"MyBatis3"
>
<commentGenerator>
<property
name=
"suppressDate"
value=
"true"
/>
<!-- 是否去除自动生成的注释 true:是 : false:否 -->
<property
name=
"suppressAllComments"
value=
"true"
/>
<property
name=
"addRemarkComments"
value=
"true"
/>
<property
name=
"dateFormat"
value=
"false"
/>
<property
name=
"suppressDate"
value=
"false"
/>
</commentGenerator>
<!--数据库链接URL,用户名、密码 -->
<jdbcConnection
driverClass=
"com.mysql.jdbc.Driver"
connectionURL=
"jdbc:mysql://192.168.110.60:3306/pica"
userId=
"pica_test"
password=
"pkv#sqvSGn@O1@tg"
>
</jdbcConnection>
<javaTypeResolver>
<property
name=
"forceBigDecimals"
value=
"false"
/>
</javaTypeResolver>
<!-- 生成模型的包名和位置-->
<javaModelGenerator
targetPackage=
"com.pica.cloud.wechat.yunqueyilian.server.entity"
targetProject=
"src/main/java"
>
<property
name=
"enableSubPackages"
value=
"true"
/>
<property
name=
"trimStrings"
value=
"true"
/>
</javaModelGenerator>
<!-- 生成映射文件的包名和位置-->
<sqlMapGenerator
targetPackage=
"mybatis"
targetProject=
"src/main/resources"
>
<property
name=
"enableSubPackages"
value=
"true"
/>
</sqlMapGenerator>
<!-- 生成DAO的包名和位置-->
<javaClientGenerator
type=
"XMLMAPPER"
targetPackage=
"com.pica.cloud.wechat.yunqueyilian.server.mapper"
targetProject=
"src/main/java"
>
<property
name=
"enableSubPackages"
value=
"true"
/>
</javaClientGenerator>
<table
tableName=
"pica.p_hospital"
domainObjectName=
"Hospital"
enableCountByExample=
"false"
enableUpdateByExample=
"false"
enableDeleteByExample=
"false"
enableSelectByExample=
"false"
selectByExampleQueryId=
"false"
></table>
</context>
</generatorConfiguration>
server/src/main/resources/mybatis/HospitalMapper.xml
0 → 100644
浏览文件 @
feaab709
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper
namespace=
"com.pica.cloud.wechat.yunqueyilian.server.mapper.HospitalMapper"
>
<resultMap
id=
"BaseResultMap"
type=
"com.pica.cloud.wechat.yunqueyilian.server.entity.Hospital"
>
<id
column=
"id"
property=
"id"
jdbcType=
"INTEGER"
/>
<result
column=
"province_id"
property=
"provinceId"
jdbcType=
"INTEGER"
/>
<result
column=
"province_name"
property=
"provinceName"
jdbcType=
"VARCHAR"
/>
<result
column=
"city_id"
property=
"cityId"
jdbcType=
"BIGINT"
/>
<result
column=
"city_name"
property=
"cityName"
jdbcType=
"VARCHAR"
/>
<result
column=
"county_id"
property=
"countyId"
jdbcType=
"BIGINT"
/>
<result
column=
"county_name"
property=
"countyName"
jdbcType=
"VARCHAR"
/>
<result
column=
"town_id"
property=
"townId"
jdbcType=
"BIGINT"
/>
<result
column=
"town_name"
property=
"townName"
jdbcType=
"VARCHAR"
/>
<result
column=
"village_id"
property=
"villageId"
jdbcType=
"BIGINT"
/>
<result
column=
"village_name"
property=
"villageName"
jdbcType=
"VARCHAR"
/>
<result
column=
"name"
property=
"name"
jdbcType=
"VARCHAR"
/>
<result
column=
"hospital_address"
property=
"hospitalAddress"
jdbcType=
"VARCHAR"
/>
<result
column=
"type"
property=
"type"
jdbcType=
"INTEGER"
/>
<result
column=
"delete_flag"
property=
"deleteFlag"
jdbcType=
"INTEGER"
/>
<result
column=
"creat_id"
property=
"creatId"
jdbcType=
"INTEGER"
/>
<result
column=
"creat_time"
property=
"creatTime"
jdbcType=
"TIMESTAMP"
/>
<result
column=
"modify_id"
property=
"modifyId"
jdbcType=
"INTEGER"
/>
<result
column=
"modify_time"
property=
"modifyTime"
jdbcType=
"TIMESTAMP"
/>
<result
column=
"hospital_statistics_type"
property=
"hospitalStatisticsType"
jdbcType=
"INTEGER"
/>
<result
column=
"hospital_rank"
property=
"hospitalRank"
jdbcType=
"INTEGER"
/>
<result
column=
"hospital_alias"
property=
"hospitalAlias"
jdbcType=
"VARCHAR"
/>
<result
column=
"parent_id"
property=
"parentId"
jdbcType=
"INTEGER"
/>
<result
column=
"hospital_class"
property=
"hospitalClass"
jdbcType=
"VARCHAR"
/>
<result
column=
"hospital_level"
property=
"hospitalLevel"
jdbcType=
"VARCHAR"
/>
<result
column=
"hospital_grade"
property=
"hospitalGrade"
jdbcType=
"VARCHAR"
/>
</resultMap>
<sql
id=
"Base_Column_List"
>
id, province_id, province_name, city_id, city_name, county_id, county_name, town_id,
town_name, village_id, village_name, name, hospital_address, type, delete_flag, creat_id,
creat_time, modify_id, modify_time, hospital_statistics_type, hospital_rank, hospital_alias,
parent_id, hospital_class, hospital_level, hospital_grade
</sql>
<select
id=
"selectByPrimaryKey"
resultMap=
"BaseResultMap"
parameterType=
"java.lang.Integer"
>
select
<include
refid=
"Base_Column_List"
/>
from p_hospital
where id = #{id,jdbcType=INTEGER}
</select>
<delete
id=
"deleteByPrimaryKey"
parameterType=
"java.lang.Integer"
>
delete from p_hospital
where id = #{id,jdbcType=INTEGER}
</delete>
<insert
id=
"insert"
parameterType=
"com.pica.cloud.wechat.yunqueyilian.server.entity.Hospital"
>
insert into p_hospital (id, province_id, province_name,
city_id, city_name, county_id,
county_name, town_id, town_name,
village_id, village_name, name,
hospital_address, type, delete_flag,
creat_id, creat_time, modify_id,
modify_time, hospital_statistics_type, hospital_rank,
hospital_alias, parent_id, hospital_class,
hospital_level, hospital_grade)
values (#{id,jdbcType=INTEGER}, #{provinceId,jdbcType=INTEGER}, #{provinceName,jdbcType=VARCHAR},
#{cityId,jdbcType=BIGINT}, #{cityName,jdbcType=VARCHAR}, #{countyId,jdbcType=BIGINT},
#{countyName,jdbcType=VARCHAR}, #{townId,jdbcType=BIGINT}, #{townName,jdbcType=VARCHAR},
#{villageId,jdbcType=BIGINT}, #{villageName,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR},
#{hospitalAddress,jdbcType=VARCHAR}, #{type,jdbcType=INTEGER}, #{deleteFlag,jdbcType=INTEGER},
#{creatId,jdbcType=INTEGER}, #{creatTime,jdbcType=TIMESTAMP}, #{modifyId,jdbcType=INTEGER},
#{modifyTime,jdbcType=TIMESTAMP}, #{hospitalStatisticsType,jdbcType=INTEGER}, #{hospitalRank,jdbcType=INTEGER},
#{hospitalAlias,jdbcType=VARCHAR}, #{parentId,jdbcType=INTEGER}, #{hospitalClass,jdbcType=VARCHAR},
#{hospitalLevel,jdbcType=VARCHAR}, #{hospitalGrade,jdbcType=VARCHAR})
</insert>
<insert
id=
"insertSelective"
parameterType=
"com.pica.cloud.wechat.yunqueyilian.server.entity.Hospital"
>
insert into p_hospital
<trim
prefix=
"("
suffix=
")"
suffixOverrides=
","
>
<if
test=
"id != null"
>
id,
</if>
<if
test=
"provinceId != null"
>
province_id,
</if>
<if
test=
"provinceName != null"
>
province_name,
</if>
<if
test=
"cityId != null"
>
city_id,
</if>
<if
test=
"cityName != null"
>
city_name,
</if>
<if
test=
"countyId != null"
>
county_id,
</if>
<if
test=
"countyName != null"
>
county_name,
</if>
<if
test=
"townId != null"
>
town_id,
</if>
<if
test=
"townName != null"
>
town_name,
</if>
<if
test=
"villageId != null"
>
village_id,
</if>
<if
test=
"villageName != null"
>
village_name,
</if>
<if
test=
"name != null"
>
name,
</if>
<if
test=
"hospitalAddress != null"
>
hospital_address,
</if>
<if
test=
"type != null"
>
type,
</if>
<if
test=
"deleteFlag != null"
>
delete_flag,
</if>
<if
test=
"creatId != null"
>
creat_id,
</if>
<if
test=
"creatTime != null"
>
creat_time,
</if>
<if
test=
"modifyId != null"
>
modify_id,
</if>
<if
test=
"modifyTime != null"
>
modify_time,
</if>
<if
test=
"hospitalStatisticsType != null"
>
hospital_statistics_type,
</if>
<if
test=
"hospitalRank != null"
>
hospital_rank,
</if>
<if
test=
"hospitalAlias != null"
>
hospital_alias,
</if>
<if
test=
"parentId != null"
>
parent_id,
</if>
<if
test=
"hospitalClass != null"
>
hospital_class,
</if>
<if
test=
"hospitalLevel != null"
>
hospital_level,
</if>
<if
test=
"hospitalGrade != null"
>
hospital_grade,
</if>
</trim>
<trim
prefix=
"values ("
suffix=
")"
suffixOverrides=
","
>
<if
test=
"id != null"
>
#{id,jdbcType=INTEGER},
</if>
<if
test=
"provinceId != null"
>
#{provinceId,jdbcType=INTEGER},
</if>
<if
test=
"provinceName != null"
>
#{provinceName,jdbcType=VARCHAR},
</if>
<if
test=
"cityId != null"
>
#{cityId,jdbcType=BIGINT},
</if>
<if
test=
"cityName != null"
>
#{cityName,jdbcType=VARCHAR},
</if>
<if
test=
"countyId != null"
>
#{countyId,jdbcType=BIGINT},
</if>
<if
test=
"countyName != null"
>
#{countyName,jdbcType=VARCHAR},
</if>
<if
test=
"townId != null"
>
#{townId,jdbcType=BIGINT},
</if>
<if
test=
"townName != null"
>
#{townName,jdbcType=VARCHAR},
</if>
<if
test=
"villageId != null"
>
#{villageId,jdbcType=BIGINT},
</if>
<if
test=
"villageName != null"
>
#{villageName,jdbcType=VARCHAR},
</if>
<if
test=
"name != null"
>
#{name,jdbcType=VARCHAR},
</if>
<if
test=
"hospitalAddress != null"
>
#{hospitalAddress,jdbcType=VARCHAR},
</if>
<if
test=
"type != null"
>
#{type,jdbcType=INTEGER},
</if>
<if
test=
"deleteFlag != null"
>
#{deleteFlag,jdbcType=INTEGER},
</if>
<if
test=
"creatId != null"
>
#{creatId,jdbcType=INTEGER},
</if>
<if
test=
"creatTime != null"
>
#{creatTime,jdbcType=TIMESTAMP},
</if>
<if
test=
"modifyId != null"
>
#{modifyId,jdbcType=INTEGER},
</if>
<if
test=
"modifyTime != null"
>
#{modifyTime,jdbcType=TIMESTAMP},
</if>
<if
test=
"hospitalStatisticsType != null"
>
#{hospitalStatisticsType,jdbcType=INTEGER},
</if>
<if
test=
"hospitalRank != null"
>
#{hospitalRank,jdbcType=INTEGER},
</if>
<if
test=
"hospitalAlias != null"
>
#{hospitalAlias,jdbcType=VARCHAR},
</if>
<if
test=
"parentId != null"
>
#{parentId,jdbcType=INTEGER},
</if>
<if
test=
"hospitalClass != null"
>
#{hospitalClass,jdbcType=VARCHAR},
</if>
<if
test=
"hospitalLevel != null"
>
#{hospitalLevel,jdbcType=VARCHAR},
</if>
<if
test=
"hospitalGrade != null"
>
#{hospitalGrade,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update
id=
"updateByPrimaryKeySelective"
parameterType=
"com.pica.cloud.wechat.yunqueyilian.server.entity.Hospital"
>
update p_hospital
<set
>
<if
test=
"provinceId != null"
>
province_id = #{provinceId,jdbcType=INTEGER},
</if>
<if
test=
"provinceName != null"
>
province_name = #{provinceName,jdbcType=VARCHAR},
</if>
<if
test=
"cityId != null"
>
city_id = #{cityId,jdbcType=BIGINT},
</if>
<if
test=
"cityName != null"
>
city_name = #{cityName,jdbcType=VARCHAR},
</if>
<if
test=
"countyId != null"
>
county_id = #{countyId,jdbcType=BIGINT},
</if>
<if
test=
"countyName != null"
>
county_name = #{countyName,jdbcType=VARCHAR},
</if>
<if
test=
"townId != null"
>
town_id = #{townId,jdbcType=BIGINT},
</if>
<if
test=
"townName != null"
>
town_name = #{townName,jdbcType=VARCHAR},
</if>
<if
test=
"villageId != null"
>
village_id = #{villageId,jdbcType=BIGINT},
</if>
<if
test=
"villageName != null"
>
village_name = #{villageName,jdbcType=VARCHAR},
</if>
<if
test=
"name != null"
>
name = #{name,jdbcType=VARCHAR},
</if>
<if
test=
"hospitalAddress != null"
>
hospital_address = #{hospitalAddress,jdbcType=VARCHAR},
</if>
<if
test=
"type != null"
>
type = #{type,jdbcType=INTEGER},
</if>
<if
test=
"deleteFlag != null"
>
delete_flag = #{deleteFlag,jdbcType=INTEGER},
</if>
<if
test=
"creatId != null"
>
creat_id = #{creatId,jdbcType=INTEGER},
</if>
<if
test=
"creatTime != null"
>
creat_time = #{creatTime,jdbcType=TIMESTAMP},
</if>
<if
test=
"modifyId != null"
>
modify_id = #{modifyId,jdbcType=INTEGER},
</if>
<if
test=
"modifyTime != null"
>
modify_time = #{modifyTime,jdbcType=TIMESTAMP},
</if>
<if
test=
"hospitalStatisticsType != null"
>
hospital_statistics_type = #{hospitalStatisticsType,jdbcType=INTEGER},
</if>
<if
test=
"hospitalRank != null"
>
hospital_rank = #{hospitalRank,jdbcType=INTEGER},
</if>
<if
test=
"hospitalAlias != null"
>
hospital_alias = #{hospitalAlias,jdbcType=VARCHAR},
</if>
<if
test=
"parentId != null"
>
parent_id = #{parentId,jdbcType=INTEGER},
</if>
<if
test=
"hospitalClass != null"
>
hospital_class = #{hospitalClass,jdbcType=VARCHAR},
</if>
<if
test=
"hospitalLevel != null"
>
hospital_level = #{hospitalLevel,jdbcType=VARCHAR},
</if>
<if
test=
"hospitalGrade != null"
>
hospital_grade = #{hospitalGrade,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=INTEGER}
</update>
<update
id=
"updateByPrimaryKey"
parameterType=
"com.pica.cloud.wechat.yunqueyilian.server.entity.Hospital"
>
update p_hospital
set province_id = #{provinceId,jdbcType=INTEGER},
province_name = #{provinceName,jdbcType=VARCHAR},
city_id = #{cityId,jdbcType=BIGINT},
city_name = #{cityName,jdbcType=VARCHAR},
county_id = #{countyId,jdbcType=BIGINT},
county_name = #{countyName,jdbcType=VARCHAR},
town_id = #{townId,jdbcType=BIGINT},
town_name = #{townName,jdbcType=VARCHAR},
village_id = #{villageId,jdbcType=BIGINT},
village_name = #{villageName,jdbcType=VARCHAR},
name = #{name,jdbcType=VARCHAR},
hospital_address = #{hospitalAddress,jdbcType=VARCHAR},
type = #{type,jdbcType=INTEGER},
delete_flag = #{deleteFlag,jdbcType=INTEGER},
creat_id = #{creatId,jdbcType=INTEGER},
creat_time = #{creatTime,jdbcType=TIMESTAMP},
modify_id = #{modifyId,jdbcType=INTEGER},
modify_time = #{modifyTime,jdbcType=TIMESTAMP},
hospital_statistics_type = #{hospitalStatisticsType,jdbcType=INTEGER},
hospital_rank = #{hospitalRank,jdbcType=INTEGER},
hospital_alias = #{hospitalAlias,jdbcType=VARCHAR},
parent_id = #{parentId,jdbcType=INTEGER},
hospital_class = #{hospitalClass,jdbcType=VARCHAR},
hospital_level = #{hospitalLevel,jdbcType=VARCHAR},
hospital_grade = #{hospitalGrade,jdbcType=VARCHAR}
where id = #{id,jdbcType=INTEGER}
</update>
</mapper>
\ No newline at end of file
server/src/test/java/pica/cloud/content/AppTest.java
0 → 100644
浏览文件 @
feaab709
package
com
.
pica
.
cloud
.
wechat
.
yunqueyilian
;
import
static
org
.
junit
.
Assert
.
assertTrue
;
import
org.junit.Test
;
/**
* Unit test for simple App.
*/
public
class
AppTest
{
/**
* Rigorous Test :-)
*/
@Test
public
void
shouldAnswerWithTrue
()
{
assertTrue
(
true
);
}
}
写
预览
Markdown
格式
0%
请重试
or
附加一个文件
附加文件
取消
您添加了
0
人
到此讨论。请谨慎行事。
先完成此消息的编辑!
取消
想要评论请
注册
或
登录