DataStore::sort_intervals( AutomatticWooCommerceAdminAPIReportsstdClass $data, string $sort_by, string $direction )

Sorts intervals according to user’s request.


Description Description

They are pre-sorted in SQL, but after adding gaps, they need to be sorted including the added ones.


Parameters Parameters

$data

(Required) Data object, must contain an array under $data->intervals.

$sort_by

(Required) Ordering property.

$direction

(Required) DESC/ASC.


Top ↑

Source Source

File: packages/woocommerce-admin/src/API/Reports/DataStore.php


			


Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.