38381-vm/core/models.py
Flatlogic Bot 587ca82ae6 T0
2026-02-12 13:11:59 +00:00

18 lines
817 B
Python

from django.db import models
class InventoryItem(models.Model):
name = models.CharField(max_length=255)
description = models.TextField(blank=True)
cost = models.DecimalField(max_digits=10, decimal_places=2)
installments_options = models.CharField(max_length=255, help_text="e.g., 12 months interest free")
features = models.TextField(help_text="Comma separated features")
store_location = models.CharField(max_length=255)
store_name = models.CharField(max_length=255)
lead_time = models.CharField(max_length=100, help_text="e.g., 3-5 days")
image_url = models.URLField(blank=True, null=True)
created_at = models.DateTimeField(auto_now_add=True)
updated_at = models.DateTimeField(auto_now=True)
def __str__(self):
return f"{self.name} - {self.store_name}"