| | |
| | | public MesReturn synMatInfo(@RequestHeader(required = false) String appkey,@RequestBody MesMatInfo param,HttpServletRequest request){ |
| | | auth(appkey, param, request); |
| | | MesReturn mesReturn = new MesReturn(); |
| | | if (mesService.synMatInfo(param) == -2) { |
| | | mesReturn.setSuccess("2"); |
| | | mesReturn.setMessage("该物料已存在,无法修改"); |
| | | return mesReturn; |
| | | } |
| | | mesReturn.setSuccess(mesService.synMatInfo(param) == 1 ? "1" : "2"); |
| | | return mesReturn; |
| | | } |
| | |
| | | import com.zy.asrs.entity.param.CombParam; |
| | | import com.zy.asrs.entity.rcs.*; |
| | | import com.zy.asrs.mapper.AgvInfoMapper; |
| | | import com.zy.asrs.mapper.LocDetlMapper; |
| | | import com.zy.asrs.service.*; |
| | | import com.zy.common.model.enums.WorkNoType; |
| | | import com.zy.common.service.CommonService; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.beans.factory.annotation.Value; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | |
| | | private CommonService commonService; |
| | | @Resource |
| | | private AgvInfoMapper agvInfoMapper; |
| | | @Autowired |
| | | private LocDetlMapper locDetlMapper; |
| | | |
| | | |
| | | // region MES接口 |
| | |
| | | public int synMatInfo(MesMatInfo mesMatInfo) { |
| | | |
| | | try { |
| | | List<LocDetl> locDetls = locDetlMapper.selectList(new EntityWrapper<LocDetl>() |
| | | .eq("matnr", mesMatInfo.getItem_no())); |
| | | if (locDetls.size() > 0) { |
| | | return -2; |
| | | } |
| | | // 规则定义:默认第3层为同步的物料类型 |
| | | long secondPath = 2; |
| | | String secondParentName = WMS_CURRENT_NAME; |
| | |
| | | } |
| | | |
| | | var matCols = [ |
| | | {field: 'matnr', align: 'center',title: '商品编号(品号)', width: 180} |
| | | {field: 'matnr', align: 'left',title: '商品编号(品号)', width: 180} |
| | | // {field: 'id', align: 'center',title: 'ID'} |
| | | // ,{field: 'uuid', align: 'center',title: '编号'} |
| | | ,{field: 'maktx', align: 'center',title: '商品名称(品名)', width: 200} |
| | | ,{field: 'specs', align: 'center',title: '规格'} |
| | | ,{field: 'deadTime', align: 'center',title: '寿命'} |
| | | ,{field: 'model', align: 'center',title: '代码', hide: true} |
| | | ,{field: 'color', align: 'center',title: '颜色', hide: true} |
| | | ,{field: 'brand', align: 'center',title: '品牌', hide: true} |
| | |
| | | ,{field: 'supp', align: 'center',title: '供应商', hide: true} |
| | | ,{field: 'suppCode', align: 'center',title: '供应商编码', hide: true} |
| | | ,{field: 'beBatch$', align: 'center',title: '是否批次', hide: true} |
| | | ,{field: 'deadTime', align: 'center',title: '保质期', hide: true} |
| | | ,{field: 'deadWarn', align: 'center',title: '预警天数', hide: true} |
| | | ,{field: 'source$', align: 'center',title: '制购', hide: true} |
| | | ,{field: 'check$', align: 'center',title: '要求检验', hide: true} |