Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface BaseCrudContext<T, C>

Type parameters

  • T

  • C

Hierarchy

Index

Properties

Optional bareData

bareData: any

Data sent by client, only available on Update

context

context: C

Http context you use in your application. Usually includes user, locale additional query parameters etc.

Optional data

data: any

Data sent by client to update or create resource. It represents the new, complete resource -- thusly when updating a single attribute,data contains not just the new attribute, but also all the attributes existing on the resource before the update.

In other words, data is entity with overwritten data sent by client. To get only data sent by client, see bareData.

Present in the following operations:

  • Create (data client provides to create a resource)
  • Update (client's data for update with attributes defaulting to existing resource)

Optional entity

entity: T

Existing resource client is manipulating. Present in the following operations:

  • Detail (entity client is trying to fetch)
  • Update (existing entity before the update)
  • Delete (entity client is trying to destroy)

options

options: any

Options passed to your data manipulation logic. Contains data from (1) context, (2) dynamic options from getOptions and (3) direct options passed on when creating a handler.

safe

safe: boolean

True for detail, list

type

type: Operation

write

write: boolean

True for create or update

Generated using TypeDoc