Commit 792259bd authored by 郭凡凡's avatar 郭凡凡

修改bug

parent 487f5bf7
......@@ -23,7 +23,7 @@ public interface OcpApiGroupMapper extends BaseMapper<OcpApiGroup> {
List<OcpApiBaseVo> selectPageLists(ApiBaseDto apiBaseReq);
List<OcpGroupBaseDto> apiTree(String apiGroupCompanyCode, String apiGroupPcode, Integer apiGroupPromotionType);
List<OcpGroupBaseDto> apiTree(OcpApiBaseVo ocpApiBaseVo);
List<OcpGroupBaseDto> selectBase(String apiGroupCompanyCode, String apiGroupPcode,Integer apiGroupPromotionType);
......
......@@ -108,7 +108,7 @@ public class OcpApiBaseVo implements Serializable {
private String apiGroupName;
@ApiModelProperty("推广类型0统推,1自建")
private long apiGroupPromotionType;
private Integer apiGroupPromotionType;
@ApiModelProperty("分类所属公司")
private String apiGroupCompanyCode;
......@@ -312,11 +312,11 @@ public class OcpApiBaseVo implements Serializable {
this.apiGroupName = apiGroupName;
}
public long getApiGroupPromotionType() {
public Integer getApiGroupPromotionType() {
return apiGroupPromotionType;
}
public void setApiGroupPromotionType(long apiGroupPromotionType) {
public void setApiGroupPromotionType(Integer apiGroupPromotionType) {
this.apiGroupPromotionType = apiGroupPromotionType;
}
......
......@@ -156,7 +156,11 @@ public class ApiBasicManagementServiceImpl extends ServiceImpl<ApiBasicManagemen
@Override
public List<OcpGroupBaseDto> apiBaseTreeOther(String apiGroupCompanyCode, String apiGroupPcode, Integer apiGroupPromotionType, String apiCode) {
List<OcpGroupBaseDto> ocpApiGroups = ocpApiGroupMapper.apiTree(apiGroupCompanyCode, apiGroupPcode, apiGroupPromotionType);
OcpApiBaseVo ocpApiBaseVo = new OcpApiBaseVo();
ocpApiBaseVo.setApiGroupCompanyCode(apiGroupCompanyCode);
ocpApiBaseVo.setApiGroupPcode(apiGroupPcode);
ocpApiBaseVo.setApiGroupPromotionType(apiGroupPromotionType);
List<OcpGroupBaseDto> ocpApiGroups = ocpApiGroupMapper.apiTree(ocpApiBaseVo);
if (ocpApiGroups.size() != 0) {
return ocpApiGroups;
} else {
......
......@@ -50,22 +50,20 @@
</select>
<select id="apiTree" resultType="com.pms.ocp.model.dto.OcpGroupBaseDto">
<select id="apiTree" resultType="com.pms.ocp.model.dto.OcpGroupBaseDto" parameterType="com.pms.ocp.model.vo.OcpApiBaseVo">
select api_group_code,api_group_name as apiName,api_group_pcode,api_group_level from ocp_api_group where is_delete = 0
<if test="apiGroupPcode == null ">
and api_group_pcode is null or api_group_pcode =''
</if>
<if test="apiGroupPcode!=null and apiGroupPcode!=''">
and api_group_pcode = #{apiGroupPcode}
</if>
<if test="apiGroupCompanyCode!=null and apiGroupCompanyCode!=''">
and api_group_company_code =#{apiGroupCompanyCode}
</if>
<if test="apiGroupPromotionType!=null and apiGroupPromotionType!=''">
<if test="apiGroupPromotionType !=null">
and api_group_promotion_type =#{apiGroupPromotionType}
</if>
<if test="apiGroupPcode == null ">
and (api_group_pcode is null or api_group_pcode ='')
</if>
</select>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment