Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
amos-boot-biz
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
项目统一框架
amos-boot-biz
Commits
2358b46b
Commit
2358b46b
authored
Nov 03, 2023
by
tianyiming
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
两员配备-三项制度统计统计表数据
parent
ed09931b
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
12 changed files
with
139 additions
and
24 deletions
+139
-24
DateUtils.java
...ava/com/yeejoin/amos/boot/biz/common/utils/DateUtils.java
+1
-0
ThreeSystemsDto.java
...yeejoin/amos/boot/module/tcm/api/dto/ThreeSystemsDto.java
+13
-3
ThreeSystems.java
...yeejoin/amos/boot/module/tcm/api/entity/ThreeSystems.java
+3
-3
ThreeSystemsMapper.java
...n/amos/boot/module/tcm/api/mapper/ThreeSystemsMapper.java
+9
-0
TzsTwoStaffingMapper.java
...amos/boot/module/tcm/api/mapper/TzsTwoStaffingMapper.java
+1
-0
IThreeSystemsService.java
...mos/boot/module/tcm/api/service/IThreeSystemsService.java
+3
-0
ITzsTwoStaffingService.java
...s/boot/module/tcm/api/service/ITzsTwoStaffingService.java
+0
-1
ThreeSystemsMapper.xml
...-tcm-api/src/main/resources/mapper/ThreeSystemsMapper.xml
+97
-0
ThreeSystemsController.java
...oot/module/tcm/biz/controller/ThreeSystemsController.java
+9
-0
TzsTwoStaffingController.java
...t/module/tcm/biz/controller/TzsTwoStaffingController.java
+0
-8
ThreeSystemsServiceImpl.java
.../module/tcm/biz/service/impl/ThreeSystemsServiceImpl.java
+0
-0
TzsTwoStaffingServiceImpl.java
...odule/tcm/biz/service/impl/TzsTwoStaffingServiceImpl.java
+3
-9
No files found.
amos-boot-biz-common/src/main/java/com/yeejoin/amos/boot/biz/common/utils/DateUtils.java
View file @
2358b46b
...
@@ -17,6 +17,7 @@ public class DateUtils {
...
@@ -17,6 +17,7 @@ public class DateUtils {
public
static
final
String
DATE_TIME_PATTERN
=
"yyyy-MM-dd HH:mm:ss"
;
public
static
final
String
DATE_TIME_PATTERN
=
"yyyy-MM-dd HH:mm:ss"
;
public
static
final
String
MINUTE_PATTERN
=
"yyyy-MM-dd HH:mm"
;
public
static
final
String
MINUTE_PATTERN
=
"yyyy-MM-dd HH:mm"
;
public
static
final
String
DATE_HOUR_PATTERN
=
"yyyy-MM-dd HH"
;
public
static
final
String
HOUR_PATTERN
=
"yyyy-MM-dd HH:mm:ss"
;
public
static
final
String
HOUR_PATTERN
=
"yyyy-MM-dd HH:mm:ss"
;
public
static
final
String
DATE_PATTERN
=
"yyyy-MM-dd"
;
public
static
final
String
DATE_PATTERN
=
"yyyy-MM-dd"
;
public
static
final
String
MONTH_PATTERN
=
"yyyy-MM"
;
public
static
final
String
MONTH_PATTERN
=
"yyyy-MM"
;
...
...
amos-boot-system-tzs/amos-boot-module-tcm/amos-boot-module-tcm-api/src/main/java/com/yeejoin/amos/boot/module/tcm/api/dto/ThreeSystemsDto.java
View file @
2358b46b
...
@@ -26,12 +26,22 @@ public class ThreeSystemsDto extends BaseDto {
...
@@ -26,12 +26,22 @@ public class ThreeSystemsDto extends BaseDto {
@ApiModelProperty
(
value
=
"监管单位名称"
)
@ApiModelProperty
(
value
=
"监管单位名称"
)
private
String
supervisoryUnitName
;
private
String
supervisoryUnitName
;
@ApiModelProperty
(
value
=
"监管单位org
c
ode"
)
@ApiModelProperty
(
value
=
"监管单位org
C
ode"
)
private
String
supervisoryUnitOrg
c
ode
;
private
String
supervisoryUnitOrg
C
ode
;
@ApiModelProperty
(
value
=
"监管单位等级"
)
@ApiModelProperty
(
value
=
"监管单位等级"
)
private
String
supervisoryUnitLevel
;
private
String
supervisoryUnitLevel
;
@ApiModelProperty
(
value
=
"使用单位类型"
)
private
String
unitType
;
@ApiModelProperty
(
value
=
"使用单位统一信用代码"
)
private
String
useCode
;
@ApiModelProperty
(
value
=
"检查状态"
)
private
String
checkStatus
;
@ApiModelProperty
(
value
=
"占比"
)
@ApiModelProperty
(
value
=
"占比"
)
private
String
proportion
;
private
String
proportion
;
...
@@ -48,7 +58,7 @@ public class ThreeSystemsDto extends BaseDto {
...
@@ -48,7 +58,7 @@ public class ThreeSystemsDto extends BaseDto {
private
String
planType
;
private
String
planType
;
@ApiModelProperty
(
value
=
"统计日期"
)
@ApiModelProperty
(
value
=
"统计日期"
)
private
Date
checkDate
;
private
String
checkDate
;
@ApiModelProperty
(
value
=
"统计开始日期"
)
@ApiModelProperty
(
value
=
"统计开始日期"
)
private
Date
startDate
;
private
Date
startDate
;
...
...
amos-boot-system-tzs/amos-boot-module-tcm/amos-boot-module-tcm-api/src/main/java/com/yeejoin/amos/boot/module/tcm/api/entity/ThreeSystems.java
View file @
2358b46b
...
@@ -39,8 +39,8 @@ public class ThreeSystems extends BaseEntity {
...
@@ -39,8 +39,8 @@ public class ThreeSystems extends BaseEntity {
/**
/**
* 监管单位orgcode
* 监管单位orgcode
*/
*/
@TableField
(
"supervisory_unit_orgcode"
)
@TableField
(
"supervisory_unit_org
_
code"
)
private
String
supervisoryUnitOrg
c
ode
;
private
String
supervisoryUnitOrg
C
ode
;
/**
/**
* 监管单位等级
* 监管单位等级
...
@@ -82,6 +82,6 @@ public class ThreeSystems extends BaseEntity {
...
@@ -82,6 +82,6 @@ public class ThreeSystems extends BaseEntity {
* 统计日期
* 统计日期
*/
*/
@TableField
(
"check_date"
)
@TableField
(
"check_date"
)
private
Date
checkDate
;
private
String
checkDate
;
}
}
amos-boot-system-tzs/amos-boot-module-tcm/amos-boot-module-tcm-api/src/main/java/com/yeejoin/amos/boot/module/tcm/api/mapper/ThreeSystemsMapper.java
View file @
2358b46b
package
com
.
yeejoin
.
amos
.
boot
.
module
.
tcm
.
api
.
mapper
;
package
com
.
yeejoin
.
amos
.
boot
.
module
.
tcm
.
api
.
mapper
;
import
com.yeejoin.amos.boot.module.tcm.api.dto.ThreeSystemsDto
;
import
com.yeejoin.amos.boot.module.tcm.api.entity.ThreeSystems
;
import
com.yeejoin.amos.boot.module.tcm.api.entity.ThreeSystems
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
org.apache.ibatis.annotations.Param
;
import
java.util.List
;
/**
/**
* Mapper 接口
* Mapper 接口
...
@@ -11,4 +15,9 @@ import com.baomidou.mybatisplus.core.mapper.BaseMapper;
...
@@ -11,4 +15,9 @@ import com.baomidou.mybatisplus.core.mapper.BaseMapper;
*/
*/
public
interface
ThreeSystemsMapper
extends
BaseMapper
<
ThreeSystems
>
{
public
interface
ThreeSystemsMapper
extends
BaseMapper
<
ThreeSystems
>
{
List
<
ThreeSystemsDto
>
getCompanyThreeSystemsStatisticsList
(
@Param
(
"type"
)
Integer
type
,
@Param
(
"startDay"
)
String
startDay
,
@Param
(
"endDay"
)
String
endDay
);
void
saveOrUpdateBatch
(
@Param
(
"resultList"
)
List
<
ThreeSystems
>
resultList
);
List
<
ThreeSystemsDto
>
getOldCompanyThreeSystemsStatisticsList
(
@Param
(
"type"
)
Integer
type
,
@Param
(
"lastStart"
)
String
lastStart
);
}
}
amos-boot-system-tzs/amos-boot-module-tcm/amos-boot-module-tcm-api/src/main/java/com/yeejoin/amos/boot/module/tcm/api/mapper/TzsTwoStaffingMapper.java
View file @
2358b46b
...
@@ -2,6 +2,7 @@ package com.yeejoin.amos.boot.module.tcm.api.mapper;
...
@@ -2,6 +2,7 @@ package com.yeejoin.amos.boot.module.tcm.api.mapper;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.yeejoin.amos.boot.module.tcm.api.dto.ThreeSystemsDto
;
import
com.yeejoin.amos.boot.module.tcm.api.dto.TzsTwoStaffingCompanyCheckDto
;
import
com.yeejoin.amos.boot.module.tcm.api.dto.TzsTwoStaffingCompanyCheckDto
;
import
com.yeejoin.amos.boot.module.tcm.api.dto.TzsTwoStaffingCompanyDto
;
import
com.yeejoin.amos.boot.module.tcm.api.dto.TzsTwoStaffingCompanyDto
;
import
com.yeejoin.amos.boot.module.tcm.api.entity.TzsTwoStaffing
;
import
com.yeejoin.amos.boot.module.tcm.api.entity.TzsTwoStaffing
;
...
...
amos-boot-system-tzs/amos-boot-module-tcm/amos-boot-module-tcm-api/src/main/java/com/yeejoin/amos/boot/module/tcm/api/service/IThreeSystemsService.java
View file @
2358b46b
...
@@ -15,4 +15,7 @@ import java.util.List;
...
@@ -15,4 +15,7 @@ import java.util.List;
public
interface
IThreeSystemsService
{
public
interface
IThreeSystemsService
{
List
<
ThreeSystems
>
getStatisticsMessage
(
List
<
LinkedHashMap
>
list
,
String
planType
,
String
startDate
,
String
endDate
);
List
<
ThreeSystems
>
getStatisticsMessage
(
List
<
LinkedHashMap
>
list
,
String
planType
,
String
startDate
,
String
endDate
);
void
getThreeSystemsStatistics
(
String
type
);
}
}
amos-boot-system-tzs/amos-boot-module-tcm/amos-boot-module-tcm-api/src/main/java/com/yeejoin/amos/boot/module/tcm/api/service/ITzsTwoStaffingService.java
View file @
2358b46b
...
@@ -25,6 +25,5 @@ public interface ITzsTwoStaffingService {
...
@@ -25,6 +25,5 @@ public interface ITzsTwoStaffingService {
Page
<
TzsTwoStaffingCompanyCheckDto
>
getCompanyCheckList
(
String
orgCode
,
TzsTwoStaffingCompanyCheckDto
companyDto
,
Page
<
TzsTwoStaffingCompanyCheckDto
>
page
);
Page
<
TzsTwoStaffingCompanyCheckDto
>
getCompanyCheckList
(
String
orgCode
,
TzsTwoStaffingCompanyCheckDto
companyDto
,
Page
<
TzsTwoStaffingCompanyCheckDto
>
page
);
void
getThreeSystemsStatistics
();
}
}
amos-boot-system-tzs/amos-boot-module-tcm/amos-boot-module-tcm-api/src/main/resources/mapper/ThreeSystemsMapper.xml
View file @
2358b46b
...
@@ -2,4 +2,101 @@
...
@@ -2,4 +2,101 @@
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"com.yeejoin.amos.boot.module.tcm.api.mapper.ThreeSystemsMapper"
>
<mapper
namespace=
"com.yeejoin.amos.boot.module.tcm.api.mapper.ThreeSystemsMapper"
>
<select
id=
"getCompanyThreeSystemsStatisticsList"
resultType=
"com.yeejoin.amos.boot.module.tcm.api.dto.ThreeSystemsDto"
>
SELECT
ei.use_code useCode,
ei.supervise_org_code supervisoryUnitOrgCode,
ei.unit_type unitType,
CASE
WHEN (
SELECT COUNT
( 1 )
FROM
amos_tzs_biz.p_plan_task pt
WHERE
pt.finish_status = '2'
AND ppt.use_code = pt.use_code
AND pt.check_date BETWEEN #{startDay}
AND #{endDay}
AND pt.plan_type = #{type}
) > 0 THEN
1 ELSE 0
END AS checkStatus
FROM
amos_tzs_biz.tz_base_enterprise_info ei
LEFT JOIN amos_tzs_biz.p_plan_task ppt ON ei.use_code = ppt.use_code
GROUP BY
ei.use_code
</select>
<select
id=
"saveOrUpdateBatch"
>
INSERT INTO "amos_tzs_biz"."tzs_three_systems" (
"sequence_nbr",
"rec_date",
"rec_user_id",
"rec_user_name",
"is_delete",
"supervisory_unit_id",
"supervisory_unit_name",
"supervisory_unit_org_code",
"supervisory_unit_level",
"proportion",
"registered_num",
"check_num",
"finish_check_num",
"plan_type",
"check_date"
)
VALUES
<foreach
collection=
"resultList"
item=
"item"
index=
"index"
separator=
","
>
(
#{item.sequenceNbr},
#{item.recDate},
#{item.recUserId},
#{item.recUserName},
false,
#{item.supervisoryUnitId},
#{item.supervisoryUnitName},
#{item.supervisoryUnitOrgCode},
#{item.supervisoryUnitLevel},
#{item.proportion},
#{item.registeredNum},
#{item.checkNum},
#{item.finishCheckNum},
#{item.planType},
#{item.checkDate}
)
</foreach>
on conflict (supervisory_unit_org_code,plan_type,check_date) do update set
"sequence_nbr" = EXCLUDED."sequence_nbr",
"rec_date" = EXCLUDED."rec_date",
"rec_user_id" = EXCLUDED."rec_user_id",
"rec_user_name" = EXCLUDED."rec_user_name",
"is_delete" = EXCLUDED."is_delete",
"supervisory_unit_id" = EXCLUDED."supervisory_unit_id",
"supervisory_unit_name" = EXCLUDED."supervisory_unit_name",
"supervisory_unit_org_code" = EXCLUDED."supervisory_unit_org_code",
"supervisory_unit_level" = EXCLUDED."supervisory_unit_level",
"proportion" = EXCLUDED."proportion",
"registered_num" = EXCLUDED."registered_num",
"check_num" = EXCLUDED."check_num",
"finish_check_num" = EXCLUDED."finish_check_num",
"plan_type" = EXCLUDED."plan_type",
"check_date" = EXCLUDED."check_date"
</select>
<select
id=
"getOldCompanyThreeSystemsStatisticsList"
resultType=
"com.yeejoin.amos.boot.module.tcm.api.dto.ThreeSystemsDto"
>
SELECT
*
FROM
tzs_three_systems
WHERE
plan_type = #{type}
AND check_date = #{lastStart}
</select>
</mapper>
</mapper>
amos-boot-system-tzs/amos-boot-module-tcm/amos-boot-module-tcm-biz/src/main/java/com/yeejoin/amos/boot/module/tcm/biz/controller/ThreeSystemsController.java
View file @
2358b46b
...
@@ -49,4 +49,13 @@ public class ThreeSystemsController<string> extends BaseController {
...
@@ -49,4 +49,13 @@ public class ThreeSystemsController<string> extends BaseController {
return
ResponseHelper
.
buildResponse
(
threeSystemsPage
);
return
ResponseHelper
.
buildResponse
(
threeSystemsPage
);
}
}
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
,
needAuth
=
false
)
@GetMapping
(
value
=
"/getThreeSystemsStatistics"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"生成三项制度统计"
,
notes
=
"生成三项制度统计"
)
public
ResponseModel
<
Object
>
getThreeSystemsStatistics
(
@RequestParam
(
value
=
"type"
)
String
type
)
{
iThreeSystemsService
.
getThreeSystemsStatistics
(
type
);
return
ResponseHelper
.
buildResponse
(
"ok"
);
}
}
}
amos-boot-system-tzs/amos-boot-module-tcm/amos-boot-module-tcm-biz/src/main/java/com/yeejoin/amos/boot/module/tcm/biz/controller/TzsTwoStaffingController.java
View file @
2358b46b
...
@@ -130,12 +130,4 @@ public class TzsTwoStaffingController extends BaseController {
...
@@ -130,12 +130,4 @@ public class TzsTwoStaffingController extends BaseController {
return
ResponseHelper
.
buildResponse
(
tzsTwoStaffingService
.
getCompanyCheckList
(
orgCode
,
companyDto
,
page
));
return
ResponseHelper
.
buildResponse
(
tzsTwoStaffingService
.
getCompanyCheckList
(
orgCode
,
companyDto
,
page
));
}
}
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
,
needAuth
=
false
)
@GetMapping
(
value
=
"/getThreeSystemsStatistics"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"生成三项制度统计"
,
notes
=
"生成三项制度统计"
)
public
ResponseModel
<
Object
>
getThreeSystemsStatistics
()
{
tzsTwoStaffingService
.
getThreeSystemsStatistics
();
return
ResponseHelper
.
buildResponse
(
"ok"
);
}
}
}
amos-boot-system-tzs/amos-boot-module-tcm/amos-boot-module-tcm-biz/src/main/java/com/yeejoin/amos/boot/module/tcm/biz/service/impl/ThreeSystemsServiceImpl.java
View file @
2358b46b
This diff is collapsed.
Click to expand it.
amos-boot-system-tzs/amos-boot-module-tcm/amos-boot-module-tcm-biz/src/main/java/com/yeejoin/amos/boot/module/tcm/biz/service/impl/TzsTwoStaffingServiceImpl.java
View file @
2358b46b
...
@@ -5,6 +5,7 @@ import com.google.common.collect.Lists;
...
@@ -5,6 +5,7 @@ import com.google.common.collect.Lists;
import
com.yeejoin.amos.boot.biz.common.utils.DateUtils
;
import
com.yeejoin.amos.boot.biz.common.utils.DateUtils
;
import
com.yeejoin.amos.boot.biz.common.utils.RedisUtils
;
import
com.yeejoin.amos.boot.biz.common.utils.RedisUtils
;
import
com.yeejoin.amos.boot.module.tcm.api.common.BizCommonConstant
;
import
com.yeejoin.amos.boot.module.tcm.api.common.BizCommonConstant
;
import
com.yeejoin.amos.boot.module.tcm.api.dto.ThreeSystemsDto
;
import
com.yeejoin.amos.boot.module.tcm.api.dto.TzsTwoStaffingCompanyCheckDto
;
import
com.yeejoin.amos.boot.module.tcm.api.dto.TzsTwoStaffingCompanyCheckDto
;
import
com.yeejoin.amos.boot.module.tcm.api.dto.TzsTwoStaffingCompanyDto
;
import
com.yeejoin.amos.boot.module.tcm.api.dto.TzsTwoStaffingCompanyDto
;
import
com.yeejoin.amos.boot.module.tcm.api.dto.TzsTwoStaffingDto
;
import
com.yeejoin.amos.boot.module.tcm.api.dto.TzsTwoStaffingDto
;
...
@@ -27,10 +28,7 @@ import java.math.BigDecimal;
...
@@ -27,10 +28,7 @@ import java.math.BigDecimal;
import
java.math.RoundingMode
;
import
java.math.RoundingMode
;
import
java.text.DecimalFormat
;
import
java.text.DecimalFormat
;
import
java.text.SimpleDateFormat
;
import
java.text.SimpleDateFormat
;
import
java.util.ArrayList
;
import
java.util.*
;
import
java.util.Date
;
import
java.util.LinkedHashMap
;
import
java.util.List
;
import
java.util.stream.Collectors
;
import
java.util.stream.Collectors
;
/**
/**
...
@@ -160,12 +158,8 @@ public class TzsTwoStaffingServiceImpl extends BaseService<TzsTwoStaffingDto, Tz
...
@@ -160,12 +158,8 @@ public class TzsTwoStaffingServiceImpl extends BaseService<TzsTwoStaffingDto, Tz
return
tzsTwoStaffingMapper
.
getCompanyCheckList
(
page
,
orgCode
,
companyDto
);
return
tzsTwoStaffingMapper
.
getCompanyCheckList
(
page
,
orgCode
,
companyDto
);
}
}
@Override
public
void
getThreeSystemsStatistics
()
{
}
p
rivate
List
<
LinkedHashMap
<
String
,
Object
>>
getSupervisionList
()
{
p
ublic
List
<
LinkedHashMap
<
String
,
Object
>>
getSupervisionList
()
{
List
<
LinkedHashMap
<
String
,
Object
>>
supervisionList
=
List
<
LinkedHashMap
<
String
,
Object
>>
supervisionList
=
(
List
<
LinkedHashMap
<
String
,
Object
>>)
redisUtils
.
get
(
BizCommonConstant
.
REGULATOR_UNIT_LIST
);
(
List
<
LinkedHashMap
<
String
,
Object
>>)
redisUtils
.
get
(
BizCommonConstant
.
REGULATOR_UNIT_LIST
);
if
(
ValidationUtil
.
isEmpty
(
supervisionList
))
{
if
(
ValidationUtil
.
isEmpty
(
supervisionList
))
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment