Model specialoffers


Permissions

User GroupCreate?Read?Update?Delete?
managerxxxx
line_managerxxxx
financexxxx
adminx
allx

Fields

NameTypeLinkMaps ToDefaultIndexed?Unique?Required?
__vNumber
_deletedBooleanfalsex
_idObjectID[Function]
_owner_idObjectIDUser_ownerx
_updated_by_idObjectIDUser_updated_byx
bodyString
createdAtDate
dateDate[Function]xx
descriptionString
end_dateDate[Function]x
imgString
linkString
location_idArray of ObjectID[Function]
nameStringxx
partnerString
partner_codeString
start_dateDate[Function]x
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": []
}

body

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

createdAt

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

date

{
  "path": "date",
  "instance": "Date",
  "options": {
    "required": true,
    "index": true
  },
  "validators": [
    {
      "message": "Path `{PATH}` is required."
    }
  ],
  "isRequired": true,
  "defaultValue": "[Function]"
}

Validators

description

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

end_date

{
  "path": "end_date",
  "instance": "Date",
  "options": {
    "index": true
  },
  "validators": [],
  "defaultValue": "[Function]"
}

img

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

link

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

location_id

{
  "path": "location_id",
  "instance": "Array",
  "options": {
    "type": [
      {
        "link": "Location"
      }
    ]
  },
  "validators": [],
  "defaultValue": "[Function]",
  "arrayType": "ObjectID"
}

name

{
  "path": "name",
  "instance": "String",
  "options": {
    "unique": true,
    "index": true
  },
  "validators": []
}

partner

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

partner_code

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

start_date

{
  "path": "start_date",
  "instance": "Date",
  "options": {
    "index": true
  },
  "validators": [],
  "defaultValue": "[Function]"
}

updatedAt

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