| | |
| | | damage.setLine(deviceId); |
| | | damage.setType(type); |
| | | damage.setRemark(remark); |
| | | damage.setStatus(0); |
| | | damage.setStatus(1); |
| | | this.insertDamage(damage); |
| | | } |
| | | |
| | |
| | | glassInfoSelectWrapper.eq(GlassInfo::getGlassId, damage.getGlassId()); |
| | | GlassInfo glassInfo = glassInfoMapper.selectOne(glassInfoSelectWrapper); |
| | | BeanUtils.copyProperties(glassInfo, damage); |
| | | |
| | | damage.setStatus(1); |
| | | LambdaQueryWrapper<WorkAssignment> workAssignmentSelectWrapper = new LambdaQueryWrapper<>(); |
| | | workAssignmentSelectWrapper |
| | | .eq(WorkAssignment::getLine, damage.getLine()) |
| | |
| | | package com.mes.glassinfo.entity; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | |
| | | /** |
| | | * 状态 |
| | | */ |
| | | @TableField(exist = false) |
| | | private Integer status; |
| | | |
| | | |
| | |
| | | public List<TemperingGlassInfo> selectOutGlass() { |
| | | //获取出炉中的玻璃信息 |
| | | QueryWrapper<TemperingGlassInfo> wrap = new QueryWrapper<>(); |
| | | wrap.select("Top 1 *").eq("state", 3); |
| | | wrap.select("Top 1 *").eq("state", 4) |
| | | .orderByDesc("id"); |
| | | TemperingGlassInfo glass = temperingMapper.selectOne(wrap); |
| | | //根据工程号和版图获取数据 |
| | | if (glass != null) { |
| | |
| | | //获取过旋转台最大的钢化版图id |
| | | QueryWrapper<TemperingGlassInfo> wapper = new QueryWrapper<>(); |
| | | wapper.select("Top 1 *").eq("state", 4) |
| | | .orderByDesc("tempering_layout_id,engineer_id"); |
| | | .orderByDesc("id"); |
| | | //根据最大的版图id显示钢化后的版图信息 |
| | | TemperingGlassInfo glassinfo = temperingMapper.selectOne(wapper); |
| | | if (glassinfo == null) { |
| | |
| | | temperingGlassInfo.setState(damage.getStatus()); |
| | | temperingGlassInfo.setGlassId(damage.getGlassId()); |
| | | int result=temperingGlassInfoService.updateTemperingState(temperingGlassInfo); |
| | | // if(damage.getStatus()>5) { |
| | | // damage.setType(damage.getStatus()); |
| | | // damage.setStatus(1); |
| | | // damageService.insertDamage(damage); |
| | | // } |
| | | if (damage.getStatus() > 5) { |
| | | damageService.autoSubmitReport(damage.getGlassId(), damage.getLine() |
| | | , damage.getWorkingProcedure(), "钢化炉", damage.getStatus()); |
| | | } |
| | | return Result.build(200, "破损成功", result); |
| | | } |
| | | |