Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/negative durations #5

Merged
merged 8 commits into from
May 28, 2018
Merged

Feature/negative durations #5

merged 8 commits into from
May 28, 2018

Conversation

DerHahne
Copy link
Contributor

Hi,
I implemented the feature request to enable negative time durations. The configuration is set to false by default.

This implementation is regarding to feature request #3

@@ -56,6 +59,14 @@
</tr>

<tr>
<td *ngIf="config.showNegative">
<input type="checkbox" id="dp-negative" [(ngModel)]="negative" #status [disabled]="disabled">
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why do we need this <input> ?

@@ -59,11 +59,47 @@ describe('DurationPickerComponent', () => {
expect(component.generate()).toBe('P9MT10M');
});

it('generate() should correctly generate the negative duration values', () => {
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this test is failing for me

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed!

@FrancescoBorzi
Copy link
Owner

@DerHahne Thanks a lot for your contribution! Please check my review comments

@DerHahne
Copy link
Contributor Author

Hi!
I made some rework on input checkbox and the failing unit test.

We have a binding on a variable by clicking the negative/positive state button without input checkbox.

For the failing unit test i forgot to add a variable which must be set to true.

@FrancescoBorzi FrancescoBorzi merged commit 03be95f into FrancescoBorzi:master May 28, 2018
@FrancescoBorzi
Copy link
Owner

@DerHahne merged, thanks a lot!

@DerHahne
Copy link
Contributor Author

Thx @ShinDarth !!! :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants