mirror of
https://github.com/Fabio286/antares.git
synced 2025-06-05 21:59:22 +02:00
refactor: ts and composition api on WorkspaceExplorebar* components
This commit is contained in:
@@ -4,12 +4,12 @@ import connStringConstruct from '../libs/connStringDecode';
|
||||
import { unproxify } from '../libs/unproxify';
|
||||
|
||||
export default class {
|
||||
static makeTest (params: ConnectionParams & { pgConnString: string }): Promise<IpcResponse> {
|
||||
static makeTest (params: ConnectionParams & { pgConnString?: string }): Promise<IpcResponse> {
|
||||
const newParams = connStringConstruct(params) as ConnectionParams;
|
||||
return ipcRenderer.invoke('test-connection', unproxify(newParams));
|
||||
}
|
||||
|
||||
static connect (params: ConnectionParams & { pgConnString: string }): Promise<IpcResponse> {
|
||||
static connect (params: ConnectionParams & { pgConnString?: string }): Promise<IpcResponse> {
|
||||
const newParams = connStringConstruct(params) as ConnectionParams;
|
||||
return ipcRenderer.invoke('connect', unproxify(newParams));
|
||||
}
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
import { AlterFunctionParams, CreateFunctionParams, FunctionInfos, IpcResponse } from 'common/interfaces/antares';
|
||||
import { AlterFunctionParams, CreateFunctionParams, IpcResponse } from 'common/interfaces/antares';
|
||||
import { ipcRenderer } from 'electron';
|
||||
import { unproxify } from '../libs/unproxify';
|
||||
|
||||
export default class {
|
||||
static getFunctionInformations (params: { uid: string; schema: string; func: string}): Promise<IpcResponse<FunctionInfos>> {
|
||||
static getFunctionInformations (params: { uid: string; schema: string; func: string}): Promise<IpcResponse> {
|
||||
return ipcRenderer.invoke('get-function-informations', unproxify(params));
|
||||
}
|
||||
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
import { ipcRenderer } from 'electron';
|
||||
import { unproxify } from '../libs/unproxify';
|
||||
import { AlterRoutineParams, CreateRoutineParams, IpcResponse, RoutineInfos } from 'common/interfaces/antares';
|
||||
import { AlterRoutineParams, CreateRoutineParams, IpcResponse } from 'common/interfaces/antares';
|
||||
|
||||
export default class {
|
||||
static getRoutineInformations (params: { uid: string; schema: string; routine: string}): Promise<IpcResponse<RoutineInfos>> {
|
||||
static getRoutineInformations (params: { uid: string; schema: string; routine: string}): Promise<IpcResponse> {
|
||||
return ipcRenderer.invoke('get-routine-informations', unproxify(params));
|
||||
}
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@ export default class {
|
||||
return ipcRenderer.invoke('create-scheduler', unproxify(params));
|
||||
}
|
||||
|
||||
static toggleScheduler (params: { uid: string; schema: string; scheduler: string}): Promise<IpcResponse> {
|
||||
static toggleScheduler (params: { uid: string; schema: string; scheduler: string; enabled: boolean}): Promise<IpcResponse> {
|
||||
return ipcRenderer.invoke('toggle-scheduler', unproxify(params));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -7,7 +7,7 @@ export default class {
|
||||
return ipcRenderer.invoke('get-trigger-informations', unproxify(params));
|
||||
}
|
||||
|
||||
static dropTrigger (params: { schema: string; trigger: string }): Promise<IpcResponse> {
|
||||
static dropTrigger (params: { uid: string; schema: string; trigger: string }): Promise<IpcResponse> {
|
||||
return ipcRenderer.invoke('drop-trigger', unproxify(params));
|
||||
}
|
||||
|
||||
@@ -19,7 +19,7 @@ export default class {
|
||||
return ipcRenderer.invoke('create-trigger', unproxify(params));
|
||||
}
|
||||
|
||||
static toggleTrigger (params: { uid: string; schema: string; trigger: string }): Promise<IpcResponse> {
|
||||
static toggleTrigger (params: { uid: string; schema: string; trigger: string; enabled: boolean }): Promise<IpcResponse> {
|
||||
return ipcRenderer.invoke('toggle-trigger', unproxify(params));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user