Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

Index

Constructors

Properties

Methods

Constructors

constructor

  • Returns default

Properties

$modelClass

$modelClass: ModelClass<default>

QueryBuilderType

QueryBuilderType: QueryBuilder<default, Titres[]>

Optional activites

activites: null | ITitreActivite[]

Optional activitesAbsentes

activitesAbsentes: null | number

Optional activitesDeposees

activitesDeposees: null | number

Optional activitesEnConstruction

activitesEnConstruction: null | number

Optional administrations

administrations: null | IAdministration[]

Optional administrationsGestionnaires

administrationsGestionnaires: null | IAdministration[]

Optional administrationsLocales

administrationsLocales: null | IAdministration[]

Optional amodiataires

amodiataires: null | ITitreEntreprise[]

archive

archive: boolean

Optional communes

communes: null | ICommune[]

Optional confidentiel

confidentiel: null | boolean

Optional contenu

contenu: null | IContenu

Optional contenusTitreEtapesIds

contenusTitreEtapesIds: null | IContenusTitreEtapesIds

Optional coordonnees

coordonnees: null | ICoordonnees

Optional dateDebut

dateDebut: null | string

Optional dateDemande

dateDemande: null | string

Optional dateFin

dateFin: null | string

Optional demarches

demarches: ITitreDemarche[]

Optional demarchesCreation

demarchesCreation: null | boolean

Optional domaine

domaine: null | IDomaine

domaineId

domaineId: string

Optional doublonTitreId

doublonTitreId: null | string

Optional entreprisesLecture

entreprisesLecture: null | boolean

Optional forets

forets: null | IForet[]

Optional geojsonCentre

geojsonCentre: null | IGeoJsonCentre

Optional geojsonMultiPolygon

geojsonMultiPolygon: null | IGeoJson

Optional geojsonPoints

geojsonPoints: null | IGeoJson

id

id: string

Optional modification

modification: null | boolean

nom

nom: string

Optional pays

pays: null | IPays[]

Optional points

points: null | ITitrePoint[]

propsTitreEtapesIds

propsTitreEtapesIds: IPropsTitreEtapesIds

Optional publicLecture

publicLecture: null | boolean

Optional references

references: null | ITitreReference[]

Optional sdomZones

sdomZones: null | ISDOMZone[]

Optional slug

slug: string

Optional statut

statut: null | ITitreStatut

Optional statutId

statutId: null | string

Optional substances

substances: null | ITitreSubstance[]

Optional suppression

suppression: null | boolean

Optional surface

surface: null | number

Optional surfaceEtape

surfaceEtape: null | ITitreEtape

Optional titresAdministrations

titresAdministrations: null | IAdministration[]

Optional titulaires

titulaires: null | ITitreEntreprise[]

Optional travauxCreation

travauxCreation: null | boolean

Optional type

type: null | ITitreType

typeId

typeId: string

Static BelongsToOneRelation

BelongsToOneRelation: RelationType

Static HasManyRelation

HasManyRelation: RelationType

Static HasOneRelation

HasOneRelation: RelationType

Static HasOneThroughRelation

HasOneThroughRelation: RelationType

Static ManyToManyRelation

ManyToManyRelation: RelationType

Static QueryBuilder

QueryBuilder: typeof QueryBuilder

Static columnNameMappers

columnNameMappers: ColumnNameMappers

Static dbRefProp

dbRefProp: string

Static Optional defaultGraphOptions

defaultGraphOptions: GraphOptions

Static fn

fn: FunctionFunction

Static idColumn

idColumn: string | string[]

Static jsonAttributes

jsonAttributes: string[]

Static jsonSchema

jsonSchema: { properties: { archive: { type: string }; contenusTitreEtapesIds: { type: string[] }; coordonnees: { properties: { x: { type: string }; y: { type: string } }; type: string[] }; dateDebut: { type: string[] }; dateDemande: { type: string[] }; dateFin: { type: string[] }; domaineId: { maxLength: number; type: string }; doublonTitreId: { type: string[] }; id: { type: string }; nom: { type: string }; propsTitreEtapesIds: { type: string }; slug: { type: string }; statutId: { maxLength: number; type: string }; typeId: { maxLength: number; type: string } }; required: string[]; type: string } = ...

Type declaration

  • properties: { archive: { type: string }; contenusTitreEtapesIds: { type: string[] }; coordonnees: { properties: { x: { type: string }; y: { type: string } }; type: string[] }; dateDebut: { type: string[] }; dateDemande: { type: string[] }; dateFin: { type: string[] }; domaineId: { maxLength: number; type: string }; doublonTitreId: { type: string[] }; id: { type: string }; nom: { type: string }; propsTitreEtapesIds: { type: string }; slug: { type: string }; statutId: { maxLength: number; type: string }; typeId: { maxLength: number; type: string } }
    • archive: { type: string }
      • type: string
    • contenusTitreEtapesIds: { type: string[] }
      • type: string[]
    • coordonnees: { properties: { x: { type: string }; y: { type: string } }; type: string[] }
      • properties: { x: { type: string }; y: { type: string } }
        • x: { type: string }
          • type: string
        • y: { type: string }
          • type: string
      • type: string[]
    • dateDebut: { type: string[] }
      • type: string[]
    • dateDemande: { type: string[] }
      • type: string[]
    • dateFin: { type: string[] }
      • type: string[]
    • domaineId: { maxLength: number; type: string }
      • maxLength: number
      • type: string
    • doublonTitreId: { type: string[] }
      • type: string[]
    • id: { type: string }
      • type: string
    • nom: { type: string }
      • type: string
    • propsTitreEtapesIds: { type: string }
      • type: string
    • slug: { type: string }
      • type: string
    • statutId: { maxLength: number; type: string }
      • maxLength: number
      • type: string
    • typeId: { maxLength: number; type: string }
      • maxLength: number
      • type: string
  • required: string[]
  • type: string

Static modelPaths

modelPaths: string[]

Static modifiers

modifiers: Modifiers<AnyQueryBuilder>

Static pickJsonSchemaProperties

pickJsonSchemaProperties: boolean

Static propRefRegex

propRefRegex: RegExp

Static raw

raw: RawFunction

Static ref

ref: ReferenceFunction

Static relatedFindQueryMutates

relatedFindQueryMutates: boolean

Static relatedInsertQueryMutates

relatedInsertQueryMutates: boolean

Static tableName

tableName: string = 'titres'

Static uidProp

uidProp: string

Static uidRefProp

uidRefProp: string

Static useLimitInFirst

useLimitInFirst: boolean

Static virtualAttributes

virtualAttributes: string[]

Methods

$afterDelete

  • $afterDelete(queryContext: QueryContext): void | Promise<any>

$afterFind

  • $afterFind(): void

$afterGet

  • $afterGet(queryContext: QueryContext): void | Promise<any>

$afterInsert

  • $afterInsert(queryContext: QueryContext): void | Promise<any>

$afterUpdate

  • $afterUpdate(opt: ModelOptions, queryContext: QueryContext): void | Promise<any>

$afterValidate

  • $afterValidate(json: Pojo, opt: ModelOptions): void

$appendRelated

  • $appendRelated<RM>(relation: String | Relation, related: undefined | null | RM | RM[]): default

$beforeDelete

  • $beforeDelete(queryContext: QueryContext): void | Promise<any>

$beforeInsert

  • $beforeInsert(context: QueryContext): Promise<any>

$beforeUpdate

  • $beforeUpdate(opt: ModelOptions, queryContext: QueryContext): void | Promise<any>

$beforeValidate

  • $beforeValidate(jsonSchema: JSONSchema, json: Pojo, opt: ModelOptions): JSONSchema

$clone

  • $clone(opt?: CloneOptions): default

$fetchGraph

  • $fetchGraph(expression: RelationExpression<M>, options?: FetchGraphOptions): QueryBuilder<default, default>

$formatDatabaseJson

  • $formatDatabaseJson(json: Pojo): Pojo

$formatJson

  • $formatJson(json: Pojo): Pojo

$id

  • $id(id: any): void
  • $id(): any

$knex

  • $knex(): Knex<any, Record<string, any>[]>

$omit

  • $omit(keys: string | string[] | {}): default

$parseDatabaseJson

  • $parseDatabaseJson(json: Pojo): Pojo

$parseJson

  • $parseJson(json: Pojo): Pojo

$pick

  • $pick(keys: string | string[] | {}): default

$query

  • $query(trxOrKnex?: TransactionOrKnex): QueryBuilder<default, default>

$relatedQuery

  • $relatedQuery<K>(relationName: K, trxOrKnex?: TransactionOrKnex): RelatedQueryBuilder<default[K]>
  • $relatedQuery<RM>(relationName: string, trxOrKnex?: TransactionOrKnex): QueryBuilderType<RM>

$set

$setDatabaseJson

  • $setDatabaseJson(json: object): default

$setJson

  • $setJson(json: object, opt?: ModelOptions): default

$setRelated

  • $setRelated<RM>(relation: String | Relation, related: undefined | null | RM | RM[]): default

$toDatabaseJson

  • $toDatabaseJson(): Pojo

$toJson

  • $toJson(opt?: ToJsonOptions): ModelObject<default>

$transaction

  • $transaction(): Knex<any, Record<string, any>[]>

$traverse

  • $traverse(filterConstructor: typeof Model, traverser: TraverserFunction): default
  • $traverse(traverser: TraverserFunction): default

$traverseAsync

  • $traverseAsync(filterConstructor: typeof Model, traverser: TraverserFunction): Promise<default>
  • $traverseAsync(traverser: TraverserFunction): Promise<default>

$validate

  • $validate(json?: Pojo, opt?: ModelOptions): Pojo

toJSON

  • toJSON(opt?: ToJsonOptions): ModelObject<default>

Static afterDelete

  • afterDelete(args: StaticHookArguments<any, any>): any

Static afterFind

  • afterFind(args: StaticHookArguments<any, any>): any

Static afterInsert

  • afterInsert(args: StaticHookArguments<any, any>): any

Static afterUpdate

  • afterUpdate(args: StaticHookArguments<any, any>): any

Static beforeDelete

  • beforeDelete(args: StaticHookArguments<any, any>): any

Static beforeFind

  • beforeFind(args: StaticHookArguments<any, any>): any

Static beforeInsert

  • beforeInsert(args: StaticHookArguments<any, any>): any

Static beforeUpdate

  • beforeUpdate(args: StaticHookArguments<any, any>): any

Static bindKnex

  • bindKnex<M>(trxOrKnex: TransactionOrKnex): M

Static bindTransaction

  • bindTransaction<M>(trxOrKnex: TransactionOrKnex): M

Static createNotFoundError

  • createNotFoundError(queryContext: QueryContext, args: CreateNotFoundErrorArgs): Error

Static createValidationError

  • createValidationError(args: CreateValidationErrorArgs): Error

Static createValidator

  • createValidator(): Validator

Static fetchGraph

  • fetchGraph<M>(modelOrObject: PartialModelObject<M>, expression: RelationExpression<M>, options?: FetchGraphOptions): SingleQueryBuilder<QueryBuilderType<M>>
  • fetchGraph<M>(modelOrObject: PartialModelObject<M>[], expression: RelationExpression<M>, options?: FetchGraphOptions): QueryBuilderType<M>

Static fetchTableMetadata

  • fetchTableMetadata(opt?: FetchTableMetadataOptions): Promise<TableMetadata>

Static fromDatabaseJson

  • fromDatabaseJson<M>(json: object): M

Static fromJson

  • fromJson<M>(json: object, opt?: ModelOptions): M

Static getRelation

  • getRelation(name: string): Relation

Static getRelations

  • getRelations(): Relations

Static knex

  • knex(knex?: Knex<any, Record<string, any>[]>): Knex<any, Record<string, any>[]>

Static knexQuery

  • knexQuery(): QueryBuilder<any, any>

Static query

  • query<M>(trxOrKnex?: TransactionOrKnex): QueryBuilderType<M>

Static relatedQuery

  • relatedQuery<M, K>(relationName: K, trxOrKnex?: TransactionOrKnex): ArrayRelatedQueryBuilder<M[K]>
  • relatedQuery<RM>(relationName: string, trxOrKnex?: TransactionOrKnex): QueryBuilderType<RM>

Static relationMappings

  • relationMappings(): { activites: { join: { from: string; to: string }; modelClass: typeof default; relation: RelationType }; administrationsGestionnaires: { join: { from: string; through: { extra: string[]; from: ReferenceBuilder; to: string }; to: string }; modelClass: typeof default; relation: RelationType }; administrationsLocales: { join: { from: ReferenceBuilder; through: { extra: string[]; from: string; to: string }; to: string }; modelClass: typeof default; relation: RelationType }; amodiataires: { join: { from: ReferenceBuilder; through: { extra: string[]; from: string; to: string }; to: string }; modelClass: typeof default; relation: RelationType }; communes: { join: { from: ReferenceBuilder; through: { extra: string[]; from: string; to: string }; to: string }; modelClass: typeof default; relation: RelationType }; demarches: { join: { from: string; to: string }; modelClass: typeof default; relation: RelationType }; domaine: { join: { from: string; to: string }; modelClass: typeof default; relation: RelationType }; doublonTitre: { join: { from: string; to: string }; modelClass: typeof default; relation: RelationType }; forets: { join: { from: ReferenceBuilder; through: { extra: string[]; from: string; to: string }; to: string }; modelClass: typeof default; relation: RelationType }; points: { join: { from: ReferenceBuilder; to: string }; modelClass: typeof default; relation: RelationType }; references: { join: { from: string; to: string }; modelClass: typeof default; relation: RelationType }; sdomZones: { join: { from: ReferenceBuilder; through: { extra: string[]; from: string; to: string }; to: string }; modelClass: typeof default; relation: RelationType }; statut: { join: { from: string; to: string }; modelClass: typeof default; relation: RelationType }; substances: { join: { from: ReferenceBuilder; through: { extra: string[]; from: string; to: string }; to: string }; modelClass: typeof default; relation: RelationType }; surfaceEtape: { join: { from: ReferenceBuilder; to: string }; modelClass: typeof default; relation: RelationType }; titresAdministrations: { join: { from: string; through: { from: string; to: string }; to: string }; modelClass: typeof default; relation: RelationType }; titulaires: { join: { from: ReferenceBuilder; through: { extra: string[]; from: string; to: string }; to: string }; modelClass: typeof default; relation: RelationType }; type: { join: { from: string; to: string }; modelClass: typeof default; relation: RelationType } }
  • Returns { activites: { join: { from: string; to: string }; modelClass: typeof default; relation: RelationType }; administrationsGestionnaires: { join: { from: string; through: { extra: string[]; from: ReferenceBuilder; to: string }; to: string }; modelClass: typeof default; relation: RelationType }; administrationsLocales: { join: { from: ReferenceBuilder; through: { extra: string[]; from: string; to: string }; to: string }; modelClass: typeof default; relation: RelationType }; amodiataires: { join: { from: ReferenceBuilder; through: { extra: string[]; from: string; to: string }; to: string }; modelClass: typeof default; relation: RelationType }; communes: { join: { from: ReferenceBuilder; through: { extra: string[]; from: string; to: string }; to: string }; modelClass: typeof default; relation: RelationType }; demarches: { join: { from: string; to: string }; modelClass: typeof default; relation: RelationType }; domaine: { join: { from: string; to: string }; modelClass: typeof default; relation: RelationType }; doublonTitre: { join: { from: string; to: string }; modelClass: typeof default; relation: RelationType }; forets: { join: { from: ReferenceBuilder; through: { extra: string[]; from: string; to: string }; to: string }; modelClass: typeof default; relation: RelationType }; points: { join: { from: ReferenceBuilder; to: string }; modelClass: typeof default; relation: RelationType }; references: { join: { from: string; to: string }; modelClass: typeof default; relation: RelationType }; sdomZones: { join: { from: ReferenceBuilder; through: { extra: string[]; from: string; to: string }; to: string }; modelClass: typeof default; relation: RelationType }; statut: { join: { from: string; to: string }; modelClass: typeof default; relation: RelationType }; substances: { join: { from: ReferenceBuilder; through: { extra: string[]; from: string; to: string }; to: string }; modelClass: typeof default; relation: RelationType }; surfaceEtape: { join: { from: ReferenceBuilder; to: string }; modelClass: typeof default; relation: RelationType }; titresAdministrations: { join: { from: string; through: { from: string; to: string }; to: string }; modelClass: typeof default; relation: RelationType }; titulaires: { join: { from: ReferenceBuilder; through: { extra: string[]; from: string; to: string }; to: string }; modelClass: typeof default; relation: RelationType }; type: { join: { from: string; to: string }; modelClass: typeof default; relation: RelationType } }

    • activites: { join: { from: string; to: string }; modelClass: typeof default; relation: RelationType }
      • join: { from: string; to: string }
        • from: string
        • to: string
      • modelClass: typeof default
      • relation: RelationType
    • administrationsGestionnaires: { join: { from: string; through: { extra: string[]; from: ReferenceBuilder; to: string }; to: string }; modelClass: typeof default; relation: RelationType }
      • join: { from: string; through: { extra: string[]; from: ReferenceBuilder; to: string }; to: string }
        • from: string
        • through: { extra: string[]; from: ReferenceBuilder; to: string }
          • extra: string[]
          • from: ReferenceBuilder
          • to: string
        • to: string
      • modelClass: typeof default
      • relation: RelationType
    • administrationsLocales: { join: { from: ReferenceBuilder; through: { extra: string[]; from: string; to: string }; to: string }; modelClass: typeof default; relation: RelationType }
      • join: { from: ReferenceBuilder; through: { extra: string[]; from: string; to: string }; to: string }
        • from: ReferenceBuilder
        • through: { extra: string[]; from: string; to: string }
          • extra: string[]
          • from: string
          • to: string
        • to: string
      • modelClass: typeof default
      • relation: RelationType
    • amodiataires: { join: { from: ReferenceBuilder; through: { extra: string[]; from: string; to: string }; to: string }; modelClass: typeof default; relation: RelationType }
      • join: { from: ReferenceBuilder; through: { extra: string[]; from: string; to: string }; to: string }
        • from: ReferenceBuilder
        • through: { extra: string[]; from: string; to: string }
          • extra: string[]
          • from: string
          • to: string
        • to: string
      • modelClass: typeof default
      • relation: RelationType
    • communes: { join: { from: ReferenceBuilder; through: { extra: string[]; from: string; to: string }; to: string }; modelClass: typeof default; relation: RelationType }
      • join: { from: ReferenceBuilder; through: { extra: string[]; from: string; to: string }; to: string }
        • from: ReferenceBuilder
        • through: { extra: string[]; from: string; to: string }
          • extra: string[]
          • from: string
          • to: string
        • to: string
      • modelClass: typeof default
      • relation: RelationType
    • demarches: { join: { from: string; to: string }; modelClass: typeof default; relation: RelationType }
      • join: { from: string; to: string }
        • from: string
        • to: string
      • modelClass: typeof default
      • relation: RelationType
    • domaine: { join: { from: string; to: string }; modelClass: typeof default; relation: RelationType }
      • join: { from: string; to: string }
        • from: string
        • to: string
      • modelClass: typeof default
      • relation: RelationType
    • doublonTitre: { join: { from: string; to: string }; modelClass: typeof default; relation: RelationType }
      • join: { from: string; to: string }
        • from: string
        • to: string
      • modelClass: typeof default
      • relation: RelationType
    • forets: { join: { from: ReferenceBuilder; through: { extra: string[]; from: string; to: string }; to: string }; modelClass: typeof default; relation: RelationType }
      • join: { from: ReferenceBuilder; through: { extra: string[]; from: string; to: string }; to: string }
        • from: ReferenceBuilder
        • through: { extra: string[]; from: string; to: string }
          • extra: string[]
          • from: string
          • to: string
        • to: string
      • modelClass: typeof default
      • relation: RelationType
    • points: { join: { from: ReferenceBuilder; to: string }; modelClass: typeof default; relation: RelationType }
      • join: { from: ReferenceBuilder; to: string }
        • from: ReferenceBuilder
        • to: string
      • modelClass: typeof default
      • relation: RelationType
    • references: { join: { from: string; to: string }; modelClass: typeof default; relation: RelationType }
      • join: { from: string; to: string }
        • from: string
        • to: string
      • modelClass: typeof default
      • relation: RelationType
    • sdomZones: { join: { from: ReferenceBuilder; through: { extra: string[]; from: string; to: string }; to: string }; modelClass: typeof default; relation: RelationType }
      • join: { from: ReferenceBuilder; through: { extra: string[]; from: string; to: string }; to: string }
        • from: ReferenceBuilder
        • through: { extra: string[]; from: string; to: string }
          • extra: string[]
          • from: string
          • to: string
        • to: string
      • modelClass: typeof default
      • relation: RelationType
    • statut: { join: { from: string; to: string }; modelClass: typeof default; relation: RelationType }
      • join: { from: string; to: string }
        • from: string
        • to: string
      • modelClass: typeof default
      • relation: RelationType
    • substances: { join: { from: ReferenceBuilder; through: { extra: string[]; from: string; to: string }; to: string }; modelClass: typeof default; relation: RelationType }
      • join: { from: ReferenceBuilder; through: { extra: string[]; from: string; to: string }; to: string }
        • from: ReferenceBuilder
        • through: { extra: string[]; from: string; to: string }
          • extra: string[]
          • from: string
          • to: string
        • to: string
      • modelClass: typeof default
      • relation: RelationType
    • surfaceEtape: { join: { from: ReferenceBuilder; to: string }; modelClass: typeof default; relation: RelationType }
      • join: { from: ReferenceBuilder; to: string }
        • from: ReferenceBuilder
        • to: string
      • modelClass: typeof default
      • relation: RelationType
    • titresAdministrations: { join: { from: string; through: { from: string; to: string }; to: string }; modelClass: typeof default; relation: RelationType }
      • join: { from: string; through: { from: string; to: string }; to: string }
        • from: string
        • through: { from: string; to: string }
          • from: string
          • to: string
        • to: string
      • modelClass: typeof default
      • relation: RelationType
    • titulaires: { join: { from: ReferenceBuilder; through: { extra: string[]; from: string; to: string }; to: string }; modelClass: typeof default; relation: RelationType }
      • join: { from: ReferenceBuilder; through: { extra: string[]; from: string; to: string }; to: string }
        • from: ReferenceBuilder
        • through: { extra: string[]; from: string; to: string }
          • extra: string[]
          • from: string
          • to: string
        • to: string
      • modelClass: typeof default
      • relation: RelationType
    • type: { join: { from: string; to: string }; modelClass: typeof default; relation: RelationType }
      • join: { from: string; to: string }
        • from: string
        • to: string
      • modelClass: typeof default
      • relation: RelationType

Static startTransaction

  • startTransaction(knexOrTransaction?: TransactionOrKnex): Promise<Transaction>

Static tableMetadata

  • tableMetadata(opt?: TableMetadataOptions): TableMetadata

Static transaction

  • transaction<T>(callback: (trx: Transaction) => Promise<T>): Promise<T>
  • transaction<T>(trxOrKnex: TransactionOrKnex, callback: (trx: Transaction) => Promise<T>): Promise<T>

Static traverse

  • traverse(models: Model | Model[], traverser: TraverserFunction): void
  • traverse(filterConstructor: typeof Model, models: Model | Model[], traverser: TraverserFunction): void

Static traverseAsync

  • traverseAsync(models: Model | Model[], traverser: TraverserFunction): Promise<void>
  • traverseAsync(filterConstructor: typeof Model, models: Model | Model[], traverser: TraverserFunction): Promise<void>

Generated using TypeDoc