Browse Source
Merge pull request #8071 from engix-ltd/base64_api
Add Base64 functions to Utils service.
pull/8278/head
Igor Kulikov
3 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with
22 additions and
1 deletions
-
ui-ngx/src/app/core/services/utils.service.ts
|
|
|
@ -29,7 +29,11 @@ import { |
|
|
|
isDefined, |
|
|
|
isDefinedAndNotNull, |
|
|
|
isString, |
|
|
|
isUndefined |
|
|
|
isUndefined, |
|
|
|
objToBase64, |
|
|
|
objToBase64URI, |
|
|
|
base64toString, |
|
|
|
base64toObj |
|
|
|
} from '@core/utils'; |
|
|
|
import { WindowMessage } from '@shared/models/window-message.model'; |
|
|
|
import { TranslateService } from '@ngx-translate/core'; |
|
|
|
@ -518,4 +522,21 @@ export class UtilsService { |
|
|
|
refCount() |
|
|
|
); |
|
|
|
} |
|
|
|
|
|
|
|
public objToBase64(obj: any): string { |
|
|
|
return objToBase64(obj); |
|
|
|
} |
|
|
|
|
|
|
|
public base64toString(b64Encoded: string): string { |
|
|
|
return base64toString(b64Encoded); |
|
|
|
} |
|
|
|
|
|
|
|
public objToBase64URI(obj: any): string { |
|
|
|
return objToBase64URI(obj); |
|
|
|
} |
|
|
|
|
|
|
|
public base64toObj(b64Encoded: string): any { |
|
|
|
return base64toObj(b64Encoded); |
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|