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

Support task deadline #139

Merged
merged 5 commits into from
Oct 19, 2020

Conversation

T-Fang
Copy link

@T-Fang T-Fang commented Oct 19, 2020

No description provided.

@T-Fang T-Fang added the enhancement New feature or request label Oct 19, 2020
@T-Fang T-Fang added this to the v1.3 milestone Oct 19, 2020
@T-Fang T-Fang requested a review from GeNiaaz October 19, 2020 05:57
@T-Fang T-Fang self-assigned this Oct 19, 2020
@codecov-io
Copy link

Codecov Report

Merging #139 into master will decrease coverage by 0.15%.
The diff coverage is 10.00%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master     #139      +/-   ##
============================================
- Coverage     59.42%   59.26%   -0.16%     
- Complexity      597      598       +1     
============================================
  Files           109      109              
  Lines          2228     2234       +6     
  Branches        274      275       +1     
============================================
  Hits           1324     1324              
- Misses          825      830       +5     
- Partials         79       80       +1     
Impacted Files Coverage Δ Complexity Δ
...address/logic/commands/project/AddTaskCommand.java 0.00% <ø> (ø) 0.00 <0.00> (ø)
...ddress/logic/commands/project/EditTaskCommand.java 0.00% <ø> (ø) 0.00 <0.00> (ø)
...edu/address/logic/parser/AddTaskCommandParser.java 0.00% <0.00%> (ø) 0.00 <0.00> (ø)
...du/address/logic/parser/EditTaskCommandParser.java 0.00% <0.00%> (ø) 0.00 <0.00> (ø)
src/main/java/seedu/address/model/task/Task.java 55.26% <0.00%> (-8.38%) 13.00 <0.00> (+1.00) ⬇️
.../address/logic/parser/TaskFilterCommandParser.java 94.11% <100.00%> (ø) 6.00 <0.00> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 7096dd7...e700aeb. Read the comment docs.

@T-Fang T-Fang linked an issue Oct 19, 2020 that may be closed by this pull request
Copy link

@GeNiaaz GeNiaaz left a comment

Choose a reason for hiding this comment

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

LGTM, thanks especially for changing the JavaFXVersion 👍

@@ -42,7 +42,7 @@ task coverage(type: JacocoReport) {

dependencies {
String jUnitVersion = '5.4.0'
String javaFxVersion = '11'
String javaFxVersion = '11.0.1'
Copy link

Choose a reason for hiding this comment

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

WOW this has been bugging me for the longest time, thanks for finding and changing it

@@ -37,8 +39,11 @@ public AddTaskCommand parse(String args) throws ParseException {
ParserUtil.parseTaskBasicInformation(argMultimap.getValue(PREFIX_TASK_PROGRESS).get()));
boolean taskStatus = Boolean.parseBoolean(
ParserUtil.parseTaskBasicInformation(argMultimap.getValue(PREFIX_TASK_IS_DONE).get()));

Task task = new Task(taskName, null, null, taskProgress, taskStatus);
Deadline taskDeadline = null;
Copy link

Choose a reason for hiding this comment

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

Why set it to null here? Why not declare the variable below.

@@ -46,7 +46,7 @@ public TaskFilterCommand parse(String args) throws ParseException {

if (argMultimap.getValue(PREFIX_TASK_DEADLINE).isPresent()) {
Deadline deadline = ParserUtil.parseDeadline(argMultimap.getValue(PREFIX_TASK_DEADLINE).get());
predicate = task -> task.getDeadline().equals(deadline);
predicate = task -> task.isDueOn(deadline);
Copy link

Choose a reason for hiding this comment

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

Good adhering to Law of Demeter

@GeNiaaz GeNiaaz merged commit 27a8fb0 into AY2021S1-CS2103T-W10-3:master Oct 19, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Support Task Deadline management
3 participants