Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
YeeAmosFireAutoSysRoot
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
station
YeeAmosFireAutoSysRoot
Commits
91249096
Commit
91249096
authored
Feb 01, 2021
by
zhengjiawei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bug
parent
62769d43
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
3 deletions
+3
-3
RiskModelController.java
...oin/amos/fas/business/controller/RiskModelController.java
+1
-1
IFmeaDao.java
...om/yeejoin/amos/fas/business/dao/repository/IFmeaDao.java
+2
-2
No files found.
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/controller/RiskModelController.java
View file @
91249096
...
...
@@ -165,7 +165,7 @@ public class RiskModelController extends BaseController {
public
CommonResponse
editFmea
(
@ApiParam
(
value
=
"Fmea模型对象"
,
required
=
true
)
@RequestBody
List
<
Fmea
>
params
)
{
try
{
params
.
forEach
(
param
->
{
int
i
=
iFmeaDao
.
checkIdAndName
(
param
.
getRiskSourceId
(),
param
.
getRiskFactorsId
());
int
i
=
iFmeaDao
.
checkIdAndName
(
param
.
getRiskSourceId
(),
param
.
getRiskFactorsId
()
,
param
.
getId
()
);
if
(
i
>
0
){
throw
new
YeeException
(
"危险因素重复"
);
}
...
...
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/dao/repository/IFmeaDao.java
View file @
91249096
...
...
@@ -49,6 +49,6 @@ public interface IFmeaDao extends BaseDao<Fmea, Long> {
@Query
(
value
=
"select * from `f_fmea` where id in ?1"
,
nativeQuery
=
true
)
List
<
Fmea
>
findAllByRiskSourceIds
(
List
<
Long
>
ids
);
@Query
(
value
=
"select count(1) from `f_fmea` where risk_source_id = ?1 and risk_factors_id = ?2"
,
nativeQuery
=
true
)
int
checkIdAndName
(
Long
sId
,
Long
nId
);
@Query
(
value
=
"select count(1) from `f_fmea` where risk_source_id = ?1 and risk_factors_id = ?2
and id != ?3
"
,
nativeQuery
=
true
)
int
checkIdAndName
(
Long
sId
,
Long
nId
,
Long
id
);
}
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