Class: CategoryEntity

Entity.CategoryEntity(idopt, labelopt, coloropt, createdAtopt, updatedAtopt)

Category entity.

Constructor

new CategoryEntity(idopt, labelopt, coloropt, createdAtopt, updatedAtopt)

Parameters:
Name Type Attributes Default Description
id string <optional>
null Category UUID.
label string <optional>
'' Label of response. Size: 2-256 characters.
color string <optional>
'#e3e3e3' Hexadecimal color with 7 characters (including '#', e.g.: '#ff00ff').
createdAt Date <optional>
new Date() Creation date.
updatedAt Date <optional>
null Last update Date.
Author:
  • Bruno Morceli - pirofagista@gmail.com
Source:

Extends

Members

color

Properties:
Name Type Description
color string Hexadecimal color with 7 characters (including '#', e.g.: '#ff00ff').
Source:

createdAt

Properties:
Name Type Description
createdAt Date Creation date.
Source:

id

Properties:
Name Type Description
id string Category UUID.
Source:

label

Properties:
Name Type Description
label string Label of response. Size: 2-256 characters.
Source:

updatedAt

Properties:
Name Type Description
updatedAt Date Last update Date.
Source:

Methods

setData(rawData) → {this}

Set all fields of a object.
Parameters:
Name Type Description
rawData object Raw data containing all object information.
Inherited From:
Source:
Returns:
Current context.
Type
this

toJSON() → {object}

Create a new JavaScript Object Literal containing all class properties.
Inherited From:
Source:
Returns:
Type
object