aboutsummaryrefslogtreecommitdiffstats
path: root/todolist/util.go
Commit message (Collapse)AuthorAgeFilesLines
* Refactor the formatter to an interface and rename itGrant Ammons2017-10-031-0/+20
| | | | | | | | | | | | This change refactors the formatter to be an interface called Printer. `NewApp` will use the functionality of `ScreenPrinter`, which is what I refactored the old `Formatter` class into. There is a new class the implements the `Printer` interface called `MemoryPrinter`, which will simply store the `groups` as they were passed to it. This will allow tests in `app_test.go` to become much more powerful, since `App` no longer needs to be tightly coupled to printing to the screen.
* Have a util function to pluralize todo.Stuart Skelton2017-08-121-0/+7
|
* fix build error with older go versionIngo Richter2017-04-081-0/+6
|
* Add `CompletedDate` to todo item.Ingo Richter2017-04-081-1/+3
| | | | | | | | | | | `CompletedDate` will save a timestamp in ISO8601 format (Internet date/ time format to preserve timezone information) Added a new `Complete` and `Uncomplete` method for todo_item. Currently a todo has a boolean flag and the timestamp to indicate that the item is completed. The boolean flag could be kept for backward compatibility (reading the json into memory), but should be omitted for files being written.
* This commit removes all usages of github.com/jinzhu/now.DmitriyMV2017-03-041-0/+17
| | | | | | | | | github.com/jinzhu/now has numerous errors handling date and time. The example's of them are: 1. Incorrect handling of DST (https://github.com/jinzhu/now/issues/13). 2. 24 Hour long days (https://stackoverflow.com/questions/25254443/return-local-beginning-of-day-time-object-in-go) Chicago has 23, 24, or 25 hours in a day. 3. Incorrect usage of time.Truncate which can return time with a non-zero minute, depending on the time's Location. (https://github.com/golang/go/issues/16647). There are other issues as well, including getting incorrect beginning and end of the month.
* Make everything a pointer, add archive completed fnGrant Ammons2016-05-031-1/+1
|
* Get filtering by projects, contexts workingGrant Ammons2016-05-021-0/+29