@pax2pay/model-banking 0.0.31 → 0.0.33

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -11,7 +11,7 @@ export class Notes extends rest.Collection<gracely.Error> {
11
11
  organization: string,
12
12
  account: string,
13
13
  transaction: string,
14
- note: Transaction.Note
14
+ note: Transaction.Note.Creatable
15
15
  ): Promise<Transaction | gracely.Error> {
16
16
  return this.client.post<Transaction>(`/transaction/${transaction}/note`, note, {
17
17
  organization: organization,
@@ -1,4 +1,5 @@
1
1
  import * as isoly from "isoly"
2
+
2
3
  export interface Note extends Note.Creatable {
3
4
  author: string
4
5
  created: isoly.DateTime
@@ -8,13 +9,13 @@ export namespace Note {
8
9
  export function fromCreatable(note: Creatable, author: string): Note {
9
10
  return { ...note, created: isoly.DateTime.now(), author: author }
10
11
  }
11
- export namespace Creatable {
12
- export function is(value: Creatable | any): value is Note {
13
- return true
14
- }
15
- }
16
12
  export interface Creatable {
17
13
  text?: string
18
14
  action?: "approve" | "reject"
19
15
  }
16
+ export namespace Creatable {
17
+ export function is(value: Creatable | any): value is Creatable {
18
+ return true
19
+ }
20
+ }
20
21
  }
@@ -4,5 +4,5 @@ import * as rest from "cloudly-rest";
4
4
  import { Transaction } from "../../Transaction";
5
5
  export declare class Notes extends rest.Collection<gracely.Error> {
6
6
  constructor(client: http.Client);
7
- create(organization: string, account: string, transaction: string, note: Transaction.Note): Promise<Transaction | gracely.Error>;
7
+ create(organization: string, account: string, transaction: string, note: Transaction.Note.Creatable): Promise<Transaction | gracely.Error>;
8
8
  }
@@ -1 +1 @@
1
- {"version":3,"file":"Notes.js","sourceRoot":"../","sources":["Client/Transactions/Notes.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,IAAI,MAAM,cAAc,CAAA;AAGpC,MAAM,OAAO,KAAM,SAAQ,IAAI,CAAC,UAAyB;IACxD,YAAY,MAAmB;QAC9B,KAAK,CAAC,MAAM,CAAC,CAAA;IACd,CAAC;IACD,KAAK,CAAC,MAAM,CACX,YAAoB,EACpB,OAAe,EACf,WAAmB,EACnB,IAAsB;QAEtB,OAAO,IAAI,CAAC,MAAM,CAAC,IAAI,CAAc,gBAAgB,WAAW,OAAO,EAAE,IAAI,EAAE;YAC9E,YAAY,EAAE,YAAY;YAC1B,OAAO,EAAE,OAAO;SAChB,CAAC,CAAA;IACH,CAAC;CACD"}
1
+ {"version":3,"file":"Notes.js","sourceRoot":"../","sources":["Client/Transactions/Notes.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,IAAI,MAAM,cAAc,CAAA;AAGpC,MAAM,OAAO,KAAM,SAAQ,IAAI,CAAC,UAAyB;IACxD,YAAY,MAAmB;QAC9B,KAAK,CAAC,MAAM,CAAC,CAAA;IACd,CAAC;IACD,KAAK,CAAC,MAAM,CACX,YAAoB,EACpB,OAAe,EACf,WAAmB,EACnB,IAAgC;QAEhC,OAAO,IAAI,CAAC,MAAM,CAAC,IAAI,CAAc,gBAAgB,WAAW,OAAO,EAAE,IAAI,EAAE;YAC9E,YAAY,EAAE,YAAY;YAC1B,OAAO,EAAE,OAAO;SAChB,CAAC,CAAA;IACH,CAAC;CACD"}
@@ -5,11 +5,11 @@ export interface Note extends Note.Creatable {
5
5
  }
6
6
  export declare namespace Note {
7
7
  function fromCreatable(note: Creatable, author: string): Note;
8
- namespace Creatable {
9
- function is(value: Creatable | any): value is Note;
10
- }
11
8
  interface Creatable {
12
9
  text?: string;
13
10
  action?: "approve" | "reject";
14
11
  }
12
+ namespace Creatable {
13
+ function is(value: Creatable | any): value is Creatable;
14
+ }
15
15
  }
@@ -1 +1 @@
1
- {"version":3,"file":"Note.js","sourceRoot":"../","sources":["Transaction/Note.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAM9B,MAAM,KAAW,IAAI,CAapB;AAbD,WAAiB,IAAI;IACpB,SAAgB,aAAa,CAAC,IAAe,EAAE,MAAc;QAC5D,OAAO,EAAE,GAAG,IAAI,EAAE,OAAO,EAAE,KAAK,CAAC,QAAQ,CAAC,GAAG,EAAE,EAAE,MAAM,EAAE,MAAM,EAAE,CAAA;IAClE,CAAC;IAFe,kBAAa,gBAE5B,CAAA;IACD,IAAiB,SAAS,CAIzB;IAJD,WAAiB,SAAS;QACzB,SAAgB,EAAE,CAAC,KAAsB;YACxC,OAAO,IAAI,CAAA;QACZ,CAAC;QAFe,YAAE,KAEjB,CAAA;IACF,CAAC,EAJgB,SAAS,GAAT,cAAS,KAAT,cAAS,QAIzB;AAKF,CAAC,EAbgB,IAAI,KAAJ,IAAI,QAapB"}
1
+ {"version":3,"file":"Note.js","sourceRoot":"../","sources":["Transaction/Note.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAO9B,MAAM,KAAW,IAAI,CAapB;AAbD,WAAiB,IAAI;IACpB,SAAgB,aAAa,CAAC,IAAe,EAAE,MAAc;QAC5D,OAAO,EAAE,GAAG,IAAI,EAAE,OAAO,EAAE,KAAK,CAAC,QAAQ,CAAC,GAAG,EAAE,EAAE,MAAM,EAAE,MAAM,EAAE,CAAA;IAClE,CAAC;IAFe,kBAAa,gBAE5B,CAAA;IAKD,IAAiB,SAAS,CAIzB;IAJD,WAAiB,SAAS;QACzB,SAAgB,EAAE,CAAC,KAAsB;YACxC,OAAO,IAAI,CAAA;QACZ,CAAC;QAFe,YAAE,KAEjB,CAAA;IACF,CAAC,EAJgB,SAAS,GAAT,cAAS,KAAT,cAAS,QAIzB;AACF,CAAC,EAbgB,IAAI,KAAJ,IAAI,QAapB"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pax2pay/model-banking",
3
- "version": "0.0.31",
3
+ "version": "0.0.33",
4
4
  "description": "Library containing data model types and functions for the Pax2Pay Banking API.",
5
5
  "author": "Pax2Pay Ltd",
6
6
  "license": "MIT",