bank is added

This commit is contained in:
병준 박 2022-08-12 06:42:07 +00:00
parent ee22fe015d
commit 2dcdf56318
8 changed files with 221 additions and 0 deletions

View File

@ -43,6 +43,7 @@ static TARGETS: Lazy<HashMap<&str, Vec<&str>>> = Lazy::new(|| {
"./proto/models/member/member_level.proto", "./proto/models/member/member_level.proto",
"./proto/models/member/member.proto", "./proto/models/member/member.proto",
"./proto/models/member/member_session.proto", "./proto/models/member/member_session.proto",
"./proto/models/account/bank.proto",
], ],
); );
@ -51,9 +52,12 @@ static TARGETS: Lazy<HashMap<&str, Vec<&str>>> = Lazy::new(|| {
vec![ vec![
"./proto/c2se/core/network.proto", "./proto/c2se/core/network.proto",
"./proto/c2se/common/identity.proto", "./proto/c2se/common/identity.proto",
"./proto/c2se/common/bank.proto",
"./proto/c2se/backend/site.proto", "./proto/c2se/backend/site.proto",
"./proto/c2se/backend/account.proto",
"./proto/c2se/backend/identity.proto", "./proto/c2se/backend/identity.proto",
"./proto/c2se/backend/member.proto", "./proto/c2se/backend/member.proto",
"./proto/c2se/frontend/account.proto",
"./proto/c2se/frontend/identity.proto", "./proto/c2se/frontend/identity.proto",
], ],
); );
@ -64,6 +68,7 @@ static TARGETS: Lazy<HashMap<&str, Vec<&str>>> = Lazy::new(|| {
"./proto/ss/domain/site.proto", "./proto/ss/domain/site.proto",
"./proto/ss/member/identity.proto", "./proto/ss/member/identity.proto",
"./proto/ss/member/member.proto", "./proto/ss/member/member.proto",
"./proto/ss/account/bank.proto",
], ],
); );

View File

@ -0,0 +1,4 @@
// subject = bet.beteran.c2se.backend.bank.ListBanks
// subject = bet.beteran.c2se.backend.bank.CreateBank
// subject = bet.beteran.c2se.backend.bank.UpdateBank
// subject = bet.beteran.c2se.backend.bank.DeleteBank

View File

@ -10,6 +10,26 @@ import "protobuf/pagination/sort.proto";
import "models/member/member.proto"; import "models/member/member.proto";
// subject = bet.beteran.c2se.backend.member.CreateMember
message CreateMemberRequest {
string site_id = 1;
string member_class_id = 2;
string member_level_id = 3;
optional string referrer_member_id = 4;
string username = 5;
string nickname = 6;
optional string mobile_phone_number = 7;
bet.beteran.member.MemberState state = 8;
}
message CreateMemberResponse {
message Result {
bet.beteran.member.MemberModel member = 1;
}
optional bet.protobuf.rpc.Error error = 1;
optional Result result = 2;
}
// subject = bet.beteran.c2se.backend.member.ListMembers // subject = bet.beteran.c2se.backend.member.ListMembers
message ListMembersRequest { message ListMembersRequest {
optional bet.protobuf.pagination.Pagination pagination = 1; optional bet.protobuf.pagination.Pagination pagination = 1;
@ -35,6 +55,8 @@ message ListMembersResponse {
optional Result result = 2; optional Result result = 2;
} }
// subject = bet.beteran.c2se.backend.member.GetMember // subject = bet.beteran.c2se.backend.member.GetMember
message GetMemberRequest { message GetMemberRequest {
string id = 1; string id = 1;

View File

@ -0,0 +1,77 @@
syntax = "proto3";
package bet.beteran.c2se.common.bank;
import "protobuf/rpc/error.proto";
import "protobuf/pagination/pagination.proto";
import "protobuf/pagination/search.proto";
import "protobuf/pagination/sort.proto";
import "models/account/bank.proto";
// subject = bet.beteran.c2se.common.bank.CreateBank
message CreateBankRequest {
string name = 1;
bool show = 2;
bool can_use = 3;
optional string memo = 4;
optional uint64 expires_at = 5;
}
message CreateBankResponse {
message Result {
bet.beteran.account.Bank bank = 1;
}
optional bet.protobuf.rpc.Error error = 1;
optional Result result = 2;
}
// subject = bet.beteran.c2se.common.bank.ListBanks
message ListBanksRequest {
optional bet.protobuf.pagination.Pagination pagination = 1;
repeated bet.protobuf.pagination.Search searches = 2;
repeated bet.protobuf.pagination.Sort sorts = 3;
optional string name_like = 4;
optional bool show = 5;
optional bool can_use = 6;
optional string memo_like = 7;
}
message ListBanksResponse {
message Result {
repeated bet.beteran.account.Bank banks = 1;
}
optional bet.protobuf.rpc.Error error = 1;
optional Result result = 2;
}
// subject = bet.beteran.c2se.common.bank.UpdateBank
message UpdateBankRequest {
string id = 1;
string name = 2;
bool show = 3;
bool can_use = 4;
optional string memo = 5;
}
message UpdateBankResponse {
message Result {
bet.beteran.account.Bank bank = 1;
}
optional bet.protobuf.rpc.Error error = 1;
optional Result result = 2;
}
// subject = bet.beteran.c2se.common.bank.DeleteBank
message DeleteBankRequest {
string id = 1;
}
message DeleteBankResponse {
message Result {
}
optional bet.protobuf.rpc.Error error = 1;
optional Result result = 2;
}

View File

@ -0,0 +1 @@
// subject = bet.beteran.c2se.frontend.bank.ListBanks

View File

@ -0,0 +1,13 @@
syntax = "proto3";
package bet.beteran.account;
message Bank {
string id = 1;
string name = 2;
bool show = 3;
bool can_use = 4;
optional string memo = 5;
uint64 created_at = 6;
uint64 updated_at = 7;
}

View File

@ -0,0 +1,79 @@
syntax = "proto3";
package bet.beteran.ss.account.bank;
import "protobuf/rpc/error.proto";
import "protobuf/pagination/pagination.proto";
import "protobuf/pagination/search.proto";
import "protobuf/pagination/sort.proto";
import "models/core/network.proto";
import "models/account/bank.proto";
// subject = bet.beteran.ss.account.bank.ListBanks;
message ListBanksRequest {
bet.beteran.core.network.Client client = 1;
optional bet.protobuf.pagination.Pagination pagination = 2;
repeated bet.protobuf.pagination.Search searches = 3;
repeated bet.protobuf.pagination.Sort sorts = 4;
optional string name_like = 5;
optional bool show = 6;
optional bool can_use = 7;
optional string memo_like = 8;
}
message ListBanksResponse {
message Result {
repeated bet.beteran.account.Bank banks = 1;
}
optional bet.protobuf.rpc.Error error = 1;
optional Result result = 2;
}
// subject = bet.beteran.ss.account.bank.CreateBank;
message CreateBankRequest {
bet.beteran.core.network.Client client = 1;
string name = 2;
bool show = 3;
bool can_use = 4;
optional string memo = 5;
}
message CreateBankResponse {
message Result {
bet.beteran.account.Bank bank = 1;
}
optional bet.protobuf.rpc.Error error = 1;
optional Result result = 2;
}
// subject = bet.beteran.ss.account.bank.UpdateBank
message UpdateBankRequest {
bet.beteran.core.network.Client client = 1;
string id = 2;
string name = 3;
bool show = 4;
bool can_use = 5;
optional string memo = 6;
}
message UpdateBankResponse {
message Result {
bet.beteran.account.Bank bank = 1;
}
optional bet.protobuf.rpc.Error error = 1;
optional Result result = 2;
}
// subject = bet.beteran.ss.account.bank.DeleteBank
message DeleteBankRequest {
bet.beteran.core.network.Client client = 1;
string id = 2;
}
message DeleteBankResponse {
message Result {
}
optional bet.protobuf.rpc.Error error = 1;
optional Result result = 2;
}

View File

@ -10,6 +10,26 @@ import "protobuf/pagination/sort.proto";
import "models/member/member.proto"; import "models/member/member.proto";
// subject = bet.beteran.ss.member.CreateMember
message CreateMemberRequest {
bet.beteran.core.network.Client client = 1;
string site_id = 2;
string member_class_id = 3;
string member_level_id = 4;
optional string referrer_member_id = 5;
string username = 6;
string nickname = 7;
optional string mobile_phone_number = 8;
bet.beteran.member.MemberState state = 9;
}
message CreateMemberResponse {
message Result {
bet.beteran.member.MemberModel member = 1;
}
optional bet.protobuf.rpc.Error error = 1;
optional Result result = 2;
}
// subject = bet.beteran.ss.member.ListMembers // subject = bet.beteran.ss.member.ListMembers
message ListMembersRequest { message ListMembersRequest {