feat: partially added filters to GitRepo CLI

This commit is contained in:
Jef Roosens 2022-05-18 08:22:13 +02:00
parent 1e079143cd
commit 5e81dadce3
Signed by: Jef Roosens
GPG key ID: B580B976584B5F30
5 changed files with 60 additions and 6 deletions

View file

@ -1,5 +1,6 @@
module db
[params]
pub struct GitRepoFilter {
pub mut:
limit u64 = 25

View file

@ -78,6 +78,7 @@ pub fn git_repo_from_params(params map[string]string) ?GitRepo {
// get_git_repos returns all GitRepo's in the database.
pub fn (db &VieterDb) get_git_repos(filter GitRepoFilter) []GitRepo {
println(filter)
// This seems to currently be blocked by a bug in the ORM, I'll have to ask
// around.
if filter.repo != '' {