一些问题修改
This commit is contained in:
@@ -79,6 +79,10 @@ public class MdProductBomController extends BaseController
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody MdProductBom mdProductBom)
|
||||
{
|
||||
if(mdProductBom.getBomItemId() == mdProductBom.getItemId()){
|
||||
return AjaxResult.error("产品不能作为自身的BOM物料!");
|
||||
}
|
||||
|
||||
return toAjax(mdProductBomService.insertMdProductBom(mdProductBom));
|
||||
}
|
||||
|
||||
|
||||
@@ -120,7 +120,7 @@ public class ProTaskController extends BaseController
|
||||
}
|
||||
BigDecimal produced = workorder.getQuantityProduced();
|
||||
BigDecimal quantitiy = workorder.getQuantity();
|
||||
wdata.setProgress( produced.divide(quantitiy).floatValue());
|
||||
wdata.setProgress( produced.divide(quantitiy,BigDecimal.ROUND_HALF_UP).floatValue());
|
||||
wdata.setDuration(0L);
|
||||
wdata.setType(UserConstants.GANTT_TASK_TYPE_PROJECT);
|
||||
ganttData.add(wdata);
|
||||
|
||||
Reference in New Issue
Block a user