adapted pmvhaven
This commit is contained in:
156
src/api.rs
156
src/api.rs
@@ -124,85 +124,85 @@ async fn status(req: HttpRequest) -> Result<impl web::Responder, web::Error> {
|
|||||||
favicon: "https://www.google.com/s2/favicons?sz=64&domain=pornhub.com".to_string(),
|
favicon: "https://www.google.com/s2/favicons?sz=64&domain=pornhub.com".to_string(),
|
||||||
status: "active".to_string(),
|
status: "active".to_string(),
|
||||||
categories: vec![],
|
categories: vec![],
|
||||||
options: vec![
|
options: vec![ChannelOption {
|
||||||
ChannelOption {
|
id: "sort".to_string(),
|
||||||
id: "sort".to_string(),
|
title: "Sort".to_string(),
|
||||||
title: "Sort".to_string(),
|
description: "Sort the Videos".to_string(), //"Sort the videos by Date or Name.".to_string(),
|
||||||
description: "Sort the Videos".to_string(), //"Sort the videos by Date or Name.".to_string(),
|
systemImage: "list.number".to_string(),
|
||||||
systemImage: "list.number".to_string(),
|
colorName: "blue".to_string(),
|
||||||
colorName: "blue".to_string(),
|
options: vec![
|
||||||
options: vec![
|
FilterOption {
|
||||||
FilterOption {
|
id: "mr".to_string(),
|
||||||
id: "mr".to_string(),
|
title: "Most Recent".to_string(),
|
||||||
title: "Most Recent".to_string(),
|
},
|
||||||
},
|
FilterOption {
|
||||||
FilterOption {
|
id: "mv".to_string(),
|
||||||
id: "mv".to_string(),
|
title: "Most Viewed".to_string(),
|
||||||
title: "Most Viewed".to_string(),
|
},
|
||||||
},
|
FilterOption {
|
||||||
FilterOption {
|
id: "tr".to_string(),
|
||||||
id: "tr".to_string(),
|
title: "Top Rated".to_string(),
|
||||||
title: "Top Rated".to_string(),
|
},
|
||||||
},
|
FilterOption {
|
||||||
FilterOption {
|
id: "lg".to_string(),
|
||||||
id: "lg".to_string(),
|
title: "Longest".to_string(),
|
||||||
title: "Longest".to_string(),
|
},
|
||||||
},
|
],
|
||||||
],
|
multiSelect: false,
|
||||||
multiSelect: false,
|
}],
|
||||||
},],
|
|
||||||
nsfw: true,
|
|
||||||
});
|
|
||||||
// pmvhaven
|
|
||||||
status.add_channel(Channel {
|
|
||||||
id: "pmvhaven".to_string(),
|
|
||||||
name: "Pmvhaven".to_string(),
|
|
||||||
description: "Explore a curated collection of captivating PMV".to_string(),
|
|
||||||
premium: false,
|
|
||||||
favicon: "https://www.google.com/s2/favicons?sz=64&domain=pmvhaven.com".to_string(),
|
|
||||||
status: "active".to_string(),
|
|
||||||
categories: vec![],
|
|
||||||
options: vec![
|
|
||||||
ChannelOption {
|
|
||||||
id: "category".to_string(),
|
|
||||||
title: "Category".to_string(),
|
|
||||||
description: "Category of PMV Video get".to_string(), //"Sort the videos by Date or Name.".to_string(),
|
|
||||||
systemImage: "list.number".to_string(),
|
|
||||||
colorName: "blue".to_string(),
|
|
||||||
options: vec![
|
|
||||||
FilterOption {
|
|
||||||
id: "all".to_string(),
|
|
||||||
title: "All".to_string(),
|
|
||||||
},
|
|
||||||
FilterOption {
|
|
||||||
id: "pmv".to_string(),
|
|
||||||
title: "PMV".to_string(),
|
|
||||||
},
|
|
||||||
FilterOption {
|
|
||||||
id: "hmv".to_string(),
|
|
||||||
title: "HMV".to_string(),
|
|
||||||
},
|
|
||||||
FilterOption {
|
|
||||||
id: "tiktok".to_string(),
|
|
||||||
title: "Tiktok".to_string(),
|
|
||||||
},
|
|
||||||
FilterOption {
|
|
||||||
id: "koreanbj".to_string(),
|
|
||||||
title: "KoreanBJ".to_string(),
|
|
||||||
},
|
|
||||||
FilterOption {
|
|
||||||
id: "hypno".to_string(),
|
|
||||||
title: "Hypno".to_string(),
|
|
||||||
},
|
|
||||||
FilterOption {
|
|
||||||
id: "other".to_string(),
|
|
||||||
title: "Other".to_string(),
|
|
||||||
},
|
|
||||||
],
|
|
||||||
multiSelect: false,
|
|
||||||
},],
|
|
||||||
nsfw: true,
|
nsfw: true,
|
||||||
});
|
});
|
||||||
|
if clientversion >= ClientVersion::new(22, 101, "22e".to_string()) {
|
||||||
|
// pmvhaven
|
||||||
|
status.add_channel(Channel {
|
||||||
|
id: "pmvhaven".to_string(),
|
||||||
|
name: "Pmvhaven".to_string(),
|
||||||
|
description: "Explore a curated collection of captivating PMV".to_string(),
|
||||||
|
premium: false,
|
||||||
|
favicon: "https://www.google.com/s2/favicons?sz=64&domain=pmvhaven.com".to_string(),
|
||||||
|
status: "active".to_string(),
|
||||||
|
categories: vec![],
|
||||||
|
options: vec![ChannelOption {
|
||||||
|
id: "category".to_string(),
|
||||||
|
title: "Category".to_string(),
|
||||||
|
description: "Category of PMV Video get".to_string(), //"Sort the videos by Date or Name.".to_string(),
|
||||||
|
systemImage: "list.number".to_string(),
|
||||||
|
colorName: "blue".to_string(),
|
||||||
|
options: vec![
|
||||||
|
FilterOption {
|
||||||
|
id: "all".to_string(),
|
||||||
|
title: "All".to_string(),
|
||||||
|
},
|
||||||
|
FilterOption {
|
||||||
|
id: "pmv".to_string(),
|
||||||
|
title: "PMV".to_string(),
|
||||||
|
},
|
||||||
|
FilterOption {
|
||||||
|
id: "hmv".to_string(),
|
||||||
|
title: "HMV".to_string(),
|
||||||
|
},
|
||||||
|
FilterOption {
|
||||||
|
id: "tiktok".to_string(),
|
||||||
|
title: "Tiktok".to_string(),
|
||||||
|
},
|
||||||
|
FilterOption {
|
||||||
|
id: "koreanbj".to_string(),
|
||||||
|
title: "KoreanBJ".to_string(),
|
||||||
|
},
|
||||||
|
FilterOption {
|
||||||
|
id: "hypno".to_string(),
|
||||||
|
title: "Hypno".to_string(),
|
||||||
|
},
|
||||||
|
FilterOption {
|
||||||
|
id: "other".to_string(),
|
||||||
|
title: "Other".to_string(),
|
||||||
|
},
|
||||||
|
],
|
||||||
|
multiSelect: false,
|
||||||
|
}],
|
||||||
|
nsfw: true,
|
||||||
|
});
|
||||||
|
}
|
||||||
if clientversion >= ClientVersion::new(22, 97, "22a".to_string()) {
|
if clientversion >= ClientVersion::new(22, 97, "22a".to_string()) {
|
||||||
// perverzija
|
// perverzija
|
||||||
status.add_channel(Channel {
|
status.add_channel(Channel {
|
||||||
@@ -428,7 +428,7 @@ async fn videos_post(
|
|||||||
page.to_string(),
|
page.to_string(),
|
||||||
perPage.to_string(),
|
perPage.to_string(),
|
||||||
featured.clone(),
|
featured.clone(),
|
||||||
category.clone()
|
category.clone(),
|
||||||
)
|
)
|
||||||
.await;
|
.await;
|
||||||
videos.items = video_items.clone();
|
videos.items = video_items.clone();
|
||||||
|
|||||||
@@ -200,10 +200,10 @@ impl PmvhavenVideo {
|
|||||||
thumbnail,
|
thumbnail,
|
||||||
self.duration as u32,
|
self.duration as u32,
|
||||||
)
|
)
|
||||||
.formats(vec![
|
//.formats(vec![
|
||||||
VideoFormat::new(format!("https://storage.pmvhaven.com/{}/{}_{}.mp4", video_id, encoded_title, video_id), "1080".to_string(), "mp4".to_string()).protocol("https".to_string()),
|
// VideoFormat::new(format!("https://storage.pmvhaven.com/{}/{}_{}.mp4", video_id, encoded_title, video_id), "1080".to_string(), "mp4".to_string()).protocol("https".to_string()),
|
||||||
VideoFormat::new(format!("https://storage.pmvhaven.com/{}/264_{}.mp4", video_id, video_id), "1080".to_string(), "mp4".to_string()).protocol("https".to_string())
|
// VideoFormat::new(format!("https://storage.pmvhaven.com/{}/264_{}.mp4", video_id, video_id), "1080".to_string(), "mp4".to_string()).protocol("https".to_string())
|
||||||
])
|
//])
|
||||||
|
|
||||||
.views(self.views);
|
.views(self.views);
|
||||||
item = match self.creator{
|
item = match self.creator{
|
||||||
|
|||||||
Reference in New Issue
Block a user