Patrikk,
Not any thumbnails was created.. image generator just create the
directory with the file name ... but doesn't create any thumbnail file
on it... but original is well download...
/filename_thumbail_directory/...nothing
filname_original.jpg
looks like PIL doesn't do his job... i m sure P
I want to create a multi-dimentional arry in a form element and
convert that to a list of dicts.
My form element looks like this:
What I was hoping to have was an arry named search with a key of
result.NAME and a value of result.CODE that looks like this:
search
[
NAME1=>CODE1
NAME2
On Sat, Feb 21, 2009 at 11:52 PM, Jlcarroll wrote:
> What is the best way to fix this? What if someone wants to enter a
> broken url in an admin page? What if the url isn't broken, just
> requires a login?
Please read the documentation for URLField, which explains how to
control this validation
when editing a url field in the admin, I entered the url of a page
that used apache to authenticate, and required a valid django user to
log in. The admin, said that hte url was broken, and required me to
"fix" the field before it would save it. There was no "over-ride, I
know what I am doing" opt
Try to modify your form_action to "/mysite/count/{{ number }}" and
edit urls.py to change corresponding rule as something like r'/mysite/
count/(?P\d*)'.
Doesn't that render_to_response line contains a typo? It must be
{'number':new_number}.
--~--~-~--~~~---~--~~
Yo
Well, Let me re-phrase that question: I'm currently using the
following line of code to populate text_input fields in the custom
form:
form.base_fields['r_date'].widget.attrs['value'] =
obj.transaction.trans_date
But is this acceptable way of coding? If yes, how can I populate
ChoiceFields?
--~--
On Feb 18, 9:14 pm, Malcolm Tredinnick
wrote:
> On Wed, 2009-02-18 at 18:07 -0800, adelevie wrote:
> > According to Djangobook, the philosophy of theadminsite is that all
> > users of it are "trusted" not just "authenticated," meaning you will
> > trust them to do the right thing.
>
> That's not
hi,
I trying to increase a number by hitting a submit button. So each time
you hit the button the site shows an increasing number. How can I
show each time the next number?
my "count.html"
-
{{ number }}
my "view.py"
-
Hi,
I need help in solving two small problems.
1. A form submitted, after validation calls HttpResponseRedirect
(reverse('view.get_links',args=(request.POST['data'])))
In url pattern
(r'^links/(?P.*)/',get_links),
I am trying to send one more argument along with "request.POST
['data'
That would work, except, as you say, computed values throw it off, and,
at least in my opinion, instantiating fields in the same way they're
defined in the models.py is the most sure-fire way to get things working.
It also has the nice side-effect of making the stored values of the
fields more hu
On Sat, Feb 21, 2009 at 5:48 PM, Andrew Godwin wrote:
>
> Heh, as I expected.
>
> So, when I first started on South, I initially tried introspecting the
> various fields to drag their parameters out of wherever they had been
> saved to - for example, max_length in a field goes to self.max_length.
Heh, as I expected.
So, when I first started on South, I initially tried introspecting the
various fields to drag their parameters out of wherever they had been
saved to - for example, max_length in a field goes to self.max_length.
Then, you have the special cases for Django core fields. For exa
On Sat, Feb 21, 2009 at 2:54 PM, Andrew Godwin wrote:
>
> Hello everyone,
>
> I'm currently working on the next version of South
> [http://south.aeracode.org], and I need some test fodder for our new
> models.py parser - rather than our previous approach using regexes and a
> reasonable amount of
could you be a bit more specific?
what exactly works? what not?
it seems that you can upload an image but the thumbnail is not
created. do you mean the actual "thumbnail" or one of the image-
versions named "thumbnail"?
patrick
On Feb 21, 11:50 am, leau2001 wrote:
> Hi,
>
> I try to use file
You have to use `Q` objects [1]
[1]:
http://docs.djangoproject.com/en/dev/topics/db/queries/#complex-lookups-with-q-objects
On Sat, Feb 21, 2009 at 9:40 PM, Nate Morse wrote:
>
> Before I go down the road of writing SQL by hand or using
> QuerySet.extra(...) [ don't know much about that yet:],
I'm writing a blog app (yeah, I know. super boring, right?), and I was
running into a strange issue where user comments were being issued a
default email address. Is there any way to prevent this from
happening?
The URL field is fine -- no default value is being set there.
I'm using django.contr
Hello everyone,
I'm currently working on the next version of South
[http://south.aeracode.org], and I need some test fodder for our new
models.py parser - rather than our previous approach using regexes and a
reasonable amount of hope, this time it's being done properly, using the
python parsing
Before I go down the road of writing SQL by hand or using
QuerySet.extra(...) [ don't know much about that yet:], I thought I
would ask if there is a way to achieve (within the QuerySet methods)
something like
...WHERE field_a = 'abc' OR field_b = '123' ...?
It seems if I do:
rs = mymodel.filter(
On Feb 21, 7:27 pm, 3xM <3...@detfalskested.dk> wrote:
> I've got 2 models:
>
>
> class Person(models.Model):
> ...
>
> class Project(models.Model):
> ...
> persons = models.ManyToManyField(Person)
>
>
> Now, how do I lookup Projects including person_a and person_b?
>
> I've
I've defined a custom ModelForm for one of my models. Many of the
custom form fields differ from the model fields. I've made the
'save_model' method to calculate required model_field_values from the
given form_field_values. Now after adding one instance, how can I do
the reverse? I mean, how to po
> http://code.djangoproject.com/ticket/8813
>
> If you could attach the file you dpasted to that ticket and note that you
> see this problem in the admin, that would probably be useful, as recreating
> it in admin should be easier than recreating the user-defined form, view,
> and models involved
I've got 2 models:
class Person(models.Model):
...
class Project(models.Model):
...
persons = models.ManyToManyField(Person)
Now, how do I lookup Projects including person_a and person_b?
I've tried chaining filters like this, but that won't work (returning
no results):
BTW, That is with a timezone of "America/New_York"
On Feb 21, 1:05 pm, Sean Brant wrote:
> Would something like this work?
>
> def U(self):
> "Seconds since the Unix epoch (January 1 1970 00:00:00 GMT)"
> import calendar
> timestamp = calendar.timegm(self.data.timetuple())
> retu
Would something like this work?
def U(self):
"Seconds since the Unix epoch (January 1 1970 00:00:00 GMT)"
import calendar
timestamp = calendar.timegm(self.data.timetuple())
return timestamp + time.timezone
Test:
r"""
>>> print dateformat.format(my_birthday, 'U')
40437
"""
fr
Hi,
I want to add already uploaded images to a models ImageFileField. I
finally managed to do this as follows:
(in the shell):
---
from trips.models import Event
from leden.models import Lid
from foto.models import Foto
from django.core.files.base import File
from
If you are using default Django sessions, they will be stored in the database.
>From the docs:
By default, Django stores sessions in your database (using the model
django.contrib.sessions.models.Session). Though this is convenient, in
some setups it's faster to store session data elsewhere, so Dj
Hi -
I am using the Django auth backend and I'd like to test which users
are currently logged in. I can't do this just by grabbing
User.objects.all() and testing each with is_authenticated, because the
User objects being User objects as opposed to AnonymousUser objects
will always return True for
On 2/21/2009 7:01 AM, Alex Gaynor wrote:
> On Sat, Feb 21, 2009 at 6:02 AM, David M. Besonen
> wrote:
>
>> has anyone seen any django code with spreadsheet-like
>> functionality?
>>
> What do you mean spreadsheet functionality? Do you mean a
> website like google docs?
yes. code i could integ
You could also create a rest-like interface with php if all you're
really doing with php is server side processing.
On Feb 20, 9:08 am, Matt McCants wrote:
> Hey there,
>
> Try setting the Handler to None just like you do with your media
> directory. With a basic PHP setup it should process the
You were right! There was a missing view!
Thanks!
--
Philippe
--
The trouble with common sense is that it is so uncommon.
On Friday 20 February 2009 18:11:44 Briel wrote:
> I've seen errors like this when an url is missing a view to link
> to. All urls defined must have a view aswel
On Sat, Feb 21, 2009 at 16:04, Alex Gaynor wrote:
>
>
> On Sat, Feb 21, 2009 at 7:50 AM, TiNo wrote:
>
>>
>> Hi,
>>
>> I am trying to use a model from an app that is on my python path, but
>> not in the INSTALLED_APPS setting. But I can't get it to work.
>>
>> Why would I want this? DRY. I want
Thanks. I checked carefully and all the defined URLs do have a view
defined. There are no apparent problems with the templates.
And this morning I'm getting a new error. A named url is reversed
correctly but the page is not found. Yesterday, it was found all
right.
Curiouser and curiouser!
-
On Sat, Feb 21, 2009 at 7:50 AM, TiNo wrote:
>
> Hi,
>
> I am trying to use a model from an app that is on my python path, but
> not in the INSTALLED_APPS setting. But I can't get it to work.
>
> Why would I want this? DRY. I want to use parts (ex. the 'PhotoSize'
> model) of a 3rd party app (ex.
On Sat, Feb 21, 2009 at 7:48 AM, Chris wrote:
>
> Is it a good idea to reuse admin's JS datepicker widget in other apps,
> and if so, what's the best way?
>
> I'm using django.contrib.admin.widgets.AdminDateWidget in my form, and
> I've added these JS tags to my template:
>
> admin/DateTimeShortc
On Sat, Feb 21, 2009 at 6:02 AM, David M. Besonen wrote:
>
> has anyone seen any django code with spreadsheet-like
> functionality?
>
> >
>
What do you mean spreadsheet functionality? Do you mean a website like
google docs? Or do you mean the ability to read or generate excel or csv
spreadsheets
What's the best way to display generic read-only model data on a
template, without having to manually write the html for each column
you want displayed? I'm toying around with a ModelForm, using custom
form widgets to format the data into strings instead of form fields.
Is there a better way?
--~-
Hi,
I am trying to use a model from an app that is on my python path, but
not in the INSTALLED_APPS setting. But I can't get it to work.
Why would I want this? DRY. I want to use parts (ex. the 'PhotoSize'
model) of a 3rd party app (ex. photologue), without it filling my
database with tables and
Is it a good idea to reuse admin's JS datepicker widget in other apps,
and if so, what's the best way?
I'm using django.contrib.admin.widgets.AdminDateWidget in my form, and
I've added these JS tags to my template:
admin/DateTimeShortcuts.js
admin/RelatedObjectLookups.js
calendar.js
core.js
Thi
Hi list!
I've been working for the past months or so on a project that reuses
imported data.
This data is extremely unreliable. I have to set up a lot of stuff to
normalize it throughout Django. However there is still a field I
haven't covered decently, ForeignKeys.
I have a good hundred tables
Hi,
I try to use filebrowser in my project, all is fine, but when i use
image generator, the rep was create but not any thumbnail...
PIL is on my python
Used django 1.0.2 released
whats wrong ?
thx
lo
--~--~-~--~~~---~--~~
You received this message because y
has anyone seen any django code with spreadsheet-like
functionality?
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubsc
41 matches
Mail list logo