Files
owl/web/static/src/ts/core/ajax.ts
T
2019-02-02 16:30:34 +01:00

23 lines
596 B
TypeScript

//------------------------------------------------------------------------------
// Types
//------------------------------------------------------------------------------
export interface RPCQuery {
model: string;
method: string;
args: any;
}
export interface IAjax {
rpc(rpc: RPCQuery): Promise<any>;
}
//------------------------------------------------------------------------------
// Ajax
//------------------------------------------------------------------------------
export class Ajax implements IAjax {
rpc(rpc: RPCQuery): Promise<any> {
return Promise.resolve(1);
}
}