fix - quota stat none in pos sharing

This commit is contained in:
2025-12-04 13:24:42 +03:30
parent c2bb50d9f8
commit 05395202cb
3 changed files with 3 additions and 3 deletions

View File

@@ -14,7 +14,7 @@
</component> </component>
<component name="NewModuleRootManager"> <component name="NewModuleRootManager">
<content url="file://$MODULE_DIR$" /> <content url="file://$MODULE_DIR$" />
<orderEntry type="jdk" jdkName="Python 3.10 (env)" jdkType="Python SDK" /> <orderEntry type="jdk" jdkName="Python 3.8" jdkType="Python SDK" />
<orderEntry type="sourceFolder" forTests="false" /> <orderEntry type="sourceFolder" forTests="false" />
</component> </component>
<component name="PyDocumentationSettings"> <component name="PyDocumentationSettings">

2
.idea/misc.xml generated
View File

@@ -3,5 +3,5 @@
<component name="Black"> <component name="Black">
<option name="sdkName" value="Python 3.10 (env)" /> <option name="sdkName" value="Python 3.10 (env)" />
</component> </component>
<component name="ProjectRootManager" version="2" project-jdk-name="Python 3.10 (env)" project-jdk-type="Python SDK" /> <component name="ProjectRootManager" version="2" project-jdk-name="Python 3.8" project-jdk-type="Python SDK" />
</project> </project>

View File

@@ -35,7 +35,7 @@ def pos_organizations_sharing_information(
"amount": quota.broker_values.filter( "amount": quota.broker_values.filter(
broker=item.broker, broker=item.broker,
# if quota price features was edited for this organization # if quota price features was edited for this organization
org_quota_stat=quota_stat if quota_stat.broker_values.exists() else None org_quota_stat=quota_stat if quota_stat and quota_stat.broker_values.exists() else None
).first().value if quota.broker_values.filter(broker=item.broker).exists() else None, ).first().value if quota.broker_values.filter(broker=item.broker).exists() else None,
# """ # """
# if we will need to get agencies share amount, we can use this bellow code # if we will need to get agencies share amount, we can use this bellow code