diff --git a/.all-contributorsrc b/.all-contributorsrc index afa28c9019c..78f3e5e8078 100644 --- a/.all-contributorsrc +++ b/.all-contributorsrc @@ -9,6 +9,7 @@ "imageSize": 100, "commit": true, "commitConvention": "none", + "contributorTemplate": "\">\" loading=\"lazy\" width=\"<%= options.imageSize %>\" alt=\"\"/>
<%= contributor.name %>
", "contributors": [ { "login": "sreichel", @@ -1308,7 +1309,25 @@ "contributions": [ "code" ] + }, + { + "login": "nimasan", + "name": "Benjamin MARROT", + "avatar_url": "https://avatars.githubusercontent.com/u/5030086?v=4", + "profile": "https://www.developpeur-web-tlse.fr/", + "contributions": [ + "doc" + ] + }, + { + "login": "tmewes", + "name": "Tino Mewes", + "avatar_url": "https://avatars.githubusercontent.com/u/12640514?v=4", + "profile": "https://github.com/tmewes", + "contributions": [ + "code" + ] } ], "contributorsPerLine": 7 -} +} \ No newline at end of file diff --git a/.github/phpstan-baseline.neon b/.github/phpstan-baseline.neon new file mode 100644 index 00000000000..a01cd5da26b --- /dev/null +++ b/.github/phpstan-baseline.neon @@ -0,0 +1,1157 @@ +parameters: + ignoreErrors: + - + message: "#^Method Mage_Adminhtml_Block_Backup\\:\\:_prepareLayout\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Backup\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Backup.php + + - + message: "#^Method Mage_Adminhtml_Block_Backup_Dialogs\\:\\:_prepareLayout\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Backup_Dialogs\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Backup/Dialogs.php + + - + message: "#^Method Mage_Adminhtml_Block_Catalog_Category_Checkboxes_Tree\\:\\:_prepareLayout\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Catalog_Category_Checkboxes_Tree\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Catalog/Category/Checkboxes/Tree.php + + - + message: "#^Method Mage_Adminhtml_Block_Catalog_Category_Tab_Attributes\\:\\:_prepareLayout\\(\\) should return Mage_Core_Block_Abstract but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Catalog/Category/Tab/Attributes.php + + - + message: "#^Method Mage_Adminhtml_Block_Catalog_Category_Tab_Design\\:\\:_prepareLayout\\(\\) should return Mage_Core_Block_Abstract but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Catalog/Category/Tab/Design.php + + - + message: "#^Method Mage_Adminhtml_Block_Catalog_Category_Tab_General\\:\\:_prepareLayout\\(\\) should return Mage_Core_Block_Abstract but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Catalog/Category/Tab/General.php + + - + message: "#^Method Mage_Adminhtml_Block_Catalog_Form\\:\\:_prepareLayout\\(\\) should return Mage_Core_Block_Abstract but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Catalog/Form.php + + - + message: "#^Method Mage_Adminhtml_Block_Catalog_Product_Attribute_New_Product_Attributes\\:\\:_prepareForm\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Catalog_Product_Attribute_New_Product_Attributes\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Catalog/Product/Attribute/New/Product/Attributes.php + + - + message: "#^Method Mage_Adminhtml_Block_Catalog_Product_Attribute_New_Product_Created\\:\\:_prepareLayout\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Catalog_Product_Attribute_New_Product_Created\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Catalog/Product/Attribute/New/Product/Created.php + + - + message: "#^Method Mage_Adminhtml_Block_Catalog_Product_Attribute_Set_Main_Formattribute\\:\\:_prepareForm\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Catalog_Product_Attribute_Set_Main_Formattribute\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Catalog/Product/Attribute/Set/Main/Formattribute.php + + - + message: "#^Method Mage_Adminhtml_Block_Catalog_Product_Attribute_Set_Main_Formgroup\\:\\:_prepareForm\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Catalog_Product_Attribute_Set_Main_Formgroup\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Catalog/Product/Attribute/Set/Main/Formgroup.php + + - + message: "#^Method Mage_Adminhtml_Block_Catalog_Product_Attribute_Set_Main_Formset\\:\\:_prepareForm\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Catalog_Product_Attribute_Set_Main_Formset\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Catalog/Product/Attribute/Set/Main/Formset.php + + - + message: "#^Method Mage_Adminhtml_Block_Catalog_Product_Attribute_Set_Toolbar_Main_Filter\\:\\:_prepareForm\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Catalog_Product_Attribute_Set_Toolbar_Main_Filter\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Catalog/Product/Attribute/Set/Toolbar/Main/Filter.php + + - + message: "#^Method Mage_Adminhtml_Block_Catalog_Product_Created\\:\\:_prepareLayout\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Catalog_Product_Created\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Catalog/Product/Created.php + + - + message: "#^Method Mage_Adminhtml_Block_Catalog_Product_Edit_Action_Attribute\\:\\:_prepareLayout\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Catalog_Product_Edit_Action_Attribute\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Catalog/Product/Edit/Action/Attribute.php + + - + message: "#^Method Mage_Adminhtml_Block_Catalog_Product_Edit_Action_Attribute_Tab_Attributes\\:\\:_prepareForm\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Catalog_Product_Edit_Action_Attribute_Tab_Attributes\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Catalog/Product/Edit/Action/Attribute/Tab/Attributes.php + + - + message: "#^Method Mage_Adminhtml_Block_Catalog_Product_Edit_Tab_Attributes\\:\\:_prepareLayout\\(\\) should return Mage_Core_Block_Abstract but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Catalog/Product/Edit/Tab/Attributes.php + + - + message: "#^Method Mage_Adminhtml_Block_Catalog_Product_Edit_Tab_Price\\:\\:_prepareForm\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Catalog_Product_Edit_Tab_Price\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Catalog/Product/Edit/Tab/Price.php + + - + message: "#^Method Mage_Adminhtml_Block_Catalog_Product_Edit_Tab_Settings\\:\\:_prepareForm\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Catalog_Product_Edit_Tab_Settings\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Catalog/Product/Edit/Tab/Settings.php + + - + message: "#^Method Mage_Adminhtml_Block_Catalog_Product_Edit_Tab_Super_Settings\\:\\:_prepareLayout\\(\\) should return Mage_Core_Block_Abstract but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Catalog/Product/Edit/Tab/Super/Settings.php + + - + message: "#^Method Mage_Adminhtml_Block_Catalog_Product_Edit_Tabs_Configurable\\:\\:_prepareLayout\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Catalog_Product_Edit_Tabs_Configurable\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Catalog/Product/Edit/Tabs/Configurable.php + + - + message: "#^Method Mage_Adminhtml_Block_Catalog_Product_Edit_Tabs_Grouped\\:\\:_prepareLayout\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Catalog_Product_Edit_Tabs_Grouped\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Catalog/Product/Edit/Tabs/Grouped.php + + - + message: "#^Method Mage_Adminhtml_Block_Catalog_Product_Widget_Chooser\\:\\:getCheckboxCheckCallback\\(\\) should return string but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Catalog/Product/Widget/Chooser.php + + - + message: "#^Method Mage_Adminhtml_Block_Catalog_Product_Widget_Chooser\\:\\:getRowClickCallback\\(\\) should return string but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Catalog/Product/Widget/Chooser.php + + - + message: "#^Method Mage_Adminhtml_Block_Cms_Block_Edit_Form\\:\\:_prepareLayout\\(\\) should return Mage_Core_Block_Abstract but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Cms/Block/Edit/Form.php + + - + message: "#^Method Mage_Adminhtml_Block_Cms_Page_Edit_Tab_Content\\:\\:_prepareLayout\\(\\) should return Mage_Core_Block_Abstract but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Cms/Page/Edit/Tab/Content.php + + - + message: "#^Result of method Mage_Adminhtml_Block_Cms_Wysiwyg_Images_Content\\:\\:getDeleteFilesUrl\\(\\) \\(void\\) is used\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Cms/Wysiwyg/Images/Content.php + + - + message: "#^Method Mage_Adminhtml_Block_Customer_Edit_Tab_View_Accordion\\:\\:_prepareLayout\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Customer_Edit_Tab_View_Accordion\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Customer/Edit/Tab/View/Accordion.php + + - + message: "#^Method Mage_Adminhtml_Block_Customer_Group_Edit_Form\\:\\:_prepareLayout\\(\\) should return Mage_Core_Block_Abstract but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Customer/Group/Edit/Form.php + + - + message: "#^Method Mage_Adminhtml_Block_Dashboard\\:\\:_prepareLayout\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Dashboard\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Dashboard.php + + - + message: "#^Method Mage_Adminhtml_Block_Dashboard_Sales\\:\\:_prepareLayout\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Dashboard_Sales\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Dashboard/Sales.php + + - + message: "#^Method Mage_Adminhtml_Block_Dashboard_Totals\\:\\:_prepareLayout\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Dashboard_Totals\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Dashboard/Totals.php + + - + message: "#^Method Mage_Adminhtml_Block_Permissions_Tab_Useredit\\:\\:_prepareForm\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Permissions_Tab_Useredit\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Permissions/Tab/Useredit.php + + - + message: "#^Method Mage_Adminhtml_Block_Poll_Answer_Edit_Form\\:\\:_prepareForm\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Poll_Answer_Edit_Form\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Poll/Answer/Edit/Form.php + + - + message: "#^Method Mage_Adminhtml_Block_Poll_Edit_Tab_Answers_Form\\:\\:_prepareForm\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Poll_Edit_Tab_Answers_Form\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Poll/Edit/Tab/Answers/Form.php + + - + message: "#^Method Mage_Adminhtml_Block_Report_Customer_Accounts_Grid\\:\\:_prepareCollection\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Report_Customer_Accounts_Grid\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Report/Customer/Accounts/Grid.php + + - + message: "#^Method Mage_Adminhtml_Block_Report_Customer_Orders_Grid\\:\\:_prepareCollection\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Report_Customer_Orders_Grid\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Report/Customer/Orders/Grid.php + + - + message: "#^Method Mage_Adminhtml_Block_Report_Customer_Totals_Grid\\:\\:_prepareCollection\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Report_Customer_Totals_Grid\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Report/Customer/Totals/Grid.php + + - + message: "#^Method Mage_Adminhtml_Block_Report_Grid\\:\\:_prepareCollection\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Report_Grid\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Report/Grid.php + + - + message: "#^Method Mage_Adminhtml_Block_Report_Product_Ordered_Grid\\:\\:_prepareCollection\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Report_Product_Ordered_Grid\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Report/Product/Ordered/Grid.php + + - + message: "#^Method Mage_Adminhtml_Block_Review_Add_Form\\:\\:_prepareForm\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Review_Add_Form\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Review/Add/Form.php + + - + message: "#^Method Mage_Adminhtml_Block_Review_Grid\\:\\:_prepareMassaction\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Review_Grid\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Review/Grid.php + + - + message: "#^Method Mage_Adminhtml_Block_Review_Grid_Renderer_Type\\:\\:render\\(\\) should return string but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Review/Grid/Renderer/Type.php + + - + message: "#^Method Mage_Adminhtml_Block_Sales_Order_Comments_View\\:\\:_beforeToHtml\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Sales_Order_Comments_View\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Sales/Order/Comments/View.php + + - + message: "#^Undefined variable\\: \\$info$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Sales/Order/Create/Items/Grid.php + + - + message: "#^Method Mage_Adminhtml_Block_Sales_Order_Create_Messages\\:\\:_prepareLayout\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Sales_Order_Create_Messages\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Sales/Order/Create/Messages.php + + - + message: "#^Method Mage_Adminhtml_Block_Sales_Order_Invoice_Create_Tracking\\:\\:_prepareLayout\\(\\) should return Mage_Adminhtml_Block_Sales_Order_View_Giftmessage but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Sales/Order/Invoice/Create/Tracking.php + + - + message: "#^Method Mage_Adminhtml_Block_Sales_Order_Payment\\:\\:_beforeToHtml\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Sales_Order_Payment\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Sales/Order/Payment.php + + - + message: "#^Method Mage_Adminhtml_Block_Sales_Order_Shipment_Create_Form\\:\\:_prepareLayout\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Sales_Order_Shipment_Create_Form\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Sales/Order/Shipment/Create/Form.php + + - + message: "#^Method Mage_Adminhtml_Block_Sales_Order_Shipment_Create_Tracking\\:\\:_prepareLayout\\(\\) should return Mage_Adminhtml_Block_Sales_Order_View_Giftmessage but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Sales/Order/Shipment/Create/Tracking.php + + - + message: "#^Method Mage_Adminhtml_Block_Sales_Order_Shipment_View_Tracking\\:\\:_prepareLayout\\(\\) should return Mage_Adminhtml_Block_Sales_Order_View_Giftmessage but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Sales/Order/Shipment/View/Tracking.php + + - + message: "#^Method Mage_Adminhtml_Block_Sales_Order_Totalbar\\:\\:_beforeToHtml\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Sales_Order_Totalbar\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Sales/Order/Totalbar.php + + - + message: "#^Method Mage_Adminhtml_Block_Sales_Order_View_Giftmessage\\:\\:_beforeToHtml\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Sales_Order_View_Giftmessage\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Sales/Order/View/Giftmessage.php + + - + message: "#^Method Mage_Adminhtml_Block_Sales_Order_View_Info\\:\\:_beforeToHtml\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Sales_Order_View_Info\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Sales/Order/View/Info.php + + - + message: "#^Method Mage_Adminhtml_Block_Sales_Order_View_Items\\:\\:_beforeToHtml\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Sales_Order_View_Items\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Sales/Order/View/Items.php + + - + message: "#^Method Mage_Adminhtml_Block_System_Design_Edit_Tab_General\\:\\:_prepareForm\\(\\) should return \\$this\\(Mage_Adminhtml_Block_System_Design_Edit_Tab_General\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/System/Design/Edit/Tab/General.php + + - + message: "#^Method Mage_Adminhtml_Block_Urlrewrite_Link\\:\\:_toHtml\\(\\) should return string but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Urlrewrite/Link.php + + - + message: "#^Method Mage_Adminhtml_Block_Widget_Grid_Column_Renderer_Options\\:\\:render\\(\\) should return string but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Widget/Grid/Column/Renderer/Options.php + + - + message: "#^Method Mage_Adminhtml_Block_Widget_Tabs\\:\\:addTabAfter\\(\\) should return Mage_Adminhtml_Block_Widget_Tabs but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Block/Widget/Tabs.php + + - + message: "#^Undefined variable\\: \\$pdf$#" + count: 2 + path: ../app/code/core/Mage/Adminhtml/Controller/Sales/Creditmemo.php + + - + message: "#^Undefined variable\\: \\$pdf$#" + count: 2 + path: ../app/code/core/Mage/Adminhtml/Controller/Sales/Invoice.php + + - + message: "#^Undefined variable\\: \\$pdf$#" + count: 2 + path: ../app/code/core/Mage/Adminhtml/Controller/Sales/Shipment.php + + - + message: "#^Method Mage_Adminhtml_Helper_Catalog_Product_Composite\\:\\:renderConfigureResult\\(\\) should return \\$this\\(Mage_Adminhtml_Helper_Catalog_Product_Composite\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Helper/Catalog/Product/Composite.php + + - + message: "#^Method Mage_Adminhtml_Helper_Catalog_Product_Composite\\:\\:renderUpdateResult\\(\\) should return \\$this\\(Mage_Adminhtml_Helper_Catalog_Product_Composite\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Helper/Catalog/Product/Composite.php + + - + message: "#^Method Mage_Adminhtml_Model_Config\\:\\:getSection\\(\\) should return Varien_Simplexml_Element but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Model/Config.php + + - + message: "#^Method Mage_Adminhtml_Model_System_Config_Backend_Baseurl\\:\\:_afterSave\\(\\) should return \\$this\\(Mage_Adminhtml_Model_System_Config_Backend_Baseurl\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Model/System/Config/Backend/Baseurl.php + + - + message: "#^Method Mage_Adminhtml_Model_System_Config_Backend_Cache\\:\\:_afterSave\\(\\) should return \\$this\\(Mage_Adminhtml_Model_System_Config_Backend_Cache\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Model/System/Config/Backend/Cache.php + + - + message: "#^Method Mage_Adminhtml_Model_System_Config_Backend_Currency_Cron\\:\\:_afterSave\\(\\) should return \\$this\\(Mage_Adminhtml_Model_System_Config_Backend_Currency_Cron\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Model/System/Config/Backend/Currency/Cron.php + + - + message: "#^Method Mage_Adminhtml_Model_System_Config_Backend_Datashare\\:\\:_afterSave\\(\\) should return \\$this\\(Mage_Adminhtml_Model_System_Config_Backend_Datashare\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Model/System/Config/Backend/Datashare.php + + - + message: "#^Method Mage_Adminhtml_Model_System_Config_Backend_Design_Package\\:\\:_beforeSave\\(\\) should return \\$this\\(Mage_Adminhtml_Model_System_Config_Backend_Design_Package\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Model/System/Config/Backend/Design/Package.php + + - + message: "#^Method Mage_Adminhtml_Model_System_Config_Backend_Encrypted\\:\\:_afterLoad\\(\\) should return \\$this\\(Mage_Adminhtml_Model_System_Config_Backend_Encrypted\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Model/System/Config/Backend/Encrypted.php + + - + message: "#^Method Mage_Adminhtml_Model_System_Config_Backend_Encrypted\\:\\:_beforeSave\\(\\) should return \\$this\\(Mage_Adminhtml_Model_System_Config_Backend_Encrypted\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Model/System/Config/Backend/Encrypted.php + + - + message: "#^Inner named functions are not supported by PHPStan\\. Consider refactoring to an anonymous function, class method, or a top\\-level\\-defined function\\. See issue \\#165 \\(https\\://github\\.com/phpstan/phpstan/issues/165\\) for more details\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Model/System/Config/Backend/Locale.php + + - + message: "#^Method Mage_Adminhtml_Model_System_Config_Backend_Log_Cron\\:\\:_afterSave\\(\\) should return \\$this\\(Mage_Adminhtml_Model_System_Config_Backend_Log_Cron\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Model/System/Config/Backend/Log/Cron.php + + - + message: "#^Method Mage_Adminhtml_Model_System_Config_Backend_Product_Alert_Cron\\:\\:_afterSave\\(\\) should return \\$this\\(Mage_Adminhtml_Model_System_Config_Backend_Product_Alert_Cron\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Model/System/Config/Backend/Product/Alert/Cron.php + + - + message: "#^Method Mage_Adminhtml_Model_System_Config_Backend_Secure\\:\\:_afterSave\\(\\) should return \\$this\\(Mage_Adminhtml_Model_System_Config_Backend_Secure\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Model/System/Config/Backend/Secure.php + + - + message: "#^Method Mage_Adminhtml_Model_System_Config_Backend_Serialized\\:\\:_afterLoad\\(\\) should return \\$this\\(Mage_Adminhtml_Model_System_Config_Backend_Serialized\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Model/System/Config/Backend/Serialized.php + + - + message: "#^Method Mage_Adminhtml_Model_System_Config_Backend_Serialized\\:\\:_beforeSave\\(\\) should return \\$this\\(Mage_Adminhtml_Model_System_Config_Backend_Serialized\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Model/System/Config/Backend/Serialized.php + + - + message: "#^Method Mage_Adminhtml_Model_System_Config_Backend_Shipping_Tablerate\\:\\:_afterSave\\(\\) should return \\$this\\(Mage_Adminhtml_Model_System_Config_Backend_Shipping_Tablerate\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Model/System/Config/Backend/Shipping/Tablerate.php + + - + message: "#^Method Mage_Adminhtml_Model_System_Config_Backend_Sitemap_Cron\\:\\:_afterSave\\(\\) should return \\$this\\(Mage_Adminhtml_Model_System_Config_Backend_Sitemap_Cron\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Model/System/Config/Backend/Sitemap/Cron.php + + - + message: "#^Method Mage_Adminhtml_Model_System_Config_Backend_Store\\:\\:_afterSave\\(\\) should return \\$this\\(Mage_Adminhtml_Model_System_Config_Backend_Store\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Model/System/Config/Backend/Store.php + + - + message: "#^Method Mage_Adminhtml_Model_Url\\:\\:renewSecretUrls\\(\\) should return \\$this\\(Mage_Adminhtml_Model_Url\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/Model/Url.php + + - + message: "#^Method Mage_Adminhtml_Catalog_Product_AttributeController\\:\\:preDispatch\\(\\) should return \\$this\\(Mage_Adminhtml_Catalog_Product_AttributeController\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/controllers/Catalog/Product/AttributeController.php + + - + message: "#^Method Mage_Adminhtml_CustomerController\\:\\:cartAction\\(\\) should return string but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/controllers/CustomerController.php + + - + message: "#^Method Mage_Adminhtml_JsonController\\:\\:countryRegionAction\\(\\) should return string but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/controllers/JsonController.php + + - + message: "#^Method Mage_Adminhtml_Sales_Order_CreditmemoController\\:\\:_needToAddDummy\\(\\) should return bool but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/controllers/Sales/Order/CreditmemoController.php + + - + message: "#^Method Mage_Adminhtml_Sales_Order_InvoiceController\\:\\:_needToAddDummy\\(\\) should return bool but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/controllers/Sales/Order/InvoiceController.php + + - + message: "#^Method Mage_Adminhtml_Sales_Order_InvoiceController\\:\\:_needToAddDummyForShipment\\(\\) should return bool but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/controllers/Sales/Order/InvoiceController.php + + - + message: "#^Undefined variable\\: \\$shippingResponse$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/controllers/Sales/Order/InvoiceController.php + + - + message: "#^Method Mage_Adminhtml_Sales_Order_ShipmentController\\:\\:_needToAddDummy\\(\\) should return bool but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/controllers/Sales/Order/ShipmentController.php + + - + message: "#^Method Mage_Adminhtml_System_ConfigController\\:\\:_isSectionAllowed\\(\\) should return bool but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/controllers/System/ConfigController.php + + - + message: "#^Method Mage_Adminhtml_Tax_RateController\\:\\:deleteAction\\(\\) should return bool but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/controllers/Tax/RateController.php + + - + message: "#^Method Mage_Adminhtml_Tax_RateController\\:\\:saveAction\\(\\) should return bool but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/controllers/Tax/RateController.php + + - + message: "#^Method Mage_Adminhtml_Tax_RuleController\\:\\:saveAction\\(\\) should return Mage_Core_Controller_Response_Http\\|Mage_Core_Controller_Varien_Action but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Adminhtml/controllers/Tax/RuleController.php + + - + message: "#^Method Mage_Core_Model_Resource_Db_Abstract\\:\\:load\\(\\) invoked with 1 parameter, 2\\-3 required\\.$#" + count: 1 + path: ../app/code/core/Mage/Api/Model/Resource/Roles.php + + - + message: "#^Method Mage_Api2_Block_Adminhtml_Attribute_Grid\\:\\:_prepareCollection\\(\\) should return \\$this\\(Mage_Api2_Block_Adminhtml_Attribute_Grid\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Api2/Block/Adminhtml/Attribute/Grid.php + + - + message: "#^Method Mage_Api2_Block_Adminhtml_Roles_Tab_Info\\:\\:_prepareForm\\(\\) should return \\$this\\(Mage_Api2_Block_Adminhtml_Roles_Tab_Info\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Api2/Block/Adminhtml/Roles/Tab/Info.php + + - + message: "#^Method Mage_Api2_Model_Acl_Global_Rule_ResourcePermission\\:\\:setFilterValue\\(\\) should return Mage_Api2_Model_Acl_PermissionInterface but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Api2/Model/Acl/Global/Rule/ResourcePermission.php + + - + message: "#^Call to an undefined method Mage_Api2_Model_Resource\\:\\:_multiDelete\\(\\)\\.$#" + count: 1 + path: ../app/code/core/Mage/Api2/Model/Resource.php + + - + message: "#^Method Mage_Authorizenet_Model_Directpost\\:\\:authorize\\(\\) should return Mage_Paygate_Model_Authorizenet but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Authorizenet/Model/Directpost.php + + - + message: "#^Method Mage_Authorizenet_Model_Directpost\\:\\:initialize\\(\\) should return \\$this\\(Mage_Authorizenet_Model_Directpost\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Authorizenet/Model/Directpost.php + + - + message: "#^Method Mage_Backup_Model_Config_Backend_Cron\\:\\:_afterSave\\(\\) should return Mage_Adminhtml_Model_System_Config_Backend_Log_Cron but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Backup/Model/Config/Backend/Cron.php + + - + message: "#^Result of method Mage_Bundle_Block_Catalog_Product_View_Type_Bundle_Option\\:\\:_getSelectedOptions\\(\\) \\(void\\) is used\\.$#" + count: 4 + path: ../app/code/core/Mage/Bundle/Block/Catalog/Product/View/Type/Bundle/Option.php + + - + message: "#^Call to an undefined method Mage_Bundle_Model_Product_Price\\:\\:getPricesTierPrice\\(\\)\\.$#" + count: 2 + path: ../app/code/core/Mage/Bundle/Model/Product/Price.php + + - + message: "#^Method Mage_Bundle_Model_Product_Type\\:\\:beforeSave\\(\\) should return Mage_Catalog_Model_Product_Type_Abstract but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Bundle/Model/Product/Type.php + + - + message: "#^Method Mage_Bundle_Model_Resource_Selection_Collection\\:\\:_initSelect\\(\\) should return \\$this\\(Mage_Bundle_Model_Resource_Selection_Collection\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Bundle/Model/Resource/Selection/Collection.php + + - + message: "#^Method Mage_Catalog_Block_Product_View_Options_Type_Select\\:\\:getValuesHtml\\(\\) should return string but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Catalog/Block/Product/View/Options/Type/Select.php + + - + message: "#^Method Mage_Catalog_Block_Product_View_Tabs\\:\\:addTab\\(\\) should return bool but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Catalog/Block/Product/View/Tabs.php + + - + message: "#^Call to an undefined method Mage_Catalog_Model_Api_Resource\\:\\:_checkAttributeAcl\\(\\)\\.$#" + count: 1 + path: ../app/code/core/Mage/Catalog/Model/Api/Resource.php + + - + message: "#^Method Mage_Catalog_Model_Api2_Product_Image_Rest_Admin_V1\\:\\:_create\\(\\) should return string but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Catalog/Model/Api2/Product/Image/Rest/Admin/V1.php + + - + message: "#^Method Mage_Catalog_Model_Api2_Product_Validator_Product\\:\\:_validateAttributeSet\\(\\) should return bool but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Catalog/Model/Api2/Product/Validator/Product.php + + - + message: "#^Method Mage_Catalog_Model_Api2_Product_Validator_Product\\:\\:_validateProductType\\(\\) should return bool but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Catalog/Model/Api2/Product/Validator/Product.php + + - + message: "#^Method Mage_Catalog_Model_Api2_Product_Validator_Product\\:\\:_validateSku\\(\\) should return bool but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Catalog/Model/Api2/Product/Validator/Product.php + + - + message: "#^Method Mage_Catalog_Model_Category_Attribute_Backend_Image\\:\\:afterSave\\(\\) should return \\$this\\(Mage_Catalog_Model_Category_Attribute_Backend_Image\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Catalog/Model/Category/Attribute/Backend/Image.php + + - + message: "#^Call to an undefined method Mage_Catalog_Model_Config\\:\\:_init\\(\\)\\.$#" + count: 1 + path: ../app/code/core/Mage/Catalog/Model/Config.php + + - + message: "#^Method Mage_Catalog_Model_Config\\:\\:getAttributeSetId\\(\\) invoked with 1 parameter, 2 required\\.$#" + count: 2 + path: ../app/code/core/Mage/Catalog/Model/Config.php + + - + message: "#^Method Mage_Catalog_Model_Product\\:\\:_afterDeleteCommit\\(\\) should return \\$this\\(Mage_Catalog_Model_Product\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Catalog/Model/Product.php + + - + message: "#^Method Mage_Catalog_Model_Product\\:\\:_beforeSave\\(\\) should return \\$this\\(Mage_Catalog_Model_Product\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Catalog/Model/Product.php + + - + message: "#^Method Mage_Catalog_Model_Product_Attribute_Api\\:\\:remove\\(\\) should return bool but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Catalog/Model/Product/Attribute/Api.php + + - + message: "#^Method Mage_Catalog_Model_Product_Attribute_Backend_Media\\:\\:afterLoad\\(\\) should return \\$this\\(Mage_Catalog_Model_Product_Attribute_Backend_Media\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Catalog/Model/Product/Attribute/Backend/Media.php + + - + message: "#^Method Mage_Catalog_Model_Product_Attribute_Backend_Recurring\\:\\:_unserialize\\(\\) should return \\$this\\(Mage_Catalog_Model_Product_Attribute_Backend_Recurring\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Catalog/Model/Product/Attribute/Backend/Recurring.php + + - + message: "#^Method Mage_Catalog_Model_Product_Attribute_Backend_Recurring\\:\\:beforeSave\\(\\) should return \\$this\\(Mage_Catalog_Model_Product_Attribute_Backend_Recurring\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Catalog/Model/Product/Attribute/Backend/Recurring.php + + - + message: "#^Method Mage_Catalog_Model_Product_Option_Type_File\\:\\:_validateFile\\(\\) should return bool but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Catalog/Model/Product/Option/Type/File.php + + - + message: "#^Method Mage_Catalog_Model_Product_Option_Type_File\\:\\:getCustomizedView\\(\\) should return string but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Catalog/Model/Product/Option/Type/File.php + + - + message: "#^Access to an undefined property Mage_Catalog_Model_Resource_Category_Tree\\:\\:\\$_inactiveItems\\.$#" + count: 2 + path: ../app/code/core/Mage/Catalog/Model/Resource/Category/Tree.php + + - + message: "#^Cannot call abstract method Mage_Core_Model_Resource_Abstract\\:\\:_construct\\(\\)\\.$#" + count: 1 + path: ../app/code/core/Mage/CatalogIndex/Model/Resource/Abstract.php + + - + message: "#^Method Mage_CatalogIndex_Model_Resource_Attribute\\:\\:_construct\\(\\) should return Mage_Core_Model_Resource_Db_Abstract but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/CatalogIndex/Model/Resource/Attribute.php + + - + message: "#^Method Mage_CatalogIndex_Model_Resource_Price\\:\\:_construct\\(\\) should return Mage_Core_Model_Resource_Db_Abstract but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/CatalogIndex/Model/Resource/Price.php + + - + message: "#^Method Mage_CatalogInventory_Model_System_Config_Backend_Minsaleqty\\:\\:_afterLoad\\(\\) should return \\$this\\(Mage_CatalogInventory_Model_System_Config_Backend_Minsaleqty\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/CatalogInventory/Model/System/Config/Backend/Minsaleqty.php + + - + message: "#^Method Mage_CatalogInventory_Model_System_Config_Backend_Minsaleqty\\:\\:_beforeSave\\(\\) should return \\$this\\(Mage_CatalogInventory_Model_System_Config_Backend_Minsaleqty\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/CatalogInventory/Model/System/Config/Backend/Minsaleqty.php + + - + message: "#^Method Mage_CatalogInventory_Model_System_Config_Backend_Qtyincrements\\:\\:_beforeSave\\(\\) should return \\$this\\(Mage_CatalogInventory_Model_System_Config_Backend_Qtyincrements\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/CatalogInventory/Model/System/Config/Backend/Qtyincrements.php + + - + message: "#^Method Mage_Checkout_Block_Onepage_Payment_Methods\\:\\:getMethodLabelAfterHtml\\(\\) should return string but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Checkout/Block/Onepage/Payment/Methods.php + + - + message: "#^Method Mage_Checkout_Model_Cart\\:\\:saveQuote\\(\\) should return Mage_Checkout_Model_Cart_Interface but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Checkout/Model/Cart.php + + - + message: "#^Method Mage_Checkout_Model_Session\\:\\:unsetAll\\(\\) should return \\$this\\(Mage_Checkout_Model_Session\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Checkout/Model/Session.php + + - + message: "#^Result of method Mage_ConfigurableSwatches_Helper_Mediafallback\\:\\:attachProductChildrenAttributeMapping\\(\\) \\(void\\) is used\\.$#" + count: 1 + path: ../app/code/core/Mage/ConfigurableSwatches/Helper/Mediafallback.php + + - + message: "#^Method Mage_Core_Block_Flush\\:\\:_toHtml\\(\\) should return string but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Core/Block/Flush.php + + - + message: "#^Method Mage_Core_Block_Messages\\:\\:_prepareLayout\\(\\) should return \\$this\\(Mage_Core_Block_Messages\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Core/Block/Messages.php + + - + message: "#^Result of method Mage_Core_Block_Abstract\\:\\:__construct\\(\\) \\(void\\) is used\\.$#" + count: 1 + path: ../app/code/core/Mage/Core/Block/Store/Switcher.php + + - + message: "#^Result of method Zend_Controller_Response_Abstract\\:\\:sendResponse\\(\\) \\(void\\) is used\\.$#" + count: 1 + path: ../app/code/core/Mage/Core/Controller/Response/Http.php + + - + message: "#^Undefined variable\\: \\$realModule$#" + count: 2 + path: ../app/code/core/Mage/Core/Controller/Varien/Router/Standard.php + + - + message: "#^Method Mage_Core_Model_Config_Data\\:\\:afterLoad\\(\\) should return \\$this\\(Mage_Core_Model_Config_Data\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Core/Model/Config/Data.php + + - + message: "#^Cannot unset offset '@attributes' on \\(array\\{\\}\\|array\\{\\000\\*\\000_parent\\: Varien_Simplexml_Element\\}\\)\\.$#" + count: 1 + path: ../app/code/core/Mage/Core/Model/Layout.php + + - + message: "#^Method Mage_Core_Model_Resource_Design\\:\\:_beforeSave\\(\\) should return \\$this\\(Mage_Core_Model_Resource_Design\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Core/Model/Resource/Design.php + + - + message: "#^Function mageCoreErrorHandler\\(\\) should return bool but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Core/functions.php + + - + message: "#^Function mageDebugBacktrace\\(\\) should return string but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Core/functions.php + + - + message: "#^Method Mage_Customer_Block_Address_Edit\\:\\:_prepareLayout\\(\\) should return \\$this\\(Mage_Customer_Block_Address_Edit\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Customer/Block/Address/Edit.php + + - + message: "#^Call to an undefined method Mage_Customer_Model_Api2_Customer_Address\\:\\:_getDefaultAddressesInfo\\(\\)\\.$#" + count: 1 + path: ../app/code/core/Mage/Customer/Model/Api2/Customer/Address.php + + - + message: "#^Method Mage_Customer_Model_Api2_Customer_Rest_Customer_V1\\:\\:_retrieve\\(\\) should return array but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Customer/Model/Api2/Customer/Rest/Customer/V1.php + + - + message: "#^Method Mage_Customer_Model_Customer\\:\\:printError\\(\\) should return bool but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Customer/Model/Customer.php + + - + message: "#^Method Mage_Customer_Model_Customer_Attribute_Backend_Billing\\:\\:afterSave\\(\\) should return \\$this\\(Mage_Customer_Model_Customer_Attribute_Backend_Billing\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Customer/Model/Customer/Attribute/Backend/Billing.php + + - + message: "#^Method Mage_Customer_Model_Customer_Attribute_Backend_Billing\\:\\:beforeSave\\(\\) should return \\$this\\(Mage_Customer_Model_Customer_Attribute_Backend_Billing\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Customer/Model/Customer/Attribute/Backend/Billing.php + + - + message: "#^Method Mage_Customer_Model_Customer_Attribute_Backend_Password\\:\\:beforeSave\\(\\) should return \\$this\\(Mage_Customer_Model_Customer_Attribute_Backend_Password\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Customer/Model/Customer/Attribute/Backend/Password.php + + - + message: "#^Method Mage_Customer_Model_Customer_Attribute_Backend_Shipping\\:\\:afterSave\\(\\) should return \\$this\\(Mage_Customer_Model_Customer_Attribute_Backend_Shipping\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Customer/Model/Customer/Attribute/Backend/Shipping.php + + - + message: "#^Method Mage_Customer_Model_Customer_Attribute_Backend_Shipping\\:\\:beforeSave\\(\\) should return \\$this\\(Mage_Customer_Model_Customer_Attribute_Backend_Shipping\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Customer/Model/Customer/Attribute/Backend/Shipping.php + + - + message: "#^Method Mage_Customer_AccountController\\:\\:postDispatch\\(\\) should return \\$this\\(Mage_Customer_AccountController\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Customer/controllers/AccountController.php + + - + message: "#^Method Mage_Customer_AccountController\\:\\:preDispatch\\(\\) should return \\$this\\(Mage_Customer_AccountController\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Customer/controllers/AccountController.php + + - + message: "#^Method Mage_Customer_AddressController\\:\\:preDispatch\\(\\) should return \\$this\\(Mage_Customer_AddressController\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Customer/controllers/AddressController.php + + - + message: "#^Method Mage_Dataflow_Model_Batch\\:\\:_afterDelete\\(\\) should return \\$this\\(Mage_Dataflow_Model_Batch\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Dataflow/Model/Batch.php + + - + message: "#^Method Mage_Dataflow_Model_Batch\\:\\:_beforeSave\\(\\) should return \\$this\\(Mage_Dataflow_Model_Batch\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Dataflow/Model/Batch.php + + - + message: "#^Call to an undefined method Mage_Dataflow_Model_Convert_Action_Abstract\\:\\:addException\\(\\)\\.$#" + count: 1 + path: ../app/code/core/Mage/Dataflow/Model/Convert/Action/Abstract.php + + - + message: "#^Call to an undefined method Mage_Dataflow_Model_Convert_Action_Abstract\\:\\:getClassNameByType\\(\\)\\.$#" + count: 1 + path: ../app/code/core/Mage/Dataflow/Model/Convert/Action/Abstract.php + + - + message: "#^Undefined variable\\: \\$action$#" + count: 1 + path: ../app/code/core/Mage/Dataflow/Model/Convert/Action/Abstract.php + + - + message: "#^Undefined variable\\: \\$profile$#" + count: 1 + path: ../app/code/core/Mage/Dataflow/Model/Convert/Profile/Abstract.php + + - + message: "#^Access to constant FATAL on an unknown class Mage_Dataflow_Model_Convert_Exceptin\\.$#" + count: 1 + path: ../app/code/core/Mage/Dataflow/Model/Convert/Validator/Dryrun.php + + - + message: "#^Method Mage_Dataflow_Model_Profile\\:\\:_afterLoad\\(\\) should return \\$this\\(Mage_Dataflow_Model_Profile\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Dataflow/Model/Profile.php + + - + message: "#^Method Mage_Dataflow_Model_Profile\\:\\:_afterSave\\(\\) should return \\$this\\(Mage_Dataflow_Model_Profile\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Dataflow/Model/Profile.php + + - + message: "#^Method Mage_Dataflow_Model_Profile\\:\\:_beforeSave\\(\\) should return \\$this\\(Mage_Dataflow_Model_Profile\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Dataflow/Model/Profile.php + + - + message: "#^Method Mage_Dataflow_Model_Resource_Profile\\:\\:_beforeSave\\(\\) should return \\$this\\(Mage_Dataflow_Model_Resource_Profile\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Dataflow/Model/Resource/Profile.php + + - + message: "#^Method Mage_Downloadable_Block_Adminhtml_Catalog_Product_Edit_Tab_Downloadable_Links\\:\\:_prepareLayout\\(\\) should return Mage_Core_Block_Abstract but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Downloadable/Block/Adminhtml/Catalog/Product/Edit/Tab/Downloadable/Links.php + + - + message: "#^Method Mage_Downloadable_Block_Adminhtml_Catalog_Product_Edit_Tab_Downloadable_Samples\\:\\:_prepareLayout\\(\\) should return Mage_Core_Block_Abstract but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Downloadable/Block/Adminhtml/Catalog/Product/Edit/Tab/Downloadable/Samples.php + + - + message: "#^Method Mage_Downloadable_Model_Product_Type\\:\\:beforeSave\\(\\) should return Mage_Catalog_Model_Product_Type_Abstract but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Downloadable/Model/Product/Type.php + + - + message: "#^Method Mage_Downloadable_CustomerController\\:\\:preDispatch\\(\\) should return \\$this\\(Mage_Downloadable_CustomerController\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Downloadable/controllers/CustomerController.php + + - + message: "#^Method Mage_Downloadable_FileController\\:\\:preDispatch\\(\\) should return \\$this\\(Mage_Downloadable_FileController\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Downloadable/controllers/FileController.php + + - + message: "#^Method Mage_Downloadable_Product_EditController\\:\\:preDispatch\\(\\) should return Mage_Adminhtml_Controller_Action but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Downloadable/controllers/Product/EditController.php + + - + message: "#^Access to an undefined property Mage_Eav_Model_Convert_Adapter_Grid\\:\\:\\$_entityType\\.$#" + count: 1 + path: ../app/code/core/Mage/Eav/Model/Convert/Adapter/Grid.php + + - + message: "#^Method Mage_GiftMessage_Model_Entity_Attribute_Backend_Boolean_Config\\:\\:afterLoad\\(\\) should return \\$this\\(Mage_GiftMessage_Model_Entity_Attribute_Backend_Boolean_Config\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/GiftMessage/Model/Entity/Attribute/Backend/Boolean/Config.php + + - + message: "#^Method Mage_GiftMessage_Model_Entity_Attribute_Backend_Boolean_Config\\:\\:beforeSave\\(\\) should return \\$this\\(Mage_GiftMessage_Model_Entity_Attribute_Backend_Boolean_Config\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/GiftMessage/Model/Entity/Attribute/Backend/Boolean/Config.php + + - + message: "#^Call to an undefined method Mage_GiftMessage_IndexController\\:\\:_getMappedType\\(\\)\\.$#" + count: 1 + path: ../app/code/core/Mage/GiftMessage/controllers/IndexController.php + + - + message: "#^Method Mage_Index_Block_Adminhtml_Process_Edit\\:\\:getHeaderText\\(\\) should return string but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Index/Block/Adminhtml/Process/Edit.php + + - + message: "#^Method Mage_Index_Model_Resource_Setup\\:\\:_syncIndexes\\(\\) should return \\$this\\(Mage_Index_Model_Resource_Setup\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Index/Model/Resource/Setup.php + + - + message: "#^Result of method Mage_Core_Controller_Varien_Action\\:\\:preDispatch\\(\\) \\(void\\) is used\\.$#" + count: 1 + path: ../app/code/core/Mage/Install/controllers/IndexController.php + + - + message: "#^Result of method Mage_Core_Controller_Varien_Action\\:\\:preDispatch\\(\\) \\(void\\) is used\\.$#" + count: 1 + path: ../app/code/core/Mage/Install/controllers/WizardController.php + + - + message: "#^Method Mage_Newsletter_ManageController\\:\\:preDispatch\\(\\) should return \\$this\\(Mage_Newsletter_ManageController\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Newsletter/controllers/ManageController.php + + - + message: "#^Method Mage_Newsletter_ManageController\\:\\:saveAction\\(\\) should return Mage_Newsletter_ManageController but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Newsletter/controllers/ManageController.php + + - + message: "#^Method Mage_Oauth_Customer_TokenController\\:\\:preDispatch\\(\\) should return \\$this\\(Mage_Oauth_Customer_TokenController\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Oauth/controllers/Customer/TokenController.php + + - + message: "#^Method Mage_Payment_Block_Catalog_Product_View_Profile\\:\\:getDateHtml\\(\\) should return string but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Payment/Block/Catalog/Product/View/Profile.php + + - + message: "#^Method Mage_Payment_Model_Method_Cc\\:\\:_isPlaceOrder\\(\\) should return bool but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Payment/Model/Method/Cc.php + + - + message: "#^Access to an undefined property Mage_Paypal_Controller_Express_Abstract\\:\\:\\$_checkoutType\\.$#" + count: 1 + path: ../app/code/core/Mage/Paypal/Controller/Express/Abstract.php + + - + message: "#^Access to an undefined property Mage_Paypal_Controller_Express_Abstract\\:\\:\\$_configMethod\\.$#" + count: 1 + path: ../app/code/core/Mage/Paypal/Controller/Express/Abstract.php + + - + message: "#^Access to an undefined property Mage_Paypal_Controller_Express_Abstract\\:\\:\\$_configType\\.$#" + count: 1 + path: ../app/code/core/Mage/Paypal/Controller/Express/Abstract.php + + - + message: "#^Method Mage_Paypal_Model_Api_Nvp\\:\\:_filterBillingAgreementStatus\\(\\) should return string but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Paypal/Model/Api/Nvp.php + + - + message: "#^Method Mage_Paypal_Model_Api_Nvp\\:\\:_filterPeriodUnit\\(\\) should return string but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Paypal/Model/Api/Nvp.php + + - + message: "#^Method Mage_Paypal_Model_Hostedpro\\:\\:initialize\\(\\) should return \\$this\\(Mage_Paypal_Model_Hostedpro\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Paypal/Model/Hostedpro.php + + - + message: "#^Method Mage_Paypal_Model_Observer\\:\\:fetchReports\\(\\) should return \\$this\\(Mage_Paypal_Model_Observer\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Paypal/Model/Observer.php + + - + message: "#^Method Mage_Paypal_Model_Payflowlink\\:\\:_getTrxTokenType\\(\\) should return string but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Paypal/Model/Payflowlink.php + + - + message: "#^Method Mage_Paypal_Model_Payflowlink\\:\\:initialize\\(\\) should return \\$this\\(Mage_Paypal_Model_Payflowlink\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Paypal/Model/Payflowlink.php + + - + message: "#^Method Mage_Paypal_Model_Payflowpro\\:\\:getConfigPaymentAction\\(\\) should return string but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Paypal/Model/Payflowpro.php + + - + message: "#^Method Mage_Paypal_Model_Standard\\:\\:initialize\\(\\) should return \\$this\\(Mage_Paypal_Model_Standard\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Paypal/Model/Standard.php + + - + message: "#^Method Mage_Paypal_Model_System_Config_Backend_MerchantCountry\\:\\:_afterLoad\\(\\) should return \\$this\\(Mage_Paypal_Model_System_Config_Backend_MerchantCountry\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Paypal/Model/System/Config/Backend/MerchantCountry.php + + - + message: "#^Method Mage_Poll_Model_Resource_Poll\\:\\:_afterSave\\(\\) should return \\$this\\(Mage_Poll_Model_Resource_Poll\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Poll/Model/Resource/Poll.php + + - + message: "#^Method Mage_ProductAlert_UnsubscribeController\\:\\:preDispatch\\(\\) should return \\$this\\(Mage_ProductAlert_UnsubscribeController\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/ProductAlert/controllers/UnsubscribeController.php + + - + message: "#^Call to an undefined method Mage_Reports_Model_Resource_Review_Collection\\:\\:_joinFields\\(\\)\\.$#" + count: 1 + path: ../app/code/core/Mage/Reports/Model/Resource/Review/Collection.php + + - + message: "#^Call to an undefined static method Mage_Review_Model_Resource_Review_Collection\\:\\:resetSelect\\(\\)\\.$#" + count: 1 + path: ../app/code/core/Mage/Reports/Model/Resource/Review/Collection.php + + - + message: "#^Method Mage_Review_CustomerController\\:\\:preDispatch\\(\\) should return \\$this\\(Mage_Review_CustomerController\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Review/controllers/CustomerController.php + + - + message: "#^Method Mage_Rss_Model_System_Config_Backend_Links\\:\\:_afterSave\\(\\) should return \\$this\\(Mage_Rss_Model_System_Config_Backend_Links\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Rss/Model/System/Config/Backend/Links.php + + - + message: "#^Method Mage_Adminhtml_Block_Sales_Recurring_Profile_View_Items\\:\\:_beforeToHtml\\(\\) should return \\$this\\(Mage_Adminhtml_Block_Sales_Recurring_Profile_View_Items\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Sales/Block/Adminhtml/Recurring/Profile/View/Items.php + + - + message: "#^Method Mage_Sales_Model_Billing_Agreement\\:\\:getStatusLabel\\(\\) should return string but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Sales/Model/Billing/Agreement.php + + - + message: "#^Method Mage_Sales_Model_Entity_Order_Attribute_Backend_Shipping\\:\\:afterSave\\(\\) should return \\$this\\(Mage_Sales_Model_Entity_Order_Attribute_Backend_Shipping\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Sales/Model/Entity/Order/Attribute/Backend/Shipping.php + + - + message: "#^Method Mage_Sales_Model_Entity_Order_Attribute_Backend_Shipping\\:\\:beforeSave\\(\\) should return \\$this\\(Mage_Sales_Model_Entity_Order_Attribute_Backend_Shipping\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Sales/Model/Entity/Order/Attribute/Backend/Shipping.php + + - + message: "#^Method Mage_Sales_Model_Quote_Item\\:\\:save\\(\\) should return \\$this\\(Mage_Sales_Model_Quote_Item\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Sales/Model/Quote/Item.php + + - + message: "#^Method Mage_Sales_Model_Recurring_Profile\\:\\:_getItem\\(\\) should return Mage_Sales_Model_Order_Item but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Sales/Model/Recurring/Profile.php + + - + message: "#^Method Mage_Sales_Model_Resource_Order_Attribute_Backend_Billing\\:\\:afterSave\\(\\) should return \\$this\\(Mage_Sales_Model_Resource_Order_Attribute_Backend_Billing\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Sales/Model/Resource/Order/Attribute/Backend/Billing.php + + - + message: "#^Method Mage_Sales_Model_Resource_Order_Attribute_Backend_Billing\\:\\:beforeSave\\(\\) should return \\$this\\(Mage_Sales_Model_Resource_Order_Attribute_Backend_Billing\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Sales/Model/Resource/Order/Attribute/Backend/Billing.php + + - + message: "#^Method Mage_Sales_Model_Resource_Order_Attribute_Backend_Shipping\\:\\:afterSave\\(\\) should return \\$this\\(Mage_Sales_Model_Resource_Order_Attribute_Backend_Shipping\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Sales/Model/Resource/Order/Attribute/Backend/Shipping.php + + - + message: "#^Method Mage_Sales_Model_Resource_Order_Attribute_Backend_Shipping\\:\\:beforeSave\\(\\) should return \\$this\\(Mage_Sales_Model_Resource_Order_Attribute_Backend_Shipping\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Sales/Model/Resource/Order/Attribute/Backend/Shipping.php + + - + message: "#^Method Mage_Sales_Model_Resource_Order_Invoice_Collection\\:\\:_afterLoad\\(\\) should return \\$this\\(Mage_Sales_Model_Resource_Order_Invoice_Collection\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Sales/Model/Resource/Order/Invoice/Collection.php + + - + message: "#^Access to an undefined property Mage_Sales_Model_Resource_Sale_Collection\\:\\:\\$_orderStateValue\\.$#" + count: 2 + path: ../app/code/core/Mage/Sales/Model/Resource/Sale/Collection.php + + - + message: "#^Method Mage_Sales_Model_Service_Order\\:\\:_canInvoiceItem\\(\\) should return bool but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Sales/Model/Service/Order.php + + - + message: "#^Method Mage_Sales_Model_Service_Order\\:\\:_canRefundItem\\(\\) should return bool but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Sales/Model/Service/Order.php + + - + message: "#^Method Mage_Sales_Model_Service_Order\\:\\:_canShipItem\\(\\) should return bool but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Sales/Model/Service/Order.php + + - + message: "#^Method Mage_Sales_Billing_AgreementController\\:\\:preDispatch\\(\\) should return \\$this\\(Mage_Sales_Billing_AgreementController\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Sales/controllers/Billing/AgreementController.php + + - + message: "#^Method Mage_Sales_OrderController\\:\\:preDispatch\\(\\) should return \\$this\\(Mage_Sales_OrderController\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Sales/controllers/OrderController.php + + - + message: "#^Method Mage_Sales_Recurring_ProfileController\\:\\:preDispatch\\(\\) should return \\$this\\(Mage_Sales_Recurring_ProfileController\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Sales/controllers/Recurring/ProfileController.php + + - + message: "#^Method Mage_SalesRule_Model_Observer\\:\\:sales_order_afterPlace\\(\\) should return Mage_SalesRule_Model_Observer but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/SalesRule/Model/Observer.php + + - + message: "#^Method Mage_SalesRule_Model_Resource_Report_Collection\\:\\:_applyRulesFilter\\(\\) should return \\$this\\(Mage_SalesRule_Model_Resource_Report_Collection\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/SalesRule/Model/Resource/Report/Collection.php + + - + message: "#^Access to an undefined property Mage_Tag_Model_Entity_Customer_Collection\\:\\:\\$_read\\.$#" + count: 1 + path: ../app/code/core/Mage/Tag/Model/Entity/Customer/Collection.php + + - + message: "#^Method Mage_Tag_Model_Resource_Tag\\:\\:loadByName\\(\\) should return array\\|false but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Tag/Model/Resource/Tag.php + + - + message: "#^Call to an undefined static method Mage_Core_Model_Config_Data\\:\\:afterSave\\(\\)\\.$#" + count: 1 + path: ../app/code/core/Mage/Tax/Model/Config/Price/Include.php + + - + message: "#^Method Mage_Widget_Block_Adminhtml_Widget_Form\\:\\:_prepareForm\\(\\) should return \\$this\\(Mage_Widget_Block_Adminhtml_Widget_Form\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Widget/Block/Adminhtml/Widget/Form.php + + - + message: "#^Method Mage_Wishlist_Block_Customer_Wishlist_Item_Column\\:\\:_beforeChildToHtml\\(\\) should return string but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Wishlist/Block/Customer/Wishlist/Item/Column.php + + - + message: "#^Method Mage_Wishlist_Model_Item\\:\\:save\\(\\) should return \\$this\\(Mage_Wishlist_Model_Item\\) but return statement is missing\\.$#" + count: 1 + path: ../app/code/core/Mage/Wishlist/Model/Item.php + diff --git a/.github/phpstan.neon b/.github/phpstan.neon new file mode 100644 index 00000000000..781ce0d9a0f --- /dev/null +++ b/.github/phpstan.neon @@ -0,0 +1,103 @@ +includes: + - ../vendor/macopedia/phpstan-magento1/extension.neon + - phpstan-baseline.neon +parameters: + magentoRootPath: %currentWorkingDirectory% + paths: + #lets start small with just few modules + - %currentWorkingDirectory%/app/code/core/Mage/Admin + - %currentWorkingDirectory%/app/code/core/Mage/Adminhtml + - %currentWorkingDirectory%/app/code/core/Mage/AdminNotification + - %currentWorkingDirectory%/app/code/core/Mage/Api + - %currentWorkingDirectory%/app/code/core/Mage/Api2 + - %currentWorkingDirectory%/app/code/core/Mage/Authorizenet + - %currentWorkingDirectory%/app/code/core/Mage/Backup + - %currentWorkingDirectory%/app/code/core/Mage/Bundle + - %currentWorkingDirectory%/app/code/core/Mage/Captcha + - %currentWorkingDirectory%/app/code/core/Mage/Catalog + - %currentWorkingDirectory%/app/code/core/Mage/CatalogIndex + - %currentWorkingDirectory%/app/code/core/Mage/CatalogInventory + - %currentWorkingDirectory%/app/code/core/Mage/CatalogRule + - %currentWorkingDirectory%/app/code/core/Mage/CatalogSearch +# - %currentWorkingDirectory%/app/code/core/Mage/Centinel + - %currentWorkingDirectory%/app/code/core/Mage/Checkout + - %currentWorkingDirectory%/app/code/core/Mage/Cms + - %currentWorkingDirectory%/app/code/core/Mage/ConfigurableSwatches + - %currentWorkingDirectory%/app/code/core/Mage/Contacts + - %currentWorkingDirectory%/app/code/core/Mage/Core + - %currentWorkingDirectory%/app/code/core/Mage/Cron + - %currentWorkingDirectory%/app/code/core/Mage/CurrencySymbol + - %currentWorkingDirectory%/app/code/core/Mage/Customer + - %currentWorkingDirectory%/app/code/core/Mage/Dataflow + - %currentWorkingDirectory%/app/code/core/Mage/Directory + - %currentWorkingDirectory%/app/code/core/Mage/Downloadable + - %currentWorkingDirectory%/app/code/core/Mage/Eav + - %currentWorkingDirectory%/app/code/core/Mage/GiftMessage + - %currentWorkingDirectory%/app/code/core/Mage/GoogleAnalytics + - %currentWorkingDirectory%/app/code/core/Mage/GoogleCheckout + - %currentWorkingDirectory%/app/code/core/Mage/ImportExport + - %currentWorkingDirectory%/app/code/core/Mage/Index + - %currentWorkingDirectory%/app/code/core/Mage/Install + - %currentWorkingDirectory%/app/code/core/Mage/Log + - %currentWorkingDirectory%/app/code/core/Mage/Media + - %currentWorkingDirectory%/app/code/core/Mage/Newsletter + - %currentWorkingDirectory%/app/code/core/Mage/Oauth + - %currentWorkingDirectory%/app/code/core/Mage/Page + - %currentWorkingDirectory%/app/code/core/Mage/PageCache + - %currentWorkingDirectory%/app/code/core/Mage/Paygate + - %currentWorkingDirectory%/app/code/core/Mage/Payment + - %currentWorkingDirectory%/app/code/core/Mage/Paypal +# - %currentWorkingDirectory%/app/code/core/Mage/PaypalUk + - %currentWorkingDirectory%/app/code/core/Mage/Persistent + - %currentWorkingDirectory%/app/code/core/Mage/Poll + - %currentWorkingDirectory%/app/code/core/Mage/ProductAlert + - %currentWorkingDirectory%/app/code/core/Mage/Rating + - %currentWorkingDirectory%/app/code/core/Mage/Reports + - %currentWorkingDirectory%/app/code/core/Mage/Review + - %currentWorkingDirectory%/app/code/core/Mage/Rss + - %currentWorkingDirectory%/app/code/core/Mage/Rule + - %currentWorkingDirectory%/app/code/core/Mage/Sales + - %currentWorkingDirectory%/app/code/core/Mage/SalesRule + - %currentWorkingDirectory%/app/code/core/Mage/Sendfriend + - %currentWorkingDirectory%/app/code/core/Mage/Shipping + - %currentWorkingDirectory%/app/code/core/Mage/Sitemap + - %currentWorkingDirectory%/app/code/core/Mage/Tag + - %currentWorkingDirectory%/app/code/core/Mage/Tax + - %currentWorkingDirectory%/app/code/core/Mage/Uploader +# - %currentWorkingDirectory%/app/code/core/Mage/Usa + - %currentWorkingDirectory%/app/code/core/Mage/Widget +# - %currentWorkingDirectory%/app/code/core/Mage/Weee + - %currentWorkingDirectory%/app/code/core/Mage/Wishlist + excludePaths: + #incompatible interfaces + - */app/code/core/Mage/Admin/Model/Acl/Assert/Ip.php + - */app/code/core/Mage/Admin/Model/Acl/Assert/Time.php + - */app/code/core/Mage/Api/Model/Acl/Assert/Ip.php + - */app/code/core/Mage/Api/Model/Acl/Assert/Time.php + - */app/code/core/Mage/Adminhtml/Block/Widget/Grid/Block.php + - */app/code/core/Mage/Core/Model/Mysql4/Design/Theme/Collection.php + # deprecated _getHelper() + - */app/code/core/Mage/Adminhtml/Controller/Rss/Abstract.php + - */app/code/core/Mage/Adminhtml/controllers/Rss/OrderController.php + - */app/code/core/Mage/Adminhtml/controllers/Rss/CatalogController.php + + # contains 1 abstract method and must therefore be declared abstract or implement the remaining methods + - */app/code/core/Mage/Dataflow/Model/Session/Adapter/Http.php + - */app/code/core/Mage/Dataflow/Model/Convert/Iterator/Http.php + - */app/code/core/Mage/Dataflow/Model/Convert/Iterator/File/Csv.php + + # Cannot declare class Varien_Date, because the name is already in use + - */app/code/core/Mage/Catalog/Model/Product/Option/Type/Date.php + + # Class phpseclib\Net\SSH2 not found. + - */Paypal/Model/Report/Settlement.php + + # Class backup/db was not found while trying to analyse it + - */Adminhtml/controllers/System/BackupController.php + + # Dataflow/Model/Convert/Iterator.php + - */Dataflow/Model/Convert/Iterator.php + + level: 0 +# universalObjectCratesClasses: +# - Varien_Object diff --git a/.github/phpstan_experimental_level.neon b/.github/phpstan_experimental_level.neon new file mode 100644 index 00000000000..bddd0686c3d --- /dev/null +++ b/.github/phpstan_experimental_level.neon @@ -0,0 +1,4 @@ +includes: + - ./phpstan.neon +parameters: + level: 1 diff --git a/.github/workflows/sonar.yml b/.github/workflows/sonar.yml new file mode 100644 index 00000000000..15ab1c6ffbd --- /dev/null +++ b/.github/workflows/sonar.yml @@ -0,0 +1,58 @@ +name: OpenMage LTS - Sonar - Full Analyses + +on: + push: + pull_request: + types: [opened, synchronize, reopened] + + + +jobs: + unit: + name: Unit Tests on ${{ matrix.php-versions }} + runs-on: ${{ matrix.operating-system }} + strategy: + max-parallel: 5 + matrix: + operating-system: [ubuntu-latest] + php-versions: ['7.4', '8.1'] + steps: + - uses: actions/checkout@v1 + - name: Setup PHP + uses: shivammathur/setup-php@v2 + with: + php-version: ${{ matrix.php-versions }} + extensions: mbstring + tools: composer, pecl, phpcs, phpstan, phpunit:9.5 + ini-values-csv: pcov.directory=api, post_max_size=256M, short_open_tag=On #optional, setup php.ini configuration + coverage: pcov #optional, setup coverage driver + env: + COMPOSER_TOKEN: ${{ secrets.GITHUB_TOKEN }} + - name: Prepare + run: | + php -v + composer --version + composer install --dev -n --prefer-source --ignore-platform-req=php + - name: Run Unit Tests + run: phpunit --configuration ./dev/phpunit.xml.dist --testsuite=Unit; + - name: prepare SonarCloud Scan Data + continue-on-error: true + if: ${{ matrix.php-versions == '8.1' }} + run: | + echo $PWD + ls -la + head ./dev/tests/clover.xml + sed -i 's@'$GITHUB_WORKSPACE'/@/github/workspace/@g' ./dev/tests/junit.xml + sed -i 's@'$GITHUB_WORKSPACE'/@/github/workspace/@g' ./dev/tests/clover.xml + head ./dev/tests/clover.xml + ls -la + - name: SonarCloud Scan + uses: SonarSource/sonarcloud-github-action@master + continue-on-error: true + if: ${{ matrix.php-versions == '8.1' }} && SONAR_TOKEN + with: + args: > + -Dproject.settings=dev/sonar-project.properties + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any + SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} diff --git a/.github/workflows/static-code-analyses.yml b/.github/workflows/static-code-analyses.yml index 7ad8b8ed861..986127e794b 100644 --- a/.github/workflows/static-code-analyses.yml +++ b/.github/workflows/static-code-analyses.yml @@ -30,6 +30,28 @@ jobs: - name: Check .phtml files run: '! find app/design -type f -name "*.phtml" -exec php -d error_reporting=32767 -l {} \; 2>&1 1> /dev/null | grep "^"' + php_stan: + name: PHP Stan ${{ matrix.directories }} - ${{ matrix.config_files }} + runs-on: [ubuntu-latest] + strategy: + max-parallel: 2 + matrix: + directories: [ + '', + #'lib/', + ] + config_files: [ + '.github/phpstan.neon', + ] + steps: + - uses: actions/checkout@v2 + - name: Install dependencies + run: composer install --prefer-dist --no-progress --no-suggest --ignore-platform-reqs + - name: ensure existance of ./app/code/local + run: mkdir -p app/code/local + - name: PHPStan Static Analysis + run: php vendor/bin/phpstan.phar analyze -c ${{ matrix.config_files }} ${{ matrix.directories }} + php_syntax_experimental: name: PHP Syntax ${{ matrix.php-versions }} - experimental runs-on: ${{ matrix.operating-system }} @@ -39,7 +61,7 @@ jobs: fail-fast: false matrix: operating-system: [ubuntu-latest] - php-versions: ['8.0'] + php-versions: ['8.0','8.1'] steps: - uses: actions/checkout@v1 - name: Setup PHP @@ -59,3 +81,30 @@ jobs: continue-on-error: true run: '! find app/design -type f -name "*.phtml" -exec php -d error_reporting=32767 -l {} \; 2>&1 1> /dev/null | grep "^"' + + php_stan_experimental: + name: PHP Stan ${{ matrix.directories }} - ${{ matrix.config_files }} - experimental + runs-on: [ubuntu-latest] + needs: php_stan + strategy: + max-parallel: 1 + fail-fast: false + matrix: + directories: [ + '' + ] + config_files: [ + '.github/phpstan_experimental_level.neon', + ] + include: + - directories: 'lib/' + config_files: '.github/phpstan.neon' + steps: + - uses: actions/checkout@v2 + - name: Install dependencies + run: composer install --prefer-dist --no-progress --no-suggest --ignore-platform-reqs + - name: ensure existance of ./app/code/local + run: mkdir -p app/code/local + - name: PHPStan Static Analysis + continue-on-error: true + run: php vendor/bin/phpstan.phar analyze --error-format=raw -c ${{ matrix.config_files }} ${{ matrix.directories }} diff --git a/.gitignore b/.gitignore index 6050e32c552..45f9d4ef72a 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,13 @@ /app/etc/local.xml /media/catalog /media/captcha +/media/css +/media/css_secure +/media/email/logo +/media/favicon +/media/js +/media/sales/store/logo +/media/sales/store/logo_html +/media/wysiwyg /dev/tests/functional/generated /dev/tests/functional/vendor diff --git a/.gitpod.yml b/.gitpod.yml new file mode 100644 index 00000000000..6cd0417492e --- /dev/null +++ b/.gitpod.yml @@ -0,0 +1,22 @@ +# List the start up tasks. Learn more https://www.gitpod.io/docs/config-start-tasks/ +tasks: + - init: echo 'init script' # runs during prebuild + command: echo 'start script' + - name: Install OpenMage + init: | + BASE_URL="$(echo "$GITPOD_WORKSPACE_URL" | sed s~https://~https://8000-~)" + HOST_PORT=8000 BASE_URL=$BASE_URL bash dev/gitpod/install.sh + command: docker ps + openMode: tab-after + - name: prepare git + init: git config core.fileMode false + +vscode: + extensions: + - bmewburn.vscode-intelephense-client + +# List the ports to expose. Learn more https://www.gitpod.io/docs/config-ports/ +ports: + - port: 8000 + visibility: public + onOpen: open-preview diff --git a/README.md b/README.md index b5fccbfcfe0..64289e5e601 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@

-All Contributors +All Contributors Build Status Total Downloads @@ -28,11 +28,9 @@ Note, the branches older than `1.9.4.x` and that were created before this strate - MySQL 5.6+ (8.0+ recommended) - (optional) Redis 5+ (6.x recommended, latest verified compatible 6.0.7 with 20.x) - - PHP 7.4 and 8.0 are supported - Please be aware that although OpenMage is compatible that 1 or more extensions may not be - Installation on PHP 7.2.33 (7.2.x), MySQL 5.7.31-34 (5.7.x) Percona Server and Redis 6.x should work fine and confirmed by users. If using php 7.2+ then mcrypt needs to be disabled in php.ini or pecl to fallback on mcryptcompat and phpseclib. mcrypt is deprecated from 7.2+ onwards. @@ -40,16 +38,17 @@ If using php 7.2+ then mcrypt needs to be disabled in php.ini or pecl to fallbac ## Installation ### Using Composer + Download the latest archive and extract it, clone the repo, or add a composer dependency to your existing project like so: -``` -composer require openmage/magento-lts":"^19.4.0" +```bash +composer require "openmage/magento-lts":"^19.4.0" ``` To get the latest changes use: -``` -composer require openmage/magento-lts":"dev-main" +```bash +composer require "openmage/magento-lts":"dev-main" ``` Note: `dev-main` is just an alias for current `1.9.4.x` branch and may change @@ -58,7 +57,7 @@ composer require openmage/magento-lts":"dev-main" If you want to contribute to the project: -``` +```bash git init git remote add origin https://github.com//magento-lts git pull origin master @@ -74,15 +73,33 @@ git add -A && git commit Most important changes will be listed here, all other changes since `19.4.0` can be found in [release](https://github.com/OpenMage/magento-lts/releases) notes. -### Performance -ToDo: Please add performance related changes as run-time cache, ... +### Between Magento 1.9.4.5 and OpenMage 19.x + +Bug fixes and PHP 7.x and 8.0 compatibility. + +### Between OpenMage 19.x and 20.x + +Do not use 20.x.x if you need IE support. + +- removed IE conditional comments, IE styles, IE scripts and IE eot files #1073 +- removed frontend default themes (default, modern, iphone, german, french, blank, blue) #1600 +- fixed incorrect datetime in customer block (`$useTimezone` parameter) #1525 +- add redis as a valid option for `global/session_save` #1513 +- possibility to disable global search in backend #1532 + +For full list of changes, you can [compare tags](https://github.com/OpenMage/magento-lts/compare/1.9.4.x...20.0). ### New Config Options + - `admin/design/use_legacy_theme` +- `admin/global_search/enable` - `admin/emails/admin_notification_email_template` - `catalog/product_image/progressive_threshold` +- `catalog/search/search_separator` +- `newsletter/security/enable_form_key` ### New Events + - `adminhtml_block_widget_form_init_form_values_after` - `adminhtml_block_widget_tabs_html_before` - `adminhtml_sales_order_create_save_before` @@ -101,12 +118,14 @@ There are some new or changed translations, if you want add them to your locale - `app/locale/en_US/Sales_LTS.csv` ### Removed Modules + - `Mage_Compiler` - `Mage_GoogleBase` - `Mage_Xmlconnect` - `Phoenix_Moneybookers` ## Development Environment with ddev + - Install [ddev](https://ddev.com/get-started/) - Clone the repository as described in Installation -> Using Git - Create a ddev config using ```$ ddev config``` the defaults should be good for you @@ -155,190 +174,192 @@ Thanks goes to these wonderful people ([emoji key](https://allcontributors.org/d - - - - - - - + + + + + + + - - - - - - - + + + + + + + - - - - - - - + + + + + + + - - - - - - - + + + + + + + - - - - - - - + + + + + + + - - - - - - - + + + + + + + - - - - - - - + + + + + + + - - - - - - - + + + + + + + - - - - - - - + + + + + + + - - - - - - - + + + + + + + - - - - - - - + + + + + + + - - - - - - - + + + + + + + - - - - - - - + + + + + + + - - - - - - - + + + + + + + - - - - - - - + + + + + + + - - - - - - - + + + + + + + - - - - - - - + + + + + + + - - - - - - - + + + + + + + - - - - - - - + + + + + + + - - - - - - - + + + + + + + - - - - + + + + + +

sv3n

💻

Lee Saferite

💻

Colin Mollenhour

💻

David Robinson

💻

Tymoteusz Motylewski

💻

Daniel Fahlke

💻

SNH_NL

💻

sv3n

Lee Saferite

Colin Mollenhour

David Robinson

Tymoteusz Motylewski

Daniel Fahlke

SNH_NL

Marc Romano

💻

Fabian Blechschmidt

💻

Luboš Hubáček

💻

Erik Dannenberg

💻

Jeroen Boersma

💻

Leandro F. L.

💻

Kevin Krieger

💻 📖

Marc Romano

Fabian Blechschmidt

Luboš Hubáček

Erik Dannenberg

Jeroen Boersma

Leandro F. L.

Kevin Krieger

Ng Kiat Siong

💻

bob2021

💻

Bastien Lamamy

💻

Dmitry Furs

💻

Robert Coleman

💻

Milan Davídek

💻

Matt Davenport

💻

Ng Kiat Siong

bob2021

Bastien Lamamy

Dmitry Furs

Robert Coleman

Milan Davídek

Matt Davenport

elfling

💻

henrykb

💻

Tony

💻

Mark Lewis

💻

Eric Sean Turner

💻

Eric Seastrand

💻

Tobias Schifftner

💻

elfling

henrykb

Tony

Mark Lewis

Eric Sean Turner

Eric Seastrand

Tobias Schifftner

Simon Sprankel

💻

Tom Lankhorst

💻

shirtsofholland

💻

sebastianwagner

💻

Maxime Huran

💻

Pepijn

💻

manuperezgo

💻

Simon Sprankel

Tom Lankhorst

shirtsofholland

sebastianwagner

Maxime Huran

Pepijn

manuperezgo

luigifab

💻

Loek van Gool

💻

kpitn

💻

kalenjordan

💻

IOWEB TECHNOLOGIES

💻

Florent

💻

dvdsndr

💻

luigifab

Loek van Gool

kpitn

kalenjordan

IOWEB TECHNOLOGIES

Florent

dvdsndr

Vincent MARMIESSE

💻

Lucas van Staden

💻

zamoroka

💻

wpdevteam

💻

Wouter Samaey

💻

Vova Yatsyuk

💻

Trevor Hartman

💻

Vincent MARMIESSE

Lucas van Staden

zamoroka

wpdevteam

Wouter Samaey

Vova Yatsyuk

Trevor Hartman

Somewhere

💻

Fabian Schmengler />

💻

Roman Hutterer

💻

Sergei Filippov

💻

Sam Steele

💻

Ricardo Velhote

💻

Roy Duineveld

💻

Somewhere

Fabian Schmengler />

Roman Hutterer

Sergei Filippov

Sam Steele

Ricardo Velhote

Roy Duineveld

Roberto Sarmiento Pérez

💻

Pierre Martin

💻

Rafał Dołgopoł

💻

Rafael Patro

💻

Andreas Pointner

💻

Paul Rodriguez

💻

ollb

💻

Roberto Sarmiento Pérez

Pierre Martin

Rafał Dołgopoł

Rafael Patro

Andreas Pointner

Paul Rodriguez

ollb

Nicholas Graham

💻

Makis Palasis

💻

Miguel Balparda

💻

Mark van der Sanden

💻

Micky Socaci

💻

Marvin Sengera

💻

Kostadin A.

💻

Nicholas Graham

Makis Palasis

Miguel Balparda

Mark van der Sanden

Micky Socaci

Marvin Sengera

Kostadin A.

Julien Loizelet

💻

Jonas Hünig

💻

Stefan Jaroschek

💻

Jacques Bodin-Hullin

💻

Wilhelm Ellmann

💻

Edwin.

💻

drago-aca

💻

Julien Loizelet

Jonas Hünig

Stefan Jaroschek

Jacques Bodin-Hullin

Wilhelm Ellmann

Edwin.

drago-aca

Daniel Niedergesäß

💻

J Davis

💻

Damien Biasotto

💻

Daniel Corn

💻

Paweł Cieślik

💻

André Herrn

💻

Pablo Benmaman

💻

Daniel Niedergesäß

J Davis

Damien Biasotto

Daniel Corn

Paweł Cieślik

André Herrn

Pablo Benmaman

aterjung

💻

altdovydas

💻

Alisson Júnior

💻

Alex Kirsch

💻

Branden

💻

Pof Magicfingers

💻

Michael Thessel

💻

aterjung

altdovydas

Alisson Júnior

Alex Kirsch

Branden

Pof Magicfingers

Michael Thessel

Jonathan Laliberte

💻

Ivan Chepurnyi

💻

Igor

💻

Elias Kotlyar

💻

Hejty1

💻

Gaelle

💻

Frédéric MARTINEZ

💻

Jonathan Laliberte

Ivan Chepurnyi

Igor

Elias Kotlyar

Hejty1

Gaelle

Frédéric MARTINEZ

Tobias Faust

💻

AndresInSpace

💻

Francesco Boes

💻

Daniel Bachmann

💻

Damian Luszczymak

💻

Fabrizio Balliano

💻 📖

Jouriy

💻

Tobias Faust

AndresInSpace

Francesco Boes

Daniel Bachmann

Damian Luszczymak

Fabrizio Balliano

Jouriy

Digital Pianism

💻

Justin Beaty

💻

ADDISON

💻 📖

Aria Stewart

💻

Dean Williams

💻

Henry Hirsch

💻

kdckrs

💻

Digital Pianism

Justin Beaty

ADDISON

Aria Stewart

Dean Williams

Henry Hirsch

kdckrs

Martin René Sørensen

💻

Frank Rochlitzer

💻

AlterWeb

💻

Caprico

💻

David Windell

💻

Dragan Atanasov

💻

Eugene Lamskoy

💻

Martin René Sørensen

Frank Rochlitzer

AlterWeb

Caprico

David Windell

Dragan Atanasov

Eugene Lamskoy

Ferdinand

💻

Himanshu

💻

Jakub Idziak

💻

Joseph Maxwell

💻

Joshua Dickerson

💻

Kevin Bortnick

💻

Mehdi Chaouch

💻

Ferdinand

Himanshu

Jakub Idziak

Joseph Maxwell

Joshua Dickerson

Kevin Bortnick

Mehdi Chaouch

Mohamed ELIDRISSI

💻

Justin van Elst

💻

Nicholas Graham

💻

Patrick Schnell

💻

Patrick Cronin

💻

Petr Švamberg

💻

Rafael Corrêa Gomes

💻

Mohamed ELIDRISSI

Justin van Elst

Nicholas Graham

Patrick Schnell

Patrick Cronin

Petr Švamberg

Rafael Corrêa Gomes

Ralf Siepker

💻

Sunel Tr

💻

Tom Klingenberg

💻

Toon

💻

WEXO team

💻

Wilfried Wolf

💻

akrzemianowski

💻

Ralf Siepker

Sunel Tr

Tom Klingenberg

Toon

WEXO team

Wilfried Wolf

akrzemianowski

andthink

💻

eetzen

💻

lemundo-team

💻

mdlonline

💻

andthink

eetzen

lemundo-team

mdlonline

Benjamin MARROT

Tino Mewes
diff --git a/app/Mage.php b/app/Mage.php index d06cc46a335..214e41f3cfe 100644 --- a/app/Mage.php +++ b/app/Mage.php @@ -222,7 +222,7 @@ public static function getOpenMageVersionInfo() return array( 'major' => '20', 'minor' => '0', - 'patch' => '13', + 'patch' => '14', 'stability' => '', // beta,alpha,rc 'number' => '', // 1,2,3,0.3.7,x.7.z.92 @see https://semver.org/#spec-item-9 ); @@ -231,7 +231,7 @@ public static function getOpenMageVersionInfo() return array( 'major' => '19', 'minor' => '4', - 'patch' => '15', + 'patch' => '16', 'stability' => '', // beta,alpha,rc 'number' => '', // 1,2,3,0.3.7,x.7.z.92 @see https://semver.org/#spec-item-9 ); diff --git a/app/code/core/Mage/Admin/Model/Acl.php b/app/code/core/Mage/Admin/Model/Acl.php index c7d8139b8c2..2d246df3dcc 100644 --- a/app/code/core/Mage/Admin/Model/Acl.php +++ b/app/code/core/Mage/Admin/Model/Acl.php @@ -43,25 +43,25 @@ class Mage_Admin_Model_Acl extends Zend_Acl * */ const ROLE_TYPE_GROUP = 'G'; - + /** * All the user roles are prepended by U * */ const ROLE_TYPE_USER = 'U'; - + /** * Permission level to deny access * */ const RULE_PERM_DENY = 0; - + /** * Permission level to inheric access from parent role * */ const RULE_PERM_INHERIT = 1; - + /** * Permission level to allow access * @@ -80,7 +80,7 @@ protected function _getRoleRegistry() } return $this->_roleRegistry; } - + /** * Add parent to role object * diff --git a/app/code/core/Mage/Admin/Model/Acl/Resource.php b/app/code/core/Mage/Admin/Model/Acl/Resource.php index f4826d15e77..20ed1e2cf48 100644 --- a/app/code/core/Mage/Admin/Model/Acl/Resource.php +++ b/app/code/core/Mage/Admin/Model/Acl/Resource.php @@ -34,5 +34,5 @@ */ class Mage_Admin_Model_Acl_Resource extends Zend_Acl_Resource { - + } diff --git a/app/code/core/Mage/Admin/Model/Acl/Role/Group.php b/app/code/core/Mage/Admin/Model/Acl/Role/Group.php index f1335cbf6c6..107414df5ce 100644 --- a/app/code/core/Mage/Admin/Model/Acl/Role/Group.php +++ b/app/code/core/Mage/Admin/Model/Acl/Role/Group.php @@ -34,5 +34,5 @@ */ class Mage_Admin_Model_Acl_Role_Group extends Mage_Admin_Model_Acl_Role_Generic { - + } diff --git a/app/code/core/Mage/Admin/Model/Observer.php b/app/code/core/Mage/Admin/Model/Observer.php index 8c8b9e674b4..b88c5232ef7 100644 --- a/app/code/core/Mage/Admin/Model/Observer.php +++ b/app/code/core/Mage/Admin/Model/Observer.php @@ -39,7 +39,7 @@ class Mage_Admin_Model_Observer * Handler for controller_action_predispatch event * * @param Varien_Event_Observer $observer - * @return boolean + * @return void */ public function actionPreDispatchAdmin($observer) { @@ -106,7 +106,7 @@ public function actionPreDispatchAdmin($observer) ->setActionName('login') ->setDispatched(false); } - return false; + return; } } } diff --git a/app/code/core/Mage/AdminNotification/Model/Survey.php b/app/code/core/Mage/AdminNotification/Model/Survey.php deleted file mode 100644 index e71395a4989..00000000000 --- a/app/code/core/Mage/AdminNotification/Model/Survey.php +++ /dev/null @@ -1,114 +0,0 @@ - - */ -class Mage_AdminNotification_Model_Survey -{ - protected static $_flagCode = 'admin_notification_survey'; - protected static $_flagModel = null; - - const SURVEY_URL = 'www.magentocommerce.com/instsurvey.html'; - - /** - * Check if survey url valid (exists) or not - * - * @return bool - */ - public static function isSurveyUrlValid() - { - $curl = new Varien_Http_Adapter_Curl(); - $curl->setConfig(array('timeout' => 5)) - ->write(Zend_Http_Client::GET, self::getSurveyUrl(), '1.0'); - $response = $curl->read(); - $curl->close(); - - if (Zend_Http_Response::extractCode($response) == 200) { - return true; - } - return false; - } - - /** - * Return survey url - * - * @return string - */ - public static function getSurveyUrl() - { - $host = Mage::app()->getRequest()->isSecure() ? 'https://' : 'http://'; - return $host . self::SURVEY_URL; - } - - /** - * Return core flag model - * - * @return Mage_Core_Model_Flag - */ - protected static function _getFlagModel() - { - if (self::$_flagModel === null) { - self::$_flagModel = Mage::getModel('core/flag', array('flag_code' => self::$_flagCode))->loadSelf(); - } - return self::$_flagModel; - } - - /** - * Check if survey question was already asked - * or survey url was viewed during installation process - * - * @return boolean - */ - public static function isSurveyViewed() - { - $flagData = self::_getFlagModel()->getFlagData(); - if (isset($flagData['survey_viewed']) && $flagData['survey_viewed'] == 1) { - return true; - } - return false; - } - - /** - * Save survey viewed flag in core flag - * - * @param boolean $viewed - */ - public static function saveSurveyViewed($viewed) - { - $flagData = self::_getFlagModel()->getFlagData(); - if (is_null($flagData)) { - $flagData = array(); - } - $flagData = array_merge($flagData, array('survey_viewed' => (bool)$viewed)); - self::_getFlagModel()->setFlagData($flagData)->save(); - } -} diff --git a/app/code/core/Mage/Adminhtml/Block/Catalog/Category/Helper/Sortby/Default.php b/app/code/core/Mage/Adminhtml/Block/Catalog/Category/Helper/Sortby/Default.php index 49125ee47c7..69747e23c4a 100644 --- a/app/code/core/Mage/Adminhtml/Block/Catalog/Category/Helper/Sortby/Default.php +++ b/app/code/core/Mage/Adminhtml/Block/Catalog/Category/Helper/Sortby/Default.php @@ -58,6 +58,7 @@ public function getElementHtml() $disabled = false; if (!$this->getValue() || $elementDisabled) { + $this->setValue(Mage::getStoreConfig(Mage_Catalog_Model_Config::XML_PATH_LIST_DEFAULT_SORT_BY)); $this->setData('disabled', 'disabled'); $disabled = true; } diff --git a/app/code/core/Mage/Adminhtml/Block/Catalog/Product/Attribute/Edit/Tabs.php b/app/code/core/Mage/Adminhtml/Block/Catalog/Product/Attribute/Edit/Tabs.php index 7633a88ab3d..44ded64ea26 100644 --- a/app/code/core/Mage/Adminhtml/Block/Catalog/Product/Attribute/Edit/Tabs.php +++ b/app/code/core/Mage/Adminhtml/Block/Catalog/Product/Attribute/Edit/Tabs.php @@ -58,7 +58,7 @@ protected function _beforeToHtml() 'title' => Mage::helper('catalog')->__('Manage Label / Options'), 'content' => $this->getLayout()->createBlock('adminhtml/catalog_product_attribute_edit_tab_options')->toHtml(), )); - + /*if ('select' == $model->getFrontendInput()) { $this->addTab('options_section', array( 'label' => Mage::helper('catalog')->__('Options Control'), diff --git a/app/code/core/Mage/Adminhtml/Block/Catalog/Product/Created.php b/app/code/core/Mage/Adminhtml/Block/Catalog/Product/Created.php index ecffd3a50d2..089a0d374c9 100644 --- a/app/code/core/Mage/Adminhtml/Block/Catalog/Product/Created.php +++ b/app/code/core/Mage/Adminhtml/Block/Catalog/Product/Created.php @@ -77,7 +77,7 @@ public function isEdit() } /** - * Retrive serialized json with configurable attributes values of simple + * Retrieve serialized json with configurable attributes values of simple * * @return string */ @@ -121,7 +121,7 @@ public function getAttributes() } /** - * Retrive configurable product for created/edited simple + * Retrieve configurable product for created/edited simple * * @return Mage_Catalog_Model_Product */ @@ -136,7 +136,7 @@ public function getConfigurableProduct() } /** - * Retrive product + * Retrieve product * * @return Mage_Catalog_Model_Product */ diff --git a/app/code/core/Mage/Adminhtml/Block/Catalog/Product/Edit/Action/Attribute.php b/app/code/core/Mage/Adminhtml/Block/Catalog/Product/Edit/Action/Attribute.php index e3a8cb0fcfb..a493b81cff5 100644 --- a/app/code/core/Mage/Adminhtml/Block/Catalog/Product/Edit/Action/Attribute.php +++ b/app/code/core/Mage/Adminhtml/Block/Catalog/Product/Edit/Action/Attribute.php @@ -83,7 +83,7 @@ protected function _getHelper() { return $this->helper('adminhtml/catalog_product_edit_action_attribute'); } - + /** * Retrieve back button html code * @@ -123,7 +123,7 @@ public function getSaveUrl() { return $this->getUrl('*/*/save', array('store'=>Mage::helper('adminhtml/catalog_product_edit_action_attribute')->getSelectedStoreId())); } - + /** * Get validation url * diff --git a/app/code/core/Mage/Adminhtml/Block/Catalog/Product/Edit/Action/Attribute/Tab/Attributes.php b/app/code/core/Mage/Adminhtml/Block/Catalog/Product/Edit/Action/Attribute/Tab/Attributes.php index b66b3fbbd67..163821846bc 100644 --- a/app/code/core/Mage/Adminhtml/Block/Catalog/Product/Edit/Action/Attribute/Tab/Attributes.php +++ b/app/code/core/Mage/Adminhtml/Block/Catalog/Product/Edit/Action/Attribute/Tab/Attributes.php @@ -63,7 +63,7 @@ protected function _prepareForm() } /** - * Retrive attributes for product massupdate + * Retrieve attributes for product massupdate * * @return array */ diff --git a/app/code/core/Mage/Adminhtml/Block/Catalog/Product/Edit/Tab/Attributes/Create.php b/app/code/core/Mage/Adminhtml/Block/Catalog/Product/Edit/Tab/Attributes/Create.php index f17fc303738..30f3569eb83 100644 --- a/app/code/core/Mage/Adminhtml/Block/Catalog/Product/Edit/Tab/Attributes/Create.php +++ b/app/code/core/Mage/Adminhtml/Block/Catalog/Product/Edit/Tab/Attributes/Create.php @@ -41,7 +41,7 @@ class Mage_Adminhtml_Block_Catalog_Product_Edit_Tab_Attributes_Create extends Ma protected $_config = null; /** - * Retrive config of new attribute creation + * Retrieve config of new attribute creation * * @return Varien_Object */ diff --git a/app/code/core/Mage/Adminhtml/Block/Catalog/Product/Edit/Tabs.php b/app/code/core/Mage/Adminhtml/Block/Catalog/Product/Edit/Tabs.php index 895271db6eb..12996374dc1 100644 --- a/app/code/core/Mage/Adminhtml/Block/Catalog/Product/Edit/Tabs.php +++ b/app/code/core/Mage/Adminhtml/Block/Catalog/Product/Edit/Tabs.php @@ -193,7 +193,7 @@ protected function _prepareLayout() } /** - * Retrive product object from object if not from registry + * Retrieve product object from object if not from registry * * @return Mage_Catalog_Model_Product */ diff --git a/app/code/core/Mage/Adminhtml/Block/Catalog/Product/Helper/Form/Gallery/Content.php b/app/code/core/Mage/Adminhtml/Block/Catalog/Product/Helper/Form/Gallery/Content.php index 994368eb133..8a29d3f3109 100644 --- a/app/code/core/Mage/Adminhtml/Block/Catalog/Product/Helper/Form/Gallery/Content.php +++ b/app/code/core/Mage/Adminhtml/Block/Catalog/Product/Helper/Form/Gallery/Content.php @@ -72,7 +72,7 @@ protected function _prepareLayout() } /** - * Retrive uploader block + * Retrieve uploader block * * @return Mage_Uploader_Block_Multiple */ @@ -82,7 +82,7 @@ public function getUploader() } /** - * Retrive uploader block html + * Retrieve uploader block html * * @return string */ diff --git a/app/code/core/Mage/Adminhtml/Block/Catalog/Product/Helper/Form/Image.php b/app/code/core/Mage/Adminhtml/Block/Catalog/Product/Helper/Form/Image.php index dc5adda7477..21c95644833 100644 --- a/app/code/core/Mage/Adminhtml/Block/Catalog/Product/Helper/Form/Image.php +++ b/app/code/core/Mage/Adminhtml/Block/Catalog/Product/Helper/Form/Image.php @@ -41,7 +41,7 @@ protected function _getUrl() } return $url; } - + protected function _getDeleteCheckbox() { $html = ''; diff --git a/app/code/core/Mage/Adminhtml/Block/Cms/Block/Widget/Chooser.php b/app/code/core/Mage/Adminhtml/Block/Cms/Block/Widget/Chooser.php index bb9263e4946..a33adaa9d28 100644 --- a/app/code/core/Mage/Adminhtml/Block/Cms/Block/Widget/Chooser.php +++ b/app/code/core/Mage/Adminhtml/Block/Cms/Block/Widget/Chooser.php @@ -41,7 +41,7 @@ class Mage_Adminhtml_Block_Cms_Block_Widget_Chooser extends Mage_Adminhtml_Block public function __construct($arguments=array()) { parent::__construct($arguments); - $this->setDefaultSort('block_identifier'); + $this->setDefaultSort('block_id'); $this->setDefaultDir('ASC'); $this->setUseAjax(true); $this->setDefaultFilter(array('chooser_is_active' => '1')); diff --git a/app/code/core/Mage/Adminhtml/Block/Customer/Edit/Tab/Account.php b/app/code/core/Mage/Adminhtml/Block/Customer/Edit/Tab/Account.php index 89cb81f4e5a..c640198455b 100644 --- a/app/code/core/Mage/Adminhtml/Block/Customer/Edit/Tab/Account.php +++ b/app/code/core/Mage/Adminhtml/Block/Customer/Edit/Tab/Account.php @@ -68,6 +68,7 @@ public function initForm() foreach ($attributes as $attribute) { /* @var $attribute Mage_Eav_Model_Entity_Attribute */ $attribute->setFrontendLabel(Mage::helper('customer')->__($attribute->getFrontend()->getLabel())); + $attribute->setNote(Mage::helper('customer')->__($attribute->getNote())); $attribute->unsIsVisible(); } diff --git a/app/code/core/Mage/Adminhtml/Block/Customer/Edit/Tab/Addresses.php b/app/code/core/Mage/Adminhtml/Block/Customer/Edit/Tab/Addresses.php index 51dfa037faa..974fcd59152 100644 --- a/app/code/core/Mage/Adminhtml/Block/Customer/Edit/Tab/Addresses.php +++ b/app/code/core/Mage/Adminhtml/Block/Customer/Edit/Tab/Addresses.php @@ -130,6 +130,7 @@ public function initForm() foreach ($attributes as $attribute) { /* @var $attribute Mage_Eav_Model_Entity_Attribute */ $attribute->setFrontendLabel(Mage::helper('customer')->__($attribute->getFrontend()->getLabel())); + $attribute->setNote(Mage::helper('customer')->__($attribute->getNote())); $attribute->unsIsVisible(); } $this->_setFieldset($attributes, $fieldset); diff --git a/app/code/core/Mage/Adminhtml/Block/Media/Editor.php b/app/code/core/Mage/Adminhtml/Block/Media/Editor.php index 7d9bcd3f103..53e167885b1 100644 --- a/app/code/core/Mage/Adminhtml/Block/Media/Editor.php +++ b/app/code/core/Mage/Adminhtml/Block/Media/Editor.php @@ -116,7 +116,7 @@ public function getResizeButtonHtml() } /** - * Retrive uploader js object name + * Retrieve uploader js object name * * @return string */ @@ -126,7 +126,7 @@ public function getJsObjectName() } /** - * Retrive config json + * Retrieve config json * * @return string */ @@ -136,7 +136,7 @@ public function getConfigJson() } /** - * Retrive config object + * Retrieve config object * * @return Varien_Config */ diff --git a/app/code/core/Mage/Adminhtml/Block/Newsletter/Template/Edit/Form.php b/app/code/core/Mage/Adminhtml/Block/Newsletter/Template/Edit/Form.php index a1595d5c4fd..1e0b8883800 100644 --- a/app/code/core/Mage/Adminhtml/Block/Newsletter/Template/Edit/Form.php +++ b/app/code/core/Mage/Adminhtml/Block/Newsletter/Template/Edit/Form.php @@ -104,7 +104,7 @@ protected function _prepareForm() 'label' => Mage::helper('newsletter')->__('Sender Name'), 'title' => Mage::helper('newsletter')->__('Sender Name'), 'required' => true, - 'value' => $model->getId() !== null + 'value' => $model->getId() !== null ? $model->getTemplateSenderName() : $identityName, )); @@ -115,7 +115,7 @@ protected function _prepareForm() 'title' => Mage::helper('newsletter')->__('Sender Email'), 'class' => 'validate-email', 'required' => true, - 'value' => $model->getId() !== null + 'value' => $model->getId() !== null ? $model->getTemplateSenderEmail() : $identityEmail )); diff --git a/app/code/core/Mage/Adminhtml/Block/Newsletter/Template/Grid/Renderer/Sender.php b/app/code/core/Mage/Adminhtml/Block/Newsletter/Template/Grid/Renderer/Sender.php index 21d9f8d0be3..ce4c7d1bde6 100644 --- a/app/code/core/Mage/Adminhtml/Block/Newsletter/Template/Grid/Renderer/Sender.php +++ b/app/code/core/Mage/Adminhtml/Block/Newsletter/Template/Grid/Renderer/Sender.php @@ -31,7 +31,7 @@ * @package Mage_Adminhtml * @author Magento Core Team */ - + class Mage_Adminhtml_Block_Newsletter_Template_Grid_Renderer_Sender extends Mage_Adminhtml_Block_Widget_Grid_Column_Renderer_Abstract { public function render(Varien_Object $row) @@ -39,13 +39,13 @@ public function render(Varien_Object $row) $str = ''; if($row->getTemplateSenderName()) { $str .= $this->escapeHtml($row->getTemplateSenderName()) . ' '; - } + } if($row->getTemplateSenderEmail()) { $str .= '[' .$this->escapeHtml($row->getTemplateSenderEmail()) . ']'; - } + } if($str == '') { $str .= '---'; - } + } return $str; } } diff --git a/app/code/core/Mage/Adminhtml/Block/Notification/Survey.php b/app/code/core/Mage/Adminhtml/Block/Notification/Survey.php deleted file mode 100644 index e8753e91a15..00000000000 --- a/app/code/core/Mage/Adminhtml/Block/Notification/Survey.php +++ /dev/null @@ -1,63 +0,0 @@ - - */ -class Mage_Adminhtml_Block_Notification_Survey extends Mage_Adminhtml_Block_Template -{ - /** - * Check whether survey question can show - * - * @return boolean - */ - public function canShow() - { - $adminSession = Mage::getSingleton('admin/session'); - $seconds = intval(date('s', time())); - if ($adminSession->getHideSurveyQuestion() || !$adminSession->isAllowed('all') - || Mage_AdminNotification_Model_Survey::isSurveyViewed() - || !Mage_AdminNotification_Model_Survey::isSurveyUrlValid()) - { - return false; - } - return true; - } - - /** - * Return survey url - * - * @return string - */ - public function getSurveyUrl() - { - return Mage_AdminNotification_Model_Survey::getSurveyUrl(); - } -} diff --git a/app/code/core/Mage/Adminhtml/Block/Page/Menu.php b/app/code/core/Mage/Adminhtml/Block/Page/Menu.php index edc314afeba..057004a45b9 100644 --- a/app/code/core/Mage/Adminhtml/Block/Page/Menu.php +++ b/app/code/core/Mage/Adminhtml/Block/Page/Menu.php @@ -95,7 +95,9 @@ public function getCacheKeyInfo() */ public function getMenuArray() { - return $this->_buildMenuArray(); + $parent = Mage::getSingleton('admin/config')->getAdminhtmlConfig()->getNode('menu'); + + return $this->_buildMenuArray($parent); } /** @@ -127,12 +129,8 @@ protected function _getHelperValue(Varien_Simplexml_Element $child) * @param int $level * @return array */ - protected function _buildMenuArray(Varien_Simplexml_Element $parent=null, $path='', $level=0) + protected function _buildMenuArray(Varien_Simplexml_Element $parent, $path='', $level=0) { - if (is_null($parent)) { - $parent = Mage::getSingleton('admin/config')->getAdminhtmlConfig()->getNode('menu'); - } - $parentArr = array(); $sortOrder = 0; foreach ($parent->children() as $childName => $child) { @@ -167,6 +165,10 @@ protected function _buildMenuArray(Varien_Simplexml_Element $parent=null, $path= $menuArr['level'] = $level; + if ($child->target) { + $menuArr['target'] = $child->target; + } + if ($child->children) { $menuArr['children'] = $this->_buildMenuArray($child->children, $path.$childName.'/', $level+1); } @@ -294,6 +296,7 @@ public function getMenuLevel($menu, $level = 0) . (!empty($level) && !empty($item['last']) ? ' last' : '') . ' level' . $level . '"> ' . $this->escapeHtml($item['label']) . '' . PHP_EOL; diff --git a/app/code/core/Mage/Adminhtml/Block/Promo/Quote.php b/app/code/core/Mage/Adminhtml/Block/Promo/Quote.php index 7f6d6fb7d1f..a45780fae0e 100644 --- a/app/code/core/Mage/Adminhtml/Block/Promo/Quote.php +++ b/app/code/core/Mage/Adminhtml/Block/Promo/Quote.php @@ -41,6 +41,6 @@ public function __construct() $this->_headerText = Mage::helper('salesrule')->__('Shopping Cart Price Rules'); $this->_addButtonLabel = Mage::helper('salesrule')->__('Add New Rule'); parent::__construct(); - + } } diff --git a/app/code/core/Mage/Adminhtml/Block/Promo/Quote/Edit/Form.php b/app/code/core/Mage/Adminhtml/Block/Promo/Quote/Edit/Form.php index f7951301455..6c9d3da4bdc 100644 --- a/app/code/core/Mage/Adminhtml/Block/Promo/Quote/Edit/Form.php +++ b/app/code/core/Mage/Adminhtml/Block/Promo/Quote/Edit/Form.php @@ -41,7 +41,7 @@ public function __construct() $this->setId('promo_quote_form'); $this->setTitle(Mage::helper('salesrule')->__('Rule Information')); } - + protected function _prepareForm() { $form = new Varien_Data_Form(array('id' => 'edit_form', 'action' => $this->getData('action'), 'method' => 'post')); diff --git a/app/code/core/Mage/Adminhtml/Block/Report/Grid.php b/app/code/core/Mage/Adminhtml/Block/Report/Grid.php index 438aff6cad9..d3a38fe315d 100644 --- a/app/code/core/Mage/Adminhtml/Block/Report/Grid.php +++ b/app/code/core/Mage/Adminhtml/Block/Report/Grid.php @@ -614,7 +614,7 @@ public function getCurrentCurrencyCode() } return $this->_currentCurrencyCode; } - + /** * Get currency rate (base to given currency) * diff --git a/app/code/core/Mage/Adminhtml/Block/Review/Product/Grid.php b/app/code/core/Mage/Adminhtml/Block/Review/Product/Grid.php index a71dfa07157..227335a597c 100644 --- a/app/code/core/Mage/Adminhtml/Block/Review/Product/Grid.php +++ b/app/code/core/Mage/Adminhtml/Block/Review/Product/Grid.php @@ -37,6 +37,7 @@ class Mage_Adminhtml_Block_Review_Product_Grid extends Mage_Adminhtml_Block_Cata public function __construct() { parent::__construct(); + $this->setId('reviewProductGrid'); $this->setRowClickCallback('review.gridRowClick'); $this->setUseAjax(true); } diff --git a/app/code/core/Mage/Adminhtml/Block/Sales/Order/Create/Form/Abstract.php b/app/code/core/Mage/Adminhtml/Block/Sales/Order/Create/Form/Abstract.php index 66aeaca93a9..6d42cd43949 100644 --- a/app/code/core/Mage/Adminhtml/Block/Sales/Order/Create/Form/Abstract.php +++ b/app/code/core/Mage/Adminhtml/Block/Sales/Order/Create/Form/Abstract.php @@ -151,6 +151,7 @@ protected function _addAttributesToForm($attributes, Varien_Data_Form_Abstract $ 'label' => $this->__($attribute->getStoreLabel()), 'class' => $attribute->getFrontend()->getClass(), 'required' => $attribute->getIsRequired(), + 'note' => $this->escapeHtml($this->__($attribute->getNote())) )); if ($inputType == 'multiline') { $element->setLineCount($attribute->getMultilineCount()); diff --git a/app/code/core/Mage/Adminhtml/Block/Sales/Order/Create/Giftmessage.php b/app/code/core/Mage/Adminhtml/Block/Sales/Order/Create/Giftmessage.php index 32b6e6ac20d..a47bf3ca0d4 100644 --- a/app/code/core/Mage/Adminhtml/Block/Sales/Order/Create/Giftmessage.php +++ b/app/code/core/Mage/Adminhtml/Block/Sales/Order/Create/Giftmessage.php @@ -48,7 +48,7 @@ public function getFormHtml(Varien_Object $entity, $entityType='quote') { } /** - * Retrive items allowed for gift messages. + * Retrieve items allowed for gift messages. * * If no items available return false. * diff --git a/app/code/core/Mage/Adminhtml/Block/Sales/Order/Create/Giftmessage/Form.php b/app/code/core/Mage/Adminhtml/Block/Sales/Order/Create/Giftmessage/Form.php index 9a82bf32260..c237c4a1412 100644 --- a/app/code/core/Mage/Adminhtml/Block/Sales/Order/Create/Giftmessage/Form.php +++ b/app/code/core/Mage/Adminhtml/Block/Sales/Order/Create/Giftmessage/Form.php @@ -61,7 +61,7 @@ public function setEntity(Varien_Object $entity) } /** - * Retrive entity for form + * Retrieve entity for form * * @return Varien_Object */ @@ -252,7 +252,7 @@ protected function _initMessage() } /** - * Retrive gift message for entity + * Retrieve gift message for entity * * @return Mage_GiftMessage_Model_Message */ @@ -266,7 +266,7 @@ public function getMessage() } /** - * Retrive real name for field + * Retrieve real name for field * * @param string $name * @return string @@ -277,7 +277,7 @@ protected function _getFieldName($name) } /** - * Retrive real html id for field + * Retrieve real html id for field * * @param string $id * @return string @@ -288,7 +288,7 @@ protected function _getFieldId($id) } /** - * Retrive field html id prefix + * Retrieve field html id prefix * * @return string */ diff --git a/app/code/core/Mage/Adminhtml/Block/Sales/Order/Invoice/Totals.php b/app/code/core/Mage/Adminhtml/Block/Sales/Order/Invoice/Totals.php index d038a574a52..19826f5ea1b 100644 --- a/app/code/core/Mage/Adminhtml/Block/Sales/Order/Invoice/Totals.php +++ b/app/code/core/Mage/Adminhtml/Block/Sales/Order/Invoice/Totals.php @@ -48,12 +48,12 @@ public function getInvoice() } return $this->_invoice; } - + public function getSource() { return $this->getInvoice(); } - + /** * Initialize order totals array * diff --git a/app/code/core/Mage/Adminhtml/Block/Sales/Order/Shipment/View/Tracking.php b/app/code/core/Mage/Adminhtml/Block/Sales/Order/Shipment/View/Tracking.php index 28a7913bdd6..5865f11b7b6 100644 --- a/app/code/core/Mage/Adminhtml/Block/Sales/Order/Shipment/View/Tracking.php +++ b/app/code/core/Mage/Adminhtml/Block/Sales/Order/Shipment/View/Tracking.php @@ -73,7 +73,7 @@ public function getSubmitUrl() } /** - * Retrive save button html + * Retrieve save button html * * @return string */ diff --git a/app/code/core/Mage/Adminhtml/Block/Sales/Order/View/Giftmessage.php b/app/code/core/Mage/Adminhtml/Block/Sales/Order/View/Giftmessage.php index fdc3c303cf0..ec1403b9b90 100644 --- a/app/code/core/Mage/Adminhtml/Block/Sales/Order/View/Giftmessage.php +++ b/app/code/core/Mage/Adminhtml/Block/Sales/Order/View/Giftmessage.php @@ -84,7 +84,7 @@ protected function _prepareLayout() } /** - * Retrive save button html + * Retrieve save button html * * @return string */ @@ -110,7 +110,7 @@ public function setEntity(Varien_Object $entity) } /** - * Retrive entity for form + * Retrieve entity for form * * @return Varien_Object */ @@ -124,7 +124,7 @@ public function getEntity() } /** - * Retrive default value for giftmessage sender + * Retrieve default value for giftmessage sender * * @return string */ @@ -142,7 +142,7 @@ public function getDefaultSender() } /** - * Retrive default value for giftmessage recipient + * Retrieve default value for giftmessage recipient * * @return string */ @@ -170,7 +170,7 @@ public function getDefaultRecipient() } /** - * Retrive real name for field + * Retrieve real name for field * * @param string $name * @return string @@ -181,7 +181,7 @@ public function getFieldName($name) } /** - * Retrive real html id for field + * Retrieve real html id for field * * @param string $name * @return string @@ -192,7 +192,7 @@ public function getFieldId($id) } /** - * Retrive field html id prefix + * Retrieve field html id prefix * * @return string */ @@ -224,7 +224,7 @@ protected function _initMessage() } /** - * Retrive gift message for entity + * Retrieve gift message for entity * * @return Mage_GiftMessage_Model_Message */ @@ -249,7 +249,7 @@ public function getSaveUrl() } /** - * Retrive block html id + * Retrieve block html id * * @return string */ diff --git a/app/code/core/Mage/Adminhtml/Block/Sales/Order/View/Items/Renderer/Default.php b/app/code/core/Mage/Adminhtml/Block/Sales/Order/View/Items/Renderer/Default.php index f78864be0cf..0afe4b24595 100644 --- a/app/code/core/Mage/Adminhtml/Block/Sales/Order/View/Items/Renderer/Default.php +++ b/app/code/core/Mage/Adminhtml/Block/Sales/Order/View/Items/Renderer/Default.php @@ -78,7 +78,7 @@ public function canDisplayContainer() protected $_giftMessage = array(); /** - * Retrive default value for giftmessage sender + * Retrieve default value for giftmessage sender * * @deprecated after 1.4.2.0 * @return string @@ -97,7 +97,7 @@ public function getDefaultSender() } /** - * Retrive default value for giftmessage recipient + * Retrieve default value for giftmessage recipient * * @deprecated after 1.4.2.0 * @return string @@ -126,7 +126,7 @@ public function getDefaultRecipient() } /** - * Retrive real name for field + * Retrieve real name for field * * @deprecated after 1.4.2.0 * @param string $name @@ -160,7 +160,7 @@ protected function _initMessage() } /** - * Retrive gift message for entity + * Retrieve gift message for entity * * @deprecated after 1.4.2.0 * @return Mage_GiftMessage_Model_Message @@ -190,7 +190,7 @@ public function getSaveUrl() } /** - * Retrive block html id + * Retrieve block html id * * @deprecated after 1.4.2.0 * @return string diff --git a/app/code/core/Mage/Adminhtml/Block/System/Config/Tabs.php b/app/code/core/Mage/Adminhtml/Block/System/Config/Tabs.php index 8a9b2754714..c5399a18db7 100644 --- a/app/code/core/Mage/Adminhtml/Block/System/Config/Tabs.php +++ b/app/code/core/Mage/Adminhtml/Block/System/Config/Tabs.php @@ -159,7 +159,7 @@ public function addTab($code, $config) } /** - * Retrive tab + * Retrieve tab * * @param string $code * @return Varien_Object diff --git a/app/code/core/Mage/Adminhtml/Block/System/Currency/Edit/Form.php b/app/code/core/Mage/Adminhtml/Block/System/Currency/Edit/Form.php index 72ca6e5bbdd..bce61accbcb 100644 --- a/app/code/core/Mage/Adminhtml/Block/System/Currency/Edit/Form.php +++ b/app/code/core/Mage/Adminhtml/Block/System/Currency/Edit/Form.php @@ -39,7 +39,7 @@ public function __construct() $this->setId('currency_edit_form'); $this->setTitle(Mage::helper('adminhtml')->__('Currency Information')); } - + protected function _prepareForm() { $form = new Varien_Data_Form(array('id' => 'currency_edit_form', 'action' => $this->getData('action'), 'method' => 'post')); diff --git a/app/code/core/Mage/Adminhtml/Block/System/Currency/Edit/Tab/Main.php b/app/code/core/Mage/Adminhtml/Block/System/Currency/Edit/Tab/Main.php index 8b58829cee8..65863c556e0 100644 --- a/app/code/core/Mage/Adminhtml/Block/System/Currency/Edit/Tab/Main.php +++ b/app/code/core/Mage/Adminhtml/Block/System/Currency/Edit/Tab/Main.php @@ -33,5 +33,5 @@ */ class Mage_Adminhtml_Block_System_Currency_Edit_Tab_Main extends Mage_Adminhtml_Block_Widget_Form { - + } diff --git a/app/code/core/Mage/Adminhtml/Block/System/Currency/Edit/Tab/Rates.php b/app/code/core/Mage/Adminhtml/Block/System/Currency/Edit/Tab/Rates.php index 6eb1cb410bb..a54acf15af6 100644 --- a/app/code/core/Mage/Adminhtml/Block/System/Currency/Edit/Tab/Rates.php +++ b/app/code/core/Mage/Adminhtml/Block/System/Currency/Edit/Tab/Rates.php @@ -33,5 +33,5 @@ */ class Mage_Adminhtml_Block_System_Currency_Edit_Tab_Rates extends Mage_Adminhtml_Block_Widget_Form { - + } diff --git a/app/code/core/Mage/Adminhtml/Block/System/Currency/Edit/Tabs.php b/app/code/core/Mage/Adminhtml/Block/System/Currency/Edit/Tabs.php index e9006444c06..36c20a53d4a 100644 --- a/app/code/core/Mage/Adminhtml/Block/System/Currency/Edit/Tabs.php +++ b/app/code/core/Mage/Adminhtml/Block/System/Currency/Edit/Tabs.php @@ -53,7 +53,7 @@ protected function _beforeToHtml() 'label' => Mage::helper('adminhtml')->__('Rates'), 'content' => $this->getLayout()->createBlock('adminhtml/system_currency_edit_tab_rates')->toHtml(), )); - + return parent::_beforeToHtml(); } } diff --git a/app/code/core/Mage/Adminhtml/Block/System/Email/Template/Edit.php b/app/code/core/Mage/Adminhtml/Block/System/Email/Template/Edit.php index 0691e413844..ccd76f56099 100644 --- a/app/code/core/Mage/Adminhtml/Block/System/Email/Template/Edit.php +++ b/app/code/core/Mage/Adminhtml/Block/System/Email/Template/Edit.php @@ -271,7 +271,7 @@ public function getDeleteUrl() } /** - * Retrive email template model + * Retrieve email template model * * @return Mage_Core_Model_Email_Template */ diff --git a/app/code/core/Mage/Adminhtml/Block/System/Email/Template/Grid/Renderer/Sender.php b/app/code/core/Mage/Adminhtml/Block/System/Email/Template/Grid/Renderer/Sender.php index 3a019f29d50..cd20f737cdf 100644 --- a/app/code/core/Mage/Adminhtml/Block/System/Email/Template/Grid/Renderer/Sender.php +++ b/app/code/core/Mage/Adminhtml/Block/System/Email/Template/Grid/Renderer/Sender.php @@ -31,25 +31,25 @@ * @package Mage_Adminhtml * @author Magento Core Team */ - + class Mage_Adminhtml_Block_System_Email_Template_Grid_Renderer_Sender extends Mage_Adminhtml_Block_Widget_Grid_Column_Renderer_Abstract { public function render(Varien_Object $row) { $str = ''; - + if($row->getTemplateSenderName()) { $str .= htmlspecialchars($row->getTemplateSenderName()) . ' '; - } - + } + if($row->getTemplateSenderEmail()) { $str .= '[' . $row->getTemplateSenderEmail() . ']'; - } - + } + if($str == '') { $str .= '---'; } - + return $str; } } diff --git a/app/code/core/Mage/Adminhtml/Block/Tag/Grid/Pending.php b/app/code/core/Mage/Adminhtml/Block/Tag/Grid/Pending.php index 29a21a80fef..161382c2ed1 100644 --- a/app/code/core/Mage/Adminhtml/Block/Tag/Grid/Pending.php +++ b/app/code/core/Mage/Adminhtml/Block/Tag/Grid/Pending.php @@ -104,7 +104,7 @@ protected function _prepareColumns() } /** - * Retrives row click URL + * Retrieves row click URL * * @param mixed $row * @return string diff --git a/app/code/core/Mage/Adminhtml/Block/Tag/Tag/Grid.php b/app/code/core/Mage/Adminhtml/Block/Tag/Tag/Grid.php index 791712f5903..3759ba2df81 100644 --- a/app/code/core/Mage/Adminhtml/Block/Tag/Tag/Grid.php +++ b/app/code/core/Mage/Adminhtml/Block/Tag/Tag/Grid.php @@ -155,7 +155,7 @@ public function getGridUrl() } /** - * Retrives row click URL + * Retrieves row click URL * * @param mixed $row * @return string diff --git a/app/code/core/Mage/Adminhtml/Block/Widget/Accordion.php b/app/code/core/Mage/Adminhtml/Block/Widget/Accordion.php index 548e4e80afb..8b80d2098ad 100644 --- a/app/code/core/Mage/Adminhtml/Block/Widget/Accordion.php +++ b/app/code/core/Mage/Adminhtml/Block/Widget/Accordion.php @@ -31,20 +31,20 @@ * @package Mage_Adminhtml * @author Magento Core Team */ -class Mage_Adminhtml_Block_Widget_Accordion extends Mage_Adminhtml_Block_Widget +class Mage_Adminhtml_Block_Widget_Accordion extends Mage_Adminhtml_Block_Widget { protected $_items = array(); - public function __construct() + public function __construct() { parent::__construct(); $this->setTemplate('widget/accordion.phtml'); } - + public function getItems() { return $this->_items; } - + public function addItem($itemId, $config) { $this->_items[$itemId] = $this->getLayout()->createBlock('adminhtml/widget_accordion_item') @@ -54,7 +54,7 @@ public function addItem($itemId, $config) if (isset($config['content']) && $config['content'] instanceof Mage_Core_Block_Abstract) { $this->_items[$itemId]->setChild($itemId.'_content', $config['content']); } - + $this->setChild($itemId, $this->_items[$itemId]); return $this; } diff --git a/app/code/core/Mage/Adminhtml/Block/Widget/Grid.php b/app/code/core/Mage/Adminhtml/Block/Widget/Grid.php index 1d930b462ce..b968531fe48 100644 --- a/app/code/core/Mage/Adminhtml/Block/Widget/Grid.php +++ b/app/code/core/Mage/Adminhtml/Block/Widget/Grid.php @@ -971,23 +971,29 @@ public function _exportIterateCollection($callback, array $args) $originalCollection = $this->getCollection(); $count = null; $page = 1; + $lPage = null; + $break = false; - do { + while ($break !== true) { $collection = clone $originalCollection; $collection->setPageSize($this->_exportPageSize); $collection->setCurPage($page); $collection->load(); - - $count = $collection->count(); - - $page++; + if (is_null($count)) { + $count = $collection->getSize(); + $lPage = $collection->getLastPageNumber(); + } + if ($lPage == $page) { + $break = true; + } + $page ++; foreach ($collection as $item) { call_user_func_array(array($this, $callback), array_merge(array($item), $args)); } $collection->clear(); unset($collection); - } while($count == $this->_exportPageSize); + } } /** @@ -1292,12 +1298,18 @@ public function getParam($paramName, $default = null) { $session = Mage::getSingleton('adminhtml/session'); $sessionParamName = $this->getId().$paramName; - if ($this->getRequest()->has($paramName)) { - $param = $this->getRequest()->getParam($paramName); - if ($this->_saveParametersInSession) { - $session->setData($sessionParamName, $param); + $param = $this->getRequest()->getParam($paramName); + + if ($param !== null) { + if (trim($param) !== '') { + if ($this->_saveParametersInSession) { + $session->setData($sessionParamName, $param); + } + return $param; + } else { + $session->unsetData($sessionParamName); + return $default; } - return $param; } elseif ($this->_saveParametersInSession && ($param = $session->getData($sessionParamName))) { @@ -1390,7 +1402,7 @@ public function setMassactionIdFilter($idFilter) } /** - * Retrive massaction block name + * Retrieve massaction block name * * @return string */ @@ -1412,7 +1424,7 @@ public function setMassactionBlockName($blockName) } /** - * Retrive massaction block + * Retrieve massaction block * * @return Mage_Adminhtml_Block_Widget_Grid_Massaction_Abstract */ @@ -1725,4 +1737,10 @@ public function getRowUrl($item) $res = parent::getRowUrl($item); return ($res ? $res : '#'); } + + public function getLimitOptions(): array + { + return [20, 30, 50, 100, 200]; + } + } diff --git a/app/code/core/Mage/Adminhtml/Block/Widget/Grid/Column/Filter/Interface.php b/app/code/core/Mage/Adminhtml/Block/Widget/Grid/Column/Filter/Interface.php index 55f9c8a5808..9cdb28eb958 100644 --- a/app/code/core/Mage/Adminhtml/Block/Widget/Grid/Column/Filter/Interface.php +++ b/app/code/core/Mage/Adminhtml/Block/Widget/Grid/Column/Filter/Interface.php @@ -31,7 +31,7 @@ * @package Mage_Adminhtml * @author Magento Core Team */ -interface Mage_Adminhtml_Block_Widget_Grid_Column_Filter_Interface +interface Mage_Adminhtml_Block_Widget_Grid_Column_Filter_Interface { public function getColumn(); public function setColumn($column); diff --git a/app/code/core/Mage/Adminhtml/Block/Widget/Grid/Column/Filter/Radio.php b/app/code/core/Mage/Adminhtml/Block/Widget/Grid/Column/Filter/Radio.php index 83db7862dae..39cd1c8daa8 100644 --- a/app/code/core/Mage/Adminhtml/Block/Widget/Grid/Column/Filter/Radio.php +++ b/app/code/core/Mage/Adminhtml/Block/Widget/Grid/Column/Filter/Radio.php @@ -50,7 +50,7 @@ protected function _getOptions() ), ); } - + public function getCondition() { if ($this->getValue()) { diff --git a/app/code/core/Mage/Adminhtml/Block/Widget/Grid/Column/Filter/Text.php b/app/code/core/Mage/Adminhtml/Block/Widget/Grid/Column/Filter/Text.php index be927766ec2..4d52ba2bddf 100644 --- a/app/code/core/Mage/Adminhtml/Block/Widget/Grid/Column/Filter/Text.php +++ b/app/code/core/Mage/Adminhtml/Block/Widget/Grid/Column/Filter/Text.php @@ -31,7 +31,7 @@ * @package Mage_Adminhtml * @author Magento Core Team */ -class Mage_Adminhtml_Block_Widget_Grid_Column_Filter_Text extends Mage_Adminhtml_Block_Widget_Grid_Column_Filter_Abstract +class Mage_Adminhtml_Block_Widget_Grid_Column_Filter_Text extends Mage_Adminhtml_Block_Widget_Grid_Column_Filter_Abstract { public function getHtml() { diff --git a/app/code/core/Mage/Adminhtml/Block/Widget/Grid/Column/Renderer/Abstract.php b/app/code/core/Mage/Adminhtml/Block/Widget/Grid/Column/Renderer/Abstract.php index 3e65af203f2..032568e2318 100644 --- a/app/code/core/Mage/Adminhtml/Block/Widget/Grid/Column/Renderer/Abstract.php +++ b/app/code/core/Mage/Adminhtml/Block/Widget/Grid/Column/Renderer/Abstract.php @@ -38,12 +38,19 @@ abstract class Mage_Adminhtml_Block_Widget_Grid_Column_Renderer_Abstract protected $_defaultWidth; protected $_column; + /** + * @param Mage_Adminhtml_Block_Widget_Grid_Column $column + * @return $this + */ public function setColumn($column) { $this->_column = $column; return $this; } + /** + * @return Mage_Adminhtml_Block_Widget_Grid_Column + */ public function getColumn() { return $this->_column; @@ -77,6 +84,10 @@ public function renderExport(Varien_Object $row) return $this->render($row); } + /** + * @param Varien_Object $row + * @return string|null + */ protected function _getValue(Varien_Object $row) { if ($getter = $this->getColumn()->getGetter()) { @@ -90,6 +101,10 @@ protected function _getValue(Varien_Object $row) return $row->getData($this->getColumn()->getIndex()); } + /** + * @param Varien_Object $row + * @return string + */ public function _getInputValueElement(Varien_Object $row) { return ''; } + /** + * @param Varien_Object $row + * @return string|null + */ protected function _getInputValue(Varien_Object $row) { return $this->_getValue($row); } + /** + * @return string + */ public function renderHeader() { if (false !== $this->getColumn()->getGrid()->getSortable() && false !== $this->getColumn()->getSortable()) { @@ -121,6 +143,9 @@ public function renderHeader() return $out; } + /** + * @return string + */ public function renderProperty() { $out = ''; @@ -143,6 +168,9 @@ public function renderProperty() return $out; } + /** + * @return string|null + */ public function renderCss() { return $this->getColumn()->getCssClass(); diff --git a/app/code/core/Mage/Adminhtml/Block/Widget/Grid/Massaction/Abstract.php b/app/code/core/Mage/Adminhtml/Block/Widget/Grid/Massaction/Abstract.php index d26783797a1..d004ab4becb 100644 --- a/app/code/core/Mage/Adminhtml/Block/Widget/Grid/Massaction/Abstract.php +++ b/app/code/core/Mage/Adminhtml/Block/Widget/Grid/Massaction/Abstract.php @@ -289,4 +289,28 @@ public function setUseSelectAll($flag) $this->setData('use_select_all', (bool) $flag); return $this; } + + /** + * Group items for optgroups + * + * @return array + */ + public function getGroupedItems(): array + { + $groupedItems = [ + 'default' => [], + ]; + + foreach ($this->getItems() as $item) { + if ($item->getData('group')) { + $groupedItems['grouped'][$item->getData('group')][$item->getId()] = $item; + } + else { + $groupedItems['default'][$item->getId()] = $item; + } + } + + return $groupedItems; + } + } diff --git a/app/code/core/Mage/Adminhtml/Block/Widget/Grid/Massaction/Item.php b/app/code/core/Mage/Adminhtml/Block/Widget/Grid/Massaction/Item.php index 79bbc58f227..13eef8d893b 100644 --- a/app/code/core/Mage/Adminhtml/Block/Widget/Grid/Massaction/Item.php +++ b/app/code/core/Mage/Adminhtml/Block/Widget/Grid/Massaction/Item.php @@ -50,7 +50,7 @@ public function setMassaction($massaction) } /** - * Retrive parent massaction block + * Retrieve parent massaction block * * @return Mage_Adminhtml_Block_Widget_Grid_Massaction_Abstract */ @@ -87,7 +87,7 @@ protected function _createFromConfig(array $config) } /** - * Retrive additional action block for this item + * Retrieve additional action block for this item * * @return Mage_Core_Block_Abstract */ @@ -97,7 +97,7 @@ public function getAdditionalActionBlock() } /** - * Retrive additional action block HTML for this item + * Retrieve additional action block HTML for this item * * @return string */ diff --git a/app/code/core/Mage/Adminhtml/Controller/Rss/Abstract.php b/app/code/core/Mage/Adminhtml/Controller/Rss/Abstract.php index edb18e5ef0e..05e240516d0 100644 --- a/app/code/core/Mage/Adminhtml/Controller/Rss/Abstract.php +++ b/app/code/core/Mage/Adminhtml/Controller/Rss/Abstract.php @@ -41,7 +41,7 @@ class Mage_Adminhtml_Controller_Rss_Abstract extends Mage_Adminhtml_Controller_A */ protected function isFeedEnable($code) { - return $this->_getHelper('rss')->isRssEnabled() + return Mage::helper('rss')->isRssEnabled() && Mage::getStoreConfig('rss/'. $code); } @@ -69,6 +69,7 @@ protected function checkFeedEnable($code) * * @param string $name * @return Mage_Core_Helper_Abstract + * @deprecated this method is incompatible with parent class. Use Mage::helper instead */ protected function _getHelper($name) { diff --git a/app/code/core/Mage/Adminhtml/Helper/Catalog/Product/Edit/Action/Attribute.php b/app/code/core/Mage/Adminhtml/Helper/Catalog/Product/Edit/Action/Attribute.php index 7f80b492132..b198db134fb 100644 --- a/app/code/core/Mage/Adminhtml/Helper/Catalog/Product/Edit/Action/Attribute.php +++ b/app/code/core/Mage/Adminhtml/Helper/Catalog/Product/Edit/Action/Attribute.php @@ -37,7 +37,7 @@ class Mage_Adminhtml_Helper_Catalog_Product_Edit_Action_Attribute extends Mage_C /** * Selected products for mass-update * - * @var Mage_Catalog_Model_Entity_Product_Collection + * @var Mage_Catalog_Model_Resource_Product_Collection */ protected $_products; diff --git a/app/code/core/Mage/Adminhtml/Model/Giftmessage/Save.php b/app/code/core/Mage/Adminhtml/Model/Giftmessage/Save.php index b350491efd4..f52716b60da 100644 --- a/app/code/core/Mage/Adminhtml/Model/Giftmessage/Save.php +++ b/app/code/core/Mage/Adminhtml/Model/Giftmessage/Save.php @@ -178,7 +178,7 @@ public function addAllowQuoteItem($item) } /** - * Retrive allowed quote items for gift messages + * Retrieve allowed quote items for gift messages * * @return array */ @@ -192,7 +192,7 @@ public function getAllowQuoteItems() } /** - * Retrive allowed quote items products for gift messages + * Retrieve allowed quote items products for gift messages * * @return array */ @@ -307,7 +307,7 @@ public function importAllowQuoteItemsFromItems($items) } /** - * Retrive mapped type for entity + * Retrieve mapped type for entity * * @param string $type * @return string diff --git a/app/code/core/Mage/Adminhtml/Model/System/Config/Backend/Catalog/Search/Separator.php b/app/code/core/Mage/Adminhtml/Model/System/Config/Backend/Catalog/Search/Separator.php new file mode 100644 index 00000000000..269892b396e --- /dev/null +++ b/app/code/core/Mage/Adminhtml/Model/System/Config/Backend/Catalog/Search/Separator.php @@ -0,0 +1,24 @@ +getValue(); + $oldValue = Mage::getConfig()->getNode( + Mage_CatalogSearch_Model_Fulltext::XML_PATH_CATALOG_SEARCH_SEPARATOR, + $this->getScope(), + $this->getScopeId() + ); + if ($newValue != $oldValue) { + Mage::getSingleton('catalogsearch/fulltext')->resetSearchResults(); + } + + return $this; + } +} diff --git a/app/code/core/Mage/Adminhtml/Model/System/Config/Source/Catalog/Search/Separator.php b/app/code/core/Mage/Adminhtml/Model/System/Config/Source/Catalog/Search/Separator.php new file mode 100644 index 00000000000..7c149587fef --- /dev/null +++ b/app/code/core/Mage/Adminhtml/Model/System/Config/Source/Catalog/Search/Separator.php @@ -0,0 +1,20 @@ + 'OR', + 'label' => 'OR (default)' + ], [ + 'value' => 'AND', + 'label' => 'AND' + ] + ]; + } +} diff --git a/app/code/core/Mage/Adminhtml/Model/System/Config/Source/Language.php b/app/code/core/Mage/Adminhtml/Model/System/Config/Source/Language.php index 50b36923f2b..beb5bbef6da 100644 --- a/app/code/core/Mage/Adminhtml/Model/System/Config/Source/Language.php +++ b/app/code/core/Mage/Adminhtml/Model/System/Config/Source/Language.php @@ -28,7 +28,7 @@ class Mage_Adminhtml_Model_System_Config_Source_Language { protected $_options; - + public function toOptionArray($isMultiselect) { if (!$this->_options) { diff --git a/app/code/core/Mage/Adminhtml/Model/System/Config/Source/Locale.php b/app/code/core/Mage/Adminhtml/Model/System/Config/Source/Locale.php index d1f9f227b9a..36a3a5396d6 100644 --- a/app/code/core/Mage/Adminhtml/Model/System/Config/Source/Locale.php +++ b/app/code/core/Mage/Adminhtml/Model/System/Config/Source/Locale.php @@ -23,7 +23,7 @@ * @copyright Copyright (c) 2006-2020 Magento, Inc. (http://www.magento.com) * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) */ - + /** * Locale source * diff --git a/app/code/core/Mage/Adminhtml/Model/System/Config/Source/Locale/Country.php b/app/code/core/Mage/Adminhtml/Model/System/Config/Source/Locale/Country.php index 7c95364a8ea..ec6660a194a 100644 --- a/app/code/core/Mage/Adminhtml/Model/System/Config/Source/Locale/Country.php +++ b/app/code/core/Mage/Adminhtml/Model/System/Config/Source/Locale/Country.php @@ -23,7 +23,7 @@ * @copyright Copyright (c) 2006-2020 Magento, Inc. (http://www.magento.com) * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) */ - + /** * Locale country source * diff --git a/app/code/core/Mage/Adminhtml/Model/System/Config/Source/Locale/Currency.php b/app/code/core/Mage/Adminhtml/Model/System/Config/Source/Locale/Currency.php index aa0853aed72..e83878057a7 100644 --- a/app/code/core/Mage/Adminhtml/Model/System/Config/Source/Locale/Currency.php +++ b/app/code/core/Mage/Adminhtml/Model/System/Config/Source/Locale/Currency.php @@ -23,7 +23,7 @@ * @copyright Copyright (c) 2006-2020 Magento, Inc. (http://www.magento.com) * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) */ - + /** * Locale currency source * @@ -32,7 +32,7 @@ class Mage_Adminhtml_Model_System_Config_Source_Locale_Currency { protected $_option; - + public function toOptionArray() { return Mage::app()->getLocale()->getOptionCurrencies(); diff --git a/app/code/core/Mage/Adminhtml/Model/System/Config/Source/Locale/Timezone.php b/app/code/core/Mage/Adminhtml/Model/System/Config/Source/Locale/Timezone.php index 4484d2e0d9f..589e33a199c 100644 --- a/app/code/core/Mage/Adminhtml/Model/System/Config/Source/Locale/Timezone.php +++ b/app/code/core/Mage/Adminhtml/Model/System/Config/Source/Locale/Timezone.php @@ -23,7 +23,7 @@ * @copyright Copyright (c) 2006-2020 Magento, Inc. (http://www.magento.com) * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) */ - + /** * Locale timezone source * diff --git a/app/code/core/Mage/Adminhtml/Model/System/Config/Source/Store.php b/app/code/core/Mage/Adminhtml/Model/System/Config/Source/Store.php index 72377067981..811d4c73410 100644 --- a/app/code/core/Mage/Adminhtml/Model/System/Config/Source/Store.php +++ b/app/code/core/Mage/Adminhtml/Model/System/Config/Source/Store.php @@ -28,7 +28,7 @@ class Mage_Adminhtml_Model_System_Config_Source_Store { protected $_options; - + public function toOptionArray() { if (!$this->_options) { diff --git a/app/code/core/Mage/Adminhtml/controllers/Catalog/Product/DatafeedsController.php b/app/code/core/Mage/Adminhtml/controllers/Catalog/Product/DatafeedsController.php index 1163f3c236f..2cfa5e6e996 100644 --- a/app/code/core/Mage/Adminhtml/controllers/Catalog/Product/DatafeedsController.php +++ b/app/code/core/Mage/Adminhtml/controllers/Catalog/Product/DatafeedsController.php @@ -30,7 +30,7 @@ class Mage_Adminhtml_Catalog_DatafeedsController extends Mage_Adminhtml_Controll public function indexAction() { - + } /** diff --git a/app/code/core/Mage/Adminhtml/controllers/SurveyController.php b/app/code/core/Mage/Adminhtml/controllers/SurveyController.php deleted file mode 100644 index 36147bf7f89..00000000000 --- a/app/code/core/Mage/Adminhtml/controllers/SurveyController.php +++ /dev/null @@ -1,58 +0,0 @@ - - */ -class Mage_Adminhtml_SurveyController extends Mage_Adminhtml_Controller_Action -{ - /** - * Index Action - * - */ - public function indexAction() - { - if ($this->getRequest()->getParam('isAjax', false)) { - Mage_AdminNotification_Model_Survey::saveSurveyViewed(true); - } - $this->getResponse()->setBody(Zend_Json::encode(array('survey_decision_saved' => 1))); - } - - /** - * Check if user has enough privileges - * - * @return boolean - */ - protected function _isAllowed() - { - return Mage::getSingleton('admin/session')->isAllowed('all'); - } -} diff --git a/app/code/core/Mage/Adminhtml/controllers/System/BackupController.php b/app/code/core/Mage/Adminhtml/controllers/System/BackupController.php index 1cfc4d3e19e..ec71d43d4bf 100644 --- a/app/code/core/Mage/Adminhtml/controllers/System/BackupController.php +++ b/app/code/core/Mage/Adminhtml/controllers/System/BackupController.php @@ -375,7 +375,7 @@ protected function _isAllowed() } /** - * Retrive adminhtml session model + * Retrieve adminhtml session model * * @return Mage_Adminhtml_Model_Session */ diff --git a/app/code/core/Mage/Api/Controller/Action.php b/app/code/core/Mage/Api/Controller/Action.php index cd90c588bfe..4d91eb3cbdc 100644 --- a/app/code/core/Mage/Api/Controller/Action.php +++ b/app/code/core/Mage/Api/Controller/Action.php @@ -45,7 +45,7 @@ public function preDispatch() } /** - * Retrive webservice server + * Retrieve webservice server * * @return Mage_Api_Model_Server */ diff --git a/app/code/core/Mage/Api/Model/Server/Adapter/Interface.php b/app/code/core/Mage/Api/Model/Server/Adapter/Interface.php index 42391b79c56..085da6d39e9 100644 --- a/app/code/core/Mage/Api/Model/Server/Adapter/Interface.php +++ b/app/code/core/Mage/Api/Model/Server/Adapter/Interface.php @@ -42,7 +42,7 @@ interface Mage_Api_Model_Server_Adapter_Interface public function setHandler($handler); /** - * Retrive handler class name for webservice + * Retrieve handler class name for webservice * * @return string */ @@ -57,7 +57,7 @@ public function getHandler(); public function setController(Mage_Api_Controller_Action $controller); /** - * Retrive webservice api controller + * Retrieve webservice api controller * * @return Mage_Api_Controller_Action */ diff --git a/app/code/core/Mage/Api/Model/Server/Adapter/Soap.php b/app/code/core/Mage/Api/Model/Server/Adapter/Soap.php index e906fbe800e..45052665c8d 100644 --- a/app/code/core/Mage/Api/Model/Server/Adapter/Soap.php +++ b/app/code/core/Mage/Api/Model/Server/Adapter/Soap.php @@ -87,7 +87,7 @@ public function setHandler($handler) } /** - * Retrive handler class name for webservice + * Retrieve handler class name for webservice * * @return string */ @@ -109,7 +109,7 @@ public function setController(Mage_Api_Controller_Action $controller) } /** - * Retrive webservice api controller. If no controller have been set - emulate it by the use of Varien_Object + * Retrieve webservice api controller. If no controller have been set - emulate it by the use of Varien_Object * * @return Varien_Object */ diff --git a/app/code/core/Mage/Api/Model/Server/Adapter/Xmlrpc.php b/app/code/core/Mage/Api/Model/Server/Adapter/Xmlrpc.php index b56c4e868aa..abdf9eb453f 100644 --- a/app/code/core/Mage/Api/Model/Server/Adapter/Xmlrpc.php +++ b/app/code/core/Mage/Api/Model/Server/Adapter/Xmlrpc.php @@ -53,7 +53,7 @@ public function setHandler($handler) } /** - * Retrive handler class name for webservice + * Retrieve handler class name for webservice * * @return string */ @@ -75,7 +75,7 @@ public function setController(Mage_Api_Controller_Action $controller) } /** - * Retrive webservice api controller. If no controller have been set - emulate it by the use of Varien_Object + * Retrieve webservice api controller. If no controller have been set - emulate it by the use of Varien_Object * * @return Mage_Api_Controller_Action|Varien_Object */ diff --git a/app/code/core/Mage/Api/Model/Server/Handler/Abstract.php b/app/code/core/Mage/Api/Model/Server/Handler/Abstract.php index 9567b82a0cf..09d13fe9bcb 100644 --- a/app/code/core/Mage/Api/Model/Server/Handler/Abstract.php +++ b/app/code/core/Mage/Api/Model/Server/Handler/Abstract.php @@ -58,7 +58,7 @@ public function handlePhpError($errorCode, $errorMessage, $errorFile) /** - * Retrive webservice session + * Retrieve webservice session * * @return Mage_Api_Model_Session */ @@ -68,7 +68,7 @@ protected function _getSession() } /** - * Retrive webservice configuration + * Retrieve webservice configuration * * @return Mage_Api_Model_Config */ @@ -78,7 +78,7 @@ protected function _getConfig() } /** - * Retrive webservice server + * Retrieve webservice server * * @return Mage_Api_Model_Server */ @@ -147,7 +147,7 @@ protected function _fault($faultName, $resourceName = null, $customMessage = nul } /** - * Retrive webservice fault as array + * Retrieve webservice fault as array * * @param string $faultName * @param string $resourceName diff --git a/app/code/core/Mage/Api/Model/Wsdl/Config/Element.php b/app/code/core/Mage/Api/Model/Wsdl/Config/Element.php index e0c8b010fd8..b6ceb4e50d3 100644 --- a/app/code/core/Mage/Api/Model/Wsdl/Config/Element.php +++ b/app/code/core/Mage/Api/Model/Wsdl/Config/Element.php @@ -175,6 +175,7 @@ public function getAttributes($source, $namespace = null) * @param Varien_Simplexml_Element $source * @return array */ + #[\ReturnTypeWillChange] public function getChildren($source = null) { Mage::log('Use of deprecated method: '.__METHOD__); @@ -207,8 +208,9 @@ protected static function _getChildren($source) /** * Return if has children * - * @return boolean + * @return bool */ + #[\ReturnTypeWillChange] public function hasChildren() { if (!self::_getChildren($this)) { diff --git a/app/code/core/Mage/Api/etc/wsdl.xml b/app/code/core/Mage/Api/etc/wsdl.xml index 6b24d0d9a39..49b0a241e4d 100644 --- a/app/code/core/Mage/Api/etc/wsdl.xml +++ b/app/code/core/Mage/Api/etc/wsdl.xml @@ -83,7 +83,7 @@ - Login user and retrive session id + Login user and retrieve session id diff --git a/app/code/core/Mage/Api/etc/wsdl2.xml b/app/code/core/Mage/Api/etc/wsdl2.xml index fd9fe0d5dd3..fae9dc98c8e 100644 --- a/app/code/core/Mage/Api/etc/wsdl2.xml +++ b/app/code/core/Mage/Api/etc/wsdl2.xml @@ -152,7 +152,7 @@ - Login user and retrive session id + Login user and retrieve session id diff --git a/app/code/core/Mage/Api/etc/wsi.xml b/app/code/core/Mage/Api/etc/wsi.xml index 0db28ab2869..62f93bd4697 100644 --- a/app/code/core/Mage/Api/etc/wsi.xml +++ b/app/code/core/Mage/Api/etc/wsi.xml @@ -273,7 +273,7 @@ - Login user and retrive session id + Login user and retrieve session id diff --git a/app/code/core/Mage/Api2/Model/Renderer/Xml.php b/app/code/core/Mage/Api2/Model/Renderer/Xml.php index eda5015c50e..c411d14baa3 100644 --- a/app/code/core/Mage/Api2/Model/Renderer/Xml.php +++ b/app/code/core/Mage/Api2/Model/Renderer/Xml.php @@ -105,7 +105,7 @@ protected function _prepareData($data, $root = false) } } $data = $data instanceof Varien_Object ? $data->toArray() : (array)$data; - $isAssoc = !preg_match('/^\d+$/', implode(array_keys($data), '')); + $isAssoc = !preg_match('/^\d+$/', implode('', array_keys($data))); $preparedData = array(); foreach ($data as $key => $value) { diff --git a/app/code/core/Mage/Api2/Model/Resource/Validator/Fields.php b/app/code/core/Mage/Api2/Model/Resource/Validator/Fields.php index fbb8c73bac1..3a4a5e3421f 100644 --- a/app/code/core/Mage/Api2/Model/Resource/Validator/Fields.php +++ b/app/code/core/Mage/Api2/Model/Resource/Validator/Fields.php @@ -58,7 +58,7 @@ class Mage_Api2_Model_Resource_Validator_Fields extends Mage_Api2_Model_Resource * * @var array */ - protected $_requiredFields; + protected $_requiredFields = array(); /** * Construct. Set all depends. diff --git a/app/code/core/Mage/Backup/Model/Resource/Db.php b/app/code/core/Mage/Backup/Model/Resource/Db.php index 7a96221f13e..a24b480b737 100644 --- a/app/code/core/Mage/Backup/Model/Resource/Db.php +++ b/app/code/core/Mage/Backup/Model/Resource/Db.php @@ -176,7 +176,7 @@ protected function _quoteRow($tableName, array $row) } /** - * Retrive table partical data SQL insert + * Retrieve table partical data SQL insert * * @param string $tableName * @param int $count diff --git a/app/code/core/Mage/Bundle/Model/Product/Type.php b/app/code/core/Mage/Bundle/Model/Product/Type.php index 0aba1f4be83..5495f85f097 100644 --- a/app/code/core/Mage/Bundle/Model/Product/Type.php +++ b/app/code/core/Mage/Bundle/Model/Product/Type.php @@ -389,7 +389,7 @@ public function getOptionsCollection($product = null) } /** - * Retrive bundle selections collection based on used options + * Retrieve bundle selections collection based on used options * * @param array $optionIds * @param Mage_Catalog_Model_Product $product diff --git a/app/code/core/Mage/Bundle/Model/Resource/Option/Collection.php b/app/code/core/Mage/Bundle/Model/Resource/Option/Collection.php index 9807abdabc5..502b736958b 100644 --- a/app/code/core/Mage/Bundle/Model/Resource/Option/Collection.php +++ b/app/code/core/Mage/Bundle/Model/Resource/Option/Collection.php @@ -194,7 +194,7 @@ public function resetAllIds() } /** - * Retrive all ids for collection + * Retrieve all ids for collection * * @return array */ diff --git a/app/code/core/Mage/Catalog/Block/Breadcrumbs.php b/app/code/core/Mage/Catalog/Block/Breadcrumbs.php index 37c39211a5c..3547442b447 100644 --- a/app/code/core/Mage/Catalog/Block/Breadcrumbs.php +++ b/app/code/core/Mage/Catalog/Block/Breadcrumbs.php @@ -23,7 +23,7 @@ * @copyright Copyright (c) 2006-2020 Magento, Inc. (http://www.magento.com) * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) */ - + /** * Catalog breadcrumbs * diff --git a/app/code/core/Mage/Catalog/Block/Product/Abstract.php b/app/code/core/Mage/Catalog/Block/Product/Abstract.php index 9aa165eb0c3..e2028b9d2a1 100644 --- a/app/code/core/Mage/Catalog/Block/Product/Abstract.php +++ b/app/code/core/Mage/Catalog/Block/Product/Abstract.php @@ -383,15 +383,12 @@ public function getTierPriceHtml($product = null, $parent = null) ->callParentToHtml(); } - /* + /** * Calls the object's to Html method. * This method exists to make the code more testable. * By having a protected wrapper for the final method toHtml, we can 'mock' out this method * when unit testing * - * @return string - */ - /** * @return string */ protected function callParentToHtml() diff --git a/app/code/core/Mage/Catalog/Block/Product/List/Toolbar.php b/app/code/core/Mage/Catalog/Block/Product/List/Toolbar.php index cbfc5b428ce..41e714783da 100644 --- a/app/code/core/Mage/Catalog/Block/Product/List/Toolbar.php +++ b/app/code/core/Mage/Catalog/Block/Product/List/Toolbar.php @@ -569,7 +569,7 @@ public function setModes($modes) } /** - * Retrive URL for view mode + * Retrieve URL for view mode * * @param string $mode * @return string diff --git a/app/code/core/Mage/Catalog/Block/Product/View/Abstract.php b/app/code/core/Mage/Catalog/Block/Product/View/Abstract.php index 9016fb22823..4194ffa0932 100644 --- a/app/code/core/Mage/Catalog/Block/Product/View/Abstract.php +++ b/app/code/core/Mage/Catalog/Block/Product/View/Abstract.php @@ -34,7 +34,7 @@ abstract class Mage_Catalog_Block_Product_View_Abstract extends Mage_Catalog_Block_Product_Abstract { /** - * Retrive product + * Retrieve product * * @return Mage_Catalog_Model_Product */ diff --git a/app/code/core/Mage/Catalog/Exception.php b/app/code/core/Mage/Catalog/Exception.php index 1eaa89989a4..923875ce203 100644 --- a/app/code/core/Mage/Catalog/Exception.php +++ b/app/code/core/Mage/Catalog/Exception.php @@ -29,5 +29,5 @@ class Mage_Catalog_Exception extends Zend_Exception { - + } diff --git a/app/code/core/Mage/Catalog/Helper/Product/Compare.php b/app/code/core/Mage/Catalog/Helper/Product/Compare.php index a88581f3c68..a32160cbdd0 100644 --- a/app/code/core/Mage/Catalog/Helper/Product/Compare.php +++ b/app/code/core/Mage/Catalog/Helper/Product/Compare.php @@ -165,7 +165,7 @@ public function getAddUrl($product) } /** - * Retrive add to wishlist url + * Retrieve add to wishlist url * * @param Mage_Catalog_Model_Product $product * @return string @@ -176,7 +176,7 @@ public function getAddToWishlistUrl($product) } /** - * Retrive add to cart url + * Retrieve add to cart url * * @param Mage_Catalog_Model_Product $product * @return string @@ -361,7 +361,7 @@ public function getAddUrlCustom($product, $addFormKey = true) } /** - * Retrive add to wishlist url with or without Form Key + * Retrieve add to wishlist url with or without Form Key * * @param Mage_Catalog_Model_Product $product * @param bool $addFormKey @@ -376,7 +376,7 @@ public function getAddToWishlistUrlCustom($product, $addFormKey = true) } /** - * Retrive add to cart url with or without Form Key + * Retrieve add to cart url with or without Form Key * * @param Mage_Catalog_Model_Product $product * @param bool $addFormKey diff --git a/app/code/core/Mage/Catalog/Helper/Product/View.php b/app/code/core/Mage/Catalog/Helper/Product/View.php index 04be258a9ae..f1034643d86 100644 --- a/app/code/core/Mage/Catalog/Helper/Product/View.php +++ b/app/code/core/Mage/Catalog/Helper/Product/View.php @@ -117,7 +117,7 @@ public function prepareAndRender($productId, $controller, $params = null) $params = new Varien_Object(); } - // Standard algorithm to prepare and rendern product view page + // Standard algorithm to prepare and render a product view page $product = $productHelper->initProduct($productId, $controller, $params); if (!$product) { throw new Mage_Core_Exception($this->__('Product is not loaded'), $this->ERR_NO_PRODUCT_LOADED); diff --git a/app/code/core/Mage/Catalog/Model/Api/Resource.php b/app/code/core/Mage/Catalog/Model/Api/Resource.php index bce87a08706..39e94368163 100644 --- a/app/code/core/Mage/Catalog/Model/Api/Resource.php +++ b/app/code/core/Mage/Catalog/Model/Api/Resource.php @@ -86,7 +86,7 @@ protected function _isAllowedAttribute($attribute, $attributes = null) } /** - * Retrives store id from store code, if no store id specified, + * Retrieves store id from store code, if no store id specified, * it use seted session or admin store * * @param string|int $store diff --git a/app/code/core/Mage/Catalog/Model/Api2/Product/Rest.php b/app/code/core/Mage/Catalog/Model/Api2/Product/Rest.php index 749b2ea6f5f..451996d27b0 100644 --- a/app/code/core/Mage/Catalog/Model/Api2/Product/Rest.php +++ b/app/code/core/Mage/Catalog/Model/Api2/Product/Rest.php @@ -377,7 +377,7 @@ protected function _calculatePrice($price, $percent, $includeTax) } /** - * Retrive tier prices in special format + * Retrieve tier prices in special format * * @return array */ diff --git a/app/code/core/Mage/Catalog/Model/Api2/Product/Website/Rest.php b/app/code/core/Mage/Catalog/Model/Api2/Product/Website/Rest.php index f3085a12c6b..a87ec631f79 100644 --- a/app/code/core/Mage/Catalog/Model/Api2/Product/Website/Rest.php +++ b/app/code/core/Mage/Catalog/Model/Api2/Product/Website/Rest.php @@ -103,14 +103,13 @@ protected function _create(array $data) $this->_critical(self::RESOURCE_INTERNAL_ERROR); } - return $this->_getLocation($website, $product); + return $this->_getLocation($website); } /** * Product website assign * * @param array $data - * @return string */ protected function _multiCreate(array $data) { diff --git a/app/code/core/Mage/Catalog/Model/Category.php b/app/code/core/Mage/Catalog/Model/Category.php index d6dddcd085c..3fdf7a1f987 100644 --- a/app/code/core/Mage/Catalog/Model/Category.php +++ b/app/code/core/Mage/Catalog/Model/Category.php @@ -470,13 +470,13 @@ public function getStoreId() /** * Set store id * - * @param integer $storeId + * @param string|int|Mage_Core_Model_Store $storeId * @return $this */ public function setStoreId($storeId) { if (!is_numeric($storeId)) { - $storeId = Mage::app($storeId)->getStore()->getId(); + $storeId = Mage::app()->getStore($storeId)->getId(); } $this->setData('store_id', $storeId); $this->getResource()->setStoreId($storeId); diff --git a/app/code/core/Mage/Catalog/Model/Category/Api.php b/app/code/core/Mage/Catalog/Model/Category/Api.php index ab5c940c740..1703be132f6 100644 --- a/app/code/core/Mage/Catalog/Model/Category/Api.php +++ b/app/code/core/Mage/Catalog/Model/Category/Api.php @@ -404,11 +404,14 @@ public function delete($categoryId) } /** - * Get prduct Id from sku or from product id + * Get the product ID from a product ID or SKU. When $identifierType is left empty the helper will try to + * automatically parse the given $productId and determine if it is a SKU or ID value + * + * @param int|string $productId The product ID or SKU + * @param null|string $identifierType Should be 'sku' when working with SKU's. Leave null when using ID's * - * @param int|string $productId - * @param string $identifierType * @return int + * @throws Mage_Api_Exception */ protected function _getProductId($productId, $identifierType = null) { @@ -456,7 +459,8 @@ public function assignedProducts($categoryId, $store = null) * @param int $categoryId * @param int $productId * @param int $position - * @param null $identifierType + * @param null|string $identifierType Should be 'sku' when working with SKU's. Leave null when using ID's + * @return boolean * @throws Mage_Api_Exception */ @@ -464,7 +468,7 @@ public function assignProduct($categoryId, $productId, $position = null, $identi { $category = $this->_initCategory($categoryId); $positions = $category->getProductsPosition(); - $productId = $this->_getProductId($productId); + $productId = $this->_getProductId($productId, $identifierType); $positions[$productId] = $position; $category->setPostedProducts($positions); diff --git a/app/code/core/Mage/Catalog/Model/Category/Attribute/Source/Page.php b/app/code/core/Mage/Catalog/Model/Category/Attribute/Source/Page.php index 356aac88e1a..d4d4547dca9 100644 --- a/app/code/core/Mage/Catalog/Model/Category/Attribute/Source/Page.php +++ b/app/code/core/Mage/Catalog/Model/Category/Attribute/Source/Page.php @@ -40,6 +40,7 @@ public function getAllOptions() { if (!$this->_options) { $this->_options = Mage::getResourceModel('cms/block_collection') + ->setOrder('title', 'ASC') ->load() ->toOptionArray(); array_unshift($this->_options, array('value'=>'', 'label'=>Mage::helper('catalog')->__('Please select a static block ...'))); diff --git a/app/code/core/Mage/Catalog/Model/Convert/Adapter/Product.php b/app/code/core/Mage/Catalog/Model/Convert/Adapter/Product.php index d892c02fce7..98d7ab8e744 100644 --- a/app/code/core/Mage/Catalog/Model/Convert/Adapter/Product.php +++ b/app/code/core/Mage/Catalog/Model/Convert/Adapter/Product.php @@ -503,7 +503,7 @@ public function save() } $collections = $this->getData(); - if ($collections instanceof Mage_Catalog_Model_Entity_Product_Collection) { + if ($collections instanceof Mage_Catalog_Model_Resource_Product_Collection) { $collections = array($collections->getEntity()->getStoreId()=>$collections); } elseif (!is_array($collections)) { $this->addException( @@ -517,7 +517,7 @@ public function save() foreach ($collections as $storeId => $collection) { $this->addException(Mage::helper('catalog')->__('Records for "%s" store found.', $stores[$storeId])); - if (!$collection instanceof Mage_Catalog_Model_Entity_Product_Collection) { + if (!$collection instanceof Mage_Catalog_Model_Resource_Product_Collection) { $this->addException( Mage::helper('catalog')->__('Product collection expected.'), Mage_Dataflow_Model_Convert_Exception::FATAL diff --git a/app/code/core/Mage/Catalog/Model/Design.php b/app/code/core/Mage/Catalog/Model/Design.php index 36b85112bce..875373544f8 100644 --- a/app/code/core/Mage/Catalog/Model/Design.php +++ b/app/code/core/Mage/Catalog/Model/Design.php @@ -88,7 +88,7 @@ protected function _apply($package, $theme) * Apply custom design * * @param string $design - * @return bool + * @return null|false */ public function applyCustomDesign($design) { diff --git a/app/code/core/Mage/Catalog/Model/Product.php b/app/code/core/Mage/Catalog/Model/Product.php index 6ed5dfebf87..5dd0a324793 100644 --- a/app/code/core/Mage/Catalog/Model/Product.php +++ b/app/code/core/Mage/Catalog/Model/Product.php @@ -540,7 +540,7 @@ public function getLinkInstance() } /** - * Retrive product id by sku + * Retrieve product id by sku * * @param string $sku * @return integer @@ -1223,7 +1223,7 @@ public function getGroupedLinkCollection() ** Media API */ /** - * Retrive attributes for media gallery + * Retrieve attributes for media gallery * * @return Mage_Catalog_Model_Resource_Eav_Attribute[] */ @@ -1242,7 +1242,7 @@ public function getMediaAttributes() } /** - * Retrive media gallery images + * Retrieve media gallery images * * @return Varien_Data_Collection */ @@ -1288,7 +1288,7 @@ public function addImageToMediaGallery($file, $mediaAttribute = null, $move = fa } /** - * Retrive product media config + * Retrieve product media config * * @return Mage_Catalog_Model_Product_Media_Config */ diff --git a/app/code/core/Mage/Catalog/Model/Product/Attribute/Api.php b/app/code/core/Mage/Catalog/Model/Product/Attribute/Api.php index fc43eb7b1ad..cc3a2f223e9 100644 --- a/app/code/core/Mage/Catalog/Model/Product/Attribute/Api.php +++ b/app/code/core/Mage/Catalog/Model/Product/Attribute/Api.php @@ -217,10 +217,10 @@ public function update($attribute, $data) $model->save(); // clear translation cache because attribute labels are stored in translation Mage::app()->cleanCache(array(Mage_Core_Model_Translate::CACHE_TAG)); - return true; } catch (Exception $e) { $this->_fault('unable_to_save', $e->getMessage()); } + return true; } /** diff --git a/app/code/core/Mage/Catalog/Model/Product/Attribute/Backend/Media.php b/app/code/core/Mage/Catalog/Model/Product/Attribute/Backend/Media.php index 550faa7351f..224c7951219 100644 --- a/app/code/core/Mage/Catalog/Model/Product/Attribute/Backend/Media.php +++ b/app/code/core/Mage/Catalog/Model/Product/Attribute/Backend/Media.php @@ -235,7 +235,6 @@ public function afterSave($object) } $toDelete = array(); - $filesToValueIds = array(); foreach ($value['images'] as &$image) { if (!empty($image['removed'])) { if (isset($image['value_id']) && !isset($picturesInOtherStores[$image['file']])) { @@ -278,6 +277,7 @@ public function afterSave($object) * @param boolean $move if true, it will move source file * @param boolean $exclude mark image as disabled in product page view * @return string + * @throws Mage_Core_Exception */ public function addImage( Mage_Catalog_Model_Product $product, @@ -376,6 +376,7 @@ public function addImage( * @param boolean $move if true, it will move source file * @param boolean $exclude mark image as disabled in product page view * @return array array of parallel arrays with original and renamed files + * @throws Mage_Core_Exception */ public function addImagesWithDifferentMediaAttributes( Mage_Catalog_Model_Product $product, @@ -474,7 +475,7 @@ public function removeImage(Mage_Catalog_Model_Product $product, $file) } /** - * Retrive image from gallery + * Retrieve image from gallery * * @param Mage_Catalog_Model_Product $product * @param string $file @@ -557,7 +558,7 @@ protected function _getResource() } /** - * Retrive media config + * Retrieve media config * * @return Mage_Catalog_Model_Product_Media_Config */ @@ -637,6 +638,7 @@ protected function _getUniqueFileName($file, $dirsep) * * @param string $file * @return string + * @throws Mage_Core_Exception */ protected function _copyImage($file) { diff --git a/app/code/core/Mage/Catalog/Model/Product/Option/Api/V2.php b/app/code/core/Mage/Catalog/Model/Product/Option/Api/V2.php index 51de8a495a0..65c8775b32f 100644 --- a/app/code/core/Mage/Catalog/Model/Product/Option/Api/V2.php +++ b/app/code/core/Mage/Catalog/Model/Product/Option/Api/V2.php @@ -69,7 +69,7 @@ public function update($optionId, $data, $store = null) * @param int|string|null $store * @return array */ - public function items($productId, $store) + public function items($productId, $store = null) { $result = parent::items($productId, $store); foreach ($result as $key => $option) { diff --git a/app/code/core/Mage/Catalog/Model/Product/Type/Abstract.php b/app/code/core/Mage/Catalog/Model/Product/Type/Abstract.php index e9d524aa202..6351912ef43 100644 --- a/app/code/core/Mage/Catalog/Model/Product/Type/Abstract.php +++ b/app/code/core/Mage/Catalog/Model/Product/Type/Abstract.php @@ -828,7 +828,7 @@ public function hasRequiredOptions($product = null) } /** - * Retrive store filter for associated products + * Retrieve store filter for associated products * * @param null $product * @return int|Mage_Core_Model_Store diff --git a/app/code/core/Mage/Catalog/Model/Resource/Abstract.php b/app/code/core/Mage/Catalog/Model/Resource/Abstract.php index c48213808c4..e568d91ef2b 100644 --- a/app/code/core/Mage/Catalog/Model/Resource/Abstract.php +++ b/app/code/core/Mage/Catalog/Model/Resource/Abstract.php @@ -634,7 +634,7 @@ public function getAttributeRawValue($entityId, $attribute, $store) if ($staticAttributes) { $select = $adapter->select()->from($staticTable, $staticAttributes) ->where($this->getEntityIdField() . ' = :entity_id'); - $attributesData = $adapter->fetchRow($select, array('entity_id' => $entityId)); + $attributesData = $adapter->fetchRow($select, array('entity_id' => $entityId)) ?: []; } /** @@ -646,7 +646,7 @@ public function getAttributeRawValue($entityId, $attribute, $store) } $store = (int)$store; - + foreach ($typedAttributes as $table => $_attributes) { $select = $adapter->select() ->from(array('default_value' => $table), array('attribute_id')) diff --git a/app/code/core/Mage/Catalog/Model/Resource/Eav/Attribute.php b/app/code/core/Mage/Catalog/Model/Resource/Eav/Attribute.php index 0b58e93c3c4..be8f4203a1b 100644 --- a/app/code/core/Mage/Catalog/Model/Resource/Eav/Attribute.php +++ b/app/code/core/Mage/Catalog/Model/Resource/Eav/Attribute.php @@ -29,45 +29,45 @@ * * @method Mage_Catalog_Model_Resource_Attribute _getResource() * @method Mage_Catalog_Model_Resource_Attribute getResource() - * @method $this getFrontendInputRenderer() - * @method string setFrontendInputRenderer(string $value) - * @method int setIsGlobal(int $value) - * @method $this getIsVisible() - * @method int setIsVisible(int $value) - * @method $this getIsSearchable() - * @method int setIsSearchable(int $value) - * @method $this getSearchWeight() - * @method int setSearchWeight(int $value) - * @method $this getIsFilterable() - * @method int setIsFilterable(int $value) - * @method $this getIsComparable() - * @method int setIsComparable(int $value) - * @method int setIsVisibleOnFront(int $value) - * @method $this getIsHtmlAllowedOnFront() - * @method int setIsHtmlAllowedOnFront(int $value) - * @method $this getIsUsedForPriceRules() - * @method int setIsUsedForPriceRules(int $value) - * @method $this getIsFilterableInSearch() - * @method int setIsFilterableInSearch(int $value) - * @method $this getUsedInProductListing() - * @method int setUsedInProductListing(int $value) - * @method $this getUsedForSortBy() - * @method int setUsedForSortBy(int $value) - * @method $this getIsConfigurable() - * @method int setIsConfigurable(int $value) - * @method string setApplyTo(string $value) - * @method $this getIsVisibleInAdvancedSearch() - * @method int setIsVisibleInAdvancedSearch(int $value) - * @method $this getPosition() - * @method int setPosition(int $value) - * @method $this getIsWysiwygEnabled() - * @method int setIsWysiwygEnabled(int $value) - * @method $this getIsUsedForPromoRules() - * @method int setIsUsedForPromoRules(int $value) - * @method $this getIsUsedForCustomerSegment() - * @method int setIsUsedForCustomerSegment(int $value) - * @method $this getIsUsedForTargetRules() - * @method int setIsUsedForTargetRules(int $value) + * @method string getFrontendInputRenderer() + * @method $this setFrontendInputRenderer(string $value) + * @method $this setIsGlobal(int $value) + * @method int getIsVisible() + * @method $this setIsVisible(int $value) + * @method int getIsSearchable() + * @method $this setIsSearchable(int $value) + * @method int getSearchWeight() + * @method $this setSearchWeight(int $value) + * @method int getIsFilterable() + * @method $this setIsFilterable(int $value) + * @method int getIsComparable() + * @method $this setIsComparable(int $value) + * @method $this setIsVisibleOnFront(int $value) + * @method int getIsHtmlAllowedOnFront() + * @method $this setIsHtmlAllowedOnFront(int $value) + * @method int getIsUsedForPriceRules() + * @method $this setIsUsedForPriceRules(int $value) + * @method int getIsFilterableInSearch() + * @method $this setIsFilterableInSearch(int $value) + * @method int getUsedInProductListing() + * @method $this setUsedInProductListing(int $value) + * @method int getUsedForSortBy() + * @method $this setUsedForSortBy(int $value) + * @method int getIsConfigurable() + * @method $this setIsConfigurable(int $value) + * @method $this setApplyTo(string $value) + * @method int getIsVisibleInAdvancedSearch() + * @method $this setIsVisibleInAdvancedSearch(int $value) + * @method int getPosition() + * @method $this setPosition(int $value) + * @method int getIsWysiwygEnabled() + * @method $this setIsWysiwygEnabled(int $value) + * @method int getIsUsedForPromoRules() + * @method $this setIsUsedForPromoRules(int $value) + * @method int getIsUsedForCustomerSegment() + * @method $this setIsUsedForCustomerSegment(int $value) + * @method int getIsUsedForTargetRules() + * @method $this setIsUsedForTargetRules(int $value) * @method bool getIsUserDefined() * * @category Mage diff --git a/app/code/core/Mage/Catalog/Model/Resource/Product/Attribute/Backend/Media.php b/app/code/core/Mage/Catalog/Model/Resource/Product/Attribute/Backend/Media.php index 5180a6b2992..6c220fc0bdb 100644 --- a/app/code/core/Mage/Catalog/Model/Resource/Product/Attribute/Backend/Media.php +++ b/app/code/core/Mage/Catalog/Model/Resource/Product/Attribute/Backend/Media.php @@ -108,7 +108,7 @@ protected function _removeDuplicates(&$result) } /** - * Insert gallery value to db and retrive last id + * Insert gallery value to db and retrieve last id * * @param array $data * @return int diff --git a/app/code/core/Mage/Catalog/Model/Resource/Product/Collection.php b/app/code/core/Mage/Catalog/Model/Resource/Product/Collection.php index f7bfaffb1be..fbe8d104dfc 100644 --- a/app/code/core/Mage/Catalog/Model/Resource/Product/Collection.php +++ b/app/code/core/Mage/Catalog/Model/Resource/Product/Collection.php @@ -966,7 +966,7 @@ protected function _buildClearSelect($select = null) } /** - * Retrive all ids for collection + * Retrieve all ids for collection * * @inheritDoc */ diff --git a/app/code/core/Mage/Catalog/Model/Resource/Product/Compare/Item/Collection.php b/app/code/core/Mage/Catalog/Model/Resource/Product/Compare/Item/Collection.php index b3920a56c88..9b44f6723ce 100644 --- a/app/code/core/Mage/Catalog/Model/Resource/Product/Compare/Item/Collection.php +++ b/app/code/core/Mage/Catalog/Model/Resource/Product/Compare/Item/Collection.php @@ -237,7 +237,7 @@ public function getComparableAttributes() array('store_label' => new Zend_Db_Expr('IFNULL(al.value, main_table.frontend_label)')) ) ->joinLeft( - array('ai' => $this->getTable('eav/entity_attribute')), + array('ai' => $this->getTable('eav/entity_attribute')), 'ai.attribute_id = main_table.attribute_id' ) ->where('additional_table.is_comparable=?', 1) diff --git a/app/code/core/Mage/Catalog/Model/Resource/Product/Indexer/Price/Default.php b/app/code/core/Mage/Catalog/Model/Resource/Product/Indexer/Price/Default.php index 097ef8e1286..b4bc135e096 100644 --- a/app/code/core/Mage/Catalog/Model/Resource/Product/Indexer/Price/Default.php +++ b/app/code/core/Mage/Catalog/Model/Resource/Product/Indexer/Price/Default.php @@ -389,11 +389,6 @@ protected function _applyCustomOption() 'csg.group_id = cw.default_group_id', array() ) - ->join( - array('cs' => $this->getTable('core/store')), - 'cs.store_id = csg.default_store_id', - array() - ) ->join( array('o' => $this->getTable('catalog/product_option')), 'o.product_id = i.entity_id', @@ -411,7 +406,7 @@ protected function _applyCustomOption() ) ->joinLeft( array('otps' => $this->getTable('catalog/product_option_type_price')), - 'otps.option_type_id = otpd.option_type_id AND otpd.store_id = cs.store_id', + 'otps.option_type_id = otpd.option_type_id AND otps.store_id = csg.default_store_id', array() ) ->group(array('i.entity_id', 'i.customer_group_id', 'i.website_id', 'o.option_id')); @@ -468,11 +463,6 @@ protected function _applyCustomOption() 'csg.group_id = cw.default_group_id', array() ) - ->join( - array('cs' => $this->getTable('core/store')), - 'cs.store_id = csg.default_store_id', - array() - ) ->join( array('o' => $this->getTable('catalog/product_option')), 'o.product_id = i.entity_id', @@ -485,7 +475,7 @@ protected function _applyCustomOption() ) ->joinLeft( array('ops' => $this->getTable('catalog/product_option_price')), - 'ops.option_id = opd.option_id AND ops.store_id = cs.store_id', + 'ops.option_id = opd.option_id AND ops.store_id = csg.default_store_id', array() ); diff --git a/app/code/core/Mage/Catalog/Model/Resource/Product/Type/Configurable/Attribute/Collection.php b/app/code/core/Mage/Catalog/Model/Resource/Product/Type/Configurable/Attribute/Collection.php index da0e4dcf9c9..7474326c30d 100644 --- a/app/code/core/Mage/Catalog/Model/Resource/Product/Type/Configurable/Attribute/Collection.php +++ b/app/code/core/Mage/Catalog/Model/Resource/Product/Type/Configurable/Attribute/Collection.php @@ -318,7 +318,7 @@ protected function _loadPrices() } /** - * Retrive product instance + * Retrieve product instance * * @return Mage_Catalog_Model_Product */ diff --git a/app/code/core/Mage/CatalogRule/Model/Action/Index/Refresh.php b/app/code/core/Mage/CatalogRule/Model/Action/Index/Refresh.php index d7a76c90edd..bc54aa6e935 100644 --- a/app/code/core/Mage/CatalogRule/Model/Action/Index/Refresh.php +++ b/app/code/core/Mage/CatalogRule/Model/Action/Index/Refresh.php @@ -561,7 +561,7 @@ protected function _prepareIndexSelect(Mage_Core_Model_Website $website, $time) new Zend_Db_Expr($this->_connection->getUnixTimestamp('dates.rule_date') . " <= to_time") ) ) - ->group(array('customer_group_id', 'product_id', 'dates.rule_date')); + ->group(array('customer_group_id', 'product_id', 'dates.rule_date', 'website_id')); return $select; } @@ -590,7 +590,9 @@ protected function _fillIndexData(Mage_Core_Model_Website $website, $time) $this->_connection->query( $this->_connection->insertFromSelect( $this->_prepareIndexSelect($website, $time), - $this->_resource->getTable('catalogrule/rule_product_price') + $this->_resource->getTable('catalogrule/rule_product_price'), + [], + Varien_Db_Adapter_Interface::INSERT_IGNORE ) ); } diff --git a/app/code/core/Mage/CatalogRule/Model/Rule/Condition/Product.php b/app/code/core/Mage/CatalogRule/Model/Rule/Condition/Product.php index ec7b1c3542a..9dd400c4d64 100644 --- a/app/code/core/Mage/CatalogRule/Model/Rule/Condition/Product.php +++ b/app/code/core/Mage/CatalogRule/Model/Rule/Condition/Product.php @@ -114,7 +114,10 @@ protected function _getAttributeValue($object) protected function _prepareDatetimeValue($value, $object) { $attribute = $object->getResource()->getAttribute($this->getAttribute()); - if ($attribute && $attribute->getBackendType() == 'datetime') { + if ($attribute && $attribute->getBackendType() === 'datetime') { + if (!$value) { + return null; + } $value = strtotime($value); } return $value; diff --git a/app/code/core/Mage/CatalogSearch/Model/Fulltext.php b/app/code/core/Mage/CatalogSearch/Model/Fulltext.php index a1bebe26b30..886e8a3f22f 100644 --- a/app/code/core/Mage/CatalogSearch/Model/Fulltext.php +++ b/app/code/core/Mage/CatalogSearch/Model/Fulltext.php @@ -48,6 +48,7 @@ class Mage_CatalogSearch_Model_Fulltext extends Mage_Core_Model_Abstract const SEARCH_TYPE_FULLTEXT = 2; const SEARCH_TYPE_COMBINE = 3; const XML_PATH_CATALOG_SEARCH_TYPE = 'catalog/search/search_type'; + const XML_PATH_CATALOG_SEARCH_SEPARATOR = 'catalog/search/search_separator'; /** * Whether table changes are allowed diff --git a/app/code/core/Mage/CatalogSearch/Model/Mysql4/Indexer/Fulltext.php b/app/code/core/Mage/CatalogSearch/Model/Mysql4/Indexer/Fulltext.php index 82077cf6176..3629f237021 100644 --- a/app/code/core/Mage/CatalogSearch/Model/Mysql4/Indexer/Fulltext.php +++ b/app/code/core/Mage/CatalogSearch/Model/Mysql4/Indexer/Fulltext.php @@ -35,5 +35,5 @@ */ class Mage_CatalogSearch_Model_Mysql4_Indexer_Fulltext extends Mage_CatalogSearch_Model_Resource_Indexer_Fulltext { - + } diff --git a/app/code/core/Mage/CatalogSearch/Model/Resource/Fulltext.php b/app/code/core/Mage/CatalogSearch/Model/Resource/Fulltext.php index c2e4c3bd5ea..a13e7a872fc 100644 --- a/app/code/core/Mage/CatalogSearch/Model/Resource/Fulltext.php +++ b/app/code/core/Mage/CatalogSearch/Model/Resource/Fulltext.php @@ -355,7 +355,8 @@ public function prepareResult($object, $queryText, $query) } if ($like) { - $likeCond = '(' . implode(' OR ', $like) . ')'; + $separator = Mage::getStoreConfig(Mage_CatalogSearch_Model_Fulltext::XML_PATH_CATALOG_SEARCH_SEPARATOR); + $likeCond = '(' . implode(' ' . $separator . ' ', $like) . ')'; } } diff --git a/app/code/core/Mage/CatalogSearch/Model/Resource/Query/Collection.php b/app/code/core/Mage/CatalogSearch/Model/Resource/Query/Collection.php index cec93d849ac..f0e178ff010 100644 --- a/app/code/core/Mage/CatalogSearch/Model/Resource/Query/Collection.php +++ b/app/code/core/Mage/CatalogSearch/Model/Resource/Query/Collection.php @@ -119,7 +119,7 @@ public function setPopularQueryFilter($storeIds = null) ->distinct(true) ->from( array('main_table' => $this->getTable('catalogsearch/search_query')), - array('name' => $ifSynonymFor, 'num_results', 'popularity') + array('name' => $ifSynonymFor, 'num_results', 'popularity', 'query_id') ); if ($storeIds) { $this->addStoreFilter($storeIds); diff --git a/app/code/core/Mage/CatalogSearch/etc/config.xml b/app/code/core/Mage/CatalogSearch/etc/config.xml index 1b9d82a4393..965cb612d95 100644 --- a/app/code/core/Mage/CatalogSearch/etc/config.xml +++ b/app/code/core/Mage/CatalogSearch/etc/config.xml @@ -137,6 +137,7 @@ 128 10 1 + OR 2000 1 diff --git a/app/code/core/Mage/CatalogSearch/etc/system.xml b/app/code/core/Mage/CatalogSearch/etc/system.xml index 32f8fda4deb..0c93c89ad8d 100644 --- a/app/code/core/Mage/CatalogSearch/etc/system.xml +++ b/app/code/core/Mage/CatalogSearch/etc/system.xml @@ -98,6 +98,16 @@ 1 1 + + + select + adminhtml/system_config_backend_catalog_search_separator + adminhtml/system_config_source_catalog_search_separator + 22 + 1 + 1 + 1 + text diff --git a/app/code/core/Mage/Checkout/Exception.php b/app/code/core/Mage/Checkout/Exception.php index 0844f1f2e78..f6185b81f1d 100644 --- a/app/code/core/Mage/Checkout/Exception.php +++ b/app/code/core/Mage/Checkout/Exception.php @@ -29,5 +29,5 @@ class Mage_Checkout_Exception extends Zend_Exception { - + } diff --git a/app/code/core/Mage/Checkout/Model/Cart/Api/V2.php b/app/code/core/Mage/Checkout/Model/Cart/Api/V2.php index 14cd5543db3..e46a3f2cff5 100644 --- a/app/code/core/Mage/Checkout/Model/Cart/Api/V2.php +++ b/app/code/core/Mage/Checkout/Model/Cart/Api/V2.php @@ -33,5 +33,5 @@ */ class Mage_Checkout_Model_Cart_Api_V2 extends Mage_Checkout_Model_Cart_Api { - + } diff --git a/app/code/core/Mage/Checkout/Model/Cart/Customer/Api/V2.php b/app/code/core/Mage/Checkout/Model/Cart/Customer/Api/V2.php index f1dc4ce51f0..9aa11ba043b 100644 --- a/app/code/core/Mage/Checkout/Model/Cart/Customer/Api/V2.php +++ b/app/code/core/Mage/Checkout/Model/Cart/Customer/Api/V2.php @@ -64,7 +64,7 @@ protected function _prepareCustomerAddressData($data) } return parent::_prepareCustomerAddressData($dataAddresses); } - + return null; } } diff --git a/app/code/core/Mage/Checkout/Model/Cart/Shipping/Api.php b/app/code/core/Mage/Checkout/Model/Cart/Shipping/Api.php index 7e84c73ff0e..98884642909 100644 --- a/app/code/core/Mage/Checkout/Model/Cart/Shipping/Api.php +++ b/app/code/core/Mage/Checkout/Model/Cart/Shipping/Api.php @@ -106,7 +106,7 @@ public function getShippingMethodsList($quoteId, $store = null) } } } catch (Mage_Core_Exception $e) { - $this->_fault('shipping_methods_list_could_not_be_retrived', $e->getMessage()); + $this->_fault('shipping_methods_list_could_not_be_retrieved', $e->getMessage()); } return $ratesResult; diff --git a/app/code/core/Mage/Checkout/Model/Session.php b/app/code/core/Mage/Checkout/Model/Session.php index 4ec71794344..9e6595866fe 100644 --- a/app/code/core/Mage/Checkout/Model/Session.php +++ b/app/code/core/Mage/Checkout/Model/Session.php @@ -326,7 +326,7 @@ public function loadCustomerQuote() * Set step data for given checkout step (e.g. "billing"). * By providing the two parameters data and value, the data will be added to existing step data. * By providing an associative array [data => value, ...] the existing step data will be replaced. - * + * * @param string $step * @param array|string $data * @param mixed|null $value diff --git a/app/code/core/Mage/Checkout/etc/api.xml b/app/code/core/Mage/Checkout/etc/api.xml index cda12908144..444061e0792 100644 --- a/app/code/core/Mage/Checkout/etc/api.xml +++ b/app/code/core/Mage/Checkout/etc/api.xml @@ -288,10 +288,10 @@ 1063 Can not set shipping method. - + 1064 Can not receive list of shipping methods. - + diff --git a/app/code/core/Mage/Checkout/etc/system.xml b/app/code/core/Mage/Checkout/etc/system.xml index 60c78c00ce9..6c79a424b35 100644 --- a/app/code/core/Mage/Checkout/etc/system.xml +++ b/app/code/core/Mage/Checkout/etc/system.xml @@ -71,7 +71,7 @@ 1 1 0 - + select diff --git a/app/code/core/Mage/Cms/Model/Wysiwyg/Images/Storage/Collection.php b/app/code/core/Mage/Cms/Model/Wysiwyg/Images/Storage/Collection.php index 98d1d605b32..c1f63b7986c 100644 --- a/app/code/core/Mage/Cms/Model/Wysiwyg/Images/Storage/Collection.php +++ b/app/code/core/Mage/Cms/Model/Wysiwyg/Images/Storage/Collection.php @@ -39,7 +39,7 @@ class Mage_Cms_Model_Wysiwyg_Images_Storage_Collection extends Varien_Data_Colle protected function _generateRow($filename) { $filename = preg_replace('~[/\\\]+~', DIRECTORY_SEPARATOR, $filename); - + return array( 'filename' => $filename, 'basename' => basename($filename), diff --git a/app/code/core/Mage/Core/Block/Template/Smarty.php b/app/code/core/Mage/Core/Block/Template/Smarty.php index cd732fd5cb2..4b3c4555279 100644 --- a/app/code/core/Mage/Core/Block/Template/Smarty.php +++ b/app/code/core/Mage/Core/Block/Template/Smarty.php @@ -27,5 +27,5 @@ class Mage_Core_Block_Template_Smarty extends Mage_Core_Block_Template { - + } diff --git a/app/code/core/Mage/Core/Controller/Front/Router.php b/app/code/core/Mage/Core/Controller/Front/Router.php index 196a2132b25..be6007dbcbb 100644 --- a/app/code/core/Mage/Core/Controller/Front/Router.php +++ b/app/code/core/Mage/Core/Controller/Front/Router.php @@ -56,7 +56,7 @@ public function addRoutes(Zend_Controller_Router_Interface $router) $routeParams = array('module'=>$moduleName, 'controller'=>'index', 'action'=>'index', '_frontName'=>$frontName); $route = new Zend_Controller_Router_Route($routeMatch, $routeParams); $router->addRoute($moduleName, $route); - + return $this; } @@ -67,12 +67,12 @@ public function addRoutes(Zend_Controller_Router_Interface $router) public function getUrl($params = array()) { static $reservedKeys = array('module'=>1, 'controller'=>1, 'action'=>1, 'array'=>1); - + if (is_string($params)) { $paramsArr = explode('/', $params); $params = array('controller'=>$paramsArr[0], 'action'=>$paramsArr[1]); } - + $url = Mage::getBaseUrl($params); if (!empty($params['frontName'])) { @@ -80,7 +80,7 @@ public function getUrl($params = array()) } else { $url .= $this->_config->getName().'/'; } - + if (!empty($params)) { $paramsStr = ''; foreach ($params as $key => $value) { @@ -88,19 +88,19 @@ public function getUrl($params = array()) $paramsStr .= $key.'/'.$value.'/'; } } - + if (empty($params['controller']) && !empty($paramsStr)) { $params['controller'] = 'index'; } $url .= empty($params['controller']) ? '' : $params['controller'].'/'; - + if (empty($params['action']) && !empty($paramsStr)) { $params['action'] = 'index'; } $url .= empty($params['action']) ? '' : $params['action'].'/'; - + $url .= $paramsStr; - + $url .= empty($params['array']) ? '' : '?' . http_build_query($params['array']); } diff --git a/app/code/core/Mage/Core/Model/App.php b/app/code/core/Mage/Core/Model/App.php index ce823a5dd21..79560aeb7aa 100644 --- a/app/code/core/Mage/Core/Model/App.php +++ b/app/code/core/Mage/Core/Model/App.php @@ -1065,7 +1065,7 @@ public function getLocale() } /** - * Retrive layout object + * Retrieve layout object * * @return Mage_Core_Model_Layout */ @@ -1380,13 +1380,13 @@ public function dispatchEvent($eventName, $args) $method = $obs['method']; $observer->addData($args); $object = Mage::getModel($obs['model']); - $this->_callObserverMethod($object, $method, $observer); + $this->_callObserverMethod($object, $method, $observer, $obsName); break; default: $method = $obs['method']; $observer->addData($args); $object = Mage::getSingleton($obs['model']); - $this->_callObserverMethod($object, $method, $observer); + $this->_callObserverMethod($object, $method, $observer, $obsName); break; } Varien_Profiler::stop('OBSERVER: '.$obsName); @@ -1401,15 +1401,22 @@ public function dispatchEvent($eventName, $args) * @param object $object * @param string $method * @param Varien_Event_Observer $observer + * @param string $observerName * @return $this * @throws Mage_Core_Exception */ - protected function _callObserverMethod($object, $method, $observer) + protected function _callObserverMethod($object, $method, $observer, $observerName = 'undefined') { if (is_object($object) && method_exists($object, $method)) { $object->$method($observer); } elseif (Mage::getIsDeveloperMode()) { - Mage::throwException('Method "'.$method.'" is not defined in "'.get_class($object).'"'); + if (is_object($object)) { + $message = 'Method "' . $method . '" is not defined in "' . get_class($object) . '"'; + } else { + $message = 'Class from observer "' . $observerName . '" is not initialized'; + } + + Mage::throwException($message); } return $this; } diff --git a/app/code/core/Mage/Core/Model/App/Emulation.php b/app/code/core/Mage/Core/Model/App/Emulation.php index 295e99262b4..3f09b66e921 100644 --- a/app/code/core/Mage/Core/Model/App/Emulation.php +++ b/app/code/core/Mage/Core/Model/App/Emulation.php @@ -95,7 +95,7 @@ public function startEnvironmentEmulation( ->setInitialLocaleCode($initialLocaleCode); Mage::app()->getTranslator()->init($area, true); - + return $initialEnvironmentInfo; } diff --git a/app/code/core/Mage/Core/Model/Config.php b/app/code/core/Mage/Core/Model/Config.php index 90c266bd78e..31c2d8e9dc9 100644 --- a/app/code/core/Mage/Core/Model/Config.php +++ b/app/code/core/Mage/Core/Model/Config.php @@ -720,7 +720,7 @@ public function setNode($path, $value, $overwrite = true) /** - * Retrive Declared Module file list + * Retrieve Declared Module file list * * @return array|false */ @@ -1271,7 +1271,7 @@ public function getGroupedClassName($groupType, $classId, $groupRootNode = null) $config = $this->_xml->global->{$groupType.'s'}->{$group}; // First - check maybe the entity class was rewritten - $className = null; + $className = ''; if (isset($config->rewrite->$class)) { $className = (string)$config->rewrite->$class; } else { @@ -1288,7 +1288,7 @@ public function getGroupedClassName($groupType, $classId, $groupRootNode = null) } } } - + $className = trim($className); // Second - if entity is not rewritten then use class prefix to form class name @@ -1558,7 +1558,7 @@ public function shouldUrlBeSecure($url) /** * Get DB table names prefix * - * @return string + * @return Mage_Core_Model_Config_Element */ public function getTablePrefix() { diff --git a/app/code/core/Mage/Core/Model/Cookie.php b/app/code/core/Mage/Core/Model/Cookie.php index 7e2981487c4..ccdf9afd9cc 100644 --- a/app/code/core/Mage/Core/Model/Cookie.php +++ b/app/code/core/Mage/Core/Model/Cookie.php @@ -264,7 +264,7 @@ public function set($name, $value, $period = null, $path = null, $domain = null, if (PHP_VERSION_ID >= 70300) { setcookie( $name, - $value, + (string)$value, [ 'expires' => $expire, 'path' => $path, @@ -278,7 +278,7 @@ public function set($name, $value, $period = null, $path = null, $domain = null, if (!empty($sameSite)) { $path.= "; samesite=${sameSite}"; } - setcookie($name, $value, $expire, $path, $domain, $secure, $httponly); + setcookie($name, (string)$value, $expire, $path, $domain, $secure, $httponly); } return $this; @@ -339,6 +339,6 @@ public function delete($name, $path = null, $domain = null, $secure = null, $htt return $this; } - return $this->set($name, null, null, $path, $domain, $secure, $httponly, $sameSite); + return $this->set($name, '', null, $path, $domain, $secure, $httponly, $sameSite); } } diff --git a/app/code/core/Mage/Core/Model/Email/Template.php b/app/code/core/Mage/Core/Model/Email/Template.php index 2a144fa4a55..0f258151f9f 100644 --- a/app/code/core/Mage/Core/Model/Email/Template.php +++ b/app/code/core/Mage/Core/Model/Email/Template.php @@ -210,7 +210,7 @@ public function loadDefault($templateId, $locale = null) } /** - * Retrive default templates from config + * Retrieve default templates from config * * @return array */ @@ -224,7 +224,7 @@ public static function getDefaultTemplates() } /** - * Retrive default templates as options array + * Retrieve default templates as options array * * @return array */ diff --git a/app/code/core/Mage/Core/Model/Message.php b/app/code/core/Mage/Core/Model/Message.php index 242a98ae751..d240944b062 100644 --- a/app/code/core/Mage/Core/Model/Message.php +++ b/app/code/core/Mage/Core/Model/Message.php @@ -63,7 +63,7 @@ protected function _factory($code, $type, $class = '', $method = '') } $message->setClass($class); $message->setMethod($method); - + return $message; } diff --git a/app/code/core/Mage/Core/Model/Template.php b/app/code/core/Mage/Core/Model/Template.php index 23f74bcc191..f45aa8095a0 100644 --- a/app/code/core/Mage/Core/Model/Template.php +++ b/app/code/core/Mage/Core/Model/Template.php @@ -51,7 +51,7 @@ abstract class Mage_Core_Model_Template extends Mage_Core_Model_Abstract */ protected $_designConfig; - + /** * Configuration of emulated desing package. * diff --git a/app/code/core/Mage/Core/Model/Translate.php b/app/code/core/Mage/Core/Model/Translate.php index d558e681cf9..3975f9cbd56 100644 --- a/app/code/core/Mage/Core/Model/Translate.php +++ b/app/code/core/Mage/Core/Model/Translate.php @@ -462,7 +462,7 @@ public function getTranslateInline() } /** - * Retrive translated template file + * Retrieve translated template file * * @param string $file * @param string $type diff --git a/app/code/core/Mage/Core/Model/Translate/Expr.php b/app/code/core/Mage/Core/Model/Translate/Expr.php index 9c051707418..0debfdc0a52 100644 --- a/app/code/core/Mage/Core/Model/Translate/Expr.php +++ b/app/code/core/Mage/Core/Model/Translate/Expr.php @@ -23,7 +23,7 @@ * @copyright Copyright (c) 2006-2020 Magento, Inc. (http://www.magento.com) * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) */ - + /** * Translate expression object * @@ -63,7 +63,7 @@ public function setModule($module) $this->_module = $module; return $this; } - + /** * Retrieve expression text * @@ -73,7 +73,7 @@ public function getText() { return $this->_text; } - + /** * Retrieve expression module * @@ -83,7 +83,7 @@ public function getModule() { return $this->_module; } - + /** * Retrieve expression code * diff --git a/app/code/core/Mage/Core/Model/Translate/String.php b/app/code/core/Mage/Core/Model/Translate/String.php index 00fdff82401..95d1ebd2012 100644 --- a/app/code/core/Mage/Core/Model/Translate/String.php +++ b/app/code/core/Mage/Core/Model/Translate/String.php @@ -59,7 +59,7 @@ public function setString($string) //$this->setData('string', strtolower($string)); return $this; } - + /** * Retrieve string * diff --git a/app/code/core/Mage/Core/functions.php b/app/code/core/Mage/Core/functions.php index e89340fd068..6ea667e8bad 100644 --- a/app/code/core/Mage/Core/functions.php +++ b/app/code/core/Mage/Core/functions.php @@ -70,10 +70,12 @@ function uc_words($str, $destSep = '_', $srcSep = '_') * * @param bool $dayOnly * @return string + * @deprecated use equivalent Varien method directly + * @see Varien_Date::now() */ function now($dayOnly = false) { - return date($dayOnly ? 'Y-m-d' : 'Y-m-d H:i:s'); + return Varien_Date::now($dayOnly); } /** @@ -404,3 +406,48 @@ function hash_equals($known_string, $user_string) return 0 === $result; } } + +/** + * polyfill for PHP 8.0 function "str_contains" + */ +if (!function_exists('str_contains')) { + /** + * @param string $haystack + * @param string $needle + * @return bool + */ + function str_contains($haystack, $needle) + { + return '' === $needle || false !== strpos($haystack, $needle); + } +} + +/** + * polyfill for PHP 8.0 function "str_starts_with" + */ +if (!function_exists('str_starts_with')) { + /** + * @param string $haystack + * @param string $needle + * @return bool + */ + function str_starts_with($haystack, $needle) + { + return 0 === strncmp($haystack, $needle, \strlen($needle)); + } +} + +/** + * polyfill for PHP 8.0 function "str_ends_with" + */ +if (!function_exists('str_ends_with')) { + /** + * @param string $haystack + * @param string $needle + * @return bool + */ + function str_ends_with($haystack, $needle) + { + return '' === $needle || ('' !== $haystack && 0 === substr_compare($haystack, $needle, -\strlen($needle))); + } +} diff --git a/app/code/core/Mage/Customer/Block/Address/Renderer/Default.php b/app/code/core/Mage/Customer/Block/Address/Renderer/Default.php index 1a2de3a2c71..cbae2e51ded 100644 --- a/app/code/core/Mage/Customer/Block/Address/Renderer/Default.php +++ b/app/code/core/Mage/Customer/Block/Address/Renderer/Default.php @@ -42,7 +42,7 @@ class Mage_Customer_Block_Address_Renderer_Default extends Mage_Core_Block_Abstr protected $_type; /** - * Retrive format type object + * Retrieve format type object * * @return Varien_Object */ @@ -52,7 +52,7 @@ public function getType() } /** - * Retrive format type object + * Retrieve format type object * * @param Varien_Object $type * @return $this diff --git a/app/code/core/Mage/Customer/Block/Address/Renderer/Interface.php b/app/code/core/Mage/Customer/Block/Address/Renderer/Interface.php index abb4568e40d..b15a3206e17 100644 --- a/app/code/core/Mage/Customer/Block/Address/Renderer/Interface.php +++ b/app/code/core/Mage/Customer/Block/Address/Renderer/Interface.php @@ -42,7 +42,7 @@ interface Mage_Customer_Block_Address_Renderer_Interface public function setType(Varien_Object $type); /** - * Retrive format type object + * Retrieve format type object * * @return Varien_Object */ diff --git a/app/code/core/Mage/Customer/Exception.php b/app/code/core/Mage/Customer/Exception.php index 2364ff7b52b..3863ce80817 100644 --- a/app/code/core/Mage/Customer/Exception.php +++ b/app/code/core/Mage/Customer/Exception.php @@ -26,5 +26,5 @@ class Mage_Customer_Exception extends Mage_Core_Exception { - + } diff --git a/app/code/core/Mage/Customer/Model/Address/Abstract.php b/app/code/core/Mage/Customer/Model/Address/Abstract.php index 6790cfc2272..0e636efeba4 100644 --- a/app/code/core/Mage/Customer/Model/Address/Abstract.php +++ b/app/code/core/Mage/Customer/Model/Address/Abstract.php @@ -338,7 +338,7 @@ public function getCountry() } /** - * Retrive country model + * Retrieve country model * * @return Mage_Directory_Model_Country */ @@ -353,7 +353,7 @@ public function getCountryModel() } /** - * Retrive country model + * Retrieve country model * * @param int|null $region * @return Mage_Directory_Model_Country @@ -405,7 +405,7 @@ public function format($type) } /** - * Retrive address config object + * Retrieve address config object * * @return Mage_Customer_Model_Address_Config */ diff --git a/app/code/core/Mage/Customer/Model/Address/Api.php b/app/code/core/Mage/Customer/Model/Address/Api.php index 0e90c096802..0d19107ccbb 100644 --- a/app/code/core/Mage/Customer/Model/Address/Api.php +++ b/app/code/core/Mage/Customer/Model/Address/Api.php @@ -43,7 +43,7 @@ public function __construct() } /** - * Retrive customer addresses list + * Retrieve customer addresses list * * @param int $customerId * @return array diff --git a/app/code/core/Mage/Customer/Model/Config/Share.php b/app/code/core/Mage/Customer/Model/Config/Share.php index 00b9f5baa26..7756a783b4c 100644 --- a/app/code/core/Mage/Customer/Model/Config/Share.php +++ b/app/code/core/Mage/Customer/Model/Config/Share.php @@ -38,7 +38,7 @@ class Mage_Customer_Model_Config_Share extends Mage_Core_Model_Config_Data * */ const XML_PATH_CUSTOMER_ACCOUNT_SHARE = 'customer/account_share/scope'; - + /** * Possible customer sharing scopes * diff --git a/app/code/core/Mage/Customer/Model/Customer.php b/app/code/core/Mage/Customer/Model/Customer.php index bc66d80929d..7798b8b96bf 100644 --- a/app/code/core/Mage/Customer/Model/Customer.php +++ b/app/code/core/Mage/Customer/Model/Customer.php @@ -422,9 +422,11 @@ public function getAddressesCollection() if ($this->_addressesCollection === null) { $this->_addressesCollection = $this->getAddressCollection() ->setCustomerFilter($this) - ->addAttributeToSelect('*'); + ->addAttributeToSelect('*') + ->setOrder('entity_id', 'desc'); foreach ($this->_addressesCollection as $address) { $address->setCustomer($this); + $address->setDataChanges(false); } } @@ -939,7 +941,7 @@ public function getSharedStoreIds() } /** - * Retrive shared website ids + * Retrieve shared website ids * * @return array */ diff --git a/app/code/core/Mage/Customer/Model/Customer/Attribute/Backend/Shipping.php b/app/code/core/Mage/Customer/Model/Customer/Attribute/Backend/Shipping.php index c4ee7087fa6..c7a14698825 100644 --- a/app/code/core/Mage/Customer/Model/Customer/Attribute/Backend/Shipping.php +++ b/app/code/core/Mage/Customer/Model/Customer/Attribute/Backend/Shipping.php @@ -60,7 +60,7 @@ public function afterSave($object) $addressId = $address->getId(); } } - + if ($addressId) { $object->setDefaultShipping($addressId); $this->getAttribute()->getEntity() diff --git a/app/code/core/Mage/Customer/Model/Resource/Customer.php b/app/code/core/Mage/Customer/Model/Resource/Customer.php index e8b7dffe508..ced0d6ad107 100644 --- a/app/code/core/Mage/Customer/Model/Resource/Customer.php +++ b/app/code/core/Mage/Customer/Model/Resource/Customer.php @@ -134,8 +134,8 @@ protected function _afterSave(Varien_Object $customer) */ protected function _saveAddresses(Mage_Customer_Model_Customer $customer) { - $defaultBillingId = $customer->getData('default_billing'); - $defaultShippingId = $customer->getData('default_shipping'); + $defaultBillingId = $customer->getData('default_billing'); + $defaultShippingId = $customer->getData('default_shipping'); foreach ($customer->getAddresses() as $address) { if ($address->getData('_deleted')) { if ($address->getId() == $defaultBillingId) { @@ -146,10 +146,19 @@ protected function _saveAddresses(Mage_Customer_Model_Customer $customer) } $address->delete(); } else { - $address->setParentId($customer->getId()) - ->setStoreId($customer->getStoreId()) - ->setIsCustomerSaveTransaction(true) - ->save(); + if ($address->getParentId() != $customer->getId()) { + $address->setParentId($customer->getId()); + } + + if ($address->hasDataChanges()) { + $address->setStoreId($customer->getStoreId()) + ->setIsCustomerSaveTransaction(true) + ->save(); + } else { + $address->setStoreId($customer->getStoreId()) + ->setIsCustomerSaveTransaction(true); + } + if (($address->getIsPrimaryBilling() || $address->getIsDefaultBilling()) && $address->getId() != $defaultBillingId ) { diff --git a/app/code/core/Mage/Directory/Exception.php b/app/code/core/Mage/Directory/Exception.php index b062e9fe875..b9ce079c05e 100644 --- a/app/code/core/Mage/Directory/Exception.php +++ b/app/code/core/Mage/Directory/Exception.php @@ -26,5 +26,5 @@ class Mage_Directory_Exception extends Mage_Core_Exception { - + } diff --git a/app/code/core/Mage/Directory/Model/Country.php b/app/code/core/Mage/Directory/Model/Country.php index ac1ae3f12e1..32d7f938e33 100644 --- a/app/code/core/Mage/Directory/Model/Country.php +++ b/app/code/core/Mage/Directory/Model/Country.php @@ -131,7 +131,7 @@ public function formatAddress(Varien_Object $address, $html = false) } /** - * Retrive formats for + * Retrieve formats for * * @return Mage_Directory_Model_Resource_Country_Format_Collection */ @@ -152,7 +152,7 @@ public function getFormats() } /** - * Retrive format + * Retrieve format * * @param string $type * @return Mage_Directory_Model_Country_Format diff --git a/app/code/core/Mage/Directory/sql/directory_setup/mysql4-upgrade-0.8.10-0.8.11.php b/app/code/core/Mage/Directory/sql/directory_setup/mysql4-upgrade-0.8.10-0.8.11.php index 395cb3f886c..b4e45b72382 100644 --- a/app/code/core/Mage/Directory/sql/directory_setup/mysql4-upgrade-0.8.10-0.8.11.php +++ b/app/code/core/Mage/Directory/sql/directory_setup/mysql4-upgrade-0.8.10-0.8.11.php @@ -193,7 +193,7 @@ array('LV', 'Ērgļu novads', 'Ērgļu novads'), array('LV', 'Ķeguma novads', 'Ķeguma novads'), array('LV', 'Ķekavas novads', 'Ķekavas novads'), - + //ISO-3166-2:LT array('LT', 'LT-AL', 'Alytaus Apskritis'), array('LT', 'LT-KU', 'Kauno Apskritis'), diff --git a/app/code/core/Mage/Downloadable/Block/Adminhtml/Catalog/Product/Edit/Tab/Downloadable/Links.php b/app/code/core/Mage/Downloadable/Block/Adminhtml/Catalog/Product/Edit/Tab/Downloadable/Links.php index f5c89801963..921a8363809 100644 --- a/app/code/core/Mage/Downloadable/Block/Adminhtml/Catalog/Product/Edit/Tab/Downloadable/Links.php +++ b/app/code/core/Mage/Downloadable/Block/Adminhtml/Catalog/Product/Edit/Tab/Downloadable/Links.php @@ -275,7 +275,7 @@ public function getUploadButtonHtml() } /** - * Retrive config json + * Retrieve config json * * @param string $type * @return string diff --git a/app/code/core/Mage/Eav/Exception.php b/app/code/core/Mage/Eav/Exception.php index 6df4e1d26d1..2a46430a6de 100644 --- a/app/code/core/Mage/Eav/Exception.php +++ b/app/code/core/Mage/Eav/Exception.php @@ -26,5 +26,5 @@ class Mage_Eav_Exception extends Mage_Core_Exception { - + } diff --git a/app/code/core/Mage/Eav/Model/Attribute/Data/File.php b/app/code/core/Mage/Eav/Model/Attribute/Data/File.php index 5f47b5caa03..c4499076d20 100644 --- a/app/code/core/Mage/Eav/Model/Attribute/Data/File.php +++ b/app/code/core/Mage/Eav/Model/Attribute/Data/File.php @@ -172,6 +172,9 @@ public function validateValue($value) } if (!$attribute->getIsRequired() && !$toUpload) { + if ($toDelete) { + $attribute->setAttributeValidationAsPassed(); + } return true; } diff --git a/app/code/core/Mage/Eav/Model/Entity/Attribute/Frontend/Interface.php b/app/code/core/Mage/Eav/Model/Entity/Attribute/Frontend/Interface.php index 68946ea7dfa..595e3362e21 100644 --- a/app/code/core/Mage/Eav/Model/Entity/Attribute/Frontend/Interface.php +++ b/app/code/core/Mage/Eav/Model/Entity/Attribute/Frontend/Interface.php @@ -33,5 +33,5 @@ */ interface Mage_Eav_Model_Entity_Attribute_Frontend_Interface { - + } diff --git a/app/code/core/Mage/Eav/Model/Entity/Collection/Abstract.php b/app/code/core/Mage/Eav/Model/Entity/Collection/Abstract.php index 691e4616793..4ae853605a6 100644 --- a/app/code/core/Mage/Eav/Model/Entity/Collection/Abstract.php +++ b/app/code/core/Mage/Eav/Model/Entity/Collection/Abstract.php @@ -923,7 +923,7 @@ protected function _getAllIdsSelect($limit = null, $offset = null) } /** - * Retrive all ids for collection + * Retrieve all ids for collection * * @param int $limit * @param int $offset @@ -935,7 +935,7 @@ public function getAllIds($limit = null, $offset = null) } /** - * Retrive all ids sql + * Retrieve all ids sql * * @deprecated * @return Varien_Db_Select diff --git a/app/code/core/Mage/Eav/Model/Entity/Setup.php b/app/code/core/Mage/Eav/Model/Entity/Setup.php index c270c3a9ac2..cc13d856622 100644 --- a/app/code/core/Mage/Eav/Model/Entity/Setup.php +++ b/app/code/core/Mage/Eav/Model/Entity/Setup.php @@ -291,7 +291,7 @@ public function addAttributeSet($entityTypeId, $name, $sortOrder = null) * * @param mixed $entityTypeId * @param int $id - * @param string $field + * @param array|string $field * @param mixed $value * @return $this */ diff --git a/app/code/core/Mage/GiftMessage/Block/Adminhtml/Sales/Order/View/Items.php b/app/code/core/Mage/GiftMessage/Block/Adminhtml/Sales/Order/View/Items.php index 94635357caa..713d3dba4e2 100644 --- a/app/code/core/Mage/GiftMessage/Block/Adminhtml/Sales/Order/View/Items.php +++ b/app/code/core/Mage/GiftMessage/Block/Adminhtml/Sales/Order/View/Items.php @@ -51,7 +51,7 @@ public function getItem() } /** - * Retrive default value for giftmessage sender + * Retrieve default value for giftmessage sender * * @return string */ @@ -69,7 +69,7 @@ public function getDefaultSender() } /** - * Retrive default value for giftmessage recipient + * Retrieve default value for giftmessage recipient * * @return string */ @@ -97,7 +97,7 @@ public function getDefaultRecipient() } /** - * Retrive real name for field + * Retrieve real name for field * * @param string $name * @return string @@ -108,7 +108,7 @@ public function getFieldName($name) } /** - * Retrive real html id for field + * Retrieve real html id for field * * @param string $id * @return string @@ -119,7 +119,7 @@ public function getFieldId($id) } /** - * Retrive field html id prefix + * Retrieve field html id prefix * * @return string */ @@ -150,7 +150,7 @@ protected function _initMessage() } /** - * Retrive gift message for entity + * Retrieve gift message for entity * * @return Mage_GiftMessage_Model_Message */ @@ -178,7 +178,7 @@ public function getSaveUrl() } /** - * Retrive block html id + * Retrieve block html id * * @return string */ diff --git a/app/code/core/Mage/GiftMessage/Helper/Message.php b/app/code/core/Mage/GiftMessage/Helper/Message.php index 4c15f337e4d..88dbafe4446 100644 --- a/app/code/core/Mage/GiftMessage/Helper/Message.php +++ b/app/code/core/Mage/GiftMessage/Helper/Message.php @@ -55,7 +55,7 @@ class Mage_GiftMessage_Helper_Message extends Mage_Core_Helper_Data protected $_innerCache = array(); /** - * Retrive old stule edit button html for editing of giftmessage in popup + * Retrieve old stule edit button html for editing of giftmessage in popup * * @param string $type * @param Varien_Object $entity @@ -75,7 +75,7 @@ public function getButton($type, Varien_Object $entity) } /** - * Retrive inline giftmessage edit form for specified entity + * Retrieve inline giftmessage edit form for specified entity * * @param string $type * @param Varien_Object $entity @@ -190,7 +190,7 @@ public function getIsMessagesAvailable($type, Varien_Object $entity, $store = nu } /** - * Retrive escaped and preformated gift message text for specified entity + * Retrieve escaped and preformated gift message text for specified entity * * @param Varien_Object $entity * @return string|null @@ -205,7 +205,7 @@ public function getEscapedGiftMessage(Varien_Object $entity) } /** - * Retrive gift message for entity. If message not exists return null + * Retrieve gift message for entity. If message not exists return null * * @param Varien_Object $entity * @return Mage_GiftMessage_Model_Message @@ -220,7 +220,7 @@ public function getGiftMessageForEntity(Varien_Object $entity) } /** - * Retrive internal cached data with specified key. + * Retrieve internal cached data with specified key. * * If cached data not found return null. * @@ -296,7 +296,7 @@ public function getAvailableForAddressItems($items, $store = null) } /** - * Retrive gift message with specified id + * Retrieve gift message with specified id * * @param integer $messageId * @return Mage_GiftMessage_Model_Message diff --git a/app/code/core/Mage/GiftMessage/Helper/Url.php b/app/code/core/Mage/GiftMessage/Helper/Url.php index 81c594ba60d..718ab23aa68 100644 --- a/app/code/core/Mage/GiftMessage/Helper/Url.php +++ b/app/code/core/Mage/GiftMessage/Helper/Url.php @@ -34,7 +34,7 @@ class Mage_GiftMessage_Helper_Url extends Mage_Core_Helper_Url { /** - * Retrive gift message save url + * Retrieve gift message save url * * @param Varien_Object $item * @param string $type @@ -53,7 +53,7 @@ public function getEditUrl(Varien_Object $item, $type, $params = array()) } /** - * Retrive gift message button block url + * Retrieve gift message button block url * * @param integer $itemId * @param string $type @@ -67,7 +67,7 @@ public function getButtonUrl($itemId, $type, $params = array()) } /** - * Retrive gift message remove url + * Retrieve gift message remove url * * @param integer $itemId * @param string $type @@ -81,7 +81,7 @@ public function getRemoveUrl($itemId, $type, $params = array()) } /** - * Retrive gift message save url + * Retrieve gift message save url * * @param integer $itemId * @param string $type diff --git a/app/code/core/Mage/GoogleCheckout/etc/config.xml b/app/code/core/Mage/GoogleCheckout/etc/config.xml index a31c718baf1..b68fae3a1a1 100644 --- a/app/code/core/Mage/GoogleCheckout/etc/config.xml +++ b/app/code/core/Mage/GoogleCheckout/etc/config.xml @@ -42,6 +42,7 @@ 1 + Google Checkout googlecheckout/payment diff --git a/app/code/core/Mage/ImportExport/Model/Import/Adapter/Abstract.php b/app/code/core/Mage/ImportExport/Model/Import/Adapter/Abstract.php index c129e0d96d4..6b36cc8fec2 100644 --- a/app/code/core/Mage/ImportExport/Model/Import/Adapter/Abstract.php +++ b/app/code/core/Mage/ImportExport/Model/Import/Adapter/Abstract.php @@ -159,6 +159,7 @@ public function key() * @param int $position The position to seek to. * @return void */ + #[\ReturnTypeWillChange] public function seek($position) { Mage::throwException(Mage::helper('importexport')->__('Not implemented yet')); @@ -169,6 +170,7 @@ public function seek($position) * * @return boolean Returns true on success or false on failure. */ + #[\ReturnTypeWillChange] public function valid() { return !empty($this->_currentRow); diff --git a/app/code/core/Mage/ImportExport/Model/Import/Adapter/Csv.php b/app/code/core/Mage/ImportExport/Model/Import/Adapter/Csv.php index f89db7d1c94..4f9d81b4776 100644 --- a/app/code/core/Mage/ImportExport/Model/Import/Adapter/Csv.php +++ b/app/code/core/Mage/ImportExport/Model/Import/Adapter/Csv.php @@ -81,6 +81,7 @@ protected function _init() * * @return void Any returned value is ignored. */ + #[\ReturnTypeWillChange] public function next() { $this->_currentRow = fgetcsv($this->_fileHandler, null, $this->_delimiter, $this->_enclosure); @@ -92,6 +93,7 @@ public function next() * * @return void Any returned value is ignored. */ + #[\ReturnTypeWillChange] public function rewind() { // rewind resource, reset column names, read first row as current @@ -111,11 +113,13 @@ public function rewind() * @throws OutOfBoundsException * @return void */ + #[\ReturnTypeWillChange] public function seek($position) { if ($position != $this->_currentKey) { if (0 == $position) { - return $this->rewind(); + $this->rewind(); + return; } elseif ($position > 0) { if ($position < $this->_currentKey) { $this->rewind(); diff --git a/app/code/core/Mage/ImportExport/Model/Import/Entity/Product.php b/app/code/core/Mage/ImportExport/Model/Import/Entity/Product.php index 34318b5c5e5..bb8eab9e7e2 100644 --- a/app/code/core/Mage/ImportExport/Model/Import/Entity/Product.php +++ b/app/code/core/Mage/ImportExport/Model/Import/Entity/Product.php @@ -1855,7 +1855,6 @@ protected function _saveProductWebsites(array $websiteData) * * @param string $resourceModelName * @return Object - * @phpstan-ignore-next-line */ protected function getResourceModel($resourceModelName) { @@ -1867,7 +1866,6 @@ protected function getResourceModel($resourceModelName) * * @param string $helperName * @return Mage_Core_Helper_Abstract - * @phpstan-ignore-next-line */ protected function getHelper($helperName) { diff --git a/app/code/core/Mage/ImportExport/Model/Import/Entity/Product/Type/Grouped.php b/app/code/core/Mage/ImportExport/Model/Import/Entity/Product/Type/Grouped.php index 0411d70951d..44eea4011bb 100644 --- a/app/code/core/Mage/ImportExport/Model/Import/Entity/Product/Type/Grouped.php +++ b/app/code/core/Mage/ImportExport/Model/Import/Entity/Product/Type/Grouped.php @@ -50,7 +50,7 @@ class Mage_ImportExport_Model_Import_Entity_Product_Type_Grouped extends Mage_Im protected $_behavior; /** - * Retrive model behavior + * Retrieve model behavior * * @return string */ diff --git a/app/code/core/Mage/ImportExport/Model/Resource/Import/Data.php b/app/code/core/Mage/ImportExport/Model/Resource/Import/Data.php index 87fc1ef5752..d25ed6dd24a 100644 --- a/app/code/core/Mage/ImportExport/Model/Resource/Import/Data.php +++ b/app/code/core/Mage/ImportExport/Model/Resource/Import/Data.php @@ -51,6 +51,7 @@ protected function _construct() * * @return IteratorIterator */ + #[\ReturnTypeWillChange] public function getIterator() { $adapter = $this->_getWriteAdapter(); diff --git a/app/code/core/Mage/Index/etc/config.xml b/app/code/core/Mage/Index/etc/config.xml index ee498e27e2b..5fc2a7fe0d8 100644 --- a/app/code/core/Mage/Index/etc/config.xml +++ b/app/code/core/Mage/Index/etc/config.xml @@ -32,6 +32,11 @@ + + + Mage_Index_Helper + + Mage_Index_Model @@ -69,7 +74,7 @@ index/indexer - + diff --git a/app/code/core/Mage/Install/Block/Abstract.php b/app/code/core/Mage/Install/Block/Abstract.php index 6fb28f085a1..2ecd054c5d8 100644 --- a/app/code/core/Mage/Install/Block/Abstract.php +++ b/app/code/core/Mage/Install/Block/Abstract.php @@ -23,7 +23,7 @@ * @copyright Copyright (c) 2006-2020 Magento, Inc. (http://www.magento.com) * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) */ - + /** * Abstract installation block * @@ -40,7 +40,7 @@ public function getInstaller() { return Mage::getSingleton('install/installer'); } - + /** * Retrieve wizard model * @@ -50,7 +50,7 @@ public function getWizard() { return Mage::getSingleton('install/wizard'); } - + /** * Retrieve current installation step * diff --git a/app/code/core/Mage/Install/Block/Admin.php b/app/code/core/Mage/Install/Block/Admin.php index 8bfed8840f7..6872178a40c 100644 --- a/app/code/core/Mage/Install/Block/Admin.php +++ b/app/code/core/Mage/Install/Block/Admin.php @@ -23,7 +23,7 @@ * @copyright Copyright (c) 2006-2020 Magento, Inc. (http://www.magento.com) * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) */ - + /** * Administrator account install block * @@ -31,17 +31,17 @@ */ class Mage_Install_Block_Admin extends Mage_Install_Block_Abstract { - public function __construct() + public function __construct() { parent::__construct(); $this->setTemplate('install/create_admin.phtml'); } - + public function getPostUrl() { return $this->getUrl('*/*/administratorPost'); } - + public function getFormData() { $data = $this->getData('form_data'); diff --git a/app/code/core/Mage/Install/Block/End.php b/app/code/core/Mage/Install/Block/End.php index a8ec959639f..d5992f86bdb 100644 --- a/app/code/core/Mage/Install/Block/End.php +++ b/app/code/core/Mage/Install/Block/End.php @@ -46,18 +46,4 @@ public function getEncryptionKey() } return $key; } - - /** - * Return url for iframe source - * - * @return string - */ - public function getIframeSourceUrl() - { - if (!Mage_AdminNotification_Model_Survey::isSurveyUrlValid() - || Mage::getSingleton('install/installer')->getHideIframe()) { - return null; - } - return Mage_AdminNotification_Model_Survey::getSurveyUrl(); - } } diff --git a/app/code/core/Mage/Install/Controller/Action.php b/app/code/core/Mage/Install/Controller/Action.php index 4301d04381c..75bed9ab0ff 100644 --- a/app/code/core/Mage/Install/Controller/Action.php +++ b/app/code/core/Mage/Install/Controller/Action.php @@ -30,13 +30,13 @@ class Mage_Install_Controller_Action extends Mage_Core_Controller_Varien_Action protected function _construct() { parent::_construct(); - + Mage::getDesign()->setArea('install') ->setPackageName('default') ->setTheme('default'); $this->getLayout()->setArea('install'); - + $this->setFlag('', self::FLAG_NO_CHECK_INSTALLATION, true); } } diff --git a/app/code/core/Mage/Install/Model/Session.php b/app/code/core/Mage/Install/Model/Session.php index cac3881d307..8f8e2ca8f7b 100644 --- a/app/code/core/Mage/Install/Model/Session.php +++ b/app/code/core/Mage/Install/Model/Session.php @@ -33,7 +33,7 @@ */ class Mage_Install_Model_Session extends Mage_Core_Model_Session_Abstract { - public function __construct() + public function __construct() { $this->init('install'); } diff --git a/app/code/core/Mage/Install/controllers/WizardController.php b/app/code/core/Mage/Install/controllers/WizardController.php index f57ac390328..52bc723e0a2 100644 --- a/app/code/core/Mage/Install/controllers/WizardController.php +++ b/app/code/core/Mage/Install/controllers/WizardController.php @@ -345,8 +345,6 @@ public function endAction() $this->_getInstaller()->finish(); - Mage_AdminNotification_Model_Survey::saveSurveyViewed(true); - $this->_prepareLayout(); $this->_initLayoutMessages('install/session'); diff --git a/app/code/core/Mage/Log/Model/Resource/Log.php b/app/code/core/Mage/Log/Model/Resource/Log.php index 644f5bacd1f..8b712c330cf 100644 --- a/app/code/core/Mage/Log/Model/Resource/Log.php +++ b/app/code/core/Mage/Log/Model/Resource/Log.php @@ -102,7 +102,7 @@ protected function _cleanVisitors($time) } $condition = array('visitor_id IN (?)' => $visitorIds); - + // remove visitors from log/quote $writeAdapter->delete($this->getTable('log/quote_table'), $condition); diff --git a/app/code/core/Mage/Media/Model/File/Image.php b/app/code/core/Mage/Media/Model/File/Image.php index da004d27e2c..5307ae5b52c 100644 --- a/app/code/core/Mage/Media/Model/File/Image.php +++ b/app/code/core/Mage/Media/Model/File/Image.php @@ -207,7 +207,7 @@ public function saveAs(Mage_Media_Model_Image $object, $extension = null) } /** - * Retrive image dimensions + * Retrieve image dimensions * * @param Mage_Media_Model_Image $object * @return Varien_Object diff --git a/app/code/core/Mage/Media/Model/Image.php b/app/code/core/Mage/Media/Model/Image.php index 8f6e1ee89cb..128edb0f0f4 100644 --- a/app/code/core/Mage/Media/Model/Image.php +++ b/app/code/core/Mage/Media/Model/Image.php @@ -83,7 +83,7 @@ public function setConfig(Mage_Media_Model_Image_Config_Interface $config) } /** - * Retrive media image config instance + * Retrieve media image config instance * * @return Mage_Media_Model_Image_Config_Interface */ @@ -117,7 +117,7 @@ public function getTmpImage() } /** - * Retrive source dimensions object + * Retrieve source dimensions object * * @return Varien_Object */ @@ -130,7 +130,7 @@ public function getDimensions() } /** - * Retrive destanation dimensions object + * Retrieve destanation dimensions object * * @return Varien_Object */ diff --git a/app/code/core/Mage/Media/Model/Image/Config/Interface.php b/app/code/core/Mage/Media/Model/Image/Config/Interface.php index b6b6270b4a7..e9bb9f7ff80 100644 --- a/app/code/core/Mage/Media/Model/Image/Config/Interface.php +++ b/app/code/core/Mage/Media/Model/Image/Config/Interface.php @@ -36,21 +36,21 @@ interface Mage_Media_Model_Image_Config_Interface { /** - * Retrive base url for media files + * Retrieve base url for media files * * @return string */ public function getBaseMediaUrl(); /** - * Retrive base path for media files + * Retrieve base path for media files * * @return string */ public function getBaseMediaPath(); /** - * Retrive url for media file + * Retrieve url for media file * * @param string $file * @return string @@ -58,7 +58,7 @@ public function getBaseMediaPath(); public function getMediaUrl($file); /** - * Retrive file system path for media file + * Retrieve file system path for media file * * @param string $file * @return string diff --git a/app/code/core/Mage/Newsletter/Model/Message.php b/app/code/core/Mage/Newsletter/Model/Message.php index 97939f70707..c6ad570a6ac 100644 --- a/app/code/core/Mage/Newsletter/Model/Message.php +++ b/app/code/core/Mage/Newsletter/Model/Message.php @@ -23,7 +23,7 @@ * @copyright Copyright (c) 2006-2020 Magento, Inc. (http://www.magento.com) * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) */ - + /** * Newsletter message model * @@ -31,8 +31,8 @@ * @package Mage_Newsletter * @author Magento Core Team */ - + class Mage_Newsletter_Model_Message extends Mage_Core_Model_Message { - + } diff --git a/app/code/core/Mage/Newsletter/controllers/SubscriberController.php b/app/code/core/Mage/Newsletter/controllers/SubscriberController.php index 62f2099bedf..7631c0e0e1b 100644 --- a/app/code/core/Mage/Newsletter/controllers/SubscriberController.php +++ b/app/code/core/Mage/Newsletter/controllers/SubscriberController.php @@ -33,11 +33,21 @@ */ class Mage_Newsletter_SubscriberController extends Mage_Core_Controller_Front_Action { + /** + * Use CSRF validation flag from newsletter config + */ + const XML_CSRF_USE_FLAG_CONFIG_PATH = 'newsletter/security/enable_form_key'; + /** * New subscription action */ public function newAction() { + if (!$this->_validateFormKey()) { + $this->_redirectReferer(); + return; + } + if ($this->getRequest()->isPost() && $this->getRequest()->getPost('email')) { $session = Mage::getSingleton('core/session'); $customerSession = Mage::getSingleton('customer/session'); @@ -125,4 +135,14 @@ public function unsubscribeAction() } $this->_redirectReferer(); } + + /** + * Check if form key validation is enabled in newsletter config. + * + * @return bool + */ + protected function _isFormKeyEnabled() + { + return Mage::getStoreConfigFlag(self::XML_CSRF_USE_FLAG_CONFIG_PATH); + } } diff --git a/app/code/core/Mage/Newsletter/etc/config.xml b/app/code/core/Mage/Newsletter/etc/config.xml index 0f7d6962760..2ea7e524e12 100644 --- a/app/code/core/Mage/Newsletter/etc/config.xml +++ b/app/code/core/Mage/Newsletter/etc/config.xml @@ -196,6 +196,9 @@ 0 + + 0 + diff --git a/app/code/core/Mage/Newsletter/etc/system.xml b/app/code/core/Mage/Newsletter/etc/system.xml index d1d28eb43a4..5f3d09e6697 100644 --- a/app/code/core/Mage/Newsletter/etc/system.xml +++ b/app/code/core/Mage/Newsletter/etc/system.xml @@ -118,6 +118,26 @@ + + + text + 1 + 1 + 1 + 1 + + + + select + adminhtml/system_config_source_yesno + 1 + 1 + 1 + 1 + Important! Enabling this option means that your custom templates used for newsletter subscription must contain form_key block output. Otherwise newsletter subscription will not work.]]> + + + diff --git a/app/code/core/Mage/Newsletter/sql/newsletter_setup/mysql4-upgrade-0.8.2-0.8.3.php b/app/code/core/Mage/Newsletter/sql/newsletter_setup/mysql4-upgrade-0.8.2-0.8.3.php index b1babf3fcd5..dc3484f870b 100644 --- a/app/code/core/Mage/Newsletter/sql/newsletter_setup/mysql4-upgrade-0.8.2-0.8.3.php +++ b/app/code/core/Mage/Newsletter/sql/newsletter_setup/mysql4-upgrade-0.8.2-0.8.3.php @@ -67,7 +67,7 @@ foreach ($rows as $row) { $whereBind = $conn ->quoteInto('queue_id=?', $row['queue_id']); - + $conn ->update( $queueTable, diff --git a/app/code/core/Mage/Page/Block/Template/Links/Block.php b/app/code/core/Mage/Page/Block/Template/Links/Block.php index 698f0f27058..4a9f3ecee12 100644 --- a/app/code/core/Mage/Page/Block/Template/Links/Block.php +++ b/app/code/core/Mage/Page/Block/Template/Links/Block.php @@ -199,7 +199,7 @@ public function getLinkUrl() { return $this->_url; } - + /** * Prepare tag attributes * @@ -219,7 +219,7 @@ protected function _prepareParams($params) } return ''; } - + /** * Return Li Params * @@ -229,7 +229,7 @@ public function getLiParams() { return $this->_prepareParams($this->_liParams); } - + /** * Return Link Tag Params * diff --git a/app/code/core/Mage/Page/Helper/Html.php b/app/code/core/Mage/Page/Helper/Html.php index d561a32dc2b..422ba220c3c 100644 --- a/app/code/core/Mage/Page/Helper/Html.php +++ b/app/code/core/Mage/Page/Helper/Html.php @@ -23,7 +23,7 @@ * @copyright Copyright (c) 2006-2020 Magento, Inc. (http://www.magento.com) * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) */ - + /** * Html helper * @@ -31,5 +31,5 @@ */ class Mage_Page_Helper_Html extends Mage_Core_Helper_Abstract { - + } diff --git a/app/code/core/Mage/Paygate/Model/Authorizenet/Request.php b/app/code/core/Mage/Paygate/Model/Authorizenet/Request.php index 797060d146d..a21632ca480 100644 --- a/app/code/core/Mage/Paygate/Model/Authorizenet/Request.php +++ b/app/code/core/Mage/Paygate/Model/Authorizenet/Request.php @@ -25,7 +25,7 @@ */ -class Mage_Paygate_Model_Authorizenet_Request extends Varien_Object +class Mage_Paygate_Model_Authorizenet_Request extends Varien_Object { - + } diff --git a/app/code/core/Mage/Paygate/Model/Authorizenet/Result.php b/app/code/core/Mage/Paygate/Model/Authorizenet/Result.php index aadb2e6bb74..c25c5233d5b 100644 --- a/app/code/core/Mage/Paygate/Model/Authorizenet/Result.php +++ b/app/code/core/Mage/Paygate/Model/Authorizenet/Result.php @@ -25,7 +25,7 @@ */ -class Mage_Paygate_Model_Authorizenet_Result extends Varien_Object +class Mage_Paygate_Model_Authorizenet_Result extends Varien_Object { - + } diff --git a/app/code/core/Mage/Payment/Block/Form/Cc.php b/app/code/core/Mage/Payment/Block/Form/Cc.php index e4a9d4f20d9..2f173d366b5 100644 --- a/app/code/core/Mage/Payment/Block/Form/Cc.php +++ b/app/code/core/Mage/Payment/Block/Form/Cc.php @@ -98,7 +98,7 @@ public function getCcYears() } /** - * Retrive has verification configuration + * Retrieve has verification configuration * * @return boolean */ diff --git a/app/code/core/Mage/Payment/Model/Observer.php b/app/code/core/Mage/Payment/Model/Observer.php index 95a7494a274..2b352df3f3f 100644 --- a/app/code/core/Mage/Payment/Model/Observer.php +++ b/app/code/core/Mage/Payment/Model/Observer.php @@ -124,7 +124,7 @@ public function beforeOrderPaymentSave(Varien_Event_Observer $observer) if ($payment->getMethod() === Mage_Payment_Model_Method_Banktransfer::PAYMENT_METHOD_BANKTRANSFER_CODE) { $payment->setAdditionalInformation( 'instructions', - $payment->getMethodInstance()->getInstructions() + $payment->getMethodInstance()->setStore($payment->getOrder()->getStoreId())->getInstructions() ); } } diff --git a/app/code/core/Mage/Payment/Model/Paygate/Result.php b/app/code/core/Mage/Payment/Model/Paygate/Result.php index 10c41b00a60..8fa06a11106 100644 --- a/app/code/core/Mage/Payment/Model/Paygate/Result.php +++ b/app/code/core/Mage/Payment/Model/Paygate/Result.php @@ -27,5 +27,5 @@ class Mage_Payment_Model_Paygate_Result extends Varien_Object { - + } diff --git a/app/code/core/Mage/Paypal/Model/Config.php b/app/code/core/Mage/Paypal/Model/Config.php index 7398421b644..96e9247ed3f 100644 --- a/app/code/core/Mage/Paypal/Model/Config.php +++ b/app/code/core/Mage/Paypal/Model/Config.php @@ -226,42 +226,357 @@ class Mage_Paypal_Model_Config * * @var array */ - protected $_supportedCurrencyCodes = array('AUD', 'CAD', 'CZK', 'DKK', 'EUR', 'HKD', 'HUF', 'ILS', 'JPY', 'MXN', - 'NOK', 'NZD', 'PLN', 'GBP', 'SGD', 'SEK', 'CHF', 'USD', 'TWD', 'THB'); + protected $_supportedCurrencyCodes = [ + 'AUD', + 'CAD', + 'CZK', + 'DKK', + 'EUR', + 'HKD', + 'HUF', + 'ILS', + 'JPY', + 'MXN', + 'NOK', + 'NZD', + 'PLN', + 'GBP', + 'RUB', + 'SGD', + 'SEK', + 'CHF', + 'TWD', + 'THB', + 'USD', + 'INR', + ]; /** * Merchant country supported by PayPal * * @var array */ - protected $_supportedCountryCodes = array( - 'AE','AR','AT','AU','BE','BG','BR','CA','CH','CL','CR','CY','CZ','DE','DK','DO','EC','EE','ES','FI','FR','GB', - 'GF','GI','GP','GR','HK','HU','ID','IE','IL','IN','IS','IT','JM','JP','KR','LI','LT','LU','LV','MQ','MT','MX', - 'MY','NL','NO','NZ','PH','PL','PT','RE','RO','SE','SG','SI','SK','SM','TH','TR','TW','US','UY','VE','VN','ZA'); + protected $_supportedCountryCodes = [ + 'AE', + 'AR', + 'AT', + 'AU', + 'BE', + 'BG', + 'BR', + 'CA', + 'CN', + 'CH', + 'CL', + 'CR', + 'CY', + 'CZ', + 'DE', + 'DK', + 'DO', + 'EC', + 'EE', + 'ES', + 'FI', + 'FR', + 'GB', + 'GF', + 'GI', + 'GP', + 'GR', + 'HK', + 'HU', + 'ID', + 'IE', + 'IL', + 'IN', + 'IS', + 'IT', + 'JM', + 'JP', + 'KR', + 'LI', + 'LT', + 'LU', + 'LV', + 'MQ', + 'MT', + 'MX', + 'MY', + 'NL', + 'NO', + 'NZ', + 'PH', + 'PL', + 'PT', + 'RU', + 'RE', + 'RO', + 'SE', + 'SG', + 'SI', + 'SK', + 'SM', + 'TH', + 'TR', + 'TW', + 'US', + 'UY', + 'VE', + 'VN', + 'ZA', + ]; /** * Buyer country supported by PayPal * * @var array */ - protected $_supportedBuyerCountryCodes = array( - 'AF ', 'AX ', 'AL ', 'DZ ', 'AS ', 'AD ', 'AO ', 'AI ', 'AQ ', 'AG ', 'AR ', 'AM ', 'AW ', 'AU ', 'AT ', 'AZ ', - 'BS ', 'BH ', 'BD ', 'BB ', 'BY ', 'BE ', 'BZ ', 'BJ ', 'BM ', 'BT ', 'BO ', 'BA ', 'BW ', 'BV ', 'BR ', 'IO ', - 'BN ', 'BG ', 'BF ', 'BI ', 'KH ', 'CM ', 'CA ', 'CV ', 'KY ', 'CF ', 'TD ', 'CL ', 'CN ', 'CX ', 'CC ', 'CO ', - 'KM ', 'CG ', 'CD ', 'CK ', 'CR ', 'CI ', 'HR ', 'CU ', 'CY ', 'CZ ', 'DK ', 'DJ ', 'DM ', 'DO ', 'EC ', 'EG ', - 'SV ', 'GQ ', 'ER ', 'EE ', 'ET ', 'FK ', 'FO ', 'FJ ', 'FI ', 'FR ', 'GF ', 'PF ', 'TF ', 'GA ', 'GM ', 'GE ', - 'DE ', 'GH ', 'GI ', 'GR ', 'GL ', 'GD ', 'GP ', 'GU ', 'GT ', 'GG ', 'GN ', 'GW ', 'GY ', 'HT ', 'HM ', 'VA ', - 'HN ', 'HK ', 'HU ', 'IS ', 'IN ', 'ID ', 'IR ', 'IQ ', 'IE ', 'IM ', 'IL ', 'IT ', 'JM ', 'JP ', 'JE ', 'JO ', - 'KZ ', 'KE ', 'KI ', 'KP ', 'KR ', 'KW ', 'KG ', 'LA ', 'LV ', 'LB ', 'LS ', 'LR ', 'LY ', 'LI ', 'LT ', 'LU ', - 'MO ', 'MK ', 'MG ', 'MW ', 'MY ', 'MV ', 'ML ', 'MT ', 'MH ', 'MQ ', 'MR ', 'MU ', 'YT ', 'MX ', 'FM ', 'MD ', - 'MC ', 'MN ', 'MS ', 'MA ', 'MZ ', 'MM ', 'NA ', 'NR ', 'NP ', 'NL ', 'AN ', 'NC ', 'NZ ', 'NI ', 'NE ', 'NG ', - 'NU ', 'NF ', 'MP ', 'NO ', 'OM ', 'PK ', 'PW ', 'PS ', 'PA ', 'PG ', 'PY ', 'PE ', 'PH ', 'PN ', 'PL ', 'PT ', - 'PR ', 'QA ', 'RE ', 'RO ', 'RU ', 'RW ', 'SH ', 'KN ', 'LC ', 'PM ', 'VC ', 'WS ', 'SM ', 'ST ', 'SA ', 'SN ', - 'CS ', 'SC ', 'SL ', 'SG ', 'SK ', 'SI ', 'SB ', 'SO ', 'ZA ', 'GS ', 'ES ', 'LK ', 'SD ', 'SR ', 'SJ ', 'SZ ', - 'SE ', 'CH ', 'SY ', 'TW ', 'TJ ', 'TZ ', 'TH ', 'TL ', 'TG ', 'TK ', 'TO ', 'TT ', 'TN ', 'TR ', 'TM ', 'TC ', - 'TV ', 'UG ', 'UA ', 'AE ', 'GB ', 'US ', 'UM ', 'UY ', 'UZ ', 'VU ', 'VE ', 'VN ', 'VG ', 'VI ', 'WF ', 'EH ', - 'YE ', 'ZM ', 'ZW' - ); + protected $_supportedBuyerCountryCodes = [ + 'AF ', + 'AX ', + 'AL ', + 'DZ ', + 'AS ', + 'AD ', + 'AO ', + 'AI ', + 'AQ ', + 'AG ', + 'AR ', + 'AM ', + 'AW ', + 'AU ', + 'AT ', + 'AZ ', + 'BS ', + 'BH ', + 'BD ', + 'BB ', + 'BY ', + 'BE ', + 'BZ ', + 'BJ ', + 'BM ', + 'BT ', + 'BO ', + 'BA ', + 'BW ', + 'BV ', + 'BR ', + 'IO ', + 'BN ', + 'BG ', + 'BF ', + 'BI ', + 'KH ', + 'CM ', + 'CA ', + 'CV ', + 'KY ', + 'CF ', + 'TD ', + 'CL ', + 'CN ', + 'CX ', + 'CC ', + 'CO ', + 'KM ', + 'CG ', + 'CD ', + 'CK ', + 'CR ', + 'CI ', + 'HR ', + 'CU ', + 'CY ', + 'CZ ', + 'DK ', + 'DJ ', + 'DM ', + 'DO ', + 'EC ', + 'EG ', + 'SV ', + 'GQ ', + 'ER ', + 'EE ', + 'ET ', + 'FK ', + 'FO ', + 'FJ ', + 'FI ', + 'FR ', + 'GF ', + 'PF ', + 'TF ', + 'GA ', + 'GM ', + 'GE ', + 'DE ', + 'GH ', + 'GI ', + 'GR ', + 'GL ', + 'GD ', + 'GP ', + 'GU ', + 'GT ', + 'GG ', + 'GN ', + 'GW ', + 'GY ', + 'HT ', + 'HM ', + 'VA ', + 'HN ', + 'HK ', + 'HU ', + 'IS ', + 'IN ', + 'ID ', + 'IR ', + 'IQ ', + 'IE ', + 'IM ', + 'IL ', + 'IT ', + 'JM ', + 'JP ', + 'JE ', + 'JO ', + 'KZ ', + 'KE ', + 'KI ', + 'KP ', + 'KR ', + 'KW ', + 'KG ', + 'LA ', + 'LV ', + 'LB ', + 'LS ', + 'LR ', + 'LY ', + 'LI ', + 'LT ', + 'LU ', + 'MO ', + 'MK ', + 'MG ', + 'MW ', + 'MY ', + 'MV ', + 'ML ', + 'MT ', + 'MH ', + 'MQ ', + 'MR ', + 'MU ', + 'YT ', + 'MX ', + 'FM ', + 'MD ', + 'MC ', + 'MN ', + 'MS ', + 'MA ', + 'MZ ', + 'MM ', + 'NA ', + 'NR ', + 'NP ', + 'NL ', + 'AN ', + 'NC ', + 'NZ ', + 'NI ', + 'NE ', + 'NG ', + 'NU ', + 'NF ', + 'MP ', + 'NO ', + 'OM ', + 'PK ', + 'PW ', + 'PS ', + 'PA ', + 'PG ', + 'PY ', + 'PE ', + 'PH ', + 'PN ', + 'PL ', + 'PT ', + 'PR ', + 'QA ', + 'RE ', + 'RO ', + 'RU ', + 'RW ', + 'SH ', + 'KN ', + 'LC ', + 'PM ', + 'VC ', + 'WS ', + 'SM ', + 'ST ', + 'SA ', + 'SN ', + 'CS ', + 'SC ', + 'SL ', + 'SG ', + 'SK ', + 'SI ', + 'SB ', + 'SO ', + 'ZA ', + 'GS ', + 'ES ', + 'LK ', + 'SD ', + 'SR ', + 'SJ ', + 'SZ ', + 'SE ', + 'CH ', + 'SY ', + 'TW ', + 'TJ ', + 'TZ ', + 'TH ', + 'TL ', + 'TG ', + 'TK ', + 'TO ', + 'TT ', + 'TN ', + 'TR ', + 'TM ', + 'TC ', + 'TV ', + 'UG ', + 'UA ', + 'AE ', + 'GB ', + 'US ', + 'UM ', + 'UY ', + 'UZ ', + 'VU ', + 'VE ', + 'VN ', + 'VG ', + 'VI ', + 'WF ', + 'EH ', + 'YE ', + 'ZM ', + 'ZW', + ]; /** * Locale codes supported by misc images (marks, shortcuts etc) @@ -269,8 +584,21 @@ class Mage_Paypal_Model_Config * @var array * @link https://cms.paypal.com/us/cgi-bin/?cmd=_render-content&content_ID=developer/e_howto_api_ECButtonIntegration#id089QD0O0TX4__id08AH904I0YK */ - protected $_supportedImageLocales = array('de_DE', 'en_AU', 'en_GB', self::LOCALE_US, - 'es_ES', 'es_XC', 'fr_FR', 'fr_XC', 'it_IT', 'ja_JP', 'nl_NL', 'pl_PL', 'zh_CN', 'zh_XC', + protected $_supportedImageLocales = array( + 'de_DE', + 'en_AU', + 'en_GB', + 'en_US', + 'es_ES', + 'es_XC', + 'fr_FR', + 'fr_XC', + 'it_IT', + 'ja_JP', + 'nl_NL', + 'pl_PL', + 'zh_CN', + 'zh_XC', ); /** diff --git a/app/code/core/Mage/ProductAlert/Block/Email/Price.php b/app/code/core/Mage/ProductAlert/Block/Email/Price.php index 3fed30ae695..e6d9a557b3b 100644 --- a/app/code/core/Mage/ProductAlert/Block/Email/Price.php +++ b/app/code/core/Mage/ProductAlert/Block/Email/Price.php @@ -45,7 +45,7 @@ public function __construct() } /** - * Retrive unsubscribe url for product + * Retrieve unsubscribe url for product * * @param int $productId * @return string diff --git a/app/code/core/Mage/ProductAlert/Block/Email/Stock.php b/app/code/core/Mage/ProductAlert/Block/Email/Stock.php index 2929a696cc1..d8f9aacb439 100644 --- a/app/code/core/Mage/ProductAlert/Block/Email/Stock.php +++ b/app/code/core/Mage/ProductAlert/Block/Email/Stock.php @@ -45,7 +45,7 @@ public function __construct() } /** - * Retrive unsubscribe url for product + * Retrieve unsubscribe url for product * * @param int $productId * @return string diff --git a/app/code/core/Mage/Reports/Exception.php b/app/code/core/Mage/Reports/Exception.php index 5e65e2fcc36..41476cf7d9f 100644 --- a/app/code/core/Mage/Reports/Exception.php +++ b/app/code/core/Mage/Reports/Exception.php @@ -29,5 +29,5 @@ class Mage_Reports_Exception extends Zend_Exception { - + } diff --git a/app/code/core/Mage/Reports/Model/Resource/Report/Abstract.php b/app/code/core/Mage/Reports/Model/Resource/Report/Abstract.php index 219c0a00d7d..024f577bccb 100644 --- a/app/code/core/Mage/Reports/Model/Resource/Report/Abstract.php +++ b/app/code/core/Mage/Reports/Model/Resource/Report/Abstract.php @@ -42,7 +42,7 @@ abstract class Mage_Reports_Model_Resource_Report_Abstract extends Mage_Core_Mod protected $_flag = null; /** - * Retrive flag object + * Retrieve flag object * * @return Mage_Reports_Model_Flag */ diff --git a/app/code/core/Mage/Reports/Model/Resource/Tag/Product/Collection.php b/app/code/core/Mage/Reports/Model/Resource/Tag/Product/Collection.php index 6a3fe8a3c13..7ce47b5df10 100644 --- a/app/code/core/Mage/Reports/Model/Resource/Tag/Product/Collection.php +++ b/app/code/core/Mage/Reports/Model/Resource/Tag/Product/Collection.php @@ -50,7 +50,7 @@ protected function _construct() public function addUniqueTagedCount() { $select = clone $this->getSelect(); - + $select->reset() ->from(array('rel' => $this->getTable('tag/relation')), 'COUNT(DISTINCT rel.tag_id)') ->where('rel.product_id = e.entity_id'); diff --git a/app/code/core/Mage/Reports/Model/Resource/Wishlist/Collection.php b/app/code/core/Mage/Reports/Model/Resource/Wishlist/Collection.php index e0e1b495358..47002820361 100644 --- a/app/code/core/Mage/Reports/Model/Resource/Wishlist/Collection.php +++ b/app/code/core/Mage/Reports/Model/Resource/Wishlist/Collection.php @@ -81,7 +81,7 @@ public function getWishlistCustomerCount() { /** @var Mage_Customer_Model_Resource_Customer_Collection $collection */ $collection = Mage::getResourceModel('customer/customer_collection'); - + $customersSelect = $collection->getSelectCountSql(); $countSelect = clone $customersSelect; diff --git a/app/code/core/Mage/Reports/sql/reports_setup/mysql4-upgrade-0.7.1-0.7.2.php b/app/code/core/Mage/Reports/sql/reports_setup/mysql4-upgrade-0.7.1-0.7.2.php index 8dc1c4f7d94..66085046e9c 100644 --- a/app/code/core/Mage/Reports/sql/reports_setup/mysql4-upgrade-0.7.1-0.7.2.php +++ b/app/code/core/Mage/Reports/sql/reports_setup/mysql4-upgrade-0.7.1-0.7.2.php @@ -39,10 +39,10 @@ $installer->run(" ALTER TABLE {$this->getTable('report_event_types')} DROP INDEX `event_type_id`; -ALTER TABLE {$this->getTable('report_event_types')} CHANGE `event_name` `event_name` varchar(64) NOT NULL; +ALTER TABLE {$this->getTable('report_event_types')} CHANGE `event_name` `event_name` varchar(64) NOT NULL; UPDATE {$this->getTable('report_event_types')} SET `event_name`='catalog_product_compare_add_product' WHERE `event_type_id`=3; ALTER TABLE {$this->getTable('report_event')} ADD `sybtype` tinyint(3) unsigned NOT NULL default '0' AFTER `subject_id`; -ALTER TABLE {$this->getTable('report_event')} ADD INDEX (`event_type_id`); +ALTER TABLE {$this->getTable('report_event')} ADD INDEX (`event_type_id`); ALTER TABLE {$this->getTable('report_event')} ADD INDEX (`sybtype`); ALTER TABLE {$this->getTable('report_event')} ADD INDEX (`store_id`); ALTER TABLE {$this->getTable('report_event_types')} ADD `customer_login` TINYINT UNSIGNED NOT NULL DEFAULT '0'; diff --git a/app/code/core/Mage/Review/Model/Resource/Review/Product/Collection.php b/app/code/core/Mage/Review/Model/Resource/Review/Product/Collection.php index 3fcdac0510f..40d5b2c121d 100644 --- a/app/code/core/Mage/Review/Model/Resource/Review/Product/Collection.php +++ b/app/code/core/Mage/Review/Model/Resource/Review/Product/Collection.php @@ -301,7 +301,7 @@ protected function _joinFields() } /** - * Retrive all ids for collection + * Retrieve all ids for collection * * @inheritDoc */ diff --git a/app/code/core/Mage/Rule/Model/Action/Interface.php b/app/code/core/Mage/Rule/Model/Action/Interface.php index 5e8975a275f..20faa7594d1 100644 --- a/app/code/core/Mage/Rule/Model/Action/Interface.php +++ b/app/code/core/Mage/Rule/Model/Action/Interface.php @@ -27,5 +27,5 @@ interface Mage_Rule_Model_Action_Interface { - + } diff --git a/app/code/core/Mage/Rule/Model/Condition/Interface.php b/app/code/core/Mage/Rule/Model/Condition/Interface.php index f24af354169..425f44ff942 100644 --- a/app/code/core/Mage/Rule/Model/Condition/Interface.php +++ b/app/code/core/Mage/Rule/Model/Condition/Interface.php @@ -27,5 +27,5 @@ interface Mage_Rule_Model_Condition_Interface { - + } diff --git a/app/code/core/Mage/Sales/Exception.php b/app/code/core/Mage/Sales/Exception.php index 77f2ef7ce1f..01544d873ad 100644 --- a/app/code/core/Mage/Sales/Exception.php +++ b/app/code/core/Mage/Sales/Exception.php @@ -27,5 +27,5 @@ class Mage_Sales_Exception extends Zend_Exception { - + } diff --git a/app/code/core/Mage/Sales/Model/Entity/Order/Creditmemo/Attribute/Backend/Parent.php b/app/code/core/Mage/Sales/Model/Entity/Order/Creditmemo/Attribute/Backend/Parent.php index 0f0c5882f8c..b3d8ddb77fe 100644 --- a/app/code/core/Mage/Sales/Model/Entity/Order/Creditmemo/Attribute/Backend/Parent.php +++ b/app/code/core/Mage/Sales/Model/Entity/Order/Creditmemo/Attribute/Backend/Parent.php @@ -40,7 +40,7 @@ public function afterSave($object) foreach ($object->getAllItems() as $item) { $item->save(); } - + foreach ($object->getCommentsCollection() as $comment) { $comment->save(); } diff --git a/app/code/core/Mage/Sales/Model/Entity/Quote/Address/Attribute/Backend/Parent.php b/app/code/core/Mage/Sales/Model/Entity/Quote/Address/Attribute/Backend/Parent.php index d76fca11fba..24cbce7165b 100644 --- a/app/code/core/Mage/Sales/Model/Entity/Quote/Address/Attribute/Backend/Parent.php +++ b/app/code/core/Mage/Sales/Model/Entity/Quote/Address/Attribute/Backend/Parent.php @@ -33,10 +33,10 @@ class Mage_Sales_Model_Entity_Quote_Address_Attribute_Backend_Parent extends Mag public function afterSave($object) { parent::afterSave($object); - + $object->getItemsCollection()->save(); $object->getShippingRatesCollection()->save(); - + return $this; } } diff --git a/app/code/core/Mage/Sales/Model/Entity/Quote/Address/Attribute/Frontend.php b/app/code/core/Mage/Sales/Model/Entity/Quote/Address/Attribute/Frontend.php index a1b092dda6e..d1fc5756dfa 100644 --- a/app/code/core/Mage/Sales/Model/Entity/Quote/Address/Attribute/Frontend.php +++ b/app/code/core/Mage/Sales/Model/Entity/Quote/Address/Attribute/Frontend.php @@ -34,7 +34,7 @@ class Mage_Sales_Model_Entity_Quote_Address_Attribute_Frontend extends Mage_Eav_ public function fetchTotals(Mage_Sales_Model_Quote_Address $address) { $arr = array(); - + return $arr; } } diff --git a/app/code/core/Mage/Sales/Model/Entity/Sale/Collection.php b/app/code/core/Mage/Sales/Model/Entity/Sale/Collection.php index 3d9248b5fd4..82c36230c79 100644 --- a/app/code/core/Mage/Sales/Model/Entity/Sale/Collection.php +++ b/app/code/core/Mage/Sales/Model/Entity/Sale/Collection.php @@ -190,6 +190,7 @@ public function getEntity() * * @return ArrayIterator */ + #[\ReturnTypeWillChange] public function getIterator() { return new ArrayIterator($this->_items); diff --git a/app/code/core/Mage/Sales/Model/Order/Invoice/Api.php b/app/code/core/Mage/Sales/Model/Order/Invoice/Api.php index 44234591e4a..a2c7a3faf76 100644 --- a/app/code/core/Mage/Sales/Model/Order/Invoice/Api.php +++ b/app/code/core/Mage/Sales/Model/Order/Invoice/Api.php @@ -45,7 +45,7 @@ public function __construct() } /** - * Retrive invoices list. Filtration could be applied + * Retrieve invoices list. Filtration could be applied * * @param null|object|array $filters * @return array @@ -98,6 +98,10 @@ public function info($invoiceIncrementId) $result = $this->_getAttributes($invoice, 'invoice'); $result['order_increment_id'] = $invoice->getOrderIncrementId(); + $result['order_created_at'] = $invoice->getOrder()->getCreatedAt(); + $result['billing_firstname'] = $invoice->getBillingAddress()->getFirstname(); + $result['billing_middlename'] = $invoice->getBillingAddress()->getMiddlename(); + $result['billing_lastname'] = $invoice->getBillingAddress()->getLastname(); $result['items'] = array(); foreach ($invoice->getAllItems() as $item) { diff --git a/app/code/core/Mage/Sales/Model/Order/Pdf/Creditmemo.php b/app/code/core/Mage/Sales/Model/Order/Pdf/Creditmemo.php index 4ead5675ac0..2a22231638a 100644 --- a/app/code/core/Mage/Sales/Model/Order/Pdf/Creditmemo.php +++ b/app/code/core/Mage/Sales/Model/Order/Pdf/Creditmemo.php @@ -43,12 +43,12 @@ class Mage_Sales_Model_Order_Pdf_Creditmemo extends Mage_Sales_Model_Order_Pdf_A protected function _drawHeader(Zend_Pdf_Page $page) { $this->_setFontRegular($page, 10); - $page->setFillColor(new Zend_Pdf_Color_RGB(0.93, 0.92, 0.92)); + $page->setFillColor(new Zend_Pdf_Color_Rgb(0.93, 0.92, 0.92)); $page->setLineColor(new Zend_Pdf_Color_GrayScale(0.5)); $page->setLineWidth(0.5); $page->drawRectangle(25, $this->y, 570, $this->y - 30); $this->y -= 10; - $page->setFillColor(new Zend_Pdf_Color_RGB(0, 0, 0)); + $page->setFillColor(new Zend_Pdf_Color_Rgb(0, 0, 0)); //columns headers $lines[0][] = array( diff --git a/app/code/core/Mage/Sales/Model/Order/Pdf/Invoice.php b/app/code/core/Mage/Sales/Model/Order/Pdf/Invoice.php index a965a404ddd..9a5c47f1507 100644 --- a/app/code/core/Mage/Sales/Model/Order/Pdf/Invoice.php +++ b/app/code/core/Mage/Sales/Model/Order/Pdf/Invoice.php @@ -43,12 +43,12 @@ protected function _drawHeader(Zend_Pdf_Page $page) { /* Add table head */ $this->_setFontRegular($page, 10); - $page->setFillColor(new Zend_Pdf_Color_RGB(0.93, 0.92, 0.92)); + $page->setFillColor(new Zend_Pdf_Color_Rgb(0.93, 0.92, 0.92)); $page->setLineColor(new Zend_Pdf_Color_GrayScale(0.5)); $page->setLineWidth(0.5); $page->drawRectangle(25, $this->y, 570, $this->y -15); $this->y -= 10; - $page->setFillColor(new Zend_Pdf_Color_RGB(0, 0, 0)); + $page->setFillColor(new Zend_Pdf_Color_Rgb(0, 0, 0)); //columns headers $lines[0][] = array( diff --git a/app/code/core/Mage/Sales/Model/Order/Pdf/Shipment.php b/app/code/core/Mage/Sales/Model/Order/Pdf/Shipment.php index 37260b4bf4a..ec8c99a52f2 100644 --- a/app/code/core/Mage/Sales/Model/Order/Pdf/Shipment.php +++ b/app/code/core/Mage/Sales/Model/Order/Pdf/Shipment.php @@ -43,12 +43,12 @@ protected function _drawHeader(Zend_Pdf_Page $page) { /* Add table head */ $this->_setFontRegular($page, 10); - $page->setFillColor(new Zend_Pdf_Color_RGB(0.93, 0.92, 0.92)); + $page->setFillColor(new Zend_Pdf_Color_Rgb(0.93, 0.92, 0.92)); $page->setLineColor(new Zend_Pdf_Color_GrayScale(0.5)); $page->setLineWidth(0.5); $page->drawRectangle(25, $this->y, 570, $this->y-15); $this->y -= 10; - $page->setFillColor(new Zend_Pdf_Color_RGB(0, 0, 0)); + $page->setFillColor(new Zend_Pdf_Color_Rgb(0, 0, 0)); //columns headers $lines[0][] = array( diff --git a/app/code/core/Mage/Sales/Model/Quote.php b/app/code/core/Mage/Sales/Model/Quote.php index 2b9ffd87e45..b399ae13319 100644 --- a/app/code/core/Mage/Sales/Model/Quote.php +++ b/app/code/core/Mage/Sales/Model/Quote.php @@ -927,7 +927,7 @@ public function getItemById($itemId) if ($item->getId() == $itemId) { $quoteItem = $item; return $quoteItem; - } + } } } return $quoteItem; diff --git a/app/code/core/Mage/Sales/Model/Resource/Collection/Abstract.php b/app/code/core/Mage/Sales/Model/Resource/Collection/Abstract.php index 6cadf387b62..1d212fc393a 100644 --- a/app/code/core/Mage/Sales/Model/Resource/Collection/Abstract.php +++ b/app/code/core/Mage/Sales/Model/Resource/Collection/Abstract.php @@ -131,7 +131,7 @@ protected function _getAllIdsSelect($limit = null, $offset = null) } /** - * Retrive all ids for collection + * Retrieve all ids for collection * Backward compatibility with EAV collection * * @param int $limit diff --git a/app/code/core/Mage/Sales/Model/Resource/Quote/Address/Attribute/Backend/Parent.php b/app/code/core/Mage/Sales/Model/Resource/Quote/Address/Attribute/Backend/Parent.php index c1974cfd294..4b9ec68a861 100644 --- a/app/code/core/Mage/Sales/Model/Resource/Quote/Address/Attribute/Backend/Parent.php +++ b/app/code/core/Mage/Sales/Model/Resource/Quote/Address/Attribute/Backend/Parent.php @@ -42,10 +42,10 @@ class Mage_Sales_Model_Resource_Quote_Address_Attribute_Backend_Parent extends M public function afterSave($object) { parent::afterSave($object); - + $object->getItemsCollection()->save(); $object->getShippingRatesCollection()->save(); - + return $this; } } diff --git a/app/code/core/Mage/Sales/Model/Resource/Quote/Address/Attribute/Frontend.php b/app/code/core/Mage/Sales/Model/Resource/Quote/Address/Attribute/Frontend.php index 00b45788aca..f65ac62b213 100644 --- a/app/code/core/Mage/Sales/Model/Resource/Quote/Address/Attribute/Frontend.php +++ b/app/code/core/Mage/Sales/Model/Resource/Quote/Address/Attribute/Frontend.php @@ -43,7 +43,7 @@ class Mage_Sales_Model_Resource_Quote_Address_Attribute_Frontend extends Mage_Ea public function fetchTotals(Mage_Sales_Model_Quote_Address $address) { $arr = array(); - + return $arr; } } diff --git a/app/code/core/Mage/Sales/Model/Resource/Quote/Item/Option/Collection.php b/app/code/core/Mage/Sales/Model/Resource/Quote/Item/Option/Collection.php index 1fdb8799035..e540fdef585 100644 --- a/app/code/core/Mage/Sales/Model/Resource/Quote/Item/Option/Collection.php +++ b/app/code/core/Mage/Sales/Model/Resource/Quote/Item/Option/Collection.php @@ -116,7 +116,7 @@ public function addItemFilter($item) public function getProductIds() { $this->load(); - + return array_keys($this->_optionsByProduct); } diff --git a/app/code/core/Mage/Sales/Model/Resource/Sale/Collection.php b/app/code/core/Mage/Sales/Model/Resource/Sale/Collection.php index 50140c04b99..8589464ea5c 100644 --- a/app/code/core/Mage/Sales/Model/Resource/Sale/Collection.php +++ b/app/code/core/Mage/Sales/Model/Resource/Sale/Collection.php @@ -111,8 +111,8 @@ public function setOrderStateFilter($state, $exclude = false) $this->_orderStateValue = (!is_array($state)) ? array($state) : $state; return $this; } - - + + /** * Before load action * @@ -197,7 +197,7 @@ public function load($printQuery = false, $logQuery = false) $this->_totals[$key] += $storeObject->getData($key); } } - + if ($this->_totals['num_orders']) { $this->_totals['avgsale'] = $this->_totals['base_lifetime'] / $this->_totals['num_orders']; } diff --git a/app/code/core/Mage/Sales/Model/Service/Quote.php b/app/code/core/Mage/Sales/Model/Service/Quote.php index d28a8f2e376..34d15b461f3 100644 --- a/app/code/core/Mage/Sales/Model/Service/Quote.php +++ b/app/code/core/Mage/Sales/Model/Service/Quote.php @@ -182,7 +182,7 @@ public function submitOrder() Mage::unregister('current_order'); Mage::register('current_order', $order); - + /** * We can use configuration data for declare new order status */ diff --git a/app/code/core/Mage/Sales/etc/wsdl.xml b/app/code/core/Mage/Sales/etc/wsdl.xml index 742d637c77c..f17299402f9 100644 --- a/app/code/core/Mage/Sales/etc/wsdl.xml +++ b/app/code/core/Mage/Sales/etc/wsdl.xml @@ -272,6 +272,7 @@ + diff --git a/app/code/core/Mage/Sales/etc/wsi.xml b/app/code/core/Mage/Sales/etc/wsi.xml index c237ea0ab81..6ed5b675471 100644 --- a/app/code/core/Mage/Sales/etc/wsi.xml +++ b/app/code/core/Mage/Sales/etc/wsi.xml @@ -273,6 +273,7 @@ + diff --git a/app/code/core/Mage/Sales/sql/sales_setup/mysql4-upgrade-0.9.28-0.9.29.php b/app/code/core/Mage/Sales/sql/sales_setup/mysql4-upgrade-0.9.28-0.9.29.php index d9d6289480e..0a26c6e5648 100644 --- a/app/code/core/Mage/Sales/sql/sales_setup/mysql4-upgrade-0.9.28-0.9.29.php +++ b/app/code/core/Mage/Sales/sql/sales_setup/mysql4-upgrade-0.9.28-0.9.29.php @@ -95,7 +95,7 @@ $installer->getConnection()->query( $select->crossUpdateFromSelect(array('main_table'=>$ordersTable)) ); - + $installer->getConnection()->query( 'DROP TEMPORARY TABLE ' . $installer->getConnection()->quoteIdentifier($temporaryTableName) ); @@ -134,7 +134,7 @@ $installer->getConnection()->query( $select->crossUpdateFromSelect(array('main_table'=>$ordersTable)) ); - + $installer->getConnection()->query( 'DROP TEMPORARY TABLE ' . $installer->getConnection()->quoteIdentifier($temporaryTableName) ); diff --git a/app/code/core/Mage/Sales/sql/sales_setup/mysql4-upgrade-0.9.5-0.9.6.php b/app/code/core/Mage/Sales/sql/sales_setup/mysql4-upgrade-0.9.5-0.9.6.php index b3e28df6092..9b86d804f63 100644 --- a/app/code/core/Mage/Sales/sql/sales_setup/mysql4-upgrade-0.9.5-0.9.6.php +++ b/app/code/core/Mage/Sales/sql/sales_setup/mysql4-upgrade-0.9.5-0.9.6.php @@ -28,7 +28,7 @@ /* @var Mage_Sales_Model_Mysql4_Setup $installer */ $installer->run(" -ALTER TABLE `{$installer->getTable('sales_flat_quote_address_item')}` +ALTER TABLE `{$installer->getTable('sales_flat_quote_address_item')}` ADD COLUMN `parent_item_id` INTEGER UNSIGNED AFTER `address_item_id`, ADD KEY `IDX_PARENT_ITEM_ID` (`parent_item_id`); "); diff --git a/app/code/core/Mage/SalesRule/Exception.php b/app/code/core/Mage/SalesRule/Exception.php index e052d316deb..b15a89e6f5b 100644 --- a/app/code/core/Mage/SalesRule/Exception.php +++ b/app/code/core/Mage/SalesRule/Exception.php @@ -27,5 +27,5 @@ class Mage_SalesRule_Exception extends Zend_Exception { - + } diff --git a/app/code/core/Mage/Shipping/Block/Tracking/Popup.php b/app/code/core/Mage/Shipping/Block/Tracking/Popup.php index 60d3ab6def6..c5565960249 100644 --- a/app/code/core/Mage/Shipping/Block/Tracking/Popup.php +++ b/app/code/core/Mage/Shipping/Block/Tracking/Popup.php @@ -248,10 +248,10 @@ public function formatDeliveryTime($time, $date = null) if (!empty($date)) { $time = $date . ' ' . $time; } - + /* @var Mage_Core_Model_Locale $locale */ $locale = Mage::app()->getLocale(); - + $format = $locale->getTimeFormat(Mage_Core_Model_Locale::FORMAT_TYPE_SHORT); return $locale->date(strtotime($time), Zend_Date::TIMESTAMP, null, false) ->toString($format); diff --git a/app/code/core/Mage/Shipping/Exception.php b/app/code/core/Mage/Shipping/Exception.php index f737d4feebf..20c7e9df40e 100644 --- a/app/code/core/Mage/Shipping/Exception.php +++ b/app/code/core/Mage/Shipping/Exception.php @@ -27,5 +27,5 @@ class Mage_Shipping_Exception extends Zend_Exception { - + } diff --git a/app/code/core/Mage/Tax/Exception.php b/app/code/core/Mage/Tax/Exception.php index dcf79060e7e..72fdd2d8c84 100644 --- a/app/code/core/Mage/Tax/Exception.php +++ b/app/code/core/Mage/Tax/Exception.php @@ -27,5 +27,5 @@ class Mage_Tax_Exception extends Mage_Core_Exception { - + } diff --git a/app/code/core/Mage/Tax/Model/Resource/Calculation.php b/app/code/core/Mage/Tax/Model/Resource/Calculation.php index d371a16ea6f..d9636139ee4 100644 --- a/app/code/core/Mage/Tax/Model/Resource/Calculation.php +++ b/app/code/core/Mage/Tax/Model/Resource/Calculation.php @@ -222,16 +222,16 @@ protected function _collectPercent($percent, $rate) protected function _createSearchPostCodeTemplates($postcode) { $len = Mage::helper('tax')->getPostCodeSubStringLength(); - $strlen = strlen($postcode); + $strlen = mb_strlen($postcode); if ($strlen > $len) { - $postcode = substr($postcode, 0, $len); + $postcode = mb_substr($postcode, 0, $len); $strlen = $len; } $strArr = array((string)$postcode, $postcode . '*'); if ($strlen > 1) { for ($i = 1; $i < $strlen; $i++) { - $strArr[] = sprintf('%s*', substr($postcode, 0, - $i)); + $strArr[] = sprintf('%s*', mb_substr($postcode, 0, - $i)); } } diff --git a/app/code/core/Mage/Tax/Model/Sales/Pdf/Subtotal.php b/app/code/core/Mage/Tax/Model/Sales/Pdf/Subtotal.php index b97c0786a49..acc87b6f9c8 100644 --- a/app/code/core/Mage/Tax/Model/Sales/Pdf/Subtotal.php +++ b/app/code/core/Mage/Tax/Model/Sales/Pdf/Subtotal.php @@ -52,10 +52,10 @@ public function getTotalsForDisplay() +$this->getSource()->getTaxAmount() -$this->getSource()->getShippingTaxAmount(); } - + $amountInclTax = $this->getOrder()->formatPriceTxt($amountInclTax); $fontSize = $this->getFontSize() ? $this->getFontSize() : 7; - + if ($helper->displaySalesSubtotalBoth($store)) { $totals = array( array( @@ -82,7 +82,7 @@ public function getTotalsForDisplay() 'font_size' => $fontSize )); } - + return $totals; } } diff --git a/app/code/core/Mage/Widget/Model/Widget.php b/app/code/core/Mage/Widget/Model/Widget.php index 87c1feeb7c2..7286027f258 100644 --- a/app/code/core/Mage/Widget/Model/Widget.php +++ b/app/code/core/Mage/Widget/Model/Widget.php @@ -256,7 +256,7 @@ public function getWidgetDeclaration($type, $params = array(), $asIs = true) '', $this->_idEncode($directive), $image, - Mage::helper('core')->urlEscape($directive) + Mage::helper('core')->escapeUrl($directive) ); return $html; } diff --git a/app/code/core/Mage/Wishlist/Block/Customer/Wishlist/Item/Column/Cart.php b/app/code/core/Mage/Wishlist/Block/Customer/Wishlist/Item/Column/Cart.php index 69fc0b5e2ac..0df07b7a4e2 100644 --- a/app/code/core/Mage/Wishlist/Block/Customer/Wishlist/Item/Column/Cart.php +++ b/app/code/core/Mage/Wishlist/Block/Customer/Wishlist/Item/Column/Cart.php @@ -56,7 +56,7 @@ public function getJs() function addWItemToCart(itemId) { addWItemToCartCustom(itemId, true) } - + function addWItemToCartCustom(itemId, sendGet) { var url = ''; if (sendGet) { @@ -64,8 +64,9 @@ function addWItemToCartCustom(itemId, sendGet) { } else { url = '" . $this->getItemAddToCartUrlCustom('%item%', false) . "'; } - url = url.gsub('%item%', itemId); - var form = $('wishlist-view-form'); + url = url.replace('%item%', itemId); + + var form = document.getElementById('wishlist-view-form'); if (form) { var input = form['qty[' + itemId + ']']; if (input) { @@ -74,7 +75,7 @@ function addWItemToCartCustom(itemId, sendGet) { } } if (sendGet) { - setLocation(url); + window.location.href = encodeURI(url); } else { customFormSubmit(url, '" . json_encode(array('form_key' => $this->getFormKey())) . "', 'post'); } diff --git a/app/code/core/Mage/Wishlist/Controller/Abstract.php b/app/code/core/Mage/Wishlist/Controller/Abstract.php index 3a16869fd95..11a0c62a993 100644 --- a/app/code/core/Mage/Wishlist/Controller/Abstract.php +++ b/app/code/core/Mage/Wishlist/Controller/Abstract.php @@ -51,15 +51,11 @@ abstract class Mage_Wishlist_Controller_Abstract extends Mage_Core_Controller_Fr * * @param string $qty * @return float|int|null + * @deprecated */ protected function _processLocalizedQty($qty) { - if (!$this->_localFilter) { - $this->_localFilter = new Zend_Filter_LocalizedToNormalized( - array('locale' => Mage::app()->getLocale()->getLocaleCode()) - ); - } - $qty = $this->_localFilter->filter((float)$qty); + $qty = (float)$qty; if ($qty < 0) { $qty = null; } diff --git a/app/code/core/Mage/Wishlist/controllers/IndexController.php b/app/code/core/Mage/Wishlist/controllers/IndexController.php index 173933bda64..e391738c32d 100644 --- a/app/code/core/Mage/Wishlist/controllers/IndexController.php +++ b/app/code/core/Mage/Wishlist/controllers/IndexController.php @@ -508,8 +508,8 @@ public function cartAction() $qty = 1; } } - $qty = $this->_processLocalizedQty($qty); - if ($qty) { + $qty = (float)$qty; + if ($qty && $qty>0) { $item->setQty($qty); } diff --git a/app/code/core/Zend/Controller/Request/Http.php b/app/code/core/Zend/Controller/Request/Http.php index 264bdabb7ef..f396b8912c3 100644 --- a/app/code/core/Zend/Controller/Request/Http.php +++ b/app/code/core/Zend/Controller/Request/Http.php @@ -613,16 +613,16 @@ public function setPathInfo($pathInfo = null) $baseUrl = $this->getBaseUrl(); // this actually calls setBaseUrl() & setRequestUri() $baseUrlRaw = $this->getBaseUrl(false); $baseUrlEncoded = urlencode($baseUrlRaw); - + if (null === ($requestUri = $this->getRequestUri())) { return $this; } - + // Remove the query string from REQUEST_URI if ($pos = strpos($requestUri, '?')) { $requestUri = substr($requestUri, 0, $pos); } - + if (!empty($baseUrl) || !empty($baseUrlRaw)) { if (strpos($requestUri, $baseUrl) === 0) { $pathInfo = substr($requestUri, strlen($baseUrl)); @@ -636,7 +636,7 @@ public function setPathInfo($pathInfo = null) } else { $pathInfo = $requestUri; } - + } $this->_pathInfo = (string) $pathInfo; @@ -1034,7 +1034,7 @@ public function getHeader($header) */ public function getScheme() { - return ($this->getServer('HTTPS') == 'on') || $this->getServer('HTTP_X_FORWARDED_PROTO') == 'https' ? + return (strtolower((string)$this->getServer('HTTPS')) == 'on') || $this->getServer('HTTP_X_FORWARDED_PROTO') == 'https' ? self::SCHEME_HTTPS : self::SCHEME_HTTP; } diff --git a/app/code/core/Zend/Date.php b/app/code/core/Zend/Date.php index 7f561d9ed63..861a8149588 100644 --- a/app/code/core/Zend/Date.php +++ b/app/code/core/Zend/Date.php @@ -544,12 +544,12 @@ public function get($part = null, $locale = null) } if (($part !== null) && !defined($part) - && ($part != 'ee') && ($part != 'ss') && ($part != 'GG') && ($part != 'MM') && ($part != 'EE') && ($part != 'TT') + && ($part !== 'ee') && ($part !== 'ss') && ($part !== 'GG') && ($part !== 'MM') && ($part !== 'EE') && ($part !== 'TT') + && ($part !== 'U') && ($part !== 'X') && ($part !== 'c') && Zend_Locale::isLocale($part, null, false)) { $locale = $part; $part = null; } - if ($part === null) { $part = self::TIMESTAMP; } else if (self::$_options['format_type'] == 'php') { @@ -4046,7 +4046,7 @@ public function setWeekday($weekday, $locale = null) * If a localized dayname is given it will be parsed with the default locale or the optional * set locale. * Returned is the new date object - * Example: addWeekday(3); will add the difference of days from the begining of the month until + * Example: addWeekday(3); will add the difference of days from the beginning of the month until * wednesday. * * @param string|integer|array|Zend_Date $weekday Weekday to add @@ -4066,7 +4066,7 @@ public function addWeekday($weekday, $locale = null) * If a localized dayname is given it will be parsed with the default locale or the optional * set locale. * Returned is the new date object - * Example: subWeekday(3); will subtract the difference of days from the begining of the month until + * Example: subWeekday(3); will subtract the difference of days from the beginning of the month until * wednesday. * * @param string|integer|array|Zend_Date $weekday Weekday to sub @@ -4643,7 +4643,7 @@ public function compareMilliSecond($milli = null, $precision = null) } /** - * Returns the week as new date object using monday as begining of the week + * Returns the week as new date object using monday as beginning of the week * Example: 12.Jan.2007 -> 08.Jan.1970 00:00:00 * * @param Zend_Locale $locale OPTIONAL Locale for parsing input diff --git a/app/design/adminhtml/default/default/layout/bundle.xml b/app/design/adminhtml/default/default/layout/bundle.xml index c1f6f2c218f..9cc39bf37b1 100644 --- a/app/design/adminhtml/default/default/layout/bundle.xml +++ b/app/design/adminhtml/default/default/layout/bundle.xml @@ -98,7 +98,7 @@ Layout handle for budle products bundlebundle/adminhtml_sales_order_items_renderer - + bundlebundle/catalog_product_configuration diff --git a/app/design/adminhtml/default/default/layout/catalog.xml b/app/design/adminhtml/default/default/layout/catalog.xml index 2ac2a198d9e..e3bbce2c80c 100644 --- a/app/design/adminhtml/default/default/layout/catalog.xml +++ b/app/design/adminhtml/default/default/layout/catalog.xml @@ -77,7 +77,7 @@ - + @@ -306,11 +306,11 @@ Layout handle for configurable products - + - + diff --git a/app/design/adminhtml/default/default/layout/centinel.xml b/app/design/adminhtml/default/default/layout/centinel.xml index 82de48f1b3c..1f0c9424215 100644 --- a/app/design/adminhtml/default/default/layout/centinel.xml +++ b/app/design/adminhtml/default/default/layout/centinel.xml @@ -31,7 +31,7 @@ - + diff --git a/app/design/adminhtml/default/default/layout/dataflow.xml b/app/design/adminhtml/default/default/layout/dataflow.xml index 477a2c97dca..2599c332c64 100644 --- a/app/design/adminhtml/default/default/layout/dataflow.xml +++ b/app/design/adminhtml/default/default/layout/dataflow.xml @@ -41,7 +41,7 @@ - + diff --git a/app/design/adminhtml/default/default/layout/downloadable.xml b/app/design/adminhtml/default/default/layout/downloadable.xml index d1b292e0e70..4f3587d56a6 100644 --- a/app/design/adminhtml/default/default/layout/downloadable.xml +++ b/app/design/adminhtml/default/default/layout/downloadable.xml @@ -82,13 +82,13 @@ downloadabledownloadable/adminhtml_sales_items_column_downloadable_name - + downloadabledownloadable/catalog_product_configuration - + diff --git a/app/design/adminhtml/default/default/layout/main.xml b/app/design/adminhtml/default/default/layout/main.xml index 33d3accb5f8..81281e8e0d1 100644 --- a/app/design/adminhtml/default/default/layout/main.xml +++ b/app/design/adminhtml/default/default/layout/main.xml @@ -109,7 +109,6 @@ Default layout, loads most of the pages - diff --git a/app/design/adminhtml/default/default/template/catalog/product/composite/fieldset/qty.phtml b/app/design/adminhtml/default/default/template/catalog/product/composite/fieldset/qty.phtml index c83bc296295..0792bbafb26 100644 --- a/app/design/adminhtml/default/default/template/catalog/product/composite/fieldset/qty.phtml +++ b/app/design/adminhtml/default/default/template/catalog/product/composite/fieldset/qty.phtml @@ -38,7 +38,7 @@ diff --git a/app/design/adminhtml/default/default/template/catalog/product/edit/action/inventory.phtml b/app/design/adminhtml/default/default/template/catalog/product/edit/action/inventory.phtml index 5bbf63a98ac..4e168136fd6 100644 --- a/app/design/adminhtml/default/default/template/catalog/product/edit/action/inventory.phtml +++ b/app/design/adminhtml/default/default/template/catalog/product/edit/action/inventory.phtml @@ -85,7 +85,7 @@ function toggleValueElementsWithCheckbox(checkbox) { - + diff --git a/app/design/adminhtml/default/default/template/example.phtml b/app/design/adminhtml/default/default/template/example.phtml deleted file mode 100644 index 968efe4bcca..00000000000 --- a/app/design/adminhtml/default/default/template/example.phtml +++ /dev/null @@ -1,299 +0,0 @@ - - - - - - <?php echo Mage::helper('adminhtml')->__('Magento Commerce - Administrative Panel') ?> - - - - - -

- -
-

Today is: June 01, 2007|Minu Oh (Administrator)|Logout

-
- -
-
-
- - getLayout()->createBlock('adminhtml/page_menu')->toHtml() ?> - -
-
- -
-
-
-
-
- - - - - -

Minu Oh - Customer View

Save
-
-
-

Personal Information

-
-

Last Logged in: June, 16, 2007 ( Currently OFFLINE )

-

Account Created: April 1, 2001

-
- Contact Information
Minu Oh ( minu@varien.com)
- 3402 Motor Ave Suite B
- Los Angeles, CA 90034
- United States
- T | (310) 123-1234
-
-
-
-

Sales Tally

-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
 Lifetime SalesAverage Sale
Total$9000.82$400.99
Site 1$1899.82$82.99
Site 1$1899.82$82.99
Site 1$1899.82$82.99
Site 1$1899.82$82.99
Site 1$1899.82$82.99
Site 1$1899.82$82.99
-
-
-
-
-

Sales Stat

-
-
Last 5 Orders
-
-
Wishlist (5 items)
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Product IDProduct NamePrice
Total$400.99
00212Some sort of product name goes here$82.99
00212Some sort of product name goes here$82.99
00212Some sort of product name goes here$82.99
00212Some sort of product name goes here$82.99
00212Some sort of product name goes here$82.99
00212Some sort of product name goes here$82.99
-
Gift Registries (0 items)
-
-
Shopping Cart (1 item)
-
-
- - - - - -

- -
- - - - - -

Minu Oh - Addresses

- Delete - Save - New Address -
-
-
-

Customer Addresses

-
    -
  • -
    Minu Oh
    - 3402 Motor Ave Suite B
    - Los Angeles, CA 90034
    - T | 310-123-1234 -
    -
  • -
  • -
    Minu Oh
    - 3402 Motor Ave Suite B
    - Los Angeles, CA 90034
    - T | 310-123-1234 -
    -
  • -
  • -
    Minu Oh
    - 3402 Motor Ave Suite B
    - Los Angeles, CA 90034
    - T | 310-123-1234 -
    -
  • -
  • -
    Minu Oh
    - 3402 Motor Ave Suite B
    - Los Angeles, CA 90034
    - T | 310-123-1234 -
    -
  • -
-
-
-

Edit Address Entry

-
-
-
    -
  • -
  • -
  • -
  • -
  • -
  • -
-
-
-
- - - - - - -
-
- - - - -
-
-
- - - - - diff --git a/app/design/adminhtml/default/default/template/forgotpassword.phtml b/app/design/adminhtml/default/default/template/forgotpassword.phtml index 65b54cdb7b6..6f44613fdcc 100644 --- a/app/design/adminhtml/default/default/template/forgotpassword.phtml +++ b/app/design/adminhtml/default/default/template/forgotpassword.phtml @@ -25,17 +25,19 @@ */ ?> - + - <?php echo Mage::helper('adminhtml')->__('Log into OpenMage Admin Page'); ?> - - - - - - + <?php echo Mage::helper('adminhtml')->__('Log into OpenMage Admin Page') ?> + + + + + + + + @@ -43,29 +45,29 @@
- +
- diff --git a/app/design/adminhtml/default/default/template/login.phtml b/app/design/adminhtml/default/default/template/login.phtml index 8a7ac6ae92a..66ee5f49483 100644 --- a/app/design/adminhtml/default/default/template/login.phtml +++ b/app/design/adminhtml/default/default/template/login.phtml @@ -34,43 +34,44 @@ - - +
-
+
- +
- diff --git a/app/design/adminhtml/default/default/template/notification/survey.phtml b/app/design/adminhtml/default/default/template/notification/survey.phtml deleted file mode 100644 index 59ac538761a..00000000000 --- a/app/design/adminhtml/default/default/template/notification/survey.phtml +++ /dev/null @@ -1,56 +0,0 @@ - - -canShow()): ?> - -
- helper('adminhtml')->__('We appreciate our merchants\' feedback, please take our survey to provide insight on the features you would like included in Magento. Remove this notification') ?> - -
- diff --git a/app/design/adminhtml/default/default/template/page/footer.phtml b/app/design/adminhtml/default/default/template/page/footer.phtml index d30ae268d62..e006d75111c 100644 --- a/app/design/adminhtml/default/default/template/page/footer.phtml +++ b/app/design/adminhtml/default/default/template/page/footer.phtml @@ -31,7 +31,7 @@

__('Connect with the OpenMage Community') ?>

-__('OpenMage LTS %s', Mage::getOpenMageVersion()) ?> +__('OpenMage %s', Mage::getOpenMageVersion()) ?> - - -
-
-
- - -
-
- -
+ + + + + <?php echo Mage::helper('adminhtml')->__('Reset a Password') ?> + + + + + + + + + + + +
+ - +
+ diff --git a/app/design/adminhtml/default/default/template/widget/grid.phtml b/app/design/adminhtml/default/default/template/widget/grid.phtml index 46df2990186..bfeefd45d4d 100644 --- a/app/design/adminhtml/default/default/template/widget/grid.phtml +++ b/app/design/adminhtml/default/default/template/widget/grid.phtml @@ -27,6 +27,7 @@ getColumns()); | __('View') ?> __('per page') ?>| __('Total %d records found', $this->getCollection()->getSize()) ?> @@ -143,7 +142,11 @@ $numColumns = sizeof($this->getColumns()); getColumns() as $_column): ?> - hasTotalsLabel()) ? $_column->getTotalsLabel() : $_column->getRowField($_column->getGrid()->getTotals()) ?>  + + getType() != 'action') && ($_column->getType() != 'massaction')): ?> + hasTotalsLabel() ? $_column->getTotalsLabel() : $_column->getRowField($_column->getGrid()->getTotals()) ?>  + + diff --git a/app/design/adminhtml/default/default/template/widget/grid/massaction.phtml b/app/design/adminhtml/default/default/template/widget/grid/massaction.phtml index a853c9854ec..d768ba40abb 100644 --- a/app/design/adminhtml/default/default/template/widget/grid/massaction.phtml +++ b/app/design/adminhtml/default/default/template/widget/grid/massaction.phtml @@ -48,11 +48,23 @@ getBlockHtml('formkey')?>
- + diff --git a/app/design/adminhtml/default/openmage/template/forgotpassword.phtml b/app/design/adminhtml/default/openmage/template/forgotpassword.phtml index 67fd21530e9..63f1078919c 100644 --- a/app/design/adminhtml/default/openmage/template/forgotpassword.phtml +++ b/app/design/adminhtml/default/openmage/template/forgotpassword.phtml @@ -25,16 +25,18 @@ */ ?> - + - <?php echo Mage::helper('adminhtml')->__('Log into OpenMage LTS Admin Page'); ?> + <?php echo Mage::helper('adminhtml')->__('Log into OpenMage Admin Page') ?> - - - - + + + + + + @@ -42,26 +44,27 @@
diff --git a/app/design/adminhtml/default/openmage/template/login.phtml b/app/design/adminhtml/default/openmage/template/login.phtml index bb6984f74c7..c3fd2f547b6 100644 --- a/app/design/adminhtml/default/openmage/template/login.phtml +++ b/app/design/adminhtml/default/openmage/template/login.phtml @@ -29,42 +29,46 @@ - <?php echo Mage::helper('adminhtml')->__('Log into OpenMage LTS Admin Page') ?> + <?php echo Mage::helper('adminhtml')->__('Log into OpenMage Admin Page') ?> - - +
-
+
- +
diff --git a/app/design/adminhtml/default/openmage/template/page/header.phtml b/app/design/adminhtml/default/openmage/template/page/header.phtml index f31d0dee9df..77bb011a975 100644 --- a/app/design/adminhtml/default/openmage/template/page/header.phtml +++ b/app/design/adminhtml/default/openmage/template/page/header.phtml @@ -42,7 +42,6 @@