更新代码

This commit is contained in:
ajaxfan
2021-02-01 16:56:07 +08:00
parent f0b1df9c75
commit 1e29d341e3
55 changed files with 805 additions and 1129 deletions

33
bin/.gitignore vendored
View File

@ -1,33 +0,0 @@
HELP.md
target/
!.mvn/wrapper/maven-wrapper.jar
!**/src/main/**/target/
!**/src/test/**/target/
### STS ###
.apt_generated
.classpath
.factorypath
.project
.settings
.springBeans
.sts4-cache
### IntelliJ IDEA ###
.idea
*.iws
*.iml
*.ipr
### NetBeans ###
/nbproject/private/
/nbbuild/
/dist/
/nbdist/
/.nb-gradle/
build/
!**/src/main/**/build/
!**/src/test/**/build/
### VS Code ###
.vscode/

View File

@ -1,7 +0,0 @@
FROM harbor.dcos.guangzhou.unicom.local/eshop/skywalking_agent_springboot_8.1.0:v1.0
ENV LC_ALL=zh_CN.utf8
ENV LANG=zh_CN.utf8
ENV LANGUAGE=zh_CN.utf8
RUN localedef -c -f UTF-8 -i zh_CN zh_CN.utf8
ADD /target/biz_service_ebtp_extend-0.0.1.jar /biz_service_ebtp_extend-0.0.1.jar
ENTRYPOINT ["java", "-Djava.security.egd=file:/dev/./urandom", "-jar", "/biz_service_ebtp_extend-0.0.1.jar"]

View File

@ -1,10 +0,0 @@
# 扩展功能微服务组件
公告通知功能、共享文档...
## 组件模块
1. 包名:功能
2. 包名:功能
3. 包名:功能

View File

@ -1,17 +0,0 @@
apiVersion: v1
clusters:
- cluster:
insecure-skip-tls-verify: true
server: https://10.125.164.35:48662
name: demok8s
contexts:
- context:
cluster: demok8s
user: cluster-admin
name: default
current-context: default
kind: Config
users:
- name: cluster-admin
user:
token: df5e4896a4f6d1b1447b2584ca7405f7

View File

@ -1,83 +0,0 @@
# 接口版本
apiVersion: apps/v1
# 接口类型
kind: Deployment
metadata:
name: biz-service-ebtp-extend
namespace: default
labels:
app: biz-service-ebtp-extend
# 必选,详细定义
spec:
# pod 副本数量
replicas: 1
# 滚动升级配置信息
strategy:
rollingUpdate:
maxSurge: 1
maxUnavailable: 1
# 选择器匹配pod模板
selector:
matchLabels:
app: biz-service-ebtp-extend
template:
metadata:
labels:
# 模板名称
app: biz-service-ebtp-extend
# 定义容器模板,该模板可以包含多个容器
spec:
# 挂载日志存储
volumes:
- name: log
persistentVolumeClaim:
claimName: log-pvc
readOnly: false
- name: storage
persistentVolumeClaim:
claimName: file-pvc
readOnly: false
# 必选Pod中容器列表
containers:
- name: biz-service-ebtp-extend
image: harbor.dcos.guangzhou.unicom.local/eshop/biz-service-ebtp-extend:latest
# 在容器中挂载日志存储区
volumeMounts:
- name: log
mountPath: /log
- name: storage
mountPath: /storage
# 需要暴露的端口库号列表
ports:
- containerPort: 18018
# 容器运行前需设置的环境变量列表
env:
# Apollo 配置中心变量设置
- name: APOLLO_CONFIGSERVICE
value: http://10.242.31.158:6001
---
kind: Service
apiVersion: v1
metadata:
name: biz-service-ebtp-extend
namespace: default
labels:
app: biz-service-ebtp-extend
annotations:
lb.cke.tg.unicom/target-vports: 18018-18018
spec:
ports:
- port: 18018
targetPort: 18018
selector:
app: biz-service-ebtp-extend
status:
loadBalancer: {}
---

View File

@ -1,117 +0,0 @@
<?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.chinaunicom.ebtp</groupId>
<artifactId>mall-ebtp-cloud-parent</artifactId>
<version>0.0.1-SNAPSHOT</version>
</parent>
<groupId>com.chinaunicom.mall.ebtp</groupId>
<artifactId>biz_service_ebtp_extend</artifactId>
<version>0.0.1</version>
<name>biz_service_ebtp_extend</name>
<dependencies>
<dependency>
<groupId>com.chinaunicom.mall.ebtp</groupId>
<artifactId>uboot-core</artifactId>
<version>0.0.2-SNAPSHOT</version>
<exclusions>
<exclusion>
<groupId>com.chinaunicom.ebtp</groupId>
<artifactId>mall-ebtp-cloud-security-starter</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>com.chinaunicom.ebtp</groupId>
<artifactId>mall-ebtp-cloud-attachment-sdk</artifactId>
</dependency>
<dependency>
<groupId>com.chinaunicom.ebtp</groupId>
<artifactId>mall-ebtp-cloud-eureka-starter</artifactId>
</dependency>
<dependency>
<groupId>com.chinaunicom.ebtp</groupId>
<artifactId>mall-ebtp-cloud-feign-starter</artifactId>
</dependency>
<dependency>
<groupId>com.chinaunicom.ebtp</groupId>
<artifactId>mall-ebtp-cloud-apollo-starter</artifactId>
</dependency>
<dependency>
<groupId>com.chinaunicom.ebtp</groupId>
<artifactId>mall-ebtp-cloud-jpa-starter</artifactId>
</dependency>
<dependency>
<groupId>mysql</groupId>
<artifactId>mysql-connector-java</artifactId>
</dependency>
<dependency>
<groupId>org.apache.shardingsphere</groupId>
<artifactId>sharding-jdbc-spring-boot-starter</artifactId>
</dependency>
<dependency>
<groupId>com.chinaunicom.ebtp</groupId>
<artifactId>mall-ebtp-cloud-seata-starter</artifactId>
</dependency>
<dependency>
<groupId>com.chinaunicom.ebtp</groupId>
<artifactId>mall-ebtp-cloud-swagger-starter</artifactId>
</dependency>
<dependency>
<groupId>com.chinaunicom.ebtp</groupId>
<artifactId>mall-ebtp-cloud-redis-starter</artifactId>
</dependency>
</dependencies>
<repositories>
<repository>
<id>maven-snapshot-local</id>
<name>maven-snapshot-local</name>
<url>http://ccp.tianti.tg.unicom.local/artifactory/tianti-maven-snapshot-local/</url>
<releases>
<enabled>false</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
</repository>
</repositories>
<build>
<resources>
<resource>
<directory>src/main/resources</directory>
<filtering>true</filtering>
</resource>
<resource>
<directory>src/main/java</directory>
<includes>
<include>**/mapper/*Mapper.xml</include>
</includes>
</resource>
</resources>
<plugins>
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
</plugin>
</plugins>
</build>
</project>

View File

@ -1,134 +0,0 @@
<?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.chinaunicom.mall.ebtp.extend.bizbidnotice.dao.BizBidNoticeMapper">
<resultMap id="BaseResultMap"
type="com.chinaunicom.mall.ebtp.extend.bizbidnotice.entity.BizBidNotice">
<result column="id" jdbcType="BIGINT" property="id"/>
<result column="notice_name" jdbcType="VARCHAR" property="noticeName"/>
<result column="notice_title" jdbcType="VARCHAR" property="noticeTitle"/>
<result column="notice_content" jdbcType="VARCHAR" property="noticeContent"/>
<result column="notice_file" jdbcType="VARCHAR" property="noticeFile"/>
<result column="notice_release" jdbcType="VARCHAR" property="noticeRelease"/>
<result column="notice_top" jdbcType="VARCHAR" property="noticeTop"/>
<result column="create_by" jdbcType="VARCHAR" property="createBy"/>
<result column="create_date" jdbcType="TIMESTAMP" property="createDate"/>
<result column="update_by" jdbcType="VARCHAR" property="updateBy"/>
<result column="update_date" jdbcType="TIMESTAMP" property="updateDate"/>
<result column="delete_flag" jdbcType="VARCHAR" property="deleteFlag"/>
<result column="tenant_id" jdbcType="VARCHAR" property="tenantId"/>
<result column="tenant_name" jdbcType="VARCHAR" property="tenantName"/>
<result column="last_update_time" jdbcType="TIMESTAMP" property="lastUpdateTime"/>
</resultMap>
<sql id="selectSzReplenishVo">
select id,notice_name, notice_title, notice_content, notice_file,notice_release,notice_top, create_by,
create_date, update_by, update_date,tenant_id,tenant_name,last_update_time, delete_flag from biz_bid_notice
</sql>
<select id="getList" resultMap="BaseResultMap">
<include refid="selectSzReplenishVo"/>
where
delete_flag = "normal"
<if test="null != noticeTitle and '' != noticeTitle">
and notice_title like '%${noticeTitle}%'
</if>
<if test="null != noticeName and '' != noticeName">
and notice_name like '%${noticeName}%'
</if>
and notice_release="open"
ORDER BY notice_top limit #{pageIndex},#{pageSize}
</select>
<select id="getListByTitle" resultMap="BaseResultMap">
<include refid="selectSzReplenishVo"/>
where
delete_flag = "normal"
and notice_release="open" and notice_title like '%${noticeTitle}%' ORDER BY notice_top limit #{pageIndex},#{pageSize}
</select>
<select id="getAllList" resultMap="BaseResultMap">
<include refid="selectSzReplenishVo"/>
where
delete_flag = "normal"
<if test="null != noticeTitle and '' != noticeTitle">
and notice_title like '%${noticeTitle}%'
</if>
<if test="null != noticeName and '' != noticeName">
and notice_name like '%${noticeName}%'
</if>
<if test="null != noticeRelease and '' != noticeRelease">
and notice_release = #{noticeRelease}
</if>
ORDER BY notice_top limit #{pageIndex},#{pageSize}
</select>
<select id="getAllListByTitle" resultMap="BaseResultMap">
<include refid="selectSzReplenishVo"/>
where
delete_flag = "normal" and notice_title like '%${noticeTitle}%' ORDER BY notice_top limit #{pageIndex},#{pageSize}
</select>
<update id="delete" parameterType="com.chinaunicom.mall.ebtp.extend.bizbidnotice.entity.BizBidNotice">
update biz_bid_notice
set
delete_flag="deleted"
where notice_id=#{notice_id} limit #{pageIndex},#{pageSize}
</update>
<update id="fabu" parameterType="java.lang.Long">
update biz_bid_notice
set
notice_release="open"
where id=#{id}
</update>
<update id="qxfabu" parameterType="java.lang.Long">
update biz_bid_notice
set
notice_release="close"
where id=#{id}
</update>
<update id="top" parameterType="java.lang.Long">
update biz_bid_notice
set
notice_top="0"
where id=#{id}
</update>
<update id="qxtop" parameterType="java.lang.Long">
update biz_bid_notice
set
notice_top="1"
where id=#{id}
</update>
<update id="update" parameterType="com.chinaunicom.mall.ebtp.extend.bizbidnotice.entity.BizBidNotice">
update biz_bid_notice
<trim prefix="SET" suffixOverrides=",">
<if test="notice_name != null">notice_name = #{noticeName},</if>
<if test="notice_title != null">notice_title = #{noticeTitle},</if>
<if test="notice_content != null">notice_content = #{noticeContent},</if>
<if test="notice_file != null">notice_file = #{noticeFile},</if>
<if test="notice_release != null">notice_release=#{noticeRelease}</if>
<if test="notice_top != null">notice_top=#{noticeTop}</if>
<if test="update_by != null">update_by = #{updatBy},</if>
<if test="update_date != null">update_date = #{updateDate},</if>
<if test="tenant_id != null">tenant_id = #{tenantId},</if>
<if test="tenant_name != null">tenant_name = #{tenantName},</if>
<if test="last_update_time != null">last_update_time = #{lastTpdateTime},</if>
</trim>
where ID=#{id}
</update>
<!--逻辑删除方法 此方法为代码生成器生成 不允许修改 如有特殊需求 请自行新建SQL语句-->
<update id="deleteOff" parameterType="java.lang.Long">
update biz_bid_notice
set
delete_flag="deleted"
where ID=#{id,jdbcType=BIGINT}
</update>
</mapper>

View File

@ -1,54 +0,0 @@
<?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.chinaunicom.mall.ebtp.extend.bizbidshared.dao.BizBidSharedMapper">
<resultMap id="BaseResultMap"
type="com.chinaunicom.mall.ebtp.extend.bizbidshared.entity.BizBidShared">
<result column="id" jdbcType="BIGINT" property="id"/>
<result column="shared_id" jdbcType="VARCHAR" property="sharedId"/>
<result column="shared_name" jdbcType="VARCHAR" property="sharedName"/>
<result column="shared_role" jdbcType="VARCHAR" property="sharedRole"/>
<result column="shared_file" jdbcType="VARCHAR" property="sharedFile"/>
<result column="shared_remarks" jdbcType="VARCHAR" property="sharedRemarks"/>
<result column="create_by" jdbcType="VARCHAR" property="createBy"/>
<result column="create_date" jdbcType="TIMESTAMP" property="createDate"/>
<result column="update_by" jdbcType="VARCHAR" property="updateBy"/>
<result column="update_date" jdbcType="TIMESTAMP" property="updateDate"/>
<result column="tenant_id" jdbcType="VARCHAR" property="tenantId"/>
<result column="tenant_name" jdbcType="VARCHAR" property="tenantName"/>
<result column="last_update_time" jdbcType="TIMESTAMP" property="lastUpdateTime"/>
<result column="delete_flag" jdbcType="VARCHAR" property="deleteFlag"/>
</resultMap>
<sql id="selectSzReplenishVo">
select id,shared_id, shared_name, shared_role, shared_file,shared_remarks, create_by,
create_date, update_by, update_date,tenant_id,tenant_name,last_update_time, delete_flag from biz_bid_shared
</sql>
<select id="getList" resultMap="BaseResultMap">
<include refid="selectSzReplenishVo"/>
where
delete_flag = "normal"
<if test="null != sharedName and '' != sharedName">
and shared_name like '%${sharedName}%'
</if>
<if test="null != sharedRole and '' != sharedRole">
and shared_role like '%${sharedRole}%'
</if>
limit #{pageIndex},#{pageSize}
</select>
<select id="getListByTitle" resultMap="BaseResultMap">
<include refid="selectSzReplenishVo"/>
where
delete_flag = "normal" and shared_name like '%${sharedName}%'
</select>
<!--逻辑删除方法 此方法为代码生成器生成 不允许修改 如有特殊需求 请自行新建SQL语句-->
<update id="deleteOff" parameterType="java.lang.Long">
update biz_bid_shared
set
delete_flag="deleted"
where ID=#{id,jdbcType=BIGINT}
</update>
</mapper>

View File

@ -1,66 +0,0 @@
<?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.chinaunicom.mall.ebtp.extend.bizbidsharedrecord.dao.BizBidSharedRecordMapper">
<resultMap id="BaseResultMap"
type="com.chinaunicom.mall.ebtp.extend.bizbidsharedrecord.entity.BizBidSharedRecord">
<result column="id" jdbcType="BIGINT" property="id"/>
<result column="record_id" jdbcType="VARCHAR" property="recordId"/>
<result column="record_role" jdbcType="VARCHAR" property="recordRole"/>
<result column="record_name" jdbcType="VARCHAR" property="recordName"/>
<result column="record_staff" jdbcType="VARCHAR" property="recordStaff"/>
<result column="record_account" jdbcType="VARCHAR" property="recordAccount"/>
<result column="create_by" jdbcType="VARCHAR" property="createBy"/>
<result column="create_date" jdbcType="TIMESTAMP" property="createDate"/>
<result column="update_by" jdbcType="VARCHAR" property="updateBy"/>
<result column="update_date" jdbcType="TIMESTAMP" property="updateDate"/>
<result column="tenant_id" jdbcType="VARCHAR" property="tenantId"/>
<result column="tenant_name" jdbcType="VARCHAR" property="tenantName"/>
<result column="last_update_time" jdbcType="TIMESTAMP" property="lastUpdateTime"/>
<result column="delete_flag" jdbcType="VARCHAR" property="deleteFlag"/>
</resultMap>
<sql id="selectSzReplenishVo">
select id,record_id, record_role, record_name, record_staff,record_account, create_by,
create_date, update_by, update_date,tenant_id,tenant_name,last_update_time, delete_flag from biz_bid_shared_record
</sql>
<select id="getlist" resultMap="BaseResultMap">
<include refid="selectSzReplenishVo"/>
where
delete_flag = "normal"
<if test="null != recordId and '' != recordId">
and record_id=#{recordId}
</if>
<if test="null != recordRole and '' != recordRole">
and record_role like '%${recordRole}%'
</if>
<if test="null != recordName and '' != recordName">
and record_name=#{recordName}
</if>
<if test="null != recordStaff and '' != recordStaff">
and record_staff=#{recordStaff}
</if>
<if test="null != recordAccount and '' != recordAccount">
and record_account=#{recordAccount}
</if>
<!-- limit #{pageIndex},#{pageSize}-->
</select>
<select id="getByIdInfo" resultMap="BaseResultMap">
<include refid="selectSzReplenishVo"/>
where
delete_flag = "normal" and record_id=#{recordId} limit #{pageIndex},#{pageSize}
</select>
<!--逻辑删除方法 此方法为代码生成器生成 不允许修改 如有特殊需求 请自行新建SQL语句-->
<update id="deleteOff" parameterType="java.lang.Long">
update biz_bid_shared_record
set
delete_flag="deleted"
where ID=#{id,jdbcType=BIGINT}
</update>
</mapper>

View File

@ -1,194 +0,0 @@
server:
port: 18018
servlet:
context-path: /
# 对应 apollo 配置中心的应用名
app:
id: biz-service-ebtp-extend
# Apollo 配置信息
apollo:
meta: http://10.242.31.158:6001/
bootstrap:
namespace: application
enabled: true
eagerLoad:
enabled: true
spring:
aop:
auto: true #开启spring的aop配置
proxy-target-class: true
application:
name: biz-service-ebtp-extend
shardingsphere:
datasource:
names: ds0
ds0:
type: com.alibaba.druid.pool.DruidDataSource
driver-class-name: com.mysql.cj.jdbc.Driver
username: root
password: root
jdbc-url: jdbc:mysql://10.242.31.158:3033/ebtp_mall_extend?serverTimezone=Asia/Shanghai&useUnicode=true&characterEncoding=utf-8&zeroDateTimeBehavior=convertToNull&useSSL=false&allowPublicKeyRetrieval=true
url: jdbc:mysql://10.242.31.158:3033/ebtp_mall_extend?serverTimezone=Asia/Shanghai&useUnicode=true&characterEncoding=utf-8&zeroDateTimeBehavior=convertToNull&useSSL=false&allowPublicKeyRetrieval=true
filters: stat,wall,log4j
maxActive: 20
initialSize: 1
maxWait: 60000
minIdle: 1
timeBetweenEvictionRunsMillis: 60000
minEvictableIdleTimeMillis: 300000
validationQuery: select 'x'
testWhileIdle: true
testOnBorrow: false
testOnReturn: false
poolPreparedStatements: true
maxOpenPreparedStatements: 20
connection-properties: druid.stat.merggSql=ture;druid.stat.slowSqlMillis=5000
props:
sql:
show: true
jackson:
date-format: yyyy-MM-dd HH:mm:ss
time-zone: GMT+8
serialization:
write-dates-as-timestamps: false
# 天宫Kafka增加了安全认证需要配置安全属性
kafka:
bootstrap-servers: 10.125.164.192:32005,10.125.164.193:32005,10.125.164.194:32005
template:
default-topic: jl_test
# 生产者配置参数
producer:
client-id: core-service-ebtp-crypt
properties:
security.protocol: SASL_PLAINTEXT
sasl.mechanism: SCRAM-SHA-256
sasl.jaas.config: org.apache.kafka.common.security.scram.ScramLoginModule required username="jltest" password="Unicom#123";
# 消费者配置参数
consumer:
group-id: core-service-ebtp-crypt-consumer
auto-offset-reset: latest
properties:
security.protocol: SASL_PLAINTEXT
sasl.mechanism: SCRAM-SHA-256
sasl.jaas.config: org.apache.kafka.common.security.scram.ScramLoginModule required username="jltest" password="Unicom#123";
# 天宫 redis 需要使用哨兵进行访问
redis:
sentinel:
master: eshop-redis
nodes: 10.125.164.124:32718, 10.125.164.118:32716, 10.125.164.121:32716
password: Unicom#135
lettuce:
# jedis:
pool:
maxTotal: 50
minIdle: 1
maxWaitMillis: 5000
maxIdle: 5
testOnBorrow: true
testOnReturn: true
testWhileIdle: true
token:
database: 0
host: 125.32.114.204
port: 16379
password: redis@CC1234
timeout: 6000
uuid:
database: 1
host: 125.32.114.204
port: 16379
password: redis@CC1234
timeout: 6000
cache:
database: 2
host: 125.32.114.204
port: 16379
password: redis@CC1234
timeout: 6000
# 天宫Eureka配置
eureka:
client:
service-url:
defaultZone: http://10.242.31.158:5001/eureka,http://10.242.31.158:5002/eureka,http://10.242.31.158:5003/eureka
instance:
prefer-ip-address: true
hostname: ${spring.cloud.client.ip-address}
instance-ip: ${spring.cloud.client.ip-address}:${server.port}
mybatis-plus:
configuration:
# 是否开启自动驼峰命名规则映射:从数据库列名到Java属性驼峰命名的类似映射
map-underscore-to-camel-case: true
auto-mapping-behavior: full
# 这个配置会将执行的sql打印出来在开发或测试的时候可以用
log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
mapper-locations: classpath*:com/chinaunicom/mall/ebtp/**/mapper/*Mapper.xml
global-config:
# 逻辑删除配置
db-config:
# logic-delete-field: flag # 全局逻辑删除的实体字段名(since 3.3.0,配置后可以忽略不配置步骤2) @TableLogic
logic-delete-value: deleted # 逻辑已删除值
logic-not-delete-value: normal # 逻辑未删除值
# --------------feign ------------
feign:
httpclient:
enabled: false
okhttp:
enabled: true
client:
config:
default:
connect-timeout: 20000
read-timeout: 20000
hystrix:
command:
default:
execution:
timeout:
enabled: true
isolation:
strategy: SEMAPHORE
thread:
timeoutInMilliseconds: 200000 #熔断超时时间
circuitBreaker:
sleepWindowInMilliseconds: 20000
forceClosed: true
ribbon:
ReadTimeout: 20000 #请求处理的超时时间
ConnectTimeout: 20000 #请求连接超时时间
MaxAutoRetries: 0 #对当前实例的重试次数
MaxAutoRetriesNextServer: 1 #切换实例的重试次数 1
mconfig:
workerId: 1
datacenterId: 1
remote:
approval: true #是否需要提交公告审批
media: true #是否需要发送到媒体
#中国联通电子商城外网接入平台 相关参数
token:
userName: zbgg
password: eip_13579
file-wjpt-storage-path: http://111.198.162.67:8081/enr/api/base/file/cgDownload/ #测试地址
#获取file地址
file:
address: http://125.32.114.204:8760/api/core-service-ebtp-updownload/v1/download/oid/
#提交审批相关字段
approve:
wfSectionNo: 002
wfSectionName: 采购审批

View File

@ -1,3 +0,0 @@
spring:
profiles:
active: dev

View File

@ -1,66 +0,0 @@
transport {
# tcp udt unix-domain-socket
type = "TCP"
#NIO NATIVE
server = "NIO"
#enable heartbeat
heartbeat = true
# the client batch send request enable
enableClientBatchSendRequest = true
#thread factory for netty
threadFactory {
bossThreadPrefix = "NettyBoss"
workerThreadPrefix = "NettyServerNIOWorker"
serverExecutorThread-prefix = "NettyServerBizHandler"
shareBossWorker = false
clientSelectorThreadPrefix = "NettyClientSelector"
clientSelectorThreadSize = 1
clientWorkerThreadPrefix = "NettyClientWorkerThread"
# netty boss thread size,will not be used for UDT
bossThreadSize = 1
#auto default pin or 8
workerThreadSize = "default"
}
shutdown {
# when destroy server, wait seconds
wait = 3
}
serialization = "seata"
compressor = "none"
}
service {
#transaction service group mapping
vgroupMapping.biz-service-ebtp-expenses-fescar-service-group = "default"
#only support when registry.type=file, please don't set multiple addresses
default.grouplist = "127.0.0.1:8091"
#degrade, current not support
enableDegrade = false
#disable seata
disableGlobalTransaction = false
}
client {
rm {
asyncCommitBufferLimit = 10000
lock {
retryInterval = 10
retryTimes = 30
retryPolicyBranchRollbackOnConflict = true
}
reportRetryCount = 5
tableMetaCheckEnable = false
reportSuccessEnable = false
}
tm {
commitRetryCount = 5
rollbackRetryCount = 5
}
undo {
dataValidation = true
logSerialization = "jackson"
logTable = "undo_log"
}
log {
exceptionRate = 100
}
}

View File

@ -1,89 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<configuration scan="true" scanPeriod="60 seconds" debug="true">
<property name="logback.logdir" value="/log" />
<property name="logback.appname" value="biz-service-ebtp-extend" />
<contextName>${logback.appname}</contextName>
<!--输出到控制台 ConsoleAppender-->
<appender name="consoleLog" class="ch.qos.logback.core.ConsoleAppender">
<!--展示格式 layout-->
<layout class="ch.qos.logback.classic.PatternLayout">
<pattern>
<pattern>%d{yyyy-MM-dd HH:mm:ss.SSS} %contextName [%thread] %-5level %logger{50} - %msg%n</pattern>
</pattern>
</layout>
</appender>
<appender name="fileInfoLog" class="ch.qos.logback.core.rolling.RollingFileAppender">
<!--如果只是想要 Info 级别的日志,只是过滤 info 还是会输出 Error 日志,因为 Error 的级别高,
所以我们使用下面的策略,可以避免输出 Error 的日志-->
<filter class="ch.qos.logback.classic.filter.LevelFilter">
<!--过滤 Error-->
<level>ERROR</level>
<!--匹配到就禁止-->
<onMatch>DENY</onMatch>
<!--没有匹配到就允许-->
<onMismatch>ACCEPT</onMismatch>
</filter>
<!--日志名称如果没有File 属性那么只会使用FileNamePattern的文件路径规则
如果同时有<File>和<FileNamePattern>,那么当天日志是<File>,明天会自动把今天
的日志改名为今天的日期。即,<File> 的日志都是当天的。
-->
<File>${logback.logdir}/info.${logback.appname}.log</File>
<!--滚动策略,按照时间滚动 TimeBasedRollingPolicy-->
<rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
<!--文件路径,定义了日志的切分方式——把每一天的日志归档到一个文件中,以防止日志填满整个磁盘空间-->
<FileNamePattern>${logback.logdir}/info.${logback.appname}.%d{yyyy-MM-dd}.log</FileNamePattern>
<!--只保留最近3天的日志-->
<maxHistory>3</maxHistory>
<!--应用启动时删除超过时间范围的日志文件-->
<cleanHistoryOnStart>true</cleanHistoryOnStart>
<!--用来指定日志文件的上限大小,那么到了这个值,就会删除旧的日志-->
<!--<totalSizeCap>1GB</totalSizeCap>-->
</rollingPolicy>
<!--日志输出编码格式化-->
<encoder>
<charset>UTF-8</charset>
<pattern>%d [%thread] %-5level %logger{64} %line - %msg%n</pattern>
</encoder>
</appender>
<appender name="fileErrorLog" class="ch.qos.logback.core.rolling.RollingFileAppender">
<!--如果只是想要 Error 级别的日志,那么需要过滤一下,默认是 info 级别的ThresholdFilter-->
<filter class="ch.qos.logback.classic.filter.ThresholdFilter">
<level>Error</level>
</filter>
<!--日志名称如果没有File 属性那么只会使用FileNamePattern的文件路径规则
如果同时有<File>和<FileNamePattern>,那么当天日志是<File>,明天会自动把今天
的日志改名为今天的日期。即,<File> 的日志都是当天的。
-->
<File>${logback.logdir}/error.${logback.appname}.log</File>
<!--滚动策略,按照时间滚动 TimeBasedRollingPolicy-->
<rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
<!--文件路径,定义了日志的切分方式——把每一天的日志归档到一个文件中,以防止日志填满整个磁盘空间-->
<FileNamePattern>${logback.logdir}/error.${logback.appname}.%d{yyyy-MM-dd}.log</FileNamePattern>
<!--只保留最近3天的日志-->
<maxHistory>3</maxHistory>
<!--应用启动时删除超过时间范围的日志文件-->
<cleanHistoryOnStart>true</cleanHistoryOnStart>
<!--用来指定日志文件的上限大小,那么到了这个值,就会删除旧的日志-->
<!--<totalSizeCap>1GB</totalSizeCap>-->
</rollingPolicy>
<!--日志输出编码格式化-->
<encoder>
<charset>UTF-8</charset>
<pattern>%d [%thread] %-5level %logger{128} %line - %msg%n</pattern>
</encoder>
</appender>
<!--指定最基础的日志输出级别-->
<root level="INFO">
<appender-ref ref="consoleLog"/>
<!--appender将会添加到这个logger-->
<appender-ref ref="fileInfoLog"/>
<appender-ref ref="fileErrorLog"/>
</root>
</configuration>

View File

@ -1,79 +0,0 @@
registry {
# file 、nacos 、eureka、redis、zk、consul、etcd3、sofa
type = "eureka"
nacos {
application = "seata-server"
serverAddr = "localhost"
namespace = ""
username = ""
password = ""
}
eureka {
serviceUrl = "http://10.242.31.158:5001/eureka,http://10.242.31.158:5002/eureka,http://10.242.31.158:5003/eureka"
weight = "1"
}
redis {
serverAddr = "localhost:6379"
db = "0"
password = ""
timeout = "0"
}
zk {
serverAddr = "127.0.0.1:2181"
sessionTimeout = 6000
connectTimeout = 2000
username = ""
password = ""
}
consul {
serverAddr = "127.0.0.1:8500"
}
etcd3 {
serverAddr = "http://localhost:2379"
}
sofa {
serverAddr = "127.0.0.1:9603"
region = "DEFAULT_ZONE"
datacenter = "DefaultDataCenter"
group = "SEATA_GROUP"
addressWaitTime = "3000"
}
file {
name = "file.conf"
}
}
config {
# file、nacos 、apollo、zk、consul、etcd3、springCloudConfig
type = "file"
nacos {
serverAddr = "localhost"
namespace = ""
group = "SEATA_GROUP"
username = ""
password = ""
}
consul {
serverAddr = "127.0.0.1:8500"
}
apollo {
appId = "seata-server"
apolloMeta = "http://192.168.1.204:8801"
namespace = "application"
}
zk {
serverAddr = "127.0.0.1:2181"
sessionTimeout = 6000
connectTimeout = 2000
username = ""
password = ""
}
etcd3 {
serverAddr = "http://localhost:2379"
}
file {
name = "file.conf"
}
}

View File

@ -1,21 +0,0 @@
## ---------------------------------------------------------------------------
## Licensed to the Apache Software Foundation (ASF) under one or more
## contributor license agreements. See the NOTICE file distributed with
## this work for additional information regarding copyright ownership.
## The ASF licenses this file to You under the Apache License, Version 2.0
## (the "License"); you may not use this file except in compliance with
## the License. You may obtain a copy of the License at
##
## http://www.apache.org/licenses/LICENSE-2.0
##
## Unless required by applicable law or agreed to in writing, software
## distributed under the License is distributed on an "AS IS" BASIS,
## WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
## See the License for the specific language governing permissions and
## limitations under the License.
## ---------------------------------------------------------------------------
client {
application.id = biz-service-ebtp-extend
transaction.service.group = biz-service-ebtp-extend-fescar-service-group
}

View File

@ -1,7 +0,0 @@
unifast.swagger.basePackage=com.chinaunicom.mall.ebtp.extend
unifast.swagger.title=\u6d4b\u8bd5\u63a5\u53e3\u6587\u6863
unifast.swagger.contactName=\u5409\u6797\u9879\u76ee\u7ec4
unifast.swagger.contactUrl=http://chinaunicom.com
unifast.swagger.contactEmail=chinaunicom@chinaunicom.com
unifast.swagger.version=0.0.1
unifast.swagger.description=\u7840\u540e\u53f0\u529f\u80fd\u6846\u67b6

View File

@ -41,10 +41,6 @@ spec:
persistentVolumeClaim:
claimName: log-pvc
readOnly: false
- name: storage
persistentVolumeClaim:
claimName: file-pvc
readOnly: false
# 必选Pod中容器列表
containers:
@ -54,8 +50,6 @@ spec:
volumeMounts:
- name: log
mountPath: /log
- name: storage
mountPath: /storage
# 需要暴露的端口库号列表
ports:
- containerPort: 18018

View File

@ -1,19 +1,14 @@
package com.chinaunicom.mall.ebtp.extend;
import com.alibaba.druid.spring.boot.autoconfigure.DruidDataSourceAutoConfigure;
import org.mybatis.spring.annotation.MapperScan;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.actuate.autoconfigure.metrics.MeterRegistryCustomizer;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration;
import org.springframework.cloud.netflix.eureka.EnableEurekaClient;
import org.springframework.cloud.openfeign.EnableFeignClients;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.ComponentScan;
import com.alibaba.druid.spring.boot.autoconfigure.DruidDataSourceAutoConfigure;
import io.micrometer.core.instrument.MeterRegistry;
@SpringBootApplication(exclude = {
DataSourceAutoConfiguration.class,
DruidDataSourceAutoConfigure.class
@ -28,9 +23,4 @@ public class BizServiceEbtpExtendApplication {
SpringApplication.run(BizServiceEbtpExtendApplication.class, args);
}
@Bean
public MeterRegistryCustomizer<MeterRegistry> configurer() {
return (registry) -> registry.config().commonTags("application", "biz-service-ebtp-extend");
}
}

View File

@ -0,0 +1,110 @@
package com.chinaunicom.mall.ebtp.extend.export.bean;
import com.baomidou.mybatisplus.annotation.TableName;
import com.chinaunicom.mall.ebtp.common.base.entity.BaseEntity;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import lombok.experimental.Accessors;
import org.springframework.format.annotation.DateTimeFormat;
import java.io.Serializable;
import java.time.LocalDateTime;
/**
* 实体类 BizBidOpenroom
*
* @auto.generated
*/
@Data
@Accessors(chain = true)
@TableName(value = "biz_bid_openroom", autoResultMap = true)
public class BizBidOpenroom extends BaseEntity implements Serializable {
private static final long serialVersionUID = 1L;
/**
* 开标室id
*/
private String id;
/**
* 评审室id
*/
private String assessRoomId;
/**
* 评审室类型 1、资审 2、评审
*/
private Integer roomType;
/**
* 评审轮次id
*/
private String turnId;
/**
* 轮次
*/
private String turnSort;
/**
* 项目id
*/
private String projectId;
/**
* 项目名称
*/
private String projectName;
/**
* 项目编号
*/
private String projectNo;
/**
* 标段id
*/
private String sectionId;
/**
* 标段名称
*/
private String sectionName;
/**
* 标段编号
*/
private String sectionNo;
/**
* 开标室状态 0未开标 1、开标
*/
private String roomState;
/**
* 解封状态(0、为解封 1、解封)
*/
private String unsealState;
/**
* 开标室备注
*/
private String remarks;
/**
* 开标时间
*/
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private LocalDateTime opingTime;
/**
* 开标时限 0 未设置
*/
private String opingTimeLimit;
/**
* 开标结束时间 通过时限计算
*/
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private LocalDateTime opingEndTime;
}

View File

@ -0,0 +1,67 @@
package com.chinaunicom.mall.ebtp.extend.export.bean;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.chinaunicom.mall.ebtp.common.base.entity.BaseEntity;
import com.chinaunicom.mall.ebtp.common.config.CustomLocalDateTimeTypeHandler;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.springframework.format.annotation.DateTimeFormat;
import java.io.Serializable;
import java.time.LocalDateTime;
import java.util.Map;
/**
* 实体类 BizSupplierRegister
*
* @auto.generated
*/
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@ApiModel(value = "BizSupplierRegister对象", description = "供应商报名登记表")
public class BizSupplierRegister extends BaseEntity implements Serializable {
private static final long serialVersionUID = 1L;
/**
* 机构名称
*/
@ApiModelProperty(value = "机构名称")
private String companyName;
/**
* 投标人姓名
*/
@ApiModelProperty(value = "投标人姓名")
private String bidUserName;
/**
* 联系人名称
*/
@ApiModelProperty(value = "联系人名称")
private String contactName;
/**
* 签字确认时间
*/
@ApiModelProperty(value = "签字确认时间")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private LocalDateTime signTime;
private String newPrice;
}

View File

@ -245,4 +245,6 @@ public class ProjectSection extends BaseEntity implements Serializable {
public void setId(String id) {
this.id = id;
}
}

View File

@ -0,0 +1,28 @@
package com.chinaunicom.mall.ebtp.extend.export.bean;
import io.swagger.annotations.ApiModelProperty;
public class Tdoc {
@ApiModelProperty(value = "")
private String assessRoomId;
@ApiModelProperty(value = "轮次")
private Integer turnSort;
public String getAssessRoomId() {
return assessRoomId;
}
public void setAssessRoomId(String assessRoomId) {
this.assessRoomId = assessRoomId;
}
public Integer getTurnSort() {
return turnSort;
}
public void setTurnSort(Integer turnSort) {
this.turnSort = turnSort;
}
}

View File

@ -34,12 +34,19 @@ import org.springframework.web.bind.annotation.RestController;
import com.chinaunicom.mall.ebtp.common.base.entity.BaseResponse;
import com.chinaunicom.mall.ebtp.extend.export.bean.BidEvalDetailDTO;
import com.chinaunicom.mall.ebtp.extend.export.bean.BidEvalInfoDTO;
import com.chinaunicom.mall.ebtp.extend.export.bean.BizBidOpenroom;
import com.chinaunicom.mall.ebtp.extend.export.bean.BizSupplierRegister;
import com.chinaunicom.mall.ebtp.extend.export.bean.ExportParame;
import com.chinaunicom.mall.ebtp.extend.export.bean.ProjectSectionVO;
import com.chinaunicom.mall.ebtp.extend.export.bean.ReviewConfigCategoryDTO;
import com.chinaunicom.mall.ebtp.extend.export.bean.ReviewConfigDetailDTO;
import com.chinaunicom.mall.ebtp.extend.export.bean.Tdoc;
import com.chinaunicom.mall.ebtp.extend.export.services.ExportService;
import com.chinaunicom.mall.ebtp.extend.export.services.ExportServiceOpen;
import com.chinaunicom.mall.ebtp.extend.export.services.ExportServiceProject;
import com.chinaunicom.mall.ebtp.extend.export.services.ExportServiceResps;
import com.chinaunicom.mall.ebtp.extend.export.vo.BidEvalDetailJudgesSummaryVO;
import com.chinaunicom.mall.ebtp.extend.export.vo.BidEvalDetailSummaryVO;
import com.chinaunicom.mall.ebtp.extend.export.vo.BidEvalDetailVO;
import com.chinaunicom.mall.ebtp.extend.export.vo.BidEvalEarlyJudgesSummaryVO;
import com.chinaunicom.mall.ebtp.extend.export.vo.JuryPrintVO;
@ -62,9 +69,10 @@ public class ExportController {
private ExportService exportService;
@Resource
private ExportServiceProject exportServiceProject;
@Resource
private ExportServiceResps exportServiceResps;
@Resource
private ExportServiceOpen exportServiceOpen;
/**
@ -74,26 +82,46 @@ public class ExportController {
*/
@RequestMapping(value = "/kbjl", method = RequestMethod.GET)
@ResponseBody
//TODO 暂未完成
public void exportKbjlMessage(HttpServletRequest request, HttpServletResponse response) throws IOException {
public void exportKbjlMessage(ExportParame parame, HttpServletRequest request, HttpServletResponse response) throws IOException {
Tdoc tdocPara = new Tdoc();
tdocPara.setAssessRoomId(parame.getAssessRoomId());
tdocPara.setTurnSort(Integer.parseInt(parame.getReviewTurnId()));
BaseResponse<List<BizSupplierRegister>> listBaseResponse = exportServiceResps.getTenderQuoteList(tdocPara);
List<BizSupplierRegister> list = listBaseResponse.getData();
ArrayList<Map<String, Object>> maps = new ArrayList<>();
for (int i = 0; i < 4; i++) {
Map<String, Object> data = new HashMap<>();
data.put("num", i);
data.put("tbr", "投标人" + i);
data.put("bj", "10" + i);
data.put("yy", "有争议" + i);
data.put("sign", "签字人" + i + "2021年");
maps.add(data);
if (list != null) {
for (int i = 0; i < list.size(); i++) {
Map<String, Object> data = new HashMap<>();
data.put("num", (i + 1));
data.put("tbr", list.get(i).getBidUserName());
data.put("bj", list.get(i).getNewPrice());
data.put("yy", "");
data.put("sign", list.get(i).getContactName() + ":" + list.get(i).getSignTime());
maps.add(data);
}
}
//查询项目名称
ProjectSectionVO projectSectionVO = new ProjectSectionVO();
projectSectionVO.setId(parame.getSectionId());
BaseResponse<ProjectSectionVO> project = exportServiceProject.selectById(projectSectionVO);
//查询开标时间
BizBidOpenroom bizBidOpenroom = new BizBidOpenroom();
bizBidOpenroom.setAssessRoomId(parame.getAssessRoomId());
BaseResponse<List<BizBidOpenroom>> timeList = exportServiceOpen.list(bizBidOpenroom);
File file = new File("d:/开标记录表.docx");
Map<String, Object> all = new HashMap<String, Object>() {{
put("Record", maps);
put("time", "2020年1月11日");
put("mc", "测试项目");
put("yuan", "9999");
put("time", timeList.getData().get(0).getOpingTime());
put("mc", project.getData().getProjectName());
put("bh", project.getData().getSectionNumber());
put("bao", project.getData().getBidSectBizNum());
put("yuan", "");
}};
HackLoopTableRenderPolicy policy = new HackLoopTableRenderPolicy();
@ -115,7 +143,7 @@ public class ExportController {
*/
@RequestMapping(value = "/judges", method = RequestMethod.GET)
@ResponseBody
public void exportJudgesMessage(ExportParame parame,HttpServletRequest request, HttpServletResponse response) throws IOException {
public void exportJudgesMessage(ExportParame parame, HttpServletRequest request, HttpServletResponse response) throws IOException {
//项目和招标名称处理
ProjectSectionVO projectSectionVO = new ProjectSectionVO();
@ -123,7 +151,7 @@ public class ExportController {
BaseResponse<ProjectSectionVO> list = exportServiceProject.selectById(projectSectionVO);
//专家人员数据
BaseResponse<List<JuryPrintVO>> listBaseResponse=exportService.queryReportPrintByRoomId(parame.getAssessRoomId());
BaseResponse<List<JuryPrintVO>> listBaseResponse = exportService.queryReportPrintByRoomId(parame.getAssessRoomId());
ArrayList<Map<String, Object>> maps = new ArrayList<>();
for (int i = 0; i < listBaseResponse.getData().size(); i++) {
Map<String, Object> data = new HashMap<>();
@ -132,7 +160,7 @@ public class ExportController {
maps.add(data);
}
//获取模板
//获取模板
File file = new File("d:/评标委员会签字表.docx");
//当前时间
@ -142,7 +170,7 @@ public class ExportController {
Map<String, Object> all = new HashMap<String, Object>() {{
put("Judges", maps);
put("time", sdf.format(date));
put("bh",list.getData().getBidSectCode());
put("bh", list.getData().getBidSectCode());
put("mc", list.getData().getProjectName());
}};
@ -158,7 +186,6 @@ public class ExportController {
}
/**
* 3
* 导出方法
@ -175,15 +202,15 @@ public class ExportController {
BaseResponse<ProjectSectionVO> list = exportServiceProject.selectById(projectSectionVO);
//专家人员数据
BaseResponse<List<JuryPrintVO>> listBaseResponse=exportService.queryReportPrintByRoomId(parame.getAssessRoomId());
BaseResponse<List<JuryPrintVO>> listBaseResponse = exportService.queryReportPrintByRoomId(parame.getAssessRoomId());
ArrayList<Map<String, Object>> maps = new ArrayList<>();
for (int i = 0; i < 4; i++) {
for (int i = 0; i < listBaseResponse.getData().size(); i++) {
Map<String, Object> data = new HashMap<>();
data.put("name", listBaseResponse.getData().get(i).getName());
data.put("phone", listBaseResponse.getData().get(i).getMobile());
data.put("idCard", listBaseResponse.getData().get(i).getCertificate());
data.put("isTrue", listBaseResponse.getData().get(i).getAttitude());
data.put("isTrue", listBaseResponse.getData().get(i).getAttitude() == 1 ? "" : "");
data.put("time", listBaseResponse.getData().get(i).getLoginTime());
maps.add(data);
}
@ -205,7 +232,6 @@ public class ExportController {
}
/**
* 4
* 导出方法
@ -214,7 +240,7 @@ public class ExportController {
@RequestMapping(value = "/pbbg", method = RequestMethod.GET)
@ResponseBody
//todo 暂未完成
public void exportAllMessage( ExportParame parame,HttpServletRequest request, HttpServletResponse response) throws IOException {
public void exportAllMessage(ExportParame parame, HttpServletRequest request, HttpServletResponse response) throws IOException {
//表一假数据
List<Map<String, Object>> list1 = new ArrayList<>();
@ -235,17 +261,19 @@ public class ExportController {
list2.add(map);
}
//表三假数据
List<Map<String, Object>> list3 = new ArrayList<>();
for (int i = 0; i < 4; i++) {
Map<String, Object> map = new HashMap<>();
map.put("num", i);
map.put("work", "建设部" + i);
map.put("name", "刘某" + i);
map.put("unit", "全国各地" + i);
list3.add(map);
//表三数据
//专家人员数据
BaseResponse<List<JuryPrintVO>> listBaseResponse = exportService.queryReportPrintByRoomId(parame.getAssessRoomId());
ArrayList<Map<String, Object>> list3 = new ArrayList<>();
for (int i = 0; i < listBaseResponse.getData().size(); i++) {
Map<String, Object> data = new HashMap<>();
data.put("num", (i + 1));
data.put("name", listBaseResponse.getData().get(i).getName());
list3.add(data);
}
//表四假数据
List<Map<String, Object>> list4 = new ArrayList<>();
for (int i = 0; i < 4; i++) {
@ -267,40 +295,83 @@ public class ExportController {
}
//表六假数据
BidEvalDetailDTO bidEvalDetailDTO = new BidEvalDetailDTO();
bidEvalDetailDTO.setAssessRoomId(parame.getAssessRoomId());
bidEvalDetailDTO.setReviewTurnId(parame.getReviewTurnId());
bidEvalDetailDTO.setReviewType(parame.getReviewType());
BaseResponse<Map<String, List<BidEvalDetailSummaryVO>>> list = exportService.findCategoryResultSummary(bidEvalDetailDTO);
//商务数据
List<BidEvalDetailSummaryVO> respondlist1 = list.getData().get("1");
//服务数据,或技术
List<BidEvalDetailSummaryVO> respondlist2 = list.getData().get("5");
//价格数据
List<BidEvalDetailSummaryVO> respondlist3 = list.getData().get("0");
// 综合汇总 表6和表8一份数据
List<BidEvalDetailSummaryVO> all1 = new ArrayList<>();
respondlist1.stream().forEach(o -> {
BidEvalDetailSummaryVO object = new BidEvalDetailSummaryVO();
object.setSupplierRegisterId(o.getSupplierRegisterId());
object.setSupplierRegisterName(o.getSupplierRegisterName());
object.setBusinessAllScore(o.getFinalScore());
all1.add(object);
});
all1.stream().forEach(x -> {
respondlist2.stream().forEach(y -> {
if (x.getSupplierRegisterId().equals(y.getSupplierRegisterId())) {
x.setServiceAllScore(y.getFinalScore());
}
;
});
respondlist3.stream().forEach(z -> {
if (x.getSupplierRegisterId().equals(z.getSupplierRegisterId())) {
x.setPriceAllScore(z.getFinalScore());
}
;
});
BigDecimal allPrice = (x.getBusinessAllScore().add(x.getServiceAllScore()).add(x.getPriceAllScore())).divide(BigDecimal.valueOf(3), 2, BigDecimal.ROUND_HALF_UP);
x.setAllScore(allPrice);
});
//表六 详细评审数据
List<Map<String, Object>> list6 = new ArrayList<>();
for (int i = 0; i < 4; i++) {
for (int i = 0; i < all1.size(); i++) {
Map<String, Object> map = new HashMap<>();
map.put("num", i);
map.put("tbr", "投标人" + i);
map.put("js", "100" + i);
map.put("sw", "99" + i);
map.put("num", (i+1));
map.put("tbr", all1.get(i).getSupplierRegisterName());
map.put("js", all1.get(i).getServiceAllScore());
map.put("sw", all1.get(i).getBusinessAllScore());
list6.add(map);
}
//表七假数据
//表七 价格评审数据
List<Map<String, Object>> list7 = new ArrayList<>();
for (int i = 0; i < 3; i++) {
Map<String, Object> map = new HashMap<>();
map.put("num", i);
map.put("tbr", "投标人" + i);
map.put("bj", "100" + i);
map.put("psjg", "101" + i);
map.put("jgdf", "102" + i);
map.put("tbr", all1.get(i).getSupplierRegisterName());
map.put("bj", all1.get(i).getPriceAllScore());
map.put("psjg", "");
map.put("jgdf", "");
list7.add(map);
}
//表八数据
//表八 评审总结数据
List<Map<String, Object>> list8 = new ArrayList<>();
for (int i = 0; i < 4; i++) {
for (int i = 0; i < all1.size(); i++) {
Map<String, Object> map = new HashMap<>();
map.put("num", i);
map.put("tbr", "投标人" + i);
map.put("swdf", "100" + i);
map.put("jsdf", "101" + i);
map.put("jgdf", "102" + i);
map.put("zhdf", "103" + i);
map.put("bj", "104" + i);
map.put("num", (i+1));
map.put("tbr", all1.get(i).getSupplierRegisterName());
map.put("sw", all1.get(i).getBusinessAllScore());
map.put("js", all1.get(i).getServiceAllScore());
map.put("jg", all1.get(i).getPriceAllScore());
map.put("zhdf", all1.get(i).getAllScore());
map.put("bj", "");
list8.add(map);
}
@ -342,7 +413,6 @@ public class ExportController {
}
/**
* 5
* 导出方法
@ -372,68 +442,260 @@ public class ExportController {
*/
@RequestMapping(value = "dfhz", method = RequestMethod.GET)
@ResponseBody
// TODO: 2021/1/26 暂时未完成
public void exportDfMessage(ExportParame parame, HttpServletRequest request, HttpServletResponse response) throws IOException {
File file = new File("d:/打分汇总表.docx");
BidEvalDetailDTO bidEvalDetailDTO = new BidEvalDetailDTO();
bidEvalDetailDTO.setAssessRoomId(parame.getAssessRoomId());
bidEvalDetailDTO.setReviewTurnId(parame.getReviewTurnId());
bidEvalDetailDTO.setReviewType(parame.getReviewType());
BaseResponse<Map<String, List<BidEvalDetailSummaryVO>>> list = exportService.findCategoryResultSummary(bidEvalDetailDTO);
//表1和表2假数据
List<Map<String, Object>> list12 = new ArrayList<>();
for (int i = 0; i < 3; i++) {
Map<String, Object> map = new HashMap<>();
map.put("name", "投标人" + i);
map.put("num", i);
map.put("z1", 10);
map.put("z2", 15);
map.put("z3", 20);
map.put("avg", 15);
list12.add(map);
//商务数据
List<BidEvalDetailSummaryVO> list1 = list.getData().get("1");
//服务数据
List<BidEvalDetailSummaryVO> list2 = list.getData().get("5");
//价格数据
List<BidEvalDetailSummaryVO> list3 = list.getData().get("0");
BidEvalInfoDTO bidEvalInfoDTO = new BidEvalInfoDTO();
bidEvalInfoDTO.setAssessRoomId(parame.getAssessRoomId());
bidEvalInfoDTO.setReviewTurnId(parame.getReviewTurnId());
bidEvalInfoDTO.setReviewType(parame.getReviewType());
//所有评委
List<MemberVO> memberall = exportService.findRegisterAndUser(bidEvalInfoDTO).getData().stream().findFirst().get().getMembers();
// 综合汇总
List<BidEvalDetailSummaryVO> all = new ArrayList<>();
list1.stream().forEach(o -> {
BidEvalDetailSummaryVO object = new BidEvalDetailSummaryVO();
object.setSupplierRegisterId(o.getSupplierRegisterId());
object.setSupplierRegisterName(o.getSupplierRegisterName());
object.setBusinessAllScore(o.getFinalScore());
all.add(object);
});
all.stream().forEach(x -> {
list2.stream().forEach(y -> {
if (x.getSupplierRegisterId().equals(y.getSupplierRegisterId())) {
x.setServiceAllScore(y.getFinalScore());
}
;
});
list3.stream().forEach(z -> {
if (x.getSupplierRegisterId().equals(z.getSupplierRegisterId())) {
x.setPriceAllScore(z.getFinalScore());
}
;
});
BigDecimal allPrice = (x.getBusinessAllScore().add(x.getServiceAllScore()).add(x.getPriceAllScore())).divide(BigDecimal.valueOf(3), 2, BigDecimal.ROUND_HALF_UP);
x.setAllScore(allPrice);
});
//所有专家
Map<String, BidEvalDetailJudgesSummaryVO> members = list1.get(0).getScoreMap();
//列头
StringBuffer titles0 = new StringBuffer("投标人名称,投标序号");
ArrayList<String> strings = new ArrayList<>();
//专家信息 添加到列头
members.forEach((k, v) -> {
// titles0.append("," + k);
memberall.forEach(x -> {
if (k.equals(x.getUserId())) {
titles0.append("," + x.getName());
}
});
strings.add(v.getCreateBy());
});
//添加最后一列
titles0.append(",平均分");
//最终的列头
String titles = titles0.toString();
// 创建工作簿
SXSSFWorkbook wb = new SXSSFWorkbook();
//表格样式
CellStyle cellStyle = wb.createCellStyle();
//水平居中
cellStyle.setAlignment(HorizontalAlignment.CENTER);
//垂直居中
cellStyle.setVerticalAlignment(VerticalAlignment.CENTER);
//边框
cellStyle.setBorderBottom(BorderStyle.THIN); //下边框
cellStyle.setBorderLeft(BorderStyle.THIN);//左边框
cellStyle.setBorderTop(BorderStyle.THIN);//上边框
cellStyle.setBorderRight(BorderStyle.THIN);//右边框
//渲染所有数据表格
List<BidEvalDetailSummaryVO> createList = null;
/**
* 一共4个表固定循环4次
*/
for (int k = 0; k < 4; k++) {
// 创建表格
Sheet sheet = null;
if (k == 0) {
sheet = wb.createSheet("商务得分");
} else if (k == 1) {
sheet = wb.createSheet("服务得分");
} else if (k == 2) {
sheet = wb.createSheet("价格得分");
titles = "投标人名称,投标序号,价格得分";
} else {
sheet = wb.createSheet("评分汇总表");
titles = "投标人名称,投标序号,商务得分,服务得分,价格得分,综合得分";
}
sheet.createFreezePane(1, 1);
//最右侧列值
Integer index = (titles.split(",").length) - 1;
//行
int rowIndex = 0;
//列
int colIndex = 0;
// 1行 表头
CellRangeAddress region1 = new CellRangeAddress(0, 0, 0, index);
sheet.addMergedRegion(region1);
Row title1 = sheet.createRow(rowIndex++);
Cell titleCell1 = title1.createCell(0);
title1.setHeightInPoints(35);
titleCell1.setCellValue("打分汇总表");
titleCell1.setCellStyle(cellStyle);
// 2行
/* CellRangeAddress region2 = new CellRangeAddress(1, 1, 0, index);
sheet.addMergedRegion(region2);
Row title2 = sheet.createRow(rowIndex++);
Cell titleCell2 = title2.createCell(0);
titleCell2.setCellValue("包名 bao123456");
//3行
CellRangeAddress region3 = new CellRangeAddress(2, 2, 0, index);
sheet.addMergedRegion(region3);
Row title3 = sheet.createRow(rowIndex++);
Cell titleCell3 = title3.createCell(0);
titleCell3.setCellValue("招标编号 bh123456");*/
//4行 得分标题
CellRangeAddress region4 = new CellRangeAddress(1, 1, 0, index);
sheet.addMergedRegion(region4);
Row title4 = sheet.createRow(rowIndex++);
Cell titleCell4 = title4.createCell(0);
if (k == 0) {
titleCell4.setCellValue("商务得分");
createList = list1;
} else if (k == 1) {
titleCell4.setCellValue("服务得分");
createList = list2;
} else if (k == 2) {
titleCell4.setCellValue("价格得分");
createList = list3;
} else {
titleCell4.setCellValue("评分汇总");
}
//5行 列头
Row titleRow5 = sheet.createRow(rowIndex++);
// 设置高度为30
titleRow5.setHeightInPoints(30);
for (String title : titles.split(",")) {
sheet.setColumnWidth(colIndex, 17 * 256);
Cell titleCell = titleRow5.createCell(colIndex++);
titleCell.setCellValue(title);
//设置样式
titleCell.setCellStyle(cellStyle);
}
//6行 数据行
int num = 1;
if (k == 3) {
for (int i = 0; i < all.size(); i++) {
//3为最终汇总表
Row titleRowN = sheet.createRow(rowIndex++);
colIndex = 0;
//投标人名称
Cell cell = titleRowN.createCell(colIndex++);
cell.setCellStyle(cellStyle);
cell.setCellValue(all.get(i).getSupplierRegisterName());
//序号
Cell cell1 = titleRowN.createCell(colIndex++);
cell1.setCellStyle(cellStyle);
cell1.setCellValue(num++);
//商务汇总
Cell cell2 = titleRowN.createCell(colIndex++);
cell2.setCellStyle(cellStyle);
cell2.setCellValue(all.get(i).getBusinessAllScore().toString());
//服务汇总
Cell cell3 = titleRowN.createCell(colIndex++);
cell3.setCellStyle(cellStyle);
cell3.setCellValue(all.get(i).getServiceAllScore().toString());
//价格汇总
Cell cell4 = titleRowN.createCell(colIndex++);
cell4.setCellStyle(cellStyle);
cell4.setCellValue(all.get(i).getPriceAllScore().toString());
//综合得分
Cell cell5 = titleRowN.createCell(colIndex++);
cell5.setCellStyle(cellStyle);
cell5.setCellValue(all.get(i).getAllScore().toString());
}
} else {
for (int i = 0; i < createList.size(); i++) {
colIndex = 0;
Row titleRowN = sheet.createRow(rowIndex++);
//投标人名称
Cell cell = titleRowN.createCell(colIndex++);
cell.setCellStyle(cellStyle);
cell.setCellValue(createList.get(i).getSupplierRegisterName());
//序号
Cell cell1 = titleRowN.createCell(colIndex++);
cell1.setCellStyle(cellStyle);
cell1.setCellValue(num++);
if (k == 2) {
//价格得分 2时无专家评分有最终评分
Cell cellN1 = titleRowN.createCell(colIndex++);
cellN1.setCellStyle(cellStyle);
cellN1.setCellValue(createList.get(i).getFinalScore().toString());
} else {
//所有专家
for (int j = 0; j < createList.get(i).getScoreMap().size(); j++) {
Map<String, BidEvalDetailJudgesSummaryVO> scoreMap = createList.get(i).getScoreMap();
//获取专家的顺序
if (scoreMap != null) {
String score = null;
for (String string : strings) {
if (scoreMap.get(string) != null) {
score = (scoreMap.get(string).getScore()).toString();
} else {
score = "";
}
Cell cellN = titleRowN.createCell(colIndex++);
cellN.setCellStyle(cellStyle);
cellN.setCellValue(score);
}
}
}
//平均分
Cell cellN1 = titleRowN.createCell(colIndex++);
cellN1.setCellStyle(cellStyle);
cellN1.setCellValue(createList.get(i).getFinalScore().toString());
}
}
}
}
String filename = "打分汇总表.xls";
filename = filename.substring(0, filename.lastIndexOf('.')) + filename.substring(filename.lastIndexOf('.'));
response.reset();
response.setContentType("application/octet-stream;charset=utf-8");
response.setHeader("Content-Disposition", "attachment;filename=".concat(new String(filename.getBytes("UTF-8"), "ISO8859-1")));
wb.write(response.getOutputStream());
//表3假数据
List<Map<String, Object>> list3 = new ArrayList<>();
for (int i = 0; i < 4; i++) {
Map<String, Object> map = new HashMap<>();
map.put("name", "投标人" + i);
map.put("num", i);
map.put("jg", i);
list3.add(map);
}
//表4假数据
List<Map<String, Object>> list4 = new ArrayList<>();
for (int i = 0; i < 3; i++) {
Map<String, Object> map = new HashMap<>();
map.put("name", "投标人" + i);
map.put("num", i);
map.put("sw", i);
map.put("fw", i);
map.put("jg", i);
map.put("zh", i);
list4.add(map);
}
Map<String, Object> all = new HashMap<String, Object>() {{
put("table1", list12);
put("table2", list12);
put("table3", list3);
put("table4", list4);
}};
HackLoopTableRenderPolicy policy1 = new HackLoopTableRenderPolicy();
HackLoopTableRenderPolicy policy2 = new HackLoopTableRenderPolicy();
HackLoopTableRenderPolicy policy3 = new HackLoopTableRenderPolicy();
HackLoopTableRenderPolicy policy4 = new HackLoopTableRenderPolicy();
Configure config = Configure.builder().bind("table1", policy1).bind("table2", policy2).bind("table3", policy3).bind("table4", policy4).build();
XWPFTemplate template = XWPFTemplate.compile(file, config).render(all);
String fileName = new String("打分汇总表.docx".getBytes("UTF-8"), "iso-8859-1");
OutputStream os = response.getOutputStream();
response.setHeader("Content-disposition", "attachment; filename=" + fileName);
template.write(os);
}
@ -502,7 +764,6 @@ public class ExportController {
}
// 创建工作簿
SXSSFWorkbook wb = new SXSSFWorkbook();
//表格样式
@ -610,7 +871,7 @@ public class ExportController {
Row titleLast1 = sheet.createRow(rowIndex++);
Cell titleCellLast1 = titleLast1.createCell(0);
titleCellLast1.setCellValue("全体委员签字 ");
CellRangeAddress region6 = new CellRangeAddress((4 + maps.size()+1), (4 + maps.size()+1), 0, 6);
CellRangeAddress region6 = new CellRangeAddress((4 + maps.size() + 1), (4 + maps.size() + 1), 0, 6);
sheet.addMergedRegion(region6);
//时间行
CellStyle cellStyle1 = wb.createCellStyle();
@ -657,10 +918,8 @@ public class ExportController {
bidEvalInfoDTO.setReviewType(parame.getReviewType());
//供应商
List<SupplierRegisterVO> listBaseResponse = exportService.findRegisterAndUser(bidEvalInfoDTO).getData();
//列头
StringBuffer titles0 = new StringBuffer("序号,评审因素,评审标准");
//供应商 顺序
ArrayList<String> strings = new ArrayList<>();
for (int i = 0; i < listBaseResponse.size(); i++) {
@ -719,7 +978,6 @@ public class ExportController {
Row title3 = sheet.createRow(rowIndex++);
Cell titleCell3 = title3.createCell(0);
titleCell3.setCellValue("招标编号 : " + list.getData().getBidSectName());
//4行 列头
Row titleRow5 = sheet.createRow(rowIndex++);
// 设置高度为30
@ -731,7 +989,6 @@ public class ExportController {
//设置样式
titleCell.setCellStyle(cellStyle);
}
// 5行开始渲染
for (ReviewConfigCategoryDTO object : dataList) {
List<ReviewConfigDetailDTO> detailList = object.getDetailList();
@ -753,6 +1010,7 @@ public class ExportController {
Cell cell2 = titleRowN.createCell(colIndex++);
cell2.setCellValue("");
cell2.setCellStyle(cellStyle);
if (scoreMap != null) {
for (String string : strings) {
Boolean actualValue;
@ -1052,6 +1310,7 @@ public class ExportController {
sheet.addMergedRegion(region6);
}
String filename = "评标打分表.xls";
filename = filename.substring(0, filename.lastIndexOf('.')) + filename.substring(filename.lastIndexOf('.'));
response.reset();

View File

@ -1,16 +1,19 @@
package com.chinaunicom.mall.ebtp.extend.export.services;
import java.util.List;
import java.util.Map;
import com.chinaunicom.mall.ebtp.extend.export.bean.BidEvalInfoDTO;
import com.chinaunicom.mall.ebtp.extend.export.bean.ProjectSectionVO;
import com.chinaunicom.mall.ebtp.extend.export.bean.ReviewConfigCategoryDTO;
import com.chinaunicom.mall.ebtp.extend.export.vo.BidEvalDetailSummaryVO;
import com.chinaunicom.mall.ebtp.extend.export.vo.JuryPrintVO;
import com.chinaunicom.mall.ebtp.extend.export.vo.SupplierRegisterPriceScoreVO;
import com.chinaunicom.mall.ebtp.extend.export.vo.SupplierRegisterVO;
import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiParam;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.cloud.openfeign.SpringQueryMap;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
@ -27,6 +30,7 @@ import com.chinaunicom.mall.ebtp.extend.export.bean.BidEvalDetailDTO;
public interface ExportService {
/**
* 不同供应商的打分
*
* @param bidEvalDetailDTO
* @return
*/
@ -36,28 +40,46 @@ public interface ExportService {
/**
* 评委供应商
*
* @param bidEvalInfoDTO
* @return
*/
@PostMapping("/v1/bid/archive/findRegister")
BaseResponse<List<SupplierRegisterVO>> findRegisterAndUser(BidEvalInfoDTO bidEvalInfoDTO);
// @PostMapping("/v1/bid/archive/findRegister")
@GetMapping("/v1/bid/eval/detail/findRegister")
BaseResponse<List<SupplierRegisterVO>> findRegisterAndUser(@SpringQueryMap BidEvalInfoDTO bidEvalInfoDTO);
/**
* 初审汇总
*
* @param bidEvalDetailDTO
* @return
*/
@PostMapping("/v1/bid/eval/summary/findScoreEarlySummary")
BaseResponse<List<ReviewConfigCategoryDTO>> findScoreEarlySummary(@RequestBody BidEvalDetailDTO bidEvalDetailDTO);
BaseResponse<List<ReviewConfigCategoryDTO>> findScoreEarlySummary(@RequestBody BidEvalDetailDTO bidEvalDetailDTO);
@PostMapping("/v1/bid/archive/findPriceScoreRecord")
BaseResponse<List<SupplierRegisterPriceScoreVO>> findPriceScoreRecord( @RequestBody BidEvalDetailDTO bidEvalDetailDTO);
/**
* 价格打分
*
* @param bidEvalDetailDTO
* @return
*/
// @PostMapping("/v1/bid/archive/findPriceScoreRecord")
@PostMapping("/v1/bid/eval/record/findPriceScoreRecord")
BaseResponse<List<SupplierRegisterPriceScoreVO>> findPriceScoreRecord(@SpringQueryMap BidEvalDetailDTO bidEvalDetailDTO);
@ApiOperation("报表打印-通过评审室Id查询评委会成员数据及签到数据")
@GetMapping("v1/jury/report/print/{roomId}")
BaseResponse<List<JuryPrintVO>> queryReportPrintByRoomId(@ApiParam(value = "roomId", required = true) @PathVariable String roomId);
/**
* 打分汇总
*
* @param bidEvalDetailDTO
* @return
*/
@PostMapping("v1/bid/archive/findCategoryResultSummary")
BaseResponse<Map<String, List<BidEvalDetailSummaryVO>>> findCategoryResultSummary(@RequestBody BidEvalDetailDTO bidEvalDetailDTO);
}

View File

@ -1,18 +1,16 @@
package com.chinaunicom.mall.ebtp.extend.export.services;
import java.util.List;
import java.util.Map;
import com.chinaunicom.mall.ebtp.extend.export.bean.BidEvalInfoDTO;
import com.chinaunicom.mall.ebtp.extend.export.bean.ProjectSectionVO;
import com.chinaunicom.mall.ebtp.extend.export.bean.ReviewConfigCategoryDTO;
import com.chinaunicom.mall.ebtp.extend.export.vo.JuryPrintVO;
import com.chinaunicom.mall.ebtp.extend.export.vo.SupplierRegisterPriceScoreVO;
import com.chinaunicom.mall.ebtp.extend.export.vo.SupplierRegisterVO;
import com.chinaunicom.mall.ebtp.extend.export.vo.*;
import org.springframework.stereotype.Component;
import com.chinaunicom.mall.ebtp.common.base.entity.BaseResponse;
import com.chinaunicom.mall.ebtp.extend.export.bean.BidEvalDetailDTO;
import com.chinaunicom.mall.ebtp.extend.export.vo.BidEvalDetailVO;
@Component
public class ExportServiceFallback implements ExportService{
@ -42,5 +40,10 @@ public class ExportServiceFallback implements ExportService{
return null;
}
@Override
public BaseResponse<Map<String, List<BidEvalDetailSummaryVO>>> findCategoryResultSummary(BidEvalDetailDTO bidEvalDetailDTO) {
return null;
}
}

View File

@ -0,0 +1,44 @@
package com.chinaunicom.mall.ebtp.extend.export.services;
import com.chinaunicom.mall.ebtp.common.base.entity.BaseResponse;
import com.chinaunicom.mall.ebtp.common.constant.ServiceNameConstants;
import com.chinaunicom.mall.ebtp.extend.export.bean.BidEvalDetailDTO;
import com.chinaunicom.mall.ebtp.extend.export.bean.BidEvalInfoDTO;
import com.chinaunicom.mall.ebtp.extend.export.bean.BizBidOpenroom;
import com.chinaunicom.mall.ebtp.extend.export.bean.ReviewConfigCategoryDTO;
import com.chinaunicom.mall.ebtp.extend.export.vo.BidEvalDetailSummaryVO;
import com.chinaunicom.mall.ebtp.extend.export.vo.JuryPrintVO;
import com.chinaunicom.mall.ebtp.extend.export.vo.SupplierRegisterPriceScoreVO;
import com.chinaunicom.mall.ebtp.extend.export.vo.SupplierRegisterVO;
import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiParam;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.cloud.openfeign.SpringQueryMap;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import java.util.List;
import java.util.Map;
/**
* 调用 OPEN_SERVICE
*/
@FeignClient(value = ServiceNameConstants.OPEN_SERVICE,fallbackFactory = ExportServiceOpenFallbakFactory.class)
public interface ExportServiceOpen {
/**
* 查询数据
*
* @param
* @return
*/
@ApiOperation("查询数据")
// @GetMapping("/v1/bizbidopenroom/list")
@PostMapping ("/v1/bizbidopenroom/getPostlist")
BaseResponse<List<BizBidOpenroom>> list(@ApiParam(value = "查询对象数据", required = false) BizBidOpenroom bizBidOpenroom);
}

View File

@ -0,0 +1,28 @@
package com.chinaunicom.mall.ebtp.extend.export.services;
import cn.hutool.core.exceptions.ExceptionUtil;
import com.chinaunicom.mall.ebtp.common.base.entity.BaseResponse;
import com.chinaunicom.mall.ebtp.extend.export.bean.BizBidOpenroom;
import com.chinaunicom.mall.ebtp.extend.export.bean.BizSupplierRegister;
import com.chinaunicom.mall.ebtp.extend.export.bean.Tdoc;
import feign.hystrix.FallbackFactory;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Component;
import java.util.List;
@Component
@Slf4j
public class ExportServiceOpenFallbakFactory implements FallbackFactory<ExportServiceOpen> {
@Override
public ExportServiceOpen create(Throwable throwable) {
ExportServiceOpen resps = new ExportServiceOpen() {
@Override
public BaseResponse<List<BizBidOpenroom>> list(BizBidOpenroom bizBidOpenroom) {
return null;
}
};
log.error(ExceptionUtil.stacktraceToString(throwable));
return null;
}
}

View File

@ -0,0 +1,23 @@
package com.chinaunicom.mall.ebtp.extend.export.services;
import com.chinaunicom.mall.ebtp.common.base.entity.BaseResponse;
import com.chinaunicom.mall.ebtp.common.constant.ServiceNameConstants;
import com.chinaunicom.mall.ebtp.extend.export.bean.*;
import io.swagger.annotations.ApiParam;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import java.util.List;
/**
* 调用 RESPS_SERVICE
*/
@FeignClient(value = ServiceNameConstants.RESPS_SERVICE , fallbackFactory = ExportServiceRespsFallbakFactory.class)
public interface ExportServiceResps {
@PostMapping("/v1/tfile/getTenderQuoteList")
BaseResponse<List<BizSupplierRegister>> getTenderQuoteList(@ApiParam(value = "assessRoomId,turnSort", required = true) @RequestBody Tdoc tdocPara);
}

View File

@ -0,0 +1,26 @@
package com.chinaunicom.mall.ebtp.extend.export.services;
import cn.hutool.core.exceptions.ExceptionUtil;
import com.chinaunicom.mall.ebtp.common.base.entity.BaseResponse;
import com.chinaunicom.mall.ebtp.extend.export.bean.BizSupplierRegister;
import com.chinaunicom.mall.ebtp.extend.export.bean.Tdoc;
import feign.hystrix.FallbackFactory;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Component;
import java.util.List;
@Component
@Slf4j
public class ExportServiceRespsFallbakFactory implements FallbackFactory<ExportServiceResps> {
@Override
public ExportServiceResps create(Throwable throwable) {
ExportServiceResps resps = new ExportServiceResps() {
@Override
public BaseResponse<List<BizSupplierRegister>> getTenderQuoteList(Tdoc tdocPara) {
return null;
}
};
log.error(ExceptionUtil.stacktraceToString(throwable));
return null;
}
}

View File

@ -24,7 +24,7 @@ import java.math.BigDecimal;
@ApiModel(value="BidEvalDetailJudgesSummaryVO对象", description="详审专家汇总VO对象")
public class BidEvalDetailJudgesSummaryVO implements Serializable {
private static final long serialVersionUID = 1L;
private static final Long serialVersionUID = 1L;
@ApiModelProperty(value = "专家ID")
@JsonSerialize(using = ToStringSerializer.class)

View File

@ -26,7 +26,7 @@ import java.util.Map;
@ApiModel(value="BidEvalDetailSummaryVO对象", description="详审汇总VO对象")
public class BidEvalDetailSummaryVO implements Serializable {
private static final long serialVersionUID = 1L;
private static final Long serialVersionUID = 1L;
@ApiModelProperty(value = "报名表id(biz_bid_register)")
@JsonSerialize(using = ToStringSerializer.class)
@ -50,4 +50,64 @@ public class BidEvalDetailSummaryVO implements Serializable {
private Map<String, BidEvalDetailJudgesSummaryVO> scoreMap;
@ApiModelProperty(value = "供应商商务汇总")
private BigDecimal businessAllScore;
@ApiModelProperty(value = "供应商服务汇总")
private BigDecimal serviceAllScore;
@ApiModelProperty(value = "供应商价格汇总")
private BigDecimal priceAllScore;
@ApiModelProperty(value = "供应商综合汇总")
private BigDecimal allScore;
public String getSupplierRegisterId() {
return supplierRegisterId;
}
public void setSupplierRegisterId(String supplierRegisterId) {
this.supplierRegisterId = supplierRegisterId;
}
public String getSupplierRegisterName() {
return supplierRegisterName;
}
public void setSupplierRegisterName(String supplierRegisterName) {
this.supplierRegisterName = supplierRegisterName;
}
public BigDecimal getBusinessAllScore() {
return businessAllScore;
}
public void setBusinessAllScore(BigDecimal businessAllScore) {
this.businessAllScore = businessAllScore;
}
public BigDecimal getServiceAllScore() {
return serviceAllScore;
}
public void setServiceAllScore(BigDecimal serviceAllScore) {
this.serviceAllScore = serviceAllScore;
}
public BigDecimal getPriceAllScore() {
return priceAllScore;
}
public void setPriceAllScore(BigDecimal priceAllScore) {
this.priceAllScore = priceAllScore;
}
public BigDecimal getAllScore() {
return allScore;
}
public void setAllScore(BigDecimal allScore) {
this.allScore = allScore;
}
}