Re: DRF | Django | Up votes | Down Votes

2021-06-24 Thread oba stephen
Hi, One way would be to create an extra field to track the difference in both fields and then in your meta information on that model set the ordering to that field. Another approach which is better is to do something like this. Votes.objects.extra(select={'diff': 'upvote - downvote'}).order_by('

Re: DRF | Django | Up votes | Down Votes

2021-06-24 Thread DJANGO DEVELOPER
Is there anyone who can help me here? On Thu, Jun 24, 2021 at 7:15 PM DJANGO DEVELOPER wrote: > Hi Django experts. > I am building a Django, DRF based mobile app and I want to have > functionality of up votes and down votes for posts that user will post. > So what I want to say here that, if an

Re: Hi django

2021-06-24 Thread DJANGO DEVELOPER
muhammad haris salamat just make a form in your template, then have a name='any name here' and then make a view in which you have to get the name in the following way. query = request.POST.get('any name here') and then do this: value = ModelName.objects.filter(Q(model_field = query) On Thu, Jun 2

Django relationships

2021-06-24 Thread Murad
Hi Django developers, i am new in Python, i want to develop a simple app stock management. can you give me a brief idea how to add device to stock if it hasnt assigned to employee i have below models class Device(models.Model): STATUS = ( ('in use', in use), ('available', 'available') )

Re: Deploy Django app using cpanel

2021-06-24 Thread Kelvin Sajere
Not everyone can afford a VPS. And hosting a django website isn’t at all difficult. I use shared cpanel hosting for hosting django websites often, and it is easy. You just need to do it once and you never have to worry about doing it again. You still have to know how to host on VPS right? Or is it

Re: Diploy django on DigitalOcean

2021-06-24 Thread Kelvin Sajere
I would prefer using a cloud service like AWS or Google cloud service for your media files and host your application with Heroku. On Thu, Jun 24, 2021 at 14:05 Sunday Iyanu Ajayi wrote: > Hi > > You can use this link: > https://simpleisbetterthancomplex.com/tutorial/2016/10/14/how-to-deploy-to-d

Re: Hi django

2021-06-24 Thread muhammad haris salamat
Hi all can u help me plz how I can use filter with Contain query in Django I wanna fetch all data from my database with the help of filter query On Thu, 24 Jun 2021, 9:17 pm Richard Dushime, wrote: > THANK U I HAVE DONE TO FIX IT ITS NOW WORKING > > On Thu, Jun 24, 2021 at 6:04 PM Julio Cojom >

Re: Hi django

2021-06-24 Thread Richard Dushime
THANK U I HAVE DONE TO FIX IT ITS NOW WORKING On Thu, Jun 24, 2021 at 6:04 PM Julio Cojom wrote: > Django framework uses urls to math the html files. This work with the same > syntax of static files, you would use {% url 'app:viewname' %} to render > any page with Django. > > You should check th

Re: Hi django

2021-06-24 Thread Julio Cojom
Django framework uses urls to math the html files. This work with the same syntax of static files, you would use {% url 'app:viewname' %} to render any page with Django. You should check the docs of urls to understand how it works and get this done. Regards El jue., 24 de junio de 2021 9:00 a. m

Hi django

2021-06-24 Thread Richard Dushime
i have a problem on my navigation bar on the index.html link when i click on it its showing me the error (see error.png) or everything apart that its working fine need ur help Home About About Us

In need of urgent help as I've been stuck on this for a while

2021-06-24 Thread Aritra Ray
Hi, This is my second request regarding the same issue. I've been building a Django E-commerce website and I'm facing problems filtering the product according to price. I used django-filter to filter category and size. Please suggest a solution for price in the following manner: Latest products, Lo

How to write a v-if condition for comparing django accessed value "{{cust_package}}" and vue.js "<%radio_price%>"

2021-06-24 Thread Salima Begum
And here I am trying to write if statement and also I have interpolated a value in vue.js like "{{cust_package}}" accessed In django and <%radio_price%> accessed in vue.js for both i am trying to write a if condition like "v-if="radio_price == {{cust_package}}" So this condition is not working so

Re: Diploy django on DigitalOcean

2021-06-24 Thread Sunday Iyanu Ajayi
Hi You can use this link: https://simpleisbetterthancomplex.com/tutorial/2016/10/14/how-to-deploy-to-digital-ocean.html *AJAYI Sunday * (+234) 806 771 5394 *sunnexaj...@gmail.com * On Thu, Jun 24, 2021 at 8:27 AM Eugene TUYIZERE wrote: > Hello Team, > > I need some tutorials and steps to depl

Re: Django

2021-06-24 Thread Théodore KOSSI
thanks you very much Le jeu. 24 juin 2021 à 13:16, Boris Pérez a écrit : > Hi, u need a custom > tag...https://docs.djangoproject.com/en/3.2/howto/custom-template-tags/ > Greetings...Boris > > 2021-06-24 8:01 GMT-04:00, Théodore KOSSI : > > I want also someone who can help me to manipulate my da

Re: Django

2021-06-24 Thread Boris Pérez
Hi, u need a custom tag...https://docs.djangoproject.com/en/3.2/howto/custom-template-tags/ Greetings...Boris 2021-06-24 8:01 GMT-04:00, Théodore KOSSI : > I want also someone who can help me to manipulate my database in django > > > Le jeu. 24 juin 2021 à 13:00, Théodore KOSSI a > écrit : > >> >

Re: Django

2021-06-24 Thread Théodore KOSSI
I want also someone who can help me to manipulate my database in django Le jeu. 24 juin 2021 à 13:00, Théodore KOSSI a écrit : > > > I want to use the function now in my template and i don't know how i > can do > > theodoros17@python-developer > -- theodoros17@python-developer -- You re

Django

2021-06-24 Thread Théodore KOSSI
I want to use the function now in my template and i don't know how i can do theodoros17@python-developer -- 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 djan

Re: Diploy django on DigitalOcean

2021-06-24 Thread Gabriel Akwasi Asare
Don’t forget that heroku doesn’t manage your media files.It deletes them every reboot which is going to cost you your data Digital ocean let’s do all things yourself yeah but it’s worth it You have control to manage your site however you want it On Thu, 24 Jun 2021 at 09:45 Luciano Martins wrote:

Re: Diploy django on DigitalOcean

2021-06-24 Thread Luciano Martins
Good morning...Implementing something on a VPN like Digital Ocean will require you to take care and configure everything, part of security, database, etc, if possible choose Heroku that already delivers the infrastructure ready and you just have to will care about the code...a tip!! Em quinta-f

Re: Diploy django on DigitalOcean

2021-06-24 Thread Gabriel Akwasi Asare
Open the file,it has all you need On Thu, 24 Jun 2021 at 09:08 Antonis Christofides < anto...@antonischristofides.com> wrote: > Hi, > > you can try "Deploying Django on a single Debian or Ubuntu server" at > djangodeployment.com or djangodeployment.readthedocs.io. > > Regards, > > Antonis > > Ant

Re: Diploy django on DigitalOcean

2021-06-24 Thread Antonis Christofides
Hi, you can try "Deploying Django on a single Debian or Ubuntu server" at djangodeployment.com or djangodeployment.readthedocs.io. Regards, Antonis Antonis Christofides +30-6979924665 (mobile) On 24/06/2021 10.20, Eugene TUYIZERE wrote: Hello Team, I need some tutorials and steps to depl

Deploy Django app with Apache2

2021-06-24 Thread tristant
I was looking to turn a a laptop into a standing webserver to deploy a Django app within an intranet. This tutorial here shows how to doing with Apache2: Hands-On How to Host Django with Apache2 | by Muhammad Ryan | Level Up Coding (gitconnected.com)

Diploy django on DigitalOcean

2021-06-24 Thread Eugene TUYIZERE
Hello Team, I need some tutorials and steps to deploy a django app on DigitalOcean. Note that I already have the domain what it remaining is only to host. Thank you -- *Eugene* -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe f