| | |
| | | |
| | | import com.xxl.job.core.biz.model.ReturnT; |
| | | import com.xxl.job.core.handler.annotation.XxlJob; |
| | | import com.yeshi.buwan.iqiyi.IqiYiNewAPI; |
| | | import com.yeshi.buwan.iqiyi.util.IqiyiUtil2; |
| | | import com.yeshi.buwan.videos.iqiyi.IqiYiNewAPI; |
| | | import com.yeshi.buwan.videos.iqiyi.util.IqiyiUtil2; |
| | | import org.slf4j.Logger; |
| | | import org.slf4j.LoggerFactory; |
| | | import org.springframework.stereotype.Component; |
| | | |
| | | import javax.annotation.Resource; |
| | | import java.util.Date; |
| | | import java.util.List; |
| | | |
| | | @Component |
| | |
| | | List<String> urlList = IqiyiUtil2.getAlbumUrlsFromUrl(param); |
| | | for (String url : urlList) { |
| | | String aid = IqiYiNewAPI.getAidByUrl(url); |
| | | iqiyiUtil2.syncByAid(Long.parseLong(aid)); |
| | | iqiyiUtil2.syncByAid(Long.parseLong(aid),false); |
| | | logger.info("更新专辑:" + aid); |
| | | } |
| | | return ReturnT.SUCCESS; |
| | |
| | | @XxlJob("video-update-iqiyi-updateVideoByPlayerUrl") |
| | | public ReturnT<String> updateVideoByPlayerUrl(String param) throws Exception { |
| | | String aid = IqiYiNewAPI.getAidByUrl(param); |
| | | iqiyiUtil2.syncByAid(Long.parseLong(aid)); |
| | | iqiyiUtil2.syncByAid(Long.parseLong(aid),false); |
| | | logger.info("更新专辑:" + aid); |
| | | return ReturnT.SUCCESS; |
| | | } |