@etsoo/appscript 1.3.31 → 1.3.33
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/lib/cjs/app/CoreApp.d.ts +13 -2
- package/lib/cjs/app/CoreApp.js +0 -4
- package/lib/cjs/app/IApp.d.ts +0 -15
- package/lib/mjs/app/CoreApp.d.ts +13 -2
- package/lib/mjs/app/CoreApp.js +0 -4
- package/lib/mjs/app/IApp.d.ts +0 -15
- package/package.json +4 -4
- package/src/app/CoreApp.ts +2 -26
- package/src/app/IApp.ts +0 -25
package/lib/cjs/app/CoreApp.d.ts
CHANGED
|
@@ -286,9 +286,20 @@ export declare abstract class CoreApp<U extends IUser, S extends IAppSettings, N
|
|
|
286
286
|
* @returns string
|
|
287
287
|
*/
|
|
288
288
|
formatDate(input?: Date | string, options?: DateUtils.FormatOptions, timeZone?: string): string | undefined;
|
|
289
|
-
|
|
289
|
+
/**
|
|
290
|
+
* Format money number
|
|
291
|
+
* @param input Input money number
|
|
292
|
+
* @param isInteger Is integer
|
|
293
|
+
* @param options Options
|
|
294
|
+
* @returns Result
|
|
295
|
+
*/
|
|
290
296
|
formatMoney(input: number | bigint, isInteger?: boolean, options?: Intl.NumberFormatOptions): string;
|
|
291
|
-
|
|
297
|
+
/**
|
|
298
|
+
* Format number
|
|
299
|
+
* @param input Input number
|
|
300
|
+
* @param options Options
|
|
301
|
+
* @returns Result
|
|
302
|
+
*/
|
|
292
303
|
formatNumber(input: number | bigint, options?: Intl.NumberFormatOptions): string;
|
|
293
304
|
/**
|
|
294
305
|
* Format error
|
package/lib/cjs/app/CoreApp.js
CHANGED
|
@@ -717,8 +717,6 @@ class CoreApp {
|
|
|
717
717
|
* @returns Result
|
|
718
718
|
*/
|
|
719
719
|
formatMoney(input, isInteger = false, options) {
|
|
720
|
-
if (input == null)
|
|
721
|
-
return undefined;
|
|
722
720
|
return shared_1.NumberUtils.formatMoney(input, this.currency, this.culture, isInteger, options);
|
|
723
721
|
}
|
|
724
722
|
/**
|
|
@@ -728,8 +726,6 @@ class CoreApp {
|
|
|
728
726
|
* @returns Result
|
|
729
727
|
*/
|
|
730
728
|
formatNumber(input, options) {
|
|
731
|
-
if (input == null)
|
|
732
|
-
return undefined;
|
|
733
729
|
return shared_1.NumberUtils.format(input, this.culture, options);
|
|
734
730
|
}
|
|
735
731
|
/**
|
package/lib/cjs/app/IApp.d.ts
CHANGED
|
@@ -226,14 +226,6 @@ export interface IApp {
|
|
|
226
226
|
* @returns Error message
|
|
227
227
|
*/
|
|
228
228
|
formatError(error: ApiDataError): string;
|
|
229
|
-
/**
|
|
230
|
-
* Format money number
|
|
231
|
-
* @param input Input money number
|
|
232
|
-
* @param isInteger Is integer
|
|
233
|
-
* @param options Options
|
|
234
|
-
* @returns Result
|
|
235
|
-
*/
|
|
236
|
-
formatMoney(input: null | undefined, isInteger?: boolean, options?: Intl.NumberFormatOptions): undefined;
|
|
237
229
|
/**
|
|
238
230
|
* Format money number
|
|
239
231
|
* @param input Input money number
|
|
@@ -242,13 +234,6 @@ export interface IApp {
|
|
|
242
234
|
* @returns Result
|
|
243
235
|
*/
|
|
244
236
|
formatMoney(input: number | bigint, isInteger?: boolean, options?: Intl.NumberFormatOptions): string;
|
|
245
|
-
/**
|
|
246
|
-
* Format number
|
|
247
|
-
* @param input Input number
|
|
248
|
-
* @param options Options
|
|
249
|
-
* @returns Result
|
|
250
|
-
*/
|
|
251
|
-
formatNumber(input: null | undefined, options?: Intl.NumberFormatOptions): undefined;
|
|
252
237
|
/**
|
|
253
238
|
* Format number
|
|
254
239
|
* @param input Input number
|
package/lib/mjs/app/CoreApp.d.ts
CHANGED
|
@@ -286,9 +286,20 @@ export declare abstract class CoreApp<U extends IUser, S extends IAppSettings, N
|
|
|
286
286
|
* @returns string
|
|
287
287
|
*/
|
|
288
288
|
formatDate(input?: Date | string, options?: DateUtils.FormatOptions, timeZone?: string): string | undefined;
|
|
289
|
-
|
|
289
|
+
/**
|
|
290
|
+
* Format money number
|
|
291
|
+
* @param input Input money number
|
|
292
|
+
* @param isInteger Is integer
|
|
293
|
+
* @param options Options
|
|
294
|
+
* @returns Result
|
|
295
|
+
*/
|
|
290
296
|
formatMoney(input: number | bigint, isInteger?: boolean, options?: Intl.NumberFormatOptions): string;
|
|
291
|
-
|
|
297
|
+
/**
|
|
298
|
+
* Format number
|
|
299
|
+
* @param input Input number
|
|
300
|
+
* @param options Options
|
|
301
|
+
* @returns Result
|
|
302
|
+
*/
|
|
292
303
|
formatNumber(input: number | bigint, options?: Intl.NumberFormatOptions): string;
|
|
293
304
|
/**
|
|
294
305
|
* Format error
|
package/lib/mjs/app/CoreApp.js
CHANGED
|
@@ -714,8 +714,6 @@ export class CoreApp {
|
|
|
714
714
|
* @returns Result
|
|
715
715
|
*/
|
|
716
716
|
formatMoney(input, isInteger = false, options) {
|
|
717
|
-
if (input == null)
|
|
718
|
-
return undefined;
|
|
719
717
|
return NumberUtils.formatMoney(input, this.currency, this.culture, isInteger, options);
|
|
720
718
|
}
|
|
721
719
|
/**
|
|
@@ -725,8 +723,6 @@ export class CoreApp {
|
|
|
725
723
|
* @returns Result
|
|
726
724
|
*/
|
|
727
725
|
formatNumber(input, options) {
|
|
728
|
-
if (input == null)
|
|
729
|
-
return undefined;
|
|
730
726
|
return NumberUtils.format(input, this.culture, options);
|
|
731
727
|
}
|
|
732
728
|
/**
|
package/lib/mjs/app/IApp.d.ts
CHANGED
|
@@ -226,14 +226,6 @@ export interface IApp {
|
|
|
226
226
|
* @returns Error message
|
|
227
227
|
*/
|
|
228
228
|
formatError(error: ApiDataError): string;
|
|
229
|
-
/**
|
|
230
|
-
* Format money number
|
|
231
|
-
* @param input Input money number
|
|
232
|
-
* @param isInteger Is integer
|
|
233
|
-
* @param options Options
|
|
234
|
-
* @returns Result
|
|
235
|
-
*/
|
|
236
|
-
formatMoney(input: null | undefined, isInteger?: boolean, options?: Intl.NumberFormatOptions): undefined;
|
|
237
229
|
/**
|
|
238
230
|
* Format money number
|
|
239
231
|
* @param input Input money number
|
|
@@ -242,13 +234,6 @@ export interface IApp {
|
|
|
242
234
|
* @returns Result
|
|
243
235
|
*/
|
|
244
236
|
formatMoney(input: number | bigint, isInteger?: boolean, options?: Intl.NumberFormatOptions): string;
|
|
245
|
-
/**
|
|
246
|
-
* Format number
|
|
247
|
-
* @param input Input number
|
|
248
|
-
* @param options Options
|
|
249
|
-
* @returns Result
|
|
250
|
-
*/
|
|
251
|
-
formatNumber(input: null | undefined, options?: Intl.NumberFormatOptions): undefined;
|
|
252
237
|
/**
|
|
253
238
|
* Format number
|
|
254
239
|
* @param input Input number
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@etsoo/appscript",
|
|
3
|
-
"version": "1.3.
|
|
3
|
+
"version": "1.3.33",
|
|
4
4
|
"description": "Applications shared TypeScript framework",
|
|
5
5
|
"main": "lib/cjs/index.js",
|
|
6
6
|
"module": "lib/mjs/index.js",
|
|
@@ -52,9 +52,9 @@
|
|
|
52
52
|
},
|
|
53
53
|
"homepage": "https://github.com/ETSOO/AppScript#readme",
|
|
54
54
|
"dependencies": {
|
|
55
|
-
"@etsoo/notificationbase": "^1.1.
|
|
56
|
-
"@etsoo/restclient": "^1.0.
|
|
57
|
-
"@etsoo/shared": "^1.1.
|
|
55
|
+
"@etsoo/notificationbase": "^1.1.16",
|
|
56
|
+
"@etsoo/restclient": "^1.0.78",
|
|
57
|
+
"@etsoo/shared": "^1.1.77",
|
|
58
58
|
"@types/crypto-js": "^4.1.1",
|
|
59
59
|
"crypto-js": "^4.1.1"
|
|
60
60
|
},
|
package/src/app/CoreApp.ts
CHANGED
|
@@ -30,7 +30,6 @@ import {
|
|
|
30
30
|
SHA3
|
|
31
31
|
} from 'crypto-js';
|
|
32
32
|
import { AddressRegion } from '../address/AddressRegion';
|
|
33
|
-
import { AddressUtils } from '../address/AddressUtils';
|
|
34
33
|
import { BridgeUtils } from '../bridges/BridgeUtils';
|
|
35
34
|
import { EntityStatus } from '../business/EntityStatus';
|
|
36
35
|
import { InitCallDto } from '../erp/dto/InitCallDto';
|
|
@@ -996,16 +995,6 @@ export abstract class CoreApp<
|
|
|
996
995
|
return DateUtils.format(input, currentCulture.name, options, timeZone);
|
|
997
996
|
}
|
|
998
997
|
|
|
999
|
-
formatMoney(
|
|
1000
|
-
input: null | undefined,
|
|
1001
|
-
isInteger?: boolean,
|
|
1002
|
-
options?: Intl.NumberFormatOptions
|
|
1003
|
-
): undefined;
|
|
1004
|
-
formatMoney(
|
|
1005
|
-
input: number | bigint,
|
|
1006
|
-
isInteger?: boolean,
|
|
1007
|
-
options?: Intl.NumberFormatOptions
|
|
1008
|
-
): string;
|
|
1009
998
|
/**
|
|
1010
999
|
* Format money number
|
|
1011
1000
|
* @param input Input money number
|
|
@@ -1014,11 +1003,10 @@ export abstract class CoreApp<
|
|
|
1014
1003
|
* @returns Result
|
|
1015
1004
|
*/
|
|
1016
1005
|
formatMoney(
|
|
1017
|
-
input: number | bigint
|
|
1006
|
+
input: number | bigint,
|
|
1018
1007
|
isInteger: boolean = false,
|
|
1019
1008
|
options?: Intl.NumberFormatOptions
|
|
1020
1009
|
) {
|
|
1021
|
-
if (input == null) return undefined;
|
|
1022
1010
|
return NumberUtils.formatMoney(
|
|
1023
1011
|
input,
|
|
1024
1012
|
this.currency,
|
|
@@ -1028,25 +1016,13 @@ export abstract class CoreApp<
|
|
|
1028
1016
|
);
|
|
1029
1017
|
}
|
|
1030
1018
|
|
|
1031
|
-
formatNumber(
|
|
1032
|
-
input: null | undefined,
|
|
1033
|
-
options?: Intl.NumberFormatOptions
|
|
1034
|
-
): undefined;
|
|
1035
|
-
formatNumber(
|
|
1036
|
-
input: number | bigint,
|
|
1037
|
-
options?: Intl.NumberFormatOptions
|
|
1038
|
-
): string;
|
|
1039
1019
|
/**
|
|
1040
1020
|
* Format number
|
|
1041
1021
|
* @param input Input number
|
|
1042
1022
|
* @param options Options
|
|
1043
1023
|
* @returns Result
|
|
1044
1024
|
*/
|
|
1045
|
-
formatNumber(
|
|
1046
|
-
input: number | bigint | null | undefined,
|
|
1047
|
-
options?: Intl.NumberFormatOptions
|
|
1048
|
-
) {
|
|
1049
|
-
if (input == null) return undefined;
|
|
1025
|
+
formatNumber(input: number | bigint, options?: Intl.NumberFormatOptions) {
|
|
1050
1026
|
return NumberUtils.format(input, this.culture, options);
|
|
1051
1027
|
}
|
|
1052
1028
|
|
package/src/app/IApp.ts
CHANGED
|
@@ -8,7 +8,6 @@ import {
|
|
|
8
8
|
import { ApiDataError, IApi, IPData } from '@etsoo/restclient';
|
|
9
9
|
import { DataTypes, DateUtils, IStorage, ListType } from '@etsoo/shared';
|
|
10
10
|
import { AddressRegion } from '../address/AddressRegion';
|
|
11
|
-
import { ProductUnit } from '../business/ProductUnit';
|
|
12
11
|
import { IActionResult } from '../result/IActionResult';
|
|
13
12
|
import { IUser } from '../state/User';
|
|
14
13
|
import { IAppSettings } from './AppSettings';
|
|
@@ -299,19 +298,6 @@ export interface IApp {
|
|
|
299
298
|
*/
|
|
300
299
|
formatError(error: ApiDataError): string;
|
|
301
300
|
|
|
302
|
-
/**
|
|
303
|
-
* Format money number
|
|
304
|
-
* @param input Input money number
|
|
305
|
-
* @param isInteger Is integer
|
|
306
|
-
* @param options Options
|
|
307
|
-
* @returns Result
|
|
308
|
-
*/
|
|
309
|
-
formatMoney(
|
|
310
|
-
input: null | undefined,
|
|
311
|
-
isInteger?: boolean,
|
|
312
|
-
options?: Intl.NumberFormatOptions
|
|
313
|
-
): undefined;
|
|
314
|
-
|
|
315
301
|
/**
|
|
316
302
|
* Format money number
|
|
317
303
|
* @param input Input money number
|
|
@@ -325,17 +311,6 @@ export interface IApp {
|
|
|
325
311
|
options?: Intl.NumberFormatOptions
|
|
326
312
|
): string;
|
|
327
313
|
|
|
328
|
-
/**
|
|
329
|
-
* Format number
|
|
330
|
-
* @param input Input number
|
|
331
|
-
* @param options Options
|
|
332
|
-
* @returns Result
|
|
333
|
-
*/
|
|
334
|
-
formatNumber(
|
|
335
|
-
input: null | undefined,
|
|
336
|
-
options?: Intl.NumberFormatOptions
|
|
337
|
-
): undefined;
|
|
338
|
-
|
|
339
314
|
/**
|
|
340
315
|
* Format number
|
|
341
316
|
* @param input Input number
|