<分区>
我有一个像下面提到的数组
Array
(
[6] => Array
(
[name] => Extras
[total_products] => 0
[total_sales] => 0
[total_affiliation] => 0
)
[5] => Array
(
[name] => Office Products
[total_products] => 7
[total_sales] => 17
[total_affiliation] => 8
)
[1] => Array
(
[name] => Hardware Parts
[total_products] => 6
[total_sales] => 0
[total_affiliation] => 0
)
)
现在,订单是:配件、办公用品、硬件零件
我想对主数组进行排序,使其按降序排列的内部数组的 total_sales 排序
因此订单将是:办公用品、附加用品、硬件零件
大家帮忙