Add validators and services for Product Galleries and Product Tags
- Implemented Create, Delete, Get, and Update validators for Product Galleries. - Added Create, Delete, Get, and Update validators for Product Tags. - Created service classes for handling Discount Categories, Discount Orders, Discount Products, Discount Shopping Cart, Product Categories, Product Galleries, and Product Tags. - Each service class integrates with CQRS for command and query handling. - Established mapping profiles for Product Galleries.
This commit is contained in:
@@ -0,0 +1,98 @@
|
||||
syntax = "proto3";
|
||||
|
||||
package productcategory;
|
||||
|
||||
import "public_messages.proto";
|
||||
import "google/protobuf/empty.proto";
|
||||
import "google/protobuf/wrappers.proto";
|
||||
import "google/protobuf/duration.proto";
|
||||
import "google/protobuf/timestamp.proto";
|
||||
import "google/api/annotations.proto";
|
||||
|
||||
option csharp_namespace = "CMSMicroservice.Protobuf.Protos.ProductCategory";
|
||||
|
||||
service ProductCategoryContract
|
||||
{
|
||||
rpc CreateNewProductCategory(CreateNewProductCategoryRequest) returns (CreateNewProductCategoryResponse){
|
||||
option (google.api.http) = {
|
||||
post: "/CreateNewProductCategory"
|
||||
body: "*"
|
||||
};
|
||||
};
|
||||
rpc UpdateProductCategory(UpdateProductCategoryRequest) returns (google.protobuf.Empty){
|
||||
option (google.api.http) = {
|
||||
put: "/UpdateProductCategory"
|
||||
body: "*"
|
||||
};
|
||||
};
|
||||
rpc DeleteProductCategory(DeleteProductCategoryRequest) returns (google.protobuf.Empty){
|
||||
option (google.api.http) = {
|
||||
delete: "/DeleteProductCategory"
|
||||
body: "*"
|
||||
};
|
||||
};
|
||||
rpc GetProductCategory(GetProductCategoryRequest) returns (GetProductCategoryResponse){
|
||||
option (google.api.http) = {
|
||||
get: "/GetProductCategory"
|
||||
|
||||
};
|
||||
};
|
||||
rpc GetAllProductCategoryByFilter(GetAllProductCategoryByFilterRequest) returns (GetAllProductCategoryByFilterResponse){
|
||||
option (google.api.http) = {
|
||||
get: "/GetAllProductCategoryByFilter"
|
||||
|
||||
};
|
||||
};
|
||||
}
|
||||
message CreateNewProductCategoryRequest
|
||||
{
|
||||
int64 product_id = 1;
|
||||
int64 category_id = 2;
|
||||
}
|
||||
message CreateNewProductCategoryResponse
|
||||
{
|
||||
int64 id = 1;
|
||||
}
|
||||
message UpdateProductCategoryRequest
|
||||
{
|
||||
int64 id = 1;
|
||||
int64 product_id = 2;
|
||||
int64 category_id = 3;
|
||||
}
|
||||
message DeleteProductCategoryRequest
|
||||
{
|
||||
int64 id = 1;
|
||||
}
|
||||
message GetProductCategoryRequest
|
||||
{
|
||||
int64 id = 1;
|
||||
}
|
||||
message GetProductCategoryResponse
|
||||
{
|
||||
int64 id = 1;
|
||||
int64 product_id = 2;
|
||||
int64 category_id = 3;
|
||||
}
|
||||
message GetAllProductCategoryByFilterRequest
|
||||
{
|
||||
messages.PaginationState pagination_state = 1;
|
||||
google.protobuf.StringValue sort_by = 2;
|
||||
GetAllProductCategoryByFilterFilter filter = 3;
|
||||
}
|
||||
message GetAllProductCategoryByFilterFilter
|
||||
{
|
||||
google.protobuf.Int64Value id = 1;
|
||||
google.protobuf.Int64Value product_id = 2;
|
||||
google.protobuf.Int64Value category_id = 3;
|
||||
}
|
||||
message GetAllProductCategoryByFilterResponse
|
||||
{
|
||||
messages.MetaData meta_data = 1;
|
||||
repeated GetAllProductCategoryByFilterResponseModel models = 2;
|
||||
}
|
||||
message GetAllProductCategoryByFilterResponseModel
|
||||
{
|
||||
int64 id = 1;
|
||||
int64 product_id = 2;
|
||||
int64 category_id = 3;
|
||||
}
|
||||
Reference in New Issue
Block a user