Hello geeks:
Here is my models:
class Room_Type(models.Model):
"""Django data model Room_Type"""
ROOM_CATEGORIES={
('Elt','Elite'),
('Lux','Luxury'),
('Sig','Signature')
}
image = models.ImageField(upload_to="pics")
roomtype = models.CharField(choices=ROOM_CATEGORIES,max_length=20)
price = models.CharField(blank=True, max_length=100)
def __str__(self):
return f'{self.roomtype}'
I want Id with any one of the detail given in model,Help me solve geeks