| | |
| | | if (darray != null && darray.size() > 0) { |
| | | String auctionId = darray.optJSONObject(0).optString("item_id"); |
| | | result.getTaoBaoGoodsBriefs().set(0, TaoKeApiUtil.searchGoodsDetail(auctionId)); |
| | | }else{ |
| | | // 大淘客无法搜索到,就将最后一个字去掉然后再搜索 |
| | | String originText = sf.getKey(); |
| | | sf.setKey(originText.substring(0,originText.length()-1)); |
| | | result = TaoBaoUtil.search(sf, specialId, null); |
| | | // if(result.getTaoBaoGoodsBriefs() != null) |
| | | // for(TaoBaoGoodsBrief tb: result.getTaoBaoGoodsBriefs()){ |
| | | // if(originText.equalsIgnoreCase(tb.getTitle())){ |
| | | // |
| | | // break; |
| | | // } |
| | | // } |
| | | } |
| | | } |
| | | taoBaoGoodsCacheUtil.saveSearchResult(sf, result); |