django-camomilla-cms 5.8.4__py2.py3-none-any.whl → 5.8.6__py2.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.
camomilla/__init__.py CHANGED
@@ -1,4 +1,4 @@
1
- __version__ = "5.8.4"
1
+ __version__ = "5.8.6"
2
2
 
3
3
 
4
4
  def get_core_apps():
@@ -15,9 +15,10 @@ class RelatedField(serializers.PrimaryKeyRelatedField):
15
15
  ), 'Class {serializer_class} missing "Meta.model" attribute'.format(
16
16
  serializer_class=self.serializer.__class__.__name__
17
17
  )
18
- kwargs["queryset"] = kwargs.get(
19
- "queryset", self.serializer.Meta.model.objects.all()
20
- )
18
+ if not kwargs.get("read_only", False):
19
+ kwargs["queryset"] = kwargs.get(
20
+ "queryset", self.serializer.Meta.model.objects.all()
21
+ )
21
22
  self.allow_insert = kwargs.pop("allow_insert", False)
22
23
  # kwargs["allow_null"] = kwargs.get("allow_null", self.serializer.Meta.model._meta.get_field(self.source).null)
23
24
  super().__init__(**kwargs)
@@ -135,12 +135,17 @@ DEFAULT_NESTING_DEPTH = getattr(settings, "CAMOMILLA_DRF_NESTING_DEPTH", 10)
135
135
 
136
136
 
137
137
  class NestMixin:
138
+ def __init__(self, *args, **kwargs):
139
+ self._depth = kwargs.pop("depth", None)
140
+ return super().__init__(*args, **kwargs)
141
+
138
142
  def build_nested_field(self, field_name, relation_info, nested_depth):
139
143
  return self.build_relational_field(field_name, relation_info, nested_depth)
140
144
 
141
145
  def build_relational_field(
142
146
  self, field_name, relation_info, nested_depth=DEFAULT_NESTING_DEPTH + 1
143
147
  ):
148
+ nested_depth = nested_depth if self._depth is None else self._depth
144
149
  field_class, field_kwargs = super().build_relational_field(
145
150
  field_name, relation_info
146
151
  )
@@ -1 +1 @@
1
- __version__ = "5.8.4"
1
+ __version__ = "5.8.6"
@@ -1,28 +1,29 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: django-camomilla-cms
3
- Version: 5.8.4
3
+ Version: 5.8.6
4
4
  Summary: Django powered cms
5
- Home-page: https://github.com/lotrekagency/camomilla
6
- Author: Lotrèk
7
- Author-email: dimmitutto@lotrek.it
5
+ Author-email: Lotrèk <dimmitutto@lotrek.it>
8
6
  License: MIT
7
+ Project-URL: Homepage, https://github.com/lotrekagency/camomilla
9
8
  Keywords: cms,django,api cms
10
9
  Classifier: Environment :: Web Environment
11
10
  Classifier: Framework :: Django
12
11
  Classifier: Intended Audience :: Developers
13
12
  Classifier: Programming Language :: Python
14
13
  Classifier: Programming Language :: Python :: 3
15
- Requires-Python: >=3.0.*
14
+ Requires-Python: >=3.6
16
15
  Description-Content-Type: text/markdown
17
16
  License-File: LICENSE
18
- Requires-Dist: lotrek-django-hvad (>=2.0.6)
19
- Requires-Dist: djsuperadmin (<1.0.0,>=0.9)
20
- Requires-Dist: djangorestframework (>=3.10.0<4.0.0)
21
- Requires-Dist: djlotrek (<1.0.0,>=0.1.6)
22
- Requires-Dist: Pillow (<7.0.0,>=6.2.0)
23
- Requires-Dist: django-ckeditor (<7.0.0,>=5.7.1)
24
- Requires-Dist: python-magic (>=0.4<0.5)
25
- Requires-Dist: Django (>=1.8)
17
+ Requires-Dist: django-modeltranslation ~=0.18.11
18
+ Requires-Dist: djsuperadmin <1.0.0,>=0.9
19
+ Requires-Dist: djangorestframework <4.0.0,>=3.10.0
20
+ Requires-Dist: django-admin-interface <1.0.0,>=0.26.0
21
+ Requires-Dist: Pillow <10.0.0,>=6.2.0
22
+ Requires-Dist: django-ckeditor <7.0.0,>=5.7.1
23
+ Requires-Dist: python-magic <0.5,>=0.4
24
+ Requires-Dist: django-jsonform ~=2.19.0
25
+ Requires-Dist: Django >=3.2
26
+ Requires-Dist: pydantic ~=2.2.1
26
27
 
27
28
  # camomilla cms [![PyPI](https://img.shields.io/pypi/v/django-camomilla-cms?style=flat-square)](https://pypi.org/project/django-camomilla-cms) ![Codecov](https://img.shields.io/codecov/c/github/lotrekagency/camomilla?style=flat-square) ![GitHub Workflow Status](https://img.shields.io/github/workflow/status/lotrekagency/camomilla/Test,%20Coverage%20and%20Release?style=flat-square) [![GitHub](https://img.shields.io/github/license/lotrekagency/camomilla?style=flat-square)](./LICENSE)
28
29
 
@@ -1,4 +1,4 @@
1
- camomilla/__init__.py,sha256=Ntb8Zwr_Uy-D_d43UepfaNmYitdZSBwXhf6EFBS-a6M,111
1
+ camomilla/__init__.py,sha256=k1-GObBobIj2TldBFhBg64YvyTTeibDp4hatpMcu7vU,111
2
2
  camomilla/admin.py,sha256=FFsyN07_8HnQgF6LBnKjlZtQRqlz_Zg_re9U0RsfqCk,2362
3
3
  camomilla/apps.py,sha256=THcQ_2X0cvwec4xxn7DVow42s3P_G3VVL6zGmt6kbQs,188
4
4
  camomilla/authentication.py,sha256=jz6tQT4PPEu-_JLox1LZrOy7EiWBb9MWaObK63MJGus,855
@@ -41,12 +41,12 @@ camomilla/serializers/user.py,sha256=nUwMjsiJfVEk9b-HecMdykMJYa8wyRzPrJRBKNQgkUs
41
41
  camomilla/serializers/base/__init__.py,sha256=thkie650KhkkRflGAT4GZW-auC8b-dhEIpwRYh0DDXc,749
42
42
  camomilla/serializers/fields/__init__.py,sha256=Ufbs26qu3q0l8j1e3lY8tkqEC8rUemb2reetUW1t9qo,703
43
43
  camomilla/serializers/fields/file.py,sha256=QRSPhEAB_snT0IyjtKZQk8bKKHmT9hMNB9udzbc_nVw,648
44
- camomilla/serializers/fields/related.py,sha256=D2nDRKaA2A-jIl_CJsGznlnEnCxHi1qzRprL8pA1yAc,4339
45
- camomilla/serializers/mixins/__init__.py,sha256=s0YhC01ZSYxFdPePXrLusf0P_VN5eHjvqIRBHVWSwG0,6690
44
+ camomilla/serializers/fields/related.py,sha256=Y2SnGWGDAUr3H-Ku7_YQYzbEIXUlsFqw69NCGVEpxSU,4402
45
+ camomilla/serializers/mixins/__init__.py,sha256=1ac5qYcyCXX82t7d_oK93LybHSPJm1GpWqP7AkHBwl4,6905
46
46
  camomilla/templates/camomilla/widgets/media_select_multiple.html,sha256=k2XYou8KkPuFLnPMkPJAFJ-zGJj2Xvu6R3ZmiKa3g7Q,3727
47
47
  camomilla/templatetags/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
48
48
  camomilla/templatetags/camomilla_filters.py,sha256=dvEs_d7Rx0szRxNVe_r_0x5Q6A95YaZjB892-D-p1JI,736
49
- camomilla/theme/__init__.py,sha256=OHSChbC2m8t-xsq4gzzFF3pMDtIRO5igHmONsZ1VqTA,22
49
+ camomilla/theme/__init__.py,sha256=8nkl_rAvBDbI0tFDPTSjYRB0Q0uSHptjScTrgHRP33c,22
50
50
  camomilla/theme/static/admin/css/responsive.css,sha256=Hm3Q6nW3_nu4zNahF0iSzpu60AaVMvFwYW8R7OUMIy4,16681
51
51
  camomilla/theme/static/admin/img/logo.png,sha256=vvC1YE6QgQ1A8i6hRy6ksj3R2HbwNA4jM8qRLaKKTDo,18821
52
52
  camomilla/theme/templates/admin/base_site.html,sha256=Qlb_J7Erpu7oNSLjjQLWciDUoZLEAE49ASw5g2u4g-I,585
@@ -69,8 +69,8 @@ tests/test_camomilla_filters.py,sha256=_W9CcwsEyewMBvnNYKk4CVqrkXxRYejle3mjiBS7h
69
69
  tests/test_models.py,sha256=WJs8lxWZWn1l7X3a_QFVc8fF5LHTsI8bc3uhQe6-o-Q,684
70
70
  tests/test_utils.py,sha256=0tdEDBaBkyjAXpbqP0SpFcfgO56MV2TWZmk9xpjR7J0,3613
71
71
  tests/urls.py,sha256=yCnalWqGClQOCrrbHtIj175aC1ufE6QfhSqT0aoWyjA,562
72
- django_camomilla_cms-5.8.4.dist-info/LICENSE,sha256=kVS7zDrNkav2hLLXbOJwVdonY2ToApTK3khyJagGQoQ,1063
73
- django_camomilla_cms-5.8.4.dist-info/METADATA,sha256=BeyTYHBzgTYp37R-l8jcG0GEsY4mczrUPwv7v_cOku4,2036
74
- django_camomilla_cms-5.8.4.dist-info/WHEEL,sha256=bb2Ot9scclHKMOLDEHY6B2sicWOgugjFKaJsT7vwMQo,110
75
- django_camomilla_cms-5.8.4.dist-info/top_level.txt,sha256=G9VIGBmMMqC7JEckoTgXKmC6T2BR75QRkqRnngw1_lo,16
76
- django_camomilla_cms-5.8.4.dist-info/RECORD,,
72
+ django_camomilla_cms-5.8.6.dist-info/LICENSE,sha256=kVS7zDrNkav2hLLXbOJwVdonY2ToApTK3khyJagGQoQ,1063
73
+ django_camomilla_cms-5.8.6.dist-info/METADATA,sha256=VyVx_fTvJ_xoQc2w1O_9en8Zh_63rg4ycnxEXm6gkCw,2121
74
+ django_camomilla_cms-5.8.6.dist-info/WHEEL,sha256=iYlv5fX357PQyRT2o6tw1bN-YcKFFHKqB_LwHO5wP-g,110
75
+ django_camomilla_cms-5.8.6.dist-info/top_level.txt,sha256=G9VIGBmMMqC7JEckoTgXKmC6T2BR75QRkqRnngw1_lo,16
76
+ django_camomilla_cms-5.8.6.dist-info/RECORD,,
@@ -1,5 +1,5 @@
1
1
  Wheel-Version: 1.0
2
- Generator: bdist_wheel (0.38.4)
2
+ Generator: bdist_wheel (0.41.2)
3
3
  Root-Is-Purelib: true
4
4
  Tag: py2-none-any
5
5
  Tag: py3-none-any