package com.doumee.service.business.impl; import com.alibaba.fastjson.JSONObject; import com.doumee.biz.system.SystemDictDataBiz; import com.doumee.biz.zbom.ZbomZhongTaiService; import com.doumee.biz.zbom.model.zhongtai.ZTCatalogListRequest; import com.doumee.biz.zbom.model.zhongtai.ZTConstants; import com.doumee.biz.zbom.model.zhongtai.ZTContentListRequest; import com.doumee.biz.zbom.model.zhongtai.response.*; import com.doumee.core.constants.ResponseStatus; import com.doumee.core.exception.BusinessException; import com.doumee.dao.business.IamInterfaceLogMapper; import com.doumee.dao.business.MemberMapper; import com.doumee.service.business.GetZhongTaiDataService; import org.apache.commons.lang3.StringUtils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import java.util.List; import java.util.Objects; /** * Created by IntelliJ IDEA. * * @Author : Rk * @create 2024/7/15 14:12 */ @Service public class GetZhongTaiDataServiceImpl implements GetZhongTaiDataService { @Autowired private ZbomZhongTaiService zbomZhongTaiService; @Autowired private MemberMapper memberMapper; @Autowired private SystemDictDataBiz systemDictDataBiz; @Override public List getCatalogList(ZTCatalogListRequest ztCatalogListRequest){ if(Objects.isNull(ztCatalogListRequest) || StringUtils.isBlank(ztCatalogListRequest.getCatalogCode())){ throw new BusinessException(ResponseStatus.BAD_REQUEST); } if(ztCatalogListRequest.getCatalogCode().equals(ZTConstants.CatalogCode.ZHISHUO_ZHUANGXIU) ||ztCatalogListRequest.getCatalogCode().equals(ZTConstants.CatalogCode.CHANPING) ||ztCatalogListRequest.getCatalogCode().equals(ZTConstants.CatalogCode.ZIXUN) ||ztCatalogListRequest.getCatalogCode().equals(ZTConstants.CatalogCode.QW_CASE)){ throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"分类信息错误"); } return zbomZhongTaiService.getCatalogList(ztCatalogListRequest); } @Override public List getCataLogTagList(ZTCatalogListRequest ztCatalogListRequest){ if(Objects.isNull(ztCatalogListRequest) || StringUtils.isBlank(ztCatalogListRequest.getCatalogCode())){ throw new BusinessException(ResponseStatus.BAD_REQUEST); } if(ztCatalogListRequest.getCatalogCode().equals(ZTConstants.CatalogCode.ZHISHUO_ZHUANGXIU) ||ztCatalogListRequest.getCatalogCode().equals(ZTConstants.CatalogCode.CHANPING) ||ztCatalogListRequest.getCatalogCode().equals(ZTConstants.CatalogCode.ZIXUN) ||ztCatalogListRequest.getCatalogCode().equals(ZTConstants.CatalogCode.QW_CASE)){ throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"分类信息错误"); } return zbomZhongTaiService.getTagList(ztCatalogListRequest); } }