Skip to content

Commit

Permalink
review(JOB-135): Renames computed attribute and ajusts css
Browse files Browse the repository at this point in the history
  • Loading branch information
Issel Parra committed Oct 13, 2017
1 parent 952fb71 commit d6a84c1
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 11 deletions.
16 changes: 8 additions & 8 deletions client/src/components/InterestModal.vue
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@

<!-- modal header-->
<div class="interest-modal__header">
<h2 class="interest-modal__title">Intéressé·e&nbsp; par <strong>{{ mission }}</strong> pour <strong>{{ customer }}</strong>&nbsp;?</h2>
<button class="interest-modal__action interest-modal__action--cancel" @click="cancelInterest"><icon name="times" scale="1.5"></icon></button>
<h2 class="interest-modal__title">Intéressé·e&nbsp; par <strong>{{ mission }}</strong> pour <strong>{{ customerName }}</strong>&nbsp;?</h2>
<button class="interest-modal__action interest-modal__action--cancel" @click="_closeModal"><icon name="times" scale="1.5"></icon></button>
</div>

<!-- modal body -->
Expand All @@ -25,7 +25,7 @@
@click="submitInterest">Je suis disponible
</button>
</div>
<p class="interest-modal__mentions interest-modal__text">L'équipe Job Board te mettra en relation avec <strong>{{ missionDirectorNickname }}</strong> , dir. mission et <strong>{{ businessContactNickname }}</strong>, contact biz.</p>
<p class="interest-modal__mentions">L'équipe Job Board te mettra en relation avec <strong>{{ missionDirectorNickname }}</strong> , dir. mission et <strong>{{ businessContactNickname }}</strong>, contact biz.</p>
</div>

</modal>
Expand Down Expand Up @@ -85,7 +85,7 @@
return missionName.substring(0, 49);
},
customer() {
customerName() {
if (!this.interestingJob) return '';
return (this.interestingJob.project.customer.name) ? this.interestingJob.project.customer.name : 'N/A';
},
Expand Down Expand Up @@ -137,10 +137,6 @@
this._removeError();
},
cancelInterest() {
this._closeModal();
},
_resetInterest() {
this.interest = null;
},
Expand Down Expand Up @@ -245,7 +241,11 @@
}
.interest-modal__mentions {
width: 100%;
resize: none;
overflow: auto;
font-size: 14px;
box-sizing: border-box;
font-style: italic;
text-align: center;
}
Expand Down
7 changes: 4 additions & 3 deletions client/test/unit/specs/components/InterestModal.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -240,13 +240,14 @@ describe('Unit | Component | InterestModal.vue', () => {
// Then
expect(missionName).to.equal('SCLOU - Cloud computing : enjeux, architecture et');
});
});


it.only('should get customerName', () => {
describe('computed property #customerName', () => {
it('should get customerName', () => {
// Given

// When
const customerName = component.customer;
const customerName = component.customerName;

// Then
expect(customerName).to.equal('La Poste - Courrier');
Expand Down

0 comments on commit d6a84c1

Please sign in to comment.