here is my "Project" Model :
class Project(models.Model):
name = models.CharField(max_length=200, verbose_name="Project name", default="")
I know how to use QuerySets to filter all the Project objects who contains "result" in their name (like this) :
projects = Project.objects.filter(name__contains=result)
(if I have three projects named "Hello", "Hello_World" and "Hi" and I do this :
hello_projects = Project.objects.filter(name__contains="Hello")
my QuerySet "hello_projects" will contains the projects named "Hello" and "Hello_World")
I want to do it in the opposite way, and filter the projects who have their name in my result.
For example, if "result" is "Hello_World_Its_Me", I want to get all projects who have their names inside result, so "Hello", and "Hello_World"
Is there a way to do it ?