ob-dj-store 0.0.13.10__py3-none-any.whl → 0.0.13.11__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.
- ob_dj_store/apis/stores/rest/serializers/serializers.py +14 -3
- {ob_dj_store-0.0.13.10.dist-info → ob_dj_store-0.0.13.11.dist-info}/METADATA +1 -1
- {ob_dj_store-0.0.13.10.dist-info → ob_dj_store-0.0.13.11.dist-info}/RECORD +5 -5
- {ob_dj_store-0.0.13.10.dist-info → ob_dj_store-0.0.13.11.dist-info}/WHEEL +0 -0
- {ob_dj_store-0.0.13.10.dist-info → ob_dj_store-0.0.13.11.dist-info}/top_level.txt +0 -0
@@ -715,15 +715,26 @@ class SubCategorySerializer(serializers.ModelSerializer):
|
|
715
715
|
if store_id:
|
716
716
|
try:
|
717
717
|
current_availability_hours = AvailabilityHours.objects.get(
|
718
|
-
weekday=now().weekday() + 1,
|
718
|
+
weekday=localtime(now()).weekday() + 1,
|
719
719
|
store=store_id,
|
720
720
|
category=obj,
|
721
721
|
)
|
722
|
-
|
722
|
+
parent_availability_hours = AvailabilityHours.objects.get(
|
723
|
+
weekday=localtime(now()).weekday() + 1,
|
724
|
+
store=store_id,
|
725
|
+
category=obj.parent,
|
726
|
+
)
|
727
|
+
is_available_sub = (
|
723
728
|
current_availability_hours.from_hour
|
724
|
-
<= now().time()
|
729
|
+
<= localtime(now()).time()
|
725
730
|
<= current_availability_hours.to_hour
|
726
731
|
)
|
732
|
+
is_available_parent = (
|
733
|
+
parent_availability_hours.from_hour
|
734
|
+
<= localtime(now()).time()
|
735
|
+
<= parent_availability_hours.to_hour
|
736
|
+
)
|
737
|
+
return is_available_sub and is_available_parent
|
727
738
|
except ObjectDoesNotExist:
|
728
739
|
pass
|
729
740
|
return False
|
@@ -3,7 +3,7 @@ ob_dj_store/apis/stores/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG
|
|
3
3
|
ob_dj_store/apis/stores/filters.py,sha256=O5DAzet_WGNoWSEnqbPtwrKy3sbe1HzTtx8jcTLz1dk,7680
|
4
4
|
ob_dj_store/apis/stores/urls.py,sha256=P4d0iamg2R5lTwc5DTIuhLzJTMSH4f5QpHzGR1_PWE0,1676
|
5
5
|
ob_dj_store/apis/stores/views.py,sha256=Umdt1Lu1q4V5R6XasCLpTKjmM2VFco1qa-Z8Ba5Fsuk,36085
|
6
|
-
ob_dj_store/apis/stores/rest/serializers/serializers.py,sha256=
|
6
|
+
ob_dj_store/apis/stores/rest/serializers/serializers.py,sha256=R4ppx2eEHxU2zrYhi2muxHG3sJN0RIYQaTMDbpWyEyY,46439
|
7
7
|
ob_dj_store/apis/tap/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
8
8
|
ob_dj_store/apis/tap/serializers.py,sha256=KPrBK4h2-fWvEVf6vOj2ww5-USV9WqpyYicIqoHIiXI,1065
|
9
9
|
ob_dj_store/apis/tap/urls.py,sha256=bnOTv6an11kxpo_FdqlhsizlGPLVpNxBjCyKcf3_C9M,367
|
@@ -126,7 +126,7 @@ ob_dj_store/utils/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU
|
|
126
126
|
ob_dj_store/utils/helpers.py,sha256=o7wgypM7mI2vZqZKkhxnTcnHJC8GMQDOuYMnRwXr6tY,2058
|
127
127
|
ob_dj_store/utils/model.py,sha256=DV7hOhTaZL3gh9sptts2jTUFlTArKG3i7oPioq9HLFE,303
|
128
128
|
ob_dj_store/utils/utils.py,sha256=8UVAFB56qUSjJJ5f9vnermtw638gdFy4CFRCuMbns_M,1342
|
129
|
-
ob_dj_store-0.0.13.
|
130
|
-
ob_dj_store-0.0.13.
|
131
|
-
ob_dj_store-0.0.13.
|
132
|
-
ob_dj_store-0.0.13.
|
129
|
+
ob_dj_store-0.0.13.11.dist-info/METADATA,sha256=Rztx3a8uLPB-0Xv8GCvclKk66dos3KEGw3tPvRbBKXs,2828
|
130
|
+
ob_dj_store-0.0.13.11.dist-info/WHEEL,sha256=pkctZYzUS4AYVn6dJ-7367OJZivF2e8RA9b_ZBjif18,92
|
131
|
+
ob_dj_store-0.0.13.11.dist-info/top_level.txt,sha256=CZG3G0ptTkzGnc0dFYN-ZD7YKdJBmm47bsmGwofD_lk,12
|
132
|
+
ob_dj_store-0.0.13.11.dist-info/RECORD,,
|
File without changes
|
File without changes
|