às 13:47:55 UTC, Integr@te System
escreveu:
>
> Hi Idea man,
>
> You can acknowlegdes and try it:
>
> https://channels.readthedocs.io/en/latest/
>
>
> On Mon, Nov 4, 2019, 19:11 Daniel Carvalho > wrote:
>
>> Hello!
>>
>>
>> I'm tryi
Hello!
I'm trying to make an example to test if it is possible to have 2
independent django apps connected to the same channel from django-channels.
So far, I was able to make an example running on one machine and 2 other
machines being able to access the first via a client. But the goal is
I think the way to do is:
from django.contrib import messages
then somewhere...
messages.add_message(request, messages.ERROR, "your error message")
The message will be displayed in the top of the next admin page
On 01/03/2011 09:40 PM, Acorn wrote:
> I'd like to know this too.
>
> On 3
On 12/20/2010 12:55 AM, Daniel Carvalho wrote:
> Everybody knows the default django FileField doesn't allow to remove an
> existing file...
>
> This is a good replacement. Just use RemovableFileField instead of
> FileField in your models:
> http://djangosnippets.org/snippets/6
Everybody knows the default django FileField doesn't allow to remove an
existing file...
This is a good replacement. Just use RemovableFileField instead of
FileField in your models:
http://djangosnippets.org/snippets/636/
I want to implement on it another feature- When there is a file being
hi
I have a form with a file upload field.
If the form fails validation, the user has to give all the file fields
another time.
Someone told me it is possible to avoid that but I can't find more
information...
There was a thread about this before:
On 12/06/2010 04:18 PM, Wayne Smith wrote:
> Then yes, in the clean() method of your Galeria form, you could check the
> number of fotos present and then raise a ValidationError if it is too many,
> along with a custom message for the user.
>
> Is that what you wish to do?
>
hi
I think the
On 12/06/2010 03:05 AM, Wayne Smith wrote:
> It's hard to say, because I don't know what kind of "validation" or business
> logic regarding it you are trying to accomplish/employ.
>
suppose I want a validation like this:
the number of fotos in a galeria should be limited to a number, which
hi
I have this models:
models.py:
class Galeria(models.Model):
...
class Foto(models.Model):
...
galeria = models.ForeignKey(Galeria, null=False)
admin.py:
class FotoInline(admin.StackedInline):
model = Foto
class GaleriaAdmin(admin.ModelAdmin):
inlines = [FotoInline,
hi
I have a model that defines a function:
class Test(models.Model):
name = models.CharField(max_length=200)
data_expira = models.DateField()
def expired(self):
return self.data_expira < datetime.date.today()
expired.short_description = 'Expirou?'
I want to put it in
Hi,
I want to define a form with a multi-line textfield.
from django import forms
class TesteForm(forms.Form):
field1 = forms.CharField(
max_length=100,widget=forms.widgets.TextInput())
...
field2 = forms.CharField(
widget=forms.widgets.TextArea(attrs={'cols':
Hi
I have some models where I want objects to be displayed in an arbitrary
order.
For that I have in the model a number field, which is used to sort.
class MyModel:
...
class Meta:
ordering = ["orderfield"]
It would be cool if instead of editing this field, I have a "go up" and
"go down"
12 matches
Mail list logo