Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
cloud-fb
Overview
Overview
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
王衍超
cloud-fb
Commits
cf71e17c
Commit
cf71e17c
authored
Mar 23, 2021
by
高晓磊
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
名称校验,新增时不需要传id
parent
62e1aff6
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
6 additions
and
8 deletions
+6
-8
CameraInfoDaoImpl.java
...va/com/xyst/dinas/biz/internal/dao/CameraInfoDaoImpl.java
+1
-1
CameraInfoController.java
...ain/java/com/xyst/dinas/biz/web/CameraInfoController.java
+2
-4
DinasTypeController.java
...main/java/com/xyst/dinas/biz/web/DinasTypeController.java
+2
-2
StationController.java
...c/main/java/com/xyst/dinas/biz/web/StationController.java
+1
-1
No files found.
backend/xyst.dinas.biz/src/main/java/com/xyst/dinas/biz/internal/dao/CameraInfoDaoImpl.java
View file @
cf71e17c
...
@@ -90,7 +90,7 @@ public class CameraInfoDaoImpl extends AbstractBaseDao implements CameraInfoDao,
...
@@ -90,7 +90,7 @@ public class CameraInfoDaoImpl extends AbstractBaseDao implements CameraInfoDao,
KObject
staff
=
AminoContextHolder
.
getContext
().
getStaff
();
KObject
staff
=
AminoContextHolder
.
getContext
().
getStaff
();
kobject
.
set
(
"modifyTime"
,
new
Date
());
kobject
.
set
(
"modifyTime"
,
new
Date
());
kobject
.
set
(
"modifier"
,
staff
.
getUuid
(
"id"
));
kobject
.
set
(
"modifier"
,
staff
.
getUuid
(
"id"
));
kobject
.
set
(
"del"
,
tru
e
);
kobject
.
set
(
"del"
,
fals
e
);
template
.
merge
(
kobject
);
template
.
merge
(
kobject
);
}
}
...
...
backend/xyst.dinas.biz/src/main/java/com/xyst/dinas/biz/web/CameraInfoController.java
View file @
cf71e17c
...
@@ -155,16 +155,14 @@ public class CameraInfoController {
...
@@ -155,16 +155,14 @@ public class CameraInfoController {
* @return
* @return
*/
*/
@GetMapping
(
"/validateName"
)
@GetMapping
(
"/validateName"
)
public
ResponseObj
validateName
(
@RequestParam
(
"name"
)
String
name
,
@RequestParam
(
"id"
)
UUID
id
){
public
ResponseObj
validateName
(
@RequestParam
(
"name"
)
String
name
,
@RequestParam
(
name
=
"id"
,
required
=
false
)
UUID
id
){
if
(
StringUtils
.
isEmpty
(
name
)){
if
(
StringUtils
.
isEmpty
(
name
)){
return
ResponseObj
.
error
(
400
,
"摄像头名称不能为空"
);
return
ResponseObj
.
error
(
400
,
"摄像头名称不能为空"
);
}
}
KObject
kObject
=
cameraInfoService
.
getByName
(
name
,
id
);
KObject
kObject
=
cameraInfoService
.
getByName
(
name
,
id
);
if
(
kObject
!=
null
){
if
(
kObject
!=
null
){
return
ResponseObj
.
error
(
"摄像头
种类
名称已存在!"
);
return
ResponseObj
.
error
(
"摄像头名称已存在!"
);
}
}
return
ResponseObj
.
success
();
return
ResponseObj
.
success
();
}
}
}
}
backend/xyst.dinas.biz/src/main/java/com/xyst/dinas/biz/web/DinasTypeController.java
View file @
cf71e17c
...
@@ -104,7 +104,7 @@ public class DinasTypeController {
...
@@ -104,7 +104,7 @@ public class DinasTypeController {
* @return
* @return
*/
*/
@GetMapping
(
"/validateName"
)
@GetMapping
(
"/validateName"
)
public
ResponseObj
validateName
(
@RequestParam
(
"name"
)
String
name
,
@RequestParam
(
"id"
)
UUID
id
){
public
ResponseObj
validateName
(
@RequestParam
(
"name"
)
String
name
,
@RequestParam
(
value
=
"id"
,
required
=
false
)
UUID
id
){
if
(
StringUtils
.
isEmpty
(
name
)){
if
(
StringUtils
.
isEmpty
(
name
)){
return
ResponseObj
.
error
(
400
,
"砂石种类名称不能为空"
);
return
ResponseObj
.
error
(
400
,
"砂石种类名称不能为空"
);
}
}
...
@@ -137,7 +137,7 @@ public class DinasTypeController {
...
@@ -137,7 +137,7 @@ public class DinasTypeController {
*/
*/
@PostMapping
(
"/unCheckedStation"
)
@PostMapping
(
"/unCheckedStation"
)
public
ResponseObj
unCheckedStation
(
@RequestParam
(
"dinasTypeId"
)
UUID
dinasTypeId
,
@RequestParam
(
"stationId"
)
UUID
stationId
){
public
ResponseObj
unCheckedStation
(
@RequestParam
(
"dinasTypeId"
)
UUID
dinasTypeId
,
@RequestParam
(
value
=
"stationId"
,
required
=
true
)
UUID
stationId
){
if
(
null
==
dinasTypeId
){
if
(
null
==
dinasTypeId
){
return
ResponseObj
.
error
(
"未查询到砂石类型信息!"
);
return
ResponseObj
.
error
(
"未查询到砂石类型信息!"
);
}
}
...
...
backend/xyst.dinas.biz/src/main/java/com/xyst/dinas/biz/web/StationController.java
View file @
cf71e17c
...
@@ -142,7 +142,7 @@ public class StationController {
...
@@ -142,7 +142,7 @@ public class StationController {
* @return
* @return
*/
*/
@GetMapping
(
"/validateName"
)
@GetMapping
(
"/validateName"
)
public
ResponseObj
validateName
(
@RequestParam
(
"name"
)
String
name
,
@RequestParam
(
"id"
)
UUID
id
){
public
ResponseObj
validateName
(
@RequestParam
(
"name"
)
String
name
,
@RequestParam
(
value
=
"id"
,
required
=
false
)
UUID
id
){
if
(
StringUtils
.
isEmpty
(
name
)){
if
(
StringUtils
.
isEmpty
(
name
)){
return
ResponseObj
.
error
(
400
,
"场站名称不能为空"
);
return
ResponseObj
.
error
(
400
,
"场站名称不能为空"
);
}
}
...
...
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