Commit bff77d38 authored by chenzhao's avatar chenzhao

增加筛选条件接口

parent d4f52280
......@@ -15,6 +15,7 @@ import org.typroject.tyboot.core.restful.utils.ResponseModel;
import javax.servlet.http.HttpServletRequest;
import java.util.List;
import java.util.Map;
/**
*
......@@ -112,4 +113,19 @@ public class IdxBizFanPointProcessVariableClassificationController extends BaseC
public ResponseModel<List<IdxBizFanPointProcessVariableClassificationDto>> selectForList() {
return ResponseHelper.buildResponse(idxBizFanPointProcessVariableClassificationServiceImpl.queryForIdxBizFanPointProcessVariableClassificationList());
}
/**
* 列表全部数据查询
*
* @return
*/
@TycloudOperation(ApiLevel = UserType.AGENCY,needAuth = false)
@ApiOperation(httpMethod = "GET",value = "列表全部数据查询", notes = "列表全部数据查询")
@GetMapping(value = "/selectParams")
public ResponseModel<List<Map<String,Object>>> selectParams(String tableName,String column) {
return ResponseHelper.buildResponse(idxBizFanPointProcessVariableClassificationServiceImpl.selectParams(column,tableName));
}
}
......@@ -3,8 +3,10 @@ package com.yeejoin.amos.boot.module.jxiop.biz.mapper2;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.yeejoin.amos.boot.module.jxiop.biz.dto.IdxBizFanPointProcessVariableClassificationDto;
import com.yeejoin.amos.boot.module.jxiop.biz.entity.IdxBizFanPointProcessVariableClassification;
import org.apache.ibatis.annotations.Select;
import java.util.List;
import java.util.Map;
/**
* Mapper 接口
......@@ -15,5 +17,8 @@ import java.util.List;
public interface IdxBizFanPointProcessVariableClassificationMapper extends BaseMapper<IdxBizFanPointProcessVariableClassification> {
List<IdxBizFanPointProcessVariableClassificationDto> getInfluxDBData();
List<Map<String,Object>> selectParams(String tableName,String column);
List<String> gateWayIdListFan();
}
package com.yeejoin.amos.boot.module.jxiop.biz.service.impl;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.yeejoin.amos.boot.module.jxiop.biz.dto.IdxBizFanPointProcessVariableClassificationDto;
import com.yeejoin.amos.boot.module.jxiop.biz.entity.IdxBizFanPointProcessVariableClassification;
......@@ -9,6 +10,7 @@ import org.springframework.stereotype.Service;
import org.typroject.tyboot.core.rdbms.service.BaseService;
import java.util.List;
import java.util.Map;
/**
* 服务实现类
......@@ -31,4 +33,10 @@ public class IdxBizFanPointProcessVariableClassificationServiceImpl extends Base
public List<IdxBizFanPointProcessVariableClassificationDto> queryForIdxBizFanPointProcessVariableClassificationList() {
return this.queryForList("" , false);
}
public List<Map<String,Object>> selectParams(String column, String tableName) {
return this.getBaseMapper(). selectParams(tableName,column);
}
}
\ No newline at end of file
......@@ -87,4 +87,10 @@
<select id="gateWayIdListFan" resultType="java.lang.String">
select GATEWAY_ID from idx_biz_fan_point_process_variable_classification group by GATEWAY_ID;
</select>
<select id="selectParams" resultType="map">
select ${column} as text from ${tableName} group by ${column};
</select>
</mapper>
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