diff --git a/drogon_ctl/templates/model_cc.csp b/drogon_ctl/templates/model_cc.csp index 365ef374..a3902aa2 100644 --- a/drogon_ctl/templates/model_cc.csp +++ b/drogon_ctl/templates/model_cc.csp @@ -52,7 +52,12 @@ const bool [[className]]::hasPrimaryKey = true; <%c++ }else{%> const bool [[className]]::hasPrimaryKey = false; <%c++}%> -const std::string [[className]]::tableName = "[[tableName]]"; +const std::string [[className]]::tableName = "<%c++ +if(!schema.empty()) +{ + $$<[[tableName]]"; const std::vector [[className]]::_metaData={ <%c++for(size_t i=0;i &advice) override { - getLoop()->runInLoop(advice); + getLoop()->queueInLoop(advice); return *this; }