ÎļþÃû´Ó Source/plt-web/plt-web-parent/plt-web/src/main/java/com/vci/web/util/WebUtil.java ÐÞ¸Ä |
| | |
| | | return errContent; |
| | | } |
| | | if (e instanceof PLException ) { |
| | | // String error_code = ((VCIError) e).error_code; |
| | | // String[] error_message = ((VCIError) e).error_message; |
| | | // return MessageUtils.get(error_code, error_message); |
| | | return null; |
| | | String error_code = ((PLException) e).code; |
| | | String[] error_message = ((PLException) e).messages; |
| | | return MessageUtils.get(error_code, error_message); |
| | | } else if(e instanceof VciBaseException || e.getClass().getSuperclass().equals(VciBaseException.class)){ |
| | | return LangBaseUtil.getErrorMsg(e); |
| | | }else if (e instanceof VciException){ |
| | |
| | | * @param lo 龿¥ç±»å |
| | | * @param map map |
| | | */ |
| | | public static void copyValueToMapFromLos(com.vci.corba.omd.data.LinkObject lo,Map<String,String> map){ |
| | | public static void copyValueToMapFromLos(LinkObject lo,Map<String,String> map){ |
| | | if(lo!=null){ |
| | | WebLoServiceImpl.LO_BASE_FIELD_MAP.forEach((field,attr)->{ |
| | | WebLoServiceImpl.LO_BASE_FIELD_MAP.forEach((field, attr)->{ |
| | | map.put(attr.toLowerCase(),getValueFromFieldForCbo(getFieldForObject(field,lo),lo)); |
| | | }); |
| | | //å
æææçåæ®µæ å°æ¾å° |
| | | com.vci.corba.omd.data.AttributeValue[] newAList = lo.newAttrValList; |
| | | com.vci.corba.omd.data.AttributeValue[] hisAList = lo.hisAttrValList; |
| | | AttributeValue[] newAList = lo.newAttrValList; |
| | | AttributeValue[] hisAList = lo.hisAttrValList; |
| | | if(hisAList!=null&&hisAList.length>0){ |
| | | for(int i = 0 ; i < hisAList.length;i++){ |
| | | com.vci.corba.omd.data.AttributeValue av = hisAList[i]; |
| | | AttributeValue av = hisAList[i]; |
| | | String attrName = av.attrName.toLowerCase(); |
| | | map.put(attrName, av.attrVal); |
| | | } |
| | | } |
| | | if(newAList!=null&&newAList.length>0){ |
| | | for(int i = 0 ; i < newAList.length;i++){ |
| | | com.vci.corba.omd.data.AttributeValue av = newAList[i]; |
| | | AttributeValue av = newAList[i]; |
| | | String attrName = av.attrName.toLowerCase(); |
| | | map.put(attrName, av.attrVal); |
| | | } |
| | |
| | | * @param e å¼å¸¸å¯¹è±¡ |
| | | * @return baseå¼å¸¸å¯¹è±¡ |
| | | */ |
| | | // public static VciBaseException getVciBaseException(PLException e){ |
| | | //// return new VciBaseException(e.error_code, e.error_message); |
| | | // return null; |
| | | // } |
| | | |
| | | /** |
| | | * 转æ¢å¼å¸¸ |
| | | * @param e å¼å¸¸å¯¹è±¡ |
| | | * @return baseå¼å¸¸å¯¹è±¡ |
| | | */ |
| | | public static VciBaseException getVciBaseException(PLException e){ |
| | | return new VciBaseException(e.code, new java.lang.String[]{e.getMessage()}); |
| | | // return null; |
| | | } |
| | | |
| | | /** |