Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
O
operation-control-platform
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
王锦盛
operation-control-platform
Commits
2d9c1275
Commit
2d9c1275
authored
Mar 29, 2022
by
liukai
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/master'
parents
bce87e3c
fc8a4cfc
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
64 additions
and
39 deletions
+64
-39
src/main/java/com/pms/ocp/controller/ApiBasicManagementController.java
.../com/pms/ocp/controller/ApiBasicManagementController.java
+2
-2
src/main/java/com/pms/ocp/mapper/ApiBasicManagementMapper.java
...ain/java/com/pms/ocp/mapper/ApiBasicManagementMapper.java
+2
-1
src/main/java/com/pms/ocp/model/dto/ApiBaseDto.java
src/main/java/com/pms/ocp/model/dto/ApiBaseDto.java
+3
-0
src/main/java/com/pms/ocp/service/ApiBasicManagementService.java
...n/java/com/pms/ocp/service/ApiBasicManagementService.java
+1
-7
src/main/java/com/pms/ocp/service/impl/ApiBasicManagementServiceImpl.java
...m/pms/ocp/service/impl/ApiBasicManagementServiceImpl.java
+18
-10
src/main/resources/mapper/ApiBasicManagementMapper.xml
src/main/resources/mapper/ApiBasicManagementMapper.xml
+38
-19
No files found.
src/main/java/com/pms/ocp/controller/ApiBasicManagementController.java
View file @
2d9c1275
...
@@ -209,8 +209,8 @@ public class ApiBasicManagementController {
...
@@ -209,8 +209,8 @@ public class ApiBasicManagementController {
@ApiOperation
(
"省侧-应用接入申请-的模糊查询"
)
@ApiOperation
(
"省侧-应用接入申请-的模糊查询"
)
@GetMapping
(
"/selectByCondition"
)
@GetMapping
(
"/selectByCondition"
)
public
ResponseVO
<
PageInfo
<
OcpApiBase
Vo
>>
selectByCondition
(
ApiBaseDto
A
piBaseReq
)
{
public
ResponseVO
<
PageInfo
<
OcpApiBase
>>
selectByCondition
(
ApiBaseDto
a
piBaseReq
)
{
return
apiBasicManagementService
.
getBaseByGroupCode
(
A
piBaseReq
);
return
apiBasicManagementService
.
selectByCondition
(
a
piBaseReq
);
}
}
...
...
src/main/java/com/pms/ocp/mapper/ApiBasicManagementMapper.java
View file @
2d9c1275
package
com.pms.ocp.mapper
;
package
com.pms.ocp.mapper
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.pms.ocp.model.dto.ApiBaseDto
;
import
com.pms.ocp.model.dto.OcpApiBaseDto
;
import
com.pms.ocp.model.dto.OcpApiBaseDto
;
import
com.pms.ocp.model.entity.OcpApiBase
;
import
com.pms.ocp.model.entity.OcpApiBase
;
import
com.pms.ocp.model.vo.OcpApiBaseVo
;
import
com.pms.ocp.model.vo.OcpApiBaseVo
;
...
@@ -18,5 +19,5 @@ public interface ApiBasicManagementMapper extends BaseMapper<OcpApiBase> {
...
@@ -18,5 +19,5 @@ public interface ApiBasicManagementMapper extends BaseMapper<OcpApiBase> {
List
<
OcpApiBase
>
selectByCondition
(
@Param
(
"apiCode"
)
String
apiCode
,
@Param
(
"apiName"
)
String
apiName
,
@Param
(
"apiCenterCode"
)
String
apiCenterCode
,
@Param
(
"apiGroupCode"
)
String
apiGroupCode
);
List
<
OcpApiBase
>
selectByCondition
(
ApiBaseDto
apiBaseReq
);
}
}
src/main/java/com/pms/ocp/model/dto/ApiBaseDto.java
View file @
2d9c1275
...
@@ -57,6 +57,9 @@ public class ApiBaseDto implements Serializable {
...
@@ -57,6 +57,9 @@ public class ApiBaseDto implements Serializable {
@ApiModelProperty
(
"当前页"
)
@ApiModelProperty
(
"当前页"
)
private
Integer
pageNum
;
private
Integer
pageNum
;
//不同接口区分
@ApiModelProperty
(
"当前页2"
)
private
Integer
currentPage
;
@ApiModelProperty
(
"每页条数"
)
@ApiModelProperty
(
"每页条数"
)
private
Integer
pageSize
;
private
Integer
pageSize
;
...
...
src/main/java/com/pms/ocp/service/ApiBasicManagementService.java
View file @
2d9c1275
...
@@ -83,15 +83,9 @@ public interface ApiBasicManagementService extends IService<OcpApiBase> {
...
@@ -83,15 +83,9 @@ public interface ApiBasicManagementService extends IService<OcpApiBase> {
/**
/**
* 省侧-应用接入申请-的模糊查询
* 省侧-应用接入申请-的模糊查询
* @param apiCode
* @param apiName
* @param apiCenterCode
* @param currentPage
* @param pageSize
* @param apiGroupCode
* @return
* @return
*/
*/
ResponseVO
<
PageInfo
<
OcpApiBase
>>
selectByCondition
(
String
apiCode
,
String
apiName
,
String
apiCenterCode
,
Integer
currentPage
,
Integer
pageSize
,
String
apiGroupCode
);
ResponseVO
<
PageInfo
<
OcpApiBase
>>
selectByCondition
(
ApiBaseDto
apiBaseReq
);
/**
/**
* 省侧-应用接入申请-查询组中所有中心
* 省侧-应用接入申请-查询组中所有中心
...
...
src/main/java/com/pms/ocp/service/impl/ApiBasicManagementServiceImpl.java
View file @
2d9c1275
...
@@ -258,23 +258,31 @@ public class ApiBasicManagementServiceImpl extends ServiceImpl<ApiBasicManagemen
...
@@ -258,23 +258,31 @@ public class ApiBasicManagementServiceImpl extends ServiceImpl<ApiBasicManagemen
/**
/**
* 省侧-应用接入申请-的模糊查询
* 省侧-应用接入申请-的模糊查询
* @param apiCode
* @param apiName
* @param apiCenterCode
* @param apiGroupCode
* @param currentPage
* @param pageSize
* @return
* @return
*/
*/
public
ResponseVO
<
PageInfo
<
OcpApiBase
>>
selectByCondition
(
String
apiCode
,
String
apiName
,
String
apiCenterCode
,
Integer
currentPage
,
Integer
pageSize
,
String
apiGroupCode
)
{
public
ResponseVO
<
PageInfo
<
OcpApiBase
>>
selectByCondition
(
ApiBaseDto
apiBaseReq
)
{
if
(
currentPage
==
null
||
pageSize
==
null
)
{
if
(
apiBaseReq
.
getCurrentPage
()
==
null
||
apiBaseReq
.
getPageSize
()
==
null
)
{
return
ResponseVO
.
error
(
"分页参数不能为空"
);
return
ResponseVO
.
error
(
"分页参数不能为空"
);
}
}
PageHelper
.
startPage
(
currentPage
,
pageSize
);
apiGroupCode
.
add
(
apiBaseReq
.
getApiGroupCode
());
List
<
OcpApiBase
>
list
=
apiBasicManagementMapper
.
selectByCondition
(
apiCode
,
apiName
,
apiCenterCode
,
apiGroupCode
);
setGroupIdValue
(
apiBaseReq
.
getApiGroupCompanyCode
(),
apiBaseReq
.
getApiGroupCode
(),
apiBaseReq
.
getApiPromotion
());
PageHelper
.
startPage
(
apiBaseReq
.
getCurrentPage
(),
apiBaseReq
.
getPageSize
());
apiBaseReq
.
setApiGroupCodeList
(
apiGroupCode
);
// List<OcpApiBaseVo> ocpApiBaseVos = ocpApiGroupMapper.selectPageLists(apiBaseReq);
List
<
OcpApiBase
>
list
=
apiBasicManagementMapper
.
selectByCondition
(
apiBaseReq
);
apiGroupCode
.
clear
();
PageInfo
<
OcpApiBase
>
pageInfo
=
new
PageInfo
<>(
list
);
PageInfo
<
OcpApiBase
>
pageInfo
=
new
PageInfo
<>(
list
);
return
ResponseVO
.
ok
(
pageInfo
);
return
ResponseVO
.
ok
(
pageInfo
);
//
// if (currentPage == null || pageSize == null) {
// return ResponseVO.error("分页参数不能为空");
// }
// PageHelper.startPage(currentPage, pageSize);
// List<OcpApiBase> list = apiBasicManagementMapper.selectByCondition(apiCode, apiName, apiCenterCode,apiGroupCode);
// PageInfo<OcpApiBase> pageInfo = new PageInfo<>(list);
// return ResponseVO.ok(pageInfo);
}
}
/**
/**
...
...
src/main/resources/mapper/ApiBasicManagementMapper.xml
View file @
2d9c1275
...
@@ -27,7 +27,44 @@
...
@@ -27,7 +27,44 @@
</select>
</select>
<!-- <select id="queryOcpApiBaseDto" resultMap="oabMap">-->
<select
id=
"selectByCondition"
resultType=
"com.pms.ocp.model.entity.OcpApiBase"
>
select * from ocp_api_base
<where>
<if
test=
"apiGroupCodeList !=null "
>
and api_group_code in
<foreach
item=
"apiGroupCode"
collection=
"apiGroupCodeList"
open=
"("
separator=
","
close=
")"
>
#{apiGroupCode}
</foreach>
</if>
<if
test=
"apiUnit !=null and apiUnit!=''"
>
and api_unit = #{apiUnit}
</if>
<if
test=
"apiName !=null and apiName!=''"
>
and api_name = #{apiName}
</if>
<if
test=
"apiCode !=null and apiCode!=''"
>
and api_code = #{apiCode}
</if>
<if
test=
"apiPromotion !=null and apiPromotion!=''"
>
and api_promotion = #{apiPromotion}
</if>
<if
test=
"startCTime !=null "
>
<![CDATA[
and api_ctime >
= #{startCTime}
]]>
</if>
<if
test=
"endCTime !=null "
>
<![CDATA[
and api_ctime <= #{endCTime}
]]>
</if>
<if
test=
"keyword !=null and keyword != '' "
>
and api_name like CONCAT('%', #{keyword}::text,'%')
</if>
</where>
</select>
<!-- <select id="queryOcpApiBaseDto" resultMap="oabMap">-->
<!-- select-->
<!-- select-->
<!-- oab.obj_id,-->
<!-- oab.obj_id,-->
<!-- oab.api_code,oae.api_code,oab.api_name,oae.cluster_name,-->
<!-- oab.api_code,oae.api_code,oab.api_name,oae.cluster_name,-->
...
@@ -70,23 +107,5 @@
...
@@ -70,23 +107,5 @@
<!-- </select>-->
<!-- </select>-->
<select
id=
"selectByCondition"
resultType=
"com.pms.ocp.model.entity.OcpApiBase"
>
select api_name,api_code,api_version,owner_company_code,api_description ,api_center_code from ocp_api_base
<where>
<if
test=
"apiCode!=null and apiCode!=''"
>
and api_code=#{apiCode}
</if>
<if
test=
"apiName!=null and apiName!=''"
>
and api_name=#{apiName}
</if>
<if
test=
"apiCenterCode!=null and apiCenterCode!=''"
>
and api_center_code=#{apiCenterCode}
</if>
<if
test=
"apiGroupCode!=null and apiGroupCode!=''"
>
and api_group_code=#{apiGroupCode}
</if>
</where>
</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