@xompass/sdk-cloud-api
Version:
Xompass Client for cloud-api
109 lines • 3.18 kB
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.BIPanel = void 0;
var BIPanel = /** @class */ (function () {
function BIPanel(data) {
this._series = [];
Object.assign(this, data);
}
/**
* The name of the model represented by this $resource,
* i.e. `BIPanel`.
*/
BIPanel.getModelName = function () {
return 'BIPanel';
};
/**
* @method factory
* @author Jonathan Casarrubias
* @license MIT
* This method creates an instance of BIPanel for dynamic purposes.
*/
BIPanel.factory = function (data) {
return new BIPanel(data);
};
/**
* @method getModelDefinition
* @author Julien Ledun
* @license MIT
* This method returns an object that represents some of the model
* definitions.
*/
BIPanel.getModelDefinition = function () {
return {
name: 'BIPanel',
plural: 'BIPanels',
path: 'BIPanels',
idName: 'id',
properties: {
name: {
name: 'name',
type: 'string'
},
description: {
name: 'description',
type: 'string'
},
chart: {
name: 'chart',
type: 'any'
},
created: {
name: 'created',
type: 'Date'
},
modified: {
name: 'modified',
type: 'Date'
},
deleted: {
name: 'deleted',
type: 'Date',
default: undefined
},
id: {
name: 'id',
type: 'any'
},
_series: {
name: '_series',
type: 'Array<any>',
default: []
},
projectId: {
name: 'projectId',
type: 'any'
},
},
relations: {
series: {
name: 'series',
type: 'any[]',
model: '',
relationType: 'embedsMany',
keyFrom: '_series',
keyTo: 'id'
},
trackingLogs: {
name: 'trackingLogs',
type: 'Log[]',
model: 'Log',
relationType: 'hasMany',
keyFrom: 'id',
keyTo: 'trackingModelId'
},
project: {
name: 'project',
type: 'Project',
model: 'Project',
relationType: 'belongsTo',
keyFrom: 'projectId',
keyTo: 'id'
},
}
};
};
return BIPanel;
}());
exports.BIPanel = BIPanel;
//# sourceMappingURL=BIPanel.js.map