added: created directory 'content' which has Content:: files
added: created directory 'templates' which has Templates:: and TemplatesFunctions:: files changed: content.cpp split into many files (directory 'content') changed: templates.cpp split into many files (directory 'templates') added: full permissions changed: building of the program (GNU make is used now) Makefile and Makefile.dep added into directories added: a parser 'FunctionParser' is used to parse the GET string it recognizes directories, items, functions, functions parameters added: other classes: Function, Functions added: function: ls, privileges changed: function 'id' to 'node' changed: version: to 0.2.0 added/changed: a lot of work have been done git-svn-id: svn://ttmath.org/publicrep/cmslu/trunk@469 e52654a7-88a9-db11-a3e9-0013d4bc506e
This commit is contained in:
165
templates/templates.h
Executable file
165
templates/templates.h
Executable file
@@ -0,0 +1,165 @@
|
||||
/*
|
||||
* This file is a part of CMSLU -- Content Management System like Unix
|
||||
* and is not publicly distributed
|
||||
*
|
||||
* Copyright (c) 2008, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
*/
|
||||
|
||||
#ifndef headerfiletemplates
|
||||
#define headerfiletemplates
|
||||
|
||||
#include <iomanip>
|
||||
|
||||
#include "../../ezc/src/ezc.h"
|
||||
#include "../core/data.h"
|
||||
#include "../core/request.h"
|
||||
#include "../core/item.h"
|
||||
#include "../core/db.h"
|
||||
#include "../core/error.h"
|
||||
#include "../core/user.h"
|
||||
#include "../core/group.h"
|
||||
#include "../core/users.h"
|
||||
#include "../core/groups.h"
|
||||
#include "../core/log.h"
|
||||
|
||||
|
||||
|
||||
|
||||
namespace TemplatesFunctions
|
||||
{
|
||||
using Ezc::Info;
|
||||
|
||||
/*
|
||||
sys
|
||||
*/
|
||||
void sys_ver_major(Info & i);
|
||||
void sys_ver_minor(Info & i);
|
||||
void sys_ver_revision(Info & i);
|
||||
|
||||
|
||||
/*
|
||||
doc
|
||||
*/
|
||||
void doc_language(Info & i);
|
||||
void doc_title(Info & i);
|
||||
void doc_charset(Info & i);
|
||||
void doc_base_url(Info & i);
|
||||
void doc_current_url(Info & i);
|
||||
void doc_status_error(Info & i);
|
||||
void doc_status_code(Info & i);
|
||||
|
||||
|
||||
/*
|
||||
item
|
||||
*/
|
||||
void item_is(Info & i);
|
||||
void item_id(Info & i);
|
||||
void item_subject(Info & i);
|
||||
void item_subject_noescape(Info & i);
|
||||
void item_content(Info & i);
|
||||
void item_content_noescape(Info & i);
|
||||
void item_privileges(Info & i);
|
||||
void item_dir(Info & i); // the same as full_dir()
|
||||
void item_url(Info & i);
|
||||
void item_link(Info & i);
|
||||
|
||||
// !! wprowadzic item_old_is ?
|
||||
void item_old_id(Info & i);
|
||||
void item_old_subject(Info & i);
|
||||
void item_old_subject_noescape(Info & i);
|
||||
void item_old_content(Info & i);
|
||||
void item_old_content_noescape(Info & i);
|
||||
void item_old_privileges(Info & i);
|
||||
void item_old_dir(Info & i);
|
||||
void item_old_url(Info & i);
|
||||
void item_old_link(Info & i);
|
||||
|
||||
void item_tab(Info & i);
|
||||
void item_tab_id(Info & i);
|
||||
void item_tab_subject(Info & i);
|
||||
void item_tab_subject_noescape(Info & i);
|
||||
void item_tab_content(Info & i);
|
||||
void item_tab_content_noescape(Info & i);
|
||||
void item_tab_privileges(Info & i);
|
||||
void item_tab_dir(Info & i);
|
||||
void item_tab_url(Info & i);
|
||||
void item_tab_link(Info & i);
|
||||
|
||||
|
||||
/*
|
||||
dir
|
||||
*/
|
||||
void dir(Info & i);
|
||||
|
||||
void dir_childs_tab(Info & i);
|
||||
void dir_childs_tab_url(Info & i);
|
||||
|
||||
void dir_tab(Info & i);
|
||||
void dir_tab_url(Info & i);
|
||||
void dir_tab_link(Info & i);
|
||||
|
||||
|
||||
/*
|
||||
user
|
||||
*/
|
||||
void user_name(Info & i);
|
||||
void user_logged(Info & i);
|
||||
void user_super_user(Info & i);
|
||||
|
||||
|
||||
/*
|
||||
privileges
|
||||
*/
|
||||
void priv_user_tab(Info & i);
|
||||
void priv_user_tab_name(Info & i);
|
||||
void priv_user_tab_isdefault(Info & i);
|
||||
|
||||
void priv_group_tab(Info & i);
|
||||
void priv_group_tab_name(Info & i);
|
||||
void priv_group_tab_isdefault(Info & i);
|
||||
|
||||
|
||||
|
||||
/*
|
||||
done
|
||||
*/
|
||||
void done_errors(Info & i);
|
||||
void done_status(Info & i);
|
||||
void done_status_incorrect_dir(Info & i);
|
||||
|
||||
void done_added_item(Info & i);
|
||||
void done_edited_item(Info & i);
|
||||
void done_deleted_item(Info & i);
|
||||
void done_privileged_item(Info & i);
|
||||
void done_loggedout(Info & i);
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
} // namespace TemplatesFunctions
|
||||
|
||||
|
||||
|
||||
|
||||
class Templates
|
||||
{
|
||||
|
||||
|
||||
|
||||
public:
|
||||
|
||||
|
||||
void Read();
|
||||
void Generate();
|
||||
|
||||
void CreateFunctions();
|
||||
|
||||
|
||||
};
|
||||
|
||||
|
||||
|
||||
#endif
|
Reference in New Issue
Block a user