Tag management : first version
This commit is contained in:
@@ -88,7 +88,7 @@ public:
|
||||
static const int NOT_CHECKED_OP = (1 << 3);
|
||||
static const int ALL_OP = (~0);
|
||||
|
||||
static const int VERSION = 3;
|
||||
static const int VERSION = 4;
|
||||
|
||||
Database(const char* filename, KissCount* kiss);
|
||||
|
||||
@@ -128,6 +128,11 @@ public:
|
||||
void DeleteCategory(User* user, Category& category, int replacement);
|
||||
bool LoadCategory(int id, const QString& name, Category& category);
|
||||
|
||||
int AddTag(User* user, Tag& tag);
|
||||
void UpdateTag(Tag& tag);
|
||||
void DeleteTag(User* user, Tag& tag, int replacement);
|
||||
bool LoadTag(int id, const QString& name, Tag& tag);
|
||||
|
||||
std::map<int, std::vector<int> > GetAllOperations(User* user);
|
||||
void GenerateMonth(User* user, int monthFrom, int yearFrom, int monthTo, int yearTo);
|
||||
|
||||
@@ -140,15 +145,15 @@ public:
|
||||
|
||||
std::vector<Operation>* Search(User* user, QString* description, QDate* dateFrom, QDate* dateTo,
|
||||
int* amountFrom, int* amountTo,
|
||||
std::vector<int> categories, int types, std::vector<int> accounts, bool wildcards);
|
||||
std::vector<int> categories, int types, std::vector<int> accounts, bool wildcards, std::vector<int> tags);
|
||||
|
||||
void GetStats(User* user, int monthFrom, int yearFrom, int monthTo,
|
||||
int yearTo, std::map<int, std::map<int, std::map<int, int> > >* accountAmounts,
|
||||
std::map<int, int>* categories);
|
||||
std::map<int, int>* categories, std::map<int, int>* tags);
|
||||
|
||||
void GetMonthStats(User* user, int month, int year, int nbDays,
|
||||
std::map<int, std::vector<int> >* operations,
|
||||
std::map<int, int>* categories);
|
||||
std::map<int, int>* categories, std::map<int, int>* tags);
|
||||
|
||||
void KillMe(User* user);
|
||||
bool GetOperation(int id, Operation* op);
|
||||
|
||||
Reference in New Issue
Block a user