accrete 0.0.155__py3-none-any.whl → 0.0.156__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,21 +1,6 @@
1
- import django.apps
2
1
  from django.contrib import admin
3
- from django import forms
4
2
  from . import models
5
3
 
6
- installed_models = django.apps.apps.get_models(
7
- include_auto_created=True, include_swapped=True
8
- )
9
- model_choices = [(
10
- f'{m._meta.app_label}.{m._meta.model_name}',
11
- f'{m._meta.app_label}.{m._meta.verbose_name}'
12
- ) for m in installed_models]
13
-
14
-
15
- class LogConfigForm(forms.ModelForm):
16
-
17
- model = forms.ChoiceField(choices=model_choices)
18
-
19
4
 
20
5
  class LogConfigFieldInLine(admin.TabularInline):
21
6
 
@@ -28,7 +13,6 @@ class LogConfigAdmin(admin.ModelAdmin):
28
13
  list_display = ('model', 'ignore_errors', 'exclude_fields')
29
14
  search_fields = ('pk', 'model')
30
15
  list_filter = ['ignore_errors', 'exclude_fields']
31
- form = LogConfigForm
32
16
  inlines = [LogConfigFieldInLine]
33
17
 
34
18
 
@@ -0,0 +1,24 @@
1
+ # Generated by Django 5.2.7 on 2025-10-05 21:45
2
+
3
+ from django.conf import settings
4
+ from django.db import migrations, models
5
+
6
+
7
+ class Migration(migrations.Migration):
8
+
9
+ dependencies = [
10
+ ('accrete', '0010_alter_accessgroup_description'),
11
+ ('log', '0005_logconfig_exclude_fields_and_more'),
12
+ migrations.swappable_dependency(settings.AUTH_USER_MODEL),
13
+ ]
14
+
15
+ operations = [
16
+ migrations.RemoveIndex(
17
+ model_name='log',
18
+ name='accrete_log_model_cf888c_idx',
19
+ ),
20
+ migrations.AddIndex(
21
+ model_name='log',
22
+ index=models.Index(fields=['model', 'object_id', 'tenant_id'], name='accrete_log_model_22d992_idx'),
23
+ ),
24
+ ]
@@ -5,6 +5,8 @@ from django.conf import settings
5
5
  from django.db.models.functions import Lower
6
6
  from django.utils.translation import gettext_lazy as _
7
7
  from django.db import models
8
+ import logging
9
+ _logger = logging.getLogger(__name__)
8
10
 
9
11
 
10
12
  class Log(models.Model):
@@ -14,7 +16,7 @@ class Log(models.Model):
14
16
  verbose_name_plural = _('Logs')
15
17
  db_table = 'accrete_log'
16
18
  indexes = [
17
- models.Index(fields=['model', 'object_id'])
19
+ models.Index(fields=['model', 'object_id', 'tenant_id'])
18
20
  ]
19
21
  constraints = [
20
22
  models.UniqueConstraint(
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: accrete
3
- Version: 0.0.155
3
+ Version: 0.0.156
4
4
  Summary: Django Shared Schema Multi Tenant
5
5
  Author-email: Benedikt Jilek <benedikt.jilek@pm.me>
6
6
  License: Copyright (c) 2025 Benedikt Jilek
@@ -25,11 +25,11 @@ accrete/contrib/country/migrations/0002_auto_20250219_1759.py,sha256=hSP0WEErHHJ
25
25
  accrete/contrib/country/migrations/0003_alter_country_options.py,sha256=0reOOdHuApMA5pw4ga6BW63TCG2U1i8T8oSug7EjUXw,428
26
26
  accrete/contrib/country/migrations/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
27
27
  accrete/contrib/log/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
28
- accrete/contrib/log/admin.py,sha256=g-wdWF2O62rR0e_rLSgof_z8m42Qqv5VBrl_sFB0qlo,1212
28
+ accrete/contrib/log/admin.py,sha256=iUNGFJJLFlCxvampt-LYDOrMu_fffNY2Vo4m1m5aQlM,799
29
29
  accrete/contrib/log/apps.py,sha256=O0Cje3MmpxPToJVgO195lBg0tRCy9Ou87-ntcdGBKM0,369
30
30
  accrete/contrib/log/config.py,sha256=vRzPVbiUfpo5NGtgiJv5mEKR_h3qsYI_brxjni6-Z-Y,132
31
31
  accrete/contrib/log/helper.py,sha256=n5QXPf4Lo8NvxDaJifZs4QVNJdiNyr17e_z26QT9V-U,2514
32
- accrete/contrib/log/models.py,sha256=XRElQUV6Obj4BCMTXE85jcpEup7m-MCRVfquxmt9_Xc,6210
32
+ accrete/contrib/log/models.py,sha256=bNhfYgz8czZNGDroOA-xvuM-Ad96gQ1C1475EIWPtFg,6276
33
33
  accrete/contrib/log/queries.py,sha256=IsdzgcKkCeKE8pOa7zOFuaHcJUGG0wyr8EG1CrRrZRw,1189
34
34
  accrete/contrib/log/signals.py,sha256=q4ZjAoPBCWXnn--a42J9NKzU3cfadjNBdjoGcBLjfus,2147
35
35
  accrete/contrib/log/tests.py,sha256=mrbGGRNg5jwbTJtWWa7zSKdDyeB4vmgZCRc2nk6VY-g,60
@@ -39,6 +39,7 @@ accrete/contrib/log/migrations/0002_log_user_alter_log_new_value_type_and_more.p
39
39
  accrete/contrib/log/migrations/0003_alter_log_tenant.py,sha256=yp3WizRdAPvPctMiCmKcsqVix3a0LaIRmuAB6LJ6Gb0,582
40
40
  accrete/contrib/log/migrations/0004_logconfig_logconfigfield.py,sha256=iXD3kDj8GAD5Dce9xVozl0n8KCQaK4LsQkLHR3BDZ28,2367
41
41
  accrete/contrib/log/migrations/0005_logconfig_exclude_fields_and_more.py,sha256=eN0AG2vR80-9NvMBfijjM04qPfRGxO7B8VFabrEZ_ZQ,1127
42
+ accrete/contrib/log/migrations/0006_remove_log_accrete_log_model_cf888c_idx_and_more.py,sha256=K4gA_MrunNpKdvMZFq7CDsAQvnRqBiHspHlgI1ZYO6M,708
42
43
  accrete/contrib/log/migrations/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
43
44
  accrete/contrib/sequence/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
44
45
  accrete/contrib/sequence/admin.py,sha256=mTjab5cVklRUIQcSrsUo-_JgtXEsSdcFj_gfWhlStS4,273
@@ -294,7 +295,7 @@ accrete/utils/forms.py,sha256=naV4urdfvmpxcx5Vf3Fo72M5Fy8DjGg5-vkysMKptbA,3914
294
295
  accrete/utils/log.py,sha256=BH0MBDweAjx30wGBO4F3sFhbgkSoEs7T1lLLjlYZNnA,407
295
296
  accrete/utils/models.py,sha256=0uDhiWl7G2MDnbdYcAdKaIArw-NFMSwRArCcZ0FrZSk,1509
296
297
  accrete/utils/views.py,sha256=LE9pZ1x9f7ioaPYydbrN4t1b0o6NIIq0qUjPTb1Qkbw,5022
297
- accrete-0.0.155.dist-info/METADATA,sha256=OUKsvr4vjzDsiJwQJzvD_sDEV8PpssCVmhgFCYEbWKM,4953
298
- accrete-0.0.155.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
299
- accrete-0.0.155.dist-info/licenses/LICENSE,sha256=vHwb4Qnv8UfYKFiCWyTuRGsi49x19UQwHRCky3b2_NE,1057
300
- accrete-0.0.155.dist-info/RECORD,,
298
+ accrete-0.0.156.dist-info/METADATA,sha256=z9JgzV9JvLMWct6-DAXIuoBqTW0K11cYAnq6SuY_V_g,4953
299
+ accrete-0.0.156.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
300
+ accrete-0.0.156.dist-info/licenses/LICENSE,sha256=vHwb4Qnv8UfYKFiCWyTuRGsi49x19UQwHRCky3b2_NE,1057
301
+ accrete-0.0.156.dist-info/RECORD,,