Re: Django

2022-04-22 Thread Derek
from app2.models import ThatModel (assuming both apps are part of the same project) On Thursday, 21 April 2022 at 21:47:18 UTC+2 farid...@gmail.com wrote: > Please how do I import a model from another app. Thanks, please someone > should help me out > -- You received this message because you

Re: simple command line ./manage.py shell puzzle

2022-04-24 Thread Derek
It fails because the second datetime in your test script is taken to be a variable and it is not one you have already defined; hence the error: "NameError: name 'datetime' is not defined". Try this instead: echo "import datetime ; [e*e for e in [1,2]]" > test On Thursday, 21 April 2022 at 19:0

Re: simple command line ./manage.py shell puzzle

2022-04-24 Thread Derek
Actually, there does seem to be some further issue: echo "import datetime; [datetime.date(2022,4,e) for e in [1,2]]" > test.py Also triggers an error when used in the Django shell, but works when run as a normal Python script: python test.py On Monday, 25 April 2022 at 07:44:0

Re: Help! I begginer...

2022-04-29 Thread Derek
You may need to update the version of Django you're running; the current source code (https://github.com/django/django/blob/main/django/db/models/sql/query.py) shows this import: from collections.abc import Iterator, Mapping Hope that helps. On Tuesday, 26 April 2022 at 18:34:34 UTC+2 rikrdop

Re: create_question not define error. NameError.

2022-05-03 Thread Derek
What steps did you follow to get here? What does your code look like that creates this error? (Its probably better to post actual code snippets as text rather than screenshots.) On Monday, 2 May 2022 at 15:02:44 UTC+2 mdanz...@gmail.com wrote: > Anyone is here for help? > > On Friday, 29 Apri

Re: Json Object type field in Model in Django

2022-06-10 Thread Derek
Creating: https://docs.djangoproject.com/en/4.0/ref/models/fields/#jsonfield Querying: https://docs.djangoproject.com/en/4.0/topics/db/queries/#querying-jsonfield On Thursday, 9 June 2022 at 15:00:31 UTC+2 vmuk...@gmail.com wrote: > Hii Community, > > can we add a field in model that stores j

Re: How to generate a table in pdf?

2022-06-26 Thread Derek
https://xhtml2pdf.readthedocs.io/en/latest/usage.html is what you need. On Friday, 24 June 2022 at 16:08:10 UTC+2 kvnk...@gmail.com wrote: > > > > > *Hi family, I created a salary calculation application.As I already > display the list of employees, I now have to download it using a function >

Re: Negative Stock Prevention

2022-08-30 Thread Derek
As a start, the logic checks for the model should not be in views.py but rather with the model object (in models.py). You can extend the save() method, for example, and add the checks there. See: * https://docs.djangoproject.com/en/4.1/ref/models/instances/#saving-objects * https://docs.djang

Re: Fwd: Delivery Status Notification (Failure)

2022-09-18 Thread Derek
I agree with previous posts. It might also be worthwhile to simplify your code to avoid unneeded variables: details=Details( name=requests.POST.get('name'), roof_age=requests.POST.get('roof_age'), email=requests.POST.get('email'), phone=r

Re: How to solve primary key error in django?

2023-01-09 Thread Derek
Also understand that using '0' for a primary key is NOT recommended by MySQL; look at: https://dev.mysql.com/doc/refman/5.7/en/sql-mode.html#sqlmode_no_auto_value_on_zero This has bitten me before when migrating data from other types of DBMS. On Thursday, 5 January 2023 at 12:09:35 UTC+2 prash

Re: Django Location- Does anyone know about this?

2012-02-16 Thread Derek
http://geodjango.org/ ? On Feb 15, 6:18 pm, coded kid wrote: > Hi Guys, Does anyone knows about any good django package for maps? or > for locating of areas, states, streets? Please kindly answer if you > do. Thanks. > > BTW: I've tried using Django easy_maps but it's not working. If you've > use

Re: handling multiple parallel request

2012-02-20 Thread Derek
On Feb 20, 11:32 pm, "rafiee.nima" wrote: > tnx alot > but actually my scenario dose not deal with user so I thing cookies do > not help a lot > suppose there are 3 airline counter which fill ticket forms and send > them to the cashier maybe  simultaneously  .forms are sent to the > cashier which

Re: Reports

2012-03-05 Thread Derek
community can benefit. Cheers Derek On Mar 5, 1:12 pm, Ahmed Toulan wrote: > Hi, > > We have a Django website and we would like to have a reporting engine, if > it could be in python and integrated with Django it would be awesome. > > Here are the options I investigated: >

Re: Reports

2012-03-06 Thread Derek
I am curious as to why/how you use a reporting tool that does not support HTML for a web application? (PS I note that this tool, as in the case of Geraldo, also uses ReportLab) On Mar 5, 5:29 pm, Alexey Luchko wrote: > Hi! > > We are usinghttp://PythonReports.sf.net/. > > -- > Regards, > Alex.

Re: overlay feature in django

2012-03-08 Thread Derek
I think you will need to define, or give an example, of what exactly you mean by "overlaying". On Mar 8, 12:55 pm, Bhujang Bhagas wrote: > Hi, > > Is there any feature for overlaying templates in django . > > Thanks.. -- You received this message because you are subscribed to the Google Groups

Re: overlay feature in django

2012-03-12 Thread Derek
emplate. > > Thanks.. > --- > ---- > > On Mar 9, 11:21 am, Derek wrote: > > > > > > > > > I think you will need to define, or give an example, of what exactly > > you mean by "overlaying". > > > On Mar 8,

Re: overlay feature in django

2012-03-12 Thread Derek
So much for the Zen of Python! :D On Mar 12, 9:21 am, kenneth gonsalves wrote: > On Mon, 2012-03-12 at 00:14 -0700, Derek wrote: > > That is not an example or definition of "overlaying"; just a laundry > > list of templates. > > I would take a wild

Re: Best approach for multiple sites in a single deployment?

2012-04-11 Thread Derek
That domain and page do not exist... On Apr 10, 4:42 pm, Mario Gudelj wrote: > Hey man, > > See if this > helpshttp://tidbids.posterous.com/saas-with-django-and-postgresql-schemas > > Cheers, > > -m > > On 10 April 2012 21:53, Bernardo wrote: > > > > > > > > > I would like to create a subdomain

Variations on a table for different clients?

2012-04-11 Thread Derek
approaches or practices will help streamline work and prevent such variations from becoming a headache to maintain? (And yes, its likely to be more than one table that will require these variations). Thanks Derek -- You received this message because you are subscribed to the Google Groups

How to do form validation for inline formsets?

2012-04-18 Thread Derek
my syntax is wrong somewhere, but how do I go about fixing this? Thanks Derek Approach No.1 - NO validation # view file UploadFieldFormSet = inlineformset_factory(Upload, UploadField, max_num=None,

Re: Django - Worldwide Developer Rates - Hourly Income - location and project duration specific

2012-05-07 Thread Derek
I may have missed some key apect of this discussion, but isn't djangosite a tool fo show-casing websites; not a financial-statistics-gathering website? Is it not better to have one dedicated to this purpose; or perhaps extend http://www.djangojobs.org/ as this as least deals with employment-relate

Re: django on jb ipad

2012-05-21 Thread Derek
I'm not an iPad user, but I see you can install Python from iTunes: http://itunes.apple.com/us/app/python-for-ios/id485729872?mt=8 (BTW, SQLite library and the pysqlite language binding are built into Python) I'm assuming you can then install and run normal Python modules (of which Django is one)..

Re: Django graphical query interface?

2012-05-21 Thread Derek
I also have searched for such a beast in the past... The only one I have found recently that might be close is: http://plugins.jquery.com/project/SQL_QUERY_BUILDER (This site is down now - look at the archived view: http://web.archive.org/web/20100212131706/http://plugins.jquery.com/project/SQL_QU

Re: DB joining 3 tables in django admin, while searching on the primary table

2012-05-22 Thread Derek
Please read this: https://code.djangoproject.com/wiki/UsingTheMailingList#Donts: before continuing to post these types of messages. On May 21, 3:30 pm, Aditya Sriram M wrote: > Some one there can answer!? > > > > > > On Sunday, 20 May 2012 13:12:17 UTC+5:30, Aditya Sriram M wrote: > > > Ooo.. Nic

Re: How to use an optional ForeignKey to sites.Site and admin's "View on site"?

2012-05-30 Thread Derek
Actually, you can have a nullable ForeignKey (and there can be good reasons for this). This is mentioned in the docs themselves; see: https://docs.djangoproject.com/en/dev/ref/models/fields/#django.db.models.ForeignKey.on_delete I am not sure about the error that the OP is encountering. On May

Re: App inside another app or nesting in django apps

2012-05-31 Thread Derek
And the Zen of Python? "Flat is better than nested" On Jun 1, 8:10 am, Jani Tiainen wrote: > 31.5.2012 19:22, Kurtis Mullins kirjoitti: > > > Sure. They're just Python modules. All you need to do is: > > > 1. Include the files: __init__.py and models.py > > 2. Add the application to your setting

Re: Understanding Django for PHP developer

2012-06-03 Thread Derek
Its more of an overview, but picks up on some key points: http://j4mie.github.com/python-and-django-for-php-refugees/#slide1 On Jun 3, 12:18 pm, mikegolf wrote: > Hi, > I've started to learn Django recently, however for last 5+ years I've > been developing using PHP (especially Yii) and thus aski

Re: Getting the last modified datetime from a DateTimeField

2012-06-06 Thread Derek
Please read: http://stackoverflow.com/questions/1737017/django-auto-now-and-auto-now-add On Jun 7, 8:14 am, Jesus Noland wrote: > Thank you for your reply. > > Ok so if I type out: > > m = Model.objects.get(id=1) > > then > > m.date > > Will give me the date and time of the last time it was save

Re: Import error

2012-06-25 Thread Derek
Emily If you are starting a new topic, please start a new thread - and again, as per the guidelines for using the mailing list that Cal referred to, the more specific your question, the more chance of getting a reply. :) On Friday, 22 June 2012 17:14:34 UTC+2, Emily N wrote: > > Kurtis, Adrian

Re: Handling millions of rows + large bulk processing (now 700+ mil rows)

2012-07-01 Thread Derek
Cal Can you please confirm which timezone these times are for (I assume UTC, but was not sure...) Thanks Derek On Sunday, 1 July 2012 17:09:05 UTC+2, Cal Leeming [Simplicity Media Ltd] wrote: > > Wow - glad to see there's people interested in this! > > Here is the schedul

Cause of a "Lock wait timeout error"?

2012-07-10 Thread Derek
or see what process or issue is actually causing the error? Thanks Derek -- 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 this group, send e

Re: Cause of a "Lock wait timeout error"?

2012-07-10 Thread Derek
Lee Bieber wrote: > On Tue, 10 Jul 2012 10:57:21 +0200, Derek > declaimed the following in gmane.comp.python.django.user: > > > > > DatabaseError at /admin/app/model/1/delete/ > > (1205, 'Lock wait timeout exceeded; try restarting transaction') > > > >

Re: mysql warnings raise exception

2012-07-12 Thread Derek
George When issues with existing bugs get raised on this list. someone from "higher up" usually suggests you need to post on the developers list (apologies if you have already done; I do not subscribe to that list). Derek On Tuesday, 10 July 2012 19:10:54 UTC+2, George Lund wr

form.save() fails silently - how to debug?

2012-07-26 Thread Derek
ng this type of situation? Thanks Derek # models class ClientFile(Model): id = AutoField(primary_key=True) description = CharField(unique=True, max_length=255) file = FileField(upload_to='client', storage=CLIENT_STORAGE) class ClientData(Model): id = AutoField(primary

Re: form.save() fails silently - how to debug?

2012-07-26 Thread Derek
think > >> results = formset.save(commit=False) >> formset.save() > > should be > >> results = formset.save(commit=False) >> results.save() > > > Tervitades/Regards > Karl Sutt > > > On Thu, Jul 26, 2012 at 10:35 AM, Derek wrote: > >&g

Re: form.save() fails silently - how to debug?

2012-07-27 Thread Derek
The clean() method basically stores the non-model field data in the model's dictionary field. If this method was faulty, then it would also cause problems in the test code. As I said, when I print the data to console it looks OK. I am still trying to find how and where the save() method indi

Re: form.save() fails silently - how to debug?

2012-07-27 Thread Derek
see. I have not used pdb before; I will need to look into how that works and how might help me. On Friday, 27 July 2012 14:00:37 UTC+2, Karen Tracey wrote: > > On Fri, Jul 27, 2012 at 3:25 AM, Derek wrote: > >> The clean() method basically stores the non-model field data in t

Re: Models: Referencing A Model In Another App and Different Project

2012-07-29 Thread Derek
As a general remark related to the issues that JJ has described... are there perhaps - or rather, should there be - pointers from the Django site that discuss some good practices to the overall approach of designing and building sites/projects/apps/databases - as opposed to the technical nitty-

Re: form.save() fails silently - how to debug?

2012-07-29 Thread Derek
ut it is simply not saved. On Friday, 27 July 2012 15:46:01 UTC+2, Derek wrote: > > Thanks Karen > > I am not quite sure what you mean by "Model save() would indicate an > error" - I am making a call to the form.save(), which in turn, I assume, > should result in

Re: Read from an uploaded file and put data in a form for automatic Django validation

2012-07-29 Thread Derek
Have a look at: http://stackoverflow.com/questions/6091965/django-upload-a-file-and-read-its-content-to-populate-a-model On Sunday, 29 July 2012 04:43:15 UTC+2, forthfan wrote: > > Hi all, > > Being lazy, I want Django to validate the stuff I read from an uploaded > file as if it were being post

Re: form.save() fails silently - how to debug?

2012-07-29 Thread Derek
causing a "silent fail", but at least I can make progress now. Thanks to all who made suggestions. On Sunday, 29 July 2012 14:59:27 UTC+2, Derek wrote: > > Just to follow up... > > I have tried using pdb - but stepping into the Django code goes through > hundreds of line

Changing the text on the admin "change_list.html"

2012-09-08 Thread Derek
I need to alter the text that appears above every change list in my app: "Select *modelname* to change" However, I cannot see this text in the change_list.html file - whereabouts is this text kept, and can it be overridden? Thanks Derek -- You received this message because you are

Re: Request for comments - django-cutemodel (model logging and field change auditing)

2012-09-13 Thread Derek
think it will be a great alternative option for many folk. Cheers, Derek On Tuesday, 11 September 2012 21:11:06 UTC+2, Cal Leeming [Simplicity Media Ltd] wrote: > > Thanks for letting me know about django-reversion, it has made for > interesting reading. > > From what I can se

Re: Changing the text on the admin "change_list.html"

2012-09-13 Thread Derek
I see I was not specific enough. I do not want to change the model name; just the wrapper text that is used for *all* models. Thanks Derek On Tuesday, 11 September 2012 19:41:07 UTC+2, Melvyn Sopacua wrote: > > That would be the verbose name in the models' meta class. I think >

Re: Customizing the Django Admin Interface

2012-09-17 Thread Derek
ritten. Thanks Derek On Sunday, 16 September 2012 08:25:18 UTC+2, JJ Zolper wrote: > > Hello, > > I was able to locate the Django files for the admin under contrib in the > source. I was curious if I could get some tips about customizing the > interface. > > One website I

Re: Customizing the Django Admin Interface

2012-09-17 Thread Derek
in the source code you had made them...) On Monday, 17 September 2012 23:00:21 UTC+2, JJ Zolper wrote: > > Derek, > > You can see the custom changes I made here: > > http://www.madtrak.com/admin > > That is the extent of what I have done in relation to the default. N

Re: Getting instance of current in django site admin

2012-09-25 Thread Derek
You have not supplied enough information to make this an answerable question. What is not happening that you expect should be happening? On Saturday, 22 September 2012 06:32:12 UTC+2, Krish wrote: > > I have following code in my admin.py > > class PackageForm(forms.ModelForm): > activity = form

Re: Django 1.4 and google app engine

2012-09-25 Thread Derek
Then you should not be using GAE. From http://en.wikipedia.org/wiki/Google_App_Engine#Differences_between_SQL_and_GQL "Unlike a relational database the Datastore API is not relational in the SQL sense." On Saturday, 22 September 2012 23:00:50 UTC+2, neixetis wrote: > > Thank you ver much for a

Re: What is Django?

2011-08-24 Thread Derek
http://www.djangobook.com/en/2.0/chapter01/ discusses what a web framework is, and why/how it might offer you more productivity just using "raw" Python (bearing in mind that most of the time, apart from the HTML templates, you *will* be using Python anyway). You cannot "see" a sample app because a

Re: DjangoCon US 2011 Videos

2011-09-21 Thread Derek
+2 On Sep 21, 3:10 pm, "Cal Leeming [Simplicity Media Ltd]" wrote: > +1 > > On Wed, Sep 21, 2011 at 2:09 PM, Slafs wrote: > > I would be interested also in watching those videos > > > Regards > > >  -- > > You received this message because you are subscribed to the Google Groups > > "Django user

Re: Helping someone move from Joomla to Django

2011-09-28 Thread Derek
ast a blog post or two to impress your fellows. Working with him allows you to easily answer all the small issues that always pop-up when trying to learn an unfamiliar tool/system, and helps ensure that these are not road-blocks on the path to "enlightenment". My 2c! Derek -- You r

Re: Module or plugin architecture

2011-10-01 Thread Derek
see: http://docs.merengueproject.org/intro/overview.html#a-pluggable-architecture Derek -- 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 this group, sen

Re: sprintf in python (not strictly django, but used all the time in django webapps)

2011-10-25 Thread Derek
Those can be a bit dry... for some variety, you could also try Doug Hellman's excellent "Module of the Week": http://www.doughellmann.com/PyMOTW/ On Oct 24, 4:11 pm, "Cal Leeming [Simplicity Media Ltd]" wrote: > You're correct :L > > Thanks for this - I think I might replace my daily break with r

Re: project architecture question

2011-11-14 Thread Derek
On Nov 14, 2:44 pm, "Sells, Fred" wrote: > I build healthcare applications and the gov't regs require we log most > user access to patient info. > > Since I've only built one (rather large) Django app, my logging is in > the same DB as my data and I use decorators in views.py to log all > access.

Re: To make a basecamp like - project management site

2011-11-15 Thread Derek
This looks like spam. On Nov 15, 11:16 am, Anand wrote: > Hi Michael > > You can try BootStrapToday (http://bootstraptoday.com). Its based on python > and django. > > Regards > Anand -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to t

Re: Date_Field min_value

2011-11-17 Thread Derek
Michael Please don't an existing thread and change the topic; start a new discussion of your own. For more on mailing list etiquette, please read: https://code.djangoproject.com/wiki/UsingTheMailingList On Nov 17, 6:17 am, Michael Nacharov wrote: > Hello Django Expets! > In one of my Django app,

Re: django tutorial versions

2011-11-22 Thread Derek
This seems to keep happening. It would be incredibly helpful if the Django webpages could add the version number (or dev reference) in dark, bold lettering in the light green toolbar (right near the top of the page, next to the words "Django documentation)! On Nov 21, 9:18 pm, Jesse Aldridge wr

Re: slow function

2011-12-06 Thread Derek
On Dec 5, 12:18 pm, Håkon Erichsen wrote: > 2011/12/5 kenneth gonsalves > > > That seems to be the biggest problem you have. Some other comments: > > - Holy mother of god, that's a huge view file! I would advice to slice > it into logically separated files, and put this in a directory called > "v

Re: Conditional choice fields for model specification...

2011-12-06 Thread Derek
ition would contain all the possible choices and you'd filter these to the user accordingly. There have been many many posts to this list (as well as many blog entries) all detailing possible routes you can take. HTH Derek -- You received this message because you are subscribed to the Goog

Re: slow function

2011-12-07 Thread Derek
On Dec 6, 12:34 pm, kenneth gonsalves wrote: > On Tue, 2011-12-06 at 02:15 -0800, Derek wrote: > > Another side comment would be a suggestion to avoid "old skl vrbl nms" > > - in other words, use "player" for "ply", "month" for "mnth&q

Re: Is DJango bad for conveying business-logic?

2011-12-14 Thread Derek
I'd echo this. In my experience, the code to implement business logic is far, far less complex than that required to implement databases, web servers, email systems etc. etc. The skill required here is a mix of understanding of user/business requirements and coding ability. The best tool in the w

Re: Decorator aware Django

2011-12-14 Thread Derek
On 14 December 2011 23:57, Matej Cepl wrote: > On 13.12.2011 15:14, Javier Guerra Giraldez wrote: >> >> for me, is opposed to the "explicit is better than implicit" in the >> Zen of Python.  not a bad thing on itself, but something to be careful >> about.   (and, personally, it's a big part of why

Re: Directory layout for a large Django application (not project)

2012-01-09 Thread Derek
closely-related data sets. In this case there is a typically a "core" data set and then many other more peripheral ones that all need to connect to the core. I have not yet seen any example of such a design process - or even a set of principles - which describe *how* to achieve such a des

Re: Dual license in a django world

2012-01-10 Thread Derek
I think you can already derive commercial apps if you so desire, without any license restrictions. See this post: http://jacobian.org/writing/paid-django-apps/ - a number of the comments point to existing commercial apps. On Jan 9, 8:46 pm, Thomas Weholt wrote: > It´s been harder and harder to

Re: Directory layout for a large Django application (not project)

2012-01-10 Thread Derek
Cal I agree that its true that having more experience allows you to build better web apps and get smarter about how you do that. But I disagree that someone with that experience cannot share some or part of the "why and how" that is done. And I hope someone will be able to :) De

Re: A problem with a solution, but is it the right one?

2012-01-23 Thread Derek
That sounds very interesting, Jeff - please post the link here. On Jan 20, 3:47 pm, Jeff Heard wrote: > Yeah, I started doing that after I posted...  Thanks for the advice.  I'll > be posting this code up on GitHub in a few days, as it's part of a > reasonably complete implementation for Django o

Re: Django from UML diagram

2012-11-28 Thread Derek
Google can help you! http://code.google.com/p/uml-to-django/ On Tuesday, 27 November 2012 11:44:19 UTC+2, Abbass Khalil wrote: > > Hello, > I'm a new to Django , and I'm looking for UML Tools that can generate > Django site from UML diagram. > -- You received this message because you are subs

Re: Model method versus overriding save()

2012-12-08 Thread Derek
Rather than use a trigger (which is DB-specific and also hard to debug because not part of your code base), suggest you use signals[1]. Derek [1] https://docs.djangoproject.com/en/dev/topics/signals/ On Saturday, 8 December 2012 04:27:50 UTC+2, Chris Cogdon wrote: > > It's a simple

Re: Theming Django with Diazo/XSLT

2012-12-17 Thread Derek
example. Derek [1] https://django-grappelli.readthedocs.org/en/latest/index.html On Friday, 14 December 2012 23:55:31 UTC+2, 4 The good Life we work wrote: > > Hallo, > > I'm used to theme Plone with Diazo/ <http://www.diazo.org/>XSLT. > <http://www.diazo.org/

manage.py collectstatic?

2012-12-28 Thread Derek
why? Thanks Derek -- 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 this group, send email to django-users+unsubscr...@googlegroups.com. For mo

Re: Announcment - django-databrowse

2013-01-10 Thread Derek
I for one hope that django.contrib.auth is never "wiped off" and handed off to some random third party. I think that the framework would be much poorer for its loss and I'm happy to trade off for a "slower and dirtier" Django to be able to keep its presence. On Wednesday, 9 January 2013 01:17

Re: ANN: Portable Python 2.7.3.2 released

2013-01-14 Thread Derek
Thanks Perica The download links on the page you refer to all point to ".exe" files. Where are the installers for Linux-based systems? (Python is a cross-platform tool). Thanks Derek On Saturday, 12 January 2013 15:25:43 UTC+2, Perica Zivkovic wrote: > > Dear people, >

Re: Field pre-load hook?

2013-01-14 Thread Derek
Maybe have a look at: * http://www.tylerlesmann.com/2008/dec/19/encrypting-database-data-django/ * https://github.com/svetlyak40wt/django-fields#readme On Sunday, 13 January 2013 22:00:24 UTC+2, Matt Barry wrote: > > Hi, > > I'm creating a model from an external database that has some encrypted

Re: What's the right pattern to re-use common view code?

2013-01-23 Thread Derek
If you'd read the Django Book (IMO, an essential "before you start with Django" read), you would have encountered the include tag in Chpt 4, the introduction to the templates: http://www.djangobook.com/en/2.0/chapter04.html On Tuesday, 22 January 2013 23:51:53 UTC+2, andrew jackson wrote: > > ..

Re: Announcing new django project

2013-02-04 Thread Derek
I agree - it looks great. What are the options for integration into the admin? It would be very useful for users to be able to edit single items in the change list. On Friday, 1 February 2013 16:17:39 UTC+2, h3 wrote: > > > Looks pretty cool, and maybe this is just my naivety at work, but how

Access to data via many-to-many while in save()

2013-02-06 Thread Derek
no data in the set... print len(Parent.objects.get(pk=obj.pk).m2m.all()) I know I am not grasping some key aspect of the problem; but I cannot see what it is, and would appreciate any help with this problem! Thanks Derek -- You received this message because you are subscribed to the Google

Re: django-quickview v0.1 released - proof-of-concept/comments wanted

2013-02-19 Thread Derek
When I try and access the site: https://bitbucket.org/weholt/django-quickview I get an error: You do not have access to this repository On Monday, 18 February 2013 21:58:14 UTC+2, Thomas Weholt wrote: > > Hi, > > I looked for django-announcements to post this in, but didn't find at > groups.g

Re: Survey : Theme for Django admin interface

2013-03-11 Thread Derek
On Monday, 11 March 2013 06:05:46 UTC+2, Venkatraman.S. wrote: > > > On Mon, Mar 11, 2013 at 3:49 AM, Emiliano Dalla Verde Marcozzi < > ed...@fedoraproject.org > wrote: > >> >> I was looking for this, but didnt find anything. i think it can have a >> great market, something like >> this web: >>

Re: [ANN] Introducing Brillixy - Django admin skin & customization kit

2013-03-14 Thread Derek
y is it to change template layout - e.g. I prefer filters on the right where they are out the way (preferable hidden by javascript, actually); also the elements seem to be scattered on the page and maybe they need to be "grouped" somehow (not a designer, just saying what I see...) Derek

Re: Creating, retrieving, updating and deleting objects.(Queries??) HELP

2013-04-09 Thread Derek
/en/2.0/index.html very helpful when I was starting out. Of course, these days various authors have written commercial books, so if you have $$$ then look to those as well. When you have specific questions, post them here! Derek On Saturday, 6 April 2013 13:24:15 UTC+2, Giorgos Kontogiorgakis

Re: Can admin list being filtered be remembered

2013-04-10 Thread Derek
Use this middleware: https://code.djangoproject.com/ticket/3777#comment:6 On Tuesday, 9 April 2013 23:41:25 UTC+2, frocco wrote: > > If I set a filter in the admin list, and edit and save a record, the > filter is not remembered. > Cn this be changed? > -- You received this message because yo

Using Django and R in a production environment?

2013-04-22 Thread Derek
s of users doing high volume number crunching)? Thanks Derek PS Yes, we do need R and not one of the Python-based alternatives, as R offers many routines simply not available in those as yet (also, the client needs to re-use, and create new, R scripts themselves) -- You received this message b

Re: I have searched and searched for a CSV Importer that does the following.

2013-04-23 Thread Derek
slope for your application - my advice is to avoid if at all possible!! Derek PS Also have a look at : http://code.google.com/p/django-batchimport/ On Monday, 22 April 2013 16:47:33 UTC+2, sparky wrote: > > I have searched and searched for a CSV Importer that does the following... > *

Re: Using Django and R in a production environment?

2013-04-23 Thread Derek
working. Perhaps there are less people in the sciences using Django than I thought... Derek On Tuesday, 23 April 2013 21:32:12 UTC+2, Per-Olof Åstrand wrote: > > I am not sure I understand your question, but is it really related to > using specifically R? Could it be any kind of hea

Re: Django Admin - BooleanField issue

2013-04-28 Thread Derek
Well, both Django and Python are consistent in their use of the terms "True" and "False" to represent boolean objects: https://docs.djangoproject.com/en/dev/ref/models/fields/#booleanfield http://docs.python.org/2/library/stdtypes.html#boolean-values In addition, the whole point of the ORM is to

Re: Using Django and R in a production environment?

2013-04-29 Thread Derek
route of using Celery or other job management tools makes > sense, especially if you can use R across multiple backend machines. > Would celery mean one rpy2 per celery? You don't really want all your > users using the same R session anyways. > > Thanks, > Alex > &g

Re: Using Django and R in a production environment?

2013-04-30 Thread Derek
their own sphere, to create an application that is really useful for better and more efficient science. On 29 April 2013 16:59, Javier Guerra Giraldez wrote: > On Mon, Apr 29, 2013 at 2:13 AM, Derek wrote: > > hat no one is actually using R in a production environment themselves > (

Re: Using Django and R in a production environment?

2013-04-30 Thread Derek
etup. It's > based on Unix user accounts, so R processes run as if users were running > them on a desktop, except not. You may be able to share code in this > environment too, but I haven't played with it a ton. > > http://www.rstudio.com/ide/docs/server/getting_started &

Re: Trailing zeros in DecimalField

2013-05-20 Thread Derek
Possibly related to localisation. See: https://groups.google.com/forum/?fromgroups#!topic/django-users/evJ7jg-YhdM https://docs.djangoproject.com/en/dev/topics/i18n/formatting/ On Sunday, 19 May 2013 01:37:22 UTC+2, Pedro J. Aramburu wrote: > > I've been reviewing the code of *models.DecimalFiel

Re: theme generator

2013-05-23 Thread Derek
Not sure it is being maintained, but may be a good starting point: http://www.djangoslingshot.com/ Also available is: https://github.com/ilblackdragon/django-themes On Tuesday, 21 May 2013 23:19:30 UTC+2, Kakar wrote: > > Hi! > Is there any kind of theme generator or css generator for django?

Re: Passing filter parameters to admin's add view

2013-05-27 Thread Derek
This may be a "red herring", but its also worth looking at how middleware handles things: http://www.b-list.org/weblog/2006/jun/13/how-django-processes-request/ On Saturday, 25 May 2013 17:53:00 UTC+2, Branko Majic wrote: > > Hello all, > > I've posted a similar question a couple of months ago,

Re: Django with Moodle

2013-05-28 Thread Derek
e B in a moodle database, but got Error C.) HTH Derek On Monday, 27 May 2013 15:48:13 UTC+2, Sourabh Banerjee wrote: > > I have moodle version 2.5.But its based on PHP. > So how to integrate Django with moodle.Need help. > -- You received this message because you are subscribed to t

Re: how to import excel file into django models?

2013-06-02 Thread Derek
specific fields. There is a ton of example code for xlrd on the web, and some with examples for Django. My code works with forms that let the user specify which columns are being used for what, rather than a command-line approach. How you handle this aspect depends on your use case... Derek

Re: saving latitude and longitude values in django

2013-06-05 Thread Derek
Your question seems to be more about using javascript with Django; have a look at this Q&A: http://stackoverflow.com/questions/5735107/basic-django-and-javascript-question There is also a lonk to a downloadable sample app. The "getting the values from the map via javascript" is a different kind o

Re: saving latitude and longitude values in django

2013-06-05 Thread Derek
code) On Wednesday, 5 June 2013 09:37:21 UTC+2, Derek wrote: > > Your question seems to be more about using javascript with Django; have a > look at this Q&A: > > http://stackoverflow.com/questions/5735107/basic-django-and-javascript-question > There is also a lonk to a d

Using django-autocomplete-light?

2013-06-10 Thread Derek
empty edit box, but beyond that there is no list displaying when I start typing... I'd appreciate any ideas as to how to get this basic example working. Thanks Derek # models.py class Country(Model): id = AutoField(primary_key=True) code = CharField(unique=True, max_length=5)

Re: Running a script through Django admin interface button/url

2013-06-11 Thread Derek
Hi Giorgos What you need to do is pick the appropriate admin template to customize, and add in your link (or link+button image) there. See: https://docs.djangoproject.com/en/dev/ref/contrib/admin/#overriding-vs-replacing-an-admin-template The web is littered with examples of how to do this...

Re: export .csv file from database

2013-06-19 Thread Derek
>From just a quick glance, I have probably missed complex here - but one option to try is changing the delimiter from a comma to another character (e.g. a semi-colon) - see: http://docs.python.org/2/library/csv.html#dialects-and-formatting-parameters (But its also possible that in all the encodin

Re: Problem when creating a form for adding users to groups

2013-06-19 Thread Derek
I think the problem is that you are using queries which are in the form: (id = some_list_of_items) and you cannot do that. Have a look at the "_in" syntax: https://docs.djangoproject.com/en/dev/ref/models/querysets/#in (That whole document is very useful one to read and understand; as making que

Re: Installing/implementing a Python-based API on my website

2013-06-21 Thread Derek
CND Your question seems obscure - what exactly do you mean " implementing it on a site"? If you have Django up-and-running (and I assume you do, because why else would you be here?), then the specialised code you write can be added to a file (e.g. "mycode.py") and saved, for example, in the sa

<    1   2   3   4   5   6   7   8   9   10   >