Re: Django M2M with Oracle database FieldDoesNotExist error

2016-06-10 Thread Felipe Horta
Hi everyone, I'm following this thread and I'm having the same error. Im running a postgis db, and despite the biginteger pk, my problem is the same. Could you solve it? Thanks! On Monday, August 3, 2015 at 11:16:12 PM UTC-6, mohse...@gmail.com wrote: > > i found that even trying to access the

Re: Display objects from different models at the same page according to their published date

2016-06-10 Thread Aamu Padi
Yes, I too was thinking about that. I had doubts about the space and the performance of it. Do you see any downside \on the space and performance? On Fri, Jun 10, 2016 at 6:57 PM, Rafael Guillén wrote: > Instead of making them entirely separate models, you can use one model as > a base and have

Re: Display objects from different models at the same page according to their published date

2016-06-10 Thread Rafael Guillén
Instead of making them entirely separate models, you can use one model as a base and have the other models inherit from them, then you display the base model. I think this might be a good fit for multi-table inheritance. See if this helps: https://docs.djangoproject.com/en/1.9/topics/db/models/

Re: Django and jQuery, I don't get it

2016-06-10 Thread Stephen J. Butler
Specifically, this style is called an Immediately Invoked Function Expression, or IIFE. https://en.wikipedia.org/wiki/Immediately-invoked_function_expression On Fri, Jun 10, 2016 at 3:36 AM, ludovic coues wrote: > > (function($) { > > 'use strict'; > > > > })(django.jQuery); > > Th

Re: Stuck on tutorial your first Django app part 2

2016-06-10 Thread Neil Hunt
I just went through the tutorial again to check what the definition of my __str__() method was and I noticed where the tutorial says to add a custom method to polls/models.py. Before I copied and pasted a whole new object and method to the file instead of adding the custom method to the object.

GenericRelations admin form inline

2016-06-10 Thread sunit
I am using django 1.8.4 and i have following model class Book(models.Model): title = models.CharField(max_length=100) class Article(models.Model): title = models.CharField(max_length=100) class Paper(models.Model): title = models.CharField(max_length=100) class Rating(models.Model): #Ge

Re: Display objects from different models at the same page according to their published date

2016-06-10 Thread Aamu Padi
This is just a follow up of my question. I don't want to show each of the model objects separately at the same page. But like feeds of facebook or any other social media. Suppose a new Job object was created, and after that a new News object is created. Then, I want to show the News object first,

Display objects from different models at the same page according to their published date

2016-06-10 Thread Aamu Padi
I have three different models for my app. All are working as I expected. class Tender(models.Model): title = models.CharField(max_length=256) description = models.TextField() department = models.CharField(max_length=50) address = models.CharField(max_length=50)

Re: Django query returns nothing for legacy databse

2016-06-10 Thread Galil
@Gagaro, thanks! That worked for me! @Remco Gerlich, no I don't have a database router as what I am doing now is very simple But thank you for you answer anyway! -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group an

Re: how to forbidden mouse click and keyboard typing when loading page after press submit button in django web?

2016-06-10 Thread Sergiy Khohlov
nothing to do Simple way is adding unique ID to the request and use it to server request: Example : 1) User get page with id 1 2) User send data to server using id 1 3) Server send answer with ok and next ID 2 In case of multiple POST only first with ID1 is server, other request is send t

Re: Django and jQuery, I don't get it

2016-06-10 Thread ludovic coues
> (function($) { > 'use strict'; > > })(django.jQuery); This syntax is called a closure. First you declare a function so you don't contaminate the global scope with your local declared variable. Then you execute your function. I will assume django.JQuery is the version of JQuery shipp

Re: FieldDoesNotExist during custom migration

2016-06-10 Thread Gagaro
The issue was with my model which had a unique_together with the field removed in it. Fixed migrations are: class Migration(migrations.Migration): operations = [ migrations.AddField( model_name='Rendition', name='filter2', field=models.CharField(ma

Re: how to forbidden mouse click and keyboard typing when loading page after press submit button in django web?

2016-06-10 Thread meInvent bbird
sorry for wrong post because i am not familiar with javascript to deal with this problem i just afraid user crazily press refresh button multiple times or ctr + r multiple time during page loading On Friday, June 10, 2016 at 2:28:09 PM UTC+8, Sergiy Khohlov wrote: > > This is not django questi