| | |
| | | package com.mes.rawglassstation.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper; |
| | | import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.mes.rawglassdetails.entity.RawGlassStorageDetails; |
| | | import com.mes.rawglassstation.entity.RawGlassStorageStation; |
| | | import com.mes.rawglassstation.mapper.RawGlassStorageStationMapper; |
| | | import com.mes.rawglassstation.service.RawGlassStorageStationService; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * <p> |
| | | * 服务实现类 |
| | | * </p> |
| | | * |
| | | * @author wf |
| | | * @since 2024-09-10 |
| | | * @author system |
| | | * @since 2024-07-09 14:51:27 |
| | | */ |
| | | @Service |
| | | public abstract class RawGlassStorageStationServiceImpl extends ServiceImpl<RawGlassStorageStationMapper, RawGlassStorageStation> implements RawGlassStorageStationService { |
| | | public List<RawGlassStorageStation> selectDetails() { |
| | | @Slf4j |
| | | public class RawGlassStorageStationServiceImpl extends ServiceImpl<RawGlassStorageStationMapper, RawGlassStorageStation> implements RawGlassStorageStationService { |
| | | @Override |
| | | public List<RawGlassStorageStation> selectStations() { |
| | | return list(); |
| | | } |
| | | @Override |
| | |
| | | public boolean deleteRawGlassStorageStation(String device_id) { |
| | | QueryWrapper<RawGlassStorageStation> queryWrapper = new QueryWrapper<>(); |
| | | queryWrapper.eq("device_id", device_id); |
| | | return remove(queryWrapper); |
| | | return remove(queryWrapper); |
| | | } |
| | | |
| | | @Override |
| | | public boolean insertRawGlassStorageStation(RawGlassStorageStation rw) { |
| | | return this.save(rw); |
| | | } |
| | | } |
| | | |
| | | @Override |
| | | public List<RawGlassStorageDetails> listRawGlassDetails() { |
| | | return baseMapper.listRawGlassDetails(); |
| | | } |
| | | |
| | | @Override |
| | | public boolean updateSlotState(Integer slot, Integer enableState) { |
| | | return update( |
| | | new LambdaUpdateWrapper<RawGlassStorageStation>() |
| | | .set(RawGlassStorageStation::getEnableState, enableState) |
| | | .eq(RawGlassStorageStation::getSlot, slot)); |
| | | } |
| | | } |