feat: 新增成本运费异常目录 (#975)
This commit is contained in:
parent
d449afe147
commit
91036350cd
@ -1046,6 +1046,17 @@ $navigation = [
|
||||
],
|
||||
],
|
||||
],
|
||||
[
|
||||
'slug' => 'cost-freight-anomaly',
|
||||
'title' => '成本/运费异常',
|
||||
'directory' => [
|
||||
'icon' => 'warning_amber',
|
||||
'status' => '待接入',
|
||||
'description' => '监控商品成本与运费异常,集中展示成本缺失、成本波动、运费异常和异常结果。',
|
||||
'empty' => '成本/运费异常数据尚未接入。提供取数来源、成本口径和异常阈值后,这里会显示可追溯的异常明细。',
|
||||
'fields' => [],
|
||||
],
|
||||
],
|
||||
[
|
||||
'slug' => 'overview',
|
||||
'title' => '异常数据监控',
|
||||
|
||||
@ -24,6 +24,7 @@ class NavigationTest extends FeatureTestCase
|
||||
->assertSee('/workspace/refunds/non-jingxi-refund-data', false)
|
||||
->assertDontSee('/workspace/refunds/refund-pending', false)
|
||||
->assertSee('/workspace/fee-ratio-monitoring/refund-pending', false)
|
||||
->assertSee('/workspace/fee-ratio-monitoring/cost-freight-anomaly', false)
|
||||
->assertSee('/workspace/product-inventory/normal-products', false)
|
||||
->assertSee('/workspace/product-inventory/monthly-weighted-average-price', false)
|
||||
->assertSee('/workspace/product-inventory/inventory-report', false);
|
||||
@ -306,19 +307,30 @@ class NavigationTest extends FeatureTestCase
|
||||
$this->assertSame('费比异常数据监控', $section['title']);
|
||||
$this->assertSame('monitor_heart', $section['icon']);
|
||||
$this->assertSame(
|
||||
['refund-pending', 'overview'],
|
||||
['refund-pending', 'cost-freight-anomaly', 'overview'],
|
||||
array_column($section['pages'], 'slug'),
|
||||
);
|
||||
$this->assertSame(
|
||||
['退款待确认', '异常数据监控'],
|
||||
['退款待确认', '成本/运费异常', '异常数据监控'],
|
||||
array_column($section['pages'], 'title'),
|
||||
);
|
||||
$this->assertSame('待接入', $section['pages'][1]['directory']['status']);
|
||||
$this->assertSame('待接入', $section['pages'][2]['directory']['status']);
|
||||
|
||||
$sidebarGroup = collect(SidebarMenu::groups($this->user))
|
||||
->firstWhere('title', '费比异常数据监控');
|
||||
$this->assertNull($sidebarGroup);
|
||||
|
||||
$this->loginAs()
|
||||
->get(route('business.pages.show', [
|
||||
'section' => 'fee-ratio-monitoring',
|
||||
'page' => 'cost-freight-anomaly',
|
||||
]))
|
||||
->assertOk()
|
||||
->assertSeeText('费比异常数据监控')
|
||||
->assertSeeText('成本/运费异常')
|
||||
->assertSeeText('成本/运费异常数据尚未接入');
|
||||
|
||||
$this->loginAs()
|
||||
->get(route('business.pages.show', [
|
||||
'section' => 'fee-ratio-monitoring',
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user