Model producttypes


Permissions

User GroupCreate?Read?Update?Delete?
setupxxxx
adminx
allx

Fields

NameTypeLinkMaps ToDefaultIndexed?Unique?Required?
__vNumber
_deletedBooleanfalsex
_idObjectID[Function]
_owner_idObjectIDUser_ownerx
_updated_by_idObjectIDUser_updated_byx
bookableBooleanfalse
bookable_nounString
bookable_time_unitsNumber
createdAtDate
currency_idObjectIDCurrencyx
fire_actionString
include_in_occupancy_reportBooleanfalsex
nameStringxx
price_recommendation_formulaString
typeStringotherx
updatedAtDate

Field Details

__v

{
  "path": "__v",
  "instance": "Number",
  "options": {},
  "validators": []
}

_deleted

{
  "path": "_deleted",
  "instance": "Boolean",
  "options": {
    "default": false,
    "index": true
  },
  "validators": [],
  "defaultValue": false
}

_id

{
  "path": "_id",
  "instance": "ObjectID",
  "options": {
    "auto": true,
    "type": "ObjectId"
  },
  "validators": [],
  "defaultValue": "[Function]"
}

_owner_id

{
  "path": "_owner_id",
  "instance": "ObjectID",
  "options": {
    "link": "User",
    "map_to": "_owner",
    "index": true
  },
  "validators": []
}

_updated_by_id

{
  "path": "_updated_by_id",
  "instance": "ObjectID",
  "options": {
    "link": "User",
    "map_to": "_updated_by",
    "index": true
  },
  "validators": []
}

bookable

{
  "path": "bookable",
  "instance": "Boolean",
  "options": {
    "default": false
  },
  "validators": [],
  "defaultValue": false
}

bookable_noun

{
  "path": "bookable_noun",
  "instance": "String",
  "options": {},
  "validators": []
}

bookable_time_units

{
  "path": "bookable_time_units",
  "instance": "Number",
  "options": {},
  "validators": []
}

createdAt

{
  "path": "createdAt",
  "instance": "Date",
  "options": {
    "immutable": true
  },
  "validators": []
}

currency_id

{
  "path": "currency_id",
  "instance": "ObjectID",
  "options": {
    "index": true,
    "link": "Currency"
  },
  "validators": []
}

fire_action

{
  "path": "fire_action",
  "instance": "String",
  "options": {},
  "validators": []
}

include_in_occupancy_report

{
  "path": "include_in_occupancy_report",
  "instance": "Boolean",
  "options": {
    "default": false,
    "index": true
  },
  "validators": [],
  "defaultValue": false
}

name

{
  "path": "name",
  "instance": "String",
  "options": {
    "required": true,
    "index": true
  },
  "validators": [
    {
      "message": "Path `{PATH}` is required."
    }
  ],
  "isRequired": true
}

Validators

price_recommendation_formula

{
  "path": "price_recommendation_formula",
  "instance": "String",
  "options": {},
  "validators": []
}

type

{
  "path": "type",
  "instance": "String",
  "options": {
    "validate": {},
    "index": true,
    "default": "other"
  },
  "validators": [
    {
      "message": "Validator failed for path `{PATH}` with value `{VALUE}`"
    }
  ],
  "defaultValue": "other"
}

Validators

updatedAt

{
  "path": "updatedAt",
  "instance": "Date",
  "options": {},
  "validators": []
}