ShelfService.java
919 Bytes
package com.huaheng.pc.task.agvTask.service;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.huaheng.pc.task.agvTask.domain.Shelf;
import com.huaheng.pc.task.agvTask.mapper.ShelfMapper;
import org.springframework.stereotype.Service;
/*
* AGVTask任务服务层
* */
@Service
public class ShelfService extends ServiceImpl<ShelfMapper, Shelf>{
public Shelf getByShelfNo(String shelfNo){
Shelf one = this.getOne(new LambdaQueryWrapper<Shelf>()
.eq(Shelf::getShelfNo, shelfNo)
.last("LIMIT 1"));
return one;
}
public Shelf getByPositionName(String positionName){
Shelf one = this.getOne(new LambdaQueryWrapper<Shelf>()
.eq(Shelf::getPositionName, positionName)
.last("LIMIT 1"));
return one;
}
}