open-nomad/ui/app/models/evaluation.js
Buck Doyle 89136cbf6a Add massaged results of class codemod
Manual interventions:
• decorators on the same line for service and controller
  injections and most computed property macros
• preserving import order when possible, both per-line
  and intra-line
• moving new imports to the bottom
• removal of classic decorator for trivial cases
• conversion of init to constructor when appropriate
2020-06-10 16:18:42 -05:00

30 lines
903 B
JavaScript

import { bool, equal } from '@ember/object/computed';
import Model from 'ember-data/model';
import attr from 'ember-data/attr';
import { belongsTo } from 'ember-data/relationships';
import { fragmentArray } from 'ember-data-model-fragments/attributes';
import shortUUIDProperty from '../utils/properties/short-uuid';
export default class Evaluation extends Model {
@shortUUIDProperty('id') shortId;
@attr('number') priority;
@attr('string') type;
@attr('string') triggeredBy;
@attr('string') status;
@attr('string') statusDescription;
@fragmentArray('placement-failure', { defaultValue: () => [] }) failedTGAllocs;
@bool('failedTGAllocs.length') hasPlacementFailures;
@equal('status', 'blocked') isBlocked;
@belongsTo('job') job;
@attr('number') modifyIndex;
@attr('date') modifyTime;
@attr('number') createIndex;
@attr('date') createTime;
@attr('date') waitUntil;
}