Skip to content

Instantly share code, notes, and snippets.

diff --git a/var/tools/russian_symbols_checker/readme.md b/var/tools/russian_symbols_checker/readme.md
new file mode 100644
index 000000000..88244bc6a
--- /dev/null
+++ b/var/tools/russian_symbols_checker/readme.md
@@ -0,0 +1,42 @@
+# Russian symbols checker
+
+## Назначение
+
diff --git a/app/controllers/frontend/companies.php b/app/controllers/frontend/companies.php
index 85b3d3b47d..9c22d88763 100644
--- a/app/controllers/frontend/companies.php
+++ b/app/controllers/frontend/companies.php
@@ -347,6 +347,8 @@ if ($mode === 'view') {
}
}
fn_add_breadcrumb($category_data['category']);
+ } elseif ($category_data === false) {
+ return [CONTROLLER_STATUS_NO_PAGE];
diff --git a/app/functions/fn.cart.php b/app/functions/fn.cart.php
index 4dbb1ec83c..c9f8e80d99 100644
--- a/app/functions/fn.cart.php
+++ b/app/functions/fn.cart.php
@@ -581,7 +581,7 @@ function fn_get_payments($params = array())
$join = implode(' ', $join);
$order = !empty($order) ? 'ORDER BY ' . implode(', ', $order) : '';
$condition = !empty($condition) ? 'WHERE ' . implode(' AND ', $condition) : '';
- $having = !empty($having) ? 'HAVING ' . implode(' ,', $having) : '';
+ $having = !empty($having) ? 'HAVING ' . implode(' AND ', $having) : '';
diff --git a/app/addons/product_bundles/src/Services/ProductBundleService.php b/app/addons/product_bundles/src/Services/ProductBundleService.php
index 48d86c718e..11994b86ef 100644
--- a/app/addons/product_bundles/src/Services/ProductBundleService.php
+++ b/app/addons/product_bundles/src/Services/ProductBundleService.php
@@ -313,9 +313,10 @@ class ProductBundleService
'get_discounts' => true
]);
+ $is_warehouse_active = Registry::get('addons.warehouses.status') === ObjectStatuses::ACTIVE;
if (!empty($bundle_product['product_options'])) {
diff --git a/app/functions/fn.products.php b/app/functions/fn.products.php
index c250e14c76..b54a12208e 100644
--- a/app/functions/fn.products.php
+++ b/app/functions/fn.products.php
@@ -1331,18 +1331,6 @@ function fn_update_product($product_data, $product_id = 0, $lang_code = CART_LAN
$_data['min_qty'] = 0;
}
- if (Registry::get('settings.General.allow_negative_amount') == 'N'
- && isset($_data['amount'])
diff --git a/app/addons/product_variations/schemas/context_menu/product_variations.php b/app/addons/product_variations/schemas/context_menu/product_variations.php
index 8fed54a91d..0f7dcac29e 100644
--- a/app/addons/product_variations/schemas/context_menu/product_variations.php
+++ b/app/addons/product_variations/schemas/context_menu/product_variations.php
@@ -26,17 +26,32 @@ return [
'type' => GroupItem::class,
'items' => [
'make_active' => [
- 'name' => ['template' => 'bulk_edit.make_active'],
+ 'name' => [
diff --git a/design/themes/responsive/templates/addons/vendor_communication/views/vendor_communication/components/company_subject.tpl b/design/themes/responsive/templates/addons/vendor_communication/views/vendor_communication/components/company_subject.tpl
index 99481c6f7a..b6cd489a86 100644
--- a/design/themes/responsive/templates/addons/vendor_communication/views/vendor_communication/components/company_subject.tpl
+++ b/design/themes/responsive/templates/addons/vendor_communication/views/vendor_communication/components/company_subject.tpl
@@ -2,6 +2,12 @@
$company array Company data
*}
-<a href="{"companies.products?company_id=`$company.logos.theme.company_id`"|fn_url}" title="{$company.company}">
- {$company.company|truncate:60:"...":true}
diff --git a/app/controllers/backend/block_manager.post.php b/app/controllers/backend/block_manager.post.php
index 05c2a2e6d9..1ac68b310c 100644
--- a/app/controllers/backend/block_manager.post.php
+++ b/app/controllers/backend/block_manager.post.php
@@ -54,6 +54,7 @@ if ($_SERVER['REQUEST_METHOD'] == 'POST') {
$result = Block::instance()->update($_REQUEST['block_data']);
} elseif ($action === 'delete' && isset($_REQUEST['block_id'])) {
$result = Block::instance()->remove($_REQUEST['block_id']);
+ $_REQUEST['return_url'] = 'block_manager.blocks';
}
diff --git a/design/backend/templates/addons/rus_payments/hooks/orders/payment_info.post.tpl b/design/backend/templates/addons/rus_payments/hooks/orders/payment_info.post.tpl
index 2bdfb95aa9..c10e3d8ea8 100644
--- a/design/backend/templates/addons/rus_payments/hooks/orders/payment_info.post.tpl
+++ b/design/backend/templates/addons/rus_payments/hooks/orders/payment_info.post.tpl
@@ -6,7 +6,7 @@
{if $processor_script === "sbrf.php"}
<div class="btn-group">
- {if $addons.pdf_documents.status === "ObjectStatuses::ACTIVE"}
+ {if $addons.pdf_documents.status === "ObjectStatuses::ACTIVE"|enum}