From ae5b68578349999bc137d47ef94b59dd138c2bd4 Mon Sep 17 00:00:00 2001 From: PARK BYUNG JUN Date: Wed, 31 Aug 2022 08:41:18 +0000 Subject: [PATCH] betting is added --- src/c2se/api/betting.rs | 90 +++++++++++++++++++++++++++ src/c2se/api/mod.rs | 1 + src/c2se/backend/api/betting.rs | 4 ++ src/c2se/backend/api/mod.rs | 1 + src/models/api/betting.rs | 100 ++++++++++++++++++++++++++++++ src/models/api/mod.rs | 1 + src/ss/api/betting.rs | 106 ++++++++++++++++++++++++++++++++ src/ss/api/mod.rs | 1 + 8 files changed, 304 insertions(+) create mode 100644 src/c2se/api/betting.rs create mode 100644 src/c2se/backend/api/betting.rs create mode 100644 src/models/api/betting.rs create mode 100644 src/ss/api/betting.rs diff --git a/src/c2se/api/betting.rs b/src/c2se/api/betting.rs new file mode 100644 index 0000000..7989168 --- /dev/null +++ b/src/c2se/api/betting.rs @@ -0,0 +1,90 @@ +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct ListBettingHistoryRequest { + #[prost(message, optional, tag = "1")] + pub pagination: ::core::option::Option, + #[prost(message, repeated, tag = "2")] + pub sorts: ::prost::alloc::vec::Vec, + #[prost(message, optional, tag = "3")] + pub search: ::core::option::Option, +} +/// Nested message and enum types in `ListBettingHistoryRequest`. +pub mod list_betting_history_request { + #[derive(Clone, PartialEq, ::prost::Message)] + pub struct Search { + #[prost(string, optional, tag = "1")] + pub member_id: ::core::option::Option<::prost::alloc::string::String>, + #[prost(uint64, optional, tag = "2")] + pub vendor_id: ::core::option::Option, + #[prost(string, optional, tag = "3")] + pub vendor_name: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "4")] + pub vendor_name_like: ::core::option::Option<::prost::alloc::string::String>, + #[prost(uint64, optional, tag = "5")] + pub game_id: ::core::option::Option, + #[prost(string, optional, tag = "6")] + pub game_name: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "7")] + pub game_name_like: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "8")] + pub game_category: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "9")] + pub game_category_like: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "10")] + pub game_type: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "11")] + pub game_type_like: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "12")] + pub currency: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "13")] + pub currency_like: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "14")] + pub key: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "15")] + pub key_like: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "16")] + pub ref_id: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "17")] + pub ref_id_like: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "18")] + pub o_ref_id: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "19")] + pub o_ref_id_like: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "20")] + pub group_key: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "21")] + pub group_key_like: ::core::option::Option<::prost::alloc::string::String>, + #[prost(bool, optional, tag = "22")] + pub is_bonus: ::core::option::Option, + #[prost(bool, optional, tag = "23")] + pub is_promo: ::core::option::Option, + #[prost(bool, optional, tag = "24")] + pub is_jackpot: ::core::option::Option, + #[prost(string, optional, tag = "25")] + pub site_username: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "26")] + pub site_username_like: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "27")] + pub betting_type: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "28")] + pub betting_type_like: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "29")] + pub category: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "30")] + pub category_like: ::core::option::Option<::prost::alloc::string::String>, + } +} +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct ListBettingHistoryResponse { + #[prost(message, optional, tag = "1")] + pub error: ::core::option::Option, + #[prost(message, optional, tag = "2")] + pub result: ::core::option::Option, +} +/// Nested message and enum types in `ListBettingHistoryResponse`. +pub mod list_betting_history_response { + #[derive(Clone, PartialEq, ::prost::Message)] + pub struct Result { + #[prost(message, repeated, tag = "1")] + pub betting_history: ::prost::alloc::vec::Vec, + } +} diff --git a/src/c2se/api/mod.rs b/src/c2se/api/mod.rs index fd2b58f..c0be90e 100644 --- a/src/c2se/api/mod.rs +++ b/src/c2se/api/mod.rs @@ -1,2 +1,3 @@ +pub mod betting; pub mod game; pub mod vendor; diff --git a/src/c2se/backend/api/betting.rs b/src/c2se/backend/api/betting.rs new file mode 100644 index 0000000..4edd789 --- /dev/null +++ b/src/c2se/backend/api/betting.rs @@ -0,0 +1,4 @@ +const SUBJECT: &str = "bet.beteran.c2se.backend.api.betting"; + +pub const SUBJECT_LIST_BETTING_HISTORY: &str = + const_format::concatcp!(SUBJECT, ".ListBettingHistory"); diff --git a/src/c2se/backend/api/mod.rs b/src/c2se/backend/api/mod.rs index fd2b58f..c0be90e 100644 --- a/src/c2se/backend/api/mod.rs +++ b/src/c2se/backend/api/mod.rs @@ -1,2 +1,3 @@ +pub mod betting; pub mod game; pub mod vendor; diff --git a/src/models/api/betting.rs b/src/models/api/betting.rs new file mode 100644 index 0000000..6602f80 --- /dev/null +++ b/src/models/api/betting.rs @@ -0,0 +1,100 @@ +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct BettingHistory { + #[prost(string, tag = "1")] + pub id: ::prost::alloc::string::String, + #[prost(uint64, tag = "2")] + pub vendor_id: u64, + #[prost(string, tag = "3")] + pub vendor_name: ::prost::alloc::string::String, + #[prost(uint64, tag = "4")] + pub game_id: u64, + #[prost(string, tag = "5")] + pub game_name: ::prost::alloc::string::String, + #[prost(string, tag = "6")] + pub game_category: ::prost::alloc::string::String, + #[prost(string, tag = "7")] + pub game_type: ::prost::alloc::string::String, + #[prost(string, tag = "8")] + pub currency: ::prost::alloc::string::String, + #[prost(double, tag = "9")] + pub cash: f64, + #[prost(double, tag = "10")] + pub before_cash: f64, + #[prost(double, tag = "11")] + pub after_cash: f64, + #[prost(string, tag = "12")] + pub key: ::prost::alloc::string::String, + #[prost(string, tag = "13")] + pub ref_id: ::prost::alloc::string::String, + #[prost(string, tag = "14")] + pub o_ref_id: ::prost::alloc::string::String, + #[prost(string, optional, tag = "15")] + pub group_key: ::core::option::Option<::prost::alloc::string::String>, + #[prost(bool, tag = "16")] + pub is_bonus: bool, + #[prost(bool, tag = "17")] + pub is_promo: bool, + #[prost(bool, tag = "18")] + pub is_jackpot: bool, + #[prost(string, tag = "19")] + pub site_username: ::prost::alloc::string::String, + #[prost(string, tag = "20")] + pub betting_type: ::prost::alloc::string::String, + #[prost(string, tag = "21")] + pub category: ::prost::alloc::string::String, + #[prost(uint64, tag = "22")] + pub created_at: u64, + #[prost(uint64, tag = "23")] + pub utc_created_at: u64, +} +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct BettingHistoryModel { + #[prost(string, tag = "1")] + pub id: ::prost::alloc::string::String, + #[prost(message, optional, tag = "2")] + pub member: ::core::option::Option, + #[prost(uint64, tag = "3")] + pub vendor_id: u64, + #[prost(string, tag = "4")] + pub vendor_name: ::prost::alloc::string::String, + #[prost(uint64, tag = "5")] + pub game_id: u64, + #[prost(string, tag = "6")] + pub game_name: ::prost::alloc::string::String, + #[prost(string, tag = "7")] + pub game_category: ::prost::alloc::string::String, + #[prost(string, tag = "8")] + pub game_type: ::prost::alloc::string::String, + #[prost(string, tag = "9")] + pub currency: ::prost::alloc::string::String, + #[prost(double, tag = "10")] + pub cash: f64, + #[prost(double, tag = "11")] + pub before_cash: f64, + #[prost(double, tag = "12")] + pub after_cash: f64, + #[prost(string, tag = "13")] + pub key: ::prost::alloc::string::String, + #[prost(string, tag = "14")] + pub ref_id: ::prost::alloc::string::String, + #[prost(string, tag = "15")] + pub o_ref_id: ::prost::alloc::string::String, + #[prost(string, optional, tag = "16")] + pub group_key: ::core::option::Option<::prost::alloc::string::String>, + #[prost(bool, tag = "17")] + pub is_bonus: bool, + #[prost(bool, tag = "18")] + pub is_promo: bool, + #[prost(bool, tag = "19")] + pub is_jackpot: bool, + #[prost(string, tag = "20")] + pub site_username: ::prost::alloc::string::String, + #[prost(string, tag = "21")] + pub betting_type: ::prost::alloc::string::String, + #[prost(string, tag = "22")] + pub category: ::prost::alloc::string::String, + #[prost(uint64, tag = "23")] + pub created_at: u64, + #[prost(uint64, tag = "24")] + pub utc_created_at: u64, +} diff --git a/src/models/api/mod.rs b/src/models/api/mod.rs index fd2b58f..c0be90e 100644 --- a/src/models/api/mod.rs +++ b/src/models/api/mod.rs @@ -1,2 +1,3 @@ +pub mod betting; pub mod game; pub mod vendor; diff --git a/src/ss/api/betting.rs b/src/ss/api/betting.rs new file mode 100644 index 0000000..f51f2c1 --- /dev/null +++ b/src/ss/api/betting.rs @@ -0,0 +1,106 @@ +const SUBJECT: &str = "bet.beteran.ss.api.betting"; + +pub const SUBJECT_LIST_BETTING_HISTORY: &str = + const_format::concatcp!(SUBJECT, ".ListBettingHistory"); + +/// subject = bet.beteran.ss.api.betting.ListBettingHistory +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct ListBettingHistoryRequest { + #[prost(message, optional, tag = "1")] + pub client: ::core::option::Option, + #[prost(message, optional, tag = "2")] + pub request: ::core::option::Option, +} +/// Nested message and enum types in `ListBettingHistoryRequest`. +pub mod list_betting_history_request { + #[derive(Clone, PartialEq, ::prost::Message)] + pub struct Request { + #[prost(message, optional, tag = "1")] + pub pagination: ::core::option::Option, + #[prost(message, repeated, tag = "2")] + pub sorts: ::prost::alloc::vec::Vec, + #[prost(message, optional, tag = "3")] + pub search: ::core::option::Option, + } + /// Nested message and enum types in `Request`. + pub mod request { + #[derive(Clone, PartialEq, ::prost::Message)] + pub struct Search { + #[prost(string, optional, tag = "1")] + pub member_id: ::core::option::Option<::prost::alloc::string::String>, + #[prost(uint64, optional, tag = "2")] + pub vendor_id: ::core::option::Option, + #[prost(string, optional, tag = "3")] + pub vendor_name: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "4")] + pub vendor_name_like: ::core::option::Option<::prost::alloc::string::String>, + #[prost(uint64, optional, tag = "5")] + pub game_id: ::core::option::Option, + #[prost(string, optional, tag = "6")] + pub game_name: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "7")] + pub game_name_like: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "8")] + pub game_category: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "9")] + pub game_category_like: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "10")] + pub game_type: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "11")] + pub game_type_like: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "12")] + pub currency: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "13")] + pub currency_like: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "14")] + pub key: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "15")] + pub key_like: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "16")] + pub ref_id: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "17")] + pub ref_id_like: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "18")] + pub o_ref_id: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "19")] + pub o_ref_id_like: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "20")] + pub group_key: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "21")] + pub group_key_like: ::core::option::Option<::prost::alloc::string::String>, + #[prost(bool, optional, tag = "22")] + pub is_bonus: ::core::option::Option, + #[prost(bool, optional, tag = "23")] + pub is_promo: ::core::option::Option, + #[prost(bool, optional, tag = "24")] + pub is_jackpot: ::core::option::Option, + #[prost(string, optional, tag = "25")] + pub site_username: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "26")] + pub site_username_like: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "27")] + pub betting_type: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "28")] + pub betting_type_like: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "29")] + pub category: ::core::option::Option<::prost::alloc::string::String>, + #[prost(string, optional, tag = "30")] + pub category_like: ::core::option::Option<::prost::alloc::string::String>, + } + } +} +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct ListBettingHistoryResponse { + #[prost(message, optional, tag = "1")] + pub error: ::core::option::Option, + #[prost(message, optional, tag = "2")] + pub result: ::core::option::Option, +} +/// Nested message and enum types in `ListBettingHistoryResponse`. +pub mod list_betting_history_response { + #[derive(Clone, PartialEq, ::prost::Message)] + pub struct Result { + #[prost(message, repeated, tag = "1")] + pub betting_history: ::prost::alloc::vec::Vec, + } +} diff --git a/src/ss/api/mod.rs b/src/ss/api/mod.rs index fd2b58f..c0be90e 100644 --- a/src/ss/api/mod.rs +++ b/src/ss/api/mod.rs @@ -1,2 +1,3 @@ +pub mod betting; pub mod game; pub mod vendor;