Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
I
indicators
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
zhangkb
indicators
Commits
8b03a412
Commit
8b03a412
authored
Jul 08, 2020
by
zhangkb
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加根据考核目录类型和code获取考核目录list
parent
291245f3
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
28 additions
and
0 deletions
+28
-0
IndCatalogCtrl.java
...om/keymobile/indicators/api/hytobacco/IndCatalogCtrl.java
+7
-0
DriveIndCatalogMapper.java
...icators/model/mapper/indmapper/DriveIndCatalogMapper.java
+2
-0
DriveIndCatalogService.java
.../indicators/service/hytobacco/DriveIndCatalogService.java
+7
-0
DriveIndCatalogMapper.xml
src/main/resources/mybatis/mapping/DriveIndCatalogMapper.xml
+12
-0
No files found.
src/main/java/com/keymobile/indicators/api/hytobacco/IndCatalogCtrl.java
View file @
8b03a412
...
@@ -106,4 +106,11 @@ public class IndCatalogCtrl {
...
@@ -106,4 +106,11 @@ public class IndCatalogCtrl {
public
List
<
DriveIndCatalog
>
getByDriveCatalogIdList
(
@RequestParam
List
<
Integer
>
catalogIds
){
public
List
<
DriveIndCatalog
>
getByDriveCatalogIdList
(
@RequestParam
List
<
Integer
>
catalogIds
){
return
driveIndCatalogService
.
getByCatalogIdList
(
catalogIds
);
return
driveIndCatalogService
.
getByCatalogIdList
(
catalogIds
);
}
}
@ApiOperation
(
value
=
"根据考核指标目录类型和code获取考核目录list"
,
notes
=
"根据考核指标目录类型和code获取考核目录list"
)
@PostMapping
(
value
=
"/getByCatalogTypeAndCode"
)
public
List
<
DriveIndCatalog
>
getByCatalogTypeAndCode
(
@RequestParam
String
catalogType
,
@RequestParam
List
<
String
>
codes
){
return
driveIndCatalogService
.
getByCatalogTypeAndCode
(
catalogType
,
codes
);
}
}
}
src/main/java/com/keymobile/indicators/model/mapper/indmapper/DriveIndCatalogMapper.java
View file @
8b03a412
...
@@ -22,4 +22,6 @@ public interface DriveIndCatalogMapper extends BaseMapper<DriveIndCatalog>{
...
@@ -22,4 +22,6 @@ public interface DriveIndCatalogMapper extends BaseMapper<DriveIndCatalog>{
public
List
<
DriveIndCatalog
>
findFirstVaildCatalog
(
Map
<
String
,
Object
>
params
);
public
List
<
DriveIndCatalog
>
findFirstVaildCatalog
(
Map
<
String
,
Object
>
params
);
public
List
<
DriveIndCatalog
>
findByCatalogIdIn
(
@Param
(
"ids"
)
List
<
Integer
>
ids
);
public
List
<
DriveIndCatalog
>
findByCatalogIdIn
(
@Param
(
"ids"
)
List
<
Integer
>
ids
);
public
List
<
DriveIndCatalog
>
findByCatalogTypeAndCode
(
Map
<
String
,
Object
>
params
);
}
}
src/main/java/com/keymobile/indicators/service/hytobacco/DriveIndCatalogService.java
View file @
8b03a412
...
@@ -108,4 +108,11 @@ public class DriveIndCatalogService {
...
@@ -108,4 +108,11 @@ public class DriveIndCatalogService {
public
List
<
DriveIndCatalog
>
getByCatalogIdList
(
List
<
Integer
>
catalogIds
){
public
List
<
DriveIndCatalog
>
getByCatalogIdList
(
List
<
Integer
>
catalogIds
){
return
driveIndCatalogMapper
.
findByCatalogIdIn
(
catalogIds
);
return
driveIndCatalogMapper
.
findByCatalogIdIn
(
catalogIds
);
}
}
public
List
<
DriveIndCatalog
>
getByCatalogTypeAndCode
(
String
type
,
List
<
String
>
codes
){
Map
<
String
,
Object
>
paramMap
=
new
HashMap
<>();
paramMap
.
put
(
"type"
,
type
);
paramMap
.
put
(
"codes"
,
codes
);
return
driveIndCatalogMapper
.
findByCatalogTypeAndCode
(
paramMap
);
}
}
}
src/main/resources/mybatis/mapping/DriveIndCatalogMapper.xml
View file @
8b03a412
...
@@ -58,4 +58,15 @@
...
@@ -58,4 +58,15 @@
#{id}
#{id}
</foreach>
</foreach>
</select>
</select>
<select
id=
"findByCatalogTypeAndCode"
parameterType=
"map"
resultType=
"com.keymobile.indicators.model.entity.indicators.DriveIndCatalog"
>
select *
from drive_ind_catalog
where
catalog_type=#{type} and
code in
<foreach
item=
"id"
collection=
"codes"
open=
"("
close=
")"
separator=
","
>
#{id}
</foreach>
</select>
</mapper>
</mapper>
\ No newline at end of file
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