Skip to content

Commit

Permalink
feat(authN) - update updatedBy on Delete
Browse files Browse the repository at this point in the history
  • Loading branch information
michalkrzyz committed Dec 10, 2024
1 parent eda02c8 commit cfb4e85
Show file tree
Hide file tree
Showing 55 changed files with 150 additions and 101 deletions.
1 change: 1 addition & 0 deletions internal/api/graphql/graph/baseResolver/activity.go
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ func ActivityBaseResolver(app app.Heureka, ctx context.Context, filter *model.Ac
ServiceCCRN: filter.ServiceCcrn,
ServiceId: sId,
IssueId: issueId,
State: entity.GetStateFilterType(filter.State),
}

opt := GetListOptions(requestedFields)
Expand Down
1 change: 1 addition & 0 deletions internal/api/graphql/graph/baseResolver/component.go
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@ func ComponentBaseResolver(app app.Heureka, ctx context.Context, filter *model.C
f := &entity.ComponentFilter{
Paginated: entity.Paginated{First: first, After: afterId},
CCRN: filter.ComponentCcrn,
State: entity.GetStateFilterType(filter.State),
}

opt := GetListOptions(requestedFields)
Expand Down
2 changes: 2 additions & 0 deletions internal/api/graphql/graph/baseResolver/component_instance.go
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,7 @@ func ComponentInstanceBaseResolver(app app.Heureka, ctx context.Context, filter
ServiceCcrn: filter.ServiceCcrn,
ComponentVersionId: copmonentVersionId,
Search: filter.Search,
State: entity.GetStateFilterType(filter.State),
}

opt := GetListOptions(requestedFields)
Expand Down Expand Up @@ -146,6 +147,7 @@ func CcrnBaseResolver(app app.Heureka, ctx context.Context, filter *model.Compon
f := &entity.ComponentInstanceFilter{
CCRN: filter.Ccrn,
Search: filter.Search,
State: entity.GetStateFilterType(filter.State),
}

opt := GetListOptions(requestedFields)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,7 @@ func ComponentVersionBaseResolver(app app.Heureka, ctx context.Context, filter *
ComponentId: componentId,
ComponentCCRN: filter.ComponentCcrn,
Version: filter.Version,
State: entity.GetStateFilterType(filter.State),
}

opt := GetListOptions(requestedFields)
Expand Down
1 change: 1 addition & 0 deletions internal/api/graphql/graph/baseResolver/evidence.go
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ func EvidenceBaseResolver(app app.Heureka, ctx context.Context, filter *model.Ev
Paginated: entity.Paginated{First: first, After: afterId},
ActivityId: activityId,
IssueMatchId: imId,
State: entity.GetStateFilterType(filter.State),
}

opt := GetListOptions(requestedFields)
Expand Down
9 changes: 2 additions & 7 deletions internal/api/graphql/graph/baseResolver/issue.go
Original file line number Diff line number Diff line change
Expand Up @@ -110,10 +110,8 @@ func IssueBaseResolver(app app.Heureka, ctx context.Context, filter *model.Issue
IssueMatchStatus: nil, //@todo Implement
IssueMatchDiscoveryDate: nil, //@todo Implement
IssueMatchTargetRemediationDate: nil, //@todo Implement
}

if filter.State != nil {
f.State = entity.StateFilterType(*filter.State)
State: entity.GetStateFilterType(filter.State),
}

opt := GetIssueListOptions(requestedFields)
Expand Down Expand Up @@ -181,10 +179,7 @@ func IssueNameBaseResolver(app app.Heureka, ctx context.Context, filter *model.I
IssueMatchStatus: nil, //@todo Implement
IssueMatchDiscoveryDate: nil, //@todo Implement
IssueMatchTargetRemediationDate: nil, //@todo Implement
}

if filter.State != nil {
f.State = entity.StateFilterType(*filter.State)
State: entity.GetStateFilterType(filter.State),
}

opt := GetListOptions(requestedFields)
Expand Down
1 change: 1 addition & 0 deletions internal/api/graphql/graph/baseResolver/issue_match.go
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,7 @@ func IssueMatchBaseResolver(app app.Heureka, ctx context.Context, filter *model.
ComponentCCRN: filter.ComponentCcrn,
PrimaryName: filter.PrimaryName,
IssueType: lo.Map(filter.IssueType, func(item *model.IssueTypes, _ int) *string { return pointer.String(item.String()) }),
State: entity.GetStateFilterType(filter.State),
}

opt := GetListOptions(requestedFields)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ func IssueMatchChangeBaseResolver(app app.Heureka, ctx context.Context, filter *
Action: lo.Map(filter.Action, func(item *model.IssueMatchChangeActions, _ int) *string { return pointer.String(item.String()) }),
ActivityId: aId,
IssueMatchId: imId,
State: entity.GetStateFilterType(filter.State),
}

opt := GetListOptions(requestedFields)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,7 @@ func IssueRepositoryBaseResolver(app app.Heureka, ctx context.Context, filter *m
ServiceId: serviceId,
Name: filter.Name,
ServiceCCRN: filter.ServiceCcrn,
State: entity.GetStateFilterType(filter.State),
}

opt := GetListOptions(requestedFields)
Expand Down
2 changes: 2 additions & 0 deletions internal/api/graphql/graph/baseResolver/issue_variant.go
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ func IssueVariantBaseResolver(app app.Heureka, ctx context.Context, filter *mode
IssueId: issueId,
IssueRepositoryId: irId,
SecondaryName: filter.SecondaryName,
State: entity.GetStateFilterType(filter.State),
}

opt := GetListOptions(requestedFields)
Expand Down Expand Up @@ -163,6 +164,7 @@ func EffectiveIssueVariantBaseResolver(app app.Heureka, ctx context.Context, fil
f := &entity.IssueVariantFilter{
Paginated: entity.Paginated{First: first, After: afterId},
IssueMatchId: imId,
State: entity.GetStateFilterType(filter.State),
}

opt := GetListOptions(requestedFields)
Expand Down
2 changes: 2 additions & 0 deletions internal/api/graphql/graph/baseResolver/service.go
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,7 @@ func ServiceBaseResolver(app app.Heureka, ctx context.Context, filter *model.Ser
IssueRepositoryId: irId,
SupportGroupId: sgId,
Search: filter.Search,
State: entity.GetStateFilterType(filter.State),
}

opt := GetListOptions(requestedFields)
Expand Down Expand Up @@ -159,6 +160,7 @@ func ServiceCcrnBaseResolver(app app.Heureka, ctx context.Context, filter *model
SupportGroupCCRN: filter.SupportGroupCcrn,
CCRN: filter.ServiceCcrn,
OwnerName: filter.UserName,
State: entity.GetStateFilterType(filter.State),
}

opt := GetListOptions(requestedFields)
Expand Down
2 changes: 2 additions & 0 deletions internal/api/graphql/graph/baseResolver/support_group.go
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ func SupportGroupBaseResolver(app app.Heureka, ctx context.Context, filter *mode
ServiceId: serviceId,
UserId: userId,
CCRN: filter.SupportGroupCcrn,
State: entity.GetStateFilterType(filter.State),
}

opt := GetListOptions(requestedFields)
Expand Down Expand Up @@ -112,6 +113,7 @@ func SupportGroupCcrnBaseResolver(app app.Heureka, ctx context.Context, filter *
Paginated: entity.Paginated{},
UserId: userIds,
CCRN: filter.SupportGroupCcrn,
State: entity.GetStateFilterType(filter.State),
}

opt := GetListOptions(requestedFields)
Expand Down
3 changes: 3 additions & 0 deletions internal/api/graphql/graph/baseResolver/user.go
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ func UserBaseResolver(app app.Heureka, ctx context.Context, filter *model.UserFi
ServiceId: serviceId,
Name: filter.UserName,
UniqueUserID: filter.UniqueUserID,
State: entity.GetStateFilterType(filter.State),
}

opt := GetListOptions(requestedFields)
Expand Down Expand Up @@ -140,6 +141,7 @@ func UserNameBaseResolver(app app.Heureka, ctx context.Context, filter *model.Us
Paginated: entity.Paginated{},
Name: filter.UserName,
UniqueUserID: filter.UniqueUserID,
State: entity.GetStateFilterType(filter.State),
}

opt := GetListOptions(requestedFields)
Expand Down Expand Up @@ -178,6 +180,7 @@ func UniqueUserIDBaseResolver(app app.Heureka, ctx context.Context, filter *mode
Paginated: entity.Paginated{},
UniqueUserID: filter.UniqueUserID,
Name: filter.UserName,
State: entity.GetStateFilterType(filter.State),
}

opt := GetListOptions(requestedFields)
Expand Down
1 change: 1 addition & 0 deletions internal/api/graphql/graph/schema/activity.graphqls
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ type ActivityEdge implements Edge {
input ActivityFilter {
serviceCcrn: [String]
status: [ActivityStatusValues]
state: Int
}

enum ActivityStatusValues {
Expand Down
1 change: 1 addition & 0 deletions internal/api/graphql/graph/schema/component.graphqls
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ enum ComponentTypeValues {

input ComponentFilter {
componentCcrn: [String]
state: Int
}

type ComponentConnection implements Connection {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,4 +36,5 @@ input ComponentInstanceFilter {
ccrn: [String],
supportGroup: [String],
search:[String],
state: Int
}
Original file line number Diff line number Diff line change
Expand Up @@ -32,4 +32,5 @@ input ComponentVersionFilter {
componentCcrn: [String]
issueId: [String]
version: [String]
state: Int
}
1 change: 1 addition & 0 deletions internal/api/graphql/graph/schema/evidence.graphqls
Original file line number Diff line number Diff line change
Expand Up @@ -38,4 +38,5 @@ type EvidenceEdge implements Edge {

input EvidenceFilter {
placeholder: [Boolean]
state: Int
}
2 changes: 1 addition & 1 deletion internal/api/graphql/graph/schema/issue.graphqls
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ input IssueFilter {
primaryName: [String],
issueMatchStatus: [IssueMatchStatusValues],
issueType: [IssueTypes],
state: Int
state: Int,

componentVersionId: [String],

Expand Down
1 change: 1 addition & 0 deletions internal/api/graphql/graph/schema/issue_match.graphqls
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ input IssueMatchFilter {
severity: [SeverityValues]
affectedService: [String]
supportGroupCcrn: [String]
state: Int
}

#type CCloudSeverity {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ input IssueMatchChangeInput {

input IssueMatchChangeFilter {
action: [IssueMatchChangeActions]
state: Int
}

type IssueMatchChangeConnection implements Connection {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,4 @@ type IssueMatchFilterValue {
affectedService(filter: ServiceFilter): FilterItem
componentCcrn(filter: ComponentFilter): FilterItem
supportGroupCcrn(filter: SupportGroupFilter): FilterItem
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -32,4 +32,5 @@ input IssueRepositoryFilter {
serviceCcrn: [String]
serviceId: [String]
name: [String]
state: Int
}
1 change: 1 addition & 0 deletions internal/api/graphql/graph/schema/issue_variant.graphqls
Original file line number Diff line number Diff line change
Expand Up @@ -35,4 +35,5 @@ type IssueVariantEdge implements Edge {

input IssueVariantFilter {
secondaryName: [String]
state: Int
}
1 change: 1 addition & 0 deletions internal/api/graphql/graph/schema/service.graphqls
Original file line number Diff line number Diff line change
Expand Up @@ -42,4 +42,5 @@ input ServiceFilter {
userName: [String]
supportGroupCcrn: [String]
search: [String]
state: Int
}
1 change: 1 addition & 0 deletions internal/api/graphql/graph/schema/support_group.graphqls
Original file line number Diff line number Diff line change
Expand Up @@ -27,4 +27,5 @@ type SupportGroupEdge implements Edge {
input SupportGroupFilter {
supportGroupCcrn: [String],
userIds: [String],
state: Int
}
1 change: 1 addition & 0 deletions internal/api/graphql/graph/schema/user.graphqls
Original file line number Diff line number Diff line change
Expand Up @@ -32,4 +32,5 @@ input UserFilter {
userName: [String],
supportGroupIds: [String],
uniqueUserId: [String],
state: Int,
}
2 changes: 1 addition & 1 deletion internal/database/mariadb/activity.go
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ func (s *SqlDatabase) getActivityFilterString(filter *entity.ActivityFilter) str
fl = append(fl, buildFilterQuery(filter.ServiceCCRN, "S.service_ccrn= ?", OP_OR))
fl = append(fl, buildFilterQuery(filter.EvidenceId, "E.evidence_id = ?", OP_OR))
fl = append(fl, buildFilterQuery(filter.IssueId, "AHI.activityhasissue_issue_id = ?", OP_OR))
fl = append(fl, "A.activity_deleted_at IS NULL")
fl = appendStateFilterQuery(fl, "A.activity", filter.State)

return combineFilterQueries(fl, OP_AND)
}
Expand Down
2 changes: 1 addition & 1 deletion internal/database/mariadb/component.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ func (s *SqlDatabase) getComponentFilterString(filter *entity.ComponentFilter) s
fl = append(fl, buildFilterQuery(filter.CCRN, "C.component_ccrn = ?", OP_OR))
fl = append(fl, buildFilterQuery(filter.Id, "C.component_id = ?", OP_OR))
fl = append(fl, buildFilterQuery(filter.ComponentVersionId, "CV.componentversion_id = ?", OP_OR))
fl = append(fl, "C.component_deleted_at IS NULL")
fl = appendStateFilterQuery(fl, "C.component", filter.State)

return combineFilterQueries(fl, OP_AND)
}
Expand Down
2 changes: 1 addition & 1 deletion internal/database/mariadb/component_instance.go
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ func (s *SqlDatabase) getComponentInstanceFilterString(filter *entity.ComponentI
fl = append(fl, buildFilterQuery(filter.ComponentVersionId, "CI.componentinstance_component_version_id = ?", OP_OR))
fl = append(fl, buildFilterQuery(filter.CCRN, "CI.componentinstance_ccrn = ?", OP_OR))
fl = append(fl, buildFilterQuery(filter.Search, componentInstanceWildCardFilterQuery, OP_OR))
fl = append(fl, "CI.componentinstance_deleted_at IS NULL")
fl = appendStateFilterQuery(fl, "CI.componentinstance", filter.State)

filterStr := combineFilterQueries(fl, OP_AND)
return filterStr
Expand Down
2 changes: 1 addition & 1 deletion internal/database/mariadb/component_version.go
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ func (s *SqlDatabase) getComponentVersionFilterString(filter *entity.ComponentVe
fl = append(fl, buildFilterQuery(filter.ComponentId, "CV.componentversion_component_id = ?", OP_OR))
fl = append(fl, buildFilterQuery(filter.Version, "CV.componentversion_version = ?", OP_OR))
fl = append(fl, buildFilterQuery(filter.ComponentCCRN, "C.component_ccrn = ?", OP_OR))
fl = append(fl, "CV.componentversion_deleted_at IS NULL")
fl = appendStateFilterQuery(fl, "CV.componentversion", filter.State)

return combineFilterQueries(fl, OP_AND)
}
Expand Down
9 changes: 9 additions & 0 deletions internal/database/mariadb/database.go
Original file line number Diff line number Diff line change
Expand Up @@ -391,3 +391,12 @@ func getCursor(p entity.Paginated, filterStr string, stmt string) entity.Cursor
Limit: limit,
}
}

func appendStateFilterQuery(query []string, prefix string, state entity.StateFilterType) []string {
if state == entity.Active {
query = append(query, fmt.Sprintf("%s_deleted_at IS NULL", prefix))
} else if state == entity.Deleted {
query = append(query, fmt.Sprintf("%s_deleted_at IS NOT NULL", prefix))
}
return query
}
2 changes: 1 addition & 1 deletion internal/database/mariadb/evidence.go
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ func (s *SqlDatabase) getEvidenceFilterString(filter *entity.EvidenceFilter) str
fl = append(fl, buildFilterQuery(filter.ActivityId, "E.evidence_activity_id = ?", OP_OR))
fl = append(fl, buildFilterQuery(filter.UserId, "E.author_id = ?", OP_OR))
fl = append(fl, buildFilterQuery(filter.IssueMatchId, "IME.issuematchevidence_issue_match_id = ?", OP_OR))
fl = append(fl, "E.evidence_deleted_at IS NULL")
fl = appendStateFilterQuery(fl, "E.evidence", filter.State)

return combineFilterQueries(fl, OP_AND)
}
Expand Down
7 changes: 1 addition & 6 deletions internal/database/mariadb/issue.go
Original file line number Diff line number Diff line change
Expand Up @@ -51,12 +51,7 @@ func (s *SqlDatabase) getIssueFilterString(filter *entity.IssueFilter) string {
fl = append(fl, buildFilterQuery(filter.Type, "I.issue_type = ?", OP_OR))
fl = append(fl, buildFilterQuery(filter.PrimaryName, "I.issue_primary_name = ?", OP_OR))
fl = append(fl, buildFilterQuery(filter.Search, wildCardFilterQuery, OP_OR))
//TODO: create common function
if filter.State == entity.Active {
fl = append(fl, "I.issue_deleted_at IS NULL")
} else if filter.State == entity.Deleted {
fl = append(fl, "I.issue_deleted_at IS NOT NULL")
}
fl = appendStateFilterQuery(fl, "I.issue", filter.State)

return combineFilterQueries(fl, OP_AND)
}
Expand Down
2 changes: 1 addition & 1 deletion internal/database/mariadb/issue_match.go
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ func (s *SqlDatabase) getIssueMatchFilterString(filter *entity.IssueMatchFilter)
fl = append(fl, buildFilterQuery(filter.ComponentCCRN, "C.component_ccrn = ?", OP_OR))
fl = append(fl, buildFilterQuery(filter.IssueType, "I.issue_type = ?", OP_OR))
fl = append(fl, buildFilterQuery(filter.Search, wildCardFilterQuery, OP_OR))
fl = append(fl, "IM.issuematch_deleted_at IS NULL")
fl = appendStateFilterQuery(fl, "IM.issuematch", filter.State)

return combineFilterQueries(fl, OP_AND)
}
Expand Down
2 changes: 1 addition & 1 deletion internal/database/mariadb/issue_match_change.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ func (s *SqlDatabase) getIssueMatchChangeFilterString(filter *entity.IssueMatchC
fl = append(fl, buildFilterQuery(filter.ActivityId, "IMC.issuematchchange_activity_id = ?", OP_OR))
fl = append(fl, buildFilterQuery(filter.IssueMatchId, "IMC.issuematchchange_issue_match_id = ?", OP_OR))
fl = append(fl, buildFilterQuery(filter.Action, "IMC.issuematchchange_action = ?", OP_OR))
fl = append(fl, "IMC.issuematchchange_deleted_at IS NULL")
fl = appendStateFilterQuery(fl, "IMC.issuematchchange", filter.State)
return combineFilterQueries(fl, OP_AND)
}

Expand Down
2 changes: 1 addition & 1 deletion internal/database/mariadb/issue_repository.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ func (s *SqlDatabase) getIssueRepositoryFilterString(filter *entity.IssueReposit
fl = append(fl, buildFilterQuery(filter.Id, "IR.issuerepository_id = ?", OP_OR))
fl = append(fl, buildFilterQuery(filter.ServiceCCRN, "S.service_ccrn = ?", OP_OR))
fl = append(fl, buildFilterQuery(filter.ServiceId, "IRS.issuerepositoryservice_service_id = ?", OP_OR))
fl = append(fl, "IR.issuerepository_deleted_at IS NULL")
fl = appendStateFilterQuery(fl, "IR.issuerepository", filter.State)

return combineFilterQueries(fl, OP_AND)
}
Expand Down
2 changes: 1 addition & 1 deletion internal/database/mariadb/issue_variant.go
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ func (s *SqlDatabase) getIssueVariantFilterString(filter *entity.IssueVariantFil
fl = append(fl, buildFilterQuery(filter.IssueRepositoryId, "IV.issuevariant_repository_id = ?", OP_OR))
fl = append(fl, buildFilterQuery(filter.ServiceId, "IRS.issuerepositoryservice_service_id = ?", OP_OR))
fl = append(fl, buildFilterQuery(filter.IssueMatchId, "IM.issuematch_id = ?", OP_OR))
fl = append(fl, "IV.issuevariant_deleted_at IS NULL")
fl = appendStateFilterQuery(fl, "IV.issuevariant", filter.State)

return combineFilterQueries(fl, OP_AND)
}
Expand Down
2 changes: 1 addition & 1 deletion internal/database/mariadb/service.go
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ func (s *SqlDatabase) getServiceFilterString(filter *entity.ServiceFilter) strin
fl = append(fl, buildFilterQuery(filter.SupportGroupId, "SGS.supportgroupservice_support_group_id = ?", OP_OR))
fl = append(fl, buildFilterQuery(filter.OwnerId, "O.owner_user_id = ?", OP_OR))
fl = append(fl, buildFilterQuery(filter.Search, serviceWildCardFilterQuery, OP_OR))
fl = append(fl, "S.service_deleted_at IS NULL")
fl = appendStateFilterQuery(fl, "S.service", filter.State)

return combineFilterQueries(fl, OP_AND)
}
Expand Down
2 changes: 1 addition & 1 deletion internal/database/mariadb/service_issue_variant.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ func (s *SqlDatabase) getServiceIssueVariantFilterString(filter *entity.ServiceI
var fl []string
fl = append(fl, buildFilterQuery(filter.ComponentInstanceId, "CI.componentinstance_id = ?", OP_OR))
fl = append(fl, buildFilterQuery(filter.IssueId, "I.issue_id = ?", OP_OR))
fl = append(fl, "IV.issuevariant_deleted_at IS NULL")
fl = appendStateFilterQuery(fl, "IV.issuevariant", filter.State)

return combineFilterQueries(fl, OP_AND)
}
Expand Down
2 changes: 1 addition & 1 deletion internal/database/mariadb/support_group.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ func (s *SqlDatabase) getSupportGroupFilterString(filter *entity.SupportGroupFil
fl = append(fl, buildFilterQuery(filter.ServiceId, "SGS.supportgroupservice_service_id = ?", OP_OR))
fl = append(fl, buildFilterQuery(filter.CCRN, "SG.supportgroup_ccrn = ?", OP_OR))
fl = append(fl, buildFilterQuery(filter.UserId, "SGU.supportgroupuser_user_id = ?", OP_OR))
fl = append(fl, "SG.supportgroup_deleted_at IS NULL")
fl = appendStateFilterQuery(fl, "SG.supportgroup", filter.State)

return combineFilterQueries(fl, OP_AND)
}
Expand Down
Loading

0 comments on commit cfb4e85

Please sign in to comment.