From f22dbaae899f5e000f4066bf7db0071eba620805 Mon Sep 17 00:00:00 2001 From: PARK BYUNG JUN Date: Thu, 25 Aug 2022 02:36:56 +0000 Subject: [PATCH] bug fixed --- src/repositories/member_class/repository.rs | 6 ++++++ src/repositories/member_level/repository.rs | 6 ++++++ 2 files changed, 12 insertions(+) diff --git a/src/repositories/member_class/repository.rs b/src/repositories/member_class/repository.rs index eda64ab..9109ae1 100644 --- a/src/repositories/member_class/repository.rs +++ b/src/repositories/member_class/repository.rs @@ -69,6 +69,9 @@ impl Repository { if let Some(sp) = &s.name_like { q = q.filter(member_classes::dsl::name.like(sp)); } + if let Some(sp) = s.show { + q = q.filter(member_classes::dsl::show.eq(sp)); + } } q.count().get_result(conn) @@ -86,6 +89,9 @@ impl Repository { if let Some(sp) = &s.name_like { q = q.filter(member_classes::dsl::name.like(sp)); } + if let Some(sp) = s.show { + q = q.filter(member_classes::dsl::show.eq(sp)); + } } if let Some(p) = &find_all.pagination { diff --git a/src/repositories/member_level/repository.rs b/src/repositories/member_level/repository.rs index f058adb..eba96d8 100644 --- a/src/repositories/member_level/repository.rs +++ b/src/repositories/member_level/repository.rs @@ -69,6 +69,9 @@ impl Repository { if let Some(sp) = &s.name_like { q = q.filter(member_levels::dsl::name.like(sp)); } + if let Some(sp) = s.show { + q = q.filter(member_levels::dsl::show.eq(sp)); + } } q.count().get_result(conn) @@ -86,6 +89,9 @@ impl Repository { if let Some(sp) = &s.name_like { q = q.filter(member_levels::dsl::name.like(sp)); } + if let Some(sp) = s.show { + q = q.filter(member_levels::dsl::show.eq(sp)); + } } if let Some(p) = &find_all.pagination {