some methods from templates/item.cpp moved to ItemContent

This commit is contained in:
2021-06-20 21:22:08 +02:00
parent 801fc062ef
commit ade96bf6d3
10 changed files with 261 additions and 118 deletions

View File

@@ -53,36 +53,13 @@ public:
std::wstring name; // group name
//std::vector<long> members; // users id
Group()
{
Clear();
}
Group();
void fields();
void table();
void after_insert();
void fields()
{
field(L"id", id, morm::FT::no_insertable | morm::FT::no_updatable | morm::FT::primary_key);
field(L"name", name);
}
void table()
{
table_name(L"core", L"group");
}
void after_insert()
{
get_last_sequence_for_primary_key(L"core.group_id_seq", id);
}
void Clear()
{
id = -1;
name.clear();
//members.clear();
}
void Clear();
bool do_migration(int & current_table_version);