Remove play list for ali
This commit is contained in:
parent
5d81bb5377
commit
47872fdaf0
|
|
@ -35,14 +35,6 @@ public class Item {
|
|||
return new Gson().fromJson(str, Item.class);
|
||||
}
|
||||
|
||||
public static Item playList(Item copy, String vodPic) {
|
||||
Item item = new Item();
|
||||
item.name = "播放列表";
|
||||
item.path = copy.path;
|
||||
item.thumb = vodPic;
|
||||
return item;
|
||||
}
|
||||
|
||||
public static List<Item> arrayFrom(String str) {
|
||||
Type listType = new TypeToken<List<Item>>() {}.getType();
|
||||
return new Gson().fromJson(str, listType);
|
||||
|
|
|
|||
|
|
@ -87,7 +87,6 @@ public class AList extends Spider {
|
|||
fetchRule();
|
||||
String type = extend.containsKey("type") ? extend.get("type") : "";
|
||||
String order = extend.containsKey("order") ? extend.get("order") : "";
|
||||
String key = tid.contains("/") ? tid.substring(0, tid.indexOf("/")) : tid;
|
||||
List<Item> folders = new ArrayList<>();
|
||||
List<Item> files = new ArrayList<>();
|
||||
List<Vod> list = new ArrayList<>();
|
||||
|
|
@ -101,11 +100,6 @@ public class AList extends Spider {
|
|||
Sorter.sort(type, order, files);
|
||||
}
|
||||
|
||||
int count = 0;
|
||||
Drive drive = getDrive(key);
|
||||
for (Item item : files) if (item.isMedia(drive.isNew())) count++;
|
||||
if (count > 1) folders.add(0, Item.playList(files.get(0), vodPic));
|
||||
|
||||
for (Item item : folders) list.add(item.getVod(tid, vodPic));
|
||||
for (Item item : files) list.add(item.getVod(tid, vodPic));
|
||||
return Result.get().vod(list).page().string();
|
||||
|
|
@ -115,7 +109,6 @@ public class AList extends Spider {
|
|||
public String detailContent(List<String> ids) throws Exception {
|
||||
fetchRule();
|
||||
String id = ids.get(0);
|
||||
boolean list = id.endsWith("播放列表");
|
||||
String key = id.contains("/") ? id.substring(0, id.indexOf("/")) : id;
|
||||
String path = id.substring(0, id.lastIndexOf("/"));
|
||||
String name = path.substring(path.lastIndexOf("/") + 1);
|
||||
|
|
@ -124,22 +117,12 @@ public class AList extends Spider {
|
|||
Sorter.sort("name", "asc", parents);
|
||||
Vod vod = new Vod();
|
||||
vod.setVodPlayFrom(key);
|
||||
|
||||
if (list) {
|
||||
vod.setVodId(id);
|
||||
vod.setVodName(name);
|
||||
vod.setVodPic(vodPic);
|
||||
List<String> playUrls = new ArrayList<>();
|
||||
for (Item item : parents) if (item.isMedia(drive.isNew())) playUrls.add(item.getName() + "$" + item.getVodId(path) + findSubs(path, parents));
|
||||
vod.setVodPlayUrl(TextUtils.join("#", playUrls));
|
||||
} else {
|
||||
Item item = getDetail(id);
|
||||
vod.setVodId(item.getVodId(id));
|
||||
vod.setVodName(item.getName());
|
||||
vod.setVodPic(item.getPic(vodPic));
|
||||
vod.setVodPlayUrl(item.getName() + "$" + item.getVodId(path) + findSubs(path, parents));
|
||||
}
|
||||
|
||||
vod.setVodId(id);
|
||||
vod.setVodName(name);
|
||||
vod.setVodPic(vodPic);
|
||||
List<String> playUrls = new ArrayList<>();
|
||||
for (Item item : parents) if (item.isMedia(drive.isNew())) playUrls.add(item.getName() + "$" + item.getVodId(path) + findSubs(path, parents));
|
||||
vod.setVodPlayUrl(TextUtils.join("#", playUrls));
|
||||
return Result.string(vod);
|
||||
}
|
||||
|
||||
|
|
|
|||
Binary file not shown.
|
|
@ -1 +1 @@
|
|||
ae1463f4584754ef50ab902920ccb7da
|
||||
942e99b122cf9eb8d0859bbab9994f12
|
||||
|
|
|
|||
Loading…
Reference in New Issue