@mamindom/contracts 1.0.75 → 1.0.77
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/gen/product.d.ts +17 -0
- package/dist/gen/product.js +3 -0
- package/dist/gen/sticker.d.ts +31 -1
- package/dist/gen/sticker.js +9 -1
- package/dist/proto/product.proto +20 -0
- package/dist/proto/size_chart.proto +1 -0
- package/dist/proto/sticker.proto +42 -2
- package/gen/product.ts +35 -0
- package/gen/sticker.ts +50 -2
- package/package.json +1 -1
- package/proto/product.proto +20 -0
- package/proto/size_chart.proto +1 -0
- package/proto/sticker.proto +42 -2
package/dist/gen/product.d.ts
CHANGED
|
@@ -787,6 +787,17 @@ export interface UpdateProductVariantRequest_MetaDescriptionEntry {
|
|
|
787
787
|
export interface GetProductVariantRequest {
|
|
788
788
|
id: string;
|
|
789
789
|
}
|
|
790
|
+
export interface AssignVariantSizeChartsRequest {
|
|
791
|
+
variantId: string;
|
|
792
|
+
sizeChartIds: string[];
|
|
793
|
+
}
|
|
794
|
+
export interface RemoveVariantSizeChartRequest {
|
|
795
|
+
variantId: string;
|
|
796
|
+
sizeChartId: string;
|
|
797
|
+
}
|
|
798
|
+
export interface GetVariantSizeChartsRequest {
|
|
799
|
+
variantId: string;
|
|
800
|
+
}
|
|
790
801
|
export declare const CATALOG_V1_PACKAGE_NAME = "catalog.v1";
|
|
791
802
|
export interface ProductServiceClient {
|
|
792
803
|
getProducts(request: GetProductsRequest): Observable<GetProductsResponse>;
|
|
@@ -822,6 +833,9 @@ export interface ProductServiceClient {
|
|
|
822
833
|
createProductVariant(request: CreateProductVariantRequest): Observable<ProductVariantDetailResponse>;
|
|
823
834
|
updateProductVariant(request: UpdateProductVariantRequest): Observable<ProductVariantDetailResponse>;
|
|
824
835
|
getProductVariant(request: GetProductVariantRequest): Observable<ProductVariantDetailResponse>;
|
|
836
|
+
assignVariantSizeCharts(request: AssignVariantSizeChartsRequest): Observable<SuccessResponse>;
|
|
837
|
+
removeVariantSizeChart(request: RemoveVariantSizeChartRequest): Observable<SuccessResponse>;
|
|
838
|
+
getVariantSizeCharts(request: GetVariantSizeChartsRequest): Observable<GetProductSizeChartsResponse>;
|
|
825
839
|
}
|
|
826
840
|
export interface ProductServiceController {
|
|
827
841
|
getProducts(request: GetProductsRequest): Promise<GetProductsResponse> | Observable<GetProductsResponse> | GetProductsResponse;
|
|
@@ -857,6 +871,9 @@ export interface ProductServiceController {
|
|
|
857
871
|
createProductVariant(request: CreateProductVariantRequest): Promise<ProductVariantDetailResponse> | Observable<ProductVariantDetailResponse> | ProductVariantDetailResponse;
|
|
858
872
|
updateProductVariant(request: UpdateProductVariantRequest): Promise<ProductVariantDetailResponse> | Observable<ProductVariantDetailResponse> | ProductVariantDetailResponse;
|
|
859
873
|
getProductVariant(request: GetProductVariantRequest): Promise<ProductVariantDetailResponse> | Observable<ProductVariantDetailResponse> | ProductVariantDetailResponse;
|
|
874
|
+
assignVariantSizeCharts(request: AssignVariantSizeChartsRequest): Promise<SuccessResponse> | Observable<SuccessResponse> | SuccessResponse;
|
|
875
|
+
removeVariantSizeChart(request: RemoveVariantSizeChartRequest): Promise<SuccessResponse> | Observable<SuccessResponse> | SuccessResponse;
|
|
876
|
+
getVariantSizeCharts(request: GetVariantSizeChartsRequest): Promise<GetProductSizeChartsResponse> | Observable<GetProductSizeChartsResponse> | GetProductSizeChartsResponse;
|
|
860
877
|
}
|
|
861
878
|
export declare function ProductServiceControllerMethods(): (constructor: Function) => void;
|
|
862
879
|
export declare const PRODUCT_SERVICE_NAME = "ProductService";
|
package/dist/gen/product.js
CHANGED
|
@@ -72,6 +72,9 @@ function ProductServiceControllerMethods() {
|
|
|
72
72
|
"createProductVariant",
|
|
73
73
|
"updateProductVariant",
|
|
74
74
|
"getProductVariant",
|
|
75
|
+
"assignVariantSizeCharts",
|
|
76
|
+
"removeVariantSizeChart",
|
|
77
|
+
"getVariantSizeCharts",
|
|
75
78
|
];
|
|
76
79
|
for (const method of grpcMethods) {
|
|
77
80
|
const descriptor = Reflect.getOwnPropertyDescriptor(constructor.prototype, method);
|
package/dist/gen/sticker.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Observable } from "rxjs";
|
|
2
|
-
import { DeleteResponse, PaginationMeta, PaginationRequest } from "./common";
|
|
2
|
+
import { DeleteResponse, PaginationMeta, PaginationRequest, SuccessResponse } from "./common";
|
|
3
3
|
export declare const protobufPackage = "catalog.v1";
|
|
4
4
|
export interface StickerResponse {
|
|
5
5
|
id: string;
|
|
@@ -8,6 +8,10 @@ export interface StickerResponse {
|
|
|
8
8
|
};
|
|
9
9
|
color?: string | undefined;
|
|
10
10
|
icon?: string | undefined;
|
|
11
|
+
svgUrl?: string | undefined;
|
|
12
|
+
svgId?: string | undefined;
|
|
13
|
+
startDate?: string | undefined;
|
|
14
|
+
endDate?: string | undefined;
|
|
11
15
|
}
|
|
12
16
|
export interface StickerResponse_NameEntry {
|
|
13
17
|
key: string;
|
|
@@ -29,6 +33,10 @@ export interface CreateStickerRequest {
|
|
|
29
33
|
};
|
|
30
34
|
color?: string | undefined;
|
|
31
35
|
icon?: string | undefined;
|
|
36
|
+
svgUrl?: string | undefined;
|
|
37
|
+
svgId?: string | undefined;
|
|
38
|
+
startDate?: string | undefined;
|
|
39
|
+
endDate?: string | undefined;
|
|
32
40
|
}
|
|
33
41
|
export interface CreateStickerRequest_NameEntry {
|
|
34
42
|
key: string;
|
|
@@ -41,6 +49,10 @@ export interface UpdateStickerRequest {
|
|
|
41
49
|
};
|
|
42
50
|
color?: string | undefined;
|
|
43
51
|
icon?: string | undefined;
|
|
52
|
+
svgUrl?: string | undefined;
|
|
53
|
+
svgId?: string | undefined;
|
|
54
|
+
startDate?: string | undefined;
|
|
55
|
+
endDate?: string | undefined;
|
|
44
56
|
}
|
|
45
57
|
export interface UpdateStickerRequest_NameEntry {
|
|
46
58
|
key: string;
|
|
@@ -49,6 +61,20 @@ export interface UpdateStickerRequest_NameEntry {
|
|
|
49
61
|
export interface DeleteStickerRequest {
|
|
50
62
|
id: string;
|
|
51
63
|
}
|
|
64
|
+
export interface BulkAssignStickerRequest {
|
|
65
|
+
stickerId: string;
|
|
66
|
+
productIds: string[];
|
|
67
|
+
categoryIds: string[];
|
|
68
|
+
brandIds: string[];
|
|
69
|
+
variantIds: string[];
|
|
70
|
+
}
|
|
71
|
+
export interface BulkRemoveStickerRequest {
|
|
72
|
+
stickerId: string;
|
|
73
|
+
productIds: string[];
|
|
74
|
+
categoryIds: string[];
|
|
75
|
+
brandIds: string[];
|
|
76
|
+
variantIds: string[];
|
|
77
|
+
}
|
|
52
78
|
export declare const CATALOG_V1_PACKAGE_NAME = "catalog.v1";
|
|
53
79
|
export interface StickerServiceClient {
|
|
54
80
|
getStickers(request: GetStickersRequest): Observable<GetStickersResponse>;
|
|
@@ -56,6 +82,8 @@ export interface StickerServiceClient {
|
|
|
56
82
|
createSticker(request: CreateStickerRequest): Observable<StickerResponse>;
|
|
57
83
|
updateSticker(request: UpdateStickerRequest): Observable<StickerResponse>;
|
|
58
84
|
deleteSticker(request: DeleteStickerRequest): Observable<DeleteResponse>;
|
|
85
|
+
bulkAssignSticker(request: BulkAssignStickerRequest): Observable<SuccessResponse>;
|
|
86
|
+
bulkRemoveSticker(request: BulkRemoveStickerRequest): Observable<SuccessResponse>;
|
|
59
87
|
}
|
|
60
88
|
export interface StickerServiceController {
|
|
61
89
|
getStickers(request: GetStickersRequest): Promise<GetStickersResponse> | Observable<GetStickersResponse> | GetStickersResponse;
|
|
@@ -63,6 +91,8 @@ export interface StickerServiceController {
|
|
|
63
91
|
createSticker(request: CreateStickerRequest): Promise<StickerResponse> | Observable<StickerResponse> | StickerResponse;
|
|
64
92
|
updateSticker(request: UpdateStickerRequest): Promise<StickerResponse> | Observable<StickerResponse> | StickerResponse;
|
|
65
93
|
deleteSticker(request: DeleteStickerRequest): Promise<DeleteResponse> | Observable<DeleteResponse> | DeleteResponse;
|
|
94
|
+
bulkAssignSticker(request: BulkAssignStickerRequest): Promise<SuccessResponse> | Observable<SuccessResponse> | SuccessResponse;
|
|
95
|
+
bulkRemoveSticker(request: BulkRemoveStickerRequest): Promise<SuccessResponse> | Observable<SuccessResponse> | SuccessResponse;
|
|
66
96
|
}
|
|
67
97
|
export declare function StickerServiceControllerMethods(): (constructor: Function) => void;
|
|
68
98
|
export declare const STICKER_SERVICE_NAME = "StickerService";
|
package/dist/gen/sticker.js
CHANGED
|
@@ -13,7 +13,15 @@ exports.protobufPackage = "catalog.v1";
|
|
|
13
13
|
exports.CATALOG_V1_PACKAGE_NAME = "catalog.v1";
|
|
14
14
|
function StickerServiceControllerMethods() {
|
|
15
15
|
return function (constructor) {
|
|
16
|
-
const grpcMethods = [
|
|
16
|
+
const grpcMethods = [
|
|
17
|
+
"getStickers",
|
|
18
|
+
"getSticker",
|
|
19
|
+
"createSticker",
|
|
20
|
+
"updateSticker",
|
|
21
|
+
"deleteSticker",
|
|
22
|
+
"bulkAssignSticker",
|
|
23
|
+
"bulkRemoveSticker",
|
|
24
|
+
];
|
|
17
25
|
for (const method of grpcMethods) {
|
|
18
26
|
const descriptor = Reflect.getOwnPropertyDescriptor(constructor.prototype, method);
|
|
19
27
|
(0, microservices_1.GrpcMethod)("StickerService", method)(constructor.prototype[method], method, descriptor);
|
package/dist/proto/product.proto
CHANGED
|
@@ -63,6 +63,12 @@ service ProductService {
|
|
|
63
63
|
rpc CreateProductVariant (CreateProductVariantRequest) returns (ProductVariantDetailResponse);
|
|
64
64
|
rpc UpdateProductVariant (UpdateProductVariantRequest) returns (ProductVariantDetailResponse);
|
|
65
65
|
rpc GetProductVariant (GetProductVariantRequest) returns (ProductVariantDetailResponse);
|
|
66
|
+
|
|
67
|
+
|
|
68
|
+
|
|
69
|
+
rpc AssignVariantSizeCharts (AssignVariantSizeChartsRequest) returns (SuccessResponse);
|
|
70
|
+
rpc RemoveVariantSizeChart (RemoveVariantSizeChartRequest) returns (SuccessResponse);
|
|
71
|
+
rpc GetVariantSizeCharts (GetVariantSizeChartsRequest) returns (GetProductSizeChartsResponse);
|
|
66
72
|
}
|
|
67
73
|
|
|
68
74
|
|
|
@@ -645,4 +651,18 @@ message UpdateProductVariantRequest {
|
|
|
645
651
|
|
|
646
652
|
message GetProductVariantRequest {
|
|
647
653
|
string id = 1;
|
|
654
|
+
}
|
|
655
|
+
|
|
656
|
+
message AssignVariantSizeChartsRequest {
|
|
657
|
+
string variant_id = 1;
|
|
658
|
+
repeated string size_chart_ids = 2;
|
|
659
|
+
}
|
|
660
|
+
|
|
661
|
+
message RemoveVariantSizeChartRequest {
|
|
662
|
+
string variant_id = 1;
|
|
663
|
+
string size_chart_id = 2;
|
|
664
|
+
}
|
|
665
|
+
|
|
666
|
+
message GetVariantSizeChartsRequest {
|
|
667
|
+
string variant_id = 1;
|
|
648
668
|
}
|
package/dist/proto/sticker.proto
CHANGED
|
@@ -2,7 +2,7 @@ syntax = "proto3";
|
|
|
2
2
|
|
|
3
3
|
package catalog.v1;
|
|
4
4
|
|
|
5
|
-
import "common.proto";
|
|
5
|
+
import "common.proto";
|
|
6
6
|
|
|
7
7
|
service StickerService {
|
|
8
8
|
rpc GetStickers (GetStickersRequest) returns (GetStickersResponse);
|
|
@@ -10,6 +10,11 @@ service StickerService {
|
|
|
10
10
|
rpc CreateSticker (CreateStickerRequest) returns (StickerResponse);
|
|
11
11
|
rpc UpdateSticker (UpdateStickerRequest) returns (StickerResponse);
|
|
12
12
|
rpc DeleteSticker (DeleteStickerRequest) returns (DeleteResponse);
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
rpc BulkAssignSticker (BulkAssignStickerRequest) returns (SuccessResponse);
|
|
16
|
+
|
|
17
|
+
rpc BulkRemoveSticker (BulkRemoveStickerRequest) returns (SuccessResponse);
|
|
13
18
|
}
|
|
14
19
|
|
|
15
20
|
message StickerResponse {
|
|
@@ -17,6 +22,12 @@ message StickerResponse {
|
|
|
17
22
|
map<string, string> name = 2;
|
|
18
23
|
optional string color = 3;
|
|
19
24
|
optional string icon = 4;
|
|
25
|
+
|
|
26
|
+
optional string svg_url = 5;
|
|
27
|
+
optional string svg_id = 6;
|
|
28
|
+
|
|
29
|
+
optional string start_date = 7;
|
|
30
|
+
optional string end_date = 8;
|
|
20
31
|
}
|
|
21
32
|
|
|
22
33
|
message GetStickersRequest {
|
|
@@ -36,6 +47,12 @@ message CreateStickerRequest {
|
|
|
36
47
|
map<string, string> name = 1;
|
|
37
48
|
optional string color = 2;
|
|
38
49
|
optional string icon = 3;
|
|
50
|
+
|
|
51
|
+
optional string svg_url = 4;
|
|
52
|
+
optional string svg_id = 5;
|
|
53
|
+
|
|
54
|
+
optional string start_date = 6;
|
|
55
|
+
optional string end_date = 7;
|
|
39
56
|
}
|
|
40
57
|
|
|
41
58
|
message UpdateStickerRequest {
|
|
@@ -43,8 +60,31 @@ message UpdateStickerRequest {
|
|
|
43
60
|
map<string, string> name = 2;
|
|
44
61
|
optional string color = 3;
|
|
45
62
|
optional string icon = 4;
|
|
63
|
+
|
|
64
|
+
optional string svg_url = 5;
|
|
65
|
+
optional string svg_id = 6;
|
|
66
|
+
|
|
67
|
+
optional string start_date = 7;
|
|
68
|
+
optional string end_date = 8;
|
|
46
69
|
}
|
|
47
70
|
|
|
48
71
|
message DeleteStickerRequest {
|
|
49
72
|
string id = 1;
|
|
50
|
-
}
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
|
|
76
|
+
message BulkAssignStickerRequest {
|
|
77
|
+
string sticker_id = 1;
|
|
78
|
+
repeated string product_ids = 2;
|
|
79
|
+
repeated string category_ids = 3;
|
|
80
|
+
repeated string brand_ids = 4;
|
|
81
|
+
repeated string variant_ids = 5;
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
message BulkRemoveStickerRequest {
|
|
85
|
+
string sticker_id = 1;
|
|
86
|
+
repeated string product_ids = 2;
|
|
87
|
+
repeated string category_ids = 3;
|
|
88
|
+
repeated string brand_ids = 4;
|
|
89
|
+
repeated string variant_ids = 5;
|
|
90
|
+
}
|
package/gen/product.ts
CHANGED
|
@@ -799,6 +799,20 @@ export interface GetProductVariantRequest {
|
|
|
799
799
|
id: string;
|
|
800
800
|
}
|
|
801
801
|
|
|
802
|
+
export interface AssignVariantSizeChartsRequest {
|
|
803
|
+
variantId: string;
|
|
804
|
+
sizeChartIds: string[];
|
|
805
|
+
}
|
|
806
|
+
|
|
807
|
+
export interface RemoveVariantSizeChartRequest {
|
|
808
|
+
variantId: string;
|
|
809
|
+
sizeChartId: string;
|
|
810
|
+
}
|
|
811
|
+
|
|
812
|
+
export interface GetVariantSizeChartsRequest {
|
|
813
|
+
variantId: string;
|
|
814
|
+
}
|
|
815
|
+
|
|
802
816
|
export const CATALOG_V1_PACKAGE_NAME = "catalog.v1";
|
|
803
817
|
|
|
804
818
|
export interface ProductServiceClient {
|
|
@@ -867,6 +881,12 @@ export interface ProductServiceClient {
|
|
|
867
881
|
updateProductVariant(request: UpdateProductVariantRequest): Observable<ProductVariantDetailResponse>;
|
|
868
882
|
|
|
869
883
|
getProductVariant(request: GetProductVariantRequest): Observable<ProductVariantDetailResponse>;
|
|
884
|
+
|
|
885
|
+
assignVariantSizeCharts(request: AssignVariantSizeChartsRequest): Observable<SuccessResponse>;
|
|
886
|
+
|
|
887
|
+
removeVariantSizeChart(request: RemoveVariantSizeChartRequest): Observable<SuccessResponse>;
|
|
888
|
+
|
|
889
|
+
getVariantSizeCharts(request: GetVariantSizeChartsRequest): Observable<GetProductSizeChartsResponse>;
|
|
870
890
|
}
|
|
871
891
|
|
|
872
892
|
export interface ProductServiceController {
|
|
@@ -999,6 +1019,18 @@ export interface ProductServiceController {
|
|
|
999
1019
|
getProductVariant(
|
|
1000
1020
|
request: GetProductVariantRequest,
|
|
1001
1021
|
): Promise<ProductVariantDetailResponse> | Observable<ProductVariantDetailResponse> | ProductVariantDetailResponse;
|
|
1022
|
+
|
|
1023
|
+
assignVariantSizeCharts(
|
|
1024
|
+
request: AssignVariantSizeChartsRequest,
|
|
1025
|
+
): Promise<SuccessResponse> | Observable<SuccessResponse> | SuccessResponse;
|
|
1026
|
+
|
|
1027
|
+
removeVariantSizeChart(
|
|
1028
|
+
request: RemoveVariantSizeChartRequest,
|
|
1029
|
+
): Promise<SuccessResponse> | Observable<SuccessResponse> | SuccessResponse;
|
|
1030
|
+
|
|
1031
|
+
getVariantSizeCharts(
|
|
1032
|
+
request: GetVariantSizeChartsRequest,
|
|
1033
|
+
): Promise<GetProductSizeChartsResponse> | Observable<GetProductSizeChartsResponse> | GetProductSizeChartsResponse;
|
|
1002
1034
|
}
|
|
1003
1035
|
|
|
1004
1036
|
export function ProductServiceControllerMethods() {
|
|
@@ -1037,6 +1069,9 @@ export function ProductServiceControllerMethods() {
|
|
|
1037
1069
|
"createProductVariant",
|
|
1038
1070
|
"updateProductVariant",
|
|
1039
1071
|
"getProductVariant",
|
|
1072
|
+
"assignVariantSizeCharts",
|
|
1073
|
+
"removeVariantSizeChart",
|
|
1074
|
+
"getVariantSizeCharts",
|
|
1040
1075
|
];
|
|
1041
1076
|
for (const method of grpcMethods) {
|
|
1042
1077
|
const descriptor: any = Reflect.getOwnPropertyDescriptor(constructor.prototype, method);
|
package/gen/sticker.ts
CHANGED
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
/* eslint-disable */
|
|
8
8
|
import { GrpcMethod, GrpcStreamMethod } from "@nestjs/microservices";
|
|
9
9
|
import { Observable } from "rxjs";
|
|
10
|
-
import { DeleteResponse, PaginationMeta, PaginationRequest } from "./common";
|
|
10
|
+
import { DeleteResponse, PaginationMeta, PaginationRequest, SuccessResponse } from "./common";
|
|
11
11
|
|
|
12
12
|
export const protobufPackage = "catalog.v1";
|
|
13
13
|
|
|
@@ -16,6 +16,10 @@ export interface StickerResponse {
|
|
|
16
16
|
name: { [key: string]: string };
|
|
17
17
|
color?: string | undefined;
|
|
18
18
|
icon?: string | undefined;
|
|
19
|
+
svgUrl?: string | undefined;
|
|
20
|
+
svgId?: string | undefined;
|
|
21
|
+
startDate?: string | undefined;
|
|
22
|
+
endDate?: string | undefined;
|
|
19
23
|
}
|
|
20
24
|
|
|
21
25
|
export interface StickerResponse_NameEntry {
|
|
@@ -40,6 +44,10 @@ export interface CreateStickerRequest {
|
|
|
40
44
|
name: { [key: string]: string };
|
|
41
45
|
color?: string | undefined;
|
|
42
46
|
icon?: string | undefined;
|
|
47
|
+
svgUrl?: string | undefined;
|
|
48
|
+
svgId?: string | undefined;
|
|
49
|
+
startDate?: string | undefined;
|
|
50
|
+
endDate?: string | undefined;
|
|
43
51
|
}
|
|
44
52
|
|
|
45
53
|
export interface CreateStickerRequest_NameEntry {
|
|
@@ -52,6 +60,10 @@ export interface UpdateStickerRequest {
|
|
|
52
60
|
name: { [key: string]: string };
|
|
53
61
|
color?: string | undefined;
|
|
54
62
|
icon?: string | undefined;
|
|
63
|
+
svgUrl?: string | undefined;
|
|
64
|
+
svgId?: string | undefined;
|
|
65
|
+
startDate?: string | undefined;
|
|
66
|
+
endDate?: string | undefined;
|
|
55
67
|
}
|
|
56
68
|
|
|
57
69
|
export interface UpdateStickerRequest_NameEntry {
|
|
@@ -63,6 +75,22 @@ export interface DeleteStickerRequest {
|
|
|
63
75
|
id: string;
|
|
64
76
|
}
|
|
65
77
|
|
|
78
|
+
export interface BulkAssignStickerRequest {
|
|
79
|
+
stickerId: string;
|
|
80
|
+
productIds: string[];
|
|
81
|
+
categoryIds: string[];
|
|
82
|
+
brandIds: string[];
|
|
83
|
+
variantIds: string[];
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
export interface BulkRemoveStickerRequest {
|
|
87
|
+
stickerId: string;
|
|
88
|
+
productIds: string[];
|
|
89
|
+
categoryIds: string[];
|
|
90
|
+
brandIds: string[];
|
|
91
|
+
variantIds: string[];
|
|
92
|
+
}
|
|
93
|
+
|
|
66
94
|
export const CATALOG_V1_PACKAGE_NAME = "catalog.v1";
|
|
67
95
|
|
|
68
96
|
export interface StickerServiceClient {
|
|
@@ -75,6 +103,10 @@ export interface StickerServiceClient {
|
|
|
75
103
|
updateSticker(request: UpdateStickerRequest): Observable<StickerResponse>;
|
|
76
104
|
|
|
77
105
|
deleteSticker(request: DeleteStickerRequest): Observable<DeleteResponse>;
|
|
106
|
+
|
|
107
|
+
bulkAssignSticker(request: BulkAssignStickerRequest): Observable<SuccessResponse>;
|
|
108
|
+
|
|
109
|
+
bulkRemoveSticker(request: BulkRemoveStickerRequest): Observable<SuccessResponse>;
|
|
78
110
|
}
|
|
79
111
|
|
|
80
112
|
export interface StickerServiceController {
|
|
@@ -93,11 +125,27 @@ export interface StickerServiceController {
|
|
|
93
125
|
): Promise<StickerResponse> | Observable<StickerResponse> | StickerResponse;
|
|
94
126
|
|
|
95
127
|
deleteSticker(request: DeleteStickerRequest): Promise<DeleteResponse> | Observable<DeleteResponse> | DeleteResponse;
|
|
128
|
+
|
|
129
|
+
bulkAssignSticker(
|
|
130
|
+
request: BulkAssignStickerRequest,
|
|
131
|
+
): Promise<SuccessResponse> | Observable<SuccessResponse> | SuccessResponse;
|
|
132
|
+
|
|
133
|
+
bulkRemoveSticker(
|
|
134
|
+
request: BulkRemoveStickerRequest,
|
|
135
|
+
): Promise<SuccessResponse> | Observable<SuccessResponse> | SuccessResponse;
|
|
96
136
|
}
|
|
97
137
|
|
|
98
138
|
export function StickerServiceControllerMethods() {
|
|
99
139
|
return function (constructor: Function) {
|
|
100
|
-
const grpcMethods: string[] = [
|
|
140
|
+
const grpcMethods: string[] = [
|
|
141
|
+
"getStickers",
|
|
142
|
+
"getSticker",
|
|
143
|
+
"createSticker",
|
|
144
|
+
"updateSticker",
|
|
145
|
+
"deleteSticker",
|
|
146
|
+
"bulkAssignSticker",
|
|
147
|
+
"bulkRemoveSticker",
|
|
148
|
+
];
|
|
101
149
|
for (const method of grpcMethods) {
|
|
102
150
|
const descriptor: any = Reflect.getOwnPropertyDescriptor(constructor.prototype, method);
|
|
103
151
|
GrpcMethod("StickerService", method)(constructor.prototype[method], method, descriptor);
|
package/package.json
CHANGED
package/proto/product.proto
CHANGED
|
@@ -63,6 +63,12 @@ service ProductService {
|
|
|
63
63
|
rpc CreateProductVariant (CreateProductVariantRequest) returns (ProductVariantDetailResponse);
|
|
64
64
|
rpc UpdateProductVariant (UpdateProductVariantRequest) returns (ProductVariantDetailResponse);
|
|
65
65
|
rpc GetProductVariant (GetProductVariantRequest) returns (ProductVariantDetailResponse);
|
|
66
|
+
|
|
67
|
+
|
|
68
|
+
|
|
69
|
+
rpc AssignVariantSizeCharts (AssignVariantSizeChartsRequest) returns (SuccessResponse);
|
|
70
|
+
rpc RemoveVariantSizeChart (RemoveVariantSizeChartRequest) returns (SuccessResponse);
|
|
71
|
+
rpc GetVariantSizeCharts (GetVariantSizeChartsRequest) returns (GetProductSizeChartsResponse);
|
|
66
72
|
}
|
|
67
73
|
|
|
68
74
|
|
|
@@ -645,4 +651,18 @@ message UpdateProductVariantRequest {
|
|
|
645
651
|
|
|
646
652
|
message GetProductVariantRequest {
|
|
647
653
|
string id = 1;
|
|
654
|
+
}
|
|
655
|
+
|
|
656
|
+
message AssignVariantSizeChartsRequest {
|
|
657
|
+
string variant_id = 1;
|
|
658
|
+
repeated string size_chart_ids = 2;
|
|
659
|
+
}
|
|
660
|
+
|
|
661
|
+
message RemoveVariantSizeChartRequest {
|
|
662
|
+
string variant_id = 1;
|
|
663
|
+
string size_chart_id = 2;
|
|
664
|
+
}
|
|
665
|
+
|
|
666
|
+
message GetVariantSizeChartsRequest {
|
|
667
|
+
string variant_id = 1;
|
|
648
668
|
}
|
package/proto/size_chart.proto
CHANGED
package/proto/sticker.proto
CHANGED
|
@@ -2,7 +2,7 @@ syntax = "proto3";
|
|
|
2
2
|
|
|
3
3
|
package catalog.v1;
|
|
4
4
|
|
|
5
|
-
import "common.proto";
|
|
5
|
+
import "common.proto";
|
|
6
6
|
|
|
7
7
|
service StickerService {
|
|
8
8
|
rpc GetStickers (GetStickersRequest) returns (GetStickersResponse);
|
|
@@ -10,6 +10,11 @@ service StickerService {
|
|
|
10
10
|
rpc CreateSticker (CreateStickerRequest) returns (StickerResponse);
|
|
11
11
|
rpc UpdateSticker (UpdateStickerRequest) returns (StickerResponse);
|
|
12
12
|
rpc DeleteSticker (DeleteStickerRequest) returns (DeleteResponse);
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
rpc BulkAssignSticker (BulkAssignStickerRequest) returns (SuccessResponse);
|
|
16
|
+
|
|
17
|
+
rpc BulkRemoveSticker (BulkRemoveStickerRequest) returns (SuccessResponse);
|
|
13
18
|
}
|
|
14
19
|
|
|
15
20
|
message StickerResponse {
|
|
@@ -17,6 +22,12 @@ message StickerResponse {
|
|
|
17
22
|
map<string, string> name = 2;
|
|
18
23
|
optional string color = 3;
|
|
19
24
|
optional string icon = 4;
|
|
25
|
+
|
|
26
|
+
optional string svg_url = 5;
|
|
27
|
+
optional string svg_id = 6;
|
|
28
|
+
|
|
29
|
+
optional string start_date = 7;
|
|
30
|
+
optional string end_date = 8;
|
|
20
31
|
}
|
|
21
32
|
|
|
22
33
|
message GetStickersRequest {
|
|
@@ -36,6 +47,12 @@ message CreateStickerRequest {
|
|
|
36
47
|
map<string, string> name = 1;
|
|
37
48
|
optional string color = 2;
|
|
38
49
|
optional string icon = 3;
|
|
50
|
+
|
|
51
|
+
optional string svg_url = 4;
|
|
52
|
+
optional string svg_id = 5;
|
|
53
|
+
|
|
54
|
+
optional string start_date = 6;
|
|
55
|
+
optional string end_date = 7;
|
|
39
56
|
}
|
|
40
57
|
|
|
41
58
|
message UpdateStickerRequest {
|
|
@@ -43,8 +60,31 @@ message UpdateStickerRequest {
|
|
|
43
60
|
map<string, string> name = 2;
|
|
44
61
|
optional string color = 3;
|
|
45
62
|
optional string icon = 4;
|
|
63
|
+
|
|
64
|
+
optional string svg_url = 5;
|
|
65
|
+
optional string svg_id = 6;
|
|
66
|
+
|
|
67
|
+
optional string start_date = 7;
|
|
68
|
+
optional string end_date = 8;
|
|
46
69
|
}
|
|
47
70
|
|
|
48
71
|
message DeleteStickerRequest {
|
|
49
72
|
string id = 1;
|
|
50
|
-
}
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
|
|
76
|
+
message BulkAssignStickerRequest {
|
|
77
|
+
string sticker_id = 1;
|
|
78
|
+
repeated string product_ids = 2;
|
|
79
|
+
repeated string category_ids = 3;
|
|
80
|
+
repeated string brand_ids = 4;
|
|
81
|
+
repeated string variant_ids = 5;
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
message BulkRemoveStickerRequest {
|
|
85
|
+
string sticker_id = 1;
|
|
86
|
+
repeated string product_ids = 2;
|
|
87
|
+
repeated string category_ids = 3;
|
|
88
|
+
repeated string brand_ids = 4;
|
|
89
|
+
repeated string variant_ids = 5;
|
|
90
|
+
}
|