几个build的声明,不需要发布
This commit is contained in:
parent
101a8fd18a
commit
771e51caeb
|
|
@ -47,7 +47,7 @@ export declare type CommonAspectDict<ED extends EntityDict & BaseEntityDict, Cxt
|
|||
entity: T;
|
||||
id: string;
|
||||
filter?: ED[T]['Selection']['filter'];
|
||||
properties: Record<string, any>;
|
||||
properties?: Record<string, any>;
|
||||
}, context: Cxt) => Promise<ArrayBuffer>;
|
||||
getImportationTemplate: (params: {
|
||||
id: string;
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
import { EntityDict } from 'oak-domain/lib/types/Entity';
|
||||
import { Importation, Exportation } from 'oak-domain/lib/types/Port';
|
||||
import { AsyncContext } from 'oak-domain/lib/store/AsyncRowStore';
|
||||
export declare function registerPorts<ED extends EntityDict>(importations: Importation<ED, keyof ED, any>[], exportations: Exportation<ED, keyof ED>[]): void;
|
||||
export declare function registerPorts<ED extends EntityDict>(importations: Importation<ED, keyof ED, any>[], exportations: Exportation<ED, keyof ED, any>[]): void;
|
||||
export declare function clearPorts(): void;
|
||||
export declare function importEntity<ED extends EntityDict, Cxt extends AsyncContext<ED>>(params: {
|
||||
entity: string;
|
||||
|
|
|
|||
|
|
@ -67,7 +67,7 @@ export type CommonAspectDict<ED extends EntityDict & BaseEntityDict, Cxt extends
|
|||
entity: T;
|
||||
id: string;
|
||||
filter?: ED[T]['Selection']['filter'];
|
||||
properties: Record<string, any>;
|
||||
properties?: Record<string, any>;
|
||||
}, context: Cxt) => Promise<ArrayBuffer>;
|
||||
getImportationTemplate: (params: { id: string }, context: Cxt) => Promise<ArrayBuffer>;
|
||||
searchPoi: (options: {
|
||||
|
|
|
|||
|
|
@ -1,6 +0,0 @@
|
|||
import { AmapInstance } from 'oak-external-sdk';
|
||||
export declare function amap<T extends 'getDrivingPath' | 'regeo' | 'ipLoc' | 'getDistrict' | 'geocode'>(options: {
|
||||
key: string;
|
||||
method: T;
|
||||
data: Parameters<AmapInstance[T]>[0];
|
||||
}): Promise<any>;
|
||||
|
|
@ -8,7 +8,7 @@ import { Duplex } from 'stream';
|
|||
const Importations: Record<string, any> = {};
|
||||
const Exportations: Record<string, any> = {};
|
||||
|
||||
export function registerPorts<ED extends EntityDict>(importations: Importation<ED, keyof ED, any>[], exportations: Exportation<ED, keyof ED>[]) {
|
||||
export function registerPorts<ED extends EntityDict>(importations: Importation<ED, keyof ED, any>[], exportations: Exportation<ED, keyof ED, any>[]) {
|
||||
for (const i of importations) {
|
||||
assert(!Importations.hasOwnProperty(i.id), `Importation中的id【${i.id}】重复了`);
|
||||
Object.assign(Importations, {
|
||||
|
|
@ -40,7 +40,7 @@ function getImportation<ED extends EntityDict, T extends keyof ED>(id: string) {
|
|||
|
||||
function getExportation<ED extends EntityDict, T extends keyof ED>(id: string) {
|
||||
assert(Exportations.hasOwnProperty(id), `id为[${id}]的exportation不存在`);
|
||||
return Exportations[id] as Exportation<ED, T>;
|
||||
return Exportations[id] as Exportation<ED, T, any>;
|
||||
}
|
||||
|
||||
export async function importEntity<
|
||||
|
|
|
|||
Loading…
Reference in New Issue