| | |
| | | package com.zy.asrs.service; |
| | | |
| | | import com.baomidou.mybatisplus.service.IService; |
| | | import com.zy.asrs.entity.WrkMast; |
| | | import com.zy.asrs.entity.WrkMastLog; |
| | | |
| | | public interface WrkMastLogService extends IService<WrkMastLog> { |
| | | |
| | | boolean save(Integer workNo); |
| | | |
| | | boolean saveLog(WrkMast workNo); |
| | | } |
| | |
| | | package com.zy.asrs.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.service.impl.ServiceImpl; |
| | | import com.zy.asrs.entity.WrkMast; |
| | | import com.zy.asrs.entity.WrkMastLog; |
| | | import com.zy.asrs.mapper.WrkMastLogMapper; |
| | | import com.zy.asrs.service.WrkMastLogService; |
| | | import com.zy.common.utils.Synchro; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import java.util.Date; |
| | | |
| | | @Service("wrkMastLogService") |
| | | public class WrkMastLogServiceImpl extends ServiceImpl<WrkMastLogMapper, WrkMastLog> implements WrkMastLogService { |
| | |
| | | return this.baseMapper.save(workNo) > 0; |
| | | } |
| | | |
| | | @Override |
| | | public boolean saveLog(WrkMast workNo) { |
| | | WrkMastLog wrkMastLog=new WrkMastLog(); |
| | | Synchro.Copy(workNo,wrkMastLog); |
| | | wrkMastLog.setModiTime(new Date()); |
| | | return this.baseMapper.insert(wrkMastLog)>0; |
| | | } |
| | | |
| | | } |
| | |
| | | } |
| | | } |
| | | } |
| | | |
| | | // 保存工作主档历史档 |
| | | if (!wrkMastLogService.save(wrkMast.getWrkNo())) { |
| | | if (!wrkMastLogService.saveLog(wrkMast)) { |
| | | exceptionHandle("保存工作历史档[workNo={0}]失败", wrkMast.getWrkNo()); |
| | | } |
| | | |
| | | // // 保存工作主档历史档 |
| | | // if (!wrkMastLogService.save(wrkMast.getWrkNo())) { |
| | | // exceptionHandle("保存工作历史档[workNo={0}]失败", wrkMast.getWrkNo()); |
| | | // } |
| | | // 删除工作主档 |
| | | if (!wrkMastService.deleteById(wrkMast)) { |
| | | exceptionHandle("删除工作主档[workNo={0}]失败", wrkMast.getWrkNo()); |
| | |
| | | // ,{field: 'crnEndTime$', align: 'center',title: '堆垛机停止时间'} |
| | | // ,{field: 'plcStrTime$', align: 'center',title: '拣料时间'} |
| | | ,{field: 'modiUser$', align: 'center',title: '修改人员', hide:true} |
| | | ,{field: 'modiTime$', align: 'center',title: '修改时间', hide:true} |
| | | ,{field: 'modiTime$', align: 'center',title: '修改时间'} |
| | | // ,{field: 'appeUser$', align: 'center',title: '创建者',event: 'appeUser', style: 'cursor:pointer'} |
| | | // ,{field: 'appeTime$', align: 'center',title: '添加时间'} |
| | | ,{field: 'barcode', align: 'center',title: '条码'} |