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
9798cb7e
Commit
9798cb7e
authored
Jun 06, 2023
by
huyuchen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
优化修改
parent
6c513b63
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
42 additions
and
26 deletions
+42
-26
TDispatchInfo.java
.../yifu/cloud/plus/v1/yifu/social/entity/TDispatchInfo.java
+11
-0
TDispatchInfoServiceImpl.java
...v1/yifu/social/service/impl/TDispatchInfoServiceImpl.java
+22
-10
TForecastLibraryServiceImpl.java
...yifu/social/service/impl/TForecastLibraryServiceImpl.java
+9
-16
No files found.
yifu-social/yifu-social-api/src/main/java/com/yifu/cloud/plus/v1/yifu/social/entity/TDispatchInfo.java
View file @
9798cb7e
...
@@ -26,6 +26,7 @@ import com.baomidou.mybatisplus.annotation.TableName;
...
@@ -26,6 +26,7 @@ import com.baomidou.mybatisplus.annotation.TableName;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.ExcelAttribute
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.ExcelAttribute
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.ExcelAttributeConstants
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.ExcelAttributeConstants
;
import
com.yifu.cloud.plus.v1.yifu.common.mybatis.base.BaseEntity
;
import
com.yifu.cloud.plus.v1.yifu.common.mybatis.base.BaseEntity
;
import
com.yifu.cloud.plus.v1.yifu.social.vo.SocialImportHandleVo
;
import
io.swagger.v3.oas.annotations.media.Schema
;
import
io.swagger.v3.oas.annotations.media.Schema
;
import
lombok.Data
;
import
lombok.Data
;
import
lombok.EqualsAndHashCode
;
import
lombok.EqualsAndHashCode
;
...
@@ -750,4 +751,14 @@ public class TDispatchInfo extends BaseEntity {
...
@@ -750,4 +751,14 @@ public class TDispatchInfo extends BaseEntity {
@TableField
(
exist
=
false
)
@TableField
(
exist
=
false
)
private
String
noCreateUser
;
private
String
noCreateUser
;
@TableField
(
exist
=
false
)
private
SocialImportHandleVo
excel
;
@TableField
(
exist
=
false
)
private
String
handlerRemaek
;
@TableField
(
exist
=
false
)
private
String
socialFailureType
;
}
}
yifu-social/yifu-social-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/social/service/impl/TDispatchInfoServiceImpl.java
View file @
9798cb7e
...
@@ -5288,6 +5288,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
...
@@ -5288,6 +5288,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
String
handlerRemaek
;
String
handlerRemaek
;
List
<
TDispatchInfo
>
failueList
=
new
ArrayList
<>();
for
(
int
i
=
0
;
i
<
excelVOList
.
size
();
i
++)
{
for
(
int
i
=
0
;
i
<
excelVOList
.
size
();
i
++)
{
StringBuilder
socialSucessType
=
new
StringBuilder
();
StringBuilder
socialSucessType
=
new
StringBuilder
();
StringBuilder
socialFailureType
=
new
StringBuilder
();
StringBuilder
socialFailureType
=
new
StringBuilder
();
...
@@ -5375,26 +5376,37 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
...
@@ -5375,26 +5376,37 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
}
}
errorMessageList
.
add
(
errorMessage
);
errorMessageList
.
add
(
errorMessage
);
}
}
//办理失败处理
//办理失败处理
if
(
socialFailureType
.
length
()
>
1
)
{
if
(
socialFailureType
.
length
()
>
1
)
{
if
(!
CommonConstants
.
TWO_STRING
.
equals
(
dispatch
.
getStatus
()))
{
if
(!
CommonConstants
.
TWO_STRING
.
equals
(
dispatch
.
getStatus
()))
{
continue
;
continue
;
}
}
dispatch
.
setHandlerRemaek
(
handlerRemaek
);
dispatch
.
setSocialFailureType
(
socialFailureType
.
toString
());
dispatch
.
setExcel
(
excel
);
failueList
.
add
(
dispatch
);
}
}
catch
(
Exception
e
)
{
log
.
error
(
"批量导入办理异常:"
,
e
);
errorMessageList
.
add
(
new
ErrorMessage
(
excel
.
getRowIndex
(),
CommonConstants
.
SAVE_FAILED
,
excel
));
}
}
if
(!
Common
.
isEmpty
(
failueList
))
{
SocialImportHandleVo
vo
;
for
(
TDispatchInfo
dispatchInfo
:
failueList
)
{
vo
=
dispatchInfo
.
getExcel
();
// 执行数据插入操作 组装
// 执行数据插入操作 组装
messageList
=
addBatchApplyHandle
(
Collections
.
singletonList
(
dispatch
.
getId
()),
CommonConstants
.
ZERO_STRING
,
user
messageList
=
addBatchApplyHandle
(
Collections
.
singletonList
(
dispatchInfo
.
getId
()),
CommonConstants
.
ZERO_STRING
,
user
,
1
,
CommonConstants
.
TWO_STRING
,
handlerRemaek
+
ServiceUtil
.
ifNullToEmpty
(
excel
.
getRemark
()),
socialFailureType
.
substring
(
0
,
socialFailureType
.
length
()
-
1
),
handlerRemaek
+
ServiceUtil
.
ifNullToEmpty
(
excel
.
getRemark
()));
,
1
,
CommonConstants
.
TWO_STRING
,
dispatchInfo
.
getHandlerRemaek
()
+
ServiceUtil
.
ifNullToEmpty
(
vo
.
getRemark
()),
dispatchInfo
.
getSocialFailureType
().
substring
(
0
,
dispatchInfo
.
getSocialFailureType
().
length
()
-
1
),
dispatchInfo
.
getHandlerRemaek
()
+
ServiceUtil
.
ifNullToEmpty
(
vo
.
getRemark
()));
if
(
Common
.
isNotNull
(
messageList
))
{
if
(
Common
.
isNotNull
(
messageList
))
{
errorMessage
=
messageList
.
get
(
CommonConstants
.
ZERO_INT
);
errorMessage
=
messageList
.
get
(
CommonConstants
.
ZERO_INT
);
errorMessage
.
setData
(
excel
);
errorMessage
.
setData
(
vo
);
}
else
{
}
else
{
errorMessage
=
new
ErrorMessage
(
excel
.
getRowIndex
(),
CommonConstants
.
SAVE_SUCCESS
,
CommonConstants
.
GREEN
,
excel
);
errorMessage
=
new
ErrorMessage
(
vo
.
getRowIndex
(),
CommonConstants
.
SAVE_SUCCESS
,
CommonConstants
.
GREEN
,
vo
);
}
}
errorMessageList
.
add
(
errorMessage
);
errorMessageList
.
add
(
errorMessage
);
}
}
}
catch
(
Exception
e
)
{
log
.
error
(
"批量导入办理异常:"
,
e
);
errorMessageList
.
add
(
new
ErrorMessage
(
excel
.
getRowIndex
(),
CommonConstants
.
SAVE_FAILED
,
excel
));
}
}
}
}
}
...
...
yifu-social/yifu-social-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/social/service/impl/TForecastLibraryServiceImpl.java
View file @
9798cb7e
...
@@ -1864,11 +1864,9 @@ public class TForecastLibraryServiceImpl extends ServiceImpl<TForecastLibraryMap
...
@@ -1864,11 +1864,9 @@ public class TForecastLibraryServiceImpl extends ServiceImpl<TForecastLibraryMap
//先删除然后重新生成
//先删除然后重新生成
boolean
isSaveAndUpdate
=
false
;
boolean
isSaveAndUpdate
=
false
;
synchronized
(
this
)
{
if
(
Common
.
isNotNull
(
librarySocialList
))
{
if
(
Common
.
isNotNull
(
librarySocialList
))
{
baseMapper
.
deleteBatchIds
(
librarySocialList
);
baseMapper
.
deleteBatchIds
(
librarySocialList
);
}
}
}
if
(
Common
.
isNotNull
(
libraryFundList
))
{
if
(
Common
.
isNotNull
(
libraryFundList
))
{
baseMapper
.
deleteBatchIds
(
libraryFundList
);
baseMapper
.
deleteBatchIds
(
libraryFundList
);
}
}
...
@@ -1908,12 +1906,8 @@ public class TForecastLibraryServiceImpl extends ServiceImpl<TForecastLibraryMap
...
@@ -1908,12 +1906,8 @@ public class TForecastLibraryServiceImpl extends ServiceImpl<TForecastLibraryMap
log
.
error
(
"更新一条预估耗时:"
+
times
+
"毫秒"
);
log
.
error
(
"更新一条预估耗时:"
+
times
+
"毫秒"
);
isSaveAndUpdate
=
true
;
isSaveAndUpdate
=
true
;
}
else
{
}
else
{
synchronized
(
this
)
{
if
(
BigDecimal
.
ZERO
.
compareTo
(
BigDecimalUtils
.
isNullToZero
(
library
.
getUnitSocialSum
()))
!=
CommonConstants
.
ZERO_INT
if
(
BigDecimal
.
ZERO
.
compareTo
(
BigDecimalUtils
.
isNullToZero
(
library
.
getUnitSocialSum
()))
!=
CommonConstants
.
ZERO_INT
||
BigDecimal
.
ZERO
.
compareTo
(
BigDecimalUtils
.
isNullToZero
(
library
.
getUnitFundSum
()))
!=
CommonConstants
.
ZERO_INT
)
{
||
BigDecimal
.
ZERO
.
compareTo
(
BigDecimalUtils
.
isNullToZero
(
library
.
getUnitFundSum
()))
!=
CommonConstants
.
ZERO_INT
)
{
//判断是否有重复数据有则删除
baseMapper
.
deleteForecastSocial
(
library
.
getEmpIdcard
(),
library
.
getSocialPayMonth
(),
library
.
getSocialCreateMonth
()
,
library
.
getProvidentPayMonth
(),
library
.
getProvidentCreateMonth
());
library
.
setCreateBy
(
userId
);
library
.
setCreateBy
(
userId
);
library
.
setCreateName
(
userName
);
library
.
setCreateName
(
userName
);
library
.
setCreateTime
(
LocalDateTime
.
now
());
library
.
setCreateTime
(
LocalDateTime
.
now
());
...
@@ -1922,7 +1916,6 @@ public class TForecastLibraryServiceImpl extends ServiceImpl<TForecastLibraryMap
...
@@ -1922,7 +1916,6 @@ public class TForecastLibraryServiceImpl extends ServiceImpl<TForecastLibraryMap
}
}
}
}
}
}
}
saveLibraryMap
.
clear
();
saveLibraryMap
.
clear
();
if
(
Common
.
isNotNull
(
socialFundInfo
.
getSocialId
())
&&
CommonConstants
.
FOUR_STRING
.
equals
(
socialFundInfo
.
getSocialStatus
())
if
(
Common
.
isNotNull
(
socialFundInfo
.
getSocialId
())
&&
CommonConstants
.
FOUR_STRING
.
equals
(
socialFundInfo
.
getSocialStatus
())
||
CommonConstants
.
THREE_STRING
.
equals
(
socialFundInfo
.
getSocialStatus
()))
{
||
CommonConstants
.
THREE_STRING
.
equals
(
socialFundInfo
.
getSocialStatus
()))
{
...
...
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