Skip to content

Commit 0601f5b

Browse files
committed
TT-65 fix: correct changes of github messages
1 parent 0cb5762 commit 0601f5b

File tree

4 files changed

+19
-19
lines changed

4 files changed

+19
-19
lines changed

src/app/modules/time-clock/components/entry-fields/entry-fields.component.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,10 +35,10 @@
3535
></ngx-timepicker-field>
3636
</div>
3737
<div class="col-md-auto">
38-
<button *ngIf="showtimeInbuttons" (click)="onUpdateStartHour()" class="btn btn-success">Update</button>
38+
<button *ngIf="showTimeInbuttons" (click)="onUpdateStartHour()" class="btn btn-success">Update</button>
3939
</div>
4040
<div class="col-md-auto">
41-
<button *ngIf="showtimeInbuttons" (click)="cancelTimeInUpdate()" class="btn btn-danger">Cancel</button>
41+
<button *ngIf="showTimeInbuttons" (click)="cancelTimeInUpdate()" class="btn btn-danger">Cancel</button>
4242
</div>
4343
</div>
4444
</div>

src/app/modules/time-clock/components/entry-fields/entry-fields.component.spec.ts

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,7 @@ describe('EntryFieldsComponent', () => {
160160
component.onUpdateStartHour();
161161

162162
expect(toastrServiceStub.error).toHaveBeenCalled();
163-
expect(component.showtimeInbuttons).toEqual(false);
163+
expect(component.showTimeInbuttons).toEqual(false);
164164
});
165165

166166
it('Displays an error message when the active entry has start_time before the start_time of another entry', () => {
@@ -174,16 +174,16 @@ describe('EntryFieldsComponent', () => {
174174
component.onUpdateStartHour();
175175

176176
expect(toastrServiceStub.error).toHaveBeenCalled();
177-
expect(component.showtimeInbuttons).toEqual(false);
177+
expect(component.showTimeInbuttons).toEqual(false);
178178
});
179179

180-
it('should show time In buttons when time is modified', () => {
180+
it('should show time In control buttons when time is modified', () => {
181181
component.activeTimeInButtons();
182182

183-
expect(component.showtimeInbuttons).toEqual(true);
183+
expect(component.showTimeInbuttons).toEqual(true);
184184
});
185185

186-
it('should go back to the starting time and disappear buttons', () => {
186+
it('should reset displayed time and hide control buttons when cancelTimeInUpdate', () => {
187187
component.newData = entry;
188188
component.activeEntry = entry ;
189189
component.setDataToUpdate(entry);
@@ -192,7 +192,7 @@ describe('EntryFieldsComponent', () => {
192192
spyOn(component.entryForm, 'patchValue');
193193
component.cancelTimeInUpdate();
194194

195-
expect(component.showtimeInbuttons).toEqual(false);
195+
expect(component.showTimeInbuttons).toEqual(false);
196196
expect(component.entryForm.patchValue).toHaveBeenCalledWith(
197197
{
198198
start_hour: component.newData.start_hour
@@ -216,7 +216,7 @@ describe('EntryFieldsComponent', () => {
216216
start_hour: component.newData.start_hour
217217
}
218218
);
219-
expect(component.showtimeInbuttons).toEqual(false);
219+
expect(component.showTimeInbuttons).toEqual(false);
220220
});
221221

222222
it('If start hour is in the future, reset to initial start_date in form', () => {
@@ -235,7 +235,7 @@ describe('EntryFieldsComponent', () => {
235235
start_hour: component.newData.start_hour
236236
}
237237
);
238-
expect(component.showtimeInbuttons).toEqual(false);
238+
expect(component.showTimeInbuttons).toEqual(false);
239239
});
240240

241241
it('when a start hour is updated, then dispatch UpdateActiveEntry', () => {
@@ -247,7 +247,7 @@ describe('EntryFieldsComponent', () => {
247247

248248
component.onUpdateStartHour();
249249
expect(store.dispatch).toHaveBeenCalled();
250-
expect(component.showtimeInbuttons).toEqual(false);
250+
expect(component.showTimeInbuttons).toEqual(false);
251251
});
252252

253253
it('When start_time is updated, component.last_entry is equal to time entry in the position 1', waitForAsync(() => {

src/app/modules/time-clock/components/entry-fields/entry-fields.component.ts

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ export class EntryFieldsComponent implements OnInit {
3030
activeEntry;
3131
newData;
3232
lastEntry;
33-
showtimeInbuttons = false;
33+
showTimeInbuttons = false;
3434

3535
constructor(
3636
private formBuilder: FormBuilder,
@@ -129,7 +129,7 @@ export class EntryFieldsComponent implements OnInit {
129129
if (isEntryDateInTheFuture) {
130130
this.toastrService.error('You cannot start a time-entry in the future');
131131
this.entryForm.patchValue({ start_hour: this.newData.start_hour });
132-
this.showtimeInbuttons = false;
132+
this.showTimeInbuttons = false;
133133
return;
134134
}
135135

@@ -138,12 +138,12 @@ export class EntryFieldsComponent implements OnInit {
138138
if (isEntryDateInLastStartDate) {
139139
this.toastrService.error('There is another time entry registered in this time range');
140140
this.entryForm.patchValue({ start_hour: this.newData.start_hour });
141-
this.showtimeInbuttons = false;
141+
this.showTimeInbuttons = false;
142142
return;
143143
}
144144
this.entryForm.patchValue({ start_date: newHourEntered });
145145
this.dispatchEntries(newHourEntered);
146-
this.showtimeInbuttons = false;
146+
this.showTimeInbuttons = false;
147147
}
148148

149149
private dispatchEntries(newHourEntered) {
@@ -163,12 +163,12 @@ export class EntryFieldsComponent implements OnInit {
163163
}
164164

165165
activeTimeInButtons(){
166-
this.showtimeInbuttons = true;
166+
this.showTimeInbuttons = true;
167167
}
168168

169169
cancelTimeInUpdate(){
170170
this.entryForm.patchValue({ start_hour: this.newData.start_hour });
171-
this.showtimeInbuttons = false;
171+
this.showTimeInbuttons = false;
172172
}
173173

174174
onTechnologyAdded($event: string[]) {

src/styles.scss

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,9 @@ body {
2525
}
2626

2727
.timepicker-overlay {
28-
z-index: 10000000 !important;
28+
z-index: 1100 !important;
2929
}
3030

3131
.timepicker-backdrop-overlay {
32-
z-index: 10000000 !important;
32+
z-index: 1100 !important;
3333
}

0 commit comments

Comments
 (0)