UNPKG

@xompass/sdk-cloud-api

Version:

Xompass Client for cloud-api

95 lines 2.71 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.Control = void 0; var Control = /** @class */ (function () { function Control(data) { Object.assign(this, data); } /** * The name of the model represented by this $resource, * i.e. `Control`. */ Control.getModelName = function () { return 'Control'; }; /** * @method factory * @author Jonathan Casarrubias * @license MIT * This method creates an instance of Control for dynamic purposes. */ Control.factory = function (data) { return new Control(data); }; /** * @method getModelDefinition * @author Julien Ledun * @license MIT * This method returns an object that represents some of the model * definitions. */ Control.getModelDefinition = function () { return { name: 'Control', plural: 'Controls', path: 'Controls', idName: 'id', properties: { name: { name: 'name', type: 'string' }, enabled: { name: 'enabled', type: 'boolean' }, properties: { name: 'properties', type: 'any' }, created: { name: 'created', type: 'Date' }, modified: { name: 'modified', type: 'Date' }, deleted: { name: 'deleted', type: 'Date', default: undefined }, id: { name: 'id', type: 'any' }, assetId: { name: 'assetId', type: 'any' }, }, relations: { asset: { name: 'asset', type: 'Asset', model: 'Asset', relationType: 'belongsTo', keyFrom: 'assetId', keyTo: 'id' }, trackingLogs: { name: 'trackingLogs', type: 'Log[]', model: 'Log', relationType: 'hasMany', keyFrom: 'id', keyTo: 'trackingModelId' }, } }; }; return Control; }()); exports.Control = Control; //# sourceMappingURL=Control.js.map