diff --git a/src/Property.ts b/src/Property.ts index c44864c6..a6aff8aa 100644 --- a/src/Property.ts +++ b/src/Property.ts @@ -5,7 +5,7 @@ import { DATA_TYPES } from './utils/data-types' export class Property extends BaseProperty { public column: ColumnMetadata; - private columnPosition: number; + protected columnPosition: number; constructor(column: ColumnMetadata, columnPosition = 0) { const path = column.propertyPath diff --git a/src/Resource.ts b/src/Resource.ts index 8f3f47d2..8bfe3f0a 100644 --- a/src/Resource.ts +++ b/src/Resource.ts @@ -11,9 +11,9 @@ type ParamsType = Record; export class Resource extends BaseResource { public static validate: any; - private model: typeof BaseEntity; + protected model: typeof BaseEntity; - private propsObject: Record = {}; + protected propsObject: Record = {}; constructor(model: typeof BaseEntity) { super(model) @@ -135,7 +135,7 @@ export class Resource extends BaseResource { } } - private prepareProps() { + protected prepareProps() { const { columns } = this.model.getRepository().metadata return columns.reduce((memo, col, index) => { const property = new Property(col, index) @@ -147,7 +147,7 @@ export class Resource extends BaseResource { } /** Converts params from string to final type */ - private prepareParams(params: Record): Record { + protected prepareParams(params: Record): Record { const preparedParams: Record = { ...params } this.properties().forEach((property) => {