diff --git a/app/library/App/Model/Projects.php b/app/library/App/Model/Projects.php new file mode 100644 index 0000000..c024266 --- /dev/null +++ b/app/library/App/Model/Projects.php @@ -0,0 +1,83 @@ +setSchema("public"); + $this->belongsTo('user_id', '\User', 'id', ['alias' => 'User']); + } + + /** + * Returns table name mapped in the model. + * + * @return string + */ + public function getSource() + { + return 'projects'; + } + + /** + * Allows to query a set of records that match the specified conditions + * + * @param mixed $parameters + * @return Projects[]|Projects + */ + public static function find($parameters = null) + { + return parent::find($parameters); + } + + /** + * Allows to query the first record that match the specified conditions + * + * @param mixed $parameters + * @return Projects + */ + public static function findFirst($parameters = null) + { + return parent::findFirst($parameters); + } + +} -- libgit2 0.21.4