@xompass/sdk-cloud-api
Version:
Xompass Client for cloud-api
83 lines • 2.41 kB
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.Dashboard = void 0;
var Dashboard = /** @class */ (function () {
function Dashboard(data) {
Object.assign(this, data);
}
/**
* The name of the model represented by this $resource,
* i.e. `Dashboard`.
*/
Dashboard.getModelName = function () {
return 'Dashboard';
};
/**
* @method factory
* @author Jonathan Casarrubias
* @license MIT
* This method creates an instance of Dashboard for dynamic purposes.
*/
Dashboard.factory = function (data) {
return new Dashboard(data);
};
/**
* @method getModelDefinition
* @author Julien Ledun
* @license MIT
* This method returns an object that represents some of the model
* definitions.
*/
Dashboard.getModelDefinition = function () {
return {
name: 'Dashboard',
plural: 'Dashboards',
path: 'Dashboards',
idName: 'id',
properties: {
created: {
name: 'created',
type: 'Date'
},
modified: {
name: 'modified',
type: 'Date'
},
deleted: {
name: 'deleted',
type: 'Date',
default: undefined
},
id: {
name: 'id',
type: 'any'
},
projectId: {
name: 'projectId',
type: 'any'
},
},
relations: {
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 Dashboard;
}());
exports.Dashboard = Dashboard;
//# sourceMappingURL=Dashboard.js.map