For now I get a task_id from the async_result and have to save it the get it back later.
Would be better if I knew what the task_id what made of so I can calculate it back instead of pulling from the DB. E.G: set a task with task_id=("%s-%s" % (user_id, datetime)).
...
In my localhost Django administrator I am able to fill-in Date and Time fields by clicking on the little "Date" and "Time" helper icons next to my pub_date field. However, the same administrator on my Server does NOT show these icons. The server-side admin also doesn't pop open a pop-up window for the little "+" plus sign for fields in r...
There is code and Tracebeck. What I'm doing wrong?
media=MediaObject.objects.get(
Q(on_air__range=(strt_time,end_time)),
Q(channel=3),
Q(name__icontains="qwwwwwww".decode('utf-8')|Q(name__icontains="cccccccc dddddd".decode('utf-8')))
)
Traceback (most recent call last):
File "C:\Documents and Settings\POLINOM\web\...
I'm using a web service backend to provide authentication to Django, and the get_user method must retain a cookie provided by the web service in order to associate with a session. Right now, I make my remote calls just by calling urllib2.urlopen(myTargetService) but this doesn't pass the cookie for the current session along.
I have crea...
Hi
I've got a Http BasicAuth decorator wrapped around most of my views in django on my testing site and no BasicAuth on my production site. If debug = false it simply returns the view, otherwise it does a BasicAuth password check.
I just discovered that the nice debug error pages are still visible to any little hacker, though. (Obvious...
So I've finally figured out a system for refreshing portions of the screen using Ajax, Taconite, and jQuery within Django, sortof like Ruby on Rails partials.
I was pleased, but unfortunately, the code associated with clicking and drag and dropping is not executing.
I'm replacing the html inside divs.
How can I keep my code modula...
Hi there,
I was wondering what's the best way o modify django-admin? That is, the best way to modify it and keep compatibility with future releases?
Specifically Im refering to the search_fields where using (=field) gets converted to field_iexact in the query construction when I need field_exact ?
I just to make modifications in a wa...
Hello,
I have a system which keeps lots of "records" and need to integrate a component which will produce reports of any selected records.
To the user, it looks like this:
Click "Create Report"
Select the records to be included in the report.
Hit "Submit" and the report is displayed.
To me I think:
Load all records.
Create a Repo...
I'm creating a Django-powered site for my newspaper-ish site. The least obvious and common-sense task that I have come across in getting the site together is how best to generate a "top articles" list for the sidebar of the page.
The first thing that came to mind was some sort of database column that is updated (based on what?) with ev...
Think of this:
You create a CMS of some sort, which asks you for an application name and a csv file for that application.
Then it automatically creates that app on the fly, creates the required model.py based on the csv columns, activates the admin page for it and allows only you to have the full permission to this new table via django ...
Currently I am having three sites for example let it be site1, site2 and site3 . Each site require authentication. Both site1 and site2 take the same database let it be "Portfolio" database and site3 is having a different database let it be "site3specific" database.
I am planning to have a Common Account database for keeping the login c...
Hello, I want my urls.py to capture a long url setting as such:
/get/<lowercase_string>/<integer>/<date>/<date>/
For instance: www.mysite.com/get/ams/221/12-23-2010/01-10-2011/, as you may see date is in month/day/year format.
As my regex knowledge is near to nothing, I will be grateful for you guidance. I will be capturing <lowercas...
For a medical website I'm trying to model a questionnaire that should result in a range of possible diagnoses. The questionnaire is fairly complex with a lot of conditionals. I made a flowchart/decision tree to reflect this questionnaire. I'm using Django to make the website.
Currently I'm thinking of using Python Graph to turn the flow...
Hi,
I'm trying to store sections of a document in a Django app. The model looks like:
class Section(models.Model):
project = models.ForeignKey(Project)
parent_section = models.ForeignKey('Section', blank=True, null=True, related_name='child_set')
predecessor_section = models.ForeignKey('Section', blank=True, null=True, related_na...
Hi folks,
I'm just wondering if all I need is the identity url in order to to theoretically attach an OpenID account to a user's account.
I have identity urls that look like the following: https://www.google.com/accounts/o8/id?id=YGnyuGHMUmhUI98nuhUMhu98nuN.
Is this different between OpenID 1.0 and 2.0?
Just in case someone asks: I'm...
Hi everyone,
I'm using Django on a Debian VM, django server is loaded through nginx. Everything's working fine 'til now, except the admin interface. In fact, the admin site, doesn't load the "look and feel" of the interface. It seems that Css and images aren't loading at all, any ideas?
Thanks.
...
I'm getting object 'pyamf.amf3.ByteArray'
How can I save it to ImageField ?
...
I have a template that has a button that posts just the button's name to a view which has the following code:
if request.POST:
a = request.POST
name = mymodel.objects.get(id = a )[0]
return HttpResponse(name)
request.POST has the name of the button that submitted the post. THE error is: int() argument must be a string ...
How do I travel through multiple foreign keys in Django? I've tried everything I can think of from the django docs, but I'm obviously missed something (extreme newbie). I have models for scientists, experiments, and theories.
If I want to look at a particular Theory (let's call it 'relativity') and get a list of all of the emails of...
hi I want to override django.views.generic.create_update.create_object
To be more precise when a create is called on an object[here projects] via url
eg :http://localhost:8000/projects/create/
i need to check some permissions before the control gets passed to the create_object. I know decorators would help me do it .I tried using dec...