@carbonorm/carbonnode 2.0.9 → 2.0.10

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.
@@ -47,9 +47,9 @@ export interface iRestApiFunctions<RestData = any> {
47
47
  }
48
48
  export interface iDynamicApiImport<RestData = any> {
49
49
  default: iRestApiFunctions<RestData>;
50
- postState: (response: AxiosResponse<iPostC6RestResponse<RestData>>, request: iAPI<any>, id: string | number | boolean) => void;
51
- deleteState: (response: AxiosResponse<iDeleteC6RestResponse<RestData>>, request: iAPI<any>) => void;
52
- putState: (response: AxiosResponse<iPutC6RestResponse<RestData>>, request: iAPI<any>) => void;
50
+ postState?: (response: AxiosResponse<iPostC6RestResponse<RestData>>, request: iAPI<any>, id: string | number | boolean) => void;
51
+ deleteState?: (response: AxiosResponse<iDeleteC6RestResponse<RestData>>, request: iAPI<any>) => void;
52
+ putState?: (response: AxiosResponse<iPutC6RestResponse<RestData>>, request: iAPI<any>) => void;
53
53
  }
54
54
  export interface tC6Tables {
55
55
  [key: string]: (iC6RestfulModel & {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@carbonorm/carbonnode",
3
- "version": "2.0.9",
3
+ "version": "2.0.10",
4
4
  "main": "dist/index.cjs.js",
5
5
  "module": "dist/index.esm.js",
6
6
  "browser": "dist/index.umd.js",
@@ -58,9 +58,10 @@ export interface iRestApiFunctions<RestData = any> {
58
58
 
59
59
  export interface iDynamicApiImport<RestData = any> {
60
60
  default: iRestApiFunctions<RestData>
61
- postState: (response: AxiosResponse<iPostC6RestResponse<RestData>>, request: iAPI<any>, id: string | number | boolean) => void,
62
- deleteState: (response: AxiosResponse<iDeleteC6RestResponse<RestData>>, request: iAPI<any>) => void,
63
- putState: (response: AxiosResponse<iPutC6RestResponse<RestData>>, request: iAPI<any>) => void
61
+ // the methods below are optional
62
+ postState?: (response: AxiosResponse<iPostC6RestResponse<RestData>>, request: iAPI<any>, id: string | number | boolean) => void,
63
+ deleteState?: (response: AxiosResponse<iDeleteC6RestResponse<RestData>>, request: iAPI<any>) => void,
64
+ putState?: (response: AxiosResponse<iPutC6RestResponse<RestData>>, request: iAPI<any>) => void
64
65
  }
65
66
 
66
67
  export interface tC6Tables { [key: string]: (iC6RestfulModel & { [key: string]: any }) }