1

I am trying to implement a MPTT tree such that

Degree (Bachelor,Masters,PhD,Diploma)
- Degree_Name (B.tech,B.A,.....M.tech....)
--Course_Specialization (Civil,Mechanical,...........Eng,.....etc..)

and I have a model

  class Entity(models.Model):
    name = models.CharField(
        max_length=256,
        verbose_name="Entity Name"
    )

    def __str__(self):
        return self.name

And Course_Specialization are saved as entities in Entity table.

Is there a way of dong this i.e the MPTT tree fetches Course_Specialization values from Entity table

I can't convert Entity table as a node of MPTT tree as it has other values as well.

Andrew
  • 8,322
  • 2
  • 47
  • 70
Jack
  • 222
  • 2
  • 12

0 Answers0