latest changes incl grocery list

This commit is contained in:
Joren de Graaf
2026-10-22 10:27:11 +02:00
parent c64ebbdf28
commit b018034072
258 changed files with 413 additions and 1 deletions
+13
View File
@@ -489,3 +489,16 @@ class FieldNoteAssociation(models.Model):
if not self._state.adding:
raise ValidationError("Association history is append-only.")
return super().save(*args, **kwargs)
class McpAccessToken(models.Model):
"""Revocable credential for read-only MCP access; never stores the raw token."""
user = models.ForeignKey(settings.AUTH_USER_MODEL, on_delete=models.CASCADE, related_name="boomcast_mcp_tokens")
name = models.CharField(max_length=100)
token_hash = models.CharField(max_length=64, unique=True)
created_at = models.DateTimeField(auto_now_add=True)
revoked_at = models.DateTimeField(null=True, blank=True)
def __str__(self):
return f"{self.user}: {self.name}"