wu
2023-09-08 9020f58f9c945d8a99493eb4da2253b6937909fe
springboot-vue3/src/main/java/com/example/springboot/controller/HomeController.java
@@ -10,6 +10,7 @@
import com.example.springboot.service.HomeService;
import com.example.springboot.common.Result;
import com.example.springboot.entity.StorageCage;
import com.example.springboot.entity.alarmmg;
import org.springframework.web.bind.annotation.*;
@@ -44,6 +45,7 @@
        return Result.success(map);
    }
    
    @GetMapping("/loadinout")    
    public Result selectinout(Integer types){
        List<StorageCage> storageCageinout=homeMapper.selectinout(types);
@@ -65,4 +67,40 @@
        }
        return Result.success(map);
    }
    @GetMapping("/Addglassid")
    public Result Addglassid(Integer glassid){
        Map<String, Object> map = new HashMap<>();
        short taskno=homeMapper.SelectOutTask();
        if(taskno>0){
            map.put("message2","500");
        }else{
            map.put("message2","200");
            //调用伍上片函数
        }
        return Result.success(map);
    }
    @GetMapping("/UpdateTask")
    public Result UpdateTask(Integer types,Integer shelfrack){
        Map<String, Object> map = new HashMap<>();
        homeMapper.UpdateTask(types,shelfrack);
        if(types==0){
            homeMapper.UpdateCageTask1(shelfrack);
        }else{
            homeMapper.UpdateCageTask2(shelfrack);
        }
        map.put("message3","200");
        return Result.success(map);
    }
    @GetMapping("/SelectAlarmmgInfo")
    public Result SelectAlarmmgInfo(){
        List<alarmmg> alarmmg=homeMapper.SelectAlarmmgInfo();
        Map<String, Object> map = new HashMap<>();
        map.put("alarmmg",alarmmg);
        return Result.success(map);
    }
}