generated from Sithas/conan_template
Внесение в контроллеры Session MySQL и MySQLUserDAO
This commit is contained in:
@@ -1,12 +1,12 @@
|
||||
#pragma once
|
||||
|
||||
#include <memory>
|
||||
|
||||
#include <boost/beast.hpp>
|
||||
|
||||
#include "Controller.h"
|
||||
#include "../db/mysql_connector.h"
|
||||
#include "../DAO/IUserDAO.h"
|
||||
#include "AuthRegistrationExecutor.h"
|
||||
#include "RootExecutor.h"
|
||||
#include "../DAO/MySQLUserDAO.h"
|
||||
|
||||
namespace uad
|
||||
{
|
||||
@@ -16,7 +16,9 @@ void HandleRequest(
|
||||
boost::beast::http::request<Body, boost::beast::http::basic_fields<Allocator>>&& req,
|
||||
Send&& send)
|
||||
{
|
||||
static RootExecutor<Body, Allocator, boost::beast::http::string_body, Send> root_executor;
|
||||
static RootExecutor<Body, Allocator, boost::beast::http::string_body, Send> root_executor(
|
||||
GetMySqlSession(), std::make_shared<MySQLUserDAO>(GetMySqlSession())
|
||||
);
|
||||
|
||||
root_executor(doc_root, std::move(req), std::forward<Send>(send));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user