Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
amos-boot-biz
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
项目统一框架
amos-boot-biz
Commits
a9e6b997
Commit
a9e6b997
authored
Jun 01, 2022
by
maoying
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改车辆编辑物联编码重复提示
parent
66a7ad19
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
15 additions
and
1 deletion
+15
-1
CarController.java
...ava/com/yeejoin/equipmanage/controller/CarController.java
+1
-1
CarMapper.java
...c/main/java/com/yeejoin/equipmanage/mapper/CarMapper.java
+2
-0
CarMapper.xml
...boot-system-equip/src/main/resources/mapper/CarMapper.xml
+12
-0
No files found.
amos-boot-module/amos-boot-module-biz/amos-boot-module-equip-biz/src/main/java/com/yeejoin/equipmanage/controller/CarController.java
View file @
a9e6b997
...
...
@@ -315,7 +315,7 @@ public class CarController extends AbstractBaseController {
if
(
car
.
getIotCode
()!=
null
){
Car
ar
=
carMapper
.
getCarsByIotCode
(
car
.
getIotCode
());
Car
ar
=
carMapper
.
getCarsByIotCode
ExcludeCarId
(
car
.
getIotCode
(),
car
.
getId
());
if
(
ar
!=
null
){
throw
new
BadRequest
(
"物联编码重复"
);
}
...
...
amos-boot-module/amos-boot-module-biz/amos-boot-module-equip-biz/src/main/java/com/yeejoin/equipmanage/mapper/CarMapper.java
View file @
a9e6b997
...
...
@@ -37,6 +37,8 @@ public interface CarMapper extends BaseMapper<Car> {
List
<
String
>
getIotCodeList
(
@Param
(
"id"
)
String
id
);
Car
getCarsByIotCode
(
@Param
(
"iotCode"
)
String
iotCode
);
Car
getCarsByIotCodeExcludeCarId
(
@Param
(
"iotCode"
)
String
iotCode
,
@Param
(
"carId"
)
Long
carId
);
List
<
CarIndexVo
>
getCarsInfoByOrgCode
(
@Param
(
"orgCode"
)
String
orgCode
);
...
...
amos-boot-system-equip/src/main/resources/mapper/CarMapper.xml
View file @
a9e6b997
...
...
@@ -247,6 +247,18 @@
AND
wc.iot_code = #{iotCode}
</select>
<select
id=
"getCarsByIotCodeExcludeCarId"
resultType=
"com.yeejoin.equipmanage.common.entity.Car"
>
SELECT
wc.car_num
FROM
wl_car wc
WHERE
wc.iot_code IS NOT NULL
AND
wc.iot_code = #{iotCode}
AND wc.id != #{carId}
</select>
<select
id=
"getCarsInfoByOrgCode"
resultMap=
"carIotInfoMap"
>
...
...
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