@longvansoftware/service-js-client 2.3.4 → 2.3.5
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/src/graphql/computing/mutations.js +14 -28
- package/dist/src/graphql/computing/queries.js +6 -6
- package/dist/src/graphql/product/queries.d.ts +0 -1
- package/dist/src/graphql/product/queries.js +1 -19
- package/dist/src/graphql/storage_s3/mutations.js +44 -90
- package/dist/src/graphql/storage_s3/queries.js +18 -18
- package/dist/src/lib/computing/index.d.ts +14 -14
- package/dist/src/lib/computing/index.js +14 -31
- package/dist/src/lib/product/index.d.ts +0 -1
- package/dist/src/lib/product/index.js +0 -18
- package/dist/src/lib/storage_s3/index.d.ts +34 -34
- package/dist/src/lib/storage_s3/index.js +45 -78
- package/dist/src/types/computing.d.ts +0 -2
- package/package.json +1 -1
|
@@ -30,8 +30,8 @@ const GET_LIST_BUCKET_BY_S3_USER_ID = (fields = []) => {
|
|
|
30
30
|
const fieldStr = fields.join('\n ');
|
|
31
31
|
const hasFields = fields.length > 0;
|
|
32
32
|
return (0, graphql_tag_1.gql) `
|
|
33
|
-
query GetListBucketByS3UserId($s3UserId: String
|
|
34
|
-
getListBucketByS3UserId(s3UserId: $s3UserId
|
|
33
|
+
query GetListBucketByS3UserId($s3UserId: String!) {
|
|
34
|
+
getListBucketByS3UserId(s3UserId: $s3UserId) {
|
|
35
35
|
${hasFields ? `${fieldStr}` : ''}
|
|
36
36
|
}
|
|
37
37
|
}
|
|
@@ -42,8 +42,8 @@ const GET_LIST_OBJECT = (fields = []) => {
|
|
|
42
42
|
const fieldStr = fields.join('\n ');
|
|
43
43
|
const hasFields = fields.length > 0;
|
|
44
44
|
return (0, graphql_tag_1.gql) `
|
|
45
|
-
query GetListObject($s3UserId: String!, $bucketId: String!, $key: String
|
|
46
|
-
getListObject(s3UserId: $s3UserId, bucketId: $bucketId, key: $key
|
|
45
|
+
query GetListObject($s3UserId: String!, $bucketId: String!, $key: String!) {
|
|
46
|
+
getListObject(s3UserId: $s3UserId, bucketId: $bucketId, key: $key) {
|
|
47
47
|
${hasFields ? `${fieldStr}` : ''}
|
|
48
48
|
}
|
|
49
49
|
}
|
|
@@ -54,8 +54,8 @@ const GET_LIST_FILE_TRASH = (fields = []) => {
|
|
|
54
54
|
const fieldStr = fields.join('\n ');
|
|
55
55
|
const hasFields = fields.length > 0;
|
|
56
56
|
return (0, graphql_tag_1.gql) `
|
|
57
|
-
query GetListFileTrash($s3UserId: String!, $bucketId: String
|
|
58
|
-
getListFileTrash(s3UserId: $s3UserId, bucketId: $bucketId
|
|
57
|
+
query GetListFileTrash($s3UserId: String!, $bucketId: String!) {
|
|
58
|
+
getListFileTrash(s3UserId: $s3UserId, bucketId: $bucketId) {
|
|
59
59
|
${hasFields ? `${fieldStr}` : ''}
|
|
60
60
|
}
|
|
61
61
|
}
|
|
@@ -66,8 +66,8 @@ const GET_LIST_S3_DOMAIN_BY_S3_USER_ID = (fields = []) => {
|
|
|
66
66
|
const fieldStr = fields.join('\n ');
|
|
67
67
|
const hasFields = fields.length > 0;
|
|
68
68
|
return (0, graphql_tag_1.gql) `
|
|
69
|
-
query GetListS3DomainByS3UserId($s3UserId: String
|
|
70
|
-
getListS3DomainByS3UserId(s3UserId: $s3UserId
|
|
69
|
+
query GetListS3DomainByS3UserId($s3UserId: String!) {
|
|
70
|
+
getListS3DomainByS3UserId(s3UserId: $s3UserId) {
|
|
71
71
|
${hasFields ? `${fieldStr}` : ''}
|
|
72
72
|
}
|
|
73
73
|
}
|
|
@@ -78,8 +78,8 @@ const GET_LIST_CORS_BY_S3_USER_ID = (fields = []) => {
|
|
|
78
78
|
const fieldStr = fields.join('\n ');
|
|
79
79
|
const hasFields = fields.length > 0;
|
|
80
80
|
return (0, graphql_tag_1.gql) `
|
|
81
|
-
query GetListCorsByS3UserId($s3UserId: String!, $bucketId: String
|
|
82
|
-
getListCorsByS3UserId(s3UserId: $s3UserId, bucketId: $bucketId
|
|
81
|
+
query GetListCorsByS3UserId($s3UserId: String!, $bucketId: String!) {
|
|
82
|
+
getListCorsByS3UserId(s3UserId: $s3UserId, bucketId: $bucketId) {
|
|
83
83
|
${hasFields ? `${fieldStr}` : ''}
|
|
84
84
|
}
|
|
85
85
|
}
|
|
@@ -90,8 +90,8 @@ const GET_LIST_FILE_OTHER_VERSION = (fields = []) => {
|
|
|
90
90
|
const fieldStr = fields.join('\n ');
|
|
91
91
|
const hasFields = fields.length > 0;
|
|
92
92
|
return (0, graphql_tag_1.gql) `
|
|
93
|
-
query GetListFileOtherVersion($s3UserId: String!, $bucketId: String!, $key: String
|
|
94
|
-
getListFileOtherVersion(s3UserId: $s3UserId, bucketId: $bucketId, key: $key
|
|
93
|
+
query GetListFileOtherVersion($s3UserId: String!, $bucketId: String!, $key: String) {
|
|
94
|
+
getListFileOtherVersion(s3UserId: $s3UserId, bucketId: $bucketId, key: $key) {
|
|
95
95
|
${hasFields ? `${fieldStr}` : ''}
|
|
96
96
|
}
|
|
97
97
|
}
|
|
@@ -102,8 +102,8 @@ const CHART_IN_YEAR = (fields = []) => {
|
|
|
102
102
|
const fieldStr = fields.join('\n ');
|
|
103
103
|
const hasFields = fields.length > 0;
|
|
104
104
|
return (0, graphql_tag_1.gql) `
|
|
105
|
-
query ChartInYear($s3UserId: String!, $year: Int!, $month: Int
|
|
106
|
-
chartInYear(s3UserId: $s3UserId, year: $year, month: $month
|
|
105
|
+
query ChartInYear($s3UserId: String!, $year: Int!, $month: Int!) {
|
|
106
|
+
chartInYear(s3UserId: $s3UserId, year: $year, month: $month) {
|
|
107
107
|
${hasFields ? `${fieldStr}` : ''}
|
|
108
108
|
}
|
|
109
109
|
}
|
|
@@ -111,16 +111,16 @@ const CHART_IN_YEAR = (fields = []) => {
|
|
|
111
111
|
};
|
|
112
112
|
exports.CHART_IN_YEAR = CHART_IN_YEAR;
|
|
113
113
|
exports.GET_IP_CONSUL = (0, graphql_tag_1.gql) `
|
|
114
|
-
query GetIPConsul($userId: String
|
|
115
|
-
getIPConsul(userId: $userId
|
|
114
|
+
query GetIPConsul($userId: String!) {
|
|
115
|
+
getIPConsul(userId: $userId)
|
|
116
116
|
}
|
|
117
117
|
`;
|
|
118
118
|
const FILTER_LIST_OBJECT = (fields = []) => {
|
|
119
119
|
const fieldStr = fields.join('\n ');
|
|
120
120
|
const hasFields = fields.length > 0;
|
|
121
121
|
return (0, graphql_tag_1.gql) `
|
|
122
|
-
query FilterListObject($s3UserId: String!, $bucketId: String!, $maxKeys: Int!, $key: String, $prefixSearch: String, $continuationToken: String
|
|
123
|
-
filterListObject(s3UserId: $s3UserId, bucketId: $bucketId, maxKeys: $maxKeys, key: $key, prefixSearch: $prefixSearch, continuationToken: $continuationToken
|
|
122
|
+
query FilterListObject($s3UserId: String!, $bucketId: String!, $maxKeys: Int!, $key: String, $prefixSearch: String, $continuationToken: String) {
|
|
123
|
+
filterListObject(s3UserId: $s3UserId, bucketId: $bucketId, maxKeys: $maxKeys, key: $key, prefixSearch: $prefixSearch, continuationToken: $continuationToken){
|
|
124
124
|
${hasFields ? `${fieldStr}` : ''}
|
|
125
125
|
}
|
|
126
126
|
}
|
|
@@ -10,16 +10,16 @@ export declare class ComputingService extends Service {
|
|
|
10
10
|
constructor(endpoint: string, orgId: string, storeId: string);
|
|
11
11
|
setToken(token: string): void;
|
|
12
12
|
setStoreId(storeId: string): void;
|
|
13
|
-
computingDetail(computingId: string
|
|
14
|
-
portNats(computingId: string
|
|
15
|
-
restartVM(computingId: string, actor: string
|
|
13
|
+
computingDetail(computingId: string): Promise<any>;
|
|
14
|
+
portNats(computingId: string): Promise<any>;
|
|
15
|
+
restartVM(computingId: string, actor: string): Promise<any>;
|
|
16
16
|
updateDescriptionPortNat(payload: UpdateDescriptionPortNat, updateBy: string): Promise<any>;
|
|
17
17
|
createPortNat(payload: CreatePortNat, createBy: string): Promise<any>;
|
|
18
18
|
updatePortNat(payload: CreatePortNat, updateBy: string): Promise<any>;
|
|
19
19
|
removePortNat(portNatId: string, updateBy: string): Promise<any>;
|
|
20
|
-
startVM(computingId: string, actor: string
|
|
21
|
-
stopVM(computingId: string, actor: string
|
|
22
|
-
snapshots(computingId: string
|
|
20
|
+
startVM(computingId: string, actor: string): Promise<any>;
|
|
21
|
+
stopVM(computingId: string, actor: string): Promise<any>;
|
|
22
|
+
snapshots(computingId: string): Promise<any>;
|
|
23
23
|
createSnapshot(payload: CreateSnapShot, createBy: string): Promise<any>;
|
|
24
24
|
rollbackSnapshot(payload: RollBackSnapShot, createBy: string): Promise<any>;
|
|
25
25
|
deleteSnapshot(payload: RollBackSnapShot, updateBy: string): Promise<any>;
|
|
@@ -41,25 +41,25 @@ export declare class ComputingService extends Service {
|
|
|
41
41
|
getCluster(clusterId: string): Promise<any>;
|
|
42
42
|
getComputingByCluster(clusterId: string): Promise<any>;
|
|
43
43
|
getComputingByService(serviceId: string): Promise<any>;
|
|
44
|
-
stopUseComputing(computingId: string, userId: string
|
|
44
|
+
stopUseComputing(computingId: string, userId: string): Promise<any>;
|
|
45
45
|
getEdges(serviceId: string): Promise<any>;
|
|
46
46
|
addPortNat(data: any): Promise<any>;
|
|
47
47
|
getPortNatsByServiceId(serviceId: any): Promise<any>;
|
|
48
|
-
updateDescriptionComputing(computingId: string, description: string, updateBy: string
|
|
48
|
+
updateDescriptionComputing(computingId: string, description: string, updateBy: string): Promise<any>;
|
|
49
49
|
getTemplates(): Promise<any>;
|
|
50
50
|
getAvailableSubnetIPsByResourcePoolId(resourcePoolId: string): Promise<any>;
|
|
51
51
|
getAvailableStoragesForDC(resourcePoolId: string): Promise<any>;
|
|
52
52
|
getResourcePoolsByService(serviceId: string): Promise<any>;
|
|
53
53
|
createComputingForDC(data: any, createBy: string): Promise<any>;
|
|
54
|
-
updateNameComputing(computingId: string, name: string, updateBy: string
|
|
54
|
+
updateNameComputing(computingId: string, name: string, updateBy: string): Promise<any>;
|
|
55
55
|
getConsole(computingId: string): Promise<any>;
|
|
56
56
|
getComputingWaitRevoke(serviceId: string, fields: string[]): Promise<any>;
|
|
57
|
-
computingWaitingRevoke(computingId: string, userId: string,
|
|
58
|
-
restoreComputingWaitingRevoke(computingId: string, userId: string,
|
|
59
|
-
deleteComputing(computingId: string, userId: string,
|
|
57
|
+
computingWaitingRevoke(computingId: string, userId: string, fields: string[]): Promise<any>;
|
|
58
|
+
restoreComputingWaitingRevoke(computingId: string, userId: string, fields: string[]): Promise<any>;
|
|
59
|
+
deleteComputing(computingId: string, userId: string, fields: string[]): Promise<any>;
|
|
60
60
|
getStorageMappingForDC(resourcePoolId: string): Promise<any>;
|
|
61
|
-
updateCPU(computingId: string, socket: number, corePerSocket: number, updateBy: string
|
|
62
|
-
updateRAM(computingId: string, size: number, unit: string, updateBy: string
|
|
61
|
+
updateCPU(computingId: string, socket: number, corePerSocket: number, updateBy: string): Promise<any>;
|
|
62
|
+
updateRAM(computingId: string, size: number, unit: string, updateBy: string): Promise<any>;
|
|
63
63
|
getComputingsDynamic(userId: string, fields: string[]): Promise<any>;
|
|
64
64
|
createComputingForEC(createComputingInputForEC: any, createBy: string): Promise<any>;
|
|
65
65
|
}
|
|
@@ -29,12 +29,11 @@ class ComputingService extends serviceSDK_1.Service {
|
|
|
29
29
|
setStoreId(storeId) {
|
|
30
30
|
this.storeId = storeId;
|
|
31
31
|
}
|
|
32
|
-
computingDetail(computingId
|
|
32
|
+
computingDetail(computingId) {
|
|
33
33
|
return __awaiter(this, void 0, void 0, function* () {
|
|
34
34
|
const query = queries_1.COMPUTING_DETAIL;
|
|
35
35
|
const variables = {
|
|
36
36
|
computingId,
|
|
37
|
-
serviceId
|
|
38
37
|
};
|
|
39
38
|
try {
|
|
40
39
|
const response = yield this.graphqlQueryV2(query, variables);
|
|
@@ -46,12 +45,11 @@ class ComputingService extends serviceSDK_1.Service {
|
|
|
46
45
|
}
|
|
47
46
|
});
|
|
48
47
|
}
|
|
49
|
-
portNats(computingId
|
|
48
|
+
portNats(computingId) {
|
|
50
49
|
return __awaiter(this, void 0, void 0, function* () {
|
|
51
50
|
const query = queries_1.PORTNATS;
|
|
52
51
|
const variables = {
|
|
53
52
|
computingId,
|
|
54
|
-
serviceId
|
|
55
53
|
};
|
|
56
54
|
try {
|
|
57
55
|
const response = yield this.graphqlQueryV2(query, variables);
|
|
@@ -63,13 +61,12 @@ class ComputingService extends serviceSDK_1.Service {
|
|
|
63
61
|
}
|
|
64
62
|
});
|
|
65
63
|
}
|
|
66
|
-
restartVM(computingId, actor
|
|
64
|
+
restartVM(computingId, actor) {
|
|
67
65
|
return __awaiter(this, void 0, void 0, function* () {
|
|
68
66
|
const mutation = mutations_1.RESTARTVM;
|
|
69
67
|
const variables = {
|
|
70
68
|
computingId,
|
|
71
69
|
actor,
|
|
72
|
-
serviceId
|
|
73
70
|
};
|
|
74
71
|
try {
|
|
75
72
|
const response = yield this.graphqlMutationV2(mutation, variables);
|
|
@@ -152,13 +149,12 @@ class ComputingService extends serviceSDK_1.Service {
|
|
|
152
149
|
}
|
|
153
150
|
});
|
|
154
151
|
}
|
|
155
|
-
startVM(computingId, actor
|
|
152
|
+
startVM(computingId, actor) {
|
|
156
153
|
return __awaiter(this, void 0, void 0, function* () {
|
|
157
154
|
const mutation = mutations_1.POWER_ON;
|
|
158
155
|
const variables = {
|
|
159
156
|
computingId,
|
|
160
157
|
actor,
|
|
161
|
-
serviceId
|
|
162
158
|
};
|
|
163
159
|
try {
|
|
164
160
|
const response = yield this.graphqlMutationV2(mutation, variables);
|
|
@@ -170,13 +166,12 @@ class ComputingService extends serviceSDK_1.Service {
|
|
|
170
166
|
}
|
|
171
167
|
});
|
|
172
168
|
}
|
|
173
|
-
stopVM(computingId, actor
|
|
169
|
+
stopVM(computingId, actor) {
|
|
174
170
|
return __awaiter(this, void 0, void 0, function* () {
|
|
175
171
|
const mutation = mutations_1.POWER_OFF;
|
|
176
172
|
const variables = {
|
|
177
173
|
computingId,
|
|
178
174
|
actor,
|
|
179
|
-
serviceId
|
|
180
175
|
};
|
|
181
176
|
try {
|
|
182
177
|
const response = yield this.graphqlMutationV2(mutation, variables);
|
|
@@ -188,12 +183,11 @@ class ComputingService extends serviceSDK_1.Service {
|
|
|
188
183
|
}
|
|
189
184
|
});
|
|
190
185
|
}
|
|
191
|
-
snapshots(computingId
|
|
186
|
+
snapshots(computingId) {
|
|
192
187
|
return __awaiter(this, void 0, void 0, function* () {
|
|
193
188
|
const query = queries_1.SNAP_SHOTS;
|
|
194
189
|
const variables = {
|
|
195
190
|
computingId,
|
|
196
|
-
serviceId
|
|
197
191
|
};
|
|
198
192
|
try {
|
|
199
193
|
const response = yield this.graphqlQueryV2(query, variables);
|
|
@@ -211,7 +205,6 @@ class ComputingService extends serviceSDK_1.Service {
|
|
|
211
205
|
const variables = {
|
|
212
206
|
computingId: payload.computingId,
|
|
213
207
|
snapshotName: payload.snapshotName,
|
|
214
|
-
serviceId: payload.serviceId,
|
|
215
208
|
createBy,
|
|
216
209
|
};
|
|
217
210
|
try {
|
|
@@ -230,7 +223,6 @@ class ComputingService extends serviceSDK_1.Service {
|
|
|
230
223
|
const variables = {
|
|
231
224
|
computingId: payload.computingId,
|
|
232
225
|
snapshotId: payload.snapshotId,
|
|
233
|
-
serviceId: payload.serviceId,
|
|
234
226
|
createBy,
|
|
235
227
|
};
|
|
236
228
|
try {
|
|
@@ -249,7 +241,6 @@ class ComputingService extends serviceSDK_1.Service {
|
|
|
249
241
|
const variables = {
|
|
250
242
|
computingId: payload.computingId,
|
|
251
243
|
snapshotId: payload.snapshotId,
|
|
252
|
-
serviceId: payload.serviceId,
|
|
253
244
|
updateBy,
|
|
254
245
|
};
|
|
255
246
|
try {
|
|
@@ -575,13 +566,12 @@ class ComputingService extends serviceSDK_1.Service {
|
|
|
575
566
|
}
|
|
576
567
|
});
|
|
577
568
|
}
|
|
578
|
-
stopUseComputing(computingId, userId
|
|
569
|
+
stopUseComputing(computingId, userId) {
|
|
579
570
|
return __awaiter(this, void 0, void 0, function* () {
|
|
580
571
|
const mutation = mutations_1.STOP_USE_COMPUTING;
|
|
581
572
|
const variables = {
|
|
582
573
|
computingId,
|
|
583
574
|
userId,
|
|
584
|
-
serviceId,
|
|
585
575
|
};
|
|
586
576
|
try {
|
|
587
577
|
const response = yield this.graphqlMutationV2(mutation, variables);
|
|
@@ -639,14 +629,13 @@ class ComputingService extends serviceSDK_1.Service {
|
|
|
639
629
|
}
|
|
640
630
|
});
|
|
641
631
|
}
|
|
642
|
-
updateDescriptionComputing(computingId, description, updateBy
|
|
632
|
+
updateDescriptionComputing(computingId, description, updateBy) {
|
|
643
633
|
return __awaiter(this, void 0, void 0, function* () {
|
|
644
634
|
const query = mutations_1.UPDATE_DESCRIPTION_COMPUTING;
|
|
645
635
|
const variables = {
|
|
646
636
|
computingId,
|
|
647
637
|
description,
|
|
648
638
|
updateBy,
|
|
649
|
-
serviceId
|
|
650
639
|
};
|
|
651
640
|
try {
|
|
652
641
|
const response = yield this.graphqlMutationV2(query, variables);
|
|
@@ -746,14 +735,13 @@ class ComputingService extends serviceSDK_1.Service {
|
|
|
746
735
|
}
|
|
747
736
|
});
|
|
748
737
|
}
|
|
749
|
-
updateNameComputing(computingId, name, updateBy
|
|
738
|
+
updateNameComputing(computingId, name, updateBy) {
|
|
750
739
|
return __awaiter(this, void 0, void 0, function* () {
|
|
751
740
|
const mutation = mutations_1.UPDATE_NAME_COMPUTING;
|
|
752
741
|
const variables = {
|
|
753
742
|
computingId,
|
|
754
743
|
name,
|
|
755
744
|
updateBy,
|
|
756
|
-
serviceId
|
|
757
745
|
};
|
|
758
746
|
try {
|
|
759
747
|
const response = yield this.graphqlMutationV2(mutation, variables);
|
|
@@ -797,13 +785,12 @@ class ComputingService extends serviceSDK_1.Service {
|
|
|
797
785
|
}
|
|
798
786
|
});
|
|
799
787
|
}
|
|
800
|
-
computingWaitingRevoke(computingId, userId,
|
|
788
|
+
computingWaitingRevoke(computingId, userId, fields) {
|
|
801
789
|
return __awaiter(this, void 0, void 0, function* () {
|
|
802
790
|
const query = (0, mutations_1.COMPUTING_WAITING_REVOKE)(fields);
|
|
803
791
|
const variables = {
|
|
804
792
|
computingId,
|
|
805
793
|
userId,
|
|
806
|
-
serviceId
|
|
807
794
|
};
|
|
808
795
|
try {
|
|
809
796
|
const response = yield this.graphqlMutationV2(query, variables);
|
|
@@ -815,13 +802,12 @@ class ComputingService extends serviceSDK_1.Service {
|
|
|
815
802
|
}
|
|
816
803
|
});
|
|
817
804
|
}
|
|
818
|
-
restoreComputingWaitingRevoke(computingId, userId,
|
|
805
|
+
restoreComputingWaitingRevoke(computingId, userId, fields) {
|
|
819
806
|
return __awaiter(this, void 0, void 0, function* () {
|
|
820
807
|
const query = (0, mutations_1.RESTORE_COMPUTING_WAITING_REVOKE)(fields);
|
|
821
808
|
const variables = {
|
|
822
809
|
computingId,
|
|
823
810
|
userId,
|
|
824
|
-
serviceId
|
|
825
811
|
};
|
|
826
812
|
try {
|
|
827
813
|
const response = yield this.graphqlMutationV2(query, variables);
|
|
@@ -833,13 +819,12 @@ class ComputingService extends serviceSDK_1.Service {
|
|
|
833
819
|
}
|
|
834
820
|
});
|
|
835
821
|
}
|
|
836
|
-
deleteComputing(computingId, userId,
|
|
822
|
+
deleteComputing(computingId, userId, fields) {
|
|
837
823
|
return __awaiter(this, void 0, void 0, function* () {
|
|
838
824
|
const query = (0, mutations_1.DELETE_COMPUTING)(fields);
|
|
839
825
|
const variables = {
|
|
840
826
|
computingId,
|
|
841
827
|
userId,
|
|
842
|
-
serviceId
|
|
843
828
|
};
|
|
844
829
|
try {
|
|
845
830
|
const response = yield this.graphqlMutationV2(query, variables);
|
|
@@ -867,7 +852,7 @@ class ComputingService extends serviceSDK_1.Service {
|
|
|
867
852
|
}
|
|
868
853
|
});
|
|
869
854
|
}
|
|
870
|
-
updateCPU(computingId, socket, corePerSocket, updateBy
|
|
855
|
+
updateCPU(computingId, socket, corePerSocket, updateBy) {
|
|
871
856
|
return __awaiter(this, void 0, void 0, function* () {
|
|
872
857
|
const mutation = mutations_1.UPDATE_CPU;
|
|
873
858
|
const variables = {
|
|
@@ -875,7 +860,6 @@ class ComputingService extends serviceSDK_1.Service {
|
|
|
875
860
|
socket,
|
|
876
861
|
corePerSocket,
|
|
877
862
|
updateBy,
|
|
878
|
-
serviceId
|
|
879
863
|
};
|
|
880
864
|
try {
|
|
881
865
|
const response = yield this.graphqlMutationV2(mutation, variables);
|
|
@@ -887,7 +871,7 @@ class ComputingService extends serviceSDK_1.Service {
|
|
|
887
871
|
}
|
|
888
872
|
});
|
|
889
873
|
}
|
|
890
|
-
updateRAM(computingId, size, unit, updateBy
|
|
874
|
+
updateRAM(computingId, size, unit, updateBy) {
|
|
891
875
|
return __awaiter(this, void 0, void 0, function* () {
|
|
892
876
|
const mutation = mutations_1.UPDATE_RAM;
|
|
893
877
|
const variables = {
|
|
@@ -895,7 +879,6 @@ class ComputingService extends serviceSDK_1.Service {
|
|
|
895
879
|
size,
|
|
896
880
|
unit,
|
|
897
881
|
updateBy,
|
|
898
|
-
serviceId
|
|
899
882
|
};
|
|
900
883
|
try {
|
|
901
884
|
const response = yield this.graphqlMutationV2(mutation, variables);
|
|
@@ -56,5 +56,4 @@ export declare class ProductService extends Service {
|
|
|
56
56
|
getSimpleProductsDynamic(variables: any, storeId: string, fields: string[]): Promise<any>;
|
|
57
57
|
getProductRelatedToArticle(articleId: string, storeId: string, fields: string[]): Promise<any>;
|
|
58
58
|
getProductFeatureTypesDynamic(productId: string, storeId: string, fields: string[]): Promise<any>;
|
|
59
|
-
getProductSimpleByHandle(handle: string, store: string, fields: string[]): Promise<any>;
|
|
60
59
|
}
|
|
@@ -455,23 +455,5 @@ class ProductService extends serviceSDK_1.Service {
|
|
|
455
455
|
}
|
|
456
456
|
});
|
|
457
457
|
}
|
|
458
|
-
getProductSimpleByHandle(handle, store, fields) {
|
|
459
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
460
|
-
const query = (0, queries_1.GET_PRODUCT_SIMPLE_BY_HANDLE_DYNAMIC)(fields);
|
|
461
|
-
const variablesHandle = {
|
|
462
|
-
partnerId: this.orgId,
|
|
463
|
-
storeChannel: store ? store : this.storeId,
|
|
464
|
-
handle,
|
|
465
|
-
};
|
|
466
|
-
try {
|
|
467
|
-
const response = yield this.graphqlQueryV2(query, variablesHandle);
|
|
468
|
-
return response.getProductSimpleByHandle;
|
|
469
|
-
}
|
|
470
|
-
catch (error) {
|
|
471
|
-
console.log(`Error fetching getProductSimpleByHandle : ${error}`);
|
|
472
|
-
throw error;
|
|
473
|
-
}
|
|
474
|
-
});
|
|
475
|
-
}
|
|
476
458
|
}
|
|
477
459
|
exports.ProductService = ProductService;
|
|
@@ -4,39 +4,39 @@ export declare class StorageS3Service extends Service {
|
|
|
4
4
|
constructor(endpoint: string, orgId: string, storeId: string);
|
|
5
5
|
getListS3UserByServiceId(serviceId: string, fields: string[]): Promise<any>;
|
|
6
6
|
getListS3UserActiveByServiceId(serviceId: string, fields: string[]): Promise<any>;
|
|
7
|
-
getListBucketByS3UserId(s3UserId: string,
|
|
8
|
-
getListObject(s3UserId: string, bucketId: string, key: string,
|
|
9
|
-
uploadFolder(userId: string, bucketId: string, fileInfo: [FileInfoInput], basePrefix: string,
|
|
7
|
+
getListBucketByS3UserId(s3UserId: string, fields: string[]): Promise<any>;
|
|
8
|
+
getListObject(s3UserId: string, bucketId: string, key: string, fields: string[]): Promise<any>;
|
|
9
|
+
uploadFolder(userId: string, bucketId: string, fileInfo: [FileInfoInput], basePrefix: string, fields: string[]): Promise<any>;
|
|
10
10
|
uploadFile(s3UserId: string, bucketId: string, key: string, fields: string[]): Promise<any>;
|
|
11
|
-
updateAclPermissionFile(s3UserId: string, bucketId: string, key: string, isPublic: boolean,
|
|
12
|
-
renameFile(s3UserId: string, bucketId: string, key: string, fileNewName: boolean,
|
|
13
|
-
shareLinkFileByTime(s3UserId: string, bucketId: string, key: string, quantityHour: number
|
|
14
|
-
copyFile(s3UserId: string, bucketId: string, srcFileKey: string, dstFileKey: string,
|
|
15
|
-
moveFile(s3UserId: string, bucketId: string, srcFileKey: string, dstFileKey: string,
|
|
16
|
-
removeFile(s3UserId: string, bucketId: string, keys: string[],
|
|
17
|
-
createFolder(s3UserId: string, bucketId: string, folderName: string, key: string,
|
|
18
|
-
removeFolder(s3UserId: string, bucketId: string, key: string,
|
|
19
|
-
createBucket(s3UserId: string, bucketName: string, internalId: string, randomInternalId: boolean, enableObjectLock: boolean, enableBucketVersioning: boolean, byUser: string,
|
|
20
|
-
renameBucket(bucketId: string, bucketName: string, updateBy: string,
|
|
21
|
-
deleteBucket(bucketId: string, updateBy: string,
|
|
22
|
-
updateAclPermissionBucket(s3UserId: string, bucketId: string, isPublic: boolean, updateBy: string,
|
|
23
|
-
updateBucketVersioning(s3UserId: string, bucketId: string, isOn: boolean, updateBy: string,
|
|
24
|
-
getListFileTrash(s3UserId: string, bucketId: string,
|
|
25
|
-
restoreFileTrash(s3UserId: string, bucketId: string, key: string, versionId: string,
|
|
26
|
-
removeFileTrash(s3UserId: string, bucketId: string, files: [FileTrashInput],
|
|
27
|
-
getListS3DomainByS3UserId(s3UserId: string,
|
|
28
|
-
addS3Domain(s3UserId: string, domain: string, byUser: string,
|
|
29
|
-
removeS3Domain(s3UserId: string, domainId: string, byUser: string,
|
|
30
|
-
getListCorsByS3UserId(s3UserId: string, bucketId: string,
|
|
31
|
-
addCorsBucket(s3UserId: string, bucketId: string, allowedMethods: string[], allowedOrigins: string[], allowedHeaders: string[], exposeHeaders: string[], maxAgeSeconds: number, updateBy: string,
|
|
32
|
-
updateCorsBucket(bucketId: string, corsId: string, allowedMethods: string[], allowedOrigins: string[], allowedHeaders: string[], exposeHeaders: string[], maxAgeSeconds: number, updateBy: string,
|
|
33
|
-
removeCorsBucket(bucketId: string, corsId: string, updateBy: string,
|
|
34
|
-
getListFileOtherVersion(s3UserId: string, bucketId: string, key: string,
|
|
35
|
-
restoreFileOtherVersion(s3UserId: string, bucketId: string, key: string, versionId: string,
|
|
36
|
-
removeFileOtherVersion(s3UserId: string, bucketId: string, key: string, versionId: string,
|
|
37
|
-
resetKey(s3UserId: string, updateBy: string,
|
|
38
|
-
actionSyncUserFromS3(s3UserId: string, updateBy: string,
|
|
39
|
-
chartInYear(s3UserId: string, year: number, month: number,
|
|
40
|
-
getIPConsul(userId: string
|
|
41
|
-
filterListObject(s3UserId: string, bucketId: string, maxKeys: number, key: string, prefixSearch: string, continuationToken: string,
|
|
11
|
+
updateAclPermissionFile(s3UserId: string, bucketId: string, key: string, isPublic: boolean, fields: string[]): Promise<any>;
|
|
12
|
+
renameFile(s3UserId: string, bucketId: string, key: string, fileNewName: boolean, fields: string[]): Promise<any>;
|
|
13
|
+
shareLinkFileByTime(s3UserId: string, bucketId: string, key: string, quantityHour: number): Promise<any>;
|
|
14
|
+
copyFile(s3UserId: string, bucketId: string, srcFileKey: string, dstFileKey: string, fields: string[]): Promise<any>;
|
|
15
|
+
moveFile(s3UserId: string, bucketId: string, srcFileKey: string, dstFileKey: string, fields: string[]): Promise<any>;
|
|
16
|
+
removeFile(s3UserId: string, bucketId: string, keys: string[], fields: string[]): Promise<any>;
|
|
17
|
+
createFolder(s3UserId: string, bucketId: string, folderName: string, key: string, fields: string[]): Promise<any>;
|
|
18
|
+
removeFolder(s3UserId: string, bucketId: string, key: string, fields: string[]): Promise<any>;
|
|
19
|
+
createBucket(s3UserId: string, bucketName: string, internalId: string, randomInternalId: boolean, enableObjectLock: boolean, enableBucketVersioning: boolean, byUser: string, fields: string[]): Promise<any>;
|
|
20
|
+
renameBucket(bucketId: string, bucketName: string, updateBy: string, fields: string[]): Promise<any>;
|
|
21
|
+
deleteBucket(bucketId: string, updateBy: string, fields: string[]): Promise<any>;
|
|
22
|
+
updateAclPermissionBucket(s3UserId: string, bucketId: string, isPublic: boolean, updateBy: string, fields: string[]): Promise<any>;
|
|
23
|
+
updateBucketVersioning(s3UserId: string, bucketId: string, isOn: boolean, updateBy: string, fields: string[]): Promise<any>;
|
|
24
|
+
getListFileTrash(s3UserId: string, bucketId: string, fields: string[]): Promise<any>;
|
|
25
|
+
restoreFileTrash(s3UserId: string, bucketId: string, key: string, versionId: string, fields: string[]): Promise<any>;
|
|
26
|
+
removeFileTrash(s3UserId: string, bucketId: string, files: [FileTrashInput], fields: string[]): Promise<any>;
|
|
27
|
+
getListS3DomainByS3UserId(s3UserId: string, fields: string[]): Promise<any>;
|
|
28
|
+
addS3Domain(s3UserId: string, domain: string, byUser: string, fields: string[]): Promise<any>;
|
|
29
|
+
removeS3Domain(s3UserId: string, domainId: string, byUser: string, fields: string[]): Promise<any>;
|
|
30
|
+
getListCorsByS3UserId(s3UserId: string, bucketId: string, fields: string[]): Promise<any>;
|
|
31
|
+
addCorsBucket(s3UserId: string, bucketId: string, allowedMethods: string[], allowedOrigins: string[], allowedHeaders: string[], exposeHeaders: string[], maxAgeSeconds: number, updateBy: string, fields: string[]): Promise<any>;
|
|
32
|
+
updateCorsBucket(s3UserId: string, bucketId: string, corsId: string, allowedMethods: string[], allowedOrigins: string[], allowedHeaders: string[], exposeHeaders: string[], maxAgeSeconds: number, updateBy: string, fields: string[]): Promise<any>;
|
|
33
|
+
removeCorsBucket(bucketId: string, corsId: string, updateBy: string, fields: string[]): Promise<any>;
|
|
34
|
+
getListFileOtherVersion(s3UserId: string, bucketId: string, key: string, fields: string[]): Promise<any>;
|
|
35
|
+
restoreFileOtherVersion(s3UserId: string, bucketId: string, key: string, versionId: string, fields: string[]): Promise<any>;
|
|
36
|
+
removeFileOtherVersion(s3UserId: string, bucketId: string, key: string, versionId: string, fields: string[]): Promise<any>;
|
|
37
|
+
resetKey(s3UserId: string, updateBy: string, fields: string[]): Promise<any>;
|
|
38
|
+
actionSyncUserFromS3(s3UserId: string, updateBy: string, fields: string[]): Promise<any>;
|
|
39
|
+
chartInYear(s3UserId: string, year: number, month: number, fields: string[]): Promise<any>;
|
|
40
|
+
getIPConsul(userId: string): Promise<any>;
|
|
41
|
+
filterListObject(s3UserId: string, bucketId: string, maxKeys: number, key: string, prefixSearch: string, continuationToken: string, fields: string[]): Promise<any>;
|
|
42
42
|
}
|