Sarat
Hello guys ,   Can we create another admin panel in django?? (With out using django adminstration)
Sarat
Why would you do that ?
Because i wanna build a eCommerce website as client asked for admin panel
Alex
Because i wanna build a eCommerce website as client asked for admin panel
Use theme and customization instead of building from scratch
Charly
Use theme and customization instead of building from scratch
You don't know the needs to recommend that.
Alex
can anyone tell me how i can get started with exposing a simple django app using nginx ?
🗽
Hey guys, I have a question, I have a Group model and it has is_full=models.BooleanFiled(default=False) field, and I have a Student model, my student model has field groups=models.ManyToManyField(Group, related_name='students') I am trying to update is_full=False to True, when group model has more than let's say 5 students. How can I do it? I tried using signals but I could not solve the issue. Or is my the whole implementation is wrong here?
Otabek
Hey guys, I have a question, I have a Group model and it has is_full=models.BooleanFiled(default=False) field, and I have a Student model, my student model has field groups=models.ManyToManyField(Group, related_name='students') I am trying to update is_full=False to True, when group model has more than let's say 5 students. How can I do it? I tried using signals but I could not solve the issue. Or is my the whole implementation is wrong here?
from django.contrib.auth.decorators import login_required @login_required(login_url='/example url you want redirect/') def join_group_view(request, joined_group_id): student = Student.objects.get(id=request.user.id) group = Group.objects.get(id=joined_group_id) student.groups.add(group) if len(student.groups.all()) >= 5: student.is_full = True return redirect("somewhere")
ERMIA
Rishabh
How to add SsL to Django server and api hosted over aws
Rishabh
ec2
Doragonsureiyā
How to add SsL to Django server and api hosted over aws
Adding the word Django to your Off-Topic question doesn't magically turn it to a Django related question, so move to @PythonOfftopic group and ask there.
Maleficent
is this possible that without creating super user can i create a customize admin
refleks1a
is there any good article about using django + react?
Mirco
is there any good article about using django + react?
If you are solo developer, consider using htmx instead of react Otherwise the best way is to separate projects and use DRF ( rest framework ) and React separately
Maleficent
admin panel
Ravikumar
i need help, i have two fields in the model 1) one is urlFeild and second one is FileFeild , if i add the urlfeild and save i need to add fileupload with same url link file
Ravikumar
url_field = models.URLField() file_field = models.FileField(upload_to='files/', null=True, blank=True)
Ravikumar
when i add url_field and same file save in file_field
ashu
So what your problem tha data is not save or anything extra?
Ravikumar
i want just add the urlfeild and the urlcontaing file auto save to the filefield
Laxmi
How can i encode base64 image into a string format using local system image and display to the front end using this encoded string
Abhijit
I am stuck in one project I am getting error SSL:UNSAFE_LEGACY_RENEGOTIATION_DISABLED My getting this for sending a mail to somebody
Rishabh
Django backend, is it important to connect it to domain name
Abhijit
Rishabh how I can u explain me in detail pls
Asaf
Hello guys, What is the best way for HTTP injections, If the user press button, the HTML will change
Sourav
I can make network device monitoring project any one help me?
Doragonsureiyā
I can make network device monitoring project any one help me?
No one can help you until you explain your difficulties.
Sourav
No one can help you until you explain your difficulties.
I can Monitoring OLT, Optical Fiber, Mikrotik And other Device
Sourav
OK!
I am waiting
Doragonsureiyā
I am waiting
No one can help you until you explain your difficulties.
Sourav
No one can help you until you explain your difficulties.
OLT : ## Power Check ## On Off System Optical Fiber : ## Fiber Length ## Fiber Connect Disconnect information ## Fiber Disconnect information Mikrotik : ## Mikrotik Power ## Mikrotik CPU ## Mikrotik User Information ## Mikrotik Client
Lords
Hello everyone, I am looking to build a search engine with angular and rest framework if any one have idea How the flow will movie please let me know if any documentation is there please share it is useful for me Thankyou for your valuable time
Abhinand
Hello i have a domain and i have hosted my project in aws. How to change ip address to domain name
Doragonsureiyā
Hello i have a domain and i have hosted my project in aws. How to change ip address to domain name
Your question is not related to Django. If it's a Python related question go to @Python group, otherwise please move to @PythonOfftopic group and ask there.
E r
Gentlemen. Greetings to all. I have a question: I have a model for 70+ fields and, depending on a pair of fields, I would like to display the remaining fields for each combination for searching. What is the easiest way to organize this?
E r
Gentlemen. Greetings to all. I have a question: I have a model for 70+ fields and, depending on a pair of fields, I would like to display the remaining fields for each combination for searching. What is the easiest way to organize this?
I apologize. I didn’t ask correctly, and that’s not really what I meant. To the point. There is a project for a real estate website There, in the search, you need to organize it so that, depending on the selection, additional search criteria appear or disappear. Type selected a property type house and a search also appeared by area Is it possible to organize this without prescribing a different form for each pair by type ("rent" "apartment")?
Georg
there is no way to make a JOIN query with two tables without FK, right?
Georg
but with no "extra" methods...
Georg
because I have two models with similar pairs of fields but no FK between
Georg
or is there any way to make FK by couple of fields?
Charly
or is there any way to make FK by couple of fields?
What do you mean by a couple of fields?
Charly
Show your models and how you want to query them
Georg
class Plan(BasePPModel): amount = MoneyField() count = models.FloatField(null=True) service = models.ForeignKey(Service, on_delete=models.CASCADE, related_name='plan') date = models.DateField(null=True) class Meta: unique_together = ( ('service', 'date'), ) class Billing(BasePPModel): amount = MoneyField() count = models.FloatField(null=True) service = models.ForeignKey(Service, on_delete=models.CASCADE, related_name='billing') date = models.DateField(null=True) class Meta: unique_together = ( ('service', 'date'), ) I need to join it by service and date
Georg
wow! a syntax highlighting??
Georg
I made a query using Subquery class, but it make a subquery (select in select). That is not effective
Georg
wanna JOIN
Georg
What do you mean by a couple of fields?
maybe I can make Foreign key at last?
Charly
Why you have that dadta duplication?
Georg
These are the same models
yep. They are very similar
Georg
I cut them before shared
Charly
yep. They are very similar
There are the same
Georg
ok. I need that. because a data is different
Charly
ok. I need that. because a data is different
No is dupplicated. at least opartially you should have only the data that is different. but regardless of that why don't you just add a fk?
Georg
ok. What's the way to create it by two fields?
Muflone
but with no "extra" methods...
No fk, no extra, no raw query too?
Georg
No fk, no extra, no raw query too?
don't think) I love SQL, but the project has restrictions
Georg
Why two fields?
date + service
Charly
date + service
Why not just service and have the date on the service?
Charly
FK of two fields makes no sense
Charly
you have ids
Charly
I catually I dont know how you want to do relations in these models
Georg
service is a long life entity, bililng is a daily amount