Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
    Melvyn Sopacua
    @melvyn-sopacua
    Hello :)
    jpic ∞
    @jpic
    hello !
    Thomas Capricelli
    @orzel
    hi
    Angelo ^_^
    @angelo510
    hello. :)
    jpic ∞
    @jpic
    hi !
    that's not the company channel
    for some reason i am "Forbidden" to add you on https://gitter.im/yourlabs
    please accept github invitation for joining github.com/yourlabs, then you should have access to gitter.im/yourlabs
    this is just channel for django-autocomplete-light which should be deprecated by the end of year
    in favor of django-adapters or something
    jpic ∞
    @jpic
    Hi all! master branch protection has been activated, CI must pass for merge now. Also, we're looking to sponsor somebody to migrate from github to git.yourlabs.org, that has dedicated badass hardware for CI so then selenium would work great and we could activate them again, also it has kubernetes, so we could also have the demo site back up again, and eventually auto-deploy of temporary instance per-pull request on the kubernetes lab. No deadline, remote, flexible hour, flexible everything. Note that we have no paying customer on this product so we're really on a low budget.
    Serafeim Papastefanos
    @spapas
    Hello, is there any way to use dal 3.x in django /admin without overriding the form? Similar to how autocomplete_light.modelform_factory was used in 2.x to automatically create the dal-enabled forms ?
    Serafeim Papastefanos
    @spapas
    creating a form only for overriding a field is not really dry :|
    jpic ∞
    @jpic
    @spapas actually @guillouf found a pattern , it's currently in GFK, but can be extended to others
    @spapas if you want DRY, you need to make either the view generate the form field, either the form field generate the view, which is what guillouf does
    then he does urlpatterns += form.as_urls() or something
    jpic ∞
    @jpic
    but if you really mean "like in v2" then a controller layer or a modelform metaclass will work
    Serafeim Papastefanos
    @spapas
    Thanks @jpic! I'll take a look at your suggestions; I actually meant like in v2 (i.e using the modelform_factory). Isn't it possible to also implement a modelform_factory that would auto-use autocompletes in v3 ? Is this because autocompletes aren't "registered" in v3?
    jpic ∞
    @jpic
    @spapas you could iterate over urls and try to find the first matching view
    in the widget, that would find a default url
    yes there's no registry in v3, but even when you have a registry you have to fight the form class
    Serafeim Papastefanos
    @spapas
    yes probably iterating the urls could resolve the missing registry. I'll take a look at it thanks !
    jpic ∞
    @jpic
    @spapas that will only solve your "what should be the default url for a field" problem, not your "have default autocomplete fields in a modelform" problem
    Serafeim Papastefanos
    @spapas
    yes it could be problematic if there are multiple autocompletes for a field. but its a first step at least
    jpic ∞
    @jpic
    ok course but the issue was the same with a registry: last registered one wins