提交 9f035a60 作者: panda

开发云享飞作业服务订单-服务接口开放

上级 994a0ba8
......@@ -13,9 +13,11 @@ import com.mmc.pms.service.BackstageTaskService;
import io.swagger.annotations.*;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.*;
import springfox.documentation.annotations.ApiIgnore;
import javax.annotation.Resource;
import javax.servlet.http.HttpServletRequest;
import java.util.List;
/**
* @Author LW
......@@ -72,4 +74,12 @@ public class BackstageTaskServiceController extends BaseController {
public ResultBody<WorkServiceDTO> queryWorkServiceList(@Validated(Page.class) @RequestBody ServiceQO param, HttpServletRequest request) {
return ResultBody.success(backstageTaskService.queryWorkServiceList(param,request));
}
@ApiOperation(value = "远程查询作业服务")
@ApiResponses({@ApiResponse(code = 200, message = "OK", response = ServiceDTO.class)})
@PostMapping("feignQueryWorkServiceListById")
@ApiIgnore
public List<ServiceDTO> feignQueryWorkServiceListById(@RequestBody List<Integer> ids) {
return backstageTaskService.feignQueryWorkServiceListById(ids);
}
}
......@@ -2,6 +2,7 @@ package com.mmc.pms.dao;
import com.mmc.pms.entity.ServiceDO;
import com.mmc.pms.model.qo.ServiceQO;
import com.mmc.pms.model.work.dto.ServiceDTO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
......@@ -29,4 +30,6 @@ public interface BackstageTaskServiceDao {
int conditionCount(@Param("param") ServiceQO param, @Param("categoriesIds") List<Integer> categoriesIds, @Param("userIds") List<Integer> userIds);
List<ServiceDO> queryPageByLimit(@Param("param") ServiceQO param,@Param("categoriesIds") List<Integer> categoriesIds, @Param("userIds") List<Integer> userIds);
List<ServiceDTO> QueryWorkServiceListById(@Param("ids") List<Integer> ids);
}
......@@ -7,6 +7,7 @@ import com.mmc.pms.model.work.vo.ServiceVO;
import com.mmc.pms.page.PageResult;
import javax.servlet.http.HttpServletRequest;
import java.util.List;
/**
* @Author LW
......@@ -25,4 +26,6 @@ public interface BackstageTaskService {
PageResult queryServiceManagerList(ServiceQO param, Integer userAccountId);
PageResult queryWorkServiceList(ServiceQO param, HttpServletRequest request);
List<ServiceDTO> feignQueryWorkServiceListById(List<Integer> ids);
}
......@@ -158,6 +158,11 @@ public class BackstageTaskServiceImpl implements BackstageTaskService {
return PageResult.buildPage(pageNo, param.getPageSize(), count, workServiceDTOList);
}
@Override
public List<ServiceDTO> feignQueryWorkServiceListById(List<Integer> ids) {
return backstageTaskServiceDao.QueryWorkServiceListById(ids);
}
private List<WorkServiceDTO> getWorkServiceDTOS(List<ServiceDO> pageList) {
// 用户暂时无关联公司数据,先用假数据展示
String companyName = "浙江科比特创新科技有限公司";
......
......@@ -202,4 +202,26 @@
order by create_time desc
limit #{param.pageNo}, #{param.pageSize}
</select>
<select id="QueryWorkServiceListById" resultType="com.mmc.pms.model.work.dto.ServiceDTO">
select id,
service_name,
application_id,
industry_id,
display_state,
cover_plan,
share_card,
video,
service_introduction,
create_time,
update_time,
account_id
from service
where
is_deleted = 0
<if test="ids != null">
<foreach collection="ids" item="id" open="and id in (" close=")" separator=",">
#{id}
</foreach>
</if>
</select>
</mapper>
\ No newline at end of file
......@@ -14,5 +14,6 @@ data-filter:
- /pms/product/mall/getPageHomeCategories
- /pms/backstage/work/queryWorkServiceList
- /pms/backstage/work/queryWorkService
- /pms/backstage/work/feignQueryWorkServiceListById
- /pms/webDevice/getSecondDistrictInfo
- /pms/webDevice/ad
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论