missav upgrade
This commit is contained in:
166
src/api.rs
166
src/api.rs
@@ -471,6 +471,7 @@ async fn status(req: HttpRequest) -> Result<impl web::Responder, web::Error> {
|
||||
nsfw: true,
|
||||
});
|
||||
|
||||
// Redtube
|
||||
status.add_channel(Channel {
|
||||
id: "redtube".to_string(),
|
||||
name: "Redtube".to_string(),
|
||||
@@ -483,6 +484,7 @@ async fn status(req: HttpRequest) -> Result<impl web::Responder, web::Error> {
|
||||
nsfw: true,
|
||||
});
|
||||
|
||||
// ok.porn
|
||||
status.add_channel(Channel {
|
||||
id: "okporn".to_string(),
|
||||
name: "Ok.porn".to_string(),
|
||||
@@ -516,7 +518,8 @@ async fn status(req: HttpRequest) -> Result<impl web::Responder, web::Error> {
|
||||
nsfw: true,
|
||||
});
|
||||
|
||||
status.add_channel(Channel {
|
||||
// pornhat
|
||||
status.add_channel(Channel {
|
||||
id: "pornhat".to_string(),
|
||||
name: "Pornhat".to_string(),
|
||||
description: "free HD porn videos".to_string(),
|
||||
@@ -549,7 +552,8 @@ async fn status(req: HttpRequest) -> Result<impl web::Responder, web::Error> {
|
||||
nsfw: true,
|
||||
});
|
||||
|
||||
status.add_channel(Channel {
|
||||
//perfectgirls
|
||||
status.add_channel(Channel {
|
||||
id: "perfectgirls".to_string(),
|
||||
name: "Perfectgirls".to_string(),
|
||||
description: "Perfect Girls Tube".to_string(),
|
||||
@@ -582,6 +586,7 @@ async fn status(req: HttpRequest) -> Result<impl web::Responder, web::Error> {
|
||||
nsfw: true,
|
||||
});
|
||||
|
||||
// okxxx
|
||||
status.add_channel(Channel {
|
||||
id: "okxxx".to_string(),
|
||||
name: "Ok.xxx".to_string(),
|
||||
@@ -615,7 +620,8 @@ async fn status(req: HttpRequest) -> Result<impl web::Responder, web::Error> {
|
||||
nsfw: true,
|
||||
});
|
||||
|
||||
status.add_channel(Channel {
|
||||
// homoxxx
|
||||
status.add_channel(Channel {
|
||||
id: "homoxxx".to_string(),
|
||||
name: "Homo.xxx".to_string(),
|
||||
description: "Best Gay Porn".to_string(),
|
||||
@@ -648,6 +654,7 @@ async fn status(req: HttpRequest) -> Result<impl web::Responder, web::Error> {
|
||||
nsfw: true,
|
||||
});
|
||||
|
||||
// hentaimoon
|
||||
status.add_channel(Channel {
|
||||
id: "hentaimoon".to_string(),
|
||||
name: "Hentai Moon".to_string(),
|
||||
@@ -681,6 +688,7 @@ async fn status(req: HttpRequest) -> Result<impl web::Responder, web::Error> {
|
||||
nsfw: true,
|
||||
});
|
||||
|
||||
//missav
|
||||
status.add_channel(Channel {
|
||||
id: "missav".to_string(),
|
||||
name: "MissAV".to_string(),
|
||||
@@ -690,28 +698,124 @@ async fn status(req: HttpRequest) -> Result<impl web::Responder, web::Error> {
|
||||
status: "active".to_string(),
|
||||
categories: vec![],
|
||||
options: vec![
|
||||
// ChannelOption {
|
||||
// id: "sort".to_string(),
|
||||
// title: "Sort".to_string(),
|
||||
// description: "Sort the Videos".to_string(), //"Sort the videos by Date or Name.".to_string(),
|
||||
// systemImage: "list.number".to_string(),
|
||||
// colorName: "blue".to_string(),
|
||||
// options: vec![
|
||||
// FilterOption {
|
||||
// id: "new".to_string(),
|
||||
// title: "New".to_string(),
|
||||
// },
|
||||
// FilterOption {
|
||||
// id: "popular".to_string(),
|
||||
// title: "Popular".to_string(),
|
||||
// },
|
||||
// FilterOption {
|
||||
// id: "top-rated".to_string(),
|
||||
// title: "Top Rated".to_string(),
|
||||
// },
|
||||
// ],
|
||||
// multiSelect: false,
|
||||
// }
|
||||
ChannelOption {
|
||||
id: "sort".to_string(),
|
||||
title: "Sort".to_string(),
|
||||
description: "Sort the Videos".to_string(), //"Sort the videos by Date or Name.".to_string(),
|
||||
systemImage: "list.number".to_string(),
|
||||
colorName: "blue".to_string(),
|
||||
options: vec![
|
||||
FilterOption {
|
||||
id: "released_at".to_string(),
|
||||
title: "Release Date".to_string(),
|
||||
},
|
||||
FilterOption {
|
||||
id: "published_at".to_string(),
|
||||
title: "Recent Update".to_string(),
|
||||
},
|
||||
FilterOption {
|
||||
id: "today_views".to_string(),
|
||||
title: "Today Views".to_string(),
|
||||
},
|
||||
FilterOption {
|
||||
id: "weekly_views".to_string(),
|
||||
title: "Weekly Views".to_string(),
|
||||
},
|
||||
FilterOption {
|
||||
id: "monthly_views".to_string(),
|
||||
title: "Monthly Views".to_string(),
|
||||
},
|
||||
FilterOption {
|
||||
id: "views".to_string(),
|
||||
title: "Total Views".to_string(),
|
||||
},
|
||||
],
|
||||
multiSelect: false,
|
||||
},
|
||||
ChannelOption {
|
||||
id: "filter".to_string(),
|
||||
title: "Filter".to_string(),
|
||||
description: "Filter the Videos".to_string(), //"Sort the videos by Date or Name.".to_string(),
|
||||
systemImage: "line.horizontal.3.decrease.circle".to_string(),
|
||||
colorName: "green".to_string(),
|
||||
options: vec![
|
||||
FilterOption {
|
||||
id: "new".to_string(),
|
||||
title: "Recent update".to_string(),
|
||||
},
|
||||
FilterOption {
|
||||
id: "release".to_string(),
|
||||
title: "New Releases".to_string(),
|
||||
},
|
||||
FilterOption {
|
||||
id: "uncensored-leak".to_string(),
|
||||
title: "Uncensored".to_string(),
|
||||
},
|
||||
FilterOption {
|
||||
id: "english-subtitle".to_string(),
|
||||
title: "English subtitle".to_string(),
|
||||
},
|
||||
],
|
||||
multiSelect: false,
|
||||
},
|
||||
ChannelOption {
|
||||
id: "language".to_string(),
|
||||
title: "Language".to_string(),
|
||||
description: "What Language to fetch".to_string(), //"Sort the videos by Date or Name.".to_string(),
|
||||
systemImage: "flag.fill".to_string(),
|
||||
colorName: "white".to_string(),
|
||||
options: vec![
|
||||
FilterOption {
|
||||
id: "en".to_string(),
|
||||
title: "English".to_string(),
|
||||
},
|
||||
FilterOption {
|
||||
id: "cn".to_string(),
|
||||
title: "简体中文".to_string(),
|
||||
},
|
||||
FilterOption {
|
||||
id: "ja".to_string(),
|
||||
title: "日本語".to_string(),
|
||||
},
|
||||
FilterOption {
|
||||
id: "ko".to_string(),
|
||||
title: "한국의".to_string(),
|
||||
},
|
||||
FilterOption {
|
||||
id: "ms".to_string(),
|
||||
title: "Melayu".to_string(),
|
||||
},
|
||||
FilterOption {
|
||||
id: "th".to_string(),
|
||||
title: "ไทย".to_string(),
|
||||
},
|
||||
FilterOption {
|
||||
id: "de".to_string(),
|
||||
title: "Deutsch".to_string(),
|
||||
},
|
||||
FilterOption {
|
||||
id: "fr".to_string(),
|
||||
title: "Français".to_string(),
|
||||
},
|
||||
FilterOption {
|
||||
id: "vi".to_string(),
|
||||
title: "Tiếng Việt".to_string(),
|
||||
},
|
||||
FilterOption {
|
||||
id: "id".to_string(),
|
||||
title: "Bahasa Indonesia".to_string(),
|
||||
},
|
||||
FilterOption {
|
||||
id: "fil".to_string(),
|
||||
title: "Filipino".to_string(),
|
||||
},
|
||||
FilterOption {
|
||||
id: "pt".to_string(),
|
||||
title: "Português".to_string(),
|
||||
},
|
||||
],
|
||||
multiSelect: false,
|
||||
}
|
||||
],
|
||||
nsfw: true,
|
||||
});
|
||||
@@ -780,7 +884,17 @@ async fn videos_post(
|
||||
.as_deref()
|
||||
.unwrap_or("")
|
||||
.to_string();
|
||||
let options = ServerOptions { featured: Some(featured), category: Some(category), sites: Some(sites) };
|
||||
let filter = video_request
|
||||
.filter
|
||||
.as_deref()
|
||||
.unwrap_or("new")
|
||||
.to_string();
|
||||
let language = video_request
|
||||
.language
|
||||
.as_deref()
|
||||
.unwrap_or("en")
|
||||
.to_string();
|
||||
let options = ServerOptions { featured: Some(featured), category: Some(category), sites: Some(sites), filter: Some(filter), language: Some(language) };
|
||||
let video_items = provider
|
||||
.get_videos(
|
||||
cache.get_ref().clone(),
|
||||
|
||||
Reference in New Issue
Block a user