Re: passing url variables to views

2016-05-31 Thread Akhil Lawrence
Yeah In your view you can access it by kwargs.get('user_del') On Wed, 1 Jun 2016 at 02:33 dk wrote: > and then i can use it in the view? as an argument? > > > On Tuesday, May 31, 2016 at 12:33:55 PM UTC-5, Akhil Lawrence wrote: >> >> Hi, >> >> The URL you are calling is wrong.. >> >> You shou

Re: why blank page when load a list or dictionary into web to display a list

2016-05-31 Thread meInvent bbird
if checked a few check box and save, how to add check box field and get the value of checkboxes? https://drive.google.com/file/d/0Bxs_ao6uuBDUeW9BQzA1RTlHZEE/view?usp=sharing the number of rows in http://x.x.x.x/reg/approval.html depend on data in csv, On Saturday, May 28, 2016 at 10:22:01

how to add a dynamic number of check field and save?

2016-05-31 Thread meInvent bbird
https://drive.google.com/file/d/0Bxs_ao6uuBDUeW9BQzA1RTlHZEE/view?usp=sharing the number of rows in http://x.x.x.x/reg/approval.html depend on data in csv, if checked a few check box and save, how to add check box field and get the value of checkboxes? -- You received this message because yo

Re: how to upload file with pjango

2016-05-31 Thread meInvent bbird
after following the web, it only run one time first time the function in views.py but after press button, it do not run post method because console did not show POST. where is wrong? https://drive.google.com/file/d/0Bxs_ao6uuBDUdGpUX3p0TjZrRGM/view?usp=sharing On Friday, May 27, 2016 at 9:50

Re: why blank page when load a list or dictionary into web to display a list

2016-05-31 Thread meInvent bbird
really really thanks after tried, it works. On Saturday, May 28, 2016 at 10:22:01 PM UTC+8, Akhil Lawrence wrote: > > Dude, > > You need to make the following changes. > > 1. you need to pass a dictionary as the context in your views > > return render(request, 'approval.html', {'posts': post

django.db.migrations.graph.NodeNotFoundError:

2016-05-31 Thread Bose Yi
When new project start, commands makemigrations and runserver get error message.I do not know what I did wrong. I cannot find solution to fix it. Please any suggestion ? ---

Re: passing url variables to views

2016-05-31 Thread dk
and then i can use it in the view? as an argument? On Tuesday, May 31, 2016 at 12:33:55 PM UTC-5, Akhil Lawrence wrote: > > Hi, > > The URL you are calling is wrong.. > > You should call it like > http://127.0.0.1:8000/my_app/run_delete/ccc_ccc***a_b***/ >

Re: DjangoCon Philly July 17-22. See you there?...

2016-05-31 Thread fred
Python programmers, Consultants and Job Seekers, Today's the last day of early bird pricing for DjangoCon, the world-wide Django conference, which is in Philly this year! With the $50 early-bird discount, this 6-day event costs only $295 (individual), $495 (corporate), with a student/diversity

Re: how to append all-auth in my django project

2016-05-31 Thread Akhil Lawrence
This might help http://piratelearner.com/en/C/course/computer-science/django/django-all-auth-all-you-need-to-know/8/ On Sunday, 29 May 2016 22:15:56 UTC+5:30, pratyush singh wrote: > > i started a project and now i dont understand how to add all-auth to my > project i am having problem to un

Re: Adding view permission by default to auth_permission

2016-05-31 Thread Akhil Lawrence
Ander, Please add your suggestion as a ticket in django ticketing system. https://code.djangoproject.com/newticket On Monday, 30 May 2016 23:43:18 UTC+5:30, Ander Ustarroz wrote: > > I am surprised this feature is not implemented yet, at the moment when we > create a new model three permissi

Re: Django: Begginer Problems

2016-05-31 Thread Akhil Lawrence
As Ryan mentioned. Go through the forms tutorial. Formsets may also help. Have a look. https://docs.djangoproject.com/en/1.9/topics/forms/formsets/ On Monday, 30 May 2016 04:54:16 UTC+5:30, David Zárate wrote: > > Hi! I'm making a financial analysis app in Django and to have some data to >

Re: Looking for a good Django Forum

2016-05-31 Thread Adam
Me too - I'm looking for something simple; I have only looked at packages that were updated in 2016, so far I have examined: Pybbm - I tried this - the templates, views and models were complicated and hard to customize though the documentation was good. I may go back to this. Spirit

Re: Django websites for study and improvement

2016-05-31 Thread Akhil Lawrence
You can get many django based applications from github. https://github.com/taigaio/taiga-back https://github.com/mayan-edms/mayan-edms/ https://github.com/stephenmcd/cartridge You can also refer https://github.com/rosarior/awesome-django https://github.com/search?q=django Even though you are

Django websites for study and improvement

2016-05-31 Thread Ankush Thakur
Are there any large-ish (I mean, beyond blogs, polls, etc.) websites (web apps?) out there that are open source and can help me learn in the real world? I have covered the basics, even converted my own blog into Django, but I feel I don't know anything about how Django is used out in the wild. I c

Re: Simultaneous Web Requests appending responses in function based views

2016-05-31 Thread Stephen J. Butler
The code and output you've shown us don't make any sense. You're really going to have to provide a complete, minimal project. On Tue, May 31, 2016 at 9:40 AM, cr katz wrote: > Thanks Stephen. As suggested, below is the output. 'p' is being > overwritten before the first response is completely re

Re: passing url variables to views

2016-05-31 Thread Akhil Lawrence
Hi, The URL you are calling is wrong.. You should call it like http://127.0.0.1:8000/my_app/run_delete/ccc_ccc***a_b***/ No need to pass it as an query parameter. On Tuesday, 31 May 2016 15:03:59 UTC+5:30, dk wrote: > >

Re: passing url variables to views

2016-05-31 Thread dk
i was looking for something like this https://docs.djangoproject.com/en/1.9/ref/urls/#django.conf.urls.url http://stackoverflow.com/questions/15644809/django-url-patterns the tutorial use d for getting the number of the years, =( i am skipping a step? -- You received this message because

Re: parent: [ 'Invalid pk "0" - object does not exist.' ] and null or blank value not store in mysql

2016-05-31 Thread James Schneider
On Tue, May 31, 2016 at 5:21 AM, L K Singh wrote: > class AccountType(ModelBase): > parent = models.ForeignKey('self',on_delete = models.SET_NULL, null=True, > blank=True, default=None ) > > > class AccountTypeSerializer(serializers.ModelSerializer): > parent = > serializers.PrimaryKeyR

Re: Simultaneous Web Requests appending responses in function based views

2016-05-31 Thread cr katz
Thanks Stephen. As suggested, below is the output. 'p' is being overwritten before the first response is completely read and sent to the browser. Hello, I am X Hello, I am Y Hello, I am A Entered Search hd-www-stage 2016-05-30 00:00:00 UTC Hello, I am X Hello, I am B Hello, I am Y [31/Ma

Re: setting custom header before redirect

2016-05-31 Thread Larry Martell
On Tue, May 31, 2016 at 7:53 AM, Larry Martell wrote: > I need to set a custom header before I do a redirect. My code does this: > > resp = redirect(uri) > resp['X-Capdata-Auth'] = 'authorized' > return resp > > But when I look at the traffic with tcpdump, I do not see that header > va

Re: Django: Begginer Problems

2016-05-31 Thread 'Ryan Nowakowski' via Django users
On Sun, May 29, 2016 at 02:22:48PM -0700, David Zárate wrote: > Hi! I'm making a financial analysis app in Django and to have some data to > play with i have to store historical data of balance sheets and profit/loss > statements. I need some suggestions on how i can accomplish that. > > Th

parent: [ 'Invalid pk "0" - object does not exist.' ] and null or blank value not store in mysql

2016-05-31 Thread L K Singh
class AccountType(ModelBase): parent = models.ForeignKey('self',on_delete = models.SET_NULL, null=True, blank=True, default=None ) class AccountTypeSerializer(serializers.ModelSerializer): parent = serializers.PrimaryKeyRelatedField(queryset=AccountType.objects.all(), required=False,

setting custom header before redirect

2016-05-31 Thread Larry Martell
I need to set a custom header before I do a redirect. My code does this: resp = redirect(uri) resp['X-Capdata-Auth'] = 'authorized' return resp But when I look at the traffic with tcpdump, I do not see that header value. What am I doing wrong here? -- You received this message becau

change display value of filter in admin

2016-05-31 Thread Brad Rice
I have a field that has two values set "S" or "E". I use it to filter records in the admin. I would like the values in the filter to be spelled out as "Signature" and "Emerging". How do I have it show like that in Admin? This is my filter: list_filter = ('app_complete', 'app_type') app_type

Re: passing url variables to views

2016-05-31 Thread Mandeep Tondak
Hey you are passing query string in url not an argument . i thing ur url should work as this url(r'^run_delete/$', views.run_delete, name='run_delete') and in your view def run_delete(): if request.GET.get('user_del'): On Tue, May 31, 2016 at 3:03 PM, dk wrote: > this is the URS i g

passing url variables to views

2016-05-31 Thread dk
this is the URS i get http://127.0.0.1:8000/my_app/run_delete/?user_del=ccc_ccc***a_b***/ and i want to be able to get the string *ccc_ccc***a_b my url pattern is: url(r'^run_delete/(?P\w+)/$', views.run_delete, name='run_delete') but it looks like is not catching it, i am missing so