add: add rbac get all roles and permissions
All checks were successful
Publish / Publish Job (push) Successful in 2m36s
All checks were successful
Publish / Publish Job (push) Successful in 2m36s
This commit is contained in:
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@lendry-erp/contracts",
|
"name": "@lendry-erp/contracts",
|
||||||
"version": "1.0.48",
|
"version": "1.0.49",
|
||||||
"description": "Protobuf definitions and generated TypeScript types",
|
"description": "Protobuf definitions and generated TypeScript types",
|
||||||
"type": "commonjs",
|
"type": "commonjs",
|
||||||
"main": "./dist/index.js",
|
"main": "./dist/index.js",
|
||||||
|
|||||||
40
proto/rbax.proto
Normal file
40
proto/rbax.proto
Normal file
@@ -0,0 +1,40 @@
|
|||||||
|
syntax = "proto3";
|
||||||
|
|
||||||
|
package rbac.v1;
|
||||||
|
|
||||||
|
option go_package = "git.lendry.ru/lendry-erp/proto.git/go;pb";
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
service LdapAuthService {
|
||||||
|
rpc GetAllPermissions (GetAllPermissionsRequest) returns (GetAllPermissionsResponse);
|
||||||
|
rpc GetAllRoles(GetAllRolesRequest) returns (GetAllRolesResponse);
|
||||||
|
}
|
||||||
|
|
||||||
|
message GetAllPermissionsRequest {
|
||||||
|
string user_id = 1;
|
||||||
|
string session_id=2;
|
||||||
|
}
|
||||||
|
|
||||||
|
message GetAllPermissionsResponse {
|
||||||
|
string id = 1;
|
||||||
|
string code = 2;
|
||||||
|
string description = 3;
|
||||||
|
string module = 4;
|
||||||
|
repeated string roles = 5;
|
||||||
|
}
|
||||||
|
|
||||||
|
message GetAllRolesRequest {
|
||||||
|
string user_id = 1;
|
||||||
|
string session_id=2;
|
||||||
|
}
|
||||||
|
|
||||||
|
message GetAllRolesResponse {
|
||||||
|
string id = 1;
|
||||||
|
string name = 2;
|
||||||
|
int32 level = 3;
|
||||||
|
repeated string permissions = 4;
|
||||||
|
repeated string ldap_mapping = 5;
|
||||||
|
repeated string accounts = 6;
|
||||||
|
}
|
||||||
|
|
||||||
Reference in New Issue
Block a user