|
@@ -793,7 +793,7 @@ public class MPSMainServiceImpl implements MPSMainService {
|
|
|
@Override
|
|
|
@Transactional(propagation = Propagation.REQUIRED)
|
|
|
public synchronized Map<String, Object> NeedThrow(String caller, String mainCode, String gridStore, String toWhere, String toCode,
|
|
|
- String condition, String maKind, String purcaseCop, String apKind) {
|
|
|
+ String condition, String maKind, String purcaseCop, String apKind, String maTaskType) {
|
|
|
List<Map<Object, Object>> grid = BaseUtil.parseGridStoreToMaps(gridStore);
|
|
|
int count = 0;
|
|
|
int Makecount = 0;
|
|
@@ -935,7 +935,7 @@ public class MPSMainServiceImpl implements MPSMainService {
|
|
|
}
|
|
|
}
|
|
|
Map<Object, Object> map = new HashMap<Object, Object>();
|
|
|
- if ("MAKE".equals(rs.getString("pr_manutype"))) {
|
|
|
+ if (((maTaskType ==null || "".equals(maTaskType)) && "MAKE".equals(rs.getString("pr_manutype"))) || "MAKE".equals(maTaskType)) {
|
|
|
if (makekind == null || makekind.equals("")) {
|
|
|
BaseUtil.showError("未定义默认的MRP投放制造单类型,不能投放");
|
|
|
}
|
|
@@ -1031,7 +1031,7 @@ public class MPSMainServiceImpl implements MPSMainService {
|
|
|
count++;
|
|
|
Makecount++;
|
|
|
handlerService.handler("MpsDesk", "ThrowMake", "after", new Object[] { mainid });
|
|
|
- } else if ("OSMAKE".equals(rs.getObject("pr_manutype"))) {
|
|
|
+ } else if (((maTaskType ==null || "".equals(maTaskType)) && "OSMAKE".equals(rs.getString("pr_manutype"))) || "OSMAKE".equals(maTaskType)) {
|
|
|
if (osmakekind == null || osmakekind.equals("")) {
|
|
|
BaseUtil.showError("未定义默认的MRP投放委外单类型,不能投放");
|
|
|
}
|
|
@@ -2836,7 +2836,7 @@ public class MPSMainServiceImpl implements MPSMainService {
|
|
|
}
|
|
|
// 清理无效PR 转投放状态为 PURCHASE 投放采购件
|
|
|
mpsdesk_turnpurchase(mainCode.toString(), "MpsDesk");
|
|
|
- NeedThrow("MPSNeed", mainCode, gridStore, "AUTO", null, "", "", "", "", mianMaster);
|
|
|
+ NeedThrow("MPSNeed", mainCode, gridStore, "AUTO", null, "", "", "", "", mianMaster,null);
|
|
|
if (mdIdList.size() == 1000) {// 递归 每次1000投放数据
|
|
|
throwMrp(sql, mainCode, mianMaster, sonMaster);
|
|
|
}
|
|
@@ -2845,7 +2845,7 @@ public class MPSMainServiceImpl implements MPSMainService {
|
|
|
|
|
|
@Transactional(propagation = Propagation.REQUIRED)
|
|
|
public synchronized Map<String, Object> NeedThrow(String caller, String mainCode, String gridStore, String toWhere, String toCode,
|
|
|
- String condition, String maKind, String purcaseCop, String apKind, String mianMaster) {// 自动投放
|
|
|
+ String condition, String maKind, String purcaseCop, String apKind, String mianMaster, String maTasktype) {// 自动投放
|
|
|
int count = 0;
|
|
|
int Makecount = 0;
|
|
|
int OSMakecount = 0;
|