added: function adduser

changed: errors (removed enum, there are macros now)
added: error messages to locales (winix_err_NN)
removed: templates: err_abuse.html err_others.html


git-svn-id: svn://ttmath.org/publicrep/winix/trunk@593 e52654a7-88a9-db11-a3e9-0013d4bc506e
This commit is contained in:
2010-02-28 00:08:10 +00:00
parent 3702efc5be
commit 71a63cc70e
160 changed files with 912 additions and 607 deletions

View File

@@ -1,5 +1,5 @@
/*
* This file is a part of CMSLU -- Content Management System like Unix
* This file is a part of Winix
* and is not publicly distributed
*
* Copyright (c) 2008-2009, Tomasz Sowa
@@ -34,7 +34,7 @@ void FunctionParser::ParseDirectories()
if( !pdir )
{
// there is no the root dir
request.status = Error::no_root_dir;
request.status = WINIX_ERR_NO_ROOT_DIR;
return;
}
@@ -78,12 +78,12 @@ void FunctionParser::ParseItem()
request.status = db.GetItem(parent_id, url, request.item);
if( request.status == Error::ok )
if( request.status == WINIX_ERR_OK )
{
if( request.role == Request::authorizer && request.item.auth == Item::auth_none )
{
log << log1 << "FP: item.url: " << url << " exists but has not a static content (authorizer role)" << logend;
request.status = Error::no_item;
request.status = WINIX_ERR_NO_ITEM;
return;
}
@@ -138,7 +138,7 @@ void FunctionParser::ParseParams()
void FunctionParser::Parse()
{
request.status = Error::ok;
request.status = WINIX_ERR_OK;
get_index = 0;
get_table_len = request.get_table.size();
request.pfunction = 0;
@@ -146,7 +146,7 @@ void FunctionParser::Parse()
ParseDirectories();
if( request.status != Error::ok )
if( request.status != WINIX_ERR_OK )
return;
ParseFunction();
@@ -155,14 +155,14 @@ void FunctionParser::Parse()
{
ParseItem();
if( request.status != Error::ok )
if( request.status != WINIX_ERR_OK )
return;
ParseFunction();
if( !request.pfunction && get_index != get_table_len )
{
request.status = Error::no_function;
request.status = WINIX_ERR_NO_FUNCTION;
log << log3 << "FP: Parse: unknown function: \"" << request.get_table[get_index] << "\"" << logend;
return;
}