diff --git a/assets/pasted-20260211-144653-0ba3e61f.png b/assets/pasted-20260211-144653-0ba3e61f.png new file mode 100644 index 0000000..5e63e71 Binary files /dev/null and b/assets/pasted-20260211-144653-0ba3e61f.png differ diff --git a/core/__pycache__/models.cpython-311.pyc b/core/__pycache__/models.cpython-311.pyc index b8ccc01..f74068e 100644 Binary files a/core/__pycache__/models.cpython-311.pyc and b/core/__pycache__/models.cpython-311.pyc differ diff --git a/core/models.py b/core/models.py index eacc4a3..c9b2133 100644 --- a/core/models.py +++ b/core/models.py @@ -398,21 +398,15 @@ class SystemSetting(models.Model): favicon = models.FileField(_("Favicon"), upload_to="business_logos/", blank=True, null=True) vat_number = models.CharField(_("VAT Number"), max_length=50, blank=True) registration_number = models.CharField(_("Registration Number"), max_length=50, blank=True) - - # Financial Settings - allow_zero_stock_sales = models.BooleanField(_("Allow selling items with 0 stock"), default=False) - - # Loyalty Settings - loyalty_enabled = models.BooleanField(_("Enable Loyalty System"), default=False) - points_per_currency = models.DecimalField(_("Points Earned per Currency Unit"), max_digits=10, decimal_places=2, default=1.0) - currency_per_point = models.DecimalField(_("Currency Value per Point"), max_digits=10, decimal_places=3, default=0.010) - min_points_to_redeem = models.PositiveIntegerField(_("Minimum Points to Redeem"), default=100) - - # WhatsApp (Wablas) Settings - wablas_enabled = models.BooleanField(_("Enable WhatsApp Gateway"), default=False) - wablas_token = models.CharField(_("Wablas API Token"), max_length=255, blank=True) - wablas_server_url = models.URLField(_("Wablas Server URL"), blank=True, help_text="Example: https://console.wablas.com") - wablas_secret_key = models.CharField(_("Wablas Secret Key"), max_length=255, blank=True) + + class Meta: + permissions = [ + ("view_dashboard", "Can view dashboard"), + ("view_pos", "Can access POS"), + ("view_reports", "Can view reports"), + ("view_accounting", "Can view accounting"), + ("view_hr", "Can view HR"), + ] def __str__(self): return self.business_name