The solution I have found is overriding the save function from the model
class:
class FileUpload(models.Model):
owner = models.CharField(max_length=200,blank=False, null=False)
record = models.FileField(upload_to=path_and_rename)
def save(self, force_insert=False, force_update=False, *args, **kw
Hi,
Is it possible to mark a FileField in my model as required
My model looks like :
class FileUpload(models.Model):
owner = models.CharField(max_length=200,blank=False, null=False)
record = models.FileField(upload_to=path_and_rename,blank=False, null=False)
1st statement :
According to what i h
2 matches
Mail list logo