Skip to content

Commit

Permalink
Merge pull request nus-cs2113-AY2324S1#17 from AY2324S1-CS2113-F11-3/…
Browse files Browse the repository at this point in the history
…master

Update
  • Loading branch information
Cheezeblokz authored Nov 13, 2023
2 parents 67b3817 + 4bb7f00 commit bdcd066
Show file tree
Hide file tree
Showing 21 changed files with 297 additions and 90 deletions.
5 changes: 1 addition & 4 deletions data/events/event.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1 @@
hello | 2023-12-20T12:30:30 | 2023-12-20T12:30:30
EC3333 | 2023-12-20T12:30:30 | 2023-12-20T12:30:40
Deadline | 2023-12-20T12:30:30 | 10 | 1
More Deadline | 2023-12-20T12:30:30 | 20 | 1
Do User | 2023-12-20T12:30:30 | 2023-12-20T13:30:30
4 changes: 3 additions & 1 deletion data/flashcards/flashcard.txt
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
3 | dfdf | dfdf | 5
2 | Hello | Duke | 5
3 | Hello | Duke | 5
4 | Hello | Duke | 5
2 changes: 1 addition & 1 deletion docs/AboutUs.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,6 @@ Display | Name | Github Profile | Portfolio
--------|:------------------:|:--------------:|:---------:
![](https://media.licdn.com/dms/image/C4D03AQGTLbALYjG82Q/profile-displayphoto-shrink_800_800/0/1580629728751?e=1701907200&v=beta&t=PEfw_qZfZA39rJRfo5_Pg4o_RmbPwdneiPX3ftNt9dA) | Wendelin Wemhoener | [Github](https://github.com/wendelinwemhoener/) | [Portfolio](docs/team/wendelinwemhoener.md)
![](https://via.placeholder.com/100.png?text=Photo) | Zhu Jingxi | [Github](https://github.com/Cheezeblokz) | [Portfolio](docs/team/zhujingxi.md)
![](/Users/brian/Desktop/Colgate/NUS Fall 2023/CS2113/Team Project/docs/photo/kherlenbayasgalan.jpg) | Kherlen Bayasgalan | [Github](https://github.com/Brian030601) | [Portfolio](docs/team/Brian030601.md)
![](/Users/brian/Desktop/Colgate/NUS Fall 2023/CS2113/Team Project/docs/photo/kherlenbayasgalan.jpg) | Kherlen Bayasgalan | [Github](https://github.com/Brian030601) | [Portfolio](docs/team/brian030601.md)
![](https://via.placeholder.com/100.png?text=Photo) | Bang Junhyeong | [Github](https://github.com/junhyeong0411) | [Portfolio](docs/team/bangjunhyeong.md)
![](https://via.placeholder.com/100.png?text=Photo) | Don Roe | [Github](https://github.com/) | [Portfolio](docs/team/johndoe.md)
18 changes: 17 additions & 1 deletion docs/DeveloperGuide.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,23 @@

## Design & implementation

{Describe the design and implementation of the product. Use UML diagrams and short code snippets where applicable.}
### flashcard package

The API of the flashcard package is defined in [FlashcardComponent.java](https://github.com/AY2324S1-CS2113-F11-3/tp/blob/master/src/main/java/seedu/duke/flashcard/FlashcardComponent.java).

The flashcard package is structured into multiple parts:

- [Flashcard.java](https://github.com/AY2324S1-CS2113-F11-3/tp/blob/master/src/main/java/seedu/duke/flashcard/Flashcard.java)
- [FlashcardCommandParser.java](https://github.com/AY2324S1-CS2113-F11-3/tp/blob/master/src/main/java/seedu/duke/flashcard/FlashcardCommandParser.java)
- [FlashcardComponent.java](https://github.com/AY2324S1-CS2113-F11-3/tp/blob/master/src/main/java/seedu/duke/flashcard/FlashcardComponent.java)
- [FlashcardDirectory.java](https://github.com/AY2324S1-CS2113-F11-3/tp/blob/master/src/main/java/seedu/duke/flashcard/FlashcardDirectory.java)
- [FlashcardList.java](https://github.com/AY2324S1-CS2113-F11-3/tp/blob/master/src/main/java/seedu/duke/flashcard/FlashcardList.java)
- [FlashcardUi.java](https://github.com/AY2324S1-CS2113-F11-3/tp/blob/master/src/main/java/seedu/duke/flashcard/FlashcardUi.java)
- [command package](https://github.com/AY2324S1-CS2113-F11-3/tp/tree/master/src/main/java/seedu/duke/flashcard/command)
- [exceptions package](https://github.com/AY2324S1-CS2113-F11-3/tp/tree/master/src/main/java/seedu/duke/flashcard/exceptions)
- [review package](https://github.com/AY2324S1-CS2113-F11-3/tp/tree/master/src/main/java/seedu/duke/flashcard/review)



### Storage Components

Expand Down
218 changes: 156 additions & 62 deletions docs/UserGuide.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ the courses they are taking.
## Quick Start

1. Ensure that you have Java 11 or above installed.
2. Down the latest jar from [the latest release on GitHub](https://github.com/AY2324S1-CS2113-F11-3/tp/releases).
3. Run the jar via `java -jar duke.jar`
2. Download the latest jar from [the latest release on GitHub](https://github.com/AY2324S1-CS2113-F11-3/tp/releases).
3. Run the jar file via `java -jar duke.jar`

## Features

Expand Down Expand Up @@ -306,102 +306,181 @@ Enter your command: <b>delete all flashcards</b>
All your flashcards have been successfully deleted.
</pre>

### General Explanation of Calendar Features
### Calendar-related features

Here is your features list:

+ `add event` , `delete event`
+ `list events` , `find event`
+ `delete all events`
#### General explanation of flashcards

Users can use the above features to handle their events
TaskLinker's calendar feature allows users to manage their time effectively
by adding, listing, finding, and deleting events. Events in the calendar have a
specified start and end time, making it easy for users to plan their schedules.
This feature is particularly useful for individuals with busy schedules or
those who want to keep track of their upcoming appointments or tasks.

#### Adding a todo: `todo`
The TaskLinker is also integrated with the flashcards and can be used for setting
a goal to review flashcards. Add goal event can be used to take user input for
setting a goal to review flashcards.

Adds a new item to the list of todo items.
Here is your features list:

Format: `todo n/TODO_NAME d/DEADLINE`
+ `add event` , `delete event`
+ `list events` , `find event`
+ `delete all events` , `add goal event`

* The `DEADLINE` can be in a natural language format.
* The `TODO_NAME` cannot contain punctuation.
Users can use the above features to handle their events`

Example of usage:
#### Adding an event to the calendar: `add event`

`todo n/Write the rest of the User Guide d/next week`
Adds an event to the calendar with start and end time.

`todo n/Refactor the User Guide to remove passive voice d/13/04/2020`
After entering this command, the user is asked to enter the event name on the calendar.
Once the name is given, the user should press ENTER to continue. Once the name is entered,
the user is prompted to give a start time and an end time for the event.

The start and the end time should be in an acceptable format (`yyyy-mm-ddThh:mm:ss`.)
If it is not in an acceptable format, (`Invalid date and time format. Please try again.`)
message will appear and prompt the user to enter a new start time.

Furthermore, the end time should be later than the start time as an event cannot
end before it's start time. If an earlier time is given for the end time than the
start time, the TaskLinker displays (`End time is before or equal to the start time. Please enter the correct end time.`)
message and starts over from (`Enter your command:`).

#### Add an Event to the Calendar
Format:
<pre>
Enter your command: <b>add event</b>
What's the event?: <b>Name [Event Name]</b>
When does it start?: <b>yyyy-mm-ddThh:mm:ss [Start Time]</b>
When does it end?: <b>yyyy-mm-ddThh:mm:ss [End Time]</b>
</pre>

**Adds an event to the calendar with start and end time**
Example of usage:
<pre>
Enter your command: <b>add event</b>
What's the event?: <b>Do HW</b>
When does it start?: <b>2023-12-20T12:30:30</b>
When does it end?: <b>2023-12-20T13:40:30</b>

#### Usage
Event 'Do HW' From: 2023-12-20T12:30:30, To: 2023-12-20T13:40:30
has been added to your Calendar
</pre>

+ Format: `add event` [Command]
+ What's the event?: `Event name` [Event name]
+ When does it start?: `yyyy-mm-ddThh:mm:ss` [Start time]
+ When does it end?: `yyyy-mm-ddThh:mm:ss` [End time]
#### Adding a goal event to the calendar: `add goal event`

**Example of usage**:
Adds a goal of reviewing flashcards as an event to the calendar.

+ `Enter your command: add event`
+ `What's the event?: Do HW`
+ `When does it start?: 2023-12-20T12:30:30`
+ `When does it end?: 2023-12-20T12:40:30`
After entering (`add goal event`) command, the user is asked to provide a name
for this goal event. After the name, the user is prompted to give an end time
for the event. The end time serves as a deadline for the goal.

#### Delete an Event From the Calendar
After the deadline has been given, then the goal should be given. Goal of reviewing
some number of flashcards by the given deadline. Same as adding an event, if an unacceptable
format of end time is given, the TaskLinker will display (`Invalid date and time format. Please try again.`)
message.

**deletes an event from the calendar with event name**
Format:
<pre>
Enter your command: <b>add goal event</b>
What's the event?: <b>Name [Goal Name]</b>
When does it end?: <b>yyyy-mm-ddThh:mm:ss [End Time]</b>
How many flashcard to review by then?: <b>Number [# of flashcards to review]</b>
</pre>

#### Usage
Example of usage:
<pre>
Enter your command: <b>add goal event</b>
What's the event?: <b>Do Flashcards</b>
When does it end?: <b>2023-12-20T12:30:30</b>
How many flashcard to review by then?: <b>20</b>

+ Format: `delete event`
+ Enter the event name: `Event name` [Event name]
Goal 'Do Flashcards' review 20 flashcards by: 2023-12-20T12:30:30 (Reviewed: 0)
has been added to your Calendar
</pre>

**Example of usage**:
#### Delete an event from the calendar: `delete event`

+ `Enter your command: delete event`
+ `Enter the event name: Do HW`
Deletes an event from the calendar with event name.

#### Delete All Events From the Calendar
After the (`delete event`) command has been given, the user is prompted to give
the name of the event he/she wants to delete from the calendar. If the given
event exist in the calendar, then TaskLinker will display (`[Event Name] has been deleted from your Calendar!`).
Then the event gets deleted from the event list.

**deletes all events from the calendar**
However, if the given event name doesn't exist in the calendar. Then the event
doesn't exist in the calendar message will display (`[Event Name] doesn't exist in your Calendar!`).
The user then enter a different command.

#### Usage
Format:
<pre>
Enter your command: <b>delete event</b>
What's the event?: <b>Name [Event Name]</b>
[Event Name] has been deleted from your Calendar!
</pre>

+ Format: `delete all events`
Example of usage:
<pre>
Enter your command: <b>delete event</b>
What's the event?: <b>hello</b>
hello has been deleted from your Calendar!
</pre>

**Example of usage**:
#### Delete all events from the Calendar: `delete all events`

+ `Enter your command: delete all events`
Deletes all events from the calendar.

#### Find an Event From the Calendar
Once the (`delete all events`) command has been given by the user,
the TaskLinker will clear all events in the calendar. If the exact
command is not entered, the feature will not work.

**finds an event from the calendar**
Format & Example:
<pre>
Enter your command: <b>delete all events</b>
All your events have been successfully deleted from the Calendar.
</pre>

##### Usage
#### Find an event from the Calendar: `find event`

+ Format: `find event`
+ What event are you looking for?: `event name`
Finds an event from the calendar.

**Example of usage**:
Once the (`find event`) command has been entered, the user is prompted to
give the name of the event he/she is looking for. The input user gives can
just be partial name of the event. If so, the feature will list all
events that included the given input.

+ `Enter your command: find event`
+ `What event are you looking for?: Do HW`
However, if the given input is not found from the events in the Calendar,
then the (`No such event found`) message will be displayed.

#### List All Events From the Calendar
Format:
<pre>
Enter your command: <b>find event</b>
What's the event?: <b>Name [Event Name]</b>
1. Event 'Event Name' From: yyyy-mm-ddThh:mm:ss, To: yyyy-mm-ddThh:mm:ss
These events have been found
</pre>

**Lists all events from the calendar**
Example of usage:
<pre>
Enter your command: <b>find event</b>
What's the event?: <b>Do HW</b>
1. Event 'Do HW' From: 2023-12-20T12:30:30, To: 2023-12-20T13:30:30
These events have been found
</pre>

#### Usage
#### List all events from the Calendar: `list events`

+ Format: `list events`
Lists all events from the calendar

**Example of usage**:
Once the (`list events`) command has been entered, the TaskLinker lists
all the events in the event list. If there is no event in the event list,
the (`The Calendar is empty!`) message will be displayed.

+ `Enter your command: find event`
Format & Example:
<pre>
Enter your command: <b>list events</b>
Here is a list of all your events:
--------------------------------------------------------------------------------
1. Event 'Do User' From: 2023-12-20T12:30:30, To: 2023-12-20T13:30:30
--------------------------------------------------------------------------------
</pre>

## FAQ

Expand All @@ -415,6 +494,14 @@ Every event and flashcard are automatically save after each command.

**A**: You can transfer your data by copying & pasting the data folder.

**Q**: Why is the calendar features needed?

**A**: The calendar features are used for adding a flashcard review and other goals.

**Q**: Are the flashcard and the calendar use different commands?

**A**: Yes, they have different command based on their features.

## Command Summary

* [Listing all flashcards](#listing-all-flashcards-list-flashcards): `list
Expand All @@ -427,8 +514,15 @@ Every event and flashcard are automatically save after each command.
flashcard`
* [Deleting all flashcards](#deleting-all-flashcards-delete-all-flashcards)
`delete all flashcards`
* Create an event: `add event`
* Delete an event: `delete event`
* Delete all events: `delete all events`
* Find an event: `find event`
* List events: `list events`
* [Create an event](#adding-an-event-to-the-calendar-add-event):
`add event`
* [Add a goal event](#adding-a-goal-event-to-the-calendar-add-goal-event):
`add goal event`
* [Delete an event](#delete-an-event-from-the-calendar-delete-event):
`delete event`
* [Delete all events](#delete-all-events-from-the-calendar-delete-all-events):
`delete all events`
* [Find an event](#find-an-event-from-the-calendar-find-event):
`find event`
* [List all events](#list-all-events-from-the-calendar-list-events):
`list events`
2 changes: 1 addition & 1 deletion docs/team/brian030601.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Kherlen Bayasgalan (brian030601) - Project Portfolio Page
# Kherlen Bayasgalan (Brian030601) - Project Portfolio Page

## Overview

Expand Down
12 changes: 10 additions & 2 deletions docs/team/wendelinwemhoener.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,19 @@ taking.
### Code Contribution

See my code contribution [here on the tP Code Dashboard](https://nus-cs2113-ay2324s1.github.io/tp-dashboard/?search=wendelinwemhoener&breakdown=true)
- implemented architecture that my team reused
- made sure that build check and ui text testcase passed
- javadoc for all methods (except getters/setters and constructors)

### Contributions to the UG

- wrote the general sections

### Contributions to the DG

product scope


### Contributions to team-based tasks

- I set up the GitHub team org, created the project board on GitHub and set
Expand All @@ -26,5 +34,5 @@ See my code contribution [here on the tP Code Dashboard](https://nus-cs2113-ay23
- I documented target user profile and value proposition in UG/DG
- I set up the Google Doc we used for coordinating the project in the
initial phase
- I set up and administrated our Telegram chat group to allow for easy and
efficient communication
- I set up and administrated our Telegram chat group to allow for
efficient communication and coordinated our weekly meetings
2 changes: 1 addition & 1 deletion src/main/java/seedu/duke/calendar/CalendarManager.java
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
//@@author Brian030601 & jingxizhu
//@@author Brian030601

package seedu.duke.calendar;

Expand Down
4 changes: 3 additions & 1 deletion src/main/java/seedu/duke/calendar/Event.java
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
//@@author Brian030601 & Cheezeblokz
//@@author Brian030601

package seedu.duke.calendar;

Expand All @@ -9,13 +9,15 @@ public class Event {
private LocalDateTime from;
private LocalDateTime to;

//@@author Cheezeblokz
// Event is a constructor method for Event class.
public Event(String name, LocalDateTime from, LocalDateTime to) {
this.name = name;
this.from = from;
this.to = to;
}

//@@author Cheezeblokz
// getName returns the name of the event.
public String getName() {
return name;
Expand Down
Loading

0 comments on commit bdcd066

Please sign in to comment.