大屏接口编写

duhanyu
dongdingding 1 year ago
parent b06f38a85f
commit e636a738a2

@ -122,4 +122,17 @@ public class ScreenController extends BaseController {
public AjaxResult screenReportMap() {
return AjaxResult.success(screenService.getScreenReportMap());
}
/**
*
*/
@ApiOperation(value = "部门转办", response = ScreenDepartmentResponse.class)
@GetMapping("/screendepartment")
public AjaxResult screenDepartment() {
return AjaxResult.success(screenService.getScreenDepartment());
}
}

@ -0,0 +1,26 @@
package com.ruoyi.tcZz.domain.reponse;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
/**
*
*/
@Data
@ApiModel("部门转办")
public class ScreenDepartmentResponse {
/**
*
*/
@ApiModelProperty("数量")
private Integer count;
/**
*
*/
@ApiModelProperty("部门")
private String depName;
}

@ -82,4 +82,14 @@ public interface ScreenMapper {
* @return
*/
ScreenReportMapResponse getScreenReportMap();
/**
*
*
* @return
*/
ScreenDepartmentResponse getScreenDepartment();
}

@ -80,4 +80,12 @@ public interface ScreenService {
* @return
*/
ScreenReportMapResponse getScreenReportMap();
/**
*
*
* @return
*/
ScreenDepartmentResponse getScreenDepartment();
}

@ -64,4 +64,9 @@ public class ScreenServiceImpl implements ScreenService {
public ScreenReportMapResponse getScreenReportMap() {
return screenMapper.getScreenReportMap();
}
@Override
public ScreenDepartmentResponse getScreenDepartment() {
return screenMapper.getScreenDepartment();
}
}

@ -60,4 +60,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
FROM
tc_jbmap;
</select>
<select id="getScreenDepartment" resultType="com.ruoyi.tcZz.domain.reponse.ScreenDepartmentResponse">
select count(*)as count ,dep_name as depName from tc_zbxq group by dep_name
</select>
</mapper>
Loading…
Cancel
Save