added a bigger real-life demo
This commit is contained in:
@@ -0,0 +1,21 @@
|
||||
#ifndef USER_DIRECTORY_HPP
|
||||
#define USER_DIRECTORY_HPP
|
||||
|
||||
#include "../core/Model.hpp"
|
||||
|
||||
#include "matador/utils/base_class.hpp"
|
||||
|
||||
namespace work::models::admin {
|
||||
struct UserDirectory : core::Model {
|
||||
std::string name;
|
||||
|
||||
template<typename Operator>
|
||||
void process( Operator& op ) {
|
||||
namespace field = matador::access;
|
||||
field::process( op, *matador::base_class<Model>( this ) );
|
||||
field::attribute( op, "name", name, 511 );
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
#endif //USER_DIRECTORY_HPP
|
||||
Reference in New Issue
Block a user