Skip to content
This repository was archived by the owner on Aug 18, 2018. It is now read-only.

Commit 640c591

Browse files
committed
some fixed for compatibily with version 0.4.x
1 parent 7f96146 commit 640c591

6 files changed

Lines changed: 10 additions & 12 deletions

File tree

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "ts-angular-jsonapi",
3-
"version": "0.5.0",
3+
"version": "0.5.5",
44
"description": "JSONAPI library developed for AngularJS in Typescript",
55
"repository": {
66
"type": "git",

src/library/index.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ import { Resource } from './resource';
3434
export { Core };
3535
export { Resource };
3636
export { Service };
37+
3738
export * from './interfaces';
3839
import { IResource } from './interfaces';
3940
import { IService } from './interfaces';

src/library/interfaces/exec-params.d.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import { IParamsCollection } from '../interfaces';
22

33
export interface IExecParams {
4-
id: string | null;
4+
id: string;
55
params?: IParamsCollection | Function;
66
fc_success?: Function;
77
fc_error?: Function;

src/library/services/service-with-requests.ts renamed to src/library/parent-resource-service.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
import { Base } from '../services/base';
2-
import { IExecParams } from '../interfaces';
1+
import { Base } from './services/base';
2+
import { IExecParams } from './interfaces';
33

4-
export abstract class ServiceWithRequests {
4+
export class ParentResourceService {
55
/**
66
This method sort params for all(), get(), delete() and save()
77
*/

src/library/resource.ts

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,17 +3,15 @@
33
// import * as Jsonapi from './core';
44
import { Core } from './core';
55
import { Base } from './services/base';
6-
import { ServiceWithRequests } from './services/service-with-requests';
6+
import { ParentResourceService } from './parent-resource-service';
77
import { PathBuilder } from './services/path-builder';
88
// import { UrlParamsBuilder } from './services/url-params-builder';
99
import { Converter } from './services/resource-converter';
10-
// import { LocalFilter } from './services/localfilter';
11-
// import { MemoryCache } from './services/memorycache';
1210

1311
import { IAttributes, IResource, ICollection, IExecParams, IParamsResource } from './interfaces';
1412
import { IRelationships, IRelationship } from './interfaces';
1513

16-
export class Resource extends ServiceWithRequests implements IResource {
14+
export class Resource extends ParentResourceService implements IResource {
1715
public is_new = true;
1816
public is_loading = false;
1917
public is_saving = false;

src/library/service.ts

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,17 +4,16 @@
44
import { Core } from './core';
55
import { Base } from './services/base';
66
import { Resource } from './resource';
7-
import { ServiceWithRequests } from './services/service-with-requests';
7+
import { ParentResourceService } from './parent-resource-service';
88
import { PathBuilder } from './services/path-builder';
99
import { UrlParamsBuilder } from './services/url-params-builder';
1010
import { Converter } from './services/resource-converter';
1111
import { LocalFilter } from './services/localfilter';
1212
import { MemoryCache } from './services/memorycache';
1313

1414
import { IService, ISchema, IResource, ICollection, IExecParams, ICache, IParamsCollection, IParamsResource } from './interfaces';
15-
// import { IRelationships, IRelationship } from './interfaces';
1615

17-
export class Service extends ServiceWithRequests implements IService {
16+
export class Service extends ParentResourceService implements IService {
1817
public is_new = true;
1918
public is_loading = false;
2019
public is_saving = false;

0 commit comments

Comments
 (0)