Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
T
tianjin-cement
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
竹天卫
tianjin-cement
Commits
0f6d039f
Commit
0f6d039f
authored
Mar 25, 2021
by
竹天卫
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
产值计算优化
parent
2fcd9912
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
16 deletions
+14
-16
EntrustServiceImpl.java
...e/sc/cement/business/service/impl/EntrustServiceImpl.java
+10
-12
PrecipriceServiceImpl.java
...c/cement/business/service/impl/PrecipriceServiceImpl.java
+4
-4
No files found.
cement-business/src/main/java/cn/wise/sc/cement/business/service/impl/EntrustServiceImpl.java
View file @
0f6d039f
...
...
@@ -1379,6 +1379,15 @@ public class EntrustServiceImpl extends ServiceImpl<EntrustMapper, Entrust> impl
.
setProjectCode
(
project
.
getCode
())
.
setProjectName
(
project
.
getName
());
}
//获取产值信息
QueryWrapper
<
NormProduction
>
queryWrapper
=
new
QueryWrapper
<>();
queryWrapper
.
eq
(
"type"
,
0
);
queryWrapper
.
eq
(
"status"
,
1
);
List
<
NormProduction
>
normProduction
=
iNormProductionService
.
list
(
queryWrapper
);
if
(
normProduction
==
null
||
normProduction
.
size
()
!=
1
)
{
//还原本所编号最大值
return
BaseResponse
.
errorMsg
(
"请配置处理项的产值信息!"
);
}
/* //如果项目id或者项目编号为空,根据项目名称获取项目信息
if (StringUtils.isEmpty(entrust.getProjectCode())) {
ProjectVo projectVo = projectMapper.getByName(entrust.getProjectName());
...
...
@@ -1455,18 +1464,7 @@ public class EntrustServiceImpl extends ServiceImpl<EntrustMapper, Entrust> impl
.setStatus(0)
.setAlias(handle.getName());
sampleHandleEnclosureMapper.insert(sampleHandleEnclosure);*/
//获取产值信息
QueryWrapper
<
NormProduction
>
queryWrapper
=
new
QueryWrapper
<>();
queryWrapper
.
eq
(
"type"
,
0
);
queryWrapper
.
eq
(
"status"
,
1
);
List
<
NormProduction
>
normProduction
=
iNormProductionService
.
list
(
queryWrapper
);
if
(
normProduction
==
null
||
normProduction
.
size
()
!=
1
)
{
//评审未通过,删除评审后的样品
sampleMapper
.
deleteBatchIds
(
sampleList
);
//还原本所编号最大值
redisUtil
.
setString
(
"maxCementCode"
,
redisMaxCementCode
);
return
BaseResponse
.
errorMsg
(
"请配置处理项的产值信息!"
);
}
}
//消息推送
BaseResponse
wrapper
=
userMessageService
.
sendMessage
(
sampleHandle
.
getUserId
(),
"您有一条样品处理信息等待处理"
,
entrust
.
getId
(),
SysUserMessage
.
MessageType
.
ENTRUST
);
...
...
cement-business/src/main/java/cn/wise/sc/cement/business/service/impl/PrecipriceServiceImpl.java
View file @
0f6d039f
...
...
@@ -131,7 +131,7 @@ public class PrecipriceServiceImpl extends ServiceImpl<PrecipriceMapper, Precipr
throw
new
IllegalArgumentException
(
"联系管理员.配置产值信息!"
);
}
preciprice
.
setAnalyseRate
(
BigDecimal
.
valueOf
(
normProduction
.
getAnalyseRate
()));
preciprice
.
setAssessRate
(
BigDecimal
.
valueOf
(
normProduction
.
getAssess
Id
()));
preciprice
.
setAssessRate
(
BigDecimal
.
valueOf
(
normProduction
.
getAssess
Rate
()));
preciprice
.
setAssessValue
(
BigDecimal
.
valueOf
(
normProduction
.
getAssessValue
()));
preciprice
.
setReportedAnalyseResult
(
BigDecimal
.
valueOf
(
normProduction
.
getReportedAnalyseResult
()));
preciprice
.
setReportedResultRate
(
BigDecimal
.
valueOf
(
normProduction
.
getReportedResultRate
()));
...
...
@@ -323,7 +323,7 @@ public class PrecipriceServiceImpl extends ServiceImpl<PrecipriceMapper, Precipr
if
(!
BeanUtil
.
isEmpty
(
userId
))
{
qw
.
eq
(
"user_id"
,
userId
);
}
qw
.
eq
(
"status"
,
1
);
//
qw.eq("status", 1);
qw
.
orderByDesc
(
"create_time"
);
List
<
Preciprice
>
list
=
this
.
list
(
qw
);
List
<
NormProduction
.
NormProductionUserDetail
>
rts
=
new
ArrayList
<>(
list
.
size
());
...
...
@@ -408,7 +408,7 @@ public class PrecipriceServiceImpl extends ServiceImpl<PrecipriceMapper, Precipr
if
(!
BeanUtil
.
isEmpty
(
userId
))
{
qw
.
eq
(
"user_id"
,
userId
);
}
qw
.
eq
(
"status"
,
1
);
//
qw.eq("status", 1);
qw
.
orderByDesc
(
"create_time"
);
List
<
Preciprice
>
list
=
this
.
list
(
qw
);
List
<
NormProduction
.
NormProductionUserDetail
>
rts
=
new
ArrayList
<>(
list
.
size
());
...
...
@@ -570,7 +570,7 @@ public class PrecipriceServiceImpl extends ServiceImpl<PrecipriceMapper, Precipr
}
else
{
qw
.
eq
(
"target_id"
,
objId
);
}
qw
.
eq
(
"status"
,
1
);
//
qw.eq("status", 1);
qw
.
orderByDesc
(
"create_time"
);
List
<
Preciprice
>
list
=
this
.
list
(
qw
);
List
<
NormProduction
.
NormProductionDetail
>
rts
=
new
ArrayList
<>(
list
.
size
());
...
...
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