?????????? #16

Merged
renshen merged 1 commits from fix/renshen-order-data-navigation into main 2026-08-06 18:33:50 +08:00
2 changed files with 13 additions and 13 deletions

View File

@ -129,6 +129,12 @@ return [
['slug' => 'store-backend-invoicing', 'title' => '店铺后台开票'],
],
],
[
'slug' => 'order-data',
'title' => '订单数据',
'icon' => 'receipt_long',
'pages' => [],
],
[
'slug' => 'store-receivables',
'title' => '店铺应收账款',
@ -167,12 +173,6 @@ return [
['slug' => 'supplier-payables-report', 'title' => '供应商应付表'],
],
],
[
'slug' => 'order-data',
'title' => '订单数据',
'icon' => 'receipt_long',
'pages' => [],
],
[
'slug' => 'courier-payables',
'title' => '快递应付',

View File

@ -42,21 +42,21 @@ class NavigationTest extends FeatureTestCase
$this->assertSame('企业设立', $companyRegistration['title']);
}
public function testOrderDataIsConfiguredAsStandaloneSectionBetweenPayablesMenus()
public function testOrderDataIsConfiguredBetweenInvoiceAndReceivablesMenus()
{
$navigation = BusinessNavigation::all();
$slugs = array_column($navigation, 'slug');
$supplierIndex = array_search('supplier-payables', $slugs, true);
$invoiceIndex = array_search('invoice-management', $slugs, true);
$orderIndex = array_search('order-data', $slugs, true);
$courierIndex = array_search('courier-payables', $slugs, true);
$receivablesIndex = array_search('store-receivables', $slugs, true);
$orderData = $navigation[$orderIndex] ?? null;
$this->assertNotFalse($supplierIndex);
$this->assertNotFalse($invoiceIndex);
$this->assertNotFalse($orderIndex);
$this->assertNotFalse($courierIndex);
$this->assertGreaterThan($supplierIndex, $orderIndex);
$this->assertLessThan($courierIndex, $orderIndex);
$this->assertNotFalse($receivablesIndex);
$this->assertGreaterThan($invoiceIndex, $orderIndex);
$this->assertLessThan($receivablesIndex, $orderIndex);
$this->assertSame('订单数据', $orderData['title']);
$this->assertSame([], $orderData['pages']);
}