migrate failed due to Permission

2019-01-13 Thread ANi
Hello. I want to migrate all tables into new database but bumped into an error that it said "auth_permission" is not found. Then I searched for the possible causes, it turned out that it is because I accessed the auth model "Permission" in my code before the migrate creating table in database.

Set default value in field dependant on another model?

2019-01-13 Thread Lachlan Musicman
We have two models: Resources and Quota Resources model instances include: - red things - yellow things - blue things Quota have two fields, one is a FK to a Resource, the other is "desired quota". When instantiating the Quota request form, we create a form for each Resource. I'd like to autofil

Re: order_by function gets error if the field name or json key, has a dash.

2019-01-13 Thread Jason
I think the easiest way would be to convert the dash to an underscore to follow python standards when it comes to naming. reason being, a dash is analogous to the subtraction mathematical operation so you're requiring python to know the difference in the usage of this character in names and op

order_by function gets error if the field name or json key, has a dash.

2019-01-13 Thread Jonathan Espinal
order_by function gets error if the field name or json key, has a dash. I know Django use a dash for asc or desc methods. but in this case the dash is in the middle. EXAMPLE: MyTable.objects.all().order_by('myfield__en-us') I have a jsonb field like: { "es": "Casa", "en-us": "House"

Re: Django-error about files

2019-01-13 Thread Tarık Kantar
All right! Could you please say how can I am inside of my project’s folder? I actually new for using these processes. Thank you so much. On 13 Jan 2019 Sun at 21:01 Nebojsa Hajdukovic wrote: > you need to be inside of your project's folder, not users\asus > > нед, 13. јан 2019. у 20:59 је напис

Re: Django-error about files

2019-01-13 Thread kennedy kay
This is most probably because you are not in the directory containing manage.py Ensure you are in the directory containing 'manage.py' To do enter the command >dir see if the list of files in that directory contains manage.py If not, then >cd nam-of-folder-containing-manage.py Voila. On Sunday,

Re: keep getting an error on there is no module

2019-01-13 Thread Nebojsa Hajdukovic
when you get this error, when want to run the server? do you have any models inside of that app? нед, 13. јан 2019. у 16:28 Saeed Pooladzadeh је написао/ла: > :In my Django project while I have made an app named employee. And have > registered it in my apps but I keep getting this error: > > No

Re: Django-error about files

2019-01-13 Thread Nebojsa Hajdukovic
you need to be inside of your project's folder, not users\asus нед, 13. јан 2019. у 20:59 је написао/ла: > Hello, Could you please help me why I cant open manage.py file? You can > find the problem easily through this screen shot below. > > -- > You received this message because you are subscrib

Django-error about files

2019-01-13 Thread tarikkantar25
Hello, Could you please help me why I cant open manage.py file? You can find the problem easily through this screen shot below. -- 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, se

keep getting an error on there is no module

2019-01-13 Thread Saeed Pooladzadeh
:In my Django project while I have made an app named employee. And have registered it in my apps but I keep getting this error: No module named 'employee' Leading to the app not being able to run properly. please inform. -- You received this message because you are subscribed to the Google

Re: Using Django

2019-01-13 Thread Kasper Laudrup
On 13/01/2019 05.36, George Githaiga wrote: I have Django-apps on my root directory.I need to proceed to the environment.Kindly guide. https://stackoverflow.com/help/how-to-ask Kind regards, Kasper Laudrup -- You received this message because you are subscribed to the Google Groups "Django

Using Django

2019-01-13 Thread George Githaiga
I have Django-apps on my root directory.I need to proceed to the environment.Kindly guide. -- 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

Re: Pip installation

2019-01-13 Thread 'Amitesh Sahay' via Django users
Hello Kidwell, Did you receive any message by chance that says " "You are using pip version x.x.x, however version x.x.x is available. You should consider upgrading via the 'python -m pip install --upgrade pip' command""?where x = version of the existing pip version on your machine and the versi