myModelAdmin)
This code hasnt been tested but should be the route you want to take. You
can find more info on widgets here(
https://docs.djangoproject.com/en/1.3/ref/forms/widgets/). I hope this helps
you.
-Brian
On Sun, Oct 2, 2011 at 12:20 PM, Artemis wrote:
> Hi,
>
> I have an model
# do something to the old title then add it back to data
data['title'] = new_title
return data
admin.site.register(myModel, myModelAdmin)
Thats how I have been handling my validation issues. I hope this helps you
figure out your validation issues. If you are still having trouble po
match would help me
to decipher the problem.
I hope this helps,
Brian
On Mon, Oct 3, 2011 at 9:56 AM, He Jibo wrote:
> Hello,
>
> I want to match a url in urls.py. Can you teach me how to do it? Thanks.I
> have tried the following two versions. But as long as I put a . (dot) in the
>
Thanks for the info. I didn't know about either tastypie or piston. The easy
ability to throttle a users number of requests is awesome.
-Brian
On Mon, Oct 3, 2011 at 12:40 PM, sanket wrote:
> please checkout Tastypie .. I was able to RESTify my django app in
> couple of hours
&
Even though it is off topic from Django, I would recommend taking some time
to learn about unicode
<http://docs.python.org/howto/unicode.html>superscript and subscript
symbols.
Brian
On Tue, Oct 4, 2011 at 12:11 PM, Khuong Lien wrote:
> Hi All,
>
>
> I want to display supers
ments (True, False, None, numbers, strings,
tuples).
Brian
On Tue, Oct 4, 2011 at 7:23 PM, Martin J. Laubach wrote:
> Are you sure your context is thread-safe, ie. it's rebuilt from scratch
> every time you render an email and not re-used, stored in a global variable,
> class
.
http://www.w3schools.com/tags/tag_iframe.asp
Create a iframe_base.html template file that has the meta refresh tag included
in section and just the iframe parts should refresh.
Not sure if this is what you want, and not sure this is a good idea, but it
doesn't require javascript.
Brian S
ult with a
callable to set the lat/lng of the FarmersMarket object. It's an idea I
haven't tested, so I'm not positive it will work.
You could write some geocoding middleware that sets request.POST data in
some way as it passes through. I don't really like this solution since it
is
mysql generates an informational warning when running "drop table if
exists " if the table doesn't exist. Django then throws an
error and aborts.
Is there a good way to avoid this?
b.c.
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post t
Ubuntu has great cloud-init support for dealing with cloud startup scripts.
Works on most clouds: openstack, ec2, eucalyptus...
Sent from my iPhone
On Nov 13, 2011, at 8:52 PM, ydjango wrote:
> I was concerned that Ubuntu being a desktop OS might have some
> limitations which CENTOS or Debia
I've been trying to implement a relatively simple django app, in which
I need to have a multistep form and a dynamically generated choice
field. I'm using Django 1.3 and the Form Wizard.
In step one of the form, I ask for a URL from the user, which I'd like
to use to dynamically generate the list
with rabbitMQ so you
get instant scalability. Then your AJAX job status view can poll a job status
table that is updated by the task and you don't have to worry about threads.
https://github.com/ask/django-celery
Brian Schott
bfsch...@gmail.com
On Nov 27, 2011, at 8:54 PM, Nathan McCo
t;fil.write('coming from background')
>>fil.close()
>>
>>print Gene.objects.get(id=y+1)
>>return True
>>
>> @task
>> @transaction.commit_manually
>> def processXLS1(datasetObjectID):
>>print "proc
don't seem to get
reliable message delivery, but maybe I misread the site.
Brian Schott
bfsch...@gmail.com
On Nov 28, 2011, at 8:34 PM, Gelonida N wrote:
> On 11/28/2011 12:14 PM, Gelonida N wrote:
>> Hi,
>>
>> I'd like to use a light weight disp
null=True)
class Meta:
ordering = ['index',]
Brian Schott
bfsch...@gmail.com
On Nov 29, 2011, at 10:44 AM, Marc Edwards wrote:
> I need some help in resetting my thinking on creating my Django data
> model.
>
> I have previously created an XML sch
I have a url spec like so:
(r'^foo/$', 'blah')
I just noted from our server logs that if someone mistakenly types two
slashes ('foo//'), the page
gets served, but all of the relative links are broken. It's really
confusing. I believe it should be redirecting or 404ing instead.
I note that foo/bar
I don't think so. It's not issuing a redirect. It's just serving the
view, even though the url spec doesn't match.
On Thu, Dec 1, 2011 at 2:42 PM, creecode wrote:
> Hello Brain,
>
> Could it be you are seeing the results of the APPEND_SLASH setting <
> https://docs.djangoproject.com/en/1.3/ref/se
ay to determine what should be a separate
app. If you have a relathionships like Publishers -> Books, and Authors ->
Books should you try to break out Books, Authors, and Publishers as separate
apps?
Brian Schott
bfsch...@gmail.com
On Dec 5, 2011, at 5:18 AM, Håkon Erichsen wrote:
&
I think if you set:
new_cmd_str.id = None
That will force a new PK. Not sure why the CmdString constructor isn't
clearing this..
Brian Schott
bfsch...@gmail.com
On Dec 8, 2011, at 11:47 AM, Marc Edwards wrote:
> I'm looping through some JSON code and generating new model insta
I've been playing with django-shop. It looks lightweight, class extensible,
and lightweight, but haven't worked with it enough to recommend yet. That's
still in my scrum backlog...
Brian Schott
bfsch...@gmail.com
On Dec 8, 2011, at 11:58 AM, Nan wrote:
>> I'm g
Is there an easy way to use a ModelChoiceField with multiple databases?
The only thing I've seen that looks promising is overriding the form
__init__ and setting the queryset for the field. Seems kinda clunky.
--
You received this message because you are subscribed to the Google Groups
"Django
CloudFiles or S3? Replication is good because the MTBF plummets as you add
bits.
Brian Schott
bfsch...@gmail.com
On Dec 27, 2011, at 9:02 PM, Cameron wrote:
> Greetings all-
>
> I have a django site which is referencing about 1TB of static files at the
> moment and growing fast.
I have CACHE_MIDDLEWARE_ANONYMOUS_ONLY = True. It seems to cache pages
even for people who have logged in. For example, I can log into the
admin, and edit an object. If I then visit the view for that app, my
changes do not get seen until the 5 minute cache timeout hits.
I suspect my middleware ord
On Dec 28, 11:46 am, Hassan wrote:
> Dear All,
>
> I want to know if there is a way that i can get youtube videos to my
> website using a video url ?
>
> Best Regards ,
>
> Hassan AL-Natour
Have you seen the oEmbed specification?
http://oembed.com/
I believe there is a Django application that in
mited than I thought.
On Dec 28, 10:25 am, Brian Neal wrote:
> I have CACHE_MIDDLEWARE_ANONYMOUS_ONLY = True. It seems to cache pages
> even for people who have logged in. For example, I can log into the
> admin, and edit an object. If I then visit the view for that app, my
> change
he Google Groups
> "Django users" group.
> To post to this group, send email to django-users@googlegroups.com.
> To unsubscribe from this group, send email to
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/grou
Is overwriting settings.DEBUG the recommended way to get
connections[db].queries to work during a unit test?
--
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 unsubscribe from
I have two models. The second one has a ManyToMany to the first. Both
are managed. If I drop both tables and run syncdb, only the two model
tables are created. There's no join table. syncdb doesn't report any
errors.
"validate" shows 0 errors. Any ideas what the problem could be, or how
to debug i
but
I don't have control of that on the generated model.
On Wed, Jan 4, 2012 at 10:57 AM, Brian Craft wrote:
> I have two models. The second one has a ManyToMany to the first. Both
> are managed. If I drop both tables and run syncdb, only the two model
> tables are created. Th
Looks like a m2m class can be identified by the ._meta.auto_created
attribute, which also holds the class with the m2m field. So the
router can check for attributes on that class.
On Wed, Jan 4, 2012 at 11:49 AM, Brian Craft wrote:
> I strongly suspect the problem I'm having has to
;
PROJNAME = PROJDIR.split('/')[-2]
BASEDIR = os.path.abspath(os.path.join(PROJDIR, '..', '..')) + '/'
APPSDIR = os.path.abspath(os.path.join(BASEDIR, 'apps')) + '/'
# add apps and projects directory to path
sys.path.insert(0, PROJDIR)
sys.pat
. In reality, all of the tables are
in the same database.
I also use:
class Meta:
app_label = 'major_app'
in the model class of each sub_app, so that all of the admin pages are grouped
together.
Brian
Brian Schott
bfsch...@gmail.com
On Jan 10, 2012, at 1:46 AM,
ut SSL and virtual
hosting on Apache.
Brian Schott
bfsch...@gmail.com
On Jan 10, 2012, at 6:01 AM, Cal Leeming [Simplicity Media Ltd] wrote:
> I've hit this same problem myself many times.
>
> Ultimately there is never any one answer - you can split out functionality
> into indivi
behind the scenes.
I've thought about different options, but they all have tradeoffs:
1. dav enabled nginx process for each user with a javascript dav file explorer?
2. django-storages with sftp?
3. something else?
Brian
Brian Schott
bfsch...@gmail.com
smime.p7s
Description: S/MIME cryptographic signature
les...
On Jan 19, 2012, at 12:56 AM, Mike Dewhirst wrote:
> On 19/01/2012 2:10pm, Brian Schott wrote:
>> Looking for some expert advice. I need to provide an upload and file
>> browse capability for a user's home directory. It doesn't have to be
>> a full blow
ve died down in the last couple of years from a
peak in 2008/2009.
I did search the group and haven't seen any recent discussions on this
comparison.
Any comment really very much appreciated.
Kind regards,
Brian
--
You received this message because you are subscribed to the Google Groups
://www.dajaxproject.com
Brian Schott
bfsch...@gmail.com
On Jan 10, 2013, at 9:12 AM, Tom Evans wrote:
> On Thu, Jan 10, 2013 at 1:21 PM, Mauro Sánchez wrote:
>> Hello, I have a process that takes about 2 or 3 minutes to execute. The
>> problem is that sometimes (not always) i
I'm trying to create a development environment that supports testing my
subdomain configuration. I'll be using the django-subdomains package,
which relies on the sites framework. *To make a local environment that
supports this while using the Django built-in webserver, do I need to set
up loc
We are using ansible.
http://ansible.cc/
Other popular choices are puppet and chef. The real benefit. Is that these
tools let you version control your configurations.
Sent from my iPhone
On Feb 1, 2013, at 7:46 PM, Carlos Aguilar wrote:
Bash scripts really???
If you are a Python developer yo
over the place.
Brian Schott
bfsch...@gmail.com
On Mar 29, 2013, at 3:36 PM, David Pitchford
wrote:
> I am experienced with Python but new to Django and web development in
> general. I am struggling to understand its static files system from the
> documentation. It seems like
strategy is to do
content updates on the production site and test/develop against database
snapshots locally.
Also, when you change the models, it is worth learning how to use South to do
schema migration.
http://south.readthedocs.org/en/latest/tutorial/part1.html
Brian Schott
bfsch...@gmail.com
es.
2. Encode the thing as a JSON list and store in a JSONField
https://github.com/derek-schaefer/django-json-field
3. There are several flavors of ListField out there:
http://djangosnippets.org/snippets/1491/
Brian Schott
bfsch...@gmail.com
On Apr 10, 2013, at 1:38 PM, Cody Scott wrote:
>
Question to duplicate the
question and its choices.
https://docs.djangoproject.com/en/dev/ref/contrib/admin/actions/
That way, your workflow is duplicate a question, edit on a single page, hit
save.
Brian Schott
bfsch...@gmail.com
On Apr 10, 2013, at 3:02 PM, Cody Scott wrote:
> I like
constraint on choice + module. There are tradeoffs in all of
these approaches.
Brian
Brian Schott
bfsch...@gmail.com
On Apr 10, 2013, at 4:30 PM, Cody Scott wrote:
> I also want to have the same question in multiple quizzes. But the count for
> each option should be dependent on the Q
Hello -
I have a Django site that I've been maintaining for 4 years. It is running
Django 1.4 now and is using the usual Django User model plus the
get_profile() method to retrieve some extra information for each user. Now
that Django 1.5 has landed and we can substitute our own custom user mod
that at this point the
parent object and its form have already been saved.
Thanks for your time!
Brian Dant
PS: I crossed posted this from SO, where I wasn't getting much traction.
I realized that this is probably more of a Django Admin detail, so y'all
might know better :D
--
direction of information that could help me understand creating a
database like this, I would greatly appreciate it.
Brian
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To unsubscribe from this group and stop receiving emails from
Thanks Shawn,
I am plugging my way through the docs and djangobook. I figured that I
probably just hadn't come to it yet.
Sometimes ADD gets the best of me and I just can't help but ask a question
when something is on my brain.
I appreciate the help, off to read the links you se
Hi all,
I'm just trying to learn Django. I have an existing site that I wrote in
PHP, and I'l considering converting it to Django,
I have a legacy database that I don't want to make any changes to. I have
the basics working in Django, but am having a problem with a
ManyToManyField.
Here are th
t; 1, and instead of
showing the album name, it just shows On (x) albums.
I can't make any changes to the layout of the Song table, but making minor
changes to the Played table is a possibility. (I'd rather not, but if there
is better way to do it, I'm not opposed)
Thanks!
Brian
On
;).aggregate(lc=Count('upper(left(name,1))'))
but that doesn't work: FieldError: Cannot resolve keyword
'upper(left(name,1))' into field. Choices are: id, name, prefix
Any ideas?
Thanks!
Brian
--
You received this message because you are subscribed to the Google Groups
With this simple database table:
class Artist(models.Model):
id = models.IntegerField(primary_key=True)
name = models.CharField(max_length=255L, blank=True)
prefix = models.CharField(max_length=32L, blank=True)
class Meta:
db_table = 'artist'
I want to be able to get a lis
Kevin,
Sounds like a great idea. Wish you the best of luck.
I would be willing to give you a hand if you want the perspective of a
complete novice. I am just learning Django and am not far beyond the docs
tutorial.
Brian
--
You received this message because you are subscribed to the
y the page needed. However, when I do ./manage.py dbshell, all of my
tables are there!
Does anybody know why this sort of error might be happening?
Thanks,
Brian
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To unsubscribe from
cloned the database file
along with the rest of the project from github at the start. (this process
has worked for me before on other machines.)
Thanks,
Brian
On Saturday, June 8, 2013 11:12:21 AM UTC-4, Sergiy Khohlov wrote:
>
> looks like you are using other settings.py for .wsgi
So I have a model that looks somewhat like this:
class ProductInfo(models.Model):
manufacturer = models.ForeignKey
product_type = models.ForeignKey
product_name = models.ForeignKey
sku = models.CharField(()
--
You received this message because you are subscribed to the Google
know of a good way to do it?
Thanks
Brian
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to django-users+unsubscr...@googlegroups.com.
To post to this g
Seems like it was a path issue. I put in the full path to the sqlite3
database file in my database settings, and it works now. For future
reference - how is ./manage.py's path set up, and how apache's wsgi path is
set up?
Thanks,
Brian
On Saturday, June 8, 2013 3:10:26 PM UTC-4, J
rebranded copies, so we have multiple project directories
in our code tree, but each server is just one project. Don't forget, there are
global things like user authentication you don't want to have a user have to
login separately to go to blog.example.com from www.example.com.
Bria
NAME (path to a database file) should include the filename, not just a
directory. Try './mysite/mysite.db' for NAME.
Brian
On Jul 22, 2013, at 1:44 PM, Stian Sjøli wrote:
> I am trying to start up with django using the tutorial on the website. I get
> the following error &
I have these 2 models:
class Requestlist(model.Model):
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to django-users+unsubscr...@googlegroups.com.
To post to
I have the following models:
class Requestlist(models.Model):
>id = models.IntegerField(primary_key=True)
>songid = models.Integerfield()
>song = ForeignKey('Song', db_column='songid')
> class Song(models.Model):
> id = models.IntegerField(primary_key=True)
> title = models.CharFie
I've done that with this code:
if form.is_valid():
> f = form.save(commit = False)
> f.save(using='yourdatabase')
Works fine for me.
On Tuesday, July 23, 2013 1:21:29 PM UTC-4, Fellipe Henrique wrote:
>
> I have many database setted in my setting.py in my formModel, when I try
> to vali
I keep getting 504 gateway timeout errors on http://code.djangoproject.com/
so I can't look through the tickets for this.
There are some threads on this list that seem like they might be related;
but I can't tell because they link to code.djangoproject.com which I can't
get to.
I tried to foll
code.djangoproject.com is back up now; seems like I bumping up against this
three year old bug that has not been updated in 19 months:
https://code.djangoproject.com/ticket/13394
Any advice on how to handle this? Do I need to re-write all the tests?
Does this mean RemoteUserMiddleware is not
I'm looking for.
It's a shame that the documentation with it doesn't show how to properly
install it, and has no working examples with it.
Brian
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To unsubscribe from this group
calling AJAX from inside the browser, I recommend you
check out:
http://www.dajaxproject.com
There are other tools, but it makes life easier.
Brian Schott
bfsch...@gmail.com
On Aug 15, 2013, at 12:27 PM, evh wrote:
> Hi,
>
> I am having trouble getting REST to work within Dja
;
>
> On Thu, Aug 15, 2013 at 2:41 AM, Brian Millham
> > wrote:
>
>> I've been trying to use django-popup-forms, but with no success. Has
>> anyone used this?
>>
>> I suspect that I didn't install it correctly. I just ran sudo python
>> setup.py
Also, load the page with a busy animated gif and use something like dajaxice to
fetch and replace the computed value. Several examples and libraries out ther.
—
Sent from Mailbox for iPad
On Fri, Aug 16, 2013 at 11:22 PM, Some Developer
wrote:
> On 17/08/13 03:43, Christophe Pettus wrote:
So, my website, involving lots of database calls, works perfectly fine,
even after a reboot.
However, attempting to connect directly via dbshell results in this error:
$ ./manage.py dbshell
mysql: unknown variable 'character-set-server=utf8'
Attempting to figure out my version of mysql also gav
# only contains [mysqld_safe]; syslog
On Saturday, August 24, 2013 7:06:28 PM UTC-4, tom wrote:
>
> On Saturday, 24 August 2013, Brian Lee wrote:
>
>> So, my website, involving lots of database calls, works perfectly fine,
>> even after a reboot.
>>
>> However, attem
nk to the popup is clicked. (they are hidden until the link
is clicked)
And I'm avoiding the use of the javascript virus :-D
Thanks for any pointers!
Brian
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To unsubscribe from
I am trying to deploy my Django site. On my development environment using
runserver, everything works perfectly. After deploying to production with
Apache and Passenger WSGI on a shared hosting environment, the majority of
the site works correctly. However, I am having one issue that I am unable
I'm getting duplicate entry integrity errors when saving an object, with
transaction middleware enabled in django 1.3.
I thought the point of the middleware was to rollback transaction errors
and retry the view. Why would I be getting this error?
The db is mysql. The save code looks like this:
t
Polls not pools?
—
Sent from Mailbox for iPhone
On Sat, Oct 12, 2013 at 12:58 PM, Enrico Battiston
wrote:
> Hi, i'm a first time user and i'm experiencing an error in the first part
> of the django 1.5 tutorial.
> At the "Activating models" paragraph when i execute the command line "*python
>
within the
wsgi. But with 1.6 it does get referenced and therefore raises an
ImproperlyConfigured error. Does anyone have any suggestions to help fix
this issue? Is there anyway I can get the settings module to load before
the wsgi module?
Brian DeWeese
-- apache.conf --
WSGIScriptAlias
What are you trying to do? Typical approach would be to use Javascript to pull
the images. Take a look at dajaxice.
—
Sent from Mailbox for iPhone
On Mon, Nov 18, 2013 at 1:57 PM, Alex Karargyris
wrote:
> So thanks to Simon I was able to make this work. Here is the code for those
> who m
Could you include the output to highlight the differences?
Brian
On Wed, Apr 13, 2011 at 9:32 AM, Gianluca Sforna wrote:
> In writing a complex filter for an application, I've found a different
> behavior between a filter like:
> Model.objects.exclude(filter1, filter2)
&g
On Apr 15, 2:23 pm, Jeff Blaine wrote:
> Thank you all. I will digest the replies when I have the time to properly
> focus back on the issue (it's obviously small, since I have a workaround in
> place by shoving base.html into the project root).
>
> It still, regardless of solutions, even in ligh
I need to create objects with version tracking, a bit like wiki
content. Anyone done this in django?
I could create a model with a content field and a version field. But
I'm not sure how to query (for example) all the latest versions of a
set of objects. I'm sure there's a raw sql method via joins
On Apr 21, 12:48 pm, Guevara wrote:
> Hello!
> My project is failing to import the staticfiles_urlpatterns, using
> Eclipse Helios:
>
> urls.py
>
> import from django.contrib.staticfiles.urls staticfiles_urlpatterns
>
> In django 1.3 I already have:
>
> INSTALLED_APPS = (
> 'django.contrib.staticf
net/htmldoc/options.html#'list'>
.
Brian
On Thu, Apr 28, 2011 at 4:50 AM, Tom Evans wrote:
> On Thu, Apr 28, 2011 at 8:47 AM, Kenneth Gonsalves
> wrote:
> > On Thu, 2011-04-28 at 00:27 -0700, Derek wrote:
> >> A good IDE will convert tabs to spaces for you..
A form with a CharField seems to end up with a zero-length string in
the cleaned_data if the field is not in the form data. Is there any
good way to avoid this?
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to
This would have been so useful on my last project. 14.4 Million records
took a couple of days with a single thread using the ORM. This would have
really sped things up.
Brian
On Tue, May 3, 2011 at 7:50 AM, Thomas Weholt wrote:
> Inserting, updating or deleting lots of records using
I will definitely be using this next time. Nice post.
Brian
On Tue, May 3, 2011 at 5:50 PM, Thomas Weholt wrote:
> Hi,
>
> Just posted a new blog about more realistic performance of DSE against
> a real database. Head over to http://weholt.blogspot.com/ to read it.
>
> Thanks
complicated and closed.
Best,
Brian
On Wed, May 4, 2011 at 6:32 AM, VoodooH wrote:
> Hello guys,
>
> We currently have a desktop software that uses a sqlite embedded
> database. We are now gonna develop the online version for our software
> and we need your opinion on these matter
g to write something to allow all data to
be moved back and forth. It sounds like you have a data sync service. Any
thoughts on open sourcing that code? Anyone else know of a project that
already does this?
Thanks,
Brian
On Wed, May 4, 2011 at 9:02 AM, David Goehrig wrote:
> I'd r
structure dynamically in the view code without explicitly pre-defining it as
a class or model.
Hope this helps.
Brian
On Wed, May 4, 2011 at 12:42 PM, pankaj sharma
wrote:
> hello friends,
> i have database of colleges.
> i want to show all cities
>
> so what is did is.
I like your second solution a lot better than mine. I've never seen {%
ifchanged %} used properly before.
Brian
On Wed, May 4, 2011 at 1:19 PM, Javier Guerra Giraldez
wrote:
> On Wed, May 4, 2011 at 11:42 AM, pankaj sharma
> wrote:
> > in template..
> >
> >
AMQP is not too heavy weight for me. +1 for Celery and RabbitMQ.
Brian
2011/5/6 λq
> Thanks guys.
>
> Is AMQP a bit too heavy weight?
>
> Besides celery, are there any realworld in-production usage of
> Django+ZeroMQ?
>
> Is django-ztask stable?
>
> On Fri,
r-side state
machine that ensures what a user can and can't do with the application from
a given state.
This is not exactly what is being discussed here, but it is near it in
topic, so I thought I would mention it.
Brian
On Mon, May 9, 2011 at 8:59 AM, Cal Leeming [Simplicity Media Ltd]
I would like unit tests that do file manipulations to run with a
different storage "location", so they're not manipulating real app
files. Is there a good way to do this? Is there a way to override
model field initializers, so I can instance a model, passing in the
'storage' parameter for an ImageF
I have a model with an imagefield, and some fields that are computed
from the image. I'm trying to override the "save" method to fill in
the other fields.
When I test this in the admin, there are two problems: first, the path
(mymodel.image.path) doesn't honor the upload_to setting on the field.
I
solved this by moving it to the model clean() method, and using
imagefield.file.open() and imagefield.file.read() to get the data for
computing the other fields.
On Wed, May 11, 2011 at 1:28 PM, Brian Craft wrote:
> I have a model with an imagefield, and some fields that are computed
> fr
in
an awesome way, and since I never distribute it I never have to share my
derivative changes thereby preventing the GPL project from benefitting from
my extensions. That is a pretty easy way to sidestep any of these licenses.
Brian
On Fri, May 13, 2011 at 7:58 AM, Alistair Grant wrote:
> It w
com/dcramer/django-sentry>.
You're idea sounds great and needed, I just want to encourage you to make
sure you're adding to the community, not re-inventing existing solutions.
Best,
Brian
On Thu, May 12, 2011 at 11:44 PM, Adrien LEMAIRE <
adrien.lema...@aquasys.co.jp> wrote:
>
ave an app that does very similar
functionality to the functionality discussed.
Hope that clears up any confusion.
Brian
On Fri, May 13, 2011 at 10:20 AM, Xavier Ordoquy wrote:
> > On May 13, 9:34 pm, Brian Bouterse wrote:
> >> Go for it!
> >>
> >> I know the dis
Is there a good way to add new users to a default group when they are
created (e.g. via django-registration)? I just tried binding the
post_save signal for User, and adding the group in the signal handler
(if "created" is true). However, I haven't found a good place (file)
to put the connect() call
project __init__.py, but that works inconsistently, apparently
because django isn't fully initialized when the project __init__.py is
loaded.
On Tue, May 17, 2011 at 11:07 AM, Brian Craft wrote:
> Is there a good way to add new users to a default group when they are
> created (e.g. vi
I have a generic view that accepts its template_name attribute from
the urlconf dynamic variable:
(r'^(?P[^/]+)$', TemplateView.as_view()),
But I get an exception:
TemplateResponseMixin requires either a definition of 'template_name'
or an implementation of 'get_template_names()'
I've read the c
701 - 800 of 944 matches
Mail list logo