Skip to content
This repository was archived by the owner on Aug 12, 2020. It is now read-only.

Problem with ForeignKey #63

Open
kmvit opened this issue Oct 23, 2016 · 0 comments
Open

Problem with ForeignKey #63

kmvit opened this issue Oct 23, 2016 · 0 comments

Comments

@kmvit
Copy link

kmvit commented Oct 23, 2016

Hello!

How can I connect this model to my model. My model

class Order(models.Model):
title = models.CharField(max_length=200)
born = models.DateTimeField(default=timezone.now)
user = models.ForeignKey(User)
email = models.EmailField()
files = models.ForeignKey(Picture)

I have a form of adding order:
class AddOrderForm(forms.ModelForm):
class Meta:
model = Order
fields = 'all'
widgets = {
'body': TinyMCE(attrs={'cols': 80, 'rows': 20}),
}

How to realize adding files to the order add page ?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant