Closed
Description
This issue is automatically created based on existing pull request: #30172: fixing arguments for method in getStatusByState
Summary (*)
Magento 2.4-develop
if you will checking this condition
echo $select = $this->getConnection()->select() ->from(['sss' => $this->stateTable, []]) ->where('state = ?', $state) ->limit(1) ->columns(['status']);
then you see
SELECT
sss.*,
sss.
statusFROM
sales_order_status_stateAS
sss WHERE (state = 'complete') LIMIT 1
but method getStatusByState return is correct value - because the status of a certain state should return. But if this code is rewritten to get the state, then we will also get the status, this is all due to the incorrect parameter in the from method
Examples (*)
- echo $select in getStatusByState method should return sql like this
SELECT
sss.
statusFROM
sales_order_status_stateAS
sssWHERE (state = 'complete') LIMIT 1
Proposed solution
Metadata
Metadata
Assignees
Labels
The issue has been fixed in 2.4-develop branchGate 3 Passed. Manual verification of the issue completed. Issue is confirmedGate 1 Passed. Automatic verification of issue format passedGate 4. Acknowledged. Issue is added to backlog and ready for developmentA defect with this priority could have functionality issues which are not to expectations.Indicates original Magento version for the Issue report.The issue has been reproduced on latest 2.4-develop branchMajor restrictions or short-term circumventions are required until a fix is available.
Type
Projects
Status
Done