Re: Processing uploaded csv on the basis of user input

2015-01-15 Thread Jani Tiainen
Hi, I do something similiar this way: You could leverage Django (model)form to validate date and to normalize it to proper data. That way you would put design a contract between users that you state which column names are matched to your internal data. Then feed each row to (model)form if row

Processing uploaded csv on the basis of user input

2015-01-15 Thread David Mutton
Please let me know if this is an inappropriate question. I feel it is a little broad. I am fairly new to Django and coding an app for educational purposes. What I am trying to achieve is to allow users to upload a CSV and then populate a model by specifying that datatype that is in each

Re: filter

2015-01-15 Thread sum abiut
i expect to see only the data that have department_head_authorization="Approved" and department="FMKD" showing but instead the data that the department_head_authorization is not Approved is also showing. On Fri, Jan 16, 2015 at 11:58 AM, Vijay Khemlani wrote: > What are

Re: filter

2015-01-15 Thread Vijay Khemlani
What are you expecting to see? What are you actually seeing? On Thu, Jan 15, 2015 at 9:48 PM, sum abiut wrote: > Ok thanks, > > i just released that i have made a mistake. so basically here are my > template.html and view.py > i think there is a mistake in my view.py the

Re: filter

2015-01-15 Thread sum abiut
Ok thanks, i just released that i have made a mistake. so basically here are my template.html and view.py i think there is a mistake in my view.py the display result is not what i was looking for. can't seem to figure it out. template.html Select to approve leave First Name Last Name

Re: filter

2015-01-15 Thread Vijay Khemlani
in your view new_leave and a are QuerySet objects, and then you are comparing them to a string ("True") not a bolean (True without quotes), so it's always False. Even if you change "True" to True it won't work, try it like this if new_leave.exists() and a.exists(): return ... On Thu, Jan 15,

filter

2015-01-15 Thread sum abiut
Hi, I am trying to two column and display some result if two conditions are meet but i am getting this error: The view eLeave.views.FMKD1_leave_to_authorize didn't return an HttpResponse object. It returned None instead. I can seems to figure out the issue, here is my view.py file def

Re: Authenticate users with both username and email

2015-01-15 Thread Matt Cooper
Your if block in views.py is not well-formed. I haven't tested this but I'd write it more like this: # try username user = auth.authenticate(username=username, password=password) if user is not None: auth.login(request, user) return HttpResponseRedirect('/') #

Use django rest framework with dynamoDB

2015-01-15 Thread victor . garcia
I need to create an api-rest with django-rest-framwork for bring data from a database DynamoDB. -- 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

Canvas OAuth2 From Django View

2015-01-15 Thread Henry Versemann
First let me say that I haven't done a lot of stuff with either Python or Django, but I think I understand most of the basics. I am trying to get an access token back from the OAuth2 Web Application Flow of the Canvas' LMS API ( https://canvas.instructure.com/doc/api/file.oauth.html ). I have

Re: How not to explicly write very very big json object when rendering page in django template ?

2015-01-15 Thread Matlau Issu
OK. AJAX is the solution. -- 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 group, send email to

Re: Need some advice on how to go about building a real time web app.

2015-01-15 Thread Shazwi Suwandi
Hi group, I'm facing a very weird issue that causes a clash when I use swampdragon's *SelfPublishModel* and django's *models.Model*. This is the current model that I'm using. class Activity(SelfPublishModel, models.Model): content = models.TextField() dateTime = models.DateTimeField()

Re: ChoiceInline field giving name error

2015-01-15 Thread sanjeet kaur
> > Are you following any tutorial? If yes, provide link. Yes I was following tutorial of poll app and the error was solved by the solution provided by vinayak -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and

Authenticate users with both username and email

2015-01-15 Thread Kakar Nyori
I have extendted the *UserCreationForm* with email and other fields, so that I could authenticate a user with both its username and email. forms.py: > class UserCreationForm(UserCreationForm): > class Meta: > model = User > fields = ('first_name', 'last_name', 'username', 'email',)

Re: Which 3rd Party (Social) Auth App should I use?

2015-01-15 Thread Tobias Dacoir
After more reading and experimenting I think I will use django-allauth. It allows local and social auth and signup. And I was able to customize the local signup form very easily (thanks to stackoverflow). -- You received this message because you are subscribed to the Google Groups "Django

Re: ChoiceInline field giving name error

2015-01-15 Thread sanjeet kaur
On Jan 15, 2015 4:17 PM, "Kamal Kaur" wrote: > > On Thu, Jan 15, 2015 at 4:08 PM, sanjeet kaur wrote: > > Yes I tried but all that is correct. > > Are you following any tutorial? If yes, provide link. Error solved -- You received this message

Re: ChoiceInline field giving name error

2015-01-15 Thread Kamal Kaur
On Thu, Jan 15, 2015 at 4:08 PM, sanjeet kaur wrote: > Yes I tried but all that is correct. Are you following any tutorial? If yes, provide link. -- Kamaljeet Kaur -- You received this message because you are subscribed to the Google Groups "Django users" group. To

Re: ChoiceInline field giving name error

2015-01-15 Thread sanjeet kaur
> > > Have you tried this? > > http://stackoverflow.com/questions/22768262/nameerror-not-defined > > -- > Kamaljeet Kaur > Yes I tried but all that is correct. -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this