Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Y
yichengstreet-be
Project
Project
Details
Activity
Releases
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
yichengstreet
yichengstreet-be
Commits
0fe95dae
Commit
0fe95dae
authored
Mar 20, 2025
by
luben
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix
parent
68081979
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
31 additions
and
4 deletions
+31
-4
RegionController.java
.../java/com/ruoyi/web/controller/grid/RegionController.java
+17
-0
GridRegionService.java
...java/com/ruoyi/system/service/grid/GridRegionService.java
+2
-0
GridRegionServiceImpl.java
...ruoyi/system/service/grid/impl/GridRegionServiceImpl.java
+12
-4
No files found.
ruoyi-admin/src/main/java/com/ruoyi/web/controller/grid/RegionController.java
View file @
0fe95dae
...
@@ -914,4 +914,21 @@ public class RegionController extends BaseController {
...
@@ -914,4 +914,21 @@ public class RegionController extends BaseController {
return
AjaxResult
.
success
(
gridRegionMapper
.
changeTreeNodeNameByCode
(
id
,
name
));
return
AjaxResult
.
success
(
gridRegionMapper
.
changeTreeNodeNameByCode
(
id
,
name
));
}
}
@RequestMapping
(
value
=
"/getRegion"
,
method
=
RequestMethod
.
GET
)
@ResponseBody
public
AjaxResult
getRegion
(
@RequestParam
(
"wgCode"
)
String
wgCode
)
{
Map
<
String
,
List
<
GridRegion
>>
res
=
new
HashMap
<>();
List
<
GridRegion
>
type1
=
gridRegionService
.
getGridRegionMapByWgCodeAndWgType
(
wgCode
,
"1"
);
List
<
GridRegion
>
type4
=
gridRegionService
.
getGridRegionMapByWgCodeAndWgType
(
wgCode
,
"4"
);
List
<
GridRegion
>
type5
=
gridRegionService
.
getGridRegionMapByWgCodeAndWgType
(
wgCode
,
"5"
);
List
<
GridRegion
>
type6
=
gridRegionService
.
getGridRegionMapByWgCodeAndWgType
(
wgCode
,
"6"
);
List
<
GridRegion
>
type7
=
gridRegionService
.
getGridRegionMapByWgCodeAndWgType
(
wgCode
,
"7"
);
res
.
put
(
"1"
,
type1
);
res
.
put
(
"4"
,
type4
);
res
.
put
(
"5"
,
type5
);
res
.
put
(
"6"
,
type6
);
res
.
put
(
"7"
,
type7
);
return
AjaxResult
.
success
(
res
);
}
}
}
ruoyi-system/src/main/java/com/ruoyi/system/service/grid/GridRegionService.java
View file @
0fe95dae
...
@@ -39,4 +39,6 @@ public interface GridRegionService extends BaseService<GridRegion, GridRegionExa
...
@@ -39,4 +39,6 @@ public interface GridRegionService extends BaseService<GridRegion, GridRegionExa
List
<
GridRegion
>
getByParams
(
GridRegionSearchParam
searchParam
);
List
<
GridRegion
>
getByParams
(
GridRegionSearchParam
searchParam
);
List
<
GridRegion
>
getGridRegionMapByWgType
(
String
wgType
);
List
<
GridRegion
>
getGridRegionMapByWgType
(
String
wgType
);
List
<
GridRegion
>
getGridRegionMapByWgCodeAndWgType
(
String
wgCode
,
String
wgType
);
}
}
ruoyi-system/src/main/java/com/ruoyi/system/service/grid/impl/GridRegionServiceImpl.java
View file @
0fe95dae
...
@@ -15,10 +15,7 @@ import org.slf4j.LoggerFactory;
...
@@ -15,10 +15,7 @@ import org.slf4j.LoggerFactory;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
org.springframework.stereotype.Service
;
import
java.util.ArrayList
;
import
java.util.*
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.stream.Collectors
;
import
java.util.stream.Collectors
;
/**
/**
...
@@ -176,4 +173,15 @@ public class GridRegionServiceImpl extends BaseServiceImpl<GridRegionMapper, Gri
...
@@ -176,4 +173,15 @@ public class GridRegionServiceImpl extends BaseServiceImpl<GridRegionMapper, Gri
return
gridRegionService
.
selectByExample
(
ex
);
return
gridRegionService
.
selectByExample
(
ex
);
}
}
@Override
public
List
<
GridRegion
>
getGridRegionMapByWgCodeAndWgType
(
String
wgCode
,
String
wgType
)
{
GridRegionExample
example
=
new
GridRegionExample
();
GridRegionExample
.
Criteria
criteria
=
example
.
createCriteria
();
criteria
.
andIsValidEqualTo
(
"1"
);
criteria
.
andWgTypeEqualTo
(
wgType
);
criteria
.
andWgCodeNotEqualTo
(
wgCode
);
criteria
.
andWgCodeLike
(
"%"
+
wgCode
+
"%"
);
return
gridRegionMapper
.
selectByExampleWithBLOBs
(
example
);
}
}
}
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