Commit 6446174d authored by 刘学辉's avatar 刘学辉

物料查询品牌调整

parent c2678360
...@@ -293,16 +293,18 @@ public class NonProdApplyNextController extends CommonController { ...@@ -293,16 +293,18 @@ public class NonProdApplyNextController extends CommonController {
return forward("nonProdApplyClass", nonProdApplyDept); return forward("nonProdApplyClass", nonProdApplyDept);
case "V": //销售 case "V": //销售
if (StringUtils.isNotBlank(nonProdApplyDept.getMatnr())) { if (StringUtils.isNotBlank(nonProdApplyDept.getMatnr())) {
String url = "/md/mditem/queryBrandByItemCode?sapItemcode=" + nonProdApplyDept.getMatnr(); String url = "md/mditem/queryBrandByItemCode/" + nonProdApplyDept.getMatnr();
Map map = new HashMap(); Map map = new HashMap();
try { try {
//{msg:"","code":"",data:{"code":"","name":}} //{msg:"","code":"",data:{"code":"","name":}}
String result = defaultHttpClient.executeForEp(map, url); String result = defaultHttpClient.executeForEp(map, url);
EpResult epResult = JSONObject.parseObject(result, EpResult.class); EpResult epResult = JSONObject.parseObject(result, EpResult.class);
if ("".equals(epResult.getMsg())) { if ("200".equals(epResult.getCode())) {
if (epResult.getData()!=null){
nonProdApplyDept.setBrand(epResult.getData().getCode()); nonProdApplyDept.setBrand(epResult.getData().getCode());
nonProdApplyDept.setBrandName(epResult.getData().getName()); nonProdApplyDept.setBrandName(epResult.getData().getName());
nonProdApplyDept.setMvgr2(epResult.getData().getCode()); nonProdApplyDept.setMvgr2(epResult.getData().getCode());
}
} else { } else {
throw new RuntimeException("从EP查询品牌错误:" + epResult.getMsg()); throw new RuntimeException("从EP查询品牌错误:" + epResult.getMsg());
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment