some improvement in templates
(now we have O(1) time for selecting the right html template) added: winix function: template for selecting a template for an item (file or dir) git-svn-id: svn://ttmath.org/publicrep/winix/trunk@636 e52654a7-88a9-db11-a3e9-0013d4bc506e
This commit is contained in:
@@ -31,6 +31,7 @@ void Db::ItemColumns::SetColumns(PGresult * r)
|
||||
guest_name = PQfnumber(r, "guest_name");
|
||||
auth = PQfnumber(r, "auth");
|
||||
auth_path = PQfnumber(r, "auth_path");
|
||||
html_template = PQfnumber(r, "template");
|
||||
modification_user_id = PQfnumber(r, "modification_user_id");
|
||||
}
|
||||
|
||||
@@ -55,6 +56,7 @@ void Db::ItemColumns::SetItem(PGresult * r, long row, Item & item)
|
||||
if( guest_name != -1 ) item.guest_name = Db::AssertValue(r, row, guest_name);
|
||||
if( auth != -1 ) item.auth = static_cast<Item::Auth>( atoi(Db::AssertValue(r, row, auth)) );
|
||||
if( auth_path != -1 ) item.auth_path = Db::AssertValue(r, row, auth_path);
|
||||
if( html_template != -1 ) item.html_template = Db::AssertValue(r, row, html_template);
|
||||
if( modification_user_id != -1 ) item.modification_user_id = atol( Db::AssertValue(r, row, modification_user_id) );
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user