From bfb2253a4931e904f9bff9d53cabc5938bdc413b Mon Sep 17 00:00:00 2001 From: kevin Date: Fri, 17 May 2019 11:05:34 +0200 Subject: [PATCH] improve tag --- protos/models/tag.proto | 9 +++++++++ protos/services/tags_service.proto | 9 ++------- 2 files changed, 11 insertions(+), 7 deletions(-) create mode 100644 protos/models/tag.proto diff --git a/protos/models/tag.proto b/protos/models/tag.proto new file mode 100644 index 0000000..576a956 --- /dev/null +++ b/protos/models/tag.proto @@ -0,0 +1,9 @@ +syntax = "proto3"; + +package stashall; + +message Tag { + string id = 1; + string label = 2; + string color = 3; +} \ No newline at end of file diff --git a/protos/services/tags_service.proto b/protos/services/tags_service.proto index 6db0b9b..90d5dbd 100644 --- a/protos/services/tags_service.proto +++ b/protos/services/tags_service.proto @@ -3,18 +3,13 @@ syntax = "proto3"; package stashall; import "google/protobuf/empty.proto"; +import "models/tag.proto"; message CreateTagRequest { string label = 1; string color = 2; } -message CreateTagResponse { - string id = 1; - string label = 2; - string color = 3; -} - message EditTagRequest { string id = 1; string label = 2; @@ -25,7 +20,7 @@ message DeleteTagRequest { string id = 1; } service TagsService { /// The client must send the Authorization metadata - rpc createTag(CreateTagRequest) returns (CreateTagResponse); + rpc createTag(CreateTagRequest) returns (Tag); /// The client must send the Authorization metadata rpc editTag(EditTagRequest) returns (google.protobuf.Empty);