From 23e802ea9608878d6f03e8b144677888d4c1a132 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=90=9D=E5=8D=9C?= Date: Wed, 18 Mar 2026 23:02:07 +0800 Subject: [PATCH] =?UTF-8?q?=E7=BB=9F=E4=B8=80=E6=80=BB=E5=8F=B0=E4=BB=AA?= =?UTF-8?q?=E8=A1=A8=E7=9B=98=E5=B7=B2=E4=BB=98=E6=97=A0=E5=9B=9E=E6=89=A7?= =?UTF-8?q?=E8=BE=85=E5=8A=A9=E6=96=87=E6=A1=88=E5=8F=A3=E5=BE=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- resources/views/admin/dashboard.blade.php | 4 +-- ...aLabelShouldUsePaidNoReceiptPhraseTest.php | 33 +++++++++++++++++++ 2 files changed, 35 insertions(+), 2 deletions(-) create mode 100644 tests/Feature/AdminDashboardPaidNoReceiptAriaLabelShouldUsePaidNoReceiptPhraseTest.php diff --git a/resources/views/admin/dashboard.blade.php b/resources/views/admin/dashboard.blade.php index 95516c2..cb408cf 100644 --- a/resources/views/admin/dashboard.blade.php +++ b/resources/views/admin/dashboard.blade.php @@ -442,7 +442,7 @@ 'rowRole' => 'dashboard-po-no-receipt-row', 'barRole' => 'dashboard-po-no-receipt-bar', 'href' => $platformOrdersQuickLinks['paid_no_receipt'], - 'ariaLabel' => '进入无回执订单集合', + 'ariaLabel' => '进入已付无回执订单集合', 'label' => '无回执', 'pct' => $poNoReceiptPct, 'title' => $poNoReceipt . ' / ' . $poTotal . '(' . $poNoReceiptPct . '%)', @@ -757,7 +757,7 @@ 'rowRole' => 'ops-risk-no-receipt-row', 'barRole' => 'ops-risk-no-receipt-bar', 'href' => $platformOrdersQuickLinks['paid_no_receipt'], - 'ariaLabel' => '进入无回执订单集合', + 'ariaLabel' => '进入已付无回执订单集合', 'label' => '无回执', 'pct' => $pctRiskNoReceipt, 'title' => $riskNoReceipt . ' / ' . $poTotalForOps . '(' . $pctRiskNoReceipt . '%)', diff --git a/tests/Feature/AdminDashboardPaidNoReceiptAriaLabelShouldUsePaidNoReceiptPhraseTest.php b/tests/Feature/AdminDashboardPaidNoReceiptAriaLabelShouldUsePaidNoReceiptPhraseTest.php new file mode 100644 index 0000000..3f110c1 --- /dev/null +++ b/tests/Feature/AdminDashboardPaidNoReceiptAriaLabelShouldUsePaidNoReceiptPhraseTest.php @@ -0,0 +1,33 @@ +seed(); + + $this->post('/admin/login', [ + 'email' => 'platform.admin@demo.local', + 'password' => 'Platform@123456', + ])->assertRedirect('/admin'); + } + + public function test_dashboard_paid_no_receipt_aria_label_should_use_paid_no_receipt_phrase(): void + { + $this->loginAsPlatformAdmin(); + + $res = $this->get('/admin'); + $res->assertOk(); + + $html = (string) $res->getContent(); + $this->assertStringContainsString('aria-label="进入已付无回执订单集合"', $html); + $this->assertStringNotContainsString('aria-label="进入无回执订单集合"', $html); + } +}