Maverick
Check for uniqueness(or put check on data which supposed to be unique)
Maverick
Before adding
Anders (izzno / gooood) 🇳🇴
O M G
Maverick
Like if not data == yourData.fieldNameForData:
_add_data()
Anders (izzno / gooood) 🇳🇴
Pastebin people
Anders (izzno / gooood) 🇳🇴
Yes.
Maverick
Cool will remember that
Anders (izzno / gooood) 🇳🇴
Many reasons not to, copying and pasting it from here will be wrong, refering to lines impossible, the sheer amount of lines etc.
Manish
@solletravinder I tried in models.py by adding unique=True but raised again some more error
Maverick
Maverick
Not in models.py
Maverick
Manish
can you please help me with the condition code part.
Maverick
Maverick
Maverick
Maverick
Ariel
Meba
Ariel
Trying to trigger call_command to run unitest from a view
Ariel
call_command('test')
Kumar
django.db.utils.OperationalError: (2003, "Can't connect to MySQL server on '72.stockone.in' (110)")
Kumar
I am facing these
Kumar
Can any one help on this
mojo
Doesn't media folder get uploaded when we upload our project?
mojo
I have uploaded my project on heroku and it is deleting my images after sometime.
Tukhtamurod
Tukhtamurod
mojo
Can we save images on heroku or do we need to set an account on aws?
Milan
Unless maybe the images are part of the source code
mojo
Milan
Check out the documentation for django-storages for the list of all possible providers and how to configure them
mojo
Anas
Any of you guys have done chained drop down leads to page application in Django
Roman
Is there faster way to do this query ?
models = Model.objects.all().iterator()
for i in models:
i.new_date = parse_date(i.date)
i.save()
Shubham
I have created an API
Shubham
class ListMenu(viewsets.ModelViewSet):
serializer_class = MenuOfTheDaySerializer
b = MenuOfTheDay
# queryset = [(MenuOfTheDay.objects.filter(days=i[0]).values('menu_name'))
# for i in b.DAYS_OF_WEEK]
# queryset = MenuOfTheDay.objects.all()
l = [i[1] for i in b.DAYS_OF_WEEK]
print(l)
# queryset = MenuOfTheDay.objects.filter(days__in=l).values('menu_name')
queryset = MenuOfTheDay.objects.filter(
days_in_week__in=l).values('menu_name')
def list(self, request):
return Response(self.queryset.values())
Shubham
when I trying to retreive http://127.0.0.1:8000/list/10/
Shubham
getting result
Shubham
{
"menu_name": "poha",
"days": null,
"meal_type": null
}
Shubham
why null?
Sarang
Publish it on cloud
but i want standalone type offline ... my webapp create json file of some DB value and compare value n all stuff so foe this i want to xonvert my webapp to exe
Niko
Has anyone worked before with ERD diagrams with django/django rest?
Atharva Paliwal
If i am giving user an option to receive email notifications from this 4 options :
Hackerrank
Hackerearth
Codeforces
Codechef
And if user selects one for example hackerrank...
Then how can i store it in my database and schedule the emails for the user?
Anonymous
Anonymous
💋❤️
Anonymous
Hi
Anonymous
Anyone know that how to clean duplicate history from particular model.
Anonymous
Please help me out
Bheeshma
Put unique=true
Anonymous
Where to put ?
Anonymous
history= HistoricalRecords (unique=True)
Anonymous
Through error
The
Hello friends
The
Anyone here good at Django ?
I just need 2minutes
✙Yaroslav
The
M working on one assignment
But m confused how to start
I mean m Learning and then working on it.
But this time m stuck. Just need guidance about from where to start.
I've never used Django.
But used flask few times.
Stump Lowell
Please an any one help me out
Stump Lowell
Am stuck here
Trying to get two apps in my django project
Want to manage users separate
Stump Lowell
Have created my apps and registered properly and have ran the migration
But am getting this error
The
I am supposed to make a quiz app
Where first screen would ask from name
Second and third screen are one question on each page
And when click on finish ,it should display result
And when click on history button,
It should display all quiz history from databse
Stump Lowell
Stump Lowell
Any one to help me out so I share the screenshots privately
Can't share media files herw
Mirco
Anonymous
help in gunicorn
i m trying to deploy a djnago app which aslo have websocket. in local i used to run it using asgi.
how to run it on server and also
how to bind a host ip and port in
.sock file.
8 m. doing exec gunicorn but i need to bind using a server ip and port. cuz localhost wont work for me
Mirco
Anonymous
unicorn?
Anonymous
uvicorn
Anonymous
I stuck at a problem while integrating stripe in Django the error is "Must provide source or customer" here is my views.py code
https://dpaste.org/yUJr
Anonymous
Please check out my YouTube video
https://youtu.be/3kqPZafYOvw
A sub would be incredible
Roman
Hi guys please guide me, how can I change data in serializer before the is_valid check inside the serializer ?
Ariel
Someone has an experience with Celery and Selenium grid?
Root
Hi I have problem in deploying my app my app when running with gunicorn gives 500 when debug is false but runs when debug is true
Root