物料用量计算
This commit is contained in:
parent
5bece0b46d
commit
d73f450488
@ -232,6 +232,7 @@ public class ProductProcessServiceImpl extends AbstractService<ProductProcess, I
|
||||
processMaterials.setStatus(ProduceManageConstant.STATUS_AVAILABLE);
|
||||
processMaterials.setProcessId(process.getId());
|
||||
processMaterials.setCode(ProduceManagePublicMethod.creatUniqueCode("SCWL"));
|
||||
processMaterials.setDosage(productProcess.getPiNum()*processMaterials.getDosage());
|
||||
processMaterials.setCompanyId(currentUser.getCompanyId());
|
||||
processMaterialsList.add(processMaterials);
|
||||
}
|
||||
|
@ -121,33 +121,6 @@ public class MtAloneProcessController {
|
||||
return ResultGenerator.genSuccessResult(pageInfo);
|
||||
}
|
||||
|
||||
/**
|
||||
* hy正在用
|
||||
* 点击加工处理页面中工序列表最后一列查看或处理按钮,
|
||||
* 由工序id获取该工序详情及包含的物料信息
|
||||
* @param params
|
||||
* @param currentUser
|
||||
* @return
|
||||
*/
|
||||
//@ApiOperation(value = "根据工序id查询工序详情及物料信息", notes = "根据工序id查询工序详情及物料信息")
|
||||
//@ApiImplicitParams({
|
||||
// @ApiImplicitParam(name = "processId", value = "工序id", paramType = "query", dataType = "int", required = true),
|
||||
// @ApiImplicitParam(name = "companyId", value = "公司id", paramType = "query", dataType = "int", required = false)
|
||||
//
|
||||
//})
|
||||
//@OperateLog(description = "根据工序id查询工序详情及物料信息", type = "查询")
|
||||
//@GetMapping("/query/process/detail")
|
||||
//public Result queryProcessDetail(MtAloneProcessParams params, @ApiIgnore @User CurrentUser currentUser) {
|
||||
// if(currentUser==null){
|
||||
// return ResultGenerator.genFailResult(CommonCode.SERVICE_ERROR,"未登录错误",null );
|
||||
// }
|
||||
//
|
||||
// params.setCompanyId(currentUser.getCompanyId());
|
||||
// PageHelper.startPage(params.getPageNum(), params.getPageSize());
|
||||
// ProcessAndMaterialsBom processAndMaterialsBom = mtAloneProcessService.queryProcessDetail(params);
|
||||
// return ResultGenerator.genSuccessResult(processAndMaterialsBom);
|
||||
//}
|
||||
|
||||
/**
|
||||
* hy正在用
|
||||
* 点击加工处理页面中工序列表最后一列查看或处理按钮,
|
||||
@ -175,7 +148,7 @@ public class MtAloneProcessController {
|
||||
}
|
||||
|
||||
/**
|
||||
* hy正在用
|
||||
* hy停用
|
||||
* 工序处理完毕时,点击提交同时更新工序信息、保存物料信息、更新物料库存信息
|
||||
* @param processAndProcMat
|
||||
* @param currentUser
|
||||
@ -188,11 +161,24 @@ public class MtAloneProcessController {
|
||||
@OperateLog(description = "工序及物料信息保存", type = "更新、保存")
|
||||
@PostMapping("/saveProcAndProcMat")
|
||||
public Result saveProcAndProcMat(@RequestBody ProcessAndProcMat processAndProcMat, @ApiIgnore @User CurrentUser currentUser) {
|
||||
//if(currentUser==null){
|
||||
// return ResultGenerator.genFailResult(CommonCode.SERVICE_ERROR,"未登录错误",null );
|
||||
//}
|
||||
if(currentUser==null){
|
||||
return ResultGenerator.genFailResult(CommonCode.SERVICE_ERROR,"未登录错误",null );
|
||||
}
|
||||
|
||||
mtAloneProcessService.saveProcAndProcMat(processAndProcMat, currentUser);
|
||||
return ResultGenerator.genSuccessResult();
|
||||
}
|
||||
|
||||
|
||||
//@ApiOperation(value = "工序详情更新", notes = "工序详情更新")
|
||||
//@ApiImplicitParams({
|
||||
// @ApiImplicitParam(name = "processAndProcMat", value = "工序及物料", paramType = "body", dataType = "ProcessAndProcMat", required = true)
|
||||
//})
|
||||
//@OperateLog(description = "工序详情更新", type = "更新")
|
||||
//@PostMapping("/update")
|
||||
//public Result updateProcess(@RequestBody MtAloneProcess mtAloneProcess) {
|
||||
// mtAloneProcess.setUpdateTime(new Date());
|
||||
// mtAloneProcessService.update(mtAloneProcess);
|
||||
// return ResultGenerator.genSuccessResult();
|
||||
//}
|
||||
}
|
||||
|
Caricamento…
Fai riferimento in un nuovo problema
Block a user