Re: hi friends am sending how to create a project in django with step by step. if you are satisfied please send me comments

2018-09-25 Thread Vineet Kothari
Thanks it is quite useful for coming out of drak sublime On Tue 25 Sep, 2018, 11:16 PM Sudha Mohan, wrote: > > -- > 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 > emai

Re: Starting a New Project somewhat like multitenant saas appication.

2018-09-25 Thread Scot Hacker
It's a little tough to understand what your actual questions are, but: > the role-based authentication I can do but is there any other better option or thing available? The native Django permissions system is limited to specifying who can see or edit particular models (and even then, is limited

Re: No module named "newsimage" app

2018-09-25 Thread Melissa Malala
Thank you all very much, I made the migration and the app works fine. On Tuesday, 25 September 2018 14:06:11 UTC+3, Melissa Malala wrote: > > My project is giving me an error called "No Module named "newsimage" app > (2 Screenshots attached) whenever I run the server using: > python3.6 manage.p

Re: hi friends am sending how to create a project in django with step by step. if you are satisfied please send me comments

2018-09-25 Thread Dheeraj Kumar
Sudha, Its very helpful for us. Thanks so much. Grace, I didn't get what u add in this. On Tue 25 Sep, 2018, 11:40 PM Gear Crew, wrote: > nice man the awesome pdf but I want to add more about urls , views, and > link with model > > On Tuesday, 25 September 2018 19:48:12 UTC+2, Sudha Mohan wro

Re: Using a custom user model extended from AbstractBaseUser, the user object is lose between requests

2018-09-25 Thread L
As an additional detail - This product unfortunately has to use an existing database, which means no django migrations, which means all ORM has to be done manually. This is why the user model isn't capable of saving back to the DB, and why I'm going through this whole convoluted setup. -- You

Using a custom user model extended from AbstractBaseUser, the user object is lose between requests

2018-09-25 Thread L
I'm using a custom user model that extends `AbstractBaseUser`. This is the user model: class cUser(AbstractBaseUser): def save(self, *args, **kwargs): pass role_id = models.IntegerField() user_id = models.IntegerField() email = models.CharField(max_length=40) password

Re: Allow a limit_choices_to callable to accept the current model instances object

2018-09-25 Thread Tim Graham
There's a ticket with that feature request: https://code.djangoproject.com/ticket/25306 On Tuesday, September 25, 2018 at 6:25:38 PM UTC-4, Ochui Princewill wrote: > > Hello, > > Am current working on a project and i want to filter the content of a > ForeignkeyField base on the current model ob

Re: DEFAULT_FILE_STORAGE and tests

2018-09-25 Thread luca bocchi
Il giorno giovedì 20 settembre 2018 15:25:23 UTC+2, sandro dentella ha scritto: > > Hi, > > I have a storage that create some thumbnail and is declared in some > models' fields. It's created inheriting from DEFAULT_FILE_STORAGE and it > just works fine both in FileSystemStorage and in Aws. >

Re: My django model joining wrong fields when there are multiple related fields with join

2018-09-25 Thread luca bocchi
Hi Sadaf, re the m2m rel: since your not adding additional fields on the intermediate model ProductShadowCategory, there's no need for that: class Category(SlugableModel): shadow_products = models.ManyToManyField("product_management.Product") the orm will automatically create an intermediate

Re: My django model joining wrong fields when there are multiple related fields with join

2018-09-25 Thread luca bocchi
Hi Sadaf, re the m2m rel: since your not adding additional fields on the intermediate model ProductShadowCategory, there's no need for that: class Category(SlugableModel): shadow_products = models.ManyToManyField("product_management.Product") the orm will automatically create an intermediate

Re: DEFAULT_FILE_STORAGE and tests

2018-09-25 Thread luca bocchi
already tried: class GeneraliDiscoverRunner(DiscoverRunner): def setup_test_environment(self, **kwargs): settings.DEFAULT_FILE_STORAGE = 'web.storage.TestStorage' super().setup_test_environment(**kwargs) ? although I'm not sure that settings can be changed at runtime by that.

[no subject]

2018-09-25 Thread Luca
-- 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 django-users@googlegroups.com. V

Allow a limit_choices_to callable to accept the current model instances object

2018-09-25 Thread Ochui Princewill
Hello, Am current working on a project and i want to filter the content of a ForeignkeyField base on the current model object class Subscription(models.Model): user = models.ForeignKey(settings.AUTH_USER_MODEL, on_delete=models.CASCADE) plan = models.ForeignKey(Plan, on_delete=models.CASCADE) e

SQL MIGRATION

2018-09-25 Thread Afoakwa Stephen
Am getting this error when moving from mysqli to mysql databases django.core.exceptions.ImproperlyConfigured: Error loading MySQLdb module. Did you install mysqlclient? -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this gro

Re: DEFAULT_FILE_STORAGE and tests

2018-09-25 Thread luca bocchi
Already tried with: class GeneraliDiscoverRunner(DiscoverRunner): def setup_test_environment(self, **kwargs): settings.DEFAULT_FILE_STORAGE = 'web.storage.TestStorage' super().setup_test_environment(**kwargs) ? otherwise, I'd say to run the test with a custom settings module

Re: hi friends am sending how to create a project in django with step by step. if you are satisfied please send me comments

2018-09-25 Thread suneel singh
Wow , it is very helpful On Tue, 25 Sep 2018, 11:40 p.m. Gear Crew, wrote: > nice man the awesome pdf but I want to add more about urls , views, and > link with model > > On Tuesday, 25 September 2018 19:48:12 UTC+2, Sudha Mohan wrote: >> >> >> -- > You received this message because you are subs

Re: django ORM with asyncio

2018-09-25 Thread luke lukes
Hi Andrew, thanks for your reply, well to be honest I'm a bit surprised / honored to get the answer directly from the creator of South. Anyhow, aiopg is not the only option, I noticed that there are also asyncpg and aiopg8000. My question is:

rest api is installed but does not run

2018-09-25 Thread Tim Vogt (Tim Vogt)
Hoi we had a django project and we have pipenv and django installed and django rest when running python manage.py django keept telling the rest is not installed. any tips? we have django_rest in installed apps.. tim -- You received this message because you are subscribed to the Googl

Re: hi friends am sending how to create a project in django with step by step. if you are satisfied please send me comments

2018-09-25 Thread Gear Crew
nice man the awesome pdf but I want to add more about urls , views, and link with model On Tuesday, 25 September 2018 19:48:12 UTC+2, Sudha Mohan wrote: > > > -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and

Re: No module named "newsimage" app

2018-09-25 Thread Okware Aldo
Hi Mellisa, are you using the module/app 'newsimage' in some part of your application? first make changes to install apps section as Vinod Kumar suggested, then make sure whenever you make reference to the app its imported. On Tue, Sep 25, 2018 at 2:19 PM 'Vinod Kumar' via Django users < django

Re: Change settings value during run-time in migrations

2018-09-25 Thread Jason
You can't do it this way, unfortunately. I would suggest you use https://github.com/jazzband/django-constance instead -- 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 ema

Re: No module named "newsimage" app

2018-09-25 Thread 'Vinod Kumar' via Django users
add app name after default dajngo.contrib . In your case INSTALLED_APPS will look like INSTALLED_APPS = [ 'django.contrib.admin', 'django.contrib.auth', 'django.contrib.contenttypes', 'django.contrib.sessions', 'django.contrib.messages', 'django.contrib.staticfiles', #

Starting a New Project somewhat like multitenant saas appication.

2018-09-25 Thread Devender Kumar
Hello, I am Dev just two step ahead of a beginner(recently started to code in Django). I want to develop an application seeking for some thoughts(help/ favors/ etc) from you guys. The application fundamental is like Hierarchy is like At top soft engg. team (me) > partners> client> location> devi

Re: No module named "newsimage" app

2018-09-25 Thread Tatenda Marshall
Did you run any migrations "The world is just for a moment so make it a moment of obedience" On Tue, Sep 25, 2018 at 1:05 PM Melissa Malala wrote: > My project is giving me an error called "No Module named "newsimage" app > (2 Screenshots attached) whenever I run the server using: > python3.6

Change settings value during run-time in migrations

2018-09-25 Thread Ajay Tripathi
Hi, I am trying to change a value in `settings.py` during run-time while creating migrations. **settings.py:** ... magicVar = "initValue" **0002_init:** ... def change_magicVar(apps, schema_editor): settings.magicVar = "newValue" ... operations = [

Re: When I click on submit button on login page, its redirecting to an random csrf token page in django

2018-09-25 Thread Srinivas Gadi
It was clarified that I suppose to the method instead of action in HTML form. On Mon, Sep 24, 2018 at 7:05 PM Nelson Varela wrote: > Do you have 'django.middleware.csrf.CsrfViewMiddleware' in your list of > middlewares in your settings? > > On Monday, September 24, 2018 at 2:52:33 PM UTC+2, S