Anonymous
Any other suggestion?
Rajjix
Your question is very general and non error related, google should have many answers and guides for what you want
Anonymous
Yeah but anybody know any best practice or have expirence with azure can guide me better
Googlom
first_name = models.CharField(_('first name'), max_length=30, blank=True) what does underscore before ('first name') means?
Rajjix
This should give you some understanding of its usage https://docs.djangoproject.com/en/2.1/topics/i18n/translation/
Mirco
first_name = models.CharField(_('first name'), max_length=30, blank=True) what does underscore before ('first name') means?
it's the alias for gettext, used for translations But the read @Rajjix has shared with you is your must read
Googlom
thanks
Mirco
thanks
yw 😁
Anonymous
Hi
Anonymous
Can we make a Django app and embed that web app to another Java webapp?
Jimmies San
😂😂😂😂
Combot
José Luis (0) has increased reputation of Django Bot (1)
El presidente de la grima
Hi everyone, question about django.test: when I use my main db and apply migrations, suit permissions(view/add/update/delete) for models are automaticaly created, but this doesn't work with test db. There are only default permissions in db... I'm using Django 2.1.1
Азатбек
Hi everyone!I have a question
Азатбек
How inside css to specify the path of statistical files
Rajjix
stupid but working solution would be ../../..etc
El presidente de la grima
That's weird
Yep, migrations should be applied :(
Anonymous
Hello, guys. I was wondering how embedding works. I mean how I can take a javascript code from drift. Embed it into my website and I'll start seeing a chat widget on my website. Anyone with an idea? I'm trying to understand this concept. I really don't know the right keywords to search on Google right now. I'm creating something that should work that way.
Anonymous
Hi
Anonymous
Please can you help me upload my django project to fastcomet?
Anonymous
What is the best way to create forms for comments? I want to create a comments and responses form, just as I add by selecting the related model in ForeignKey through Django Admin. But I do not know a way to do this, I was told to encrypt the id of the post and the comment, for the comment and the reply, respectively. Another person recommended me to create a URL pattern for this, but in those two cases would they not be vulnerable? So far, that's all I've got ready: forms.py - https://pastebin.com/6KjBVuQg / models.py - https://pastebin.com/VjTaCDNX / post.html - https://pastebin.com/Pg4D7edn /print: https://imgur.com/a/joKLb5j I do not have a great deal of knowledge in Django, and this is what I want to do, it seems a bit more advanced. Also, is there any way to rename each form that will be passed as context? For I will have two forms, one for comment and another for answer, as you can see in the archives.
R
If so you could just add some kind of validation based on user permissions
R
Anyways, you can also consider using https://django-contrib-comments.readthedocs.io/en/latest/ or some other solution as disqus
R
Additionaly, if you are building a blog and not just doing it for learning, you could also consider using some django based cms such as wagtail, mezzanine or django-cms-framework
CM
Hello guys how can I built an app which send push messages to subscribers
R
Hello guys how can I built an app which send push messages to subscribers
Probably you could do it with celery or django-channels
Combot
Rohan K (0) has increased reputation of Roger (2)
Rohan
Can you lead me to that
http://docs.celeryproject.org/en/latest/userguide/periodic-tasks.html
Combot
Masimpe Chandala (0) has increased reputation of Rohan K (1)
Anonymous
Rajjix
@combot @PulsatingQuasar how to use this cumbot
Rohan
No idea. I am just a pawn on this chessboard
Rohan
BUT, you can PM combot for help, there's inline button as soon as you start service
Manish
why i cant access static files
Manish
from static directory
Manish
i added staticfiles_dir()
Rajjix
STATICFILES_DIRS=os.path.join(BASE_DIR, ‘my_static’)
Rajjix
+ create a folder with the name my_static in the same directory as your manage.py
Rajjix
but for production you’ll need to use STATIC_ROOT to serve them from a specified server
Manish
thanks it fixed
Rajjix
Danilo
hi peoples
Danilo
whats up
Danilo
How can I mek gallery in django admin?
Danilo
make*
Anonymous
Would that comments be public or should be only accessed by some kind of users? And what kind of vulnerability are you worried about? Information disclosure?
I'm doing it to learn. I want to show the comments, but can only comment who is logged in, for that, I already know what to study. But I do not know how to make the form available to be related to the post, and the replys are related to each comment. I want comments like facebook, every comment in relation to your post, and every reply in relation to a comment.
Rajjix
Coding for entrepreneurs sometimes explains topics in a pretty advanced and remarkable way, tho mostly is basic but you’ll find good stuff in there if you explore his courses deeper
Danil
hey guys, how do i link chat model with several user models? which relationship should i use?
Danil
one to many or..?
Mirco
Many to many
Brian
Hi guys, I have a questions. It's not particularly on writing the code but how to go about it. The thing is a common problem , that part where a user accepts terms and conditions. Obviously you'll have a user class and the terms and conditions class. How do I go about the users accepting terms and conditions during the first login?
Brian
The terms can be just some Boolean fields on your user class
That works, till you want the user to accept terms and conditions then other terms like a privacy policy or something else like a waiver on top of it.. I thought a more scalable solution would be to have a different class for all these policies. How to keep track of the terms a particular user agreed to eg. Privacy policy, and waiver but they ignore the terms and conditions
Brian
And so on ..
Brian
Makes sense?
Brian
In that case you r right. That way you can even get some analytics data about the user terms and etc
Yes.. I'm thinking of having a different object to keep track of the user and the terms they agreed to. I'm a little short handed when it comes to designing such functionality
Danilo
How can I mek gallery in django admin?
I find one solution for my problem, lol, very good. Upload Multiples Images in Django Admin https://blog.rousek.name/2017/08/11/uploading-multiple-files-in-django-admin/
-
Good morning to everyone. Have someone used graphql subscription with django-channels 2? I cant find up to date info about it. Help, please.
Danil
GM everyone, so i have a problem.
Danil
that's my view
Danil
and i got this error when post a message
Danil
Cannot assign "1": "Message.chat" must be a "Chat" instance.
Danil
What am i supposed to do?
ʚɞÇherry Łoveʚɞ
What am i supposed to do?
change chat=chat_id to chat_id=chat_id
Danil
big thx to you
ʚɞÇherry Łoveʚɞ
big thx to you
U r welcome, and we on afternoon, btw.