added: privileges (user, groups, permissions)
(not finished yet) classes: User, Group, Users, Groups, UGContainer changed: Dir class into Dirs git-svn-id: svn://ttmath.org/publicrep/cmslu/trunk@467 e52654a7-88a9-db11-a3e9-0013d4bc506e
This commit is contained in:
13
core/db.h
13
core/db.h
@@ -24,7 +24,9 @@
|
||||
#include "misc.h"
|
||||
#include "error.h"
|
||||
#include "dircontainer.h"
|
||||
|
||||
#include "user.h"
|
||||
#include "group.h"
|
||||
#include "ugcontainer.h"
|
||||
|
||||
|
||||
class Db
|
||||
@@ -37,13 +39,16 @@ public:
|
||||
void Init(const std::string & database, const std::string & user, const std::string & pass);
|
||||
bool CheckUser(std::string & login, std::string & password, long & user_id);
|
||||
Error AddItem(Item & item);
|
||||
Error EditItem(Item & item, bool with_subject = true);
|
||||
Error EditItemById(Item & item, bool with_subject = true);
|
||||
Error EditItemByUrl(Item & item, bool with_subject = true);
|
||||
void CheckAllUrlSubject();
|
||||
void GetItems(std::vector<Item> & item_table, Item & item_ref);
|
||||
void GetItem(std::vector<Item> & item_table, long id);
|
||||
bool GetPriv(Item & item, long id);
|
||||
bool DelItem(const Item & item);
|
||||
void GetDirs(DirContainer & dir_table);
|
||||
|
||||
void GetUsers(UGContainer<User> & user_table);
|
||||
void GetGroups(UGContainer<Group> & group_table);
|
||||
|
||||
|
||||
|
||||
@@ -70,6 +75,8 @@ protected:
|
||||
|
||||
Error EditItemInItem(Item & item, bool with_subject);
|
||||
Error EditItemInContent(Item & item);
|
||||
Error EditItemGetId(Item & item);
|
||||
Error EditItemGetContentId(Item & item);
|
||||
|
||||
void CheckAllUrlSubjectModifyItem(Item & item);
|
||||
|
||||
|
Reference in New Issue
Block a user