You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
170 lines
4.6 KiB
170 lines
4.6 KiB
package com.letian.modules.base.controller;
|
|
|
|
import com.letian.modules.base.entity.DelNotifyBoardData;
|
|
import com.letian.modules.base.entity.NewScheduledData;
|
|
import com.letian.modules.base.entity.ScheduleListBoardData;
|
|
import com.letian.modules.base.service.BoardService;
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
import org.springframework.stereotype.Controller;
|
|
import org.springframework.web.bind.annotation.*;
|
|
|
|
import java.util.HashMap;
|
|
import java.util.List;
|
|
import java.util.Map;
|
|
|
|
@Controller
|
|
@RequestMapping(value = "/board")
|
|
public class BoardController {
|
|
|
|
@Autowired
|
|
private BoardService boardService;
|
|
|
|
/**
|
|
*@Description 获取看板当前时间
|
|
* @Title getTime
|
|
* @author rq
|
|
* @date 2020/11/17 15:39
|
|
* @return {@link Object}
|
|
* @throw
|
|
*/
|
|
@PostMapping("/getTime")
|
|
@ResponseBody
|
|
public Object getTime() {
|
|
Map<String, Object> map = new HashMap<>();
|
|
try {
|
|
String date = boardService.getTime();
|
|
map.put("success", true);
|
|
map.put("rows", date);
|
|
} catch (Exception e) {
|
|
map.put("msg", e.getMessage());
|
|
}
|
|
return map;
|
|
}
|
|
|
|
/**
|
|
* @Title getReportAbnormalData
|
|
* @Description TODO
|
|
* @author rq
|
|
* @date 2021/7/21 14:48
|
|
* @return {@link Object}
|
|
*/
|
|
|
|
@PostMapping("/kanKanYouMeiYouDiaoXian")
|
|
@ResponseBody
|
|
public Object kanKanYouMeiYouDiaoXian() {
|
|
Map<String, Object> map = new HashMap<>();
|
|
try {
|
|
map.put("success", true);
|
|
} catch (Exception e) {
|
|
map.put("success", false);
|
|
map.put("msg", e.getMessage());
|
|
}
|
|
return map;
|
|
}
|
|
|
|
/**
|
|
*@Description 获取派工单完成情况看板信息
|
|
* @Title getNewScheduledTableData
|
|
* @author rq
|
|
* @date 2020/11/17 15:39
|
|
* @return {@link Object}
|
|
* @throw
|
|
*/
|
|
@GetMapping("/getNewScheduledTableData/{number}")
|
|
@ResponseBody
|
|
public Object getNewScheduledTableData(@PathVariable("number") int number){
|
|
Map<String, Object> map = new HashMap<>();
|
|
try {
|
|
map = boardService.getNewScheduledTableData(number);
|
|
map.put("success", true);
|
|
} catch (Exception e) {
|
|
map.put("success", false);
|
|
map.put("msg", e.getMessage());
|
|
}
|
|
return map;
|
|
}
|
|
|
|
/**
|
|
*@Description 获取看板数据刷新时间
|
|
* @Title getJumpTime
|
|
* @author rq
|
|
* @date 2020/11/17 15:39
|
|
* @return {@link Object}
|
|
* @throw
|
|
*/
|
|
// @PostMapping("/getRefreshTime")
|
|
// @ResponseBody
|
|
@GetMapping("/getRefreshTime/{boardName}")
|
|
@ResponseBody
|
|
public Object getRefreshTime(@PathVariable("boardName") String boardName) {
|
|
Map<String, Object> map = new HashMap<>();
|
|
try {
|
|
String date = boardService.getRefreshTime(boardName);
|
|
map.put("success", true);
|
|
map.put("rows", date);
|
|
} catch (Exception e) {
|
|
map.put("msg", e.getMessage());
|
|
}
|
|
return map;
|
|
}
|
|
|
|
|
|
/**
|
|
*@Description 获取派工单完成情况看板信息
|
|
* @Title getNewScheduledData
|
|
* @author rq
|
|
* @date 2020/11/17 15:39
|
|
* @return {@link Object}
|
|
* @throw
|
|
*/
|
|
@PostMapping("/getScheduledData")
|
|
@ResponseBody
|
|
public Object getScheduledData() {
|
|
Map<String, Object> map = new HashMap<>();
|
|
try {
|
|
map= boardService.getNewScheduledData();
|
|
|
|
map.put("success", true);
|
|
|
|
} catch (Exception e) {
|
|
map.put("msg", e.getMessage());
|
|
}
|
|
return map;
|
|
}
|
|
|
|
/**
|
|
* @Description 下周发货看板
|
|
* @Title nextWeekShipmentBoardData
|
|
* @param
|
|
* @author rq
|
|
* @date 2021/8/13 14:08
|
|
* @return double
|
|
* @throw
|
|
*/
|
|
@PostMapping("/getDelNotifyBoardData")
|
|
@ResponseBody
|
|
public Object getDelNotifyBoardData(@RequestBody DelNotifyBoardData inData){
|
|
Map<String, Object> map =boardService.getDelNotifyBoardData(inData.getNumber());
|
|
map.put("code",200);
|
|
map.put("success", true);
|
|
return map;
|
|
}
|
|
|
|
/**
|
|
* @Description 派工单明细看板
|
|
* @Title nextWeekShipmentBoardData
|
|
* @param
|
|
* @author rq
|
|
* @date 2021/8/13 14:08
|
|
* @return double
|
|
* @throw
|
|
*/
|
|
@PostMapping("/getScheduleListData")
|
|
@ResponseBody
|
|
public Object getScheduleListData(@RequestBody ScheduleListBoardData inData){
|
|
Map<String, Object> map =boardService.getScheduleListData(inData.getNumber());
|
|
map.put("code",200);
|
|
map.put("success", true);
|
|
return map;
|
|
}
|
|
}
|