import { NzMessageService } from 'ng-zorro-antd/message'; import { NzNotificationService } from 'ng-zorro-antd/notification'; import { Router, ActivatedRoute } from "@angular/router"; import { HttpClient } from '@angular/common/http'; export declare class EmopUtilsService { private nzNotificationService; private nzMessageService; private router; private route; private http; /** * token */ access_token: string; constructor(nzNotificationService: NzNotificationService, nzMessageService: NzMessageService, router: Router, route: ActivatedRoute, http: HttpClient); /** * 初始化开发模式的组件库 */ init(options?: { access_token?: string; }): void; /** * 初始化开发模式的组件库 */ private setToken; private emopLog; /** * 创建全局提示框 * @param type 消息提示类型 'success' | 'error' | 'info' | 'warning' | 'loading' * @param title 消息提示标题 */ message(type: 'success' | 'error' | 'info' | 'warning' | 'loading', title: any): void; /** * 创建通知提醒框 * @param type 类型 'success' | 'info' | 'warning' | 'error' * @param title 标题 * @param content 内容 */ notice(type: 'success' | 'info' | 'warning' | 'error', title: any, content?: any): void; /** * 拖拽 * @param selector 要被拖拽的元素 仅支持css选择器 * @param moveSelector 可选 被移动的元素 仅支持css选择器 * @returns */ drag(selector: any, moveSelector?: any): void; /** * 路由跳转 * @param url 跳转的路由地址 * @param queryParams 跳转携带的参数 */ navigate(url: string, queryParams?: any): void; /** * uuid 生成 */ /** * 获取路由中携带的get参数 * @returns 返回get参数对象 */ getRouteQueryParams(): import("@angular/router").Params; /** * 处理api回调的响应函数 * @param res 服务器响应的数据 * @param successFn 响应200的回调 * @param errorFn 响应不是200的回调 */ response(res: any, successFn: Function, errorFn?: Function): void; /** * 清除登录信息 */ logout(): void; /** * 将内容复制进剪贴板 */ copy(text: string): boolean; /** * 将类似get参数的字符串解析成对象 */ parseCookie(): {}; } export declare function Rest(url: string): (target: any) => void; /** * 请求的装饰器 * @param url 请求的地址 * 被装饰的函数中第一个参数是传参数据,get请求会自动拼接在url中,post请求会在请求体中。第二个参数是路径参数,会自动拼接在url中。 */ export declare function Get(url: string): (target: any, name: any, descriptor: any) => void; /** * 请求的装饰器 * @param url 请求的地址 * 被装饰的函数中第一个参数是传参数据,get请求会自动拼接在url中,post请求会在请求体中。第二个参数是路径参数,会自动拼接在url中。 */ export declare function Post(url: string): (target: any, name: any, descriptor: any) => void; /** * 请求的装饰器 * @param url 请求的地址 * 被装饰的函数中第一个参数是传参数据,get请求会自动拼接在url中,post请求会在请求体中。第二个参数是路径参数,会自动拼接在url中。 */ export declare function Put(url: string): (target: any, name: any, descriptor: any) => void; /** * 请求的装饰器 * @param url 请求的地址 * 被装饰的函数中第一个参数是传参数据,get请求会自动拼接在url中,post请求会在请求体中。第二个参数是路径参数,会自动拼接在url中。 */ export declare function Delete(url: string): (target: any, name: any, descriptor: any) => void; /** * 获取函数的参数对象 */ export declare function getParameterObject(keys: any, values: any): {}; /** * 获得函数的所有参数名 * @param fn 函数 * @returns */ export declare function getParameterName(fn: Function): any;