sowinski

Results 46 comments of sowinski

I use this peace of code for general statistics per Day with some filter for a specific kind of objects. from hitcount.models import Hit from django.contrib.contenttypes.models import ContentType content_type =...

I ended up with this code. But it is super slow. ``` Building.objects.filter(user=self.request.user) .annotate(get_hits_lastmonth=Coalesce(Subquery(hitcount_30.values('myhits')[:1], output_field=IntegerField()), 0)) \ .annotate(get_hits_lastweek=Coalesce(Subquery(hitcount_7.values('myhits')[:1], output_field=IntegerField()), 0)) \ .annotate(get_hits_yesterday=Coalesce(Subquery(hitcount_1.values('myhits')[:1], output_field=IntegerField()), 0)) ``` I am using this request...

Same here importing cities1000.zip. Is this project dead?

@blag I have no experience with opensource projects but if you want I can help you. At least I can show how to crash django-cities. (Maybe afterwards I can write...

I was investigating where the problem is. On geoames.org you can see those informations and there are also in the files which you can download. Example: http://www.geonames.org/7118093/gallus.html "Innenstadt I" is...

In the config there is this line of code for district types: district_types = ['PPLX'] I have seen that the parents of PPLX is ADM5. I would like to include...

I would like to subscribe new registred user to all newsletter if the user select a checkbox at the registration. Is this possible? @sonus21 Could you figure out how to...

@simplenotezy Did you find a way to use classes?