Answer the question
In order to leave comments, you need to log in
How to choose an artist in django?
Hello. Now I'm doing a simple freelance exchange. There are users (customers, freelancers), there are projects. On the project page, you need to make, as on all exchanges, the ability to respond to the project and the ability for the customer to select a responding freelancer. How to organize it correctly? I guess it is necessary to create a response model like this:
class Otclic(models.Model):
user=models.ForeignKey(User)
project = models.ForeignKey(Project)
body = models.TextField()
active = models.BooleanField(default=False)
Answer the question
In order to leave comments, you need to log in
First, don't use transliteration in your code. This is very bad.
The second - Project - contains FK on User (executor, for example), in which we write the selected executor (there will be one executor for the project?), Otclic - a completely logical structure in the first approximation. Accordingly, the customer looks at all Responses to his project and chooses one. user from this Otclic is written to project.executor. Basically everything. That is, if you shorten the answer, then you are doing everything right
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question