| | |
| | | import com.alibaba.fastjson.parser.Feature; |
| | | import com.fasterxml.jackson.core.JsonProcessingException; |
| | | import com.fasterxml.jackson.databind.ObjectMapper; |
| | | import com.sap.conn.jco.*; |
| | | import org.aspectj.lang.ProceedingJoinPoint; |
| | | import org.aspectj.lang.annotation.Around; |
| | | import org.aspectj.lang.annotation.Aspect; |
| | |
| | | break; |
| | | case WMS: |
| | | dto.setRequestMethod("Webservice"); |
| | | if (result instanceof Map) { |
| | | Map<String, Object> map = (Map<String, Object>) result; |
| | | dto.setResponseCode(map.get("ztype").toString()); |
| | | dto.setResponseMessage(map.get("zmess").toString()); |
| | | dto.setRequestBody(map.get("importParameters") == null ? null : map.get("importParameters").toString()); |
| | | dto.setResponseBody(parseSAPResponseResult(map.get("result"))); |
| | | } |
| | | break; |
| | | case FEI_SHU: |
| | | dto.setRequestMethod("Http"); |
| | |
| | | } catch (JsonProcessingException e) { |
| | | throw new JeecgBootException(e); |
| | | } |
| | | } else if (result instanceof String) { |
| | | return result.toString(); |
| | | } else { |
| | | try { |
| | | String json = objectMapper.writeValueAsString(result); |