diff --git a/src/com/constant/Constants.java b/src/com/constant/Constants.java new file mode 100644 index 00000000..7879c047 --- /dev/null +++ b/src/com/constant/Constants.java @@ -0,0 +1,21 @@ +package com.constant; + +import weaver.interfaces.dito.comInfo.PropBean; + +public class Constants { + public static String bpm_app_workflowurl = PropBean.getUfPropValue("bpm_app_workflowurl"); + + public static String portal_doneurl = PropBean.getUfPropValue("portal_doneurl"); + + public static String bpm_app_requesturl = PropBean.getUfPropValue("bpm_app_requesturl"); + + public static String portal_todourl = PropBean.getUfPropValue("portal_todourl"); + + public static String username = PropBean.getUfPropValue("username"); + + public static String passwd = PropBean.getUfPropValue("passwd"); + + public static String center = PropBean.getUfPropValue("center"); + + public static String bpm_workflowurl = PropBean.getUfPropValue("bpm_workflowurl"); +} diff --git a/src/com/customization/dito/sendtodo/SendPortalTodoCmd.java b/src/com/customization/dito/sendtodo/SendPortalTodoCmd.java index 41fce0f1..8bf998ff 100644 --- a/src/com/customization/dito/sendtodo/SendPortalTodoCmd.java +++ b/src/com/customization/dito/sendtodo/SendPortalTodoCmd.java @@ -1,5 +1,6 @@ package com.customization.dito.sendtodo; +import com.constant.Constants; import com.engine.core.cfg.annotation.CommandDynamicProxy; import com.engine.core.interceptor.AbstractCommandProxy; import com.engine.core.interceptor.Command; @@ -62,26 +63,26 @@ public class SendPortalTodoCmd extends AbstractCommandProxy> String new_requestid = Util.null2String(resultBean.getResultInfo().get("requestid")); bb.writeLog("new_requestid:"+new_requestid); - String bpm_app_workflowurl = PropBean.getUfPropValue("bpm_app_workflowurl"); - String portal_doneurl = PropBean.getUfPropValue("portal_doneurl"); - String bpm_app_requesturl = PropBean.getUfPropValue("bpm_app_requesturl"); - String portal_todourl = PropBean.getUfPropValue("portal_todourl"); - String username = PropBean.getUfPropValue("username"); - String passwd = PropBean.getUfPropValue("passwd"); - String center = PropBean.getUfPropValue("center"); - String bpm_workflowurl = PropBean.getUfPropValue("bpm_workflowurl"); +// String bpm_app_workflowurl = PropBean.getUfPropValue("bpm_app_workflowurl"); +// String portal_doneurl = PropBean.getUfPropValue("portal_doneurl"); +// String bpm_app_requesturl = PropBean.getUfPropValue("bpm_app_requesturl"); +// String portal_todourl = PropBean.getUfPropValue("portal_todourl"); +// String username = PropBean.getUfPropValue("username"); +// String passwd = PropBean.getUfPropValue("passwd"); +// String center = PropBean.getUfPropValue("center"); +// String bpm_workflowurl = PropBean.getUfPropValue("bpm_workflowurl"); SendPortalTodoUtil sendPortalTodoUtil = new SendPortalTodoUtil(); if(Util.getIntValue(requestid) == -1 && "save".equals(src)){ - sendPortalTodoUtil.sendTodoDataByCreater(new_requestid,user,portal_todourl,bpm_app_workflowurl,username,passwd,bpm_workflowurl,center,bpm_app_requesturl); + sendPortalTodoUtil.sendTodoDataByCreater(new_requestid,user, Constants.portal_todourl,Constants.bpm_app_workflowurl,Constants.username,Constants.passwd,Constants.bpm_workflowurl,Constants.center,Constants.bpm_app_requesturl); }else if(Util.getIntValue(requestid) == -1 && "submit".equals(src)){ - sendPortalTodoUtil.sendTodoDataByCreateNode(new_requestid,nodeid,user,portal_todourl,bpm_app_workflowurl,username,passwd,bpm_workflowurl,center,bpm_app_requesturl); + sendPortalTodoUtil.sendTodoDataByCreateNode(new_requestid,nodeid,user,Constants.portal_todourl,Constants.bpm_app_workflowurl,Constants.username,Constants.passwd,Constants.bpm_workflowurl,Constants.center,Constants.bpm_app_requesturl); }else if(Util.getIntValue(requestid)> 0 && "submit".equals(src)){ - sendPortalTodoUtil.sendTodoDataByNode(requestid,nodeid,user,portal_todourl,bpm_app_workflowurl,username,passwd,bpm_workflowurl,center,bpm_app_requesturl); + sendPortalTodoUtil.sendTodoDataByNode(requestid,nodeid,user,Constants.portal_todourl,Constants.bpm_app_workflowurl,Constants.username,Constants.passwd,Constants.bpm_workflowurl,Constants.center,Constants.bpm_app_requesturl); }else if(Util.getIntValue(requestid)> 0 && "reject".equals(src)){ - sendPortalTodoUtil.sendTodoDataByReject(requestid,nodeid,user,portal_todourl,bpm_app_workflowurl,username,passwd,bpm_workflowurl,center,bpm_app_requesturl); + sendPortalTodoUtil.sendTodoDataByReject(requestid,nodeid,user,Constants.portal_todourl,Constants.bpm_app_workflowurl,Constants.username,Constants.passwd,Constants.bpm_workflowurl,Constants.center,Constants.bpm_app_requesturl); } diff --git a/src/com/customization/dito/sendtodo/SendPortalTodoRunnable.java b/src/com/customization/dito/sendtodo/SendPortalTodoRunnable.java index eb246add..1c2459cf 100644 --- a/src/com/customization/dito/sendtodo/SendPortalTodoRunnable.java +++ b/src/com/customization/dito/sendtodo/SendPortalTodoRunnable.java @@ -43,17 +43,17 @@ public class SendPortalTodoRunnable implements Runnable{ // sendPortalTodoUtil.sendTodoDataByCreater(new_requestid,user,portal_todourl,bpm_app_workflowurl,username,passwd,bpm_workflowurl,center,bpm_app_requesturl); }else if(Util.getIntValue(requestid) == -1 && "submit".equals(src)){ // sendPortalTodoUtil.sendTodoDataByCreateNode(new_requestid,nodeid,user,portal_todourl,bpm_app_workflowurl,username,passwd,bpm_workflowurl,center,bpm_app_requesturl); - sendPortalDoneUtil.sendPortalDoneData( new_requestid, nodeid, user, portal_doneurl,bpm_app_workflowurl, username, passwd, bpm_workflowurl,bpm_app_requesturl); + // sendPortalDoneUtil.sendPortalDoneData( new_requestid, nodeid, user, portal_doneurl,bpm_app_workflowurl, username, passwd, bpm_workflowurl,bpm_app_requesturl); sendPortalToReadUtil.sendToReadDataByCreateNode(new_requestid,user,portal_todourl,bpm_app_workflowurl,username,passwd,bpm_workflowurl,center,bpm_app_requesturl); }else if(Util.getIntValue(requestid)> 0 && "submit".equals(src)){ // sendPortalTodoUtil.sendTodoDataByNode(requestid,nodeid,user,portal_todourl,bpm_app_workflowurl,username,passwd,bpm_workflowurl,center,bpm_app_requesturl); - sendPortalDoneUtil.sendPortalDoneData( requestid, nodeid, user, portal_doneurl,bpm_app_workflowurl, username, passwd, bpm_workflowurl,bpm_app_requesturl); + // sendPortalDoneUtil.sendPortalDoneData( requestid, nodeid, user, portal_doneurl,bpm_app_workflowurl, username, passwd, bpm_workflowurl,bpm_app_requesturl); sendPortalToReadUtil.sendToReadDataByNode(requestid,nodeid,user,portal_todourl,bpm_app_workflowurl,username,passwd,bpm_workflowurl,center,bpm_app_requesturl); }else if(Util.getIntValue(requestid)> 0 && "reject".equals(src)){ // sendPortalTodoUtil.sendTodoDataByReject(requestid,nodeid,user,portal_todourl,bpm_app_workflowurl,username,passwd,bpm_workflowurl,center,bpm_app_requesturl); - sendPortalDoneUtil.sendPortalDoneData( requestid, nodeid, user, portal_doneurl,bpm_app_workflowurl, username, passwd, bpm_workflowurl,bpm_app_requesturl); + // sendPortalDoneUtil.sendPortalDoneData( requestid, nodeid, user, portal_doneurl,bpm_app_workflowurl, username, passwd, bpm_workflowurl,bpm_app_requesturl); } }