增加 看板接口
parent
d020b61f86
commit
6dfea314d7
@ -1,25 +1,50 @@
|
||||
package com.ruoyi.api.controller;
|
||||
|
||||
import com.ruoyi.api.domain.BroadCountNumber;
|
||||
import com.ruoyi.api.service.impl.BroadApiService;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.manage.domain.BaseStore;
|
||||
import com.ruoyi.manage.domain.LedgerRfid;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author wanghao
|
||||
* @date 2024/3/1 13:29
|
||||
*/
|
||||
@RestController
|
||||
@Controller
|
||||
@RequestMapping("/api")
|
||||
public class BroadApiController {
|
||||
|
||||
@Autowired
|
||||
private BroadApiService service;
|
||||
|
||||
|
||||
@PostMapping("/selectCountNumber")
|
||||
private String selectCountNumber(){
|
||||
return service.selectCountNumber();
|
||||
//获取区域
|
||||
@PostMapping("/getArea")
|
||||
@ResponseBody
|
||||
public AjaxResult getArea() {
|
||||
List<BaseStore> list = service.getArea();
|
||||
return AjaxResult.success(list);
|
||||
}
|
||||
//获取统计
|
||||
@PostMapping("/getCountNumberById")
|
||||
@ResponseBody
|
||||
public AjaxResult getCountNumberById(int id) {
|
||||
List<BroadCountNumber> list = service.getCountNumberById(id);
|
||||
|
||||
return AjaxResult.success(list);
|
||||
}
|
||||
//获取详细轮挡
|
||||
@PostMapping("/getLedgerByCode")
|
||||
@ResponseBody
|
||||
public AjaxResult getLedgerByCode(String locationCode){
|
||||
List<LedgerRfid> list=service.getLedgerByCode(locationCode);
|
||||
return AjaxResult.success(list);
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
@ -0,0 +1,33 @@
|
||||
package com.ruoyi.api.domain;
|
||||
|
||||
public class BroadCountNumber {
|
||||
private String areaName;
|
||||
private String locationCode;
|
||||
private int countNumber;
|
||||
|
||||
|
||||
public String getAreaName() {
|
||||
|
||||
return areaName;
|
||||
}
|
||||
|
||||
public void setAreaName(String areaName) {
|
||||
this.areaName = areaName;
|
||||
}
|
||||
|
||||
public String getLocationCode() {
|
||||
return locationCode;
|
||||
}
|
||||
|
||||
public void setLocationCode(String locationCode) {
|
||||
this.locationCode = locationCode;
|
||||
}
|
||||
|
||||
public int getCountNumber() {
|
||||
return countNumber;
|
||||
}
|
||||
|
||||
public void setCountNumber(int countNumber) {
|
||||
this.countNumber = countNumber;
|
||||
}
|
||||
}
|
@ -1,12 +1,23 @@
|
||||
package com.ruoyi.api.mapper;
|
||||
|
||||
import com.ruoyi.api.domain.BroadCountNumber;
|
||||
import com.ruoyi.manage.domain.BaseStore;
|
||||
import com.ruoyi.manage.domain.LedgerRfid;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author wanghao
|
||||
* @date 2024/3/1 13:30
|
||||
*/
|
||||
@Repository
|
||||
public interface BroadApiMapper {
|
||||
String selectCountNumber();
|
||||
|
||||
|
||||
List<BaseStore> getArea();
|
||||
|
||||
List<BroadCountNumber> getCountNumberById(int id);
|
||||
|
||||
List<LedgerRfid> getLedgerByCode(String locationCode);
|
||||
}
|
||||
|
Loading…
Reference in New Issue