No Blacklisted + Hoping and diffused research

This commit is contained in:
mr
2026-02-02 12:14:01 +01:00
parent c3352499fa
commit 0ffe98045e
6 changed files with 57 additions and 18 deletions

View File

@@ -8,7 +8,6 @@ import (
"oc-discovery/models"
oclib "cloud.o-forge.io/core/oc-lib"
"cloud.o-forge.io/core/oc-lib/dbs"
"cloud.o-forge.io/core/oc-lib/tools"
)
@@ -67,16 +66,5 @@ func (ps *PubSubService) publishEvent(
return topic.Publish(ctx, msg)
}
func (pc *PubSubService) getDefaultFilter(search string) map[string][]dbs.Filter {
return map[string][]dbs.Filter{ // filter by like name, short_description, description, owner, url if no filters are provided
"abstractintanciatedresource.abstractresource.abstractobject.name": {{Operator: dbs.LIKE.String(), Value: search}},
"abstractintanciatedresource.abstractresource.type": {{Operator: dbs.LIKE.String(), Value: search}},
"abstractintanciatedresource.abstractresource.short_description": {{Operator: dbs.LIKE.String(), Value: search}},
"abstractintanciatedresource.abstractresource.description": {{Operator: dbs.LIKE.String(), Value: search}},
"abstractintanciatedresource.abstractresource.owners.name": {{Operator: dbs.LIKE.String(), Value: search}},
"abstractintanciatedresource.abstractresource.abstractobject.creator_id": {{Operator: dbs.EQUAL.String(), Value: search}},
}
}
// TODO REVIEW PUBLISHING + ADD SEARCH ON PUBLIC : YES
// TODO : Search should verify DataType