| | |
| | | |
| | | import cn.hutool.core.bean.BeanUtil; |
| | | import com.alibaba.fastjson.JSON; |
| | | import com.alibaba.fastjson.JSONArray; |
| | | import com.alibaba.fastjson.JSONObject; |
| | | import com.core.common.Cools; |
| | | import com.core.exception.CoolException; |
| | | import com.zy.asrs.entity.MesLocDetl; |
| | | import com.zy.asrs.entity.ReportData; |
| | | import com.zy.asrs.entity.ReportDataLog; |
| | | import com.zy.asrs.service.ApiLogService; |
| | |
| | | |
| | | @Value("${mes.pakoutReportPath}") |
| | | private String pakoutReportPath; |
| | | |
| | | @Value("${mes.stock}") |
| | | private String stock; |
| | | |
| | | |
| | | @Transactional |
| | |
| | | } |
| | | return response; |
| | | } |
| | | |
| | | |
| | | @Transactional |
| | | public ReturnT<String> stock(Map<String, Object> mesTokenInfo) { |
| | | String result = doHttpRequest("{}", mesTokenInfo, "同步MES库存", url, stock, null, "127.0.0.1"); |
| | | JSONObject jsonObject = JSONObject.parseObject(result); |
| | | Object o = jsonObject.get("data"); |
| | | if (o != null) { |
| | | JSONObject jsonObject1 = JSONObject.parseObject(o.toString()); |
| | | Object o1 = jsonObject1.get("list"); |
| | | if (o1 != null) { |
| | | JSONArray jsonArray = JSONArray.parseArray(o1.toString()); |
| | | for (int i = 0; i < jsonArray.size(); i++) { |
| | | JSONObject jsonObject2 = jsonArray.getJSONObject(i); |
| | | } |
| | | } |
| | | } |
| | | MesLocDetl mesLocDetl=new MesLocDetl(); |
| | | |
| | | return SUCCESS; |
| | | } |
| | | } |