Skip to content

Commit

Permalink
Merge branches '2.3-develop' and 'GraphQl-912-CustomerInput-improveme…
Browse files Browse the repository at this point in the history
…nts' of github.com:magento/graphql-ce into GraphQl-912-CustomerInput-improvements

� Conflicts:
�	app/code/Magento/CustomerGraphQl/etc/schema.graphqls
  • Loading branch information
Vitaliy Boyko committed Sep 27, 2019
2 parents 984ef45 + ea71192 commit eb29ce7
Show file tree
Hide file tree
Showing 362 changed files with 12,219 additions and 3,307 deletions.
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,10 @@ Welcome to Magento 2 installation! We're glad you chose to install Magento 2, a

* [Installation Guide](https://devdocs.magento.com/guides/v2.3/install-gde/bk-install-guide.html).

## Learn More About GraphQL in Magento 2

* [GraphQL Developer Guide](https://devdocs.magento.com/guides/v2.3/graphql/index.html)

<h2>Contributing to the Magento 2 Code Base</h2>
Contributions can take the form of new components or features, changes to existing features, tests, documentation (such as developer guides, user guides, examples, or specifications), bug fixes, optimizations, or just good suggestions.

Expand Down
4 changes: 2 additions & 2 deletions app/code/Magento/AdminNotification/etc/db_schema.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
xsi:noNamespaceSchemaLocation="urn:magento:framework:Setup/Declaration/Schema/etc/schema.xsd">
<table name="adminnotification_inbox" resource="default" engine="innodb" comment="Adminnotification Inbox">
<column xsi:type="int" name="notification_id" padding="10" unsigned="true" nullable="false" identity="true"
comment="Notification id"/>
comment="Notification ID"/>
<column xsi:type="smallint" name="severity" padding="5" unsigned="true" nullable="false" identity="false"
default="0" comment="Problem type"/>
<column xsi:type="timestamp" name="date_added" on_update="false" nullable="false" default="CURRENT_TIMESTAMP"
Expand All @@ -35,7 +35,7 @@
</index>
</table>
<table name="admin_system_messages" resource="default" engine="innodb" comment="Admin System Messages">
<column xsi:type="varchar" name="identity" nullable="false" length="100" comment="Message id"/>
<column xsi:type="varchar" name="identity" nullable="false" length="100" comment="Message ID"/>
<column xsi:type="smallint" name="severity" padding="5" unsigned="true" nullable="false" identity="false"
default="0" comment="Problem type"/>
<column xsi:type="timestamp" name="created_at" on_update="false" nullable="false" default="CURRENT_TIMESTAMP"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@
*/
namespace Magento\AdvancedPricingImportExport\Model\Export;

use Magento\ImportExport\Model\Export;
use Magento\Store\Model\Store;
use Magento\CatalogImportExport\Model\Import\Product as ImportProduct;
use Magento\AdvancedPricingImportExport\Model\Import\AdvancedPricing as ImportAdvancedPricing;
use Magento\Catalog\Model\Product as CatalogProduct;
use Magento\CatalogImportExport\Model\Import\Product as ImportProduct;
use Magento\ImportExport\Model\Export;
use Magento\Store\Model\Store;

/**
* Export Advanced Pricing
Expand Down Expand Up @@ -150,6 +150,8 @@ public function __construct(
}

/**
* Init type models
*
* @return $this
* @throws \Magento\Framework\Exception\LocalizedException
*/
Expand All @@ -172,7 +174,9 @@ protected function initTypeModels()
}
if ($model->isSuitable()) {
$this->_productTypeModels[$productTypeName] = $model;
// phpcs:ignore Magento2.Performance.ForeachArrayMerge
$this->_disabledAttrs = array_merge($this->_disabledAttrs, $model->getDisabledAttrs());
// phpcs:ignore Magento2.Performance.ForeachArrayMerge
$this->_indexValueAttributes = array_merge(
$this->_indexValueAttributes,
$model->getIndexValueAttributes()
Expand All @@ -197,6 +201,7 @@ protected function initTypeModels()
public function export()
{
//Execution time may be very long
// phpcs:ignore Magento2.Functions.DiscouragedFunction
set_time_limit(0);

$writer = $this->getWriter();
Expand Down Expand Up @@ -234,16 +239,6 @@ public function filterAttributeCollection(\Magento\Eav\Model\ResourceModel\Entit

foreach ($collection as $attribute) {
if (in_array($attribute->getAttributeCode(), $this->_disabledAttrs)) {
if (isset($this->_parameters[\Magento\ImportExport\Model\Export::FILTER_ELEMENT_SKIP])) {
if ($attribute->getAttributeCode() == ImportAdvancedPricing::COL_TIER_PRICE
&& in_array(
$attribute->getId(),
$this->_parameters[\Magento\ImportExport\Model\Export::FILTER_ELEMENT_SKIP]
)
) {
$this->_passTierPrice = 1;
}
}
$collection->removeItemByKey($attribute->getId());
}
}
Expand Down Expand Up @@ -363,6 +358,7 @@ private function prepareExportData(
$linkedTierPricesData = [];
foreach ($tierPricesData as $tierPriceData) {
$sku = $productLinkIdToSkuMap[$tierPriceData['product_link_id']];
// phpcs:ignore Magento2.Performance.ForeachArrayMerge
$linkedTierPricesData[] = array_merge(
$tierPriceData,
[ImportAdvancedPricing::COL_SKU => $sku]
Expand Down Expand Up @@ -471,7 +467,7 @@ private function fetchTierPrices(array $productIds): array
ImportAdvancedPricing::COL_TIER_PRICE_QTY => 'ap.qty',
ImportAdvancedPricing::COL_TIER_PRICE => 'ap.value',
ImportAdvancedPricing::COL_TIER_PRICE_PERCENTAGE_VALUE => 'ap.percentage_value',
'product_link_id' => 'ap.' .$productEntityLinkField,
'product_link_id' => 'ap.' . $productEntityLinkField,
];
if ($exportFilter && array_key_exists('tier_price', $exportFilter)) {
if (!empty($exportFilter['tier_price'][0])) {
Expand All @@ -488,7 +484,7 @@ private function fetchTierPrices(array $productIds): array
$selectFields
)
->where(
'ap.'.$productEntityLinkField.' IN (?)',
'ap.' . $productEntityLinkField . ' IN (?)',
$productIds
);

Expand Down Expand Up @@ -602,7 +598,7 @@ protected function _getWebsiteCode(int $websiteId): string
}

if ($storeName && $currencyCode) {
$code = $storeName.' ['.$currencyCode.']';
$code = $storeName . ' [' . $currencyCode . ']';
} else {
$code = $storeName;
}
Expand Down
6 changes: 3 additions & 3 deletions app/code/Magento/AdvancedSearch/etc/db_schema.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,11 @@
xsi:noNamespaceSchemaLocation="urn:magento:framework:Setup/Declaration/Schema/etc/schema.xsd">
<table name="catalogsearch_recommendations" resource="default" engine="innodb"
comment="Advanced Search Recommendations">
<column xsi:type="int" name="id" padding="10" unsigned="true" nullable="false" identity="true" comment="Id"/>
<column xsi:type="int" name="id" padding="10" unsigned="true" nullable="false" identity="true" comment="ID"/>
<column xsi:type="int" name="query_id" padding="10" unsigned="true" nullable="false" identity="false"
default="0" comment="Query Id"/>
default="0" comment="Query ID"/>
<column xsi:type="int" name="relation_id" padding="10" unsigned="true" nullable="false" identity="false"
default="0" comment="Relation Id"/>
default="0" comment="Relation ID"/>
<constraint xsi:type="primary" referenceId="PRIMARY">
<column name="id"/>
</constraint>
Expand Down
41 changes: 25 additions & 16 deletions app/code/Magento/Analytics/README.md
Original file line number Diff line number Diff line change
@@ -1,18 +1,27 @@
# Magento_Analytics Module
# Magento_Analytics module

The Magento_Analytics module integrates your Magento instance with the [Magento Business Intelligence (MBI)](https://magento.com/products/business-intelligence) to use [Advanced Reporting](https://devdocs.magento.com/guides/v2.3/advanced-reporting/modules.html) functionality.

The module implements the following functionality:

* enabling subscription to the MBI and automatic re-subscription
* changing the base URL with the same MBI account remained
* declaring the configuration schemas for report data collection
* collecting the Magento instance data as reports for the MBI
* introducing API that provides the collected data
* extending Magento configuration with the module parameters:
* subscription status (enabled/disabled)
* industry (a business area in which the instance website works)
* time of data collection (time of the day when the module collects data)
- Enabling subscription to Magento Business Intelligence (MBI) and automatic re-subscription
- Declaring the configuration schemas for report data collection
- Collecting the Magento instance data as reports for MBI
- Introducing API that provides the collected data
- Extending Magento configuration with the module parameters:
- Subscription status (enabled/disabled)
- Industry (a business area in which the instance website works)
- Time of data collection (time of the day when the module collects data)

## Installation details

Before disabling or uninstalling this module, note that the following modules depends on this module:
- Magento_CatalogAnalytics
- Magento_CustomerAnalytics
- Magento_QuoteAnalytics
- Magento_ReviewAnalytics
- Magento_SalesAnalytics
- Magento_WishlistAnalytics

## Structure

Expand All @@ -29,12 +38,12 @@ The subscription to the MBI service is enabled during the installation process o
Configuration settings for the Analytics module can be modified in the Admin Panel on the Stores > Configuration page under the General > Advanced Reporting tab.

The following options can be adjusted:
* Advanced Reporting Service (Enabled/Disabled)
* Alters the status of the Advanced Reporting subscription
* Time of day to send data (Hour/Minute/Second in the store's time zone)
* Defines when the data collection process for the Advanced Reporting service occurs
* Industry
* Defines the industry of the store in order to create a personalized Advanced Reporting experience
- Advanced Reporting Service (Enabled/Disabled)
- Alters the status of the Advanced Reporting subscription
- Time of day to send data (Hour/Minute/Second in the store's time zone)
- Defines when the data collection process for the Advanced Reporting service occurs
- Industry
- Defines the industry of the store in order to create a personalized Advanced Reporting experience

## Extensibility

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,9 @@
<amOnPage url="{{AdminConfigGeneralAnalyticsPage.url}}" stepKey="amOnAdminConfig"/>
<selectOption selector="{{AdminConfigAdvancedReportingSection.advancedReportingService}}" userInput="Enable" stepKey="selectAdvancedReportingServiceEnabled"/>
<selectOption selector="{{AdminConfigAdvancedReportingSection.advancedReportingIndustry}}" userInput="Apps and Games" stepKey="selectAdvancedReportingIndustry"/>
<selectOption selector="{{AdminConfigAdvancedReportingSection.advancedReportingHour}}" userInput="11" stepKey="selectAdvancedReportingHour"/>
<selectOption selector="{{AdminConfigAdvancedReportingSection.advancedReportingMinute}}" userInput="11" stepKey="selectAdvancedReportingMinute"/>
<selectOption selector="{{AdminConfigAdvancedReportingSection.advancedReportingSeconds}}" userInput="00" stepKey="selectAdvancedReportingSeconds"/>
<selectOption selector="{{AdminConfigAdvancedReportingSection.advancedReportingHour}}" userInput="23" stepKey="selectAdvancedReportingHour"/>
<selectOption selector="{{AdminConfigAdvancedReportingSection.advancedReportingMinute}}" userInput="59" stepKey="selectAdvancedReportingMinute"/>
<selectOption selector="{{AdminConfigAdvancedReportingSection.advancedReportingSeconds}}" userInput="59" stepKey="selectAdvancedReportingSeconds"/>
<click selector="{{AdminMainActionsSection.save}}" stepKey="clickSaveConfigButton"/>
<see selector="{{AdminMessagesSection.success}}" userInput="You saved the configuration." stepKey="seeSuccess"/>
</test>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
<label>Bulk Actions</label>
<field id="lifetime" translate="label" type="text" sortOrder="10" showInDefault="1" showInWebsite="0" showInStore="0">
<label>Days Saved in Log</label>
<validate>validate-zero-or-greater validate-digits</validate>
</field>
</group>
</section>
Expand Down
6 changes: 6 additions & 0 deletions app/code/Magento/Authorization/Model/Role.php
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,9 @@ public function __construct( //phpcs:ignore Generic.CodeAnalysis.UselessOverridi

/**
* @inheritDoc
*
* @SuppressWarnings(PHPMD.SerializationAware)
* @deprecated Do not use PHP serialization.
*/
public function __sleep()
{
Expand All @@ -61,6 +64,9 @@ public function __sleep()

/**
* @inheritDoc
*
* @SuppressWarnings(PHPMD.SerializationAware)
* @deprecated Do not use PHP serialization.
*/
public function __wakeup()
{
Expand Down
Loading

0 comments on commit eb29ce7

Please sign in to comment.