changed: now Request class is a model class - we have fields() method there to map fields for ezc templates (currently only dir_tab)

removed: [dir_tab] ezc statement
changed: Ls winix function loads its own dir_tab container (beforehand it was loaded by [dir_tab] ezc statement)
         it's available by [child_dirs] name
This commit is contained in:
2021-06-17 21:44:29 +02:00
parent 4db421d6c3
commit ebd791a256
11 changed files with 146 additions and 69 deletions

View File

@@ -88,6 +88,7 @@ App::App()
winix_request.set_cur(&cur);
winix_request.set_session_manager(&session_manager);
winix_request.set_locale(&TemplatesFunctions::locale);
winix_request.set_model_connector(&model_connector);
// //////////////////////////////////

View File

@@ -53,6 +53,13 @@ Request::Request()
}
void Request::fields()
{
field(L"", L"dirs", dir_tab);
}
void Request::SetConfig(Config * pconfig)
{
config = pconfig;

View File

@@ -50,6 +50,8 @@
#include "outstreams.h"
#include "models.h"
#include "models/winixmodel.h"
namespace Winix
{
@@ -62,7 +64,7 @@ class FunctionBase;
struct Request
struct Request : public WinixModel
{
// how many input headers can be put to in_headers struct
static const size_t MAX_INPUT_HEADERS = 32;
@@ -360,6 +362,10 @@ struct Request
Request();
void SetConfig(Config * pconfig);
void fields();
void RequestStarts();
void Clear();