tgshops-integrations 3.4__tar.gz → 3.6__tar.gz
Sign up to get free protection for your applications and to get access to all the features.
- {tgshops_integrations-3.4 → tgshops_integrations-3.6}/PKG-INFO +4 -1
- {tgshops_integrations-3.4 → tgshops_integrations-3.6}/README.md +3 -0
- {tgshops_integrations-3.4 → tgshops_integrations-3.6}/setup.py +1 -1
- {tgshops_integrations-3.4 → tgshops_integrations-3.6}/tgshops_integrations/nocodb_connector/categories_management.py +2 -2
- {tgshops_integrations-3.4 → tgshops_integrations-3.6}/tgshops_integrations/nocodb_connector/model_mapping.py +4 -2
- {tgshops_integrations-3.4 → tgshops_integrations-3.6}/tgshops_integrations/nocodb_connector/products_management.py +2 -1
- {tgshops_integrations-3.4 → tgshops_integrations-3.6}/tgshops_integrations.egg-info/PKG-INFO +4 -1
- {tgshops_integrations-3.4 → tgshops_integrations-3.6}/setup.cfg +0 -0
- {tgshops_integrations-3.4 → tgshops_integrations-3.6}/tgshops_integrations/__init__.py +0 -0
- {tgshops_integrations-3.4 → tgshops_integrations-3.6}/tgshops_integrations/middlewares/__init__.py +0 -0
- {tgshops_integrations-3.4 → tgshops_integrations-3.6}/tgshops_integrations/middlewares/gateway.py +0 -0
- {tgshops_integrations-3.4 → tgshops_integrations-3.6}/tgshops_integrations/models/__init__.py +0 -0
- {tgshops_integrations-3.4 → tgshops_integrations-3.6}/tgshops_integrations/models/categories.py +0 -0
- {tgshops_integrations-3.4 → tgshops_integrations-3.6}/tgshops_integrations/models/products.py +0 -0
- {tgshops_integrations-3.4 → tgshops_integrations-3.6}/tgshops_integrations/nocodb_connector/__init__.py +0 -0
- {tgshops_integrations-3.4 → tgshops_integrations-3.6}/tgshops_integrations/nocodb_connector/client.py +0 -0
- {tgshops_integrations-3.4 → tgshops_integrations-3.6}/tgshops_integrations/nocodb_connector/tables.py +0 -0
- {tgshops_integrations-3.4 → tgshops_integrations-3.6}/tgshops_integrations.egg-info/SOURCES.txt +0 -0
- {tgshops_integrations-3.4 → tgshops_integrations-3.6}/tgshops_integrations.egg-info/dependency_links.txt +0 -0
- {tgshops_integrations-3.4 → tgshops_integrations-3.6}/tgshops_integrations.egg-info/top_level.txt +0 -0
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.1
|
2
2
|
Name: tgshops_integrations
|
3
|
-
Version: 3.
|
3
|
+
Version: 3.6
|
4
4
|
Summary: Library is intended to provide the integration of the external service or CRM system with the TelegramShops/It allows to configure the relationship between NocoDB list of the products used further to display in the shop/As a resultss the products can be synchronized and updated uppon the request.
|
5
5
|
Home-page: https://git.the-devs.com/virtual-shops/shop-system/shop-backend-integrations/integration-library/integration-library
|
6
6
|
Author: Dimi Latoff
|
@@ -74,6 +74,9 @@ async def main():
|
|
74
74
|
|
75
75
|
asyncio.run(main())
|
76
76
|
|
77
|
+
# python3 setup.py sdist bdist_wheel
|
78
|
+
# twine upload dist/* --verbose
|
79
|
+
|
77
80
|
|
78
81
|
|
79
82
|
|
@@ -1,8 +1,8 @@
|
|
1
1
|
from typing import List
|
2
2
|
from loguru import logger
|
3
3
|
from aiocache import cached
|
4
|
-
from models.categories import CategoryModel, CategoryResponseModel, CategoryListResponseModel
|
5
|
-
from models.products import ProductModel
|
4
|
+
from tgshops_integrations.models.categories import CategoryModel, CategoryResponseModel, CategoryListResponseModel
|
5
|
+
from tgshops_integrations.models.products import ProductModel
|
6
6
|
from tgshops_integrations.nocodb_connector.client import custom_key_builder, NocodbClient
|
7
7
|
from tgshops_integrations.nocodb_connector.model_mapping import (
|
8
8
|
CATEGORY_IMAGE_FIELD,
|
@@ -33,7 +33,7 @@ def initialize_model_mapping(config_path: str):
|
|
33
33
|
global PRODUCT_IMAGE_FIELD, PRODUCT_DISCOUNT_PRICE_FIELD, PRODUCT_CATEGORY_ID_LOOKUP_FIELD, PRODUCT_IMAGES_LOOKUP_FIELD
|
34
34
|
global PRODUCT_REQUIRED_OPTIONS_FIELD, PRODUCT_CATEGORIES_EXTRA_OPTIONS_FIELD, PRODUCT_CATEGORIES_EXTRA_OPTION_NAMES_FIELD
|
35
35
|
global PRODUCT_EXTRA_CHOICE_REQUIRED_FIELD, PRODUCT_ID_FIELD, PRODUCT_EXTERNAL_ID, PRODUCT_CHECKOUT_MODE
|
36
|
-
global NEW_ID_FIELD, NOCODB_CHECKOUT_MODES
|
36
|
+
global NEW_ID_FIELD, NOCODB_CHECKOUT_MODES,PRODUCT_CATEGORY_STRUCTURE
|
37
37
|
|
38
38
|
config = load_config(config_path)
|
39
39
|
|
@@ -50,6 +50,7 @@ def initialize_model_mapping(config_path: str):
|
|
50
50
|
PRODUCT_CURRENCY_FIELD = config.PRODUCT_CURRENCY_FIELD
|
51
51
|
PRODUCT_STOCK_FIELD = config.PRODUCT_STOCK_FIELD
|
52
52
|
PRODUCT_CATEGORY_NAME_FIELD = config.PRODUCT_CATEGORY_NAME_FIELD
|
53
|
+
PRODUCT_CATEGORY_STRUCTURE=config.PRODUCT_CATEGORY_STRUCTURE
|
53
54
|
PRODUCT_CATEGORY_ID_FIELD = config.PRODUCT_CATEGORY_ID_FIELD
|
54
55
|
PRODUCT_IMAGE_FIELD = config.PRODUCT_IMAGE_FIELD
|
55
56
|
PRODUCT_DISCOUNT_PRICE_FIELD = config.PRODUCT_DISCOUNT_PRICE_FIELD
|
@@ -187,7 +188,8 @@ async def parse_product_data(data: dict) -> ProductModel:
|
|
187
188
|
currency=data.get(PRODUCT_CURRENCY_FIELD, "RUB"),
|
188
189
|
stock_qty=data.get(PRODUCT_STOCK_FIELD, 0),
|
189
190
|
preview_url=preview_url,
|
190
|
-
|
191
|
+
product_properties=data.get(PRODUCT_CATEGORY_NAME_FIELD, []),
|
192
|
+
categories_structure=data.get(PRODUCT_CATEGORY_STRUCTURE, {}),
|
191
193
|
category=data.get(PRODUCT_CATEGORY_ID_LOOKUP_FIELD, []),
|
192
194
|
extra_attributes=extra_attributes,
|
193
195
|
extra_option_choice_required=bool(data.get(PRODUCT_EXTRA_CHOICE_REQUIRED_FIELD, [])),
|
@@ -2,7 +2,7 @@ from typing import List, Optional
|
|
2
2
|
import hashlib
|
3
3
|
from aiocache import cached
|
4
4
|
from loguru import logger
|
5
|
-
from models.products import ProductModel
|
5
|
+
from tgshops_integrations.models.products import ProductModel
|
6
6
|
from tgshops_integrations.nocodb_connector.client import custom_key_builder, NocodbClient
|
7
7
|
from tgshops_integrations.nocodb_connector.model_mapping import (
|
8
8
|
dump_product_data,
|
@@ -18,6 +18,7 @@ from tgshops_integrations.nocodb_connector.model_mapping import (
|
|
18
18
|
PRODUCT_IMAGES_LOOKUP_FIELD,
|
19
19
|
)
|
20
20
|
|
21
|
+
|
21
22
|
class ProductManager(NocodbClient):
|
22
23
|
def __init__(self, table_id=None, logging=False, NOCODB_HOST=None, NOCODB_API_KEY=None, SOURCE=None):
|
23
24
|
super().__init__(NOCODB_HOST=NOCODB_HOST, NOCODB_API_KEY=NOCODB_API_KEY, SOURCE=SOURCE)
|
{tgshops_integrations-3.4 → tgshops_integrations-3.6}/tgshops_integrations.egg-info/PKG-INFO
RENAMED
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.1
|
2
2
|
Name: tgshops-integrations
|
3
|
-
Version: 3.
|
3
|
+
Version: 3.6
|
4
4
|
Summary: Library is intended to provide the integration of the external service or CRM system with the TelegramShops/It allows to configure the relationship between NocoDB list of the products used further to display in the shop/As a resultss the products can be synchronized and updated uppon the request.
|
5
5
|
Home-page: https://git.the-devs.com/virtual-shops/shop-system/shop-backend-integrations/integration-library/integration-library
|
6
6
|
Author: Dimi Latoff
|
@@ -74,6 +74,9 @@ async def main():
|
|
74
74
|
|
75
75
|
asyncio.run(main())
|
76
76
|
|
77
|
+
# python3 setup.py sdist bdist_wheel
|
78
|
+
# twine upload dist/* --verbose
|
79
|
+
|
77
80
|
|
78
81
|
|
79
82
|
|
File without changes
|
File without changes
|
{tgshops_integrations-3.4 → tgshops_integrations-3.6}/tgshops_integrations/middlewares/__init__.py
RENAMED
File without changes
|
{tgshops_integrations-3.4 → tgshops_integrations-3.6}/tgshops_integrations/middlewares/gateway.py
RENAMED
File without changes
|
{tgshops_integrations-3.4 → tgshops_integrations-3.6}/tgshops_integrations/models/__init__.py
RENAMED
File without changes
|
{tgshops_integrations-3.4 → tgshops_integrations-3.6}/tgshops_integrations/models/categories.py
RENAMED
File without changes
|
{tgshops_integrations-3.4 → tgshops_integrations-3.6}/tgshops_integrations/models/products.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{tgshops_integrations-3.4 → tgshops_integrations-3.6}/tgshops_integrations.egg-info/SOURCES.txt
RENAMED
File without changes
|
File without changes
|
{tgshops_integrations-3.4 → tgshops_integrations-3.6}/tgshops_integrations.egg-info/top_level.txt
RENAMED
File without changes
|