Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/develop' into develop
Browse files Browse the repository at this point in the history
* upstream/develop: (2518 commits)
  MQE-279: Create repositories in magento organization
  MQE-279: Create repositories in magento organization
  MQE-279: Create repositories in magento organization
  Deliver magento-partners/magento2ce#25: fixed static tests failures
  #10930 getcachetags for price issue
  Fixed Typo Mistake in comment.
  Add escaping of js translation version
  MAGETWO-72469: Merge 2.2-develop into develop
  #10789: enable universal use of modal and tab_group  - Coding style updated
  #10848: added query param to url build  - Test Updated
  Deprecated Magento\Store\Model\Store::$_isAdminSecure
  MAGETWO-72401: fix jenkins unittest
  #10826: response condition order changes.  - Updated coding style
  MAGETWO-70859: Inconsistent behaviour of Scheduled Changes
  cviking26_issue-9489 // syntax hotfix
  MAGETWO-72469: Merge 2.2-develop into develop
  MAGETWO-72469: Merge 2.2-develop into develop
  cviking26_issue-9489 // changed array declaration
  cviking26_issue-9489 // added query param to url build - description in #9489
  MAGETWO-72046: Error processing your request when placing reorder for simple product of configurable if attribute is changed - for 2.2
  ...
  • Loading branch information
adrian-martinez-interactiv4 committed Sep 21, 2017
2 parents 8a92e46 + ecefd85 commit 0a69b5b
Show file tree
Hide file tree
Showing 12,512 changed files with 215,202 additions and 131,448 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
2 changes: 2 additions & 0 deletions .github/.htaccess
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
Order deny,allow
Deny from all
46 changes: 46 additions & 0 deletions .github/CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
# Contributor Covenant Code of Conduct

## Our Pledge

In the interest of fostering an open and welcoming environment, we as contributors and maintainers pledge to making participation in our project and our community a harassment-free experience for everyone, regardless of age, body size, disability, ethnicity, gender identity and expression, level of experience, nationality, personal appearance, race, religion, or sexual identity and orientation.

## Our Standards

Examples of behavior that contributes to creating a positive environment include:

* Using welcoming and inclusive language
* Being respectful of differing viewpoints and experiences
* Gracefully accepting constructive criticism
* Focusing on what is best for the community
* Showing empathy towards other community members

Examples of unacceptable behavior by participants include:

* The use of sexualized language or imagery and unwelcome sexual attention or advances
* Trolling, insulting/derogatory comments, and personal or political attacks
* Public or private harassment
* Publishing others' private information, such as a physical or electronic address, without explicit permission
* Other conduct which could reasonably be considered inappropriate in a professional setting

## Our Responsibilities

Project maintainers are responsible for clarifying the standards of acceptable behavior and are expected to take appropriate and fair corrective action in response to any instances of unacceptable behavior.

Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct, or to ban temporarily or permanently any contributor for other behaviors that they deem inappropriate, threatening, offensive, or harmful.

## Scope

This Code of Conduct applies both within project spaces and in public spaces when an individual is representing the project or its community. Examples of representing a project or community include using an official project e-mail address, posting via an official social media account, or acting as an appointed representative at an online or offline event. Representation of a project may be further defined and clarified by project maintainers.

## Enforcement

Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by contacting the project team at [email protected]. The project team will review and investigate all complaints, and will respond in a way that it deems appropriate to the circumstances. The project team is obligated to maintain confidentiality with regard to the reporter of an incident. Further details of specific enforcement policies may be posted separately.

Project maintainers who do not follow or enforce the Code of Conduct in good faith may face temporary or permanent repercussions as determined by other members of the project's leadership.

## Attribution

This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4, available at [http://contributor-covenant.org/version/1/4][version]

[homepage]: http://contributor-covenant.org
[version]: http://contributor-covenant.org/version/1/4/
5 changes: 5 additions & 0 deletions CONTRIBUTING.md → .github/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,3 +29,8 @@ If you are a new GitHub user, we recommend that you create your own [free github
3. Create and test your work.
4. Fork the Magento 2 repository according to [Fork a repository instructions](http://devdocs.magento.com/guides/v2.0/contributor-guide/contributing.html#fork) and when you are ready to send us a pull request – follow [Create a pull request instructions](http://devdocs.magento.com/guides/v2.0/contributor-guide/contributing.html#pull_request).
5. Once your contribution is received, Magento 2 development team will review the contribution and collaborate with you as needed to improve the quality of the contribution.

## Code of Conduct

Please note that this project is released with a Contributor Code of Conduct. We expect you to agree to its terms when participating in this project.
The full text is available in the repository [Wiki](https://github.com/magento/magento2/wiki/Magento-Code-of-Conduct).
File renamed without changes.
File renamed without changes.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
/.metadata
/.project
/.settings
/.vscode
atlassian*
/nbproject
/robots.txt
Expand Down Expand Up @@ -48,6 +49,7 @@ atlassian*
/pub/media/favicon/*
/pub/media/import/*
!/pub/media/import/.htaccess
/pub/media/logo/*
/pub/media/theme/*
/pub/media/theme_customization/*
!/pub/media/theme_customization/.htaccess
Expand All @@ -65,3 +67,4 @@ atlassian*
!/vendor/.htaccess
/generated/*
!/generated/.htaccess
.DS_Store
4 changes: 0 additions & 4 deletions .htaccess
Original file line number Diff line number Diff line change
Expand Up @@ -234,10 +234,6 @@
order allow,deny
deny from all
</Files>
<Files CONTRIBUTING.md>
order allow,deny
deny from all
</Files>
<Files COPYING.txt>
order allow,deny
deny from all
Expand Down
4 changes: 0 additions & 4 deletions .htaccess.sample
Original file line number Diff line number Diff line change
Expand Up @@ -210,10 +210,6 @@
order allow,deny
deny from all
</Files>
<Files CONTRIBUTING.md>
order allow,deny
deny from all
</Files>
<Files COPYING.txt>
order allow,deny
deny from all
Expand Down
33 changes: 28 additions & 5 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,27 +1,45 @@
sudo: required
dist: trusty
group: edge
addons:
apt:
packages:
- mysql-server-5.6
- mysql-client-core-5.6
- mysql-client-5.6
- postfix
firefox: "46.0"
hosts:
- magento2.travis
language: php
php:
- 7.0
- 7.1
env:
global:
- COMPOSER_BIN_DIR=~/bin
- INTEGRATION_SETS=3
- NODE_JS_VERSION=6
- MAGENTO_HOST_NAME="magento2.travis"
matrix:
- TEST_SUITE=unit
- TEST_SUITE=static
- TEST_SUITE=js GRUNT_COMMAND=spec
- TEST_SUITE=js GRUNT_COMMAND=static
- TEST_SUITE=integration INTEGRATION_INDEX=1
- TEST_SUITE=integration INTEGRATION_INDEX=2
- TEST_SUITE=integration INTEGRATION_INDEX=3
- TEST_SUITE=static
- TEST_SUITE=js
- TEST_SUITE=functional
matrix:
exclude:
- php: 7.0
env: TEST_SUITE=static
- php: 7.0
env: TEST_SUITE=js GRUNT_COMMAND=spec
- php: 7.0
env: TEST_SUITE=js GRUNT_COMMAND=static
- php: 7.0
env: TEST_SUITE=functional
cache:
apt: true
directories:
Expand All @@ -30,9 +48,14 @@ cache:
- $HOME/node_modules
- $HOME/yarn.lock
before_install: ./dev/travis/before_install.sh
install: composer install --no-interaction --prefer-dist
install: composer install --no-interaction
before_script: ./dev/travis/before_script.sh
script:
# Set arguments for variants of phpunit based tests; '|| true' prevents failing script when leading test fails
- test $TEST_SUITE = "static" && TEST_FILTER='--filter "Magento\\Test\\Php\\LiveCodeTest"' || true
- if [ $TEST_SUITE != "js" ]; then phpunit -c dev/tests/$TEST_SUITE $TEST_FILTER; fi
- if [ $TEST_SUITE == "js" ]; then grunt spec; fi
- test $TEST_SUITE = "functional" && TEST_FILTER='dev/tests/functional/testsuites/Magento/Mtf/TestSuite/InjectableTests.php' || true

# The scripts for grunt/phpunit type tests
- if [ $TEST_SUITE == "functional" ]; then dev/tests/functional/vendor/phpunit/phpunit/phpunit -c dev/tests/$TEST_SUITE $TEST_FILTER; fi
- if [ $TEST_SUITE != "functional" ] && [ $TEST_SUITE != "js" ]; then phpunit -c dev/tests/$TEST_SUITE $TEST_FILTER; fi
- if [ $TEST_SUITE == "js" ]; then grunt $GRUNT_COMMAND; fi
3 changes: 0 additions & 3 deletions app/autoload.php
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,3 @@
}

AutoloaderRegistry::registerAutoloader(new ClassLoaderWrapper($composerAutoloader));

// Sets default autoload mappings, may be overridden in Bootstrap::create
\Magento\Framework\App\Bootstrap::populateAutoloader(BP, []);
15 changes: 9 additions & 6 deletions app/bootstrap.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,14 @@
#ini_set('display_errors', 1);

/* PHP version validation */
if (!defined('PHP_VERSION_ID') || !(PHP_VERSION_ID >= 50605 && PHP_VERSION_ID < 50700 || PHP_VERSION_ID === 70002 || PHP_VERSION_ID === 70004 || PHP_VERSION_ID >= 70006)) {
if (!defined('PHP_VERSION_ID') || !(PHP_VERSION_ID === 70002 || PHP_VERSION_ID === 70004 || PHP_VERSION_ID >= 70006)) {
if (PHP_SAPI == 'cli') {
echo 'Magento supports PHP 5.6.5, 7.0.2, 7.0.4, and 7.0.6 or later. ' .
echo 'Magento supports 7.0.2, 7.0.4, and 7.0.6 or later. ' .
'Please read http://devdocs.magento.com/guides/v1.0/install-gde/system-requirements.html';
} else {
echo <<<HTML
<div style="font:12px/1.35em arial, helvetica, sans-serif;">
<p>Magento supports PHP 5.6.5, 7.0.2, 7.0.4, and 7.0.6 or later. Please read
<p>Magento supports PHP 7.0.2, 7.0.4, and 7.0.6 or later. Please read
<a target="_blank" href="http://devdocs.magento.com/guides/v1.0/install-gde/system-requirements.html">
Magento System Requirements</a>.
</div>
Expand All @@ -28,6 +28,9 @@
}

require_once __DIR__ . '/autoload.php';
// Sets default autoload mappings, may be overridden in Bootstrap::create
\Magento\Framework\App\Bootstrap::populateAutoloader(BP, []);

require_once BP . '/app/functions.php';

/* Custom umask value may be provided in optional mage_umask file in root */
Expand Down Expand Up @@ -59,6 +62,6 @@

date_default_timezone_set('UTC');

/* Adjustment of precision value for several versions of PHP */
ini_set('precision', 17);
ini_set('serialize_precision', 17);
/* For data consistency between displaying (printing) and serialization a float number */
ini_set('precision', 14);
ini_set('serialize_precision', 14);
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,6 @@
* See COPYING.txt for license details.
*/

// @codingStandardsIgnoreFile

namespace Magento\AdminNotification\Block\Grid\Renderer;

class Actions extends \Magento\Backend\Block\Widget\Grid\Column\Renderer\AbstractRenderer
Expand Down Expand Up @@ -39,9 +37,8 @@ public function __construct(
*/
public function render(\Magento\Framework\DataObject $row)
{
$readDetailsHtml = $row->getUrl() ? '<a class="action-details" target="_blank" href="' . $row->getUrl() . '">' . __(
'Read Details'
) . '</a>' : '';
$readDetailsHtml = $row->getUrl() ? '<a class="action-details" target="_blank" href="' . $row->getUrl() . '">' .
__('Read Details') . '</a>' : '';

$markAsReadHtml = !$row->getIsRead() ? '<a class="action-mark" href="' . $this->getUrl(
'*/*/markAsRead/',
Expand Down
4 changes: 4 additions & 0 deletions app/code/Magento/AdminNotification/Block/Inbox.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@
*/
namespace Magento\AdminNotification\Block;

/**
* @api
* @since 100.0.2
*/
class Inbox extends \Magento\Backend\Block\Widget\Grid\Container
{
/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@

use Magento\Framework\Notification\MessageInterface;

/**
* @api
* @since 100.0.2
*/
class UnreadMessagePopup extends \Magento\Backend\Block\Template
{
/**
Expand Down
4 changes: 2 additions & 2 deletions app/code/Magento/AdminNotification/Block/ToolbarEntry.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,14 @@
* See COPYING.txt for license details.
*/

// @codingStandardsIgnoreFile

namespace Magento\AdminNotification\Block;

/**
* Toolbar entry that shows latest notifications
*
* @api
* @author Magento Core Team <[email protected]>
* @since 100.0.2
*/
class ToolbarEntry extends \Magento\Backend\Block\Template
{
Expand Down
4 changes: 4 additions & 0 deletions app/code/Magento/AdminNotification/Block/Window.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@
*/
namespace Magento\AdminNotification\Block;

/**
* @api
* @since 100.0.2
*/
class Window extends \Magento\Backend\Block\Template
{
/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@
*/
namespace Magento\AdminNotification\Controller\Adminhtml;

/**
* @api
* @since 100.0.2
*/
abstract class Notification extends \Magento\Backend\App\AbstractAction
{
/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,35 @@
*/
namespace Magento\AdminNotification\Controller\Adminhtml\Notification;

use Magento\Backend\App\Action;
use Magento\Framework\Controller\ResultFactory;

class AjaxMarkAsRead extends \Magento\AdminNotification\Controller\Adminhtml\Notification
{
/**
* @var \Magento\AdminNotification\Model\NotificationService
*/
private $notificationService;

/**
* @param Action\Context $context
* @param \Magento\AdminNotification\Model\NotificationService|null $notificationService
* @throws \RuntimeException
*/
public function __construct(
Action\Context $context,
\Magento\AdminNotification\Model\NotificationService $notificationService = null
) {
parent::__construct($context);
$this->notificationService = $notificationService?: \Magento\Framework\App\ObjectManager::getInstance()
->get(\Magento\AdminNotification\Model\NotificationService::class);
}

/**
* Mark notification as read (AJAX action)
*
* @return void
* @return \Magento\Framework\Controller\Result\Json|void
* @throws \InvalidArgumentException
*/
public function execute()
{
Expand All @@ -21,17 +44,15 @@ public function execute()
$notificationId = (int)$this->getRequest()->getPost('id');
$responseData = [];
try {
$this->_objectManager->create(
\Magento\AdminNotification\Model\NotificationService::class
)->markAsRead(
$notificationId
);
$this->notificationService->markAsRead($notificationId);
$responseData['success'] = true;
} catch (\Exception $e) {
$responseData['success'] = false;
}
$this->getResponse()->representJson(
$this->_objectManager->create(\Magento\Framework\Json\Helper\Data::class)->jsonEncode($responseData)
);

/** @var \Magento\Framework\Controller\Result\Json $resultJson */
$resultJson = $this->resultFactory->create(ResultFactory::TYPE_JSON);
$resultJson->setData($responseData);
return $resultJson;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@
* AdminNotification update frequency source
*
* @codeCoverageIgnore
* @api
* @since 100.0.2
*/
class Frequency implements \Magento\Framework\Option\ArrayInterface
{
Expand Down
2 changes: 2 additions & 0 deletions app/code/Magento/AdminNotification/Model/Feed.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
*
* @author Magento Core Team <[email protected]>
* @SuppressWarnings(PHPMD.CouplingBetweenObjects)
* @api
* @since 100.0.2
*/
class Feed extends \Magento\Framework\Model\AbstractModel
{
Expand Down
5 changes: 2 additions & 3 deletions app/code/Magento/AdminNotification/Model/Inbox.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,6 @@
/**
* AdminNotification Inbox model
*
* @method \Magento\AdminNotification\Model\ResourceModel\Inbox _getResource()
* @method \Magento\AdminNotification\Model\ResourceModel\Inbox getResource()
* @method int getSeverity()
* @method \Magento\AdminNotification\Model\Inbox setSeverity(int $value)
* @method string getDateAdded()
Expand All @@ -29,7 +27,8 @@
* @method int getIsRemove()
* @method \Magento\AdminNotification\Model\Inbox setIsRemove(int $value)
*
* @author Magento Core Team <[email protected]>
* @api
* @since 100.0.2
*/
class Inbox extends \Magento\Framework\Model\AbstractModel implements NotifierInterface, InboxInterface
{
Expand Down
Loading

0 comments on commit 0a69b5b

Please sign in to comment.