@stashfin/grpc 1.2.3 → 1.2.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/package.json +1 -1
- package/ts/stashcash/debitsc.d.ts +6 -6
- package/ts/stashcash/debitsc.js +34 -26
package/package.json
CHANGED
|
@@ -4,7 +4,7 @@ export interface request {
|
|
|
4
4
|
customer_id: number;
|
|
5
5
|
flag: number;
|
|
6
6
|
campaign_id: number;
|
|
7
|
-
amount
|
|
7
|
+
amount?: number | undefined;
|
|
8
8
|
sc_type?: string | undefined;
|
|
9
9
|
txn_id?: string | undefined;
|
|
10
10
|
}
|
|
@@ -13,12 +13,12 @@ export interface response {
|
|
|
13
13
|
data?: response_Data | undefined;
|
|
14
14
|
}
|
|
15
15
|
export interface response_Data {
|
|
16
|
-
locked
|
|
17
|
-
unlocked
|
|
18
|
-
balance
|
|
19
|
-
rupee_balance
|
|
16
|
+
locked?: number | undefined;
|
|
17
|
+
unlocked?: number | undefined;
|
|
18
|
+
balance?: number | undefined;
|
|
19
|
+
rupee_balance?: number | undefined;
|
|
20
20
|
txn_id: number;
|
|
21
|
-
conversion_factor
|
|
21
|
+
conversion_factor?: number | undefined;
|
|
22
22
|
txn_status: string;
|
|
23
23
|
}
|
|
24
24
|
export declare const request: {
|
package/ts/stashcash/debitsc.js
CHANGED
|
@@ -14,7 +14,7 @@ const long_1 = __importDefault(require("long"));
|
|
|
14
14
|
const minimal_1 = __importDefault(require("protobufjs/minimal"));
|
|
15
15
|
exports.protobufPackage = "stashcash.debitsc";
|
|
16
16
|
function createBaserequest() {
|
|
17
|
-
return { customer_id: 0, flag: 0, campaign_id: 0, amount:
|
|
17
|
+
return { customer_id: 0, flag: 0, campaign_id: 0, amount: undefined, sc_type: undefined, txn_id: undefined };
|
|
18
18
|
}
|
|
19
19
|
exports.request = {
|
|
20
20
|
encode(message, writer = minimal_1.default.Writer.create()) {
|
|
@@ -27,7 +27,7 @@ exports.request = {
|
|
|
27
27
|
if (message.campaign_id !== 0) {
|
|
28
28
|
writer.uint32(24).int64(message.campaign_id);
|
|
29
29
|
}
|
|
30
|
-
if (message.amount !==
|
|
30
|
+
if (message.amount !== undefined) {
|
|
31
31
|
writer.uint32(37).float(message.amount);
|
|
32
32
|
}
|
|
33
33
|
if (message.sc_type !== undefined) {
|
|
@@ -94,7 +94,7 @@ exports.request = {
|
|
|
94
94
|
customer_id: isSet(object.customer_id) ? globalThis.Number(object.customer_id) : 0,
|
|
95
95
|
flag: isSet(object.flag) ? globalThis.Number(object.flag) : 0,
|
|
96
96
|
campaign_id: isSet(object.campaign_id) ? globalThis.Number(object.campaign_id) : 0,
|
|
97
|
-
amount: isSet(object.amount) ? globalThis.Number(object.amount) :
|
|
97
|
+
amount: isSet(object.amount) ? globalThis.Number(object.amount) : undefined,
|
|
98
98
|
sc_type: isSet(object.sc_type) ? globalThis.String(object.sc_type) : undefined,
|
|
99
99
|
txn_id: isSet(object.txn_id) ? globalThis.String(object.txn_id) : undefined,
|
|
100
100
|
};
|
|
@@ -110,7 +110,7 @@ exports.request = {
|
|
|
110
110
|
if (message.campaign_id !== 0) {
|
|
111
111
|
obj.campaign_id = Math.round(message.campaign_id);
|
|
112
112
|
}
|
|
113
|
-
if (message.amount !==
|
|
113
|
+
if (message.amount !== undefined) {
|
|
114
114
|
obj.amount = message.amount;
|
|
115
115
|
}
|
|
116
116
|
if (message.sc_type !== undefined) {
|
|
@@ -129,7 +129,7 @@ exports.request = {
|
|
|
129
129
|
message.customer_id = object.customer_id ?? 0;
|
|
130
130
|
message.flag = object.flag ?? 0;
|
|
131
131
|
message.campaign_id = object.campaign_id ?? 0;
|
|
132
|
-
message.amount = object.amount ??
|
|
132
|
+
message.amount = object.amount ?? undefined;
|
|
133
133
|
message.sc_type = object.sc_type ?? undefined;
|
|
134
134
|
message.txn_id = object.txn_id ?? undefined;
|
|
135
135
|
return message;
|
|
@@ -204,26 +204,34 @@ exports.response = {
|
|
|
204
204
|
},
|
|
205
205
|
};
|
|
206
206
|
function createBaseresponse_Data() {
|
|
207
|
-
return {
|
|
207
|
+
return {
|
|
208
|
+
locked: undefined,
|
|
209
|
+
unlocked: undefined,
|
|
210
|
+
balance: undefined,
|
|
211
|
+
rupee_balance: undefined,
|
|
212
|
+
txn_id: 0,
|
|
213
|
+
conversion_factor: undefined,
|
|
214
|
+
txn_status: "",
|
|
215
|
+
};
|
|
208
216
|
}
|
|
209
217
|
exports.response_Data = {
|
|
210
218
|
encode(message, writer = minimal_1.default.Writer.create()) {
|
|
211
|
-
if (message.locked !==
|
|
219
|
+
if (message.locked !== undefined) {
|
|
212
220
|
writer.uint32(13).float(message.locked);
|
|
213
221
|
}
|
|
214
|
-
if (message.unlocked !==
|
|
222
|
+
if (message.unlocked !== undefined) {
|
|
215
223
|
writer.uint32(21).float(message.unlocked);
|
|
216
224
|
}
|
|
217
|
-
if (message.balance !==
|
|
225
|
+
if (message.balance !== undefined) {
|
|
218
226
|
writer.uint32(29).float(message.balance);
|
|
219
227
|
}
|
|
220
|
-
if (message.rupee_balance !==
|
|
228
|
+
if (message.rupee_balance !== undefined) {
|
|
221
229
|
writer.uint32(37).float(message.rupee_balance);
|
|
222
230
|
}
|
|
223
231
|
if (message.txn_id !== 0) {
|
|
224
232
|
writer.uint32(40).int64(message.txn_id);
|
|
225
233
|
}
|
|
226
|
-
if (message.conversion_factor !==
|
|
234
|
+
if (message.conversion_factor !== undefined) {
|
|
227
235
|
writer.uint32(48).int32(message.conversion_factor);
|
|
228
236
|
}
|
|
229
237
|
if (message.txn_status !== "") {
|
|
@@ -290,33 +298,33 @@ exports.response_Data = {
|
|
|
290
298
|
},
|
|
291
299
|
fromJSON(object) {
|
|
292
300
|
return {
|
|
293
|
-
locked: isSet(object.locked) ? globalThis.Number(object.locked) :
|
|
294
|
-
unlocked: isSet(object.unlocked) ? globalThis.Number(object.unlocked) :
|
|
295
|
-
balance: isSet(object.balance) ? globalThis.Number(object.balance) :
|
|
296
|
-
rupee_balance: isSet(object.rupee_balance) ? globalThis.Number(object.rupee_balance) :
|
|
301
|
+
locked: isSet(object.locked) ? globalThis.Number(object.locked) : undefined,
|
|
302
|
+
unlocked: isSet(object.unlocked) ? globalThis.Number(object.unlocked) : undefined,
|
|
303
|
+
balance: isSet(object.balance) ? globalThis.Number(object.balance) : undefined,
|
|
304
|
+
rupee_balance: isSet(object.rupee_balance) ? globalThis.Number(object.rupee_balance) : undefined,
|
|
297
305
|
txn_id: isSet(object.txn_id) ? globalThis.Number(object.txn_id) : 0,
|
|
298
|
-
conversion_factor: isSet(object.conversion_factor) ? globalThis.Number(object.conversion_factor) :
|
|
306
|
+
conversion_factor: isSet(object.conversion_factor) ? globalThis.Number(object.conversion_factor) : undefined,
|
|
299
307
|
txn_status: isSet(object.txn_status) ? globalThis.String(object.txn_status) : "",
|
|
300
308
|
};
|
|
301
309
|
},
|
|
302
310
|
toJSON(message) {
|
|
303
311
|
const obj = {};
|
|
304
|
-
if (message.locked !==
|
|
312
|
+
if (message.locked !== undefined) {
|
|
305
313
|
obj.locked = message.locked;
|
|
306
314
|
}
|
|
307
|
-
if (message.unlocked !==
|
|
315
|
+
if (message.unlocked !== undefined) {
|
|
308
316
|
obj.unlocked = message.unlocked;
|
|
309
317
|
}
|
|
310
|
-
if (message.balance !==
|
|
318
|
+
if (message.balance !== undefined) {
|
|
311
319
|
obj.balance = message.balance;
|
|
312
320
|
}
|
|
313
|
-
if (message.rupee_balance !==
|
|
321
|
+
if (message.rupee_balance !== undefined) {
|
|
314
322
|
obj.rupee_balance = message.rupee_balance;
|
|
315
323
|
}
|
|
316
324
|
if (message.txn_id !== 0) {
|
|
317
325
|
obj.txn_id = Math.round(message.txn_id);
|
|
318
326
|
}
|
|
319
|
-
if (message.conversion_factor !==
|
|
327
|
+
if (message.conversion_factor !== undefined) {
|
|
320
328
|
obj.conversion_factor = Math.round(message.conversion_factor);
|
|
321
329
|
}
|
|
322
330
|
if (message.txn_status !== "") {
|
|
@@ -329,12 +337,12 @@ exports.response_Data = {
|
|
|
329
337
|
},
|
|
330
338
|
fromPartial(object) {
|
|
331
339
|
const message = createBaseresponse_Data();
|
|
332
|
-
message.locked = object.locked ??
|
|
333
|
-
message.unlocked = object.unlocked ??
|
|
334
|
-
message.balance = object.balance ??
|
|
335
|
-
message.rupee_balance = object.rupee_balance ??
|
|
340
|
+
message.locked = object.locked ?? undefined;
|
|
341
|
+
message.unlocked = object.unlocked ?? undefined;
|
|
342
|
+
message.balance = object.balance ?? undefined;
|
|
343
|
+
message.rupee_balance = object.rupee_balance ?? undefined;
|
|
336
344
|
message.txn_id = object.txn_id ?? 0;
|
|
337
|
-
message.conversion_factor = object.conversion_factor ??
|
|
345
|
+
message.conversion_factor = object.conversion_factor ?? undefined;
|
|
338
346
|
message.txn_status = object.txn_status ?? "";
|
|
339
347
|
return message;
|
|
340
348
|
},
|