@candesk/contracts 6.47.0 → 6.49.0
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/account.d.ts +1 -0
- package/dist/gen/audit.d.ts +1 -0
- package/dist/gen/catalog.d.ts +250 -0
- package/dist/gen/catalog.js +63 -1
- package/dist/gen/media.d.ts +1 -0
- package/dist/gen/media.js +1 -0
- package/dist/gen/treatment.d.ts +2 -0
- package/dist/nest/account.d.ts +1 -0
- package/dist/nest/audit.d.ts +1 -0
- package/dist/nest/catalog.d.ts +269 -0
- package/dist/nest/catalog.js +85 -2
- package/dist/nest/media.d.ts +1 -0
- package/dist/nest/media.js +1 -0
- package/dist/nest/treatment.d.ts +2 -0
- package/package.json +1 -1
- package/proto/account.proto +1 -0
- package/proto/audit.proto +1 -0
- package/proto/catalog.proto +293 -0
- package/proto/media.proto +1 -0
- package/proto/treatment.proto +2 -0
package/dist/gen/account.d.ts
CHANGED
|
@@ -192,6 +192,7 @@ export interface ListPatientAccountsRequest {
|
|
|
192
192
|
export interface ListPatientAccountsResponse {
|
|
193
193
|
accounts: PatientAccount[];
|
|
194
194
|
nextCursor?: string | undefined;
|
|
195
|
+
total: number;
|
|
195
196
|
}
|
|
196
197
|
export interface GetPatientAccountRequest {
|
|
197
198
|
id: string;
|
package/dist/gen/audit.d.ts
CHANGED
package/dist/gen/catalog.d.ts
CHANGED
|
@@ -1,15 +1,265 @@
|
|
|
1
1
|
export declare const protobufPackage = "catalog.v1";
|
|
2
2
|
export declare const protobufFileName = "catalog.proto";
|
|
3
|
+
export declare enum ProductType {
|
|
4
|
+
PRODUCT_TYPE_UNSPECIFIED = 0,
|
|
5
|
+
PRODUCT_TYPE_FLOWER = 1,
|
|
6
|
+
PRODUCT_TYPE_EXTRACT = 2,
|
|
7
|
+
UNRECOGNIZED = -1
|
|
8
|
+
}
|
|
9
|
+
export declare enum ProductStatus {
|
|
10
|
+
PRODUCT_STATUS_UNSPECIFIED = 0,
|
|
11
|
+
PRODUCT_STATUS_DRAFT = 1,
|
|
12
|
+
PRODUCT_STATUS_PUBLISHED = 2,
|
|
13
|
+
UNRECOGNIZED = -1
|
|
14
|
+
}
|
|
15
|
+
export declare enum Genetics {
|
|
16
|
+
GENETICS_UNSPECIFIED = 0,
|
|
17
|
+
GENETICS_SATIVA = 1,
|
|
18
|
+
GENETICS_SATIVA_DOMINANT = 2,
|
|
19
|
+
GENETICS_HYBRID = 3,
|
|
20
|
+
GENETICS_INDICA_DOMINANT = 4,
|
|
21
|
+
GENETICS_INDICA = 5,
|
|
22
|
+
UNRECOGNIZED = -1
|
|
23
|
+
}
|
|
24
|
+
export declare enum PotencyUnit {
|
|
25
|
+
POTENCY_UNIT_UNSPECIFIED = 0,
|
|
26
|
+
POTENCY_UNIT_PERCENT = 1,
|
|
27
|
+
POTENCY_UNIT_MG_PER_ML = 2,
|
|
28
|
+
UNRECOGNIZED = -1
|
|
29
|
+
}
|
|
30
|
+
export declare enum Availability {
|
|
31
|
+
AVAILABILITY_UNSPECIFIED = 0,
|
|
32
|
+
AVAILABILITY_UNKNOWN = 1,
|
|
33
|
+
AVAILABILITY_AVAILABLE = 2,
|
|
34
|
+
AVAILABILITY_SOLD_OUT = 3,
|
|
35
|
+
UNRECOGNIZED = -1
|
|
36
|
+
}
|
|
37
|
+
export declare enum Flavor {
|
|
38
|
+
FLAVOR_UNSPECIFIED = 0,
|
|
39
|
+
FLAVOR_EARTHY = 1,
|
|
40
|
+
FLAVOR_WOODY = 2,
|
|
41
|
+
FLAVOR_PINE = 3,
|
|
42
|
+
FLAVOR_HERBAL = 4,
|
|
43
|
+
FLAVOR_FLORAL = 5,
|
|
44
|
+
FLAVOR_CITRUS = 6,
|
|
45
|
+
FLAVOR_FRUITY = 7,
|
|
46
|
+
FLAVOR_BERRY = 8,
|
|
47
|
+
FLAVOR_TROPICAL = 9,
|
|
48
|
+
FLAVOR_SWEET = 10,
|
|
49
|
+
FLAVOR_SPICY = 11,
|
|
50
|
+
FLAVOR_PEPPERY = 12,
|
|
51
|
+
FLAVOR_MENTHOL = 13,
|
|
52
|
+
FLAVOR_CHEESE = 14,
|
|
53
|
+
FLAVOR_SKUNK = 15,
|
|
54
|
+
FLAVOR_DIESEL = 16,
|
|
55
|
+
FLAVOR_GASSY = 17,
|
|
56
|
+
FLAVOR_CHEMICAL = 18,
|
|
57
|
+
UNRECOGNIZED = -1
|
|
58
|
+
}
|
|
59
|
+
export interface Manufacturer {
|
|
60
|
+
id: string;
|
|
61
|
+
name: string;
|
|
62
|
+
slug: string;
|
|
63
|
+
}
|
|
64
|
+
export interface Strain {
|
|
65
|
+
id: string;
|
|
66
|
+
name: string;
|
|
67
|
+
slug: string;
|
|
68
|
+
}
|
|
3
69
|
export interface Terpene {
|
|
4
70
|
id: string;
|
|
5
71
|
name: string;
|
|
6
72
|
slug: string;
|
|
7
73
|
}
|
|
74
|
+
export interface Product {
|
|
75
|
+
id: string;
|
|
76
|
+
number: number;
|
|
77
|
+
name: string;
|
|
78
|
+
type: ProductType;
|
|
79
|
+
status: ProductStatus;
|
|
80
|
+
manufacturer: Manufacturer | undefined;
|
|
81
|
+
strain?: Strain | undefined;
|
|
82
|
+
genetics?: Genetics | undefined;
|
|
83
|
+
thc: number;
|
|
84
|
+
cbd: number;
|
|
85
|
+
potencyUnit: PotencyUnit;
|
|
86
|
+
country?: string | undefined;
|
|
87
|
+
isIrradiated: boolean;
|
|
88
|
+
flavors: Flavor[];
|
|
89
|
+
terpenes: Terpene[];
|
|
90
|
+
description?: string | undefined;
|
|
91
|
+
price?: number | undefined;
|
|
92
|
+
availability: Availability;
|
|
93
|
+
publishedAt?: string | undefined;
|
|
94
|
+
createdAt: string;
|
|
95
|
+
updatedAt: string;
|
|
96
|
+
coverKey?: string | undefined;
|
|
97
|
+
}
|
|
98
|
+
export interface ProductInput {
|
|
99
|
+
name: string;
|
|
100
|
+
type: ProductType;
|
|
101
|
+
manufacturerId: string;
|
|
102
|
+
strainId?: string | undefined;
|
|
103
|
+
genetics?: Genetics | undefined;
|
|
104
|
+
thc: number;
|
|
105
|
+
cbd: number;
|
|
106
|
+
potencyUnit: PotencyUnit;
|
|
107
|
+
country?: string | undefined;
|
|
108
|
+
isIrradiated: boolean;
|
|
109
|
+
flavors: Flavor[];
|
|
110
|
+
terpeneIds: string[];
|
|
111
|
+
description?: string | undefined;
|
|
112
|
+
price?: number | undefined;
|
|
113
|
+
availability: Availability;
|
|
114
|
+
}
|
|
115
|
+
export interface ListProductsRequest {
|
|
116
|
+
query?: string | undefined;
|
|
117
|
+
type?: ProductType | undefined;
|
|
118
|
+
status?: ProductStatus | undefined;
|
|
119
|
+
cursor?: string | undefined;
|
|
120
|
+
limit: number;
|
|
121
|
+
}
|
|
122
|
+
export interface ListProductsResponse {
|
|
123
|
+
products: Product[];
|
|
124
|
+
nextCursor?: string | undefined;
|
|
125
|
+
total: number;
|
|
126
|
+
}
|
|
127
|
+
export interface GetProductRequest {
|
|
128
|
+
id: string;
|
|
129
|
+
}
|
|
130
|
+
export interface GetProductResponse {
|
|
131
|
+
product: Product | undefined;
|
|
132
|
+
}
|
|
133
|
+
export interface CreateProductRequest {
|
|
134
|
+
product: ProductInput | undefined;
|
|
135
|
+
}
|
|
136
|
+
export interface CreateProductResponse {
|
|
137
|
+
product: Product | undefined;
|
|
138
|
+
}
|
|
139
|
+
export interface UpdateProductRequest {
|
|
140
|
+
id: string;
|
|
141
|
+
product: ProductInput | undefined;
|
|
142
|
+
}
|
|
143
|
+
export interface UpdateProductResponse {
|
|
144
|
+
product: Product | undefined;
|
|
145
|
+
}
|
|
146
|
+
export interface PublishProductRequest {
|
|
147
|
+
id: string;
|
|
148
|
+
}
|
|
149
|
+
export interface PublishProductResponse {
|
|
150
|
+
product: Product | undefined;
|
|
151
|
+
}
|
|
152
|
+
export interface UnpublishProductRequest {
|
|
153
|
+
id: string;
|
|
154
|
+
}
|
|
155
|
+
export interface UnpublishProductResponse {
|
|
156
|
+
product: Product | undefined;
|
|
157
|
+
}
|
|
158
|
+
export interface DeleteProductRequest {
|
|
159
|
+
id: string;
|
|
160
|
+
}
|
|
161
|
+
export interface DeleteProductResponse {
|
|
162
|
+
product: Product | undefined;
|
|
163
|
+
}
|
|
164
|
+
export interface SetProductCoverRequest {
|
|
165
|
+
id: string;
|
|
166
|
+
coverKey?: string | undefined;
|
|
167
|
+
}
|
|
168
|
+
export interface SetProductCoverResponse {
|
|
169
|
+
product: Product | undefined;
|
|
170
|
+
previousCoverKey?: string | undefined;
|
|
171
|
+
}
|
|
172
|
+
export interface ListManufacturersRequest {
|
|
173
|
+
}
|
|
174
|
+
export interface ListManufacturersResponse {
|
|
175
|
+
manufacturers: Manufacturer[];
|
|
176
|
+
}
|
|
177
|
+
export interface CreateManufacturerRequest {
|
|
178
|
+
name: string;
|
|
179
|
+
}
|
|
180
|
+
export interface CreateManufacturerResponse {
|
|
181
|
+
manufacturer: Manufacturer | undefined;
|
|
182
|
+
}
|
|
183
|
+
export interface UpdateManufacturerRequest {
|
|
184
|
+
id: string;
|
|
185
|
+
name: string;
|
|
186
|
+
}
|
|
187
|
+
export interface UpdateManufacturerResponse {
|
|
188
|
+
manufacturer: Manufacturer | undefined;
|
|
189
|
+
}
|
|
190
|
+
export interface DeleteManufacturerRequest {
|
|
191
|
+
id: string;
|
|
192
|
+
}
|
|
193
|
+
export interface DeleteManufacturerResponse {
|
|
194
|
+
manufacturer: Manufacturer | undefined;
|
|
195
|
+
}
|
|
196
|
+
export interface ListStrainsRequest {
|
|
197
|
+
}
|
|
198
|
+
export interface ListStrainsResponse {
|
|
199
|
+
strains: Strain[];
|
|
200
|
+
}
|
|
201
|
+
export interface CreateStrainRequest {
|
|
202
|
+
name: string;
|
|
203
|
+
}
|
|
204
|
+
export interface CreateStrainResponse {
|
|
205
|
+
strain: Strain | undefined;
|
|
206
|
+
}
|
|
207
|
+
export interface UpdateStrainRequest {
|
|
208
|
+
id: string;
|
|
209
|
+
name: string;
|
|
210
|
+
}
|
|
211
|
+
export interface UpdateStrainResponse {
|
|
212
|
+
strain: Strain | undefined;
|
|
213
|
+
}
|
|
214
|
+
export interface DeleteStrainRequest {
|
|
215
|
+
id: string;
|
|
216
|
+
}
|
|
217
|
+
export interface DeleteStrainResponse {
|
|
218
|
+
strain: Strain | undefined;
|
|
219
|
+
}
|
|
8
220
|
export interface ListTerpenesRequest {
|
|
9
221
|
}
|
|
10
222
|
export interface ListTerpenesResponse {
|
|
11
223
|
terpenes: Terpene[];
|
|
12
224
|
}
|
|
225
|
+
export interface CreateTerpeneRequest {
|
|
226
|
+
name: string;
|
|
227
|
+
}
|
|
228
|
+
export interface CreateTerpeneResponse {
|
|
229
|
+
terpene: Terpene | undefined;
|
|
230
|
+
}
|
|
231
|
+
export interface UpdateTerpeneRequest {
|
|
232
|
+
id: string;
|
|
233
|
+
name: string;
|
|
234
|
+
}
|
|
235
|
+
export interface UpdateTerpeneResponse {
|
|
236
|
+
terpene: Terpene | undefined;
|
|
237
|
+
}
|
|
238
|
+
export interface DeleteTerpeneRequest {
|
|
239
|
+
id: string;
|
|
240
|
+
}
|
|
241
|
+
export interface DeleteTerpeneResponse {
|
|
242
|
+
terpene: Terpene | undefined;
|
|
243
|
+
}
|
|
13
244
|
export interface CatalogService {
|
|
245
|
+
listProducts(request: ListProductsRequest): Promise<ListProductsResponse>;
|
|
246
|
+
getProduct(request: GetProductRequest): Promise<GetProductResponse>;
|
|
247
|
+
createProduct(request: CreateProductRequest): Promise<CreateProductResponse>;
|
|
248
|
+
updateProduct(request: UpdateProductRequest): Promise<UpdateProductResponse>;
|
|
249
|
+
publishProduct(request: PublishProductRequest): Promise<PublishProductResponse>;
|
|
250
|
+
unpublishProduct(request: UnpublishProductRequest): Promise<UnpublishProductResponse>;
|
|
251
|
+
deleteProduct(request: DeleteProductRequest): Promise<DeleteProductResponse>;
|
|
252
|
+
setProductCover(request: SetProductCoverRequest): Promise<SetProductCoverResponse>;
|
|
253
|
+
listManufacturers(request: ListManufacturersRequest): Promise<ListManufacturersResponse>;
|
|
254
|
+
createManufacturer(request: CreateManufacturerRequest): Promise<CreateManufacturerResponse>;
|
|
255
|
+
updateManufacturer(request: UpdateManufacturerRequest): Promise<UpdateManufacturerResponse>;
|
|
256
|
+
deleteManufacturer(request: DeleteManufacturerRequest): Promise<DeleteManufacturerResponse>;
|
|
257
|
+
listStrains(request: ListStrainsRequest): Promise<ListStrainsResponse>;
|
|
258
|
+
createStrain(request: CreateStrainRequest): Promise<CreateStrainResponse>;
|
|
259
|
+
updateStrain(request: UpdateStrainRequest): Promise<UpdateStrainResponse>;
|
|
260
|
+
deleteStrain(request: DeleteStrainRequest): Promise<DeleteStrainResponse>;
|
|
14
261
|
listTerpenes(request: ListTerpenesRequest): Promise<ListTerpenesResponse>;
|
|
262
|
+
createTerpene(request: CreateTerpeneRequest): Promise<CreateTerpeneResponse>;
|
|
263
|
+
updateTerpene(request: UpdateTerpeneRequest): Promise<UpdateTerpeneResponse>;
|
|
264
|
+
deleteTerpene(request: DeleteTerpeneRequest): Promise<DeleteTerpeneResponse>;
|
|
15
265
|
}
|
package/dist/gen/catalog.js
CHANGED
|
@@ -5,7 +5,69 @@
|
|
|
5
5
|
// protoc v3.21.12
|
|
6
6
|
// source: catalog.proto
|
|
7
7
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
8
|
-
exports.protobufFileName = exports.protobufPackage = void 0;
|
|
8
|
+
exports.Flavor = exports.Availability = exports.PotencyUnit = exports.Genetics = exports.ProductStatus = exports.ProductType = exports.protobufFileName = exports.protobufPackage = void 0;
|
|
9
9
|
/* eslint-disable */
|
|
10
10
|
exports.protobufPackage = "catalog.v1";
|
|
11
11
|
exports.protobufFileName = "catalog.proto";
|
|
12
|
+
var ProductType;
|
|
13
|
+
(function (ProductType) {
|
|
14
|
+
ProductType[ProductType["PRODUCT_TYPE_UNSPECIFIED"] = 0] = "PRODUCT_TYPE_UNSPECIFIED";
|
|
15
|
+
ProductType[ProductType["PRODUCT_TYPE_FLOWER"] = 1] = "PRODUCT_TYPE_FLOWER";
|
|
16
|
+
ProductType[ProductType["PRODUCT_TYPE_EXTRACT"] = 2] = "PRODUCT_TYPE_EXTRACT";
|
|
17
|
+
ProductType[ProductType["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
18
|
+
})(ProductType || (exports.ProductType = ProductType = {}));
|
|
19
|
+
var ProductStatus;
|
|
20
|
+
(function (ProductStatus) {
|
|
21
|
+
ProductStatus[ProductStatus["PRODUCT_STATUS_UNSPECIFIED"] = 0] = "PRODUCT_STATUS_UNSPECIFIED";
|
|
22
|
+
ProductStatus[ProductStatus["PRODUCT_STATUS_DRAFT"] = 1] = "PRODUCT_STATUS_DRAFT";
|
|
23
|
+
ProductStatus[ProductStatus["PRODUCT_STATUS_PUBLISHED"] = 2] = "PRODUCT_STATUS_PUBLISHED";
|
|
24
|
+
ProductStatus[ProductStatus["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
25
|
+
})(ProductStatus || (exports.ProductStatus = ProductStatus = {}));
|
|
26
|
+
var Genetics;
|
|
27
|
+
(function (Genetics) {
|
|
28
|
+
Genetics[Genetics["GENETICS_UNSPECIFIED"] = 0] = "GENETICS_UNSPECIFIED";
|
|
29
|
+
Genetics[Genetics["GENETICS_SATIVA"] = 1] = "GENETICS_SATIVA";
|
|
30
|
+
Genetics[Genetics["GENETICS_SATIVA_DOMINANT"] = 2] = "GENETICS_SATIVA_DOMINANT";
|
|
31
|
+
Genetics[Genetics["GENETICS_HYBRID"] = 3] = "GENETICS_HYBRID";
|
|
32
|
+
Genetics[Genetics["GENETICS_INDICA_DOMINANT"] = 4] = "GENETICS_INDICA_DOMINANT";
|
|
33
|
+
Genetics[Genetics["GENETICS_INDICA"] = 5] = "GENETICS_INDICA";
|
|
34
|
+
Genetics[Genetics["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
35
|
+
})(Genetics || (exports.Genetics = Genetics = {}));
|
|
36
|
+
var PotencyUnit;
|
|
37
|
+
(function (PotencyUnit) {
|
|
38
|
+
PotencyUnit[PotencyUnit["POTENCY_UNIT_UNSPECIFIED"] = 0] = "POTENCY_UNIT_UNSPECIFIED";
|
|
39
|
+
PotencyUnit[PotencyUnit["POTENCY_UNIT_PERCENT"] = 1] = "POTENCY_UNIT_PERCENT";
|
|
40
|
+
PotencyUnit[PotencyUnit["POTENCY_UNIT_MG_PER_ML"] = 2] = "POTENCY_UNIT_MG_PER_ML";
|
|
41
|
+
PotencyUnit[PotencyUnit["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
42
|
+
})(PotencyUnit || (exports.PotencyUnit = PotencyUnit = {}));
|
|
43
|
+
var Availability;
|
|
44
|
+
(function (Availability) {
|
|
45
|
+
Availability[Availability["AVAILABILITY_UNSPECIFIED"] = 0] = "AVAILABILITY_UNSPECIFIED";
|
|
46
|
+
Availability[Availability["AVAILABILITY_UNKNOWN"] = 1] = "AVAILABILITY_UNKNOWN";
|
|
47
|
+
Availability[Availability["AVAILABILITY_AVAILABLE"] = 2] = "AVAILABILITY_AVAILABLE";
|
|
48
|
+
Availability[Availability["AVAILABILITY_SOLD_OUT"] = 3] = "AVAILABILITY_SOLD_OUT";
|
|
49
|
+
Availability[Availability["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
50
|
+
})(Availability || (exports.Availability = Availability = {}));
|
|
51
|
+
var Flavor;
|
|
52
|
+
(function (Flavor) {
|
|
53
|
+
Flavor[Flavor["FLAVOR_UNSPECIFIED"] = 0] = "FLAVOR_UNSPECIFIED";
|
|
54
|
+
Flavor[Flavor["FLAVOR_EARTHY"] = 1] = "FLAVOR_EARTHY";
|
|
55
|
+
Flavor[Flavor["FLAVOR_WOODY"] = 2] = "FLAVOR_WOODY";
|
|
56
|
+
Flavor[Flavor["FLAVOR_PINE"] = 3] = "FLAVOR_PINE";
|
|
57
|
+
Flavor[Flavor["FLAVOR_HERBAL"] = 4] = "FLAVOR_HERBAL";
|
|
58
|
+
Flavor[Flavor["FLAVOR_FLORAL"] = 5] = "FLAVOR_FLORAL";
|
|
59
|
+
Flavor[Flavor["FLAVOR_CITRUS"] = 6] = "FLAVOR_CITRUS";
|
|
60
|
+
Flavor[Flavor["FLAVOR_FRUITY"] = 7] = "FLAVOR_FRUITY";
|
|
61
|
+
Flavor[Flavor["FLAVOR_BERRY"] = 8] = "FLAVOR_BERRY";
|
|
62
|
+
Flavor[Flavor["FLAVOR_TROPICAL"] = 9] = "FLAVOR_TROPICAL";
|
|
63
|
+
Flavor[Flavor["FLAVOR_SWEET"] = 10] = "FLAVOR_SWEET";
|
|
64
|
+
Flavor[Flavor["FLAVOR_SPICY"] = 11] = "FLAVOR_SPICY";
|
|
65
|
+
Flavor[Flavor["FLAVOR_PEPPERY"] = 12] = "FLAVOR_PEPPERY";
|
|
66
|
+
Flavor[Flavor["FLAVOR_MENTHOL"] = 13] = "FLAVOR_MENTHOL";
|
|
67
|
+
Flavor[Flavor["FLAVOR_CHEESE"] = 14] = "FLAVOR_CHEESE";
|
|
68
|
+
Flavor[Flavor["FLAVOR_SKUNK"] = 15] = "FLAVOR_SKUNK";
|
|
69
|
+
Flavor[Flavor["FLAVOR_DIESEL"] = 16] = "FLAVOR_DIESEL";
|
|
70
|
+
Flavor[Flavor["FLAVOR_GASSY"] = 17] = "FLAVOR_GASSY";
|
|
71
|
+
Flavor[Flavor["FLAVOR_CHEMICAL"] = 18] = "FLAVOR_CHEMICAL";
|
|
72
|
+
Flavor[Flavor["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
73
|
+
})(Flavor || (exports.Flavor = Flavor = {}));
|
package/dist/gen/media.d.ts
CHANGED
package/dist/gen/media.js
CHANGED
|
@@ -12,5 +12,6 @@ var MediaKind;
|
|
|
12
12
|
(function (MediaKind) {
|
|
13
13
|
MediaKind[MediaKind["MEDIA_KIND_UNSPECIFIED"] = 0] = "MEDIA_KIND_UNSPECIFIED";
|
|
14
14
|
MediaKind[MediaKind["MEDIA_KIND_AVATAR"] = 1] = "MEDIA_KIND_AVATAR";
|
|
15
|
+
MediaKind[MediaKind["MEDIA_KIND_PRODUCT_COVER"] = 2] = "MEDIA_KIND_PRODUCT_COVER";
|
|
15
16
|
MediaKind[MediaKind["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
16
17
|
})(MediaKind || (exports.MediaKind = MediaKind = {}));
|
package/dist/gen/treatment.d.ts
CHANGED
|
@@ -143,6 +143,7 @@ export interface ListTreatmentRequestsRequest {
|
|
|
143
143
|
export interface ListTreatmentRequestsResponse {
|
|
144
144
|
requests: TreatmentRequest[];
|
|
145
145
|
nextCursor?: string | undefined;
|
|
146
|
+
total: number;
|
|
146
147
|
}
|
|
147
148
|
export interface ListAllTreatmentRequestsRequest {
|
|
148
149
|
number?: string | undefined;
|
|
@@ -154,6 +155,7 @@ export interface ListAllTreatmentRequestsRequest {
|
|
|
154
155
|
export interface ListAllTreatmentRequestsResponse {
|
|
155
156
|
requests: TreatmentRequest[];
|
|
156
157
|
nextCursor?: string | undefined;
|
|
158
|
+
total: number;
|
|
157
159
|
}
|
|
158
160
|
export interface UpdateTreatmentRequestRequest {
|
|
159
161
|
userId: string;
|
package/dist/nest/account.d.ts
CHANGED
|
@@ -193,6 +193,7 @@ export interface ListPatientAccountsRequest {
|
|
|
193
193
|
export interface ListPatientAccountsResponse {
|
|
194
194
|
accounts: PatientAccount[];
|
|
195
195
|
nextCursor?: string | undefined;
|
|
196
|
+
total: number;
|
|
196
197
|
}
|
|
197
198
|
export interface GetPatientAccountRequest {
|
|
198
199
|
id: string;
|
package/dist/nest/audit.d.ts
CHANGED
package/dist/nest/catalog.d.ts
CHANGED
|
@@ -1,22 +1,291 @@
|
|
|
1
1
|
import { Observable } from "rxjs";
|
|
2
2
|
export declare const protobufPackage = "catalog.v1";
|
|
3
3
|
export declare const protobufFileName = "catalog.proto";
|
|
4
|
+
export declare enum ProductType {
|
|
5
|
+
PRODUCT_TYPE_UNSPECIFIED = 0,
|
|
6
|
+
PRODUCT_TYPE_FLOWER = 1,
|
|
7
|
+
PRODUCT_TYPE_EXTRACT = 2,
|
|
8
|
+
UNRECOGNIZED = -1
|
|
9
|
+
}
|
|
10
|
+
export declare enum ProductStatus {
|
|
11
|
+
PRODUCT_STATUS_UNSPECIFIED = 0,
|
|
12
|
+
PRODUCT_STATUS_DRAFT = 1,
|
|
13
|
+
PRODUCT_STATUS_PUBLISHED = 2,
|
|
14
|
+
UNRECOGNIZED = -1
|
|
15
|
+
}
|
|
16
|
+
export declare enum Genetics {
|
|
17
|
+
GENETICS_UNSPECIFIED = 0,
|
|
18
|
+
GENETICS_SATIVA = 1,
|
|
19
|
+
GENETICS_SATIVA_DOMINANT = 2,
|
|
20
|
+
GENETICS_HYBRID = 3,
|
|
21
|
+
GENETICS_INDICA_DOMINANT = 4,
|
|
22
|
+
GENETICS_INDICA = 5,
|
|
23
|
+
UNRECOGNIZED = -1
|
|
24
|
+
}
|
|
25
|
+
export declare enum PotencyUnit {
|
|
26
|
+
POTENCY_UNIT_UNSPECIFIED = 0,
|
|
27
|
+
POTENCY_UNIT_PERCENT = 1,
|
|
28
|
+
POTENCY_UNIT_MG_PER_ML = 2,
|
|
29
|
+
UNRECOGNIZED = -1
|
|
30
|
+
}
|
|
31
|
+
export declare enum Availability {
|
|
32
|
+
AVAILABILITY_UNSPECIFIED = 0,
|
|
33
|
+
AVAILABILITY_UNKNOWN = 1,
|
|
34
|
+
AVAILABILITY_AVAILABLE = 2,
|
|
35
|
+
AVAILABILITY_SOLD_OUT = 3,
|
|
36
|
+
UNRECOGNIZED = -1
|
|
37
|
+
}
|
|
38
|
+
export declare enum Flavor {
|
|
39
|
+
FLAVOR_UNSPECIFIED = 0,
|
|
40
|
+
FLAVOR_EARTHY = 1,
|
|
41
|
+
FLAVOR_WOODY = 2,
|
|
42
|
+
FLAVOR_PINE = 3,
|
|
43
|
+
FLAVOR_HERBAL = 4,
|
|
44
|
+
FLAVOR_FLORAL = 5,
|
|
45
|
+
FLAVOR_CITRUS = 6,
|
|
46
|
+
FLAVOR_FRUITY = 7,
|
|
47
|
+
FLAVOR_BERRY = 8,
|
|
48
|
+
FLAVOR_TROPICAL = 9,
|
|
49
|
+
FLAVOR_SWEET = 10,
|
|
50
|
+
FLAVOR_SPICY = 11,
|
|
51
|
+
FLAVOR_PEPPERY = 12,
|
|
52
|
+
FLAVOR_MENTHOL = 13,
|
|
53
|
+
FLAVOR_CHEESE = 14,
|
|
54
|
+
FLAVOR_SKUNK = 15,
|
|
55
|
+
FLAVOR_DIESEL = 16,
|
|
56
|
+
FLAVOR_GASSY = 17,
|
|
57
|
+
FLAVOR_CHEMICAL = 18,
|
|
58
|
+
UNRECOGNIZED = -1
|
|
59
|
+
}
|
|
60
|
+
export interface Manufacturer {
|
|
61
|
+
id: string;
|
|
62
|
+
name: string;
|
|
63
|
+
slug: string;
|
|
64
|
+
}
|
|
65
|
+
export interface Strain {
|
|
66
|
+
id: string;
|
|
67
|
+
name: string;
|
|
68
|
+
slug: string;
|
|
69
|
+
}
|
|
4
70
|
export interface Terpene {
|
|
5
71
|
id: string;
|
|
6
72
|
name: string;
|
|
7
73
|
slug: string;
|
|
8
74
|
}
|
|
75
|
+
export interface Product {
|
|
76
|
+
id: string;
|
|
77
|
+
number: number;
|
|
78
|
+
name: string;
|
|
79
|
+
type: ProductType;
|
|
80
|
+
status: ProductStatus;
|
|
81
|
+
manufacturer: Manufacturer | undefined;
|
|
82
|
+
strain?: Strain | undefined;
|
|
83
|
+
genetics?: Genetics | undefined;
|
|
84
|
+
thc: number;
|
|
85
|
+
cbd: number;
|
|
86
|
+
potencyUnit: PotencyUnit;
|
|
87
|
+
country?: string | undefined;
|
|
88
|
+
isIrradiated: boolean;
|
|
89
|
+
flavors: Flavor[];
|
|
90
|
+
terpenes: Terpene[];
|
|
91
|
+
description?: string | undefined;
|
|
92
|
+
price?: number | undefined;
|
|
93
|
+
availability: Availability;
|
|
94
|
+
publishedAt?: string | undefined;
|
|
95
|
+
createdAt: string;
|
|
96
|
+
updatedAt: string;
|
|
97
|
+
coverKey?: string | undefined;
|
|
98
|
+
}
|
|
99
|
+
export interface ProductInput {
|
|
100
|
+
name: string;
|
|
101
|
+
type: ProductType;
|
|
102
|
+
manufacturerId: string;
|
|
103
|
+
strainId?: string | undefined;
|
|
104
|
+
genetics?: Genetics | undefined;
|
|
105
|
+
thc: number;
|
|
106
|
+
cbd: number;
|
|
107
|
+
potencyUnit: PotencyUnit;
|
|
108
|
+
country?: string | undefined;
|
|
109
|
+
isIrradiated: boolean;
|
|
110
|
+
flavors: Flavor[];
|
|
111
|
+
terpeneIds: string[];
|
|
112
|
+
description?: string | undefined;
|
|
113
|
+
price?: number | undefined;
|
|
114
|
+
availability: Availability;
|
|
115
|
+
}
|
|
116
|
+
export interface ListProductsRequest {
|
|
117
|
+
query?: string | undefined;
|
|
118
|
+
type?: ProductType | undefined;
|
|
119
|
+
status?: ProductStatus | undefined;
|
|
120
|
+
cursor?: string | undefined;
|
|
121
|
+
limit: number;
|
|
122
|
+
}
|
|
123
|
+
export interface ListProductsResponse {
|
|
124
|
+
products: Product[];
|
|
125
|
+
nextCursor?: string | undefined;
|
|
126
|
+
total: number;
|
|
127
|
+
}
|
|
128
|
+
export interface GetProductRequest {
|
|
129
|
+
id: string;
|
|
130
|
+
}
|
|
131
|
+
export interface GetProductResponse {
|
|
132
|
+
product: Product | undefined;
|
|
133
|
+
}
|
|
134
|
+
export interface CreateProductRequest {
|
|
135
|
+
product: ProductInput | undefined;
|
|
136
|
+
}
|
|
137
|
+
export interface CreateProductResponse {
|
|
138
|
+
product: Product | undefined;
|
|
139
|
+
}
|
|
140
|
+
export interface UpdateProductRequest {
|
|
141
|
+
id: string;
|
|
142
|
+
product: ProductInput | undefined;
|
|
143
|
+
}
|
|
144
|
+
export interface UpdateProductResponse {
|
|
145
|
+
product: Product | undefined;
|
|
146
|
+
}
|
|
147
|
+
export interface PublishProductRequest {
|
|
148
|
+
id: string;
|
|
149
|
+
}
|
|
150
|
+
export interface PublishProductResponse {
|
|
151
|
+
product: Product | undefined;
|
|
152
|
+
}
|
|
153
|
+
export interface UnpublishProductRequest {
|
|
154
|
+
id: string;
|
|
155
|
+
}
|
|
156
|
+
export interface UnpublishProductResponse {
|
|
157
|
+
product: Product | undefined;
|
|
158
|
+
}
|
|
159
|
+
export interface DeleteProductRequest {
|
|
160
|
+
id: string;
|
|
161
|
+
}
|
|
162
|
+
export interface DeleteProductResponse {
|
|
163
|
+
product: Product | undefined;
|
|
164
|
+
}
|
|
165
|
+
export interface SetProductCoverRequest {
|
|
166
|
+
id: string;
|
|
167
|
+
coverKey?: string | undefined;
|
|
168
|
+
}
|
|
169
|
+
export interface SetProductCoverResponse {
|
|
170
|
+
product: Product | undefined;
|
|
171
|
+
previousCoverKey?: string | undefined;
|
|
172
|
+
}
|
|
173
|
+
export interface ListManufacturersRequest {
|
|
174
|
+
}
|
|
175
|
+
export interface ListManufacturersResponse {
|
|
176
|
+
manufacturers: Manufacturer[];
|
|
177
|
+
}
|
|
178
|
+
export interface CreateManufacturerRequest {
|
|
179
|
+
name: string;
|
|
180
|
+
}
|
|
181
|
+
export interface CreateManufacturerResponse {
|
|
182
|
+
manufacturer: Manufacturer | undefined;
|
|
183
|
+
}
|
|
184
|
+
export interface UpdateManufacturerRequest {
|
|
185
|
+
id: string;
|
|
186
|
+
name: string;
|
|
187
|
+
}
|
|
188
|
+
export interface UpdateManufacturerResponse {
|
|
189
|
+
manufacturer: Manufacturer | undefined;
|
|
190
|
+
}
|
|
191
|
+
export interface DeleteManufacturerRequest {
|
|
192
|
+
id: string;
|
|
193
|
+
}
|
|
194
|
+
export interface DeleteManufacturerResponse {
|
|
195
|
+
manufacturer: Manufacturer | undefined;
|
|
196
|
+
}
|
|
197
|
+
export interface ListStrainsRequest {
|
|
198
|
+
}
|
|
199
|
+
export interface ListStrainsResponse {
|
|
200
|
+
strains: Strain[];
|
|
201
|
+
}
|
|
202
|
+
export interface CreateStrainRequest {
|
|
203
|
+
name: string;
|
|
204
|
+
}
|
|
205
|
+
export interface CreateStrainResponse {
|
|
206
|
+
strain: Strain | undefined;
|
|
207
|
+
}
|
|
208
|
+
export interface UpdateStrainRequest {
|
|
209
|
+
id: string;
|
|
210
|
+
name: string;
|
|
211
|
+
}
|
|
212
|
+
export interface UpdateStrainResponse {
|
|
213
|
+
strain: Strain | undefined;
|
|
214
|
+
}
|
|
215
|
+
export interface DeleteStrainRequest {
|
|
216
|
+
id: string;
|
|
217
|
+
}
|
|
218
|
+
export interface DeleteStrainResponse {
|
|
219
|
+
strain: Strain | undefined;
|
|
220
|
+
}
|
|
9
221
|
export interface ListTerpenesRequest {
|
|
10
222
|
}
|
|
11
223
|
export interface ListTerpenesResponse {
|
|
12
224
|
terpenes: Terpene[];
|
|
13
225
|
}
|
|
226
|
+
export interface CreateTerpeneRequest {
|
|
227
|
+
name: string;
|
|
228
|
+
}
|
|
229
|
+
export interface CreateTerpeneResponse {
|
|
230
|
+
terpene: Terpene | undefined;
|
|
231
|
+
}
|
|
232
|
+
export interface UpdateTerpeneRequest {
|
|
233
|
+
id: string;
|
|
234
|
+
name: string;
|
|
235
|
+
}
|
|
236
|
+
export interface UpdateTerpeneResponse {
|
|
237
|
+
terpene: Terpene | undefined;
|
|
238
|
+
}
|
|
239
|
+
export interface DeleteTerpeneRequest {
|
|
240
|
+
id: string;
|
|
241
|
+
}
|
|
242
|
+
export interface DeleteTerpeneResponse {
|
|
243
|
+
terpene: Terpene | undefined;
|
|
244
|
+
}
|
|
14
245
|
export declare const CATALOG_V1_PACKAGE_NAME = "catalog.v1";
|
|
15
246
|
export interface CatalogServiceClient {
|
|
247
|
+
listProducts(request: ListProductsRequest): Observable<ListProductsResponse>;
|
|
248
|
+
getProduct(request: GetProductRequest): Observable<GetProductResponse>;
|
|
249
|
+
createProduct(request: CreateProductRequest): Observable<CreateProductResponse>;
|
|
250
|
+
updateProduct(request: UpdateProductRequest): Observable<UpdateProductResponse>;
|
|
251
|
+
publishProduct(request: PublishProductRequest): Observable<PublishProductResponse>;
|
|
252
|
+
unpublishProduct(request: UnpublishProductRequest): Observable<UnpublishProductResponse>;
|
|
253
|
+
deleteProduct(request: DeleteProductRequest): Observable<DeleteProductResponse>;
|
|
254
|
+
setProductCover(request: SetProductCoverRequest): Observable<SetProductCoverResponse>;
|
|
255
|
+
listManufacturers(request: ListManufacturersRequest): Observable<ListManufacturersResponse>;
|
|
256
|
+
createManufacturer(request: CreateManufacturerRequest): Observable<CreateManufacturerResponse>;
|
|
257
|
+
updateManufacturer(request: UpdateManufacturerRequest): Observable<UpdateManufacturerResponse>;
|
|
258
|
+
deleteManufacturer(request: DeleteManufacturerRequest): Observable<DeleteManufacturerResponse>;
|
|
259
|
+
listStrains(request: ListStrainsRequest): Observable<ListStrainsResponse>;
|
|
260
|
+
createStrain(request: CreateStrainRequest): Observable<CreateStrainResponse>;
|
|
261
|
+
updateStrain(request: UpdateStrainRequest): Observable<UpdateStrainResponse>;
|
|
262
|
+
deleteStrain(request: DeleteStrainRequest): Observable<DeleteStrainResponse>;
|
|
16
263
|
listTerpenes(request: ListTerpenesRequest): Observable<ListTerpenesResponse>;
|
|
264
|
+
createTerpene(request: CreateTerpeneRequest): Observable<CreateTerpeneResponse>;
|
|
265
|
+
updateTerpene(request: UpdateTerpeneRequest): Observable<UpdateTerpeneResponse>;
|
|
266
|
+
deleteTerpene(request: DeleteTerpeneRequest): Observable<DeleteTerpeneResponse>;
|
|
17
267
|
}
|
|
18
268
|
export interface CatalogServiceController {
|
|
269
|
+
listProducts(request: ListProductsRequest): Promise<ListProductsResponse> | Observable<ListProductsResponse> | ListProductsResponse;
|
|
270
|
+
getProduct(request: GetProductRequest): Promise<GetProductResponse> | Observable<GetProductResponse> | GetProductResponse;
|
|
271
|
+
createProduct(request: CreateProductRequest): Promise<CreateProductResponse> | Observable<CreateProductResponse> | CreateProductResponse;
|
|
272
|
+
updateProduct(request: UpdateProductRequest): Promise<UpdateProductResponse> | Observable<UpdateProductResponse> | UpdateProductResponse;
|
|
273
|
+
publishProduct(request: PublishProductRequest): Promise<PublishProductResponse> | Observable<PublishProductResponse> | PublishProductResponse;
|
|
274
|
+
unpublishProduct(request: UnpublishProductRequest): Promise<UnpublishProductResponse> | Observable<UnpublishProductResponse> | UnpublishProductResponse;
|
|
275
|
+
deleteProduct(request: DeleteProductRequest): Promise<DeleteProductResponse> | Observable<DeleteProductResponse> | DeleteProductResponse;
|
|
276
|
+
setProductCover(request: SetProductCoverRequest): Promise<SetProductCoverResponse> | Observable<SetProductCoverResponse> | SetProductCoverResponse;
|
|
277
|
+
listManufacturers(request: ListManufacturersRequest): Promise<ListManufacturersResponse> | Observable<ListManufacturersResponse> | ListManufacturersResponse;
|
|
278
|
+
createManufacturer(request: CreateManufacturerRequest): Promise<CreateManufacturerResponse> | Observable<CreateManufacturerResponse> | CreateManufacturerResponse;
|
|
279
|
+
updateManufacturer(request: UpdateManufacturerRequest): Promise<UpdateManufacturerResponse> | Observable<UpdateManufacturerResponse> | UpdateManufacturerResponse;
|
|
280
|
+
deleteManufacturer(request: DeleteManufacturerRequest): Promise<DeleteManufacturerResponse> | Observable<DeleteManufacturerResponse> | DeleteManufacturerResponse;
|
|
281
|
+
listStrains(request: ListStrainsRequest): Promise<ListStrainsResponse> | Observable<ListStrainsResponse> | ListStrainsResponse;
|
|
282
|
+
createStrain(request: CreateStrainRequest): Promise<CreateStrainResponse> | Observable<CreateStrainResponse> | CreateStrainResponse;
|
|
283
|
+
updateStrain(request: UpdateStrainRequest): Promise<UpdateStrainResponse> | Observable<UpdateStrainResponse> | UpdateStrainResponse;
|
|
284
|
+
deleteStrain(request: DeleteStrainRequest): Promise<DeleteStrainResponse> | Observable<DeleteStrainResponse> | DeleteStrainResponse;
|
|
19
285
|
listTerpenes(request: ListTerpenesRequest): Promise<ListTerpenesResponse> | Observable<ListTerpenesResponse> | ListTerpenesResponse;
|
|
286
|
+
createTerpene(request: CreateTerpeneRequest): Promise<CreateTerpeneResponse> | Observable<CreateTerpeneResponse> | CreateTerpeneResponse;
|
|
287
|
+
updateTerpene(request: UpdateTerpeneRequest): Promise<UpdateTerpeneResponse> | Observable<UpdateTerpeneResponse> | UpdateTerpeneResponse;
|
|
288
|
+
deleteTerpene(request: DeleteTerpeneRequest): Promise<DeleteTerpeneResponse> | Observable<DeleteTerpeneResponse> | DeleteTerpeneResponse;
|
|
20
289
|
}
|
|
21
290
|
export declare function CatalogServiceControllerMethods(): (constructor: Function) => void;
|
|
22
291
|
export declare const CATALOG_SERVICE_NAME = "CatalogService";
|
package/dist/nest/catalog.js
CHANGED
|
@@ -5,16 +5,99 @@
|
|
|
5
5
|
// protoc v3.21.12
|
|
6
6
|
// source: catalog.proto
|
|
7
7
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
8
|
-
exports.CATALOG_SERVICE_NAME = exports.CATALOG_V1_PACKAGE_NAME = exports.protobufFileName = exports.protobufPackage = void 0;
|
|
8
|
+
exports.CATALOG_SERVICE_NAME = exports.CATALOG_V1_PACKAGE_NAME = exports.Flavor = exports.Availability = exports.PotencyUnit = exports.Genetics = exports.ProductStatus = exports.ProductType = exports.protobufFileName = exports.protobufPackage = void 0;
|
|
9
9
|
exports.CatalogServiceControllerMethods = CatalogServiceControllerMethods;
|
|
10
10
|
/* eslint-disable */
|
|
11
11
|
const microservices_1 = require("@nestjs/microservices");
|
|
12
12
|
exports.protobufPackage = "catalog.v1";
|
|
13
13
|
exports.protobufFileName = "catalog.proto";
|
|
14
|
+
var ProductType;
|
|
15
|
+
(function (ProductType) {
|
|
16
|
+
ProductType[ProductType["PRODUCT_TYPE_UNSPECIFIED"] = 0] = "PRODUCT_TYPE_UNSPECIFIED";
|
|
17
|
+
ProductType[ProductType["PRODUCT_TYPE_FLOWER"] = 1] = "PRODUCT_TYPE_FLOWER";
|
|
18
|
+
ProductType[ProductType["PRODUCT_TYPE_EXTRACT"] = 2] = "PRODUCT_TYPE_EXTRACT";
|
|
19
|
+
ProductType[ProductType["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
20
|
+
})(ProductType || (exports.ProductType = ProductType = {}));
|
|
21
|
+
var ProductStatus;
|
|
22
|
+
(function (ProductStatus) {
|
|
23
|
+
ProductStatus[ProductStatus["PRODUCT_STATUS_UNSPECIFIED"] = 0] = "PRODUCT_STATUS_UNSPECIFIED";
|
|
24
|
+
ProductStatus[ProductStatus["PRODUCT_STATUS_DRAFT"] = 1] = "PRODUCT_STATUS_DRAFT";
|
|
25
|
+
ProductStatus[ProductStatus["PRODUCT_STATUS_PUBLISHED"] = 2] = "PRODUCT_STATUS_PUBLISHED";
|
|
26
|
+
ProductStatus[ProductStatus["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
27
|
+
})(ProductStatus || (exports.ProductStatus = ProductStatus = {}));
|
|
28
|
+
var Genetics;
|
|
29
|
+
(function (Genetics) {
|
|
30
|
+
Genetics[Genetics["GENETICS_UNSPECIFIED"] = 0] = "GENETICS_UNSPECIFIED";
|
|
31
|
+
Genetics[Genetics["GENETICS_SATIVA"] = 1] = "GENETICS_SATIVA";
|
|
32
|
+
Genetics[Genetics["GENETICS_SATIVA_DOMINANT"] = 2] = "GENETICS_SATIVA_DOMINANT";
|
|
33
|
+
Genetics[Genetics["GENETICS_HYBRID"] = 3] = "GENETICS_HYBRID";
|
|
34
|
+
Genetics[Genetics["GENETICS_INDICA_DOMINANT"] = 4] = "GENETICS_INDICA_DOMINANT";
|
|
35
|
+
Genetics[Genetics["GENETICS_INDICA"] = 5] = "GENETICS_INDICA";
|
|
36
|
+
Genetics[Genetics["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
37
|
+
})(Genetics || (exports.Genetics = Genetics = {}));
|
|
38
|
+
var PotencyUnit;
|
|
39
|
+
(function (PotencyUnit) {
|
|
40
|
+
PotencyUnit[PotencyUnit["POTENCY_UNIT_UNSPECIFIED"] = 0] = "POTENCY_UNIT_UNSPECIFIED";
|
|
41
|
+
PotencyUnit[PotencyUnit["POTENCY_UNIT_PERCENT"] = 1] = "POTENCY_UNIT_PERCENT";
|
|
42
|
+
PotencyUnit[PotencyUnit["POTENCY_UNIT_MG_PER_ML"] = 2] = "POTENCY_UNIT_MG_PER_ML";
|
|
43
|
+
PotencyUnit[PotencyUnit["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
44
|
+
})(PotencyUnit || (exports.PotencyUnit = PotencyUnit = {}));
|
|
45
|
+
var Availability;
|
|
46
|
+
(function (Availability) {
|
|
47
|
+
Availability[Availability["AVAILABILITY_UNSPECIFIED"] = 0] = "AVAILABILITY_UNSPECIFIED";
|
|
48
|
+
Availability[Availability["AVAILABILITY_UNKNOWN"] = 1] = "AVAILABILITY_UNKNOWN";
|
|
49
|
+
Availability[Availability["AVAILABILITY_AVAILABLE"] = 2] = "AVAILABILITY_AVAILABLE";
|
|
50
|
+
Availability[Availability["AVAILABILITY_SOLD_OUT"] = 3] = "AVAILABILITY_SOLD_OUT";
|
|
51
|
+
Availability[Availability["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
52
|
+
})(Availability || (exports.Availability = Availability = {}));
|
|
53
|
+
var Flavor;
|
|
54
|
+
(function (Flavor) {
|
|
55
|
+
Flavor[Flavor["FLAVOR_UNSPECIFIED"] = 0] = "FLAVOR_UNSPECIFIED";
|
|
56
|
+
Flavor[Flavor["FLAVOR_EARTHY"] = 1] = "FLAVOR_EARTHY";
|
|
57
|
+
Flavor[Flavor["FLAVOR_WOODY"] = 2] = "FLAVOR_WOODY";
|
|
58
|
+
Flavor[Flavor["FLAVOR_PINE"] = 3] = "FLAVOR_PINE";
|
|
59
|
+
Flavor[Flavor["FLAVOR_HERBAL"] = 4] = "FLAVOR_HERBAL";
|
|
60
|
+
Flavor[Flavor["FLAVOR_FLORAL"] = 5] = "FLAVOR_FLORAL";
|
|
61
|
+
Flavor[Flavor["FLAVOR_CITRUS"] = 6] = "FLAVOR_CITRUS";
|
|
62
|
+
Flavor[Flavor["FLAVOR_FRUITY"] = 7] = "FLAVOR_FRUITY";
|
|
63
|
+
Flavor[Flavor["FLAVOR_BERRY"] = 8] = "FLAVOR_BERRY";
|
|
64
|
+
Flavor[Flavor["FLAVOR_TROPICAL"] = 9] = "FLAVOR_TROPICAL";
|
|
65
|
+
Flavor[Flavor["FLAVOR_SWEET"] = 10] = "FLAVOR_SWEET";
|
|
66
|
+
Flavor[Flavor["FLAVOR_SPICY"] = 11] = "FLAVOR_SPICY";
|
|
67
|
+
Flavor[Flavor["FLAVOR_PEPPERY"] = 12] = "FLAVOR_PEPPERY";
|
|
68
|
+
Flavor[Flavor["FLAVOR_MENTHOL"] = 13] = "FLAVOR_MENTHOL";
|
|
69
|
+
Flavor[Flavor["FLAVOR_CHEESE"] = 14] = "FLAVOR_CHEESE";
|
|
70
|
+
Flavor[Flavor["FLAVOR_SKUNK"] = 15] = "FLAVOR_SKUNK";
|
|
71
|
+
Flavor[Flavor["FLAVOR_DIESEL"] = 16] = "FLAVOR_DIESEL";
|
|
72
|
+
Flavor[Flavor["FLAVOR_GASSY"] = 17] = "FLAVOR_GASSY";
|
|
73
|
+
Flavor[Flavor["FLAVOR_CHEMICAL"] = 18] = "FLAVOR_CHEMICAL";
|
|
74
|
+
Flavor[Flavor["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
75
|
+
})(Flavor || (exports.Flavor = Flavor = {}));
|
|
14
76
|
exports.CATALOG_V1_PACKAGE_NAME = "catalog.v1";
|
|
15
77
|
function CatalogServiceControllerMethods() {
|
|
16
78
|
return function (constructor) {
|
|
17
|
-
const grpcMethods = [
|
|
79
|
+
const grpcMethods = [
|
|
80
|
+
"listProducts",
|
|
81
|
+
"getProduct",
|
|
82
|
+
"createProduct",
|
|
83
|
+
"updateProduct",
|
|
84
|
+
"publishProduct",
|
|
85
|
+
"unpublishProduct",
|
|
86
|
+
"deleteProduct",
|
|
87
|
+
"setProductCover",
|
|
88
|
+
"listManufacturers",
|
|
89
|
+
"createManufacturer",
|
|
90
|
+
"updateManufacturer",
|
|
91
|
+
"deleteManufacturer",
|
|
92
|
+
"listStrains",
|
|
93
|
+
"createStrain",
|
|
94
|
+
"updateStrain",
|
|
95
|
+
"deleteStrain",
|
|
96
|
+
"listTerpenes",
|
|
97
|
+
"createTerpene",
|
|
98
|
+
"updateTerpene",
|
|
99
|
+
"deleteTerpene",
|
|
100
|
+
];
|
|
18
101
|
for (const method of grpcMethods) {
|
|
19
102
|
const descriptor = Reflect.getOwnPropertyDescriptor(constructor.prototype, method);
|
|
20
103
|
(0, microservices_1.GrpcMethod)("CatalogService", method)(constructor.prototype[method], method, descriptor);
|
package/dist/nest/media.d.ts
CHANGED
package/dist/nest/media.js
CHANGED
|
@@ -15,6 +15,7 @@ var MediaKind;
|
|
|
15
15
|
(function (MediaKind) {
|
|
16
16
|
MediaKind[MediaKind["MEDIA_KIND_UNSPECIFIED"] = 0] = "MEDIA_KIND_UNSPECIFIED";
|
|
17
17
|
MediaKind[MediaKind["MEDIA_KIND_AVATAR"] = 1] = "MEDIA_KIND_AVATAR";
|
|
18
|
+
MediaKind[MediaKind["MEDIA_KIND_PRODUCT_COVER"] = 2] = "MEDIA_KIND_PRODUCT_COVER";
|
|
18
19
|
MediaKind[MediaKind["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
19
20
|
})(MediaKind || (exports.MediaKind = MediaKind = {}));
|
|
20
21
|
exports.MEDIA_V1_PACKAGE_NAME = "media.v1";
|
package/dist/nest/treatment.d.ts
CHANGED
|
@@ -144,6 +144,7 @@ export interface ListTreatmentRequestsRequest {
|
|
|
144
144
|
export interface ListTreatmentRequestsResponse {
|
|
145
145
|
requests: TreatmentRequest[];
|
|
146
146
|
nextCursor?: string | undefined;
|
|
147
|
+
total: number;
|
|
147
148
|
}
|
|
148
149
|
export interface ListAllTreatmentRequestsRequest {
|
|
149
150
|
number?: string | undefined;
|
|
@@ -155,6 +156,7 @@ export interface ListAllTreatmentRequestsRequest {
|
|
|
155
156
|
export interface ListAllTreatmentRequestsResponse {
|
|
156
157
|
requests: TreatmentRequest[];
|
|
157
158
|
nextCursor?: string | undefined;
|
|
159
|
+
total: number;
|
|
158
160
|
}
|
|
159
161
|
export interface UpdateTreatmentRequestRequest {
|
|
160
162
|
userId: string;
|
package/package.json
CHANGED
package/proto/account.proto
CHANGED
package/proto/audit.proto
CHANGED
package/proto/catalog.proto
CHANGED
|
@@ -3,7 +3,97 @@ syntax = "proto3";
|
|
|
3
3
|
package catalog.v1;
|
|
4
4
|
|
|
5
5
|
service CatalogService {
|
|
6
|
+
rpc ListProducts (ListProductsRequest) returns (ListProductsResponse);
|
|
7
|
+
rpc GetProduct (GetProductRequest) returns (GetProductResponse);
|
|
8
|
+
rpc CreateProduct (CreateProductRequest) returns (CreateProductResponse);
|
|
9
|
+
rpc UpdateProduct (UpdateProductRequest) returns (UpdateProductResponse);
|
|
10
|
+
rpc PublishProduct (PublishProductRequest) returns (PublishProductResponse);
|
|
11
|
+
rpc UnpublishProduct (UnpublishProductRequest) returns (UnpublishProductResponse);
|
|
12
|
+
rpc DeleteProduct (DeleteProductRequest) returns (DeleteProductResponse);
|
|
13
|
+
rpc SetProductCover (SetProductCoverRequest) returns (SetProductCoverResponse);
|
|
14
|
+
|
|
15
|
+
rpc ListManufacturers (ListManufacturersRequest) returns (ListManufacturersResponse);
|
|
16
|
+
rpc CreateManufacturer (CreateManufacturerRequest) returns (CreateManufacturerResponse);
|
|
17
|
+
rpc UpdateManufacturer (UpdateManufacturerRequest) returns (UpdateManufacturerResponse);
|
|
18
|
+
rpc DeleteManufacturer (DeleteManufacturerRequest) returns (DeleteManufacturerResponse);
|
|
19
|
+
|
|
20
|
+
rpc ListStrains (ListStrainsRequest) returns (ListStrainsResponse);
|
|
21
|
+
rpc CreateStrain (CreateStrainRequest) returns (CreateStrainResponse);
|
|
22
|
+
rpc UpdateStrain (UpdateStrainRequest) returns (UpdateStrainResponse);
|
|
23
|
+
rpc DeleteStrain (DeleteStrainRequest) returns (DeleteStrainResponse);
|
|
24
|
+
|
|
6
25
|
rpc ListTerpenes (ListTerpenesRequest) returns (ListTerpenesResponse);
|
|
26
|
+
rpc CreateTerpene (CreateTerpeneRequest) returns (CreateTerpeneResponse);
|
|
27
|
+
rpc UpdateTerpene (UpdateTerpeneRequest) returns (UpdateTerpeneResponse);
|
|
28
|
+
rpc DeleteTerpene (DeleteTerpeneRequest) returns (DeleteTerpeneResponse);
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
enum ProductType {
|
|
32
|
+
PRODUCT_TYPE_UNSPECIFIED = 0;
|
|
33
|
+
PRODUCT_TYPE_FLOWER = 1;
|
|
34
|
+
PRODUCT_TYPE_EXTRACT = 2;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
enum ProductStatus {
|
|
38
|
+
PRODUCT_STATUS_UNSPECIFIED = 0;
|
|
39
|
+
PRODUCT_STATUS_DRAFT = 1;
|
|
40
|
+
PRODUCT_STATUS_PUBLISHED = 2;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
enum Genetics {
|
|
44
|
+
GENETICS_UNSPECIFIED = 0;
|
|
45
|
+
GENETICS_SATIVA = 1;
|
|
46
|
+
GENETICS_SATIVA_DOMINANT = 2;
|
|
47
|
+
GENETICS_HYBRID = 3;
|
|
48
|
+
GENETICS_INDICA_DOMINANT = 4;
|
|
49
|
+
GENETICS_INDICA = 5;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
enum PotencyUnit {
|
|
53
|
+
POTENCY_UNIT_UNSPECIFIED = 0;
|
|
54
|
+
POTENCY_UNIT_PERCENT = 1;
|
|
55
|
+
POTENCY_UNIT_MG_PER_ML = 2;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
enum Availability {
|
|
59
|
+
AVAILABILITY_UNSPECIFIED = 0;
|
|
60
|
+
AVAILABILITY_UNKNOWN = 1;
|
|
61
|
+
AVAILABILITY_AVAILABLE = 2;
|
|
62
|
+
AVAILABILITY_SOLD_OUT = 3;
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
enum Flavor {
|
|
66
|
+
FLAVOR_UNSPECIFIED = 0;
|
|
67
|
+
FLAVOR_EARTHY = 1;
|
|
68
|
+
FLAVOR_WOODY = 2;
|
|
69
|
+
FLAVOR_PINE = 3;
|
|
70
|
+
FLAVOR_HERBAL = 4;
|
|
71
|
+
FLAVOR_FLORAL = 5;
|
|
72
|
+
FLAVOR_CITRUS = 6;
|
|
73
|
+
FLAVOR_FRUITY = 7;
|
|
74
|
+
FLAVOR_BERRY = 8;
|
|
75
|
+
FLAVOR_TROPICAL = 9;
|
|
76
|
+
FLAVOR_SWEET = 10;
|
|
77
|
+
FLAVOR_SPICY = 11;
|
|
78
|
+
FLAVOR_PEPPERY = 12;
|
|
79
|
+
FLAVOR_MENTHOL = 13;
|
|
80
|
+
FLAVOR_CHEESE = 14;
|
|
81
|
+
FLAVOR_SKUNK = 15;
|
|
82
|
+
FLAVOR_DIESEL = 16;
|
|
83
|
+
FLAVOR_GASSY = 17;
|
|
84
|
+
FLAVOR_CHEMICAL = 18;
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
message Manufacturer {
|
|
88
|
+
string id = 1;
|
|
89
|
+
string name = 2;
|
|
90
|
+
string slug = 3;
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
message Strain {
|
|
94
|
+
string id = 1;
|
|
95
|
+
string name = 2;
|
|
96
|
+
string slug = 3;
|
|
7
97
|
}
|
|
8
98
|
|
|
9
99
|
message Terpene {
|
|
@@ -12,8 +102,211 @@ message Terpene {
|
|
|
12
102
|
string slug = 3;
|
|
13
103
|
}
|
|
14
104
|
|
|
105
|
+
message Product {
|
|
106
|
+
string id = 1;
|
|
107
|
+
int32 number = 2;
|
|
108
|
+
string name = 3;
|
|
109
|
+
ProductType type = 4;
|
|
110
|
+
ProductStatus status = 5;
|
|
111
|
+
Manufacturer manufacturer = 6;
|
|
112
|
+
optional Strain strain = 7;
|
|
113
|
+
optional Genetics genetics = 8;
|
|
114
|
+
double thc = 9;
|
|
115
|
+
double cbd = 10;
|
|
116
|
+
PotencyUnit potency_unit = 11;
|
|
117
|
+
optional string country = 12;
|
|
118
|
+
bool is_irradiated = 13;
|
|
119
|
+
repeated Flavor flavors = 14;
|
|
120
|
+
repeated Terpene terpenes = 15;
|
|
121
|
+
optional string description = 16;
|
|
122
|
+
optional int32 price = 17;
|
|
123
|
+
Availability availability = 18;
|
|
124
|
+
optional string published_at = 19;
|
|
125
|
+
string created_at = 20;
|
|
126
|
+
string updated_at = 21;
|
|
127
|
+
optional string cover_key = 22;
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
message ProductInput {
|
|
131
|
+
string name = 1;
|
|
132
|
+
ProductType type = 2;
|
|
133
|
+
string manufacturer_id = 3;
|
|
134
|
+
optional string strain_id = 4;
|
|
135
|
+
optional Genetics genetics = 5;
|
|
136
|
+
double thc = 6;
|
|
137
|
+
double cbd = 7;
|
|
138
|
+
PotencyUnit potency_unit = 8;
|
|
139
|
+
optional string country = 9;
|
|
140
|
+
bool is_irradiated = 10;
|
|
141
|
+
repeated Flavor flavors = 11;
|
|
142
|
+
repeated string terpene_ids = 12;
|
|
143
|
+
optional string description = 13;
|
|
144
|
+
optional int32 price = 14;
|
|
145
|
+
Availability availability = 15;
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
message ListProductsRequest {
|
|
149
|
+
optional string query = 1;
|
|
150
|
+
optional ProductType type = 2;
|
|
151
|
+
optional ProductStatus status = 3;
|
|
152
|
+
optional string cursor = 4;
|
|
153
|
+
int32 limit = 5;
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
message ListProductsResponse {
|
|
157
|
+
repeated Product products = 1;
|
|
158
|
+
optional string next_cursor = 2;
|
|
159
|
+
int32 total = 3;
|
|
160
|
+
}
|
|
161
|
+
|
|
162
|
+
message GetProductRequest {
|
|
163
|
+
string id = 1;
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
message GetProductResponse {
|
|
167
|
+
Product product = 1;
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
message CreateProductRequest {
|
|
171
|
+
ProductInput product = 1;
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
message CreateProductResponse {
|
|
175
|
+
Product product = 1;
|
|
176
|
+
}
|
|
177
|
+
|
|
178
|
+
message UpdateProductRequest {
|
|
179
|
+
string id = 1;
|
|
180
|
+
ProductInput product = 2;
|
|
181
|
+
}
|
|
182
|
+
|
|
183
|
+
message UpdateProductResponse {
|
|
184
|
+
Product product = 1;
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
message PublishProductRequest {
|
|
188
|
+
string id = 1;
|
|
189
|
+
}
|
|
190
|
+
|
|
191
|
+
message PublishProductResponse {
|
|
192
|
+
Product product = 1;
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
message UnpublishProductRequest {
|
|
196
|
+
string id = 1;
|
|
197
|
+
}
|
|
198
|
+
|
|
199
|
+
message UnpublishProductResponse {
|
|
200
|
+
Product product = 1;
|
|
201
|
+
}
|
|
202
|
+
|
|
203
|
+
message DeleteProductRequest {
|
|
204
|
+
string id = 1;
|
|
205
|
+
}
|
|
206
|
+
|
|
207
|
+
message DeleteProductResponse {
|
|
208
|
+
Product product = 1;
|
|
209
|
+
}
|
|
210
|
+
|
|
211
|
+
message SetProductCoverRequest {
|
|
212
|
+
string id = 1;
|
|
213
|
+
optional string cover_key = 2;
|
|
214
|
+
}
|
|
215
|
+
|
|
216
|
+
message SetProductCoverResponse {
|
|
217
|
+
Product product = 1;
|
|
218
|
+
optional string previous_cover_key = 2;
|
|
219
|
+
}
|
|
220
|
+
|
|
221
|
+
message ListManufacturersRequest {}
|
|
222
|
+
|
|
223
|
+
message ListManufacturersResponse {
|
|
224
|
+
repeated Manufacturer manufacturers = 1;
|
|
225
|
+
}
|
|
226
|
+
|
|
227
|
+
message CreateManufacturerRequest {
|
|
228
|
+
string name = 1;
|
|
229
|
+
}
|
|
230
|
+
|
|
231
|
+
message CreateManufacturerResponse {
|
|
232
|
+
Manufacturer manufacturer = 1;
|
|
233
|
+
}
|
|
234
|
+
|
|
235
|
+
message UpdateManufacturerRequest {
|
|
236
|
+
string id = 1;
|
|
237
|
+
string name = 2;
|
|
238
|
+
}
|
|
239
|
+
|
|
240
|
+
message UpdateManufacturerResponse {
|
|
241
|
+
Manufacturer manufacturer = 1;
|
|
242
|
+
}
|
|
243
|
+
|
|
244
|
+
message DeleteManufacturerRequest {
|
|
245
|
+
string id = 1;
|
|
246
|
+
}
|
|
247
|
+
|
|
248
|
+
message DeleteManufacturerResponse {
|
|
249
|
+
Manufacturer manufacturer = 1;
|
|
250
|
+
}
|
|
251
|
+
|
|
252
|
+
message ListStrainsRequest {}
|
|
253
|
+
|
|
254
|
+
message ListStrainsResponse {
|
|
255
|
+
repeated Strain strains = 1;
|
|
256
|
+
}
|
|
257
|
+
|
|
258
|
+
message CreateStrainRequest {
|
|
259
|
+
string name = 1;
|
|
260
|
+
}
|
|
261
|
+
|
|
262
|
+
message CreateStrainResponse {
|
|
263
|
+
Strain strain = 1;
|
|
264
|
+
}
|
|
265
|
+
|
|
266
|
+
message UpdateStrainRequest {
|
|
267
|
+
string id = 1;
|
|
268
|
+
string name = 2;
|
|
269
|
+
}
|
|
270
|
+
|
|
271
|
+
message UpdateStrainResponse {
|
|
272
|
+
Strain strain = 1;
|
|
273
|
+
}
|
|
274
|
+
|
|
275
|
+
message DeleteStrainRequest {
|
|
276
|
+
string id = 1;
|
|
277
|
+
}
|
|
278
|
+
|
|
279
|
+
message DeleteStrainResponse {
|
|
280
|
+
Strain strain = 1;
|
|
281
|
+
}
|
|
282
|
+
|
|
15
283
|
message ListTerpenesRequest {}
|
|
16
284
|
|
|
17
285
|
message ListTerpenesResponse {
|
|
18
286
|
repeated Terpene terpenes = 1;
|
|
19
287
|
}
|
|
288
|
+
|
|
289
|
+
message CreateTerpeneRequest {
|
|
290
|
+
string name = 1;
|
|
291
|
+
}
|
|
292
|
+
|
|
293
|
+
message CreateTerpeneResponse {
|
|
294
|
+
Terpene terpene = 1;
|
|
295
|
+
}
|
|
296
|
+
|
|
297
|
+
message UpdateTerpeneRequest {
|
|
298
|
+
string id = 1;
|
|
299
|
+
string name = 2;
|
|
300
|
+
}
|
|
301
|
+
|
|
302
|
+
message UpdateTerpeneResponse {
|
|
303
|
+
Terpene terpene = 1;
|
|
304
|
+
}
|
|
305
|
+
|
|
306
|
+
message DeleteTerpeneRequest {
|
|
307
|
+
string id = 1;
|
|
308
|
+
}
|
|
309
|
+
|
|
310
|
+
message DeleteTerpeneResponse {
|
|
311
|
+
Terpene terpene = 1;
|
|
312
|
+
}
|
package/proto/media.proto
CHANGED
package/proto/treatment.proto
CHANGED
|
@@ -178,6 +178,7 @@ message ListTreatmentRequestsResponse {
|
|
|
178
178
|
repeated TreatmentRequest requests = 1;
|
|
179
179
|
reserved 2, 3, 4;
|
|
180
180
|
optional string next_cursor = 5;
|
|
181
|
+
int32 total = 6;
|
|
181
182
|
}
|
|
182
183
|
|
|
183
184
|
message ListAllTreatmentRequestsRequest {
|
|
@@ -191,6 +192,7 @@ message ListAllTreatmentRequestsRequest {
|
|
|
191
192
|
message ListAllTreatmentRequestsResponse {
|
|
192
193
|
repeated TreatmentRequest requests = 1;
|
|
193
194
|
optional string next_cursor = 2;
|
|
195
|
+
int32 total = 3;
|
|
194
196
|
}
|
|
195
197
|
|
|
196
198
|
message UpdateTreatmentRequestRequest {
|