fe97f982 张雷

Merge remote-tracking branch 'origin/master' into master

2 个父辈 474413d8 4fa12e3d
......@@ -73,7 +73,7 @@ public class TestMetricInfoController {
JdbcTemplate masterDB = (JdbcTemplate)SpringContextUtils.getBean("master");
String metricInfoSql = "select ei.equipment_name , t.metric_express1 'gzExpress' , t.metric_express2 'yxExpress' ,t.metric_express3 'tzExpress' from sys_monitor_metric_info t ";
metricInfoSql += " left join equipment_info ei on ei.id = t.equipment_code ";
metricInfoSql += " where t.metric_type = 1 and t.depart_id = '"+departId+"' and t.equipment_code > 0 " ;
metricInfoSql += " where t.metric_type = 1 and t.depart_id = '"+departId+"' and t.equipment_code > 0 and ei.equipment_level = '6bf727eb7e7cca6a95c694dab0036b2c'" ;
List<MetricInfoVO> metricInfoVOList = masterDB.query(metricInfoSql,new BeanPropertyRowMapper<MetricInfoVO>(MetricInfoVO.class));
//StringBuffer fields= new StringBuffer();
......
......@@ -8,13 +8,7 @@ import java.util.Map;
import org.apache.commons.lang.StringUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.PutMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.bind.annotation.*;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
......@@ -125,4 +119,26 @@ public class EquipmentMaintainTaskController {
return result;
}
/**
* <pre>
* 通过id删除
* </pre>
* @param id
* @return
* @author 开发者姓名, 开发时间
* @Description: TODO(这里描述这个方法的需求变更情况)
*/
@AutoLog(value = "维保任务-通过id删除")
@ApiOperation(value="维保任务-通过id删除", notes="维保任务-通过id删除")
@DeleteMapping(value = "/delete")
public Result<?> delete(@RequestParam(name="id",required=true) String id) {
try {
iEquipmentMaintainTaskService.removeById(id);
} catch (Exception e) {
log.error("删除失败",e.getMessage());
return Result.error("删除失败!");
}
return Result.ok("删除成功!");
}
}
......
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!