Minor Refactoring

- Added support for more type-specific checks of attribute values.
- Added support for more type-specific attribute rendering.
- Improved generalized methods for checking columns in a report.
- Added unit tests.
- Minor code cleanup.
- Added secret hidden feature for internal testing.
This commit is contained in:
Paul Beckingham 2012-02-05 20:56:46 -05:00
parent cffc42484e
commit 96fe3f42ba
83 changed files with 351 additions and 81 deletions

View file

@ -25,7 +25,6 @@
//
////////////////////////////////////////////////////////////////////////////////
#define L10N // Localization complete.
#include <sstream>
@ -308,6 +307,23 @@ int CmdInfo::execute (std::string& output)
view.set (row, 0, STRING_COLUMN_LABEL_URGENCY);
view.set (row, 1, trimLeft (format (task->urgency (), 4, 4)));
// Show any UDAs
std::vector <std::string> all = task->all ();
std::vector <std::string>::iterator att;
for (att = all.begin (); att != all.end (); ++att)
{
if (context.config.get ("uda." + *att + ".type") != "")
{
Column* col = context.columns[*att];
if (col)
{
row = view.addRow ();
view.set (row, 0, col->label ());
view.set (row, 1, task->get (*att));
}
}
}
// Create a second table, containing undo log change details.
ViewText journal;