|
|
@ -27,82 +27,37 @@ enum DistrictQueryType {
|
|
|
|
Parents = 3;
|
|
|
|
Parents = 3;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message DepartmentInfo {
|
|
|
|
|
|
|
|
int64 ID = 1;
|
|
|
|
|
|
|
|
string status = 2;
|
|
|
|
|
|
|
|
string created_at = 3;
|
|
|
|
|
|
|
|
string updated_at = 4;
|
|
|
|
|
|
|
|
string name = 5;
|
|
|
|
|
|
|
|
int64 leader_id = 6;
|
|
|
|
|
|
|
|
string remark = 7;
|
|
|
|
|
|
|
|
int64 parent_id = 8;
|
|
|
|
|
|
|
|
DepartmentInfo parent = 10;
|
|
|
|
|
|
|
|
repeated DepartmentInfo children = 11;
|
|
|
|
|
|
|
|
repeated UserInfo users = 12;
|
|
|
|
|
|
|
|
UserInfo leader = 13;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message DeleteDictionaryDetailReq {
|
|
|
|
|
|
|
|
repeated int64 ids = 1;
|
|
|
|
|
|
|
|
int64 dict_id = 2;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message UserSocialListResp {
|
|
|
|
|
|
|
|
optional Pagination page = 1;
|
|
|
|
|
|
|
|
repeated UserSocialInfo data = 2;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// 基础回执
|
|
|
|
// 基础回执
|
|
|
|
message BaseResp {
|
|
|
|
message BaseResp {
|
|
|
|
int32 code = 1;
|
|
|
|
int32 code = 1;
|
|
|
|
string msg = 2;
|
|
|
|
string msg = 2;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message GetDistrictNameResp {
|
|
|
|
message DistrictTree {
|
|
|
|
string code = 1;
|
|
|
|
repeated DistrictInfo tree = 1;
|
|
|
|
string name = 2;
|
|
|
|
|
|
|
|
repeated string name_list = 3;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message RecordReq {
|
|
|
|
|
|
|
|
int64 user_id = 1;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message OauthProviderListResp {
|
|
|
|
|
|
|
|
optional Pagination page = 1;
|
|
|
|
|
|
|
|
repeated OauthProviderInfo data = 2;
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message TokenInfo {
|
|
|
|
message RoleReq {
|
|
|
|
int64 ID = 1;
|
|
|
|
int64 ID = 1;
|
|
|
|
string status = 2;
|
|
|
|
string name = 2;
|
|
|
|
string created_at = 3;
|
|
|
|
string code = 3;
|
|
|
|
string updated_at = 4;
|
|
|
|
bool with_user = 4;
|
|
|
|
int64 user_id = 5;
|
|
|
|
optional Pagination page = 10;
|
|
|
|
string access_token = 6;
|
|
|
|
|
|
|
|
string refresh_token = 7;
|
|
|
|
|
|
|
|
string source = 8;
|
|
|
|
|
|
|
|
int64 expired_at = 9;
|
|
|
|
|
|
|
|
UserInfo user = 10;
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message UserReq {
|
|
|
|
message TokenReq {
|
|
|
|
int64 ID = 1;
|
|
|
|
int64 ID = 1;
|
|
|
|
string username = 2;
|
|
|
|
int64 user_id = 2;
|
|
|
|
string phone_number = 3;
|
|
|
|
string username = 3;
|
|
|
|
string email = 4;
|
|
|
|
string phone_number = 4;
|
|
|
|
string nickname = 5;
|
|
|
|
string email = 5;
|
|
|
|
bool with_role = 6;
|
|
|
|
bool with_user = 6;
|
|
|
|
bool with_social = 7;
|
|
|
|
optional Pagination page = 10;
|
|
|
|
bool with_department = 8;
|
|
|
|
|
|
|
|
bool with_token = 9;
|
|
|
|
|
|
|
|
bool with_login_record = 10;
|
|
|
|
|
|
|
|
optional Pagination page = 20;
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message GetUserRolesReq {
|
|
|
|
message UserSocialListResp {
|
|
|
|
optional Pagination page = 1;
|
|
|
|
optional Pagination page = 1;
|
|
|
|
int64 user_id = 2;
|
|
|
|
repeated UserSocialInfo data = 2;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message DepartmentListResp {
|
|
|
|
message DepartmentListResp {
|
|
|
@ -110,23 +65,22 @@ message DepartmentListResp {
|
|
|
|
repeated DepartmentInfo data = 2;
|
|
|
|
repeated DepartmentInfo data = 2;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message DictionaryDetailListResp {
|
|
|
|
message DictionaryReq {
|
|
|
|
optional Pagination page = 1;
|
|
|
|
int64 ID = 1;
|
|
|
|
repeated DictionaryDetailInfo data = 2;
|
|
|
|
string name = 2;
|
|
|
|
|
|
|
|
string title = 3;
|
|
|
|
|
|
|
|
bool with_details = 4;
|
|
|
|
|
|
|
|
optional Pagination page = 10;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message DistrictListResp {
|
|
|
|
message DeleteDictionaryDetailReq {
|
|
|
|
optional Pagination page = 1;
|
|
|
|
repeated int64 ids = 1;
|
|
|
|
repeated DistrictInfo data = 2;
|
|
|
|
int64 dict_id = 2;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message OauthProviderReq {
|
|
|
|
message GetDistrictNameReq {
|
|
|
|
int64 ID = 1;
|
|
|
|
string code = 1;
|
|
|
|
string name = 2;
|
|
|
|
string separator = 2;
|
|
|
|
string client_id = 3;
|
|
|
|
|
|
|
|
optional bool system = 4;
|
|
|
|
|
|
|
|
optional bool init = 5;
|
|
|
|
|
|
|
|
optional Pagination page = 10;
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message CallbackReq {
|
|
|
|
message CallbackReq {
|
|
|
@ -134,56 +88,80 @@ message CallbackReq {
|
|
|
|
string code = 2;
|
|
|
|
string code = 2;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message OauthRedirectResp {
|
|
|
|
message RoleInfo {
|
|
|
|
string url = 1;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message UserInfo {
|
|
|
|
|
|
|
|
int64 ID = 1;
|
|
|
|
int64 ID = 1;
|
|
|
|
string status = 2;
|
|
|
|
string status = 2;
|
|
|
|
string created_at = 3;
|
|
|
|
string created_at = 3;
|
|
|
|
string updated_at = 4;
|
|
|
|
string updated_at = 4;
|
|
|
|
string username = 5;
|
|
|
|
string code = 5;
|
|
|
|
optional string phone_number = 6;
|
|
|
|
string name = 6;
|
|
|
|
optional string email = 7;
|
|
|
|
string description = 7;
|
|
|
|
string password = 8;
|
|
|
|
repeated UserInfo users = 10;
|
|
|
|
optional string nickname = 9;
|
|
|
|
|
|
|
|
map<string,string> metas = 10;
|
|
|
|
|
|
|
|
repeated RoleInfo roles = 20;
|
|
|
|
|
|
|
|
repeated UserSocialInfo socials = 21;
|
|
|
|
|
|
|
|
repeated DepartmentInfo departments = 22;
|
|
|
|
|
|
|
|
repeated TokenInfo tokens = 23;
|
|
|
|
|
|
|
|
LoginRecordInfo login_record = 24;
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message UserRoleReq {
|
|
|
|
message UserSocialInfo {
|
|
|
|
int64 user_id = 1;
|
|
|
|
int64 ID = 1;
|
|
|
|
repeated int64 role_ids = 2;
|
|
|
|
string created_at = 2;
|
|
|
|
repeated string role_codes = 3;
|
|
|
|
string updated_at = 3;
|
|
|
|
|
|
|
|
int64 user_id = 4;
|
|
|
|
|
|
|
|
string provider = 5;
|
|
|
|
|
|
|
|
string access_token = 6;
|
|
|
|
|
|
|
|
string refresh_token = 7;
|
|
|
|
|
|
|
|
string uid = 8;
|
|
|
|
|
|
|
|
string open_id = 9;
|
|
|
|
|
|
|
|
string union_id = 10;
|
|
|
|
|
|
|
|
string key = 11;
|
|
|
|
|
|
|
|
uint64 expires_in = 12;
|
|
|
|
|
|
|
|
string user_profile = 13;
|
|
|
|
|
|
|
|
UserInfo user = 14;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message DictionaryInfo {
|
|
|
|
message DepartmentInfo {
|
|
|
|
int64 ID = 1;
|
|
|
|
int64 ID = 1;
|
|
|
|
string status = 2;
|
|
|
|
string status = 2;
|
|
|
|
string created_at = 3;
|
|
|
|
string created_at = 3;
|
|
|
|
string updated_at = 4;
|
|
|
|
string updated_at = 4;
|
|
|
|
string title = 5;
|
|
|
|
string name = 5;
|
|
|
|
string name = 6;
|
|
|
|
int64 leader_id = 6;
|
|
|
|
string description = 7;
|
|
|
|
string remark = 7;
|
|
|
|
repeated DictionaryDetailInfo details = 10;
|
|
|
|
int64 parent_id = 8;
|
|
|
|
|
|
|
|
DepartmentInfo parent = 10;
|
|
|
|
|
|
|
|
repeated DepartmentInfo children = 11;
|
|
|
|
|
|
|
|
repeated UserInfo users = 12;
|
|
|
|
|
|
|
|
UserInfo leader = 13;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message DictionaryDetailInfo {
|
|
|
|
// DistrictInfo 地址单体结构
|
|
|
|
|
|
|
|
message DistrictInfo {
|
|
|
|
int64 ID = 1;
|
|
|
|
int64 ID = 1;
|
|
|
|
string status = 2;
|
|
|
|
string created_at = 2;
|
|
|
|
string created_at = 3;
|
|
|
|
string updated_at = 3;
|
|
|
|
string updated_at = 4;
|
|
|
|
string name = 4;
|
|
|
|
string title = 5;
|
|
|
|
string short_name = 5;
|
|
|
|
string key = 6;
|
|
|
|
string code = 6;
|
|
|
|
string value = 7;
|
|
|
|
string province = 7;
|
|
|
|
uint32 sort = 8;
|
|
|
|
string city = 8;
|
|
|
|
int64 dictionary_id = 9;
|
|
|
|
string area = 9;
|
|
|
|
DictionaryInfo dictionary = 10;
|
|
|
|
string street = 10;
|
|
|
|
|
|
|
|
uint32 level = 11;
|
|
|
|
|
|
|
|
double latitude = 12;
|
|
|
|
|
|
|
|
double longitude = 13;
|
|
|
|
|
|
|
|
repeated DistrictInfo children = 20;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message DistrictListResp {
|
|
|
|
|
|
|
|
optional Pagination page = 1;
|
|
|
|
|
|
|
|
repeated DistrictInfo data = 2;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message RecordReq {
|
|
|
|
|
|
|
|
int64 user_id = 1;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message UserRoleReq {
|
|
|
|
|
|
|
|
int64 user_id = 1;
|
|
|
|
|
|
|
|
repeated int64 role_ids = 2;
|
|
|
|
|
|
|
|
repeated string role_codes = 3;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message DistrictReq {
|
|
|
|
message DistrictReq {
|
|
|
@ -199,67 +177,12 @@ message DistrictReq {
|
|
|
|
DistrictQueryType query_type = 11;
|
|
|
|
DistrictQueryType query_type = 11;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message DistrictCodeReq {
|
|
|
|
message OauthProviderReq {
|
|
|
|
string code = 1;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// 分页参数
|
|
|
|
|
|
|
|
message Pagination {
|
|
|
|
|
|
|
|
uint64 size = 1;
|
|
|
|
|
|
|
|
uint64 total = 2;
|
|
|
|
|
|
|
|
uint64 current = 3;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message GetDistrictNameReq {
|
|
|
|
|
|
|
|
string code = 1;
|
|
|
|
|
|
|
|
string separator = 2;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message LoginRecordInfo {
|
|
|
|
|
|
|
|
int64 ID = 1;
|
|
|
|
|
|
|
|
string created_at = 3;
|
|
|
|
|
|
|
|
string updated_at = 4;
|
|
|
|
|
|
|
|
int64 user_id = 5;
|
|
|
|
|
|
|
|
string last_login_at = 6;
|
|
|
|
|
|
|
|
string last_login_ipv4 = 7;
|
|
|
|
|
|
|
|
string last_login_device = 8;
|
|
|
|
|
|
|
|
string last_login_ua = 9;
|
|
|
|
|
|
|
|
uint64 login_count = 10;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message OauthProviderInfo {
|
|
|
|
|
|
|
|
int64 ID = 1;
|
|
|
|
|
|
|
|
string created_at = 2;
|
|
|
|
|
|
|
|
string updated_at = 3;
|
|
|
|
|
|
|
|
string name = 4;
|
|
|
|
|
|
|
|
string client_id = 5;
|
|
|
|
|
|
|
|
string client_secret = 6;
|
|
|
|
|
|
|
|
string redirect_url = 7;
|
|
|
|
|
|
|
|
string scopes = 8;
|
|
|
|
|
|
|
|
string auth_url = 9;
|
|
|
|
|
|
|
|
string token_url = 10;
|
|
|
|
|
|
|
|
string info_url = 11;
|
|
|
|
|
|
|
|
string description = 12;
|
|
|
|
|
|
|
|
bool system = 13;
|
|
|
|
|
|
|
|
bool init = 14;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message OauthLoginReq {
|
|
|
|
|
|
|
|
string state = 1;
|
|
|
|
|
|
|
|
string provider = 2;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message TokenUserReq {
|
|
|
|
|
|
|
|
int64 user_id = 1;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message TokenReq {
|
|
|
|
|
|
|
|
int64 ID = 1;
|
|
|
|
int64 ID = 1;
|
|
|
|
int64 user_id = 2;
|
|
|
|
string name = 2;
|
|
|
|
string username = 3;
|
|
|
|
string client_id = 3;
|
|
|
|
string phone_number = 4;
|
|
|
|
optional bool system = 4;
|
|
|
|
string email = 5;
|
|
|
|
optional bool init = 5;
|
|
|
|
bool with_user = 6;
|
|
|
|
|
|
|
|
optional Pagination page = 10;
|
|
|
|
optional Pagination page = 10;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
@ -268,6 +191,20 @@ message TokenListResp {
|
|
|
|
repeated TokenInfo data = 2;
|
|
|
|
repeated TokenInfo data = 2;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message UserReq {
|
|
|
|
|
|
|
|
int64 ID = 1;
|
|
|
|
|
|
|
|
string username = 2;
|
|
|
|
|
|
|
|
string phone_number = 3;
|
|
|
|
|
|
|
|
string email = 4;
|
|
|
|
|
|
|
|
string nickname = 5;
|
|
|
|
|
|
|
|
bool with_role = 6;
|
|
|
|
|
|
|
|
bool with_social = 7;
|
|
|
|
|
|
|
|
bool with_department = 8;
|
|
|
|
|
|
|
|
bool with_token = 9;
|
|
|
|
|
|
|
|
bool with_login_record = 10;
|
|
|
|
|
|
|
|
optional Pagination page = 20;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message DictionaryDetailReq {
|
|
|
|
message DictionaryDetailReq {
|
|
|
|
optional Pagination page = 1;
|
|
|
|
optional Pagination page = 1;
|
|
|
|
int64 ID = 2;
|
|
|
|
int64 ID = 2;
|
|
|
@ -278,12 +215,54 @@ message DictionaryDetailReq {
|
|
|
|
bool with_dictionary = 7;
|
|
|
|
bool with_dictionary = 7;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message DictionaryReq {
|
|
|
|
message GetDistrictNameResp {
|
|
|
|
int64 ID = 1;
|
|
|
|
string code = 1;
|
|
|
|
string name = 2;
|
|
|
|
string name = 2;
|
|
|
|
string title = 3;
|
|
|
|
repeated string name_list = 3;
|
|
|
|
bool with_details = 4;
|
|
|
|
}
|
|
|
|
optional Pagination page = 10;
|
|
|
|
|
|
|
|
|
|
|
|
message GetUserRolesReq {
|
|
|
|
|
|
|
|
optional Pagination page = 1;
|
|
|
|
|
|
|
|
int64 user_id = 2;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// Base message
|
|
|
|
|
|
|
|
message Empty {}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// 基础回执带ID
|
|
|
|
|
|
|
|
message BaseIDResp {
|
|
|
|
|
|
|
|
int64 ID = 1;
|
|
|
|
|
|
|
|
int32 code = 2;
|
|
|
|
|
|
|
|
string msg = 3;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message DictionaryInfo {
|
|
|
|
|
|
|
|
int64 ID = 1;
|
|
|
|
|
|
|
|
string status = 2;
|
|
|
|
|
|
|
|
string created_at = 3;
|
|
|
|
|
|
|
|
string updated_at = 4;
|
|
|
|
|
|
|
|
string title = 5;
|
|
|
|
|
|
|
|
string name = 6;
|
|
|
|
|
|
|
|
string description = 7;
|
|
|
|
|
|
|
|
repeated DictionaryDetailInfo details = 10;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message DictionaryDetailInfo {
|
|
|
|
|
|
|
|
int64 ID = 1;
|
|
|
|
|
|
|
|
string status = 2;
|
|
|
|
|
|
|
|
string created_at = 3;
|
|
|
|
|
|
|
|
string updated_at = 4;
|
|
|
|
|
|
|
|
string title = 5;
|
|
|
|
|
|
|
|
string key = 6;
|
|
|
|
|
|
|
|
string value = 7;
|
|
|
|
|
|
|
|
uint32 sort = 8;
|
|
|
|
|
|
|
|
int64 dictionary_id = 9;
|
|
|
|
|
|
|
|
DictionaryInfo dictionary = 10;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message OauthProviderListResp {
|
|
|
|
|
|
|
|
optional Pagination page = 1;
|
|
|
|
|
|
|
|
repeated OauthProviderInfo data = 2;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message RoleListResp {
|
|
|
|
message RoleListResp {
|
|
|
@ -291,21 +270,16 @@ message RoleListResp {
|
|
|
|
repeated RoleInfo data = 2;
|
|
|
|
repeated RoleInfo data = 2;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message UserSocialInfo {
|
|
|
|
message TokenUserReq {
|
|
|
|
|
|
|
|
int64 user_id = 1;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message IDReq {
|
|
|
|
int64 ID = 1;
|
|
|
|
int64 ID = 1;
|
|
|
|
string created_at = 2;
|
|
|
|
}
|
|
|
|
string updated_at = 3;
|
|
|
|
|
|
|
|
int64 user_id = 4;
|
|
|
|
message IDsReq {
|
|
|
|
string provider = 5;
|
|
|
|
repeated int64 ids = 1;
|
|
|
|
string access_token = 6;
|
|
|
|
|
|
|
|
string refresh_token = 7;
|
|
|
|
|
|
|
|
string uid = 8;
|
|
|
|
|
|
|
|
string open_id = 9;
|
|
|
|
|
|
|
|
string union_id = 10;
|
|
|
|
|
|
|
|
string key = 11;
|
|
|
|
|
|
|
|
uint64 expires_in = 12;
|
|
|
|
|
|
|
|
string user_profile = 13;
|
|
|
|
|
|
|
|
UserInfo user = 14;
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message DepartmentReq {
|
|
|
|
message DepartmentReq {
|
|
|
@ -319,86 +293,112 @@ message DepartmentReq {
|
|
|
|
optional Pagination page = 10;
|
|
|
|
optional Pagination page = 10;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// 基础回执带ID
|
|
|
|
|
|
|
|
message BaseIDResp {
|
|
|
|
|
|
|
|
int64 ID = 1;
|
|
|
|
|
|
|
|
int32 code = 2;
|
|
|
|
|
|
|
|
string msg = 3;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message DictionaryListResp {
|
|
|
|
message DictionaryListResp {
|
|
|
|
optional Pagination page = 1;
|
|
|
|
optional Pagination page = 1;
|
|
|
|
repeated DictionaryInfo data = 2;
|
|
|
|
repeated DictionaryInfo data = 2;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// DistrictInfo 地址单体结构
|
|
|
|
message UserSocialReq {
|
|
|
|
message DistrictInfo {
|
|
|
|
|
|
|
|
int64 ID = 1;
|
|
|
|
int64 ID = 1;
|
|
|
|
string created_at = 2;
|
|
|
|
int64 user_id = 2;
|
|
|
|
string updated_at = 3;
|
|
|
|
string provider = 3;
|
|
|
|
string name = 4;
|
|
|
|
string access_token = 4;
|
|
|
|
string short_name = 5;
|
|
|
|
string uid = 5;
|
|
|
|
string code = 6;
|
|
|
|
string open_id = 6;
|
|
|
|
string province = 7;
|
|
|
|
string union_id = 7;
|
|
|
|
string city = 8;
|
|
|
|
bool with_user = 8;
|
|
|
|
string area = 9;
|
|
|
|
optional Pagination page = 10;
|
|
|
|
string street = 10;
|
|
|
|
|
|
|
|
uint32 level = 11;
|
|
|
|
|
|
|
|
double latitude = 12;
|
|
|
|
|
|
|
|
double longitude = 13;
|
|
|
|
|
|
|
|
repeated DistrictInfo children = 20;
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message DistrictTree {
|
|
|
|
message DictionaryDetailListResp {
|
|
|
|
repeated DistrictInfo tree = 1;
|
|
|
|
optional Pagination page = 1;
|
|
|
|
|
|
|
|
repeated DictionaryDetailInfo data = 2;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message RoleReq {
|
|
|
|
message LoginRecordInfo {
|
|
|
|
int64 ID = 1;
|
|
|
|
int64 ID = 1;
|
|
|
|
string name = 2;
|
|
|
|
string created_at = 3;
|
|
|
|
string code = 3;
|
|
|
|
string updated_at = 4;
|
|
|
|
bool with_user = 4;
|
|
|
|
int64 user_id = 5;
|
|
|
|
optional Pagination page = 10;
|
|
|
|
string last_login_at = 6;
|
|
|
|
}
|
|
|
|
string last_login_ipv4 = 7;
|
|
|
|
|
|
|
|
string last_login_device = 8;
|
|
|
|
message UserListResp {
|
|
|
|
string last_login_ua = 9;
|
|
|
|
optional Pagination page = 1;
|
|
|
|
uint64 login_count = 10;
|
|
|
|
repeated UserInfo data = 2;
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message IDsReq {
|
|
|
|
message OauthLoginReq {
|
|
|
|
repeated int64 ids = 1;
|
|
|
|
string state = 1;
|
|
|
|
|
|
|
|
string provider = 2;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message IDReq {
|
|
|
|
message TokenInfo {
|
|
|
|
int64 ID = 1;
|
|
|
|
int64 ID = 1;
|
|
|
|
|
|
|
|
string status = 2;
|
|
|
|
|
|
|
|
string created_at = 3;
|
|
|
|
|
|
|
|
string updated_at = 4;
|
|
|
|
|
|
|
|
int64 user_id = 5;
|
|
|
|
|
|
|
|
string access_token = 6;
|
|
|
|
|
|
|
|
string refresh_token = 7;
|
|
|
|
|
|
|
|
string source = 8;
|
|
|
|
|
|
|
|
int64 expired_at = 9;
|
|
|
|
|
|
|
|
UserInfo user = 10;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message RoleInfo {
|
|
|
|
message UserInfo {
|
|
|
|
int64 ID = 1;
|
|
|
|
int64 ID = 1;
|
|
|
|
string status = 2;
|
|
|
|
string status = 2;
|
|
|
|
string created_at = 3;
|
|
|
|
string created_at = 3;
|
|
|
|
string updated_at = 4;
|
|
|
|
string updated_at = 4;
|
|
|
|
string code = 5;
|
|
|
|
string username = 5;
|
|
|
|
string name = 6;
|
|
|
|
optional string phone_number = 6;
|
|
|
|
string description = 7;
|
|
|
|
optional string email = 7;
|
|
|
|
repeated UserInfo users = 10;
|
|
|
|
string password = 8;
|
|
|
|
|
|
|
|
optional string nickname = 9;
|
|
|
|
|
|
|
|
map<string,string> metas = 10;
|
|
|
|
|
|
|
|
repeated RoleInfo roles = 20;
|
|
|
|
|
|
|
|
repeated UserSocialInfo socials = 21;
|
|
|
|
|
|
|
|
repeated DepartmentInfo departments = 22;
|
|
|
|
|
|
|
|
repeated TokenInfo tokens = 23;
|
|
|
|
|
|
|
|
LoginRecordInfo login_record = 24;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message UserSocialReq {
|
|
|
|
message UserListResp {
|
|
|
|
|
|
|
|
optional Pagination page = 1;
|
|
|
|
|
|
|
|
repeated UserInfo data = 2;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// 分页参数
|
|
|
|
|
|
|
|
message Pagination {
|
|
|
|
|
|
|
|
uint64 size = 1;
|
|
|
|
|
|
|
|
uint64 total = 2;
|
|
|
|
|
|
|
|
uint64 current = 3;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message DistrictCodeReq {
|
|
|
|
|
|
|
|
string code = 1;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message OauthProviderInfo {
|
|
|
|
int64 ID = 1;
|
|
|
|
int64 ID = 1;
|
|
|
|
int64 user_id = 2;
|
|
|
|
string created_at = 2;
|
|
|
|
string provider = 3;
|
|
|
|
string updated_at = 3;
|
|
|
|
string access_token = 4;
|
|
|
|
string name = 4;
|
|
|
|
string uid = 5;
|
|
|
|
string client_id = 5;
|
|
|
|
string open_id = 6;
|
|
|
|
string client_secret = 6;
|
|
|
|
string union_id = 7;
|
|
|
|
string redirect_url = 7;
|
|
|
|
bool with_user = 8;
|
|
|
|
string scopes = 8;
|
|
|
|
optional Pagination page = 10;
|
|
|
|
string auth_url = 9;
|
|
|
|
|
|
|
|
string token_url = 10;
|
|
|
|
|
|
|
|
string info_url = 11;
|
|
|
|
|
|
|
|
string description = 12;
|
|
|
|
|
|
|
|
bool system = 13;
|
|
|
|
|
|
|
|
bool init = 14;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// Base message
|
|
|
|
message OauthRedirectResp {
|
|
|
|
message Empty {}
|
|
|
|
string url = 1;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
service Core {
|
|
|
|
service Core {
|
|
|
|
// group: base
|
|
|
|
// group: base
|
|
|
@ -503,16 +503,16 @@ service Core {
|
|
|
|
// User-Role Relationship Management
|
|
|
|
// User-Role Relationship Management
|
|
|
|
// UserBindRole 用户绑定角色
|
|
|
|
// UserBindRole 用户绑定角色
|
|
|
|
// group: user_role
|
|
|
|
// group: user_role
|
|
|
|
rpc UserBindRole(UserRoleReq) returns (BaseResp);
|
|
|
|
rpc userBindRole(UserRoleReq) returns (BaseResp);
|
|
|
|
// UserUnbindRole 用户解绑角色
|
|
|
|
// UserUnbindRole 用户解绑角色
|
|
|
|
// group: user_role
|
|
|
|
// group: user_role
|
|
|
|
rpc UserUnbindRole(UserRoleReq) returns (BaseResp);
|
|
|
|
rpc userUnbindRole(UserRoleReq) returns (BaseResp);
|
|
|
|
// UserClearRole 用户清理角色
|
|
|
|
// UserClearRole 用户清理角色
|
|
|
|
// group: user_role
|
|
|
|
// group: user_role
|
|
|
|
rpc UserClearRole(IDReq) returns (BaseResp);
|
|
|
|
rpc userClearRole(IDReq) returns (BaseResp);
|
|
|
|
// GetUserRoles 获取用户绑定的角色列表
|
|
|
|
// GetUserRoles 获取用户绑定的角色列表
|
|
|
|
// group: user_role
|
|
|
|
// group: user_role
|
|
|
|
rpc GetUserRoles(GetUserRolesReq) returns (RoleListResp);
|
|
|
|
rpc getUserRoles(GetUserRolesReq) returns (RoleListResp);
|
|
|
|
// User Management
|
|
|
|
// User Management
|
|
|
|
// group: user_social
|
|
|
|
// group: user_social
|
|
|
|
rpc createUserSocial(UserSocialInfo) returns (BaseIDResp);
|
|
|
|
rpc createUserSocial(UserSocialInfo) returns (BaseIDResp);
|
|
|
|