diff --git a/main/java/shkd/repc/resm/listplugin/MyEvalListPlugin.java b/main/java/shkd/repc/resm/listplugin/MyEvalListPlugin.java index 8358281..d918821 100644 --- a/main/java/shkd/repc/resm/listplugin/MyEvalListPlugin.java +++ b/main/java/shkd/repc/resm/listplugin/MyEvalListPlugin.java @@ -103,41 +103,15 @@ public class MyEvalListPlugin extends AbstractListPlugin implements Plugin { String format = simpleDateFormat.format(year); years.add(format);//添加进年份容器 - DynamicObject evalsupplier = resm_myeval_new.getDynamicObject("evalsupplier");//获取供应商 - if (evalsupplier != null){ - Object evalSupplierPkValue = evalsupplier.getPkValue(); - DynamicObject evaltask = resm_myeval_new.getDynamicObject("evaltask");//获取评估任务 - if (evaltask != null){ - DynamicObject resm_evaltask_new = BusinessDataServiceHelper.loadSingle(evaltask.getPkValue(), "resm_evaltask_new"); - DynamicObjectCollection evaldetail = resm_evaltask_new.getDynamicObjectCollection("evaldetail"); - if (evaldetail != null && evaldetail.size() > 0){ - for (DynamicObject dynamicObject : evaldetail) { - DynamicObject supplier = dynamicObject.getDynamicObject("supplier");//供应商 - if (supplier != null){ - if (evalSupplierPkValue.equals(supplier.getPkValue())){ - DynamicObject evalscheme = dynamicObject.getDynamicObject("evalscheme"); - if (evalscheme != null){ - Object evalSchemePkValue = evalscheme.getPkValue(); - evalSchemeId = evalSchemePkValue;//覆盖方案id - evalSchemes.add(evalSchemePkValue); - }else { - this.getView().showTipNotification("选择的我的评估单据对应的评估任务,评估详情分录中评估方案数据异常"); - return false; - } - } - }else { - this.getView().showTipNotification("选择的我的评估单据对应的评估任务,评估详情分录中供应商数据异常"); - return false; - } - } - }else { - this.getView().showTipNotification("选择的我的评估单据对应的评估任务存在评估详情数据异常"); - return false; - } - } + DynamicObject evalscheme = resm_myeval_new.getDynamicObject("evalscheme"); + if (evalscheme != null){ + Object evalSchemePkValue = evalscheme.getPkValue(); + evalSchemeId = evalSchemePkValue;//覆盖方案id + evalSchemes.add(evalSchemePkValue); + this.getView().showTipNotification("测试"); }else { - this.getView().showTipNotification("选择的我的评估单据存在供应商名称数据异常"); + this.getView().showTipNotification("选择的我的评估单据存在评估方案数据异常"); return false; } }