mirror of
https://github.com/GothenburgBitFactory/timewarrior.git
synced 2025-07-27 12:16:25 +02:00
CmdReportDay: Outlining processing
This commit is contained in:
parent
6e93538b48
commit
983d4a8945
1 changed files with 36 additions and 1 deletions
|
@ -25,7 +25,9 @@
|
||||||
////////////////////////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
#include <cmake.h>
|
#include <cmake.h>
|
||||||
|
#include <Palette.h>
|
||||||
#include <commands.h>
|
#include <commands.h>
|
||||||
|
#include <timew.h>
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////////////////////////
|
||||||
|
@ -34,7 +36,40 @@ int CmdReportDay (
|
||||||
Rules& rules,
|
Rules& rules,
|
||||||
Database& database)
|
Database& database)
|
||||||
{
|
{
|
||||||
std::cout << "# CmdReportDay\n";
|
auto filter = createFilterIntervalFromCLI (cli);
|
||||||
|
// TODO If filter is empty, choose 'today'.
|
||||||
|
|
||||||
|
auto timeline = createTimelineFromData (rules, database, filter);
|
||||||
|
auto tracked = timeline.tracked (rules);
|
||||||
|
|
||||||
|
// Create a color palette.
|
||||||
|
Palette palette;
|
||||||
|
palette.initialize (rules);
|
||||||
|
palette.enabled = rules.getBoolean ("color");
|
||||||
|
|
||||||
|
// Map tags to colors.
|
||||||
|
// TODO Note: tags may have their own defined color.
|
||||||
|
std::map <std::string, Color> tagMap;
|
||||||
|
|
||||||
|
// TODO Get the exclusion ranges, to render the exclused time.
|
||||||
|
// TODO Get the earliest hour of the filtered data.
|
||||||
|
// TODO Get the latest hour of the filtered data.
|
||||||
|
|
||||||
|
// TODO Axis, hard-coded.
|
||||||
|
std::cout << "\n"
|
||||||
|
<< " 0 1 2 3 4 5 6 7 8 9 10 11 12 1 2 3 4 5 6 7 8 9 10 11\n";
|
||||||
|
|
||||||
|
// TODO Data, missing.
|
||||||
|
std::cout << "\n"
|
||||||
|
<< "\n";
|
||||||
|
|
||||||
|
// TODO Summary, missing.
|
||||||
|
std::cout << "\n"
|
||||||
|
<< " Tracked\n"
|
||||||
|
<< " Untracked\n"
|
||||||
|
<< " Total\n"
|
||||||
|
<< "\n";
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue