Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
Y
yifu-mvp
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
fangxinjiang
yifu-mvp
Commits
97d37ac5
Commit
97d37ac5
authored
Aug 17, 2022
by
huyuchen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
划转和减项判断社保公积金状态修改
parent
325f1f86
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
69 additions
and
9 deletions
+69
-9
TStatisticsBonus.java
...fu/cloud/plus/v1/yifu/salary/entity/TStatisticsBonus.java
+2
-2
TStatisticsDeclarerController.java
...yifu/salary/controller/TStatisticsDeclarerController.java
+15
-0
TStatisticsLaborController.java
...v1/yifu/salary/controller/TStatisticsLaborController.java
+1
-1
TStatisticsRemunerationController.java
.../salary/controller/TStatisticsRemunerationController.java
+1
-1
TStatisticsDeclarerMapper.java
...plus/v1/yifu/salary/mapper/TStatisticsDeclarerMapper.java
+9
-0
TStatisticsDeclarerService.java
...us/v1/yifu/salary/service/TStatisticsDeclarerService.java
+7
-0
TStatisticsBonusServiceImpl.java
...yifu/salary/service/impl/TStatisticsBonusServiceImpl.java
+0
-1
TStatisticsDeclarerServiceImpl.java
...u/salary/service/impl/TStatisticsDeclarerServiceImpl.java
+23
-4
TStatisticsDeclarerMapper.xml
...z/src/main/resources/mapper/TStatisticsDeclarerMapper.xml
+11
-0
No files found.
yifu-salary/yifu-salary-api/src/main/java/com/yifu/cloud/plus/v1/yifu/salary/entity/TStatisticsBonus.java
View file @
97d37ac5
...
@@ -39,9 +39,9 @@ import java.math.BigDecimal;
...
@@ -39,9 +39,9 @@ import java.math.BigDecimal;
*/
*/
@Data
@Data
@TableName
(
"t_statistics_bonus"
)
@TableName
(
"t_statistics_bonus"
)
@EqualsAndHashCode
(
callSuper
=
true
)
@EqualsAndHashCode
()
@Schema
(
description
=
"全年一次性奖金申报表"
)
@Schema
(
description
=
"全年一次性奖金申报表"
)
public
class
TStatisticsBonus
extends
BaseEntity
{
public
class
TStatisticsBonus
{
/**
/**
* ID
* ID
...
...
yifu-salary/yifu-salary-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/salary/controller/TStatisticsDeclarerController.java
View file @
97d37ac5
...
@@ -22,6 +22,7 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
...
@@ -22,6 +22,7 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.ErrorMessage
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.ErrorMessage
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.R
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.R
;
import
com.yifu.cloud.plus.v1.yifu.common.log.annotation.SysLog
;
import
com.yifu.cloud.plus.v1.yifu.common.log.annotation.SysLog
;
import
com.yifu.cloud.plus.v1.yifu.common.security.annotation.Inner
;
import
com.yifu.cloud.plus.v1.yifu.salary.entity.TStatisticsDeclarer
;
import
com.yifu.cloud.plus.v1.yifu.salary.entity.TStatisticsDeclarer
;
import
com.yifu.cloud.plus.v1.yifu.salary.service.TStatisticsDeclarerService
;
import
com.yifu.cloud.plus.v1.yifu.salary.service.TStatisticsDeclarerService
;
import
com.yifu.cloud.plus.v1.yifu.salary.vo.TStatisticsDeclarerSearchVo
;
import
com.yifu.cloud.plus.v1.yifu.salary.vo.TStatisticsDeclarerSearchVo
;
...
@@ -140,6 +141,20 @@ public class TStatisticsDeclarerController {
...
@@ -140,6 +141,20 @@ public class TStatisticsDeclarerController {
return
tStatisticsDeclarerService
.
importDiy
(
file
.
getInputStream
());
return
tStatisticsDeclarerService
.
importDiy
(
file
.
getInputStream
());
}
}
/**
* @param
* @Description: 生成申报人员
* @Author: huyc
* @Date: 2022-08-17 18:17:48
* @return: com.yifu.cloud.v1.common.core.util.R
**/
@Inner
@Operation
(
description
=
"生成申报人员"
)
@PostMapping
(
"/inner/doStatisticsTaxDeclarer"
)
public
R
doStatisticsTaxDeclarer
()
{
return
tStatisticsDeclarerService
.
doStatisticsTaxDeclarer
();
}
/**
/**
* 申报对象表 批量导出
* 申报对象表 批量导出
* @author huyc
* @author huyc
...
...
yifu-salary/yifu-salary-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/salary/controller/TStatisticsLaborController.java
View file @
97d37ac5
...
@@ -110,7 +110,7 @@ public class TStatisticsLaborController {
...
@@ -110,7 +110,7 @@ public class TStatisticsLaborController {
@SysLog
(
"批量删除本期稿酬申报表"
)
@SysLog
(
"批量删除本期稿酬申报表"
)
@PostMapping
(
"/batchDelete"
)
@PostMapping
(
"/batchDelete"
)
@PreAuthorize
(
"@pms.hasPermission('salary_tstatisticslabor_del')"
)
@PreAuthorize
(
"@pms.hasPermission('salary_tstatisticslabor_del')"
)
public
R
batchDelete
(
@Request
Body
String
declareMonth
){
public
R
batchDelete
(
@Request
Param
String
declareMonth
){
return
tStatisticsLaborService
.
batchDelete
(
declareMonth
);
return
tStatisticsLaborService
.
batchDelete
(
declareMonth
);
}
}
}
}
yifu-salary/yifu-salary-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/salary/controller/TStatisticsRemunerationController.java
View file @
97d37ac5
...
@@ -109,7 +109,7 @@ public class TStatisticsRemunerationController {
...
@@ -109,7 +109,7 @@ public class TStatisticsRemunerationController {
@SysLog
(
"批量删除本期稿酬申报表"
)
@SysLog
(
"批量删除本期稿酬申报表"
)
@PostMapping
(
"/batchDelete"
)
@PostMapping
(
"/batchDelete"
)
@PreAuthorize
(
"@pms.hasPermission('salary_tstatisticsbonus_del')"
)
@PreAuthorize
(
"@pms.hasPermission('salary_tstatisticsbonus_del')"
)
public
R
batchDelete
(
@Request
Body
String
declareMonth
){
public
R
batchDelete
(
@Request
Param
String
declareMonth
){
return
tStatisticsRemunerationService
.
batchDelete
(
declareMonth
);
return
tStatisticsRemunerationService
.
batchDelete
(
declareMonth
);
}
}
}
}
yifu-salary/yifu-salary-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/salary/mapper/TStatisticsDeclarerMapper.java
View file @
97d37ac5
...
@@ -24,6 +24,8 @@ import com.yifu.cloud.plus.v1.yifu.salary.entity.TStatisticsDeclarer;
...
@@ -24,6 +24,8 @@ import com.yifu.cloud.plus.v1.yifu.salary.entity.TStatisticsDeclarer;
import
org.apache.ibatis.annotations.Mapper
;
import
org.apache.ibatis.annotations.Mapper
;
import
org.apache.ibatis.annotations.Param
;
import
org.apache.ibatis.annotations.Param
;
import
java.util.List
;
/**
/**
* 申报对象表
* 申报对象表
*
*
...
@@ -38,4 +40,11 @@ public interface TStatisticsDeclarerMapper extends BaseMapper<TStatisticsDeclare
...
@@ -38,4 +40,11 @@ public interface TStatisticsDeclarerMapper extends BaseMapper<TStatisticsDeclare
* @return
* @return
*/
*/
IPage
<
TStatisticsDeclarer
>
getTStatisticsDeclarerPage
(
Page
<
TStatisticsDeclarer
>
page
,
@Param
(
"tStatisticsDeclarer"
)
TStatisticsDeclarer
tStatisticsDeclarer
);
IPage
<
TStatisticsDeclarer
>
getTStatisticsDeclarerPage
(
Page
<
TStatisticsDeclarer
>
page
,
@Param
(
"tStatisticsDeclarer"
)
TStatisticsDeclarer
tStatisticsDeclarer
);
/**
* @param
* @Description: 统计
* @return:
**/
List
<
TStatisticsDeclarer
>
doStatisticsTaxDeclarer
(
@Param
(
"nowMonth"
)
String
nowMonth
,
@Param
(
"lastYear"
)
String
lastYear
);
}
}
yifu-salary/yifu-salary-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/salary/service/TStatisticsDeclarerService.java
View file @
97d37ac5
...
@@ -58,4 +58,11 @@ public interface TStatisticsDeclarerService extends IService<TStatisticsDeclarer
...
@@ -58,4 +58,11 @@ public interface TStatisticsDeclarerService extends IService<TStatisticsDeclarer
* @return
* @return
*/
*/
R
updateFlagById
(
String
id
,
String
isDeclare
,
String
undeclareReason
);
R
updateFlagById
(
String
id
,
String
isDeclare
,
String
undeclareReason
);
/**
* @param
* @Description: 生成申报人员
* @return
**/
R
doStatisticsTaxDeclarer
();
}
}
yifu-salary/yifu-salary-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/salary/service/impl/TStatisticsBonusServiceImpl.java
View file @
97d37ac5
...
@@ -152,7 +152,6 @@ public class TStatisticsBonusServiceImpl extends ServiceImpl<TStatisticsBonusMap
...
@@ -152,7 +152,6 @@ public class TStatisticsBonusServiceImpl extends ServiceImpl<TStatisticsBonusMap
if
(
searchVo
.
getLimitStart
()
>=
0
&&
searchVo
.
getLimitEnd
()
>
0
){
if
(
searchVo
.
getLimitStart
()
>=
0
&&
searchVo
.
getLimitEnd
()
>
0
){
wrapper
.
last
(
" limit "
+
searchVo
.
getLimitStart
()
+
","
+
searchVo
.
getLimitEnd
());
wrapper
.
last
(
" limit "
+
searchVo
.
getLimitStart
()
+
","
+
searchVo
.
getLimitEnd
());
}
}
wrapper
.
orderByDesc
(
BaseEntity:
:
getCreateTime
);
return
baseMapper
.
selectList
(
wrapper
);
return
baseMapper
.
selectList
(
wrapper
);
}
}
...
...
yifu-salary/yifu-salary-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/salary/service/impl/TStatisticsDeclarerServiceImpl.java
View file @
97d37ac5
...
@@ -16,14 +16,13 @@
...
@@ -16,14 +16,13 @@
*/
*/
package
com
.
yifu
.
cloud
.
plus
.
v1
.
yifu
.
salary
.
service
.
impl
;
package
com
.
yifu
.
cloud
.
plus
.
v1
.
yifu
.
salary
.
service
.
impl
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
com.yifu.cloud.plus.v1.yifu.archives.entity.TEmployeeProject
;
import
com.yifu.cloud.plus.v1.yifu.salary.entity.TStatisticsDeclarer
;
import
com.yifu.cloud.plus.v1.yifu.salary.entity.TStatisticsDeclarer
;
import
com.yifu.cloud.plus.v1.yifu.salary.vo.TStatisticsDeclarerVo
;
import
com.yifu.cloud.plus.v1.yifu.salary.vo.TStatisticsDeclarerVo
;
import
com.yifu.cloud.plus.v1.yifu.salary.mapper.TStatisticsDeclarerMapper
;
import
com.yifu.cloud.plus.v1.yifu.salary.mapper.TStatisticsDeclarerMapper
;
import
com.yifu.cloud.plus.v1.yifu.salary.service.TStatisticsDeclarerService
;
import
com.yifu.cloud.plus.v1.yifu.salary.service.TStatisticsDeclarerService
;
import
lombok.extern.log4j.Log4j2
;
import
lombok.extern.log4j.Log4j2
;
import
org.checkerframework.checker.units.qual.C
;
import
org.springframework.stereotype.Service
;
import
org.springframework.stereotype.Service
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.ErrorMessage
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.ErrorMessage
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.R
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.R
;
...
@@ -31,7 +30,6 @@ import com.yifu.cloud.plus.v1.yifu.salary.vo.TStatisticsDeclarerSearchVo;
...
@@ -31,7 +30,6 @@ import com.yifu.cloud.plus.v1.yifu.salary.vo.TStatisticsDeclarerSearchVo;
import
javax.servlet.http.HttpServletResponse
;
import
javax.servlet.http.HttpServletResponse
;
import
java.io.InputStream
;
import
java.io.InputStream
;
import
java.util.List
;
import
java.util.List
;
import
cn.hutool.core.bean.BeanUtil
;
import
com.alibaba.excel.EasyExcel
;
import
com.alibaba.excel.EasyExcel
;
import
com.alibaba.excel.ExcelWriter
;
import
com.alibaba.excel.ExcelWriter
;
import
com.alibaba.excel.context.AnalysisContext
;
import
com.alibaba.excel.context.AnalysisContext
;
...
@@ -90,7 +88,7 @@ public class TStatisticsDeclarerServiceImpl extends ServiceImpl<TStatisticsDecla
...
@@ -90,7 +88,7 @@ public class TStatisticsDeclarerServiceImpl extends ServiceImpl<TStatisticsDecla
response
.
setCharacterEncoding
(
"utf-8"
);
response
.
setCharacterEncoding
(
"utf-8"
);
response
.
setHeader
(
"Content-Disposition"
,
"attachment;filename="
+
URLEncoder
.
encode
(
fileName
,
"UTF-8"
));
response
.
setHeader
(
"Content-Disposition"
,
"attachment;filename="
+
URLEncoder
.
encode
(
fileName
,
"UTF-8"
));
// 这里 需要指定写用哪个class去写,然后写到第一个sheet,然后文件流会自动关闭
// 这里 需要指定写用哪个class去写,然后写到第一个sheet,然后文件流会自动关闭
ExcelWriter
excelWriter
=
EasyExcel
.
write
(
out
,
TStatisticsDeclarer
.
class
).
build
();
ExcelWriter
excelWriter
=
EasyExcel
.
write
(
out
,
TStatisticsDeclarer
.
class
).
build
();
int
index
=
0
;
int
index
=
0
;
if
(
count
>
CommonConstants
.
ZERO_INT
){
if
(
count
>
CommonConstants
.
ZERO_INT
){
for
(
int
i
=
0
;
i
<=
count
;
)
{
for
(
int
i
=
0
;
i
<=
count
;
)
{
...
@@ -164,6 +162,27 @@ public class TStatisticsDeclarerServiceImpl extends ServiceImpl<TStatisticsDecla
...
@@ -164,6 +162,27 @@ public class TStatisticsDeclarerServiceImpl extends ServiceImpl<TStatisticsDecla
return
R
.
failed
(
CommonConstants
.
PARAM_IS_NOT_ERROR
);
return
R
.
failed
(
CommonConstants
.
PARAM_IS_NOT_ERROR
);
}
}
@Override
public
R
doStatisticsTaxDeclarer
()
{
String
nowMonth
=
DateUtil
.
addMonth
(
0
);
//本月
TStatisticsDeclarer
std
=
new
TStatisticsDeclarer
();
std
.
setDeclareMonth
(
nowMonth
);
QueryWrapper
<
TStatisticsDeclarer
>
queryWrapperSs
=
new
QueryWrapper
<>();
queryWrapperSs
.
setEntity
(
std
);
long
num
=
this
.
count
(
queryWrapperSs
);
if
(
num
>
0
)
{
return
R
.
failed
(
"上月数据已生成,不可重复生成!"
);
}
else
{
String
lastMonth
=
DateUtil
.
addMonth
(-
1
);
//上月
String
lastYear
=
lastMonth
.
substring
(
0
,
4
);
List
<
TStatisticsDeclarer
>
stdvoList
=
baseMapper
.
doStatisticsTaxDeclarer
(
nowMonth
,
lastYear
);
for
(
TStatisticsDeclarer
declarer
:
stdvoList
)
{
this
.
save
(
declarer
);
}
return
R
.
ok
();
}
}
private
Long
noPageCountDiy
(
TStatisticsDeclarerSearchVo
searchVo
)
{
private
Long
noPageCountDiy
(
TStatisticsDeclarerSearchVo
searchVo
)
{
LambdaQueryWrapper
<
TStatisticsDeclarer
>
wrapper
=
buildQueryWrapper
(
searchVo
);
LambdaQueryWrapper
<
TStatisticsDeclarer
>
wrapper
=
buildQueryWrapper
(
searchVo
);
List
<
String
>
idList
=
Common
.
getList
(
searchVo
.
getIds
());
List
<
String
>
idList
=
Common
.
getList
(
searchVo
.
getIds
());
...
...
yifu-salary/yifu-salary-biz/src/main/resources/mapper/TStatisticsDeclarerMapper.xml
View file @
97d37ac5
...
@@ -97,4 +97,15 @@
...
@@ -97,4 +97,15 @@
</where>
</where>
order by a.DECLARE_MONTH desc
order by a.DECLARE_MONTH desc
</select>
</select>
<!--统计-->
<select
id=
"doStatisticsTaxDeclarer"
resultMap=
"tStatisticsDeclarerMap"
>
select
#{nowMonth} DECLARE_MONTH,a.EMP_NAME,a.EMP_IDCARD,a.EMP_PHONE,b.FILE_STATUS EMP_STATUS,
b.UNIT_NAME DECLARE_UNIT,'雇员' OCCUPATION_TYPE
from t_salary_account a
left join t_salary_employee b on b.id = a.EMP_ID
where a.DELETE_FLAG = 0 and a.SETTLEMENT_MONTH like '${lastYear}%'
GROUP BY a.EMP_IDCARD
</select>
</mapper>
</mapper>
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