Ok, I guess, I will try that. Thank you!!!
On Tue, Nov 5, 2013 at 10:40 PM, Gonzalo Delgado wrote:
> -BEGIN PGP SIGNED MESSAGE-
> Hash: SHA256
>
> El 05/11/13 13:14, Aamu Padi escribió:
> > I think abstract models is what I am after. But, I also want to get
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA256
El 05/11/13 13:14, Aamu Padi escribió:
> I think abstract models is what I am after. But, I also want to get
> the latest photo by that user, be that a profile pic or background
> pic. Can I use the abstract base model, ie the Image model to
>
Hello, Gonzalo! :D
I think abstract models is what I am after. But, I also want to get the
latest photo by that user, be that a profile pic or background pic. Can I
use the abstract base model, ie the Image model to atleast get the latest
photo by [-pub_date], even though I wont save anything in
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA256
El 04/11/13 19:33, Aamu Padi escribió:
> This is my models.py:
>
> class Image(models.Model): user = models.ForeignKey(User) caption =
> models.CharField(max_length=300) image =
> models.ImageField(upload_to=get_upload_file_name) pub_date =
>
What I want is that, each user will have a set of `profile pictures`,
`background images` and other set of `photos uploaded`. These images will
be kept separately in the templates. And if the user wants, he can easily
use (copy) the other set of photos uploaded or images from the background
image
This is my models.py:
class Image(models.Model):
user = models.ForeignKey(User)
caption = models.CharField(max_length=300)
image = models.ImageField(upload_to=get_upload_file_name)
pub_date = models.DateTimeField(default=datetime.now)
class Meta:
6 matches
Mail list logo