Re: How to create two different login system

2018-12-13 Thread Manjunath
There are multiple options to maintain different kind of users in Django. When I came across this situation, I created a custom User class by inheriting AbstractBaseUser class and kept a positive integer field to maintain the type of user. Then I created Sub-classes Manager & Employee classes.

Re: How to create two different login system

2018-12-13 Thread Mike Dewhirst
On 14/12/2018 5:28 PM, maunish dave wrote: My project contains two user one for managers and other for employees any suggestions? Django contrib.auth already has groups and I use them for deciding what they can see vertically. Horizontally I use the ordinary relational mewchanisms. Here is

How to create two different login system

2018-12-13 Thread maunish dave
My project contains two user one for managers and other for employees any suggestions? -- 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

Google Plus going away - is Groups staying ?

2018-12-13 Thread Brenda Stensland
Hey - Heard that Google + is going away ... Does that include this group ? Anyone know ? Hate to see that happen! -- 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

Re: Problems from writing test cases.

2018-12-13 Thread ANi
> > Great! Thank you for the explanation, it's what exactly I want to know, >> really helps a lot. ;-) >> > nm於 2018年12月13日星期四 UTC+8下午10時25分36秒寫道: > > Regarding the first question and the problem with retrieving the user with > `pk=1`: > When you run your tests, Django creates a test

Re: Problems from writing test cases.

2018-12-13 Thread ANi
> > Great! Thank you for the explanation, it's what exactly I want to know, >> really helps a lot. ;-) >> >> nm於 2018年12月13日星期四 UTC+8下午10時25分36秒寫道: > > Regarding the first question and the problem with retrieving the user with > `pk=1`: > When you run your tests, Django creates a test database

Create an Unique Charfiled

2018-12-13 Thread Aprimus
Hi I want to create an unique id in django charfield field: Its better to make a sort of custom Charfiled like this: class AutoGenerateCodeField(models.CharField): def __init__(self, min_length=None, *args, **kwargs): self.min_length = min_length or 4

Re: DJANGO FOR FINANCE !

2018-12-13 Thread codesign web za
I eventually chose django-chartjs and django-datatable for this On 13/12/2018 19:55, carlos wrote: yes, is posible in Django make forms for input user and output make grahp and table Cheers On Thu, Dec 13, 2018 at 9:35 AM Mamoudou Diallo mailto:mamoudoutal...@gmail.com>> wrote: Hey

Re: DJANGO FOR FINANCE !

2018-12-13 Thread carlos
yes, is posible in Django make forms for input user and output make grahp and table Cheers On Thu, Dec 13, 2018 at 9:35 AM Mamoudou Diallo wrote: > Hey EVERYONE ! > > I am working on a project where I am would like to use django to build a > site that computes certain financial formulas based

Re: about unique_together

2018-12-13 Thread Peter of the Norse
Django doesn’t support multiple primary keys. unique_together just adds an extra constraint to the table. Since you didn’t specify a primary key, id was added for you by default. Sent from my iPad > On Nov 14, 2018, at 1:55 AM, 胡超 wrote: > > > class QdProjectAssist(models.Model): >

Re: python manage.py migrate failed

2018-12-13 Thread Simon Charette
It looks like you configured your CMS_CACHE_DURATIONS setting as an integer instead of a dict with a 'content' key pointing to an integer[0]. In other words you did CMS_CACHE_DURATIONS = 42 Instead of CMS_CACHE_DURATIONS = {'content': 42} Cheers, Simon [0]

channels layers connect with aws ec2

2018-12-13 Thread rajpootsuryasingh
How to connect *CHANNEL_LAYERS* config host on AWS ec2 ? CHANNEL_LAYERS = { 'default': { 'BACKEND': 'channels_redis.core.RedisChannelLayer', 'CONFIG': { "hosts":[("", 6379)], }, }, } I am trying like this. please help me. Thanks, -- You received this message

pyhton manage.py migrate not working

2018-12-13 Thread Gilles Zoratti
Dear every one, i'm new in the Django cms environment, and I need your help ! ( please :) ) When I tried to "install" the cms is not working, I had a long list of error message (venv) project@project-web:~/work.project.www$ python manage.py migrate Traceback (most recent call last): File

Django Multipleselect

2018-12-13 Thread Anas P H
I've used CheckboxSelectMultiple one field in my view.It shows up fine in the browser, but on submit I receive the "Select a valid . That choice is not one of the available choices." but i selected already. anybody please help. -- You received this message because you are subscribed to the

Re: Problems from writing test cases.

2018-12-13 Thread nm
Regarding the first question and the problem with retrieving the user with `pk=1`: When you run your tests, Django creates a test database where all the objects created by the test cases are stored, and which is destroyed after all the tests are run. Each user you create gets a *new* pk. The pk

Issue with model method (Solved)

2018-12-13 Thread Felix Lazaro Carbonell
I beg your pardon. It was my mistake in a functional test. I missed part of the data needed to make it work correctly. Thank you all. -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving

Re: How to send parameters to templates and adjust the page url by path?

2018-12-13 Thread Saeed Pooladzadeh
Thank you Ira در چهارشنبه 12 دسامبر 2018، ساعت 19:21:26 (UTC-8)، lingo...@gmail.com نوشته: > > Hello, > > How to send parameters to templates and adjust the page url by path? > > regards, > > Saeed > -- You received this message because you are subscribed to the Google Groups "Django users"

Re: Help with data bound ModelChoiceField

2018-12-13 Thread Glen D souza
In the First Screenshot the code is def __str__(self): return "Customer" + "self.id" Remove the quotes from "self.id" def __str__(self): return "Customer" + self.id On Wed, 12 Dec 2018 at 10:47, wrote: > > TY madjardi for all your input! I continued to search and found what I > wanted.