'更新可用状态'

This commit is contained in:
zhangjie committed 2024-03-11 21:59:46 +08:00
1 parent 1855555e45
commit af46cc1a42
4 files changed
+13 -10

No files matched your search

@@ -83,7 +83,7 @@ public class MainActivity extends Activity {
public void categoryContent() { public void categoryContent() {
try { try {
Logger.t("categoryContent").d(spider.categoryContent("tv-热门-p-", "2", true, new HashMap<>())); Logger.t("categoryContent").d(spider.categoryContent("tv-热门", "2", true, new HashMap<>()));
} catch (Throwable e) { } catch (Throwable e) {
e.printStackTrace(); e.printStackTrace();
} }
@@ -91,7 +91,7 @@ public class MainActivity extends Activity {
public void detailContent() { public void detailContent() {
try { try {
Logger.t("detailContent").d(spider.detailContent(Arrays.asList("833375"))); Logger.t("detailContent").d(spider.detailContent(Arrays.asList("838500")));
} catch (Throwable e) { } catch (Throwable e) {
e.printStackTrace(); e.printStackTrace();
} }
@@ -53,7 +53,7 @@ public class Ikanbot extends Spider {
@Override @Override
public String homeContent(boolean filter) throws Exception { public String homeContent(boolean filter) throws Exception {
List<Class> classes = new ArrayList<>(); List<Class> classes = new ArrayList<>();
String[] typeIdList = {"movie-热门-p-", "tv-热门-p-"}; String[] typeIdList = {"movie-热门", "tv-热门"};
String[] typeNameList = {"热门电影", "热门剧集"}; String[] typeNameList = {"热门电影", "热门剧集"};
for (int i = 0; i < typeNameList.length; i++) { for (int i = 0; i < typeNameList.length; i++) {
classes.add(new Class(typeIdList[i], typeNameList[i])); classes.add(new Class(typeIdList[i], typeNameList[i]));
@@ -76,8 +76,11 @@ public class Ikanbot extends Spider {
@Override @Override
public String categoryContent(String tid, String pg, boolean filter, HashMap<String, String> extend) throws Exception { public String categoryContent(String tid, String pg, boolean filter, HashMap<String, String> extend) throws Exception {
String target = cateUrl + tid + pg + ".html"; String target = cateUrl + tid;
Document doc = Jsoup.parse(OkHttp.string(target, getHeaders())); if (pg != "1"){
target = target + "-p-" + pg;
}
Document doc = Jsoup.parse(OkHttp.string(target.concat(".html"), getHeaders()));
List<Vod> list = parseVods(doc); List<Vod> list = parseVods(doc);
Integer total = (Integer.parseInt(pg) + 1) * 20; Integer total = (Integer.parseInt(pg) + 1) * 20;
return Result.string(Integer.parseInt(pg), Integer.parseInt(pg) + 1, 20, total, list); return Result.string(Integer.parseInt(pg), Integer.parseInt(pg) + 1, 20, total, list);
@@ -118,10 +121,10 @@ public class Ikanbot extends Spider {
} else { } else {
PlayFrom = PlayFrom + flag; PlayFrom = PlayFrom + flag;
} }
if (!"".equals(liUrl)) { if (!"".equals(PlayUrl)) {
PlayUrl = PlayUrl + "$$$" + liUrl; PlayUrl = PlayUrl + "$$$" + liUrl.replace("$" + flag,"");
} else { } else {
PlayUrl = PlayUrl + liUrl; PlayUrl = PlayUrl + liUrl.replace("$" + flag,"");
} }
// PlayUrl += String.valueOf(element.getAsJsonObject().get("resData")).replace("\\","").replace("\\\"","\""); // PlayUrl += String.valueOf(element.getAsJsonObject().get("resData")).replace("\\","").replace("\\\"","\"");
@@ -132,7 +135,7 @@ public class Ikanbot extends Spider {
vod.setVodYear(year); vod.setVodYear(year);
vod.setVodName(name); vod.setVodName(name);
vod.setVodPlayFrom(PlayFrom); vod.setVodPlayFrom(PlayFrom);
vod.setVodPlayUrl(PlayUrl); vod.setVodPlayUrl(PlayUrl.replace("##","#").replace("#$$$","$$$"));
return Result.string(vod); return Result.string(vod);
} }
Binary file not shown.
+1 -1
View File
@@ -1 +1 @@
44d9f7ffb2da45c3043d9c90aaf5f6bd 458cc1059ef77165052ffeacd391ba97