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
ac2b3dc3
Commit
ac2b3dc3
authored
Sep 22, 2022
by
fangxinjiang
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/develop' into develop
parents
353f4bfb
af112b7d
Hide whitespace changes
Inline
Side-by-side
Showing
17 changed files
with
190 additions
and
71 deletions
+190
-71
TCertRecordController.java
...us/v1/yifu/archives/controller/TCertRecordController.java
+12
-14
TEmpContractAlertController.java
...yifu/archives/controller/TEmpContractAlertController.java
+15
-8
TEmployeeContractInfoMapper.xml
...src/main/resources/mapper/TEmployeeContractInfoMapper.xml
+0
-6
CommonConstants.java
...ud.plus.v1/yifu/common/core/constant/CommonConstants.java
+1
-0
InsuredOrderParam.java
...u/cloud/plus/v1/yifu/insurances/vo/InsuredOrderParam.java
+2
-3
TInsuranceDetailServiceImpl.java
...s/service/insurance/impl/TInsuranceDetailServiceImpl.java
+23
-10
TInsuranceDetailMapper.xml
...in/resources/mapper/insurances/TInsuranceDetailMapper.xml
+10
-3
TOrderMapper.java
...om/yifu/cloud/plus/v1/yifu/order/mapper/TOrderMapper.java
+1
-2
TOrderServiceImpl.java
...ud/plus/v1/yifu/order/service/impl/TOrderServiceImpl.java
+19
-1
TOrderMapper.xml
...yifu-order-biz/src/main/resources/mapper/TOrderMapper.xml
+1
-1
TSalaryAccountController.java
...s/v1/yifu/salary/controller/TSalaryAccountController.java
+37
-0
TSalaryEmployeeController.java
.../v1/yifu/salary/controller/TSalaryEmployeeController.java
+3
-0
TConfigSalaryMapper.xml
...ary-biz/src/main/resources/mapper/TConfigSalaryMapper.xml
+1
-1
TSalaryEmployeeMapper.xml
...y-biz/src/main/resources/mapper/TSalaryEmployeeMapper.xml
+3
-0
TSalaryStandardMapper.xml
...y-biz/src/main/resources/mapper/TSalaryStandardMapper.xml
+3
-0
TDispatchInfoController.java
...us/v1/yifu/social/controller/TDispatchInfoController.java
+44
-0
TPaymentInfoServiceImpl.java
.../v1/yifu/social/service/impl/TPaymentInfoServiceImpl.java
+15
-22
No files found.
yifu-archives/yifu-archives-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/archives/controller/TCertRecordController.java
View file @
ac2b3dc3
...
...
@@ -66,17 +66,22 @@ public class TCertRecordController {
@GetMapping
(
"/page"
)
//@PreAuthorize("@pms.hasPermission('demo_tcertrecord_get')" )
public
R
<
IPage
<
TCertRecord
>>
getTCertRecordPage
(
Page
page
,
CertRecordSearchVo
searchVo
)
{
setAuth
(
searchVo
);
return
R
.
ok
(
tCertRecordService
.
pageDiy
(
page
,
searchVo
));
}
private
void
setAuth
(
CertRecordSearchVo
searchVo
)
{
YifuUser
user
=
SecurityUtils
.
getUser
();
if
(
user
==
null
||
Common
.
isEmpty
(
user
.
getId
()))
{
return
R
.
failed
(
CommonConstants
.
PLEASE_LOG_IN
);
}
menuUtil
.
setAuthSql
(
user
,
searchVo
);
if
(
Common
.
isNotNull
(
searchVo
.
getAuthSql
())
&&
searchVo
.
getAuthSql
().
contains
(
CommonConstants
.
A_DEPT_ID
))
{
searchVo
.
setAuthSql
(
searchVo
.
getAuthSql
().
replace
(
CommonConstants
.
A_DEPT_ID
,
"dept_id"
));
}
return
R
.
ok
(
tCertRecordService
.
pageDiy
(
page
,
searchVo
));
}
/**
if
(
searchVo
.
getAuthSql
().
contains
(
CommonConstants
.
A_CREATE_BY
))
{
searchVo
.
setAuthSql
(
searchVo
.
getAuthSql
().
replace
(
CommonConstants
.
A_CREATE_BY
,
"CREATE_BY"
));
}
}
/**
* 不分页查询
* @param searchVo 证明开具记录表
* @return
...
...
@@ -85,14 +90,7 @@ public class TCertRecordController {
@GetMapping
(
"/noPage"
)
//@PreAuthorize("@pms.hasPermission('demo_tcertrecord_get')" )
public
R
<
List
<
TCertRecord
>>
getTCertRecordNoPage
(
CertRecordSearchVo
searchVo
)
{
YifuUser
user
=
SecurityUtils
.
getUser
();
if
(
user
==
null
||
Common
.
isEmpty
(
user
.
getId
()))
{
return
R
.
failed
(
CommonConstants
.
PLEASE_LOG_IN
);
}
menuUtil
.
setAuthSql
(
user
,
searchVo
);
if
(
Common
.
isNotNull
(
searchVo
.
getAuthSql
())
&&
searchVo
.
getAuthSql
().
contains
(
CommonConstants
.
A_DEPT_ID
))
{
searchVo
.
setAuthSql
(
searchVo
.
getAuthSql
().
replace
(
CommonConstants
.
A_DEPT_ID
,
"dept_id"
));
}
setAuth
(
searchVo
);
return
R
.
ok
(
tCertRecordService
.
getTCertRecordNoPage
(
searchVo
));
}
...
...
yifu-archives/yifu-archives-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/archives/controller/TEmpContractAlertController.java
View file @
ac2b3dc3
...
...
@@ -65,11 +65,7 @@ public class TEmpContractAlertController {
@GetMapping
(
"/page"
)
//@PreAuthorize("@pms.hasPermission('demo_tempcontractalert_get')" )
public
R
<
IPage
<
TEmpContractAlert
>>
getTEmpContractAlertPage
(
Page
page
,
ContractAlertSearchVo
searchVo
)
{
YifuUser
user
=
SecurityUtils
.
getUser
();
menuUtil
.
setAuthSql
(
user
,
searchVo
);
if
(
Common
.
isNotNull
(
searchVo
.
getAuthSql
())
&&
searchVo
.
getAuthSql
().
contains
(
CommonConstants
.
A_DEPT_ID
))
{
searchVo
.
setAuthSql
(
searchVo
.
getAuthSql
().
replace
(
CommonConstants
.
A_DEPT_ID
,
"dept_id"
));
}
setAuth
(
searchVo
);
return
R
.
ok
(
tEmpContractAlertService
.
pageDiy
(
page
,
searchVo
));
}
/**
...
...
@@ -81,6 +77,7 @@ public class TEmpContractAlertController {
@PostMapping
(
"/noPage"
)
//@PreAuthorize("@pms.hasPermission('demo_tempcontractalert_get')" )
public
R
<
List
<
TEmpContractAlert
>>
getTEmpContractAlertNoPage
(
@RequestBody
ContractAlertSearchVo
searchVo
)
{
setAuth
(
searchVo
);
return
R
.
ok
(
tEmpContractAlertService
.
listDiy
(
searchVo
));
}
...
...
@@ -145,13 +142,23 @@ public class TEmpContractAlertController {
@Operation
(
description
=
"导出"
)
@PostMapping
(
"/export"
)
public
void
export
(
HttpServletResponse
response
,
@RequestBody
ContractAlertSearchVo
searchVo
)
{
setAuth
(
searchVo
);
tEmpContractAlertService
.
listExport
(
response
,
searchVo
);
}
private
void
setAuth
(
ContractAlertSearchVo
searchVo
)
{
YifuUser
user
=
SecurityUtils
.
getUser
();
menuUtil
.
setAuthSql
(
user
,
searchVo
);
if
(
Common
.
isNotNull
(
searchVo
.
getAuthSql
())
&&
searchVo
.
getAuthSql
().
contains
(
CommonConstants
.
A_DEPT_ID
))
{
searchVo
.
setAuthSql
(
searchVo
.
getAuthSql
().
replace
(
CommonConstants
.
A_DEPT_ID
,
"dept_id"
));
if
(
Common
.
isNotNull
(
searchVo
.
getAuthSql
()))
{
if
(
searchVo
.
getAuthSql
().
contains
(
CommonConstants
.
A_DEPT_ID
))
{
searchVo
.
setAuthSql
(
searchVo
.
getAuthSql
().
replace
(
CommonConstants
.
A_DEPT_ID
,
"dept_id"
));
}
if
(
searchVo
.
getAuthSql
().
contains
(
CommonConstants
.
A_CREATE_BY
))
{
searchVo
.
setAuthSql
(
searchVo
.
getAuthSql
().
replace
(
CommonConstants
.
A_CREATE_BY
,
"CREATE_BY"
));
}
}
tEmpContractAlertService
.
listExport
(
response
,
searchVo
);
}
/**
* 定时任务生成合同续签代码信息
* @return R<List>
...
...
yifu-archives/yifu-archives-biz/src/main/resources/mapper/TEmployeeContractInfoMapper.xml
View file @
ac2b3dc3
...
...
@@ -394,9 +394,6 @@
SELECT
<include
refid=
"Base_Column_List"
/>
FROM t_employee_contract_info a
<if
test=
"tEmployeeContractInfo.authSql != null and tEmployeeContractInfo.authSql.trim() != ''"
>
left join t_employee_contract_area_res p on a.CREATE_BY=p.USER_ID
</if>
<where>
a.DELETE_FLAG = 0
<include
refid=
"tEmployeeContractInfo_where"
/>
...
...
@@ -425,9 +422,6 @@
SELECT
<include
refid=
"Base_Export_Column_List"
/>
FROM t_employee_contract_info a
<if
test=
"tEmployeeContractInfo.authSql != null and tEmployeeContractInfo.authSql.trim() != ''"
>
left join t_employee_contract_area_res p on a.CREATE_BY=p.USER_ID
</if>
<where>
a.DELETE_FLAG = 0
<include
refid=
"tEmployeeContractInfo_where"
/>
...
...
yifu-common/yifu-common-core/src/main/java/com/yifu.cloud.plus.v1/yifu/common/core/constant/CommonConstants.java
View file @
ac2b3dc3
...
...
@@ -494,4 +494,5 @@ public interface CommonConstants {
public
static
final
String
ERROR_IMPORT
=
"执行异常"
;
// 权限使用的
public
static
final
String
A_DEPT_ID
=
"a.dept_id"
;
public
static
final
String
A_CREATE_BY
=
"a.CREATE_BY"
;
}
yifu-insurances/yifu-insurances-api/src/main/java/com/yifu/cloud/plus/v1/yifu/insurances/vo/InsuredOrderParam.java
View file @
ac2b3dc3
package
com
.
yifu
.
cloud
.
plus
.
v1
.
yifu
.
insurances
.
vo
;
import
com.
fasterxml.jackson.annotation.JsonFormat
;
import
com.
yifu.cloud.plus.v1.yifu.common.mybatis.base.BaseEntity
;
import
io.swagger.v3.oas.annotations.media.Schema
;
import
io.swagger.v3.oas.annotations.tags.Tag
;
import
lombok.Data
;
import
java.io.Serializable
;
import
java.time.LocalDate
;
import
java.util.List
;
...
...
@@ -16,7 +15,7 @@ import java.util.List;
*/
@Data
@Tag
(
name
=
"订单商险列表查询"
)
public
class
InsuredOrderParam
implements
Serializable
{
public
class
InsuredOrderParam
extends
BaseEntity
{
/**
* 订单编号
*/
...
...
yifu-insurances/yifu-insurances-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/insurances/service/insurance/impl/TInsuranceDetailServiceImpl.java
View file @
ac2b3dc3
...
...
@@ -15,12 +15,11 @@ import com.yifu.cloud.plus.v1.yifu.archives.vo.TSettleDomainListVo;
import
com.yifu.cloud.plus.v1.yifu.archives.vo.TSettleDomainSelectVo
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.CacheConstants
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.SecurityConstants
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.*
;
import
com.yifu.cloud.plus.v1.yifu.common.core.vo.YifuUser
;
import
com.yifu.cloud.plus.v1.yifu.common.dapr.util.ArchivesDaprUtil
;
import
com.yifu.cloud.plus.v1.yifu.common.dapr.util.CheckDaprUtil
;
import
com.yifu.cloud.plus.v1.yifu.common.dapr.util.MenuUtil
;
import
com.yifu.cloud.plus.v1.yifu.common.dapr.util.SocialDaprUtils
;
import
com.yifu.cloud.plus.v1.yifu.common.dapr.config.DaprArchivesProperties
;
import
com.yifu.cloud.plus.v1.yifu.common.dapr.util.*
;
import
com.yifu.cloud.plus.v1.yifu.common.security.util.SecurityUtils
;
import
com.yifu.cloud.plus.v1.yifu.ekp.constant.EkpConstants
;
import
com.yifu.cloud.plus.v1.yifu.ekp.util.EkpInsuranceUtil
;
...
...
@@ -104,6 +103,8 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
@Resource
private
MenuUtil
menuUtil
;
@Resource
private
DaprArchivesProperties
daprArchivesProperties
;
/***********************商险办理********************************/
/**
...
...
@@ -5863,16 +5864,28 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
@Override
public
R
getOrderInsuredListPage
(
Page
<
InsuredOrderListVo
>
page
,
InsuredOrderParam
param
)
{
YifuUser
user
=
SecurityUtils
.
getUser
();
List
<
String
>
deptNoList
=
getDeptNoList
(
user
);
Page
<
InsuredOrderListVo
>
pageList
=
new
Page
<>();
if
(
CollectionUtils
.
isEmpty
(
deptNoList
)){
return
R
.
ok
(
pageList
);
}
param
.
setDeptNoList
(
deptNoList
);
String
orderNo
=
param
.
getOrderNo
();
if
(
StringUtils
.
isBlank
(
orderNo
))
{
return
R
.
failed
(
InsurancesConstants
.
ORDER_NO_IS_EMPTY
);
}
String
sql
;
// 获取人员项目权限
R
<
TSettleDomainListVo
>
res
=
HttpDaprUtil
.
invokeMethodPost
(
daprArchivesProperties
.
getAppUrl
()
,
daprArchivesProperties
.
getAppId
(),
"/tsettledomain/getSettleDomainIdsByUserId"
,
user
.
getId
(),
TSettleDomainListVo
.
class
,
SecurityConstants
.
FROM_IN
);
StringBuilder
deptStr
=
new
StringBuilder
();
if
(
res
!=
null
&&
CommonConstants
.
SUCCESS
==
res
.
getCode
()
&&
res
.
getData
()
!=
null
&&
res
.
getData
().
getDeptIds
()
!=
null
&&
!
res
.
getData
().
getDeptIds
().
isEmpty
())
{
for
(
String
deptId
:
res
.
getData
().
getDeptIds
())
{
deptStr
.
append
(
",'"
).
append
(
deptId
).
append
(
"'"
);
}
}
sql
=
"and (1=2 or a.dept_id in ('0'#settleDomainId))"
;
sql
=
sql
.
replace
(
"#settleDomainId"
,
deptStr
.
toString
());
param
.
setAuthSql
(
sql
);
//查询所有保单信息
IPage
<
InsuredOrderListVo
>
orderInsuredList
=
baseMapper
.
getOrderInsuredListPage
(
page
,
param
);
return
R
.
ok
(
orderInsuredList
);
...
...
yifu-insurances/yifu-insurances-biz/src/main/resources/mapper/insurances/TInsuranceDetailMapper.xml
View file @
ac2b3dc3
...
...
@@ -961,7 +961,7 @@
a.BUY_HANDLE_STATUS as buyHandleStatus,
a.REDUCE_HANDLE_STATUS as reduceHandleStatus
from
t_insurance_detail
detail
t_insurance_detail
a
where
a.DELETE_FLAG = 0
and
...
...
@@ -978,6 +978,9 @@
<if
test=
"param.endDate != null "
>
AND a.CREATE_TIME
<![CDATA[ <= ]]>
concat(#{param.endDate}, ' 23:59:59')
</if>
<if
test=
"param.authSql != null and param.authSql.trim() != ''"
>
${param.authSql}
</if>
<if
test=
"param.deptNoList != null"
>
and a.DEPT_NO in
<foreach
collection=
"param.deptNoList"
index=
"index"
item=
"item"
open=
"("
separator=
","
close=
")"
>
...
...
@@ -1003,7 +1006,7 @@
a.BUY_HANDLE_STATUS as buyHandleStatus,
refund.REDUCE_HANDLE_STATUS as reduceHandleStatus
from
t_insurance_detail
detail
,
t_insurance_detail
a
,
t_insurance_refund refund
where
a.DELETE_FLAG = 0
...
...
@@ -1023,13 +1026,17 @@
<if
test=
"param.endDate != null "
>
AND refund.CREATE_TIME
<![CDATA[ <= ]]>
concat(#{param.endDate}, ' 23:59:59')
</if>
<if
test=
"param.authSql != null and param.authSql.trim() != ''"
>
${param.authSql}
</if>
<if
test=
"param.deptNoList != null"
>
and a.DEPT_NO in
<foreach
collection=
"param.deptNoList"
index=
"index"
item=
"item"
open=
"("
separator=
","
close=
")"
>
#{item}
</foreach>
</if>
)order by createTime desc
)
order by createTime desc
</select>
</mapper>
yifu-order/yifu-order-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/order/mapper/TOrderMapper.java
View file @
ac2b3dc3
...
...
@@ -28,10 +28,9 @@ public interface TOrderMapper extends BaseMapper<TOrder> {
* @author licancan
* @param page
* @param param
* @param userName
* @return {@link IPage<OrderListVO>}
*/
IPage
<
OrderListVO
>
getOrderPageList
(
Page
<
OrderListParam
>
page
,
@Param
(
"param"
)
OrderListParam
param
,
@Param
(
"userName"
)
String
userName
);
IPage
<
OrderListVO
>
getOrderPageList
(
Page
<
OrderListParam
>
page
,
@Param
(
"param"
)
OrderListParam
param
);
/**
* 导出勾选查询结果
...
...
yifu-order/yifu-order-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/order/service/impl/TOrderServiceImpl.java
View file @
ac2b3dc3
...
...
@@ -8,11 +8,14 @@ import com.yifu.cloud.plus.v1.yifu.archives.entity.TSettleDomain;
import
com.yifu.cloud.plus.v1.yifu.archives.vo.TSettleDomainListVo
;
import
com.yifu.cloud.plus.v1.yifu.archives.vo.TSettleDomainSelectVo
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.SecurityConstants
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.Common
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.OSSUtil
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.R
;
import
com.yifu.cloud.plus.v1.yifu.common.core.vo.YifuUser
;
import
com.yifu.cloud.plus.v1.yifu.common.dapr.config.DaprUpmsProperties
;
import
com.yifu.cloud.plus.v1.yifu.common.dapr.util.ArchivesDaprUtil
;
import
com.yifu.cloud.plus.v1.yifu.common.dapr.util.HttpDaprUtil
;
import
com.yifu.cloud.plus.v1.yifu.common.dapr.util.MenuUtil
;
import
com.yifu.cloud.plus.v1.yifu.common.security.util.SecurityUtils
;
import
com.yifu.cloud.plus.v1.yifu.ekp.util.EkpOrderUtil
;
...
...
@@ -68,6 +71,8 @@ public class TOrderServiceImpl extends ServiceImpl<TOrderMapper, TOrder> impleme
private
MenuUtil
menuUtil
;
@Resource
private
ArchivesDaprUtil
archivesDaprUtil
;
@Resource
private
DaprUpmsProperties
daprUpmsProperties
;
/**
* 订单列表分页查询
...
...
@@ -81,7 +86,20 @@ public class TOrderServiceImpl extends ServiceImpl<TOrderMapper, TOrder> impleme
public
IPage
<
OrderListVO
>
getOrderPageList
(
Page
<
OrderListParam
>
page
,
OrderListParam
param
)
{
YifuUser
user
=
SecurityUtils
.
getUser
();
menuUtil
.
setAuthSql
(
user
,
param
);
IPage
<
OrderListVO
>
orderList
=
baseMapper
.
getOrderPageList
(
page
,
param
,
user
.
getUsername
());
if
(
Common
.
isNotNull
(
param
.
getAuthSql
())
&&
param
.
getAuthSql
().
contains
(
"#create_name"
))
{
param
.
setAuthSql
(
param
.
getAuthSql
().
replace
(
"#create_name"
,
user
.
getUsername
()));
}
if
(
Common
.
isNotNull
(
param
.
getAuthSql
())
&&
param
.
getAuthSql
().
contains
(
"#create_depts"
))
{
String
userIds
=
"0"
;
R
<
String
>
userIdR
=
HttpDaprUtil
.
invokeMethodPost
(
daprUpmsProperties
.
getAppUrl
()
,
daprUpmsProperties
.
getAppId
(),
"/user/inner/getUserIdByDeptIds"
,
user
.
getDeptId
()
,
String
.
class
,
SecurityConstants
.
FROM_IN
);
if
(
userIdR
!=
null
&&
CommonConstants
.
SUCCESS
==
userIdR
.
getCode
())
{
userIds
=
userIdR
.
getData
();
}
param
.
setAuthSql
(
param
.
getAuthSql
().
replace
(
"#create_depts"
,
userIds
));
}
IPage
<
OrderListVO
>
orderList
=
baseMapper
.
getOrderPageList
(
page
,
param
);
return
orderList
;
}
...
...
yifu-order/yifu-order-biz/src/main/resources/mapper/TOrderMapper.xml
View file @
ac2b3dc3
...
...
@@ -38,8 +38,8 @@
a.DEPT_NO as deptNo,
a.ORDER_STATUS as orderStatus
from t_order a
left join t_order_handler h on h.ORDER_NO = a.ORDER_NO
where a.DELETE_FLAG = 0
and #{userName} in (SELECT HANDLE_USER FROM t_order_handler h WHERE h.ORDER_NO = a.ORDER_NO)
<if
test=
"param.orderNo != null and param.orderNo.trim() != ''"
>
and a.ORDER_NO = #{param.orderNo}
</if>
...
...
yifu-salary/yifu-salary-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/salary/controller/TSalaryAccountController.java
View file @
ac2b3dc3
...
...
@@ -20,10 +20,14 @@ package com.yifu.cloud.plus.v1.yifu.salary.controller;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.yifu.cloud.plus.v1.yifu.archives.vo.TSettleDomainListVo
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.SecurityConstants
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.Common
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.R
;
import
com.yifu.cloud.plus.v1.yifu.common.core.vo.YifuUser
;
import
com.yifu.cloud.plus.v1.yifu.common.dapr.config.DaprArchivesProperties
;
import
com.yifu.cloud.plus.v1.yifu.common.dapr.util.HttpDaprUtil
;
import
com.yifu.cloud.plus.v1.yifu.common.dapr.util.MenuUtil
;
import
com.yifu.cloud.plus.v1.yifu.common.log.annotation.SysLog
;
import
com.yifu.cloud.plus.v1.yifu.common.security.annotation.Inner
;
...
...
@@ -66,6 +70,8 @@ public class TSalaryAccountController {
private
final
MenuUtil
menuUtil
;
private
final
DaprArchivesProperties
daprArchivesProperties
;
/**
* 简单分页查询
*
...
...
@@ -82,6 +88,37 @@ public class TSalaryAccountController {
return
new
R
<>(
tSalaryAccountService
.
getTSalaryAccountPage
(
page
,
tSalaryAccount
));
}
/**
* 简单分页查询
*
* @param page 分页对象
* @param tSalaryAccount 工资报账主表(工资条)
* @return
*/
@Operation
(
description
=
"简单分页查询"
)
@GetMapping
(
"/pageOrder"
)
public
R
<
IPage
<
TSalaryAccount
>>
getTSalaryAccountPageOrder
(
Page
<
TSalaryAccount
>
page
,
TSalaryAccountSearchVo
tSalaryAccount
)
{
tSalaryAccount
.
setDeleteFlag
(
CommonConstants
.
ZERO_INT
);
YifuUser
user
=
SecurityUtils
.
getUser
();
String
sql
;
// 获取人员项目权限
R
<
TSettleDomainListVo
>
res
=
HttpDaprUtil
.
invokeMethodPost
(
daprArchivesProperties
.
getAppUrl
()
,
daprArchivesProperties
.
getAppId
(),
"/tsettledomain/getSettleDomainIdsByUserId"
,
user
.
getId
(),
TSettleDomainListVo
.
class
,
SecurityConstants
.
FROM_IN
);
StringBuilder
deptStr
=
new
StringBuilder
();
if
(
res
!=
null
&&
CommonConstants
.
SUCCESS
==
res
.
getCode
()
&&
res
.
getData
()
!=
null
&&
res
.
getData
().
getDeptIds
()
!=
null
&&
!
res
.
getData
().
getDeptIds
().
isEmpty
())
{
for
(
String
deptId
:
res
.
getData
().
getDeptIds
())
{
deptStr
.
append
(
",'"
).
append
(
deptId
).
append
(
"'"
);
}
}
sql
=
"and (1=2 or a.dept_id in ('0'#settleDomainId))"
;
sql
=
sql
.
replace
(
"#settleDomainId"
,
deptStr
.
toString
());
tSalaryAccount
.
setAuthSql
(
sql
);
return
new
R
<>(
tSalaryAccountService
.
getTSalaryAccountPage
(
page
,
tSalaryAccount
));
}
/**
* 不分页查询
*
...
...
yifu-salary/yifu-salary-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/salary/controller/TSalaryEmployeeController.java
View file @
ac2b3dc3
...
...
@@ -155,6 +155,9 @@ public class TSalaryEmployeeController {
if
(
user
!=
null
&&
Common
.
isNotNull
(
user
.
getId
()))
{
menuUtil
.
setAuthSql
(
user
,
searchVo
);
}
if
(
searchVo
.
getAuthSql
().
contains
(
CommonConstants
.
A_CREATE_BY
))
{
searchVo
.
setAuthSql
(
searchVo
.
getAuthSql
().
replace
(
CommonConstants
.
A_CREATE_BY
,
"CREATE_BY"
));
}
tSalaryEmployeeService
.
listExport
(
response
,
searchVo
);
}
}
yifu-salary/yifu-salary-biz/src/main/resources/mapper/TConfigSalaryMapper.xml
View file @
ac2b3dc3
...
...
@@ -32,7 +32,7 @@
SOCIAL_PRIORITY,
FUND_PRIORITY,
GRANT_TYPE
FROM t_config_salary
FROM t_config_salary
a
<where>
1=1
<if
test=
"tConfigSalary.id != null and tConfigSalary.id.trim() != ''"
>
...
...
yifu-salary/yifu-salary-biz/src/main/resources/mapper/TSalaryEmployeeMapper.xml
View file @
ac2b3dc3
...
...
@@ -173,6 +173,9 @@
<where>
1=1
<include
refid=
"tSalaryEmployee_where"
/>
<if
test=
"tSalaryEmployee.authSql != null and tSalaryEmployee.authSql.trim() != ''"
>
${tSalaryEmployee.authSql}
</if>
ORDER BY a.CREATE_TIME DESC
</where>
</select>
...
...
yifu-salary/yifu-salary-biz/src/main/resources/mapper/TSalaryStandardMapper.xml
View file @
ac2b3dc3
...
...
@@ -284,6 +284,9 @@
a.DELETE_FLAG = 0
<!-- 薪资是否可查看 0 是 1否-->
<include
refid=
"tSalaryStandard_where"
/>
<if
test=
"tSalaryStandard.authSql != null and tSalaryStandard.authSql.trim() != ''"
>
${tSalaryStandard.authSql}
</if>
</where>
ORDER BY a.CREATE_TIME desc
</select>
...
...
yifu-social/yifu-social-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/social/controller/TDispatchInfoController.java
View file @
ac2b3dc3
...
...
@@ -19,11 +19,15 @@ package com.yifu.cloud.plus.v1.yifu.social.controller;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.yifu.cloud.plus.v1.yifu.archives.vo.TSettleDomainListVo
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.SecurityConstants
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.Common
;
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.vo.YifuUser
;
import
com.yifu.cloud.plus.v1.yifu.common.dapr.config.DaprArchivesProperties
;
import
com.yifu.cloud.plus.v1.yifu.common.dapr.util.HttpDaprUtil
;
import
com.yifu.cloud.plus.v1.yifu.common.dapr.util.MenuUtil
;
import
com.yifu.cloud.plus.v1.yifu.common.log.annotation.SysLog
;
import
com.yifu.cloud.plus.v1.yifu.common.security.util.SecurityUtils
;
...
...
@@ -60,6 +64,8 @@ public class TDispatchInfoController {
private
final
MenuUtil
menuUtil
;
private
final
DaprArchivesProperties
daprArchivesProperties
;
/**
* 简单分页查询
* @param page 分页对象
...
...
@@ -114,6 +120,44 @@ public class TDispatchInfoController {
return
new
R
<>(
tDispatchInfoService
.
getTDispatchInfoPage
(
page
,
tDispatchInfo
));
}
/**
* 简单分页查询--申请
* @param page 分页对象
* @param tDispatchInfo 派单信息记录表--申请
* @return
*/
@Operation
(
description
=
"简单分页查询--申请"
)
@GetMapping
(
"/pageApplyOrder"
)
public
R
<
IPage
<
TDispatchInfoPageVo
>>
getTDispatchApplyPageOrder
(
Page
<
TDispatchInfo
>
page
,
TDispatchInfoSearchVo
tDispatchInfo
)
{
YifuUser
user
=
SecurityUtils
.
getUser
();
if
(
Common
.
isEmpty
(
user
))
{
return
R
.
failed
(
CommonConstants
.
USER_FAIL
);
}
tDispatchInfo
.
setCreateBy
(
user
.
getId
());
tDispatchInfo
.
setDeleteFlag
(
CommonConstants
.
ZERO_STRING
);
String
sql
;
// 获取人员项目权限
R
<
TSettleDomainListVo
>
res
=
HttpDaprUtil
.
invokeMethodPost
(
daprArchivesProperties
.
getAppUrl
()
,
daprArchivesProperties
.
getAppId
(),
"/tsettledomain/getSettleDomainIdsByUserId"
,
user
.
getId
(),
TSettleDomainListVo
.
class
,
SecurityConstants
.
FROM_IN
);
StringBuilder
deptStr
=
new
StringBuilder
();
if
(
res
!=
null
&&
CommonConstants
.
SUCCESS
==
res
.
getCode
()
&&
res
.
getData
()
!=
null
&&
res
.
getData
().
getDeptIds
()
!=
null
&&
!
res
.
getData
().
getDeptIds
().
isEmpty
())
{
for
(
String
deptId
:
res
.
getData
().
getDeptIds
())
{
deptStr
.
append
(
",'"
).
append
(
deptId
).
append
(
"'"
);
}
}
sql
=
"and (1=2 or a.dept_id in ('0'#settleDomainId))"
;
sql
=
sql
.
replace
(
"#settleDomainId"
,
deptStr
.
toString
());
tDispatchInfo
.
setAuthSql
(
sql
);
if
(
Common
.
isNotNull
(
tDispatchInfo
.
getAuthSql
())
&&
tDispatchInfo
.
getAuthSql
().
contains
(
CommonConstants
.
A_DEPT_ID
))
{
tDispatchInfo
.
setAuthSql
(
tDispatchInfo
.
getAuthSql
().
replace
(
CommonConstants
.
A_DEPT_ID
,
"a.SETTLE_DOMAIN"
));
}
return
new
R
<>(
tDispatchInfoService
.
getTDispatchInfoPage
(
page
,
tDispatchInfo
));
}
/**
* 简单分页查询--审核
* @param page 分页对象
...
...
yifu-social/yifu-social-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/social/service/impl/TPaymentInfoServiceImpl.java
View file @
ac2b3dc3
...
...
@@ -564,7 +564,7 @@ public class TPaymentInfoServiceImpl extends ServiceImpl<TPaymentInfoMapper, TPa
executeImportSocialList
(
user
,
atomicLine
,
list
,
areaMap
,
areaMap2
,
paymentInfoPensionMap
,
paymentInfoBigMap
,
paymentInfoBirMap
,
paymentInfoMedicalMap
,
paymentInfoUnEmpMap
,
paymentInfoInjuryMap
,
CommonConstants
.
ONE_INT
,
errorMessageList
),
yfSocialImportThreadPoolExecutor
);
errorMessageList
),
yfSocialImportThreadPoolExecutor
);
completableFutureList
.
add
(
listCompletableFuture
);
}
...
...
@@ -577,7 +577,7 @@ public class TPaymentInfoServiceImpl extends ServiceImpl<TPaymentInfoMapper, TPa
executeImportSocialList
(
user
,
atomicLine
,
finalList
,
areaMap
,
areaMap2
,
paymentInfoPensionMap
,
paymentInfoBigMap
,
paymentInfoBirMap
,
paymentInfoMedicalMap
,
paymentInfoUnEmpMap
,
paymentInfoInjuryMap
,
CommonConstants
.
ONE_INT
,
errorMessageList
),
yfSocialImportThreadPoolExecutor
);
errorMessageList
),
yfSocialImportThreadPoolExecutor
);
completableFutureList
.
add
(
listCompletableFuture
);
lastIdx
=
1
;
...
...
@@ -587,12 +587,11 @@ public class TPaymentInfoServiceImpl extends ServiceImpl<TPaymentInfoMapper, TPa
if
(
i
%
partSize
==
0
)
{
lastIdx
=
i
;
List
<
TPaymentInfoVo
>
finalTempList
=
tempList
;
final
int
idx
=
i
-
partSize
+
2
;
CompletableFuture
.
supplyAsync
(()
->
executeImportSocialList
(
user
,
atomicLine
,
finalTempList
,
areaMap
,
areaMap2
,
paymentInfoPensionMap
,
paymentInfoBigMap
,
paymentInfoBirMap
,
paymentInfoMedicalMap
,
paymentInfoUnEmpMap
,
paymentInfoInjuryMap
,
idx
,
errorMessageList
),
yfSocialImportThreadPoolExecutor
);
errorMessageList
),
yfSocialImportThreadPoolExecutor
);
tempList
=
new
ArrayList
<>();
}
}
...
...
@@ -613,12 +612,11 @@ public class TPaymentInfoServiceImpl extends ServiceImpl<TPaymentInfoMapper, TPa
}
List
<
TPaymentInfoVo
>
finalTempList
=
tempList
;
int
finalLastIdx
=
lastIdx
+
1
;
CompletableFuture
<
List
<
ErrorMessage
>>
listCompletableFuture
=
CompletableFuture
.
supplyAsync
(()
->
executeImportSocialList
(
user
,
atomicLine
,
finalTempList
,
areaMap
,
areaMap2
,
paymentInfoPensionMap
,
paymentInfoBigMap
,
paymentInfoBirMap
,
paymentInfoMedicalMap
,
paymentInfoUnEmpMap
,
paymentInfoInjuryMap
,
finalLastIdx
,
errorMessageList
),
yfSocialImportThreadPoolExecutor
);
errorMessageList
),
yfSocialImportThreadPoolExecutor
);
completableFutureList
.
add
(
listCompletableFuture
);
}
...
...
@@ -689,7 +687,6 @@ public class TPaymentInfoServiceImpl extends ServiceImpl<TPaymentInfoMapper, TPa
* @param areaMap
* @param areaMap2
* @param paymentInfoPensionMap
* @param idx
* @description:
* @author: huyc
* @date: 2022/7/25
...
...
@@ -706,13 +703,13 @@ public class TPaymentInfoServiceImpl extends ServiceImpl<TPaymentInfoMapper, TPa
ConcurrentHashMap
<
String
,
TPaymentInfo
>
paymentInfoMedicalMap
,
ConcurrentHashMap
<
String
,
TPaymentInfo
>
paymentInfoUnEmpMap
,
ConcurrentHashMap
<
String
,
TPaymentInfo
>
paymentInfoInjuryMap
,
int
idx
,
List
<
ErrorMessage
>
errorMessageList
)
{
int
i
=
idx
;
List
<
ErrorMessage
>
errorMessageList
)
{
if
(
Common
.
isNotNull
(
list
))
{
TPaymentInfo
paymentInfo
=
null
;
TSocialFundInfo
socialInfo
=
null
;
TSocialFundInfo
socialInfo
;
TSocialInfo
tSocialInfo
;
String
temp
;
int
res
=
-
1
;
int
res
;
List
<
TSocialFundInfo
>
socialInfoList
=
socialFundInfoMapper
.
selectList
(
Wrappers
.<
TSocialFundInfo
>
query
().
lambda
()
.
in
(
TSocialFundInfo:
:
getEmpIdcard
,
Common
.
listObjectToStrList
(
list
,
ExcelAttributeConstants
.
EMPIDCARD
)));
...
...
@@ -720,12 +717,12 @@ public class TPaymentInfoServiceImpl extends ServiceImpl<TPaymentInfoMapper, TPa
//已存在的社保数据
HashMap
<
String
,
TSocialFundInfo
>
socialMap
=
new
HashMap
<>();
if
(
Common
.
isNotNull
(
socialInfoList
))
{
for
(
TSocialFundInfo
tSocialInfo
:
socialInfoList
)
{
socialMap
.
put
(
tSocialInfo
.
getEmpIdcard
()
+
CommonConstants
.
DOWN_LINE_STRING
+
tSocialInfo
.
getSocialProvince
()
+
CommonConstants
.
DOWN_LINE_STRING
+
tSocialInfo
.
getSocialCity
()
+
CommonConstants
.
DOWN_LINE_STRING
+
(
null
==
tSocialInfo
.
getSocialTown
()
?
"null"
:
tSocialInfo
.
getSocialTown
()),
tSocialInfo
);
for
(
TSocialFundInfo
tSocialInfo
1
:
socialInfoList
)
{
socialMap
.
put
(
tSocialInfo
1
.
getEmpIdcard
()
+
CommonConstants
.
DOWN_LINE_STRING
+
tSocialInfo
1
.
getSocialProvince
()
+
CommonConstants
.
DOWN_LINE_STRING
+
tSocialInfo
1
.
getSocialCity
()
+
CommonConstants
.
DOWN_LINE_STRING
+
(
null
==
tSocialInfo
1
.
getSocialTown
()
?
"null"
:
tSocialInfo
1
.
getSocialTown
()),
tSocialInfo1
);
}
}
...
...
@@ -733,7 +730,6 @@ public class TPaymentInfoServiceImpl extends ServiceImpl<TPaymentInfoMapper, TPa
for
(
TPaymentInfoVo
infoVo
:
list
)
{
atomicLine
.
incrementAndGet
();
++
i
;
if
(
Common
.
isNotNull
(
infoVo
.
getEmpIdcard
()))
{
infoVo
.
setEmpIdcard
(
infoVo
.
getEmpIdcard
().
replace
(
"x"
,
"X"
));
}
...
...
@@ -925,11 +921,8 @@ public class TPaymentInfoServiceImpl extends ServiceImpl<TPaymentInfoMapper, TPa
errorMessageList
.
add
(
new
ErrorMessage
(
infoVo
.
getRowIndex
(),
"已存在对应员工身份证"
+
infoVo
.
getEmpIdcard
()
+
"的单位生育缴费数据,请勿重复导入!"
));
continue
;
}
else
{
paymentInfo
=
null
;
}
TSocialInfo
tSocialInfo
=
socialInfoMapper
.
selectOne
(
Wrappers
.<
TSocialInfo
>
query
().
lambda
()
tSocialInfo
=
socialInfoMapper
.
selectOne
(
Wrappers
.<
TSocialInfo
>
query
().
lambda
()
.
eq
(
TSocialInfo:
:
getEmpIdcard
,
infoVo
.
getEmpIdcard
()).
groupBy
(
TSocialInfo:
:
getCreateTime
)
.
last
(
CommonConstants
.
LAST_ONE_SQL
));
...
...
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