-
Notifications
You must be signed in to change notification settings - Fork 100
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add searchable feature for plugins on plublic repo #448
base: master
Are you sure you want to change the base?
Conversation
chris_backend/plugins/models.py
Outdated
from cgitb import lookup | ||
from dataclasses import field |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What are these two imports for?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Must have been picked by the VsCode
extension ... I do not think they add on what I was trying to do. I have disabled the extension
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove these lines. I recommend you review your git diff
before making commits.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you, I have made chnages
chris_backend/plugins/models.py
Outdated
@@ -240,11 +242,19 @@ def search_name_title_category(self, queryset, name, value): | |||
lookup = lookup | models.Q(meta__category__icontains=value) | |||
return queryset.filter(lookup) | |||
|
|||
|
|||
def search_name_public_rep(self, queryset, name, value): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What is the purpose of this function definition?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Trying to return any value that contains public_repo
when you search
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Where is being called?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
My understanding is from pluginMeta table
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
public_repo = django_filters.CharFilter(field_name='meta__type', lookup_expr='icontains')
should be changed to
public_repo = django_filters.CharFilter(field_name='meta__public_repo, lookup_expr='icontains')
@jbernal0019 Thank you, I have made changes |
Add a searchable feature for plugins on public repo #439 which closes the earlier pr @jennydaman