Skip to content

Commit

Permalink
Merge pull request #2609 from magento-commerce/10-22_integration
Browse files Browse the repository at this point in the history
10 22 integration
  • Loading branch information
dobooth committed Oct 22, 2021
2 parents ecd524f + af6b003 commit 3ba327f
Show file tree
Hide file tree
Showing 9 changed files with 177 additions and 17 deletions.
2 changes: 1 addition & 1 deletion src/_data/toc/migration-guide.yml
Expand Up @@ -64,4 +64,4 @@ pages:
url: https://support.magento.com/hc/en-us/articles/360033020451

- label: Changelog
url: https://github.com/magento/data-migration-tool/blob/2.3/CHANGELOG.md
url: https://github.com/magento/data-migration-tool/blob/2.4/CHANGELOG.md
12 changes: 6 additions & 6 deletions src/_includes/install/sampledata/sample-data-clone-24.md
Expand Up @@ -66,12 +66,12 @@ To clone the Magento sample data GitHub repository using the SSH protocol:

If you used the `2.4-develop` branch of the Magento 2 repository, the Sample Data branch should be `2.4-develop`.

If you used the `2.4.1` branch of the Magento 2 repository, the Sample Data branch should be `2.4.1`.
If you used the `2.4.3` branch of the Magento 2 repository, the Sample Data branch should be `2.4.3`.

To checkout the correct branch, run the following command from the sample data repository's root directory (assuming you need the `2.4.1` branch):
To checkout the correct branch, run the following command from the sample data repository's root directory (assuming you need the `2.4.3` branch):

```bash
git checkout 2.4.1
git checkout 2.4.3
```

1. Change to `<magento_root>`.
Expand Down Expand Up @@ -122,12 +122,12 @@ To clone the Magento sample data GitHub repository using the HTTPS protocol:

If you used the `2.4-develop` branch of the Magento 2 repository, the Sample Data branch should be `2.4-develop`.

If you used the `2.4.1` branch of the Magento 2 repository, the Sample Data branch should be `2.4.1`.
If you used the `2.4.3` branch of the Magento 2 repository, the Sample Data branch should be `2.4.3`.

To checkout the correct branch, run the following command from the sample data repository's root directory (assuming you need the `2.4.1` branch):
To checkout the correct branch, run the following command from the sample data repository's root directory (assuming you need the `2.4.3` branch):

```bash
git checkout 2.4.1
git checkout 2.4.3
```

1. Change to `<magento_root>`.
Expand Down
2 changes: 1 addition & 1 deletion src/_includes/install/system-requirements-table.md
Expand Up @@ -16,7 +16,7 @@
| AWS S3 | | | | | | | | | | | ✔️ | ✔️ | | |
| AWS MQ | | | | | | | | | | | | 3.8.11 | | |
| AWS ElastiCache | | | | | | | | | | | | Redis 6.x | | |
| AWS ElasticSearch | | | | | | | | | | | | 7.09 | | |
| AWS ElasticSearch | | | | | | | | | | | | 7.9 | | |

<style>
.comparison-table {
Expand Down
Expand Up @@ -44,7 +44,7 @@ This directory contains:

* Service interfaces in the `/Api` [namespace](https://glossary.magento.com/namespace) of the module ([Catalog API][catalog-api]).

* Data (or *entity*) interfaces in the `Api/Data` directory ([Catalog API/Data][catalog-api-data][]).
* Data (or *entity*) interfaces in the `Api/Data` directory ([Catalog API/Data][catalog-api-data]).
Data entities* are data structures passed to and returned from service interfaces.

Files in the data directory contain `get()` and `set()` methods for entries in the entity table and extension attributes.
Expand Down
2 changes: 1 addition & 1 deletion src/guides/v2.3/inventory/inventory-cli-reference.md
Expand Up @@ -32,7 +32,7 @@ These commands include:
- Refund order or issue a credit memo (compensation reservation)
- Order cancellation (compensation reservation)

Reservation inconsistencies may occur when {{site.data.var.im}} loses the initial reservation and enters too many reservation compensations (overcompensating and leading to inconsistent amounts), or correctly places the initial reservation but loses compensational reservations.
Reservation inconsistencies may occur when {{site.data.var.im}} loses the initial reservation and enters too many reservation compensations (overcompensating and leading to inconsistent amounts), or correctly places the initial reservation but loses compensational reservations. Reservations can be manually reviewed and checked in the `inventory_reservation` table.

The following configurations and events can cause reservation inconsistencies:

Expand Down
51 changes: 51 additions & 0 deletions src/guides/v2.4/config-guide/prod/config-reference-envphp.md
Expand Up @@ -12,6 +12,7 @@ The `env.php` file contains the following sections:
| Name | Description |
|-------------------------------|-----------------------------------------------------------------|
| `backend` | Settings for the Admin area |
| `cache` | Configure redis page and default cache |
| `cache_types` | Cache storage settings |
| `consumers_wait_for_messages` | Configure how consumers process messages from the message queue |
| `cron` | Enable or disable the cron jobs |
Expand All @@ -25,6 +26,7 @@ The `env.php` file contains the following sections:
| `queue` | [Message queues][message-queues] settings |
| `resource` | Mapping of resource name to a connection |
| `session` | Session storage data |
| `system` | Disables the field for editing in the admin |
| `x-frame-options` | Setting for [x-frame-options][x-frame-options] |

## backend
Expand All @@ -37,6 +39,36 @@ Configure the **frontName** for the Magento admin url using the `backend` node i
]
```

## cache

Configure redis page and default caching by using `cache` node in env.php.

```conf
'cache' => [
'frontend' => [
'default' => [
'backend' => 'Magento\\Framework\\Cache\\Backend\\Redis',
'backend_options' => [
'server' => '127.0.0.1',
'database' => '0',
'port' => '6379'
],
],
'page_cache' => [
'backend' => 'Magento\\Framework\\Cache\\Backend\\Redis',
'backend_options' => [
'server' => '127.0.0.1',
'port' => '6379',
'database' => '1',
'compress_data' => '0'
]
]
]
]
```

Learn more in [Redis Configuration][redis-config].

## cache_types

All the Magento cache types configuration are available from this node.
Expand Down Expand Up @@ -227,6 +259,23 @@ x-frame-options header can be configured using this node.

Learn more about session in [x-frame-options][x-frame-options].

## system

Using this node, Magento locks the configuration values in `env.php` and then disables the field in the admin.

```conf
'system' => [
'default' => [
'web' => [
'secure' => [
'base_url' => 'https://magento.test/'
]
]
]
```

Learn more in [env-php-config-set][env-php-config-set].

<!-- Link definitions -->
[lock-provider-config]: {{ page.baseurl }}/install-gde/install/cli/install-cli-subcommands-lock.html
[encryption-key]: https://docs.magento.com/m2/ce/user_guide/system/encryption-key.html
Expand All @@ -240,3 +289,5 @@ Learn more about session in [x-frame-options][x-frame-options].
[downloadable-domains]: {{ page.baseurl }}/reference/cli/magento.html#downloadabledomainsadd
[change-docroot-to-pub]: {{ page.baseurl }}/install-gde/tutorials/change-docroot-to-pub.html
[crons]: {{ page.baseurl }}/config-guide/cli/config-cli-subcommands-cron.html
[env-php-config-set]: {{ page.baseurl }}/config-guide/cli/config-cli-subcommands-config-mgmt-set.html
[redis-config]: {{ page.baseurl }}/config-guide/redis/redis-pg-cache.html
1 change: 0 additions & 1 deletion src/guides/v2.4/extension-dev-guide/variable-pool/index.md

This file was deleted.

103 changes: 103 additions & 0 deletions src/guides/v2.4/extension-dev-guide/variable-pool/index.md
@@ -0,0 +1,103 @@
---
group: php-developer-guide
title: Variable Pool
---

The variable pool contains pre-defined values you can use inside CMS content.
These values are defined in [`di.xml`] files or created through the Admin interface.

## Configuration variables

Configuration variables are values that are set in the Admin area under the **Stores > Settings > Configuration** section.

The default list of variable paths available to the Variable Insertion Dialog is defined in the `di.xml` file in the [Variable module].
This list can be extended by adding more entries to the `configPaths` argument for the `Magento\Variable\Model\Source\Variables` class in your module's `di.xml` file.

**Example:** di.xml file for the Variable module

```xml
<?xml version="1.0"?>
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:ObjectManager/etc/config.xsd">
<type name="Magento\Variable\Model\Config\Structure\AvailableVariables">
<arguments>
<argument name="configPaths" xsi:type="array">
<item name="web" xsi:type="array">
<item name="web/unsecure/base_url" xsi:type="string">1</item>
<item name="web/secure/base_url" xsi:type="string">1</item>
</item>
<item name="trans_email/ident_general" xsi:type="array">
<item name="trans_email/ident_general/name" xsi:type="string">1</item>
<item name="trans_email/ident_general/email" xsi:type="string">1</item>
</item>
<item name="trans_email/ident_sales" xsi:type="array">
<item name="trans_email/ident_sales/name" xsi:type="string">1</item>
<item name="trans_email/ident_sales/email" xsi:type="string">1</item>
</item>
<item name="trans_email/ident_support" xsi:type="array">
<item name="trans_email/ident_support/name" xsi:type="string">1</item>
<item name="trans_email/ident_support/email" xsi:type="string">1</item>
</item>
<item name="trans_email/ident_custom1" xsi:type="array">
<item name="trans_email/ident_custom1/name" xsi:type="string">1</item>
<item name="trans_email/ident_custom1/email" xsi:type="string">1</item>
</item>
<item name="trans_email/ident_custom2" xsi:type="array">
<item name="trans_email/ident_custom2/name" xsi:type="string">1</item>
<item name="trans_email/ident_custom2/email" xsi:type="string">1</item>
</item>
<item name="general/store_information" xsi:type="array">
<item name="general/store_information/name" xsi:type="string">1</item>
<item name="general/store_information/phone" xsi:type="string">1</item>
<item name="general/store_information/hours" xsi:type="string">1</item>
<item name="general/store_information/country_id" xsi:type="string">1</item>
<item name="general/store_information/region_id" xsi:type="string">1</item>
<item name="general/store_information/postcode" xsi:type="string">1</item>
<item name="general/store_information/city" xsi:type="string">1</item>
<item name="general/store_information/street_line1" xsi:type="string">1</item>
<item name="general/store_information/street_line2" xsi:type="string">1</item>
<item name="general/store_information/merchant_vat_number" xsi:type="string">1</item>
</item>
</argument>
</arguments>
</type>
<type name="Magento\Variable\Model\Source\Variables">
<arguments>
<argument name="configStructure" xsi:type="object">Magento\Variable\Model\Config\StructureVirtual</argument>
</arguments>
</type>
<virtualType name="Magento\Variable\Model\Config\Structure\ReaderVirtual" type="Magento\Config\Model\Config\Structure\Reader">
<arguments>
<argument name="domDocumentClass" xsi:type="string">Magento\Variable\Model\Config\Structure\Dom</argument>
</arguments>
</virtualType>
<virtualType name="Magento\Variable\Model\Config\StructureDataVirtual" type="Magento\Config\Model\Config\Structure\Data">
<arguments>
<argument name="cacheId" xsi:type="string">variable_system_configuration_structure</argument>
<argument name="reader" xsi:type="object">Magento\Variable\Model\Config\Structure\ReaderVirtual</argument>
</arguments>
</virtualType>
<virtualType name="Magento\Variable\Model\Config\StructureVirtual" type="Magento\Config\Model\Config\StructureLazy">
<arguments>
<argument name="structureData" xsi:type="object">Magento\Variable\Model\Config\StructureDataVirtual</argument>
</arguments>
</virtualType>
</config>
```

## Custom variables

Custom variables are values created in the Admin area under **System > Other Settings > Custom Variables**.
These variables have a store view scope level and have all the features available to configuration values.

Custom Variable entities can also be created in your module's `DataInstall` or `DataUpgrade` classes.
See [Module Lifecycle] for more information.

[Variable module]: https://github.com/magento/magento2/tree/{{page.guide_version}}/app/code/Magento/Variable/etc
[Module Lifecycle]: {{page.baseurl }}/extension-dev-guide/prepare/lifecycle.html
[`di.xml`]: {{page.baseurl }}/extension-dev-guide/build/di-xml-file.html
Expand Up @@ -55,13 +55,20 @@ This `order_data` object is passed to the view page as a `DataObject` and is ref
```php
public function send(Invoice $invoice, $forceSyncMode = false)
{
$this->identityContainer->setStore($invoice->getStore());
$invoice->setSendEmail($this->identityContainer->isEnabled());
if (!$this->globalConfig->getValue('sales_email/general/async_sending') || $forceSyncMode) {
$order = $invoice->getOrder();
$this->identityContainer->setStore($order->getStore());
if ($this->checkIfPartialInvoice($order, $invoice)) {
$order->setBaseSubtotal((float) $invoice->getBaseSubtotal());
$order->setBaseTaxAmount((float) $invoice->getBaseTaxAmount());
$order->setBaseShippingAmount((float) $invoice->getBaseShippingAmount());
}
$transport = [
'order' => $order,
'order_id' => $order->getId(),
'invoice' => $invoice,
'invoice_id' => $invoice->getId(),
'comment' => $invoice->getCustomerNoteNotify() ? $invoice->getCustomerNote() : '',
'billing' => $order->getBillingAddress(),
'payment_html' => $this->getPaymentHtml($order),
Expand Down
10 changes: 5 additions & 5 deletions src/guides/v2.4/install-gde/install/cli/install-cli.md
Expand Up @@ -47,7 +47,7 @@ You must install Magento from its `bin` subdirectory.

You can run the installer multiple times with different options to complete installation tasks like the following:

* Install in phasesFor example, after you configure your web server for Secure Sockets Layer (SSL), you can run the installer again to set SSL options.
* Install in phasesFor example, after you configure your web server for Secure Sockets Layer (SSL), you can run the installer again to set SSL options.

* Correct mistakes in previous installations.

Expand All @@ -66,9 +66,9 @@ You can run the following commands to find values for some required arguments:

| Installer argument | Command |
| ------------------ | ------------------------------- |
| Language | magento info:language:list |
| Currency | magento info:currency:list |
| Time zone | php magento info:timezone:list |
| Language | bin/magento info:language:list |
| Currency | bin/magento info:currency:list |
| Time zone | bin/magento info:timezone:list |

{:.bs-callout-info}
If an error displays when you run these commands, verify that you updated installation dependencies as discussed in [Update installation dependencies]({{ page.baseurl }}/install-gde/install/prepare-install.html).
Expand All @@ -78,7 +78,7 @@ If an error displays when you run these commands, verify that you updated instal
The install command uses the following format:

```bash
magento setup:install --<option>=<value> ... --<option>=<value>
bin/magento setup:install --<option>=<value> ... --<option>=<value>
```

The following tables describe the installation option names and values. For example installation commands. see [Sample localhost installations](#install-cli-example).
Expand Down

0 comments on commit 3ba327f

Please sign in to comment.