Start your site with python manage.py runserver 0.0.0.0:8000
On Thu, 5 Nov 2015 at 11:35 Muhammad Asamov wrote:
> HI
> I was wodering whether someone can hepl me with startproject
>
> The thing is when I am running startproject from the server ip
> 127.0.0.1:8000
> which was created automaticly
HI
I was wodering whether someone can hepl me with startproject
The thing is when I am running startproject from the server ip
127.0.0.1:8000
which was created automaticly i can see the result but if i give different
address:
0.0.0.0:8000 I can see nothing it is not showing anything
Actuall
On Wed, Nov 4, 2015 at 11:58 PM, victor menezes
wrote:
> I agree that it is time for django to change it (at least making the
> changes easier)
>
I’m intrigued - exactly how much easier do you want us to make it?
At this point, it is *literally* installing a third party app, adding that
app to
I am having different URLs configuration. same view is called for two URLs
based on **kwargs decision is made what to do? In one of case I need to get
result of all related objects which is tagged with given keyword. I found
another way to do achieve same using function based view.
On Thursday,
On Sunday, October 25, 2015 at 5:43:50 PM UTC+1, Kitti Wateesatogkij wrote:
>
>
> I'm interested in django if there's a package that fits my requirements so
> I don't have to do it all manually in Flask. If possible please recommend
> such packages for me.
>
>
Django will give you more tools O
>
>
> On Wednesday 04 November 2015 10:43 PM, Avraham Serour wrote:
> So I have to use a client connection object such as Python request
> So I want to keep it as global, so that all views can access it from a
> single location, instead of creating a client request instance for every
> view on
On Wednesday 04 November 2015 10:43 PM, Avraham Serour wrote:
the question is why, why would you want to store a global connection
for a REST server?
keep in mind that you would be making HTTP requests, meaning even that
you had a global variable holding the connection it would just open
and
Hi all,
I just discovered Django and i'm using GenericIPAddressField in my fisrt
app.
I currently use Django 1.6.11 and i'm facing a problem with ipv6 validator.
I ran the following test case:
***
from django.utils.ipv6 import is_valid_ipv6_address
def check_ipv6_validator(ipv6):
Hi Django users,
I am looking for a Django consultant with knowledge in
nginx/Gunicorn/Ubuntu server administration skills. If I am in the wrong
place, I apologize in advance. I appreciate if you refer me to a venue I
could look for Django consultants for hire.
A brief description. A dedicated
On 2015-11-04 18:39, Gergely Polonkai wrote:
> An even more fine grained solution may be using an HTML parser like
> beautifulsoup. However, if your site's functionality depends on
> client side features like JavaScript, Selenium may be a better
> alternative.
My code doesn't rely on any JavaScri
On Wednesday, 4 November 2015 20:51:53 UTC, sonu kumar wrote:
>
> class based views are as below
>
> class TagList(TemplateView):
>
> def get_context_data(self, **kwargs):
>
> ...
>
> qlist = QueList.as_view()(self.request, **kwargs)
> print qlist
>
> ...
>
class based views are as below
class TagList(TemplateView):
def get_context_data(self, **kwargs):
...
qlist = QueList.as_view()(self.request, **kwargs)
print qlist
...
class QueListView(ListView):
def get_context_data(self, **kwargs):
HI!
Thanks for the pointers. I actually was able to solve it by myself. What I
did was create a multichoice checkbox field in a form. Then I used a bit of
javascript just to reformat the parameters in a way that I wanted then.
Works very good actually. :-)
Med vänliga hälsningar,
Andréas Kühne
S
I am trying to add admin action 'download_selected'. When the action is
selected, it redirects to an intermediate page. When the user selects a
file type and clicks on 'download', it downloads the file and stays on that
page. How do I redirect it back to change form page it happens for
'delet
This really depends on the structure of your models. In this case you will
most likely have a ForeignKey in one of your models; if the referenced
model has an __str__() method, the admin site (and also any other forms)
will display names instead of the text "OtherModel object".
On 4 Nov 2015 17:19,
An even more fine grained solution may be using an HTML parser like
beautifulsoup. However, if your site's functionality depends on client side
features like JavaScript, Selenium may be a better alternative.
On 4 Nov 2015 18:33, "Dheerendra Rathor" wrote:
> You can use unittest.TestCase.assertReg
In your model use define __str__ method to name1. Then django admin will
use name1 in dropdown box.
On Wed, 4 Nov 2015 at 21:50 frocco wrote:
> Hello,
>
> I have two existing tables
> table1 has name1
>
> table2 has name2
>
> when I edit table2 in admin, I want a dropdownbox that shows values fr
You can use unittest.TestCase.assertRegexpMatches for checking if form is
present in rendered template.
If you want to check the entire cycle (form loading, filling) you can use
selenium for testing on live server.
On Wed, 4 Nov 2015 at 22:08 Tim Chase
wrote:
> Beginning a new project, I'd like
the question is why, why would you want to store a global connection for a
REST server?
keep in mind that you would be making HTTP requests, meaning even that you
had a global variable holding the connection it would just open and close
each tie you make a request.
if you need t keep a connection
Details are available on the Django project weblog:
https://www.djangoproject.com/weblog/2015/nov/04/bugfix-release-issued/
--
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 a
On 4 Nov 2015 17:31, "kk" wrote:
>
>
> Ok one question,
> I would like to store a client connection in some kind of a global place
for my entire Django frontend.
> So that the request object can be used from any view.
> Can you suggest some guideline to do this?
> Happy hacking.
> Krishnakant.
Lots of ideas here:
http://stackoverflow.com/questions/5043012/django-trim-whitespaces-from-charfield
On Tuesday, 3 November 2015 16:31:26 UTC+2, DJ-Tom wrote:
>
>
> It worked! Basically it was a one-liner as well :-)
>
>
>
--
You received this message because you are subscribed to the Google
Beginning a new project, I'd like to include functional testing in
addition to my unit tests. What are recommended best practices for
exercising form-classes? I was hoping to do something like
c = django.test.Client()
results = c.get(page_url)
frm = SomeForm()
# pseudo-code for desired f
This project does not seem active, but maybe you could still make use of it:
https://github.com/kevwilde/django-adminfilters
Otherwise some other suggestions:
http://stackoverflow.com/questions/7834990/selecting-multiples-choices-in-django-admin-filter-list-filter
On Monday, 2 November 2015 16
Ok one question,
I would like to store a client connection in some kind of a global place
for my entire Django frontend.
So that the request object can be used from any view.
Can you suggest some guideline to do this?
Happy hacking.
Krishnakant.
On Tuesday 03 November 2015 08:35 PM, Remco
Hi,
So I may have judged too fast. Turns out you were pretty close! I saw that
the contributors to the plugin used jQuery in their demo project and I
tried it as well... And it worked!
Thanks for the suggestion! Really helped me out here :)
Op zaterdag 24 oktober 2015 20:01:36 UTC+2 schreef C
Hi,
So I may have judged too fast. Turns out you were pretty close! I saw that
the contributors to the plugin used jQuery in their demo project and I
tried it as well... And it worked!
Thanks for the suggestion! Really helped me out here :)
Op vrijdag 23 oktober 2015 14:54:49 UTC+2 schreef Ju
Hello,
I have two existing tables
table1 has name1
table2 has name2
when I edit table2 in admin, I want a dropdownbox that shows values from
table1 using name1
both fields are character
I cannot change the design, porting from msaccess
thanks
--
You received this message because you are su
Looks like you are not making anything very custom on you view so maybe
would be easier/better to use the buitin views from django auth.
on your urls.py you can do:
from django.contrib.auth import views as auth_views
urlpatterns = [
...
url(r'^login/', auth_views.login),
]
On your sett
I agree that it is time for django to change it (at least making the
changes easier).
On my project I did create a new user model that inherit from AbstractUser
class UserManager(BaseUserManager): ...
class User(AbstractBaseUser): email = models.EmailField(unique=True)
objects = UserManager() US
Hello Collin,
Thanks for your reply! I tried using jQuery 1.2.6. but it sadly didn't help
my problem. Since the plugin is still updated regularly, I think using the
newest jQuery plugin shouldn't be a problem.
The weird thing is, today I was playing around with the problem, and it
turns out that
Yes, there *is* a very simple way to implement “Email address as username”
- you use a custom user model that implements that approach.
https://docs.djangoproject.com/en/1.8/topics/auth/customizing/#substituting-a-custom-user-model
Django’s docs contain details of how to do this, and there are a
Hi Patrick,
I used emails "as usernames" many times in my projects. You can use
django-authtools (https://github.com/fusionbox/django-authtools), it has an
AbstractEmailUser
(https://django-authtools.readthedocs.org/en/latest/intro.html#authtools.models.AbstractEmailUser).
You can set your ow
Hello,
I'm playing around with the 1.9 beta release. The __date field lookup
(casts DateTimeField to a date) is a very useful new addition. However, it
doesn't seem to work in a custom QuerySet.
models.py
class EntryQuerySet(models.QuerySet):
def today(self):
today = now().date()
Thanks, I will try this,
Axel
> Am 02.11.2015 um 13:50 schrieb Vijay Khemlani :
>
> At least what I do in those cases is to add a constructor (__init__) to the
> form class which takes the user as a parameter, modify the choicefield
> queryset, and then call the original constructor of the form
By default emails are not unique in Django.
There are several approaches you can use:
1. In your login view use email to fetch user and then call authenticate
for username. For signup you can use any garbage username!
2. Write custom user model (Just extend User model and change
USERNAME_FIELD to e
Is there a current "best" approach or module for signup/login with an email
address?
I can't believe this is not included with django. In fact, it should
be the default. 80-99% of services and projects do not use usernames.
--
You received this message because you are subscribed to the Google
Are you suggesting that there's a relatively easy way to implement "email
address as username"? Is it as easy as just putting an email address into
the username field? And making sure to update it when someone updates their
email address?
On Monday, January 19, 2015 at 2:33:35 AM UTC-8, James
38 matches
Mail list logo