Django runserver needs restart on psql data changes

2015-04-29 Thread Arnab Banerji
Hi all - I am working on a Django app that interacts with a psql database via a set of models. (1) There is a backend job which keeps updating the database via the same models. (2) I am creating a table with a view using django_tables2 - and giving it a custom dictionary to render using data

Re: Django runserver needs restart on psql data changes

2015-04-29 Thread Arnab Banerji
:09:26 PM UTC-5, Javier Guerra wrote: > > On Wed, Apr 29, 2015 at 12:35 PM, Arnab Banerji > wrote: > > The rendering happens perfectly, but the problem is - when the client > user > > does a browser refresh, the new data does not get reloaded until I > restart

Re: Django runserver needs restart on psql data changes

2015-04-29 Thread Arnab Banerji
-5, Carl Meyer wrote: > > Hi Arnab, > > On 04/29/2015 03:13 PM, Arnab Banerji wrote: > > Hi Javier - thanks for the response. Yes - I am storing the data in a > > dictionary - then having django_tables2 API render the dictionary as a > > table. How do I force a r

Model inheritance with constraints

2016-05-25 Thread Arnab Banerji
Hi all, I currently have a set of models associated with my Django app, with the database already containing data with respect to these tables (models). What I have = class MyFunModel(models.Model): my_foo_field = What I am attempting to add = class MyAnother

Re: Model inheritance with constraints

2016-06-01 Thread Arnab Banerji
Hi Akhil - my issue was how to avoid the new OneToOne relationships, which James addressed on this post. Hi James - thanks a bunch for your help, much appreciated. While I like the WYSIWYG nature of this solution, I am not sure if the creation of the abstract base class will cause the data alre

Re: Model inheritance with constraints

2016-06-01 Thread Arnab Banerji
Nevermind my last comment on this thread, when I refactored my existing model into an abstract base class with overrides, and then ran "makemigrations", Django said "no changed detected", so it is merely treated as a code refactor and not a database related change. Thanks AB -- You received t

Django split pane with highlighting

2015-09-14 Thread Arnab Banerji
Hi all - here is what I am trying to achieve - I need a split pane view with the following contents: (1) the right half will contain a bunch of links, (2) the left half will be one long static document Depending on which link is clicked on the right hand side, I want the appropriate section

Django w/ XML DOM

2015-09-18 Thread Arnab Banerji
Hi - I am looking for a way to display XML documents in Django and get the xml section information from cursor location using XMLCursor like capabilities from XMLBeans (or its replacement, jaxb). Is there a supported library for that? Unfortunately, JSON would not be a good structure for this d

Complex form in modelform

2015-10-19 Thread Arnab Banerji
Hi - I am trying to create a form from a model, say M with the following: (1) a certain field FOO is a text field which would be constructed in views.py by concatenating a dynamic set of rows (so I need a jQuery plugin for that). (2) multiple images can be tied to the model M, and I have a Fore

Concatenate complex views

2016-01-13 Thread Arnab Banerji
Hi - I am trying to concatenate "read-only" form views of all objects pertaining to a given model in a single page (I already have a template for viewing the form for one object). Given that the forms are reasonably complex (in some cases involving formsets), a simple "inclusion tag" approach d