报工增加报废数量

master
philip 4 years ago
parent bf4f86e8ef
commit 47eb1a11d6

@ -4,6 +4,7 @@ import com.foreverwin.mesnac.meapi.dto.SfcDto;
import com.foreverwin.mesnac.meapi.dto.WorkCenterDto; import com.foreverwin.mesnac.meapi.dto.WorkCenterDto;
import com.foreverwin.mesnac.meapi.model.Sfc; import com.foreverwin.mesnac.meapi.model.Sfc;
import java.math.BigDecimal;
import java.util.Map; import java.util.Map;
public interface PodTemplateService { public interface PodTemplateService {
@ -17,6 +18,8 @@ public interface PodTemplateService {
void sfcComplete(Map<String, Object> map); void sfcComplete(Map<String, Object> map);
void sendErp(String sfc, String stepId, BigDecimal qty, BigDecimal scrapQty);
SfcDto getInfoBySfc(Sfc sfc); SfcDto getInfoBySfc(Sfc sfc);
} }

@ -303,7 +303,7 @@ public class PodTemplateServiceImpl implements PodTemplateService {
inspectionTaskService.createTask(paramMap); inspectionTaskService.createTask(paramMap);
} }
//报工 //报工
sendErp(sfc, stepId, qty); sendErp(sfc, stepId, qty,BigDecimal.ZERO);
} catch (Exception e) { } catch (Exception e) {
ExceptionUtil.throwException(e); ExceptionUtil.throwException(e);
} }
@ -399,8 +399,8 @@ public class PodTemplateServiceImpl implements PodTemplateService {
assemblyServiceInterface.assembleByComponents(assembleComponentsRequest); assemblyServiceInterface.assembleByComponents(assembleComponentsRequest);
} }
@Override
void sendErp(String sfc, String stepId, BigDecimal qty) { public void sendErp(String sfc, String stepId, BigDecimal qty ,BigDecimal scrapQty) {
Sfc sfcServiceById = sfcService.getById(HandleEnum.SFC.getHandle(CommonMethods.getSite(),sfc)); Sfc sfcServiceById = sfcService.getById(HandleEnum.SFC.getHandle(CommonMethods.getSite(),sfc));
String shopOrderBo = sfcServiceById.getShopOrderBo(); String shopOrderBo = sfcServiceById.getShopOrderBo();
String shopOrder = StringUtil.trimHandle(shopOrderBo); String shopOrder = StringUtil.trimHandle(shopOrderBo);
@ -416,7 +416,7 @@ public class PodTemplateServiceImpl implements PodTemplateService {
//良品数量 //良品数量
struIn.setLmnga(qty); struIn.setLmnga(qty);
//报废数量 //报废数量
struIn.setXmnga(BigDecimal.ZERO); struIn.setXmnga(scrapQty);
//机器工时 //机器工时
struIn.setIsm01(BigDecimal.ZERO); struIn.setIsm01(BigDecimal.ZERO);
//人工工时 //人工工时

Loading…
Cancel
Save