Skip to content

Commit

Permalink
tech(1d): use only usefull assessment attributes and clean model
Browse files Browse the repository at this point in the history
  • Loading branch information
Yaelle YAMA authored Nov 20, 2023
1 parent 8ee7e4a commit 4fdb8eb
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 14 deletions.
3 changes: 1 addition & 2 deletions 1d/app/models/activity.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import Model, { attr, belongsTo } from '@ember-data/model';
import Model, { attr } from '@ember-data/model';

export default class Activity extends Model {
@attr('string') level;
@belongsTo('assessment', { async: true, inverse: 'activities' }) assessment;
}
14 changes: 2 additions & 12 deletions 1d/app/pods/assessment/model.js
Original file line number Diff line number Diff line change
@@ -1,17 +1,7 @@
import Model, { attr, hasMany } from '@ember-data/model';
import Model, { attr } from '@ember-data/model';

export default class Assessment extends Model {
// attributes
@attr('string') certificationNumber;
@attr('string') codeCampaign;
@attr('string') state;
@attr('string') title;
@attr('string') type;
@attr('string') lastQuestionState;
@attr('string') method;

// references
@attr('string') competenceId;
@attr('string') missionId;
@hasMany('activity', { async: true, inverse: 'assessment' }) activities;
@attr('string') organizationLearnerId;
}

0 comments on commit 4fdb8eb

Please sign in to comment.