import { Observable, Subject, Subscription } from "rxjs"; import { HttpClient, HttpHandler, HttpParameterCodec, HttpParams } from "@angular/common/http"; import * as i0 from "@angular/core"; import { AfterViewInit, ElementRef, ModuleWithProviders, OnChanges, OnDestroy, OnInit, PipeTransform, TemplateRef, ViewContainerRef } from "@angular/core"; import * as i1 from "@angular/common"; export declare class iNet { /** * Either global variable or required library */ private static iNetGlobal; /** * Returns the full url from the given relative path. * * @param {String} relativePath (required) The given relative path. * * @return {String} The string URL */ static getUrl(relativePath: any): string; /** * Returns full url form given relative path with firm prefix * @param {String} path (required) The URL * @return {String} The string URL */ static getPUrl(path: string): string; /** * Returns the SSO redirect url from the given url path. * * @param {String} url (required) The given url. * @param {String} app (option) The given application. * * @return {String} The string SSO redirect URL */ static getSSOUrl(url: string, app?: string): string; /** * Gets the username of user logged */ static getUserName(): string; /** * Gets the displayName of user logged */ static getDisplayName(): string; /** * Gets the url of file server */ static getFileServer(): string; /** * Gets the image folder path of module inside cloud */ static getImageFolder(): string; /** * Gets the prefix of server */ static getPrefix(): string; /** * Gets the prefix of server */ static getFirmPrefix(): string; /** * Checks if inet layout is enabled */ static isEnableLayout(): boolean; /** * Gets the id of organization */ static getOrganId(): string; /** * Encodes an Object, Array or other value. * @param {Object} o The variable to encode. * @returns {String} The JSON string */ static encodeJSON(o: any): string; /** * Decodes (parses) a JSON string to an object. * @param {String} src The JSON string. * @returns {Object} The resulting object */ static decodeJSON(src: string): any; /** * Gets the plugin manager */ static getPluginManager(): any; /** * Gets the query param from url */ static getParam(param: string): string; /** * Gets the media path of file server */ static getMediaPath(): string; /** * The instances of global object */ static getInstances(): any; /** * Generate the identifier. * @return {String} The string */ static generateId(): string; /** * Generate the UUID. * @return {String} The string UUID */ static generateUUID(): string; /** * Returns true if the passed value is empty. The value is deemed to be * empty if it is * null * undefined * an empty array * a zero length * an empty object * string (Unless the allowBlank parameter is true) * * @param {Mixed} value The value to test * @param {Boolean} allowBlank (optional) true to allow empty strings (defaults to false) * @return {Boolean} */ static isEmpty(v: any, allowBlank?: boolean): boolean; /** * Return true if passed object is empty. * @param {Mixed} value The value to test * @returns {boolean} */ static isEmptyObject(v: any): boolean; /** * Return true if firm prefix is smartcloud. */ static isSmartCloud(): boolean; /** * Gets the web context of server */ static getWebContext(): string; /** * Appends content to the query string of a URL, handling logic for whether to place * a question mark or ampersand. * @param {String} url The URL to append to. * @param {String} s The content to append to the URL. * @return (String) The resulting URL */ static urlAppend: (url: string, s: string) => string; /** * Gets the max size of file upload */ static getMaxSizeUpload(): number; } export declare const ErrorMessage: { CLIENT: string; SERVER: string; TYPE: string; }; export interface Paging { pageSize: number; pageNumber: number; } export interface WebResponse {} export declare class ErrorResponse { errors: any[]; type: string; } export declare class ResponseData extends ErrorResponse implements WebResponse { total: number; items: any[]; } export declare class ResponseElementsData extends ErrorResponse implements WebResponse { elements: any[]; } export interface UserProfile { uuid: string; code: string; usercode: string; username: string; password: string; fname: string; mname: string; lname: string; firstName: string; lastName: string; middleName: string; name: string; email: string; mobile: string; phone: string; birthday: number; address: string; state: string; city: string; country: string; timezone: string; postalCode: string; language: string; department: string; position: string; emailToAccount: boolean; signPictureID: string; signVerify: string; secureTicket: string; attributes: any; avatar: string; } interface UserAttribute { readonly group: string; readonly name: string; readonly value: string; } export interface UserResponseData { user: UserProfile; attributes: UserAttribute[]; glcontactprofileload: UserProfile; } export declare class AppCloudConfig { canChat?: boolean; wsContext?: string; devConfigUrl?: string; } export declare class LoadingIndicatorService implements OnDestroy { static instance: LoadingIndicatorService; elementId: string; private static loadingIndicator; constructor(); setElementId(elementId: string): void; getElementId(): string; /** * Get DOM of loading indicator */ private getIndicator; private getLoadingIndicator; showLoading(message?: string): void; hideLoading(): void; complete(): void; ngOnDestroy(): void; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵprov: i0.ɵɵInjectableDeclaration; } export declare class LoadingIndicator { container: HTMLElement; element: HTMLElement; message: string; constructor(container: HTMLElement, el: HTMLElement, msg?: string); } export declare class HttpClientService extends HttpClient { private loadingService; private headers; constructor(handler: HttpHandler, loadingService: LoadingIndicatorService); convertToHttpParams(obj: any): HttpParams; getJSON(url: string, body?: any | null): Observable; postJSON(url: string, body?: any | null): Observable; putJSON(url: string, body?: any | null): Observable; deleteJSON(url: string, body?: any | null): Observable; convertToFormData(obj: any): FormData; downloadFile(url: string, obj?: any): void; showLoading(message?: string): void; hideLoading(): void; getUrl(relativePath: string): string; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵprov: i0.ɵɵInjectableDeclaration; } export declare class CoreService { private http; static instance: CoreService; private static environment; private $appCache; private applications; constructor(http: HttpClientService); logout(locale?: string): void; getAvatar(usercode: string, thumbnail?: number): string; isExternalUser(): boolean; isCommunity(): boolean; getOrg(): Observable; searchOrgan(params?: any): Observable; getSystemApplication(clearCached?: boolean): Observable; getApps(): Observable; searchFirmAccount(params: any, callback: Function): void; updateLanguage(lang: string, callback?: Function): void; /** * Get the Image URL for the current app * @param fileName - the file name */ getImageUrl(fileName: string): string; /** * Build the file URL for the file server request * @param fileName - the given file name */ getFileUrl(fileName: string): string; getSsoRedirect(data: SsoRedirectData): string; convergePlugins(): Observable; convergeSearch(params: any): Observable; setEnvironment(v?: any): void; getEnvironment(): any; private getPath; /** * Gets File server path */ getFileServerPath(): string; /** * Gets assets path of current app */ getAssetsPath(): string; /** * Get the Image URL from module * @param moduleName - the module name * @param fileName - the file name */ getImageUrlFromModule(fileName: string, moduleName?: string): string; private logoutCurrentApp; private logoutApp; private getAppsWithoutContext; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵprov: i0.ɵɵInjectableDeclaration; } export interface LogoutData { uuid: string; } export interface SsoRedirectData { url: string; application: string; redirect?: boolean; } export interface PathRedirectData { path: string; application: string; organId?: string; firmPrefix?: string; } export interface SystemApplication { domain?: string; firmContext?: string; homepage?: string; icon?: string; module?: string; name?: string; organId?: string; pattern?: string; prefixUri?: string; webContext?: string; widget?: string; } export declare class SuggestionService { private http; static instance: SuggestionService; constructor(http: HttpClientService); saveSuggestion(params: SuggestionParamData, callback?: Function): Subscription; loadSuggestion(params: SuggestionParamData, callback: Function): Subscription; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵprov: i0.ɵɵInjectableDeclaration; } export interface SuggestionParamData { content: string; keyword: string; } export interface SuggestionResponse { items: SuggestionItem[]; total: number; } export interface SuggestionItem { content: string; keyword: string; ownercode: string; usage: number; uuid: string; } export declare class HttpUrlEncodingCodec implements HttpParameterCodec { encodeKey(k: string): string; encodeValue(v: string): string; decodeKey(k: string): string; decodeValue(v: string): string; } declare namespace infinite_scroller_directive_d_exports { export { InfiniteScrollerDirective }; } export declare class InfiniteScrollerDirective implements AfterViewInit { private elm; private scrollEvent$; private userScrolledDown$; private requestOnScroll$; scrollCallback: any; immediateCallback: any; scrollPercent: number; isSubmit: boolean; constructor(elm: ElementRef); ngAfterViewInit(): void; private registerScrollEvent; private streamScrollEvents; private requestCallbackOnScroll; private isUserScrollingDown; private isScrollExpectedPercent; private isScrollSubmit; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵdir: i0.ɵɵDirectiveDeclaration; } export declare class NewPassword { oldpass: string; newpass: string; confirmpass: string; } export declare class NotificationService { constructor(); showMessage(msg: string, type?: string, title?: string, config?: any): void; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵprov: i0.ɵɵInjectableDeclaration; } export declare class SecurityService { private http; static instance: SecurityService; private roles; constructor(http: HttpClientService); load(): Promise; private parserRoleFrom; private uniqueArray; private append; hasRole(v: string): boolean; /** * Check session timeout when system is idle */ ping(): void; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵprov: i0.ɵɵInjectableDeclaration; } declare namespace role_access_directive_d_exports { export { RoleAccessDirective }; } export declare class RoleAccessDirective implements OnInit { private templateRef; private viewContainer; private securityService; roleAccess: string; constructor(templateRef: TemplateRef, viewContainer: ViewContainerRef, securityService: SecurityService); ngOnInit(): void; private applyPermission; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵdir: i0.ɵɵDirectiveDeclaration; } declare namespace ssourl_pipe_d_exports { export { SSOUrlPipe }; } export declare class SSOUrlPipe implements PipeTransform { transform(url: string): string; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵpipe: i0.ɵɵPipeDeclaration; } declare namespace time_ago_pipe_d_exports { export { TimeAgoPipe }; } export declare class TimeAgoPipe implements PipeTransform { transform(value?: number, format?: string): string | null; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵpipe: i0.ɵɵPipeDeclaration; } export declare class UserProfileService { private http; private coreService; static instance: UserProfileService; static readonly DEFAULT_AVATAR_URL = "data:image/gif;base64,R0lGODlhAQABAID/AMDAwAAAACH5BAEAAAAALAAAAAABAAEAAAICRAEAOw=="; private profile; private $systemProfileCache; private systemProfile; private $profileObservableCache; private inventory; private url; constructor(http: HttpClientService, coreService: CoreService); private loadSystemProfile; /** * Gets the currently LDAP profile of user logged */ getSystemProfile(): Observable; /** * Gets the curently profile of user logged */ getProfile(): Observable; update(user: UserProfile): Observable; changePassword(password: NewPassword): Observable; getAvatarUrlByProfile(userProfile: UserProfile): string; getAvatarUrl(): Promise; getFullName(): Promise; getSignPictureId(): Promise; getSignVerifyNumber(): Promise; increaseAvatarVersion(): void; getAvatarVersion(): number; /** * Returns the profile associated with the username. * @param username - {string} The username variable */ getProfileByUsername(username: string): Observable; /** * Returns the avatar URL with the username. * @param username - {string} The username variable */ getAvatarUrlByUsername(username: string): Promise; getDefaultAvatarUrl(): string; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵprov: i0.ɵɵInjectableDeclaration; } export declare class AccentService { private _vi_accents; private _en_accents; constructor(); viToEn(str: string): string; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵprov: i0.ɵɵInjectableDeclaration; } export declare class CacheStorageService { timeCache: number; private __storage; private __queue; constructor(); promiseQueue(name: string, promise: Function, resovle: Function): void; resolveQueue(name: string, context: any, args?: any[]): void; getData(key: string): any; setData(key: string, data: any, options?: CacheStorageOptions): void; removeData(key: string): void; clearData(): void; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵprov: i0.ɵɵInjectableDeclaration; } export interface CacheStorageOptions { timeCache?: number; resolveData?: boolean; } export interface CacheStorageItem { time: number; timeCache: number; value: any; } declare namespace autosize_directive_d_exports { export { AutoSizeDirective }; } export declare class AutoSizeDirective implements AfterViewInit { element: ElementRef; private el; private _minHeight; private _maxHeight; private _lastHeight; private _clientWidth; get minHeight(): string; set minHeight(val: string); get maxHeight(): string; set maxHeight(val: string); onResize(): void; onInput(): void; constructor(element: ElementRef); ngAfterViewInit(): void; adjust(): void; updateMinHeight(): void; updateMaxHeight(): void; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵdir: i0.ɵɵDirectiveDeclaration; } declare namespace avatar_directive_d_exports { export { AvatarDirective }; } export declare class AvatarDirective implements OnInit, OnChanges { private _el; usercode?: string; version?: number; private url; constructor(_el: ElementRef); ngOnInit(): void; ngOnChanges(): void; private _setAvatar; private _loadAvatarError; private _loadAvatarSuccess; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵdir: i0.ɵɵDirectiveDeclaration; } export declare class ResourceLoaderService { private _loaded; private _version; constructor(); load(resources: Resource[], callback: Function): any; loadJS(url: string, callback: Function): void; loadCSS(url: string, callback: Function): void; getFullUrlJS(url: string): string; isLoaded(url: string): boolean; private _loadResources; private _groupResources; private _loadGroups; private _load; private _loadWithTagName; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵprov: i0.ɵɵInjectableDeclaration; } export interface Resource { url: string; sync?: boolean; loaded?: boolean; type?: string; } export declare function initApp(): Promise; export declare class CoreModule { static forRoot(config?: AppCloudConfig): ModuleWithProviders; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵmod: i0.ɵɵNgModuleDeclaration; static ɵinj: i0.ɵɵInjectorDeclaration; } export declare abstract class WebSocketAbstract { onMessage: Subject; onStateChange: Subject; stateChange(): void; abstract readyState: number; abstract connect(options: any, username: string): any; abstract close(): any; abstract send(envelop: WebSocketEnvelop): Promise; } export declare enum WebSocketType { SEND = "send", PUBLISH = "publish" } export declare class WebSocketEnvelop { type: WebSocketType | string; address: string; socialOrgid?: string; body: EnvelopBody | CustomEnvelopBody; } export declare class EnvelopBody { uuid: string; application: string; message: EnvelopMessage; sender: string; alias: string[]; sent: number; channelIds?: string; socialOrgid?: string; categories?: string | string[]; } export declare class EnvelopMessage { sender: string; alert: string; content: string; joins: string; duration: string; channelIds?: string; constructor(sender: string, content: string, joins?: string, duration?: string); } export declare class CustomEnvelopBody { uuid: string; application: string; message: T; sender: string; alias: string[]; sent: number; channelIds?: string; socialOrgid?: string; categories?: string | string[]; } export declare class WebSocketClient { private appConfig; private http; static instance: WebSocketClient; socket: WebSocketAbstract; onMessage: Subject; onStateChange: Subject; sendTimeout: number; private _username; private _autoconnect; private _autoconnectAfter; private _autoconnectRepeat; private _autoconnectRetryAfter; private _autoconectCount; private _autoconectTimer; private _envelopQueue; get readyState(): number; get connecting(): boolean; get connected(): boolean; get closing(): boolean; get closed(): boolean; get autoconnect(): boolean; constructor(appConfig: AppCloudConfig, http: HttpClientService); close(): void; send(address: string, message: string, application?: string): Promise; sendEnvelop(envelop: WebSocketEnvelop): Promise; buildEnvelop(address: string, message: string, application?: string, join?: string): WebSocketEnvelop; private _sendEnvelopQueue; private _completeEnvelopQueue; private normalizeSocketUrl; private _register; private _getAccountInfo; private _stateChange; private _runAutoConnect; private _cancelAutoConnect; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵprov: i0.ɵɵInjectableDeclaration; } export declare class WebSocketJboss extends WebSocketAbstract { constructor(url: string, username: string); private _socket; get readyState(): number; private onChange; connect(url: string, username: string): void; close(): void; send(envelop: WebSocketEnvelop): Promise; private _ping; } export declare class WebSocketClientService extends WebSocketClient { static ɵfac: i0.ɵɵFactoryDeclaration; static ɵprov: i0.ɵɵInjectableDeclaration; } export declare class HtmlUtils { static formatPattern: RegExp; static formatHtmlDisplay(html: string): string; } export interface FileUploadOptions { maxSizeUpload?: number; resolveKey: string; filename?: string; minetype?: string; resolver(key: string, response: any): any[]; } export interface ChunkUploadOptions extends FileUploadOptions { filename: string; minetype: string; chunkCount: number; } export declare class UploaderService { private http; constructor(http: HttpClientService); private uploadFile; private uploadChunk; private uploadChunks; private uploadChunkFile; uploadBlob(url: string, blobs: Blob[], formData: FormData, options: ChunkUploadOptions): Observable; /** * Send files to a server * @param url - URL of server to receive the file * @param files - the input files * @param formData - the FormData object * @param options - the file upload options */ upload(url: string, files: File[], params?: any, options?: FileUploadOptions): Promise; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵprov: i0.ɵɵInjectableDeclaration; }