From eeb300194647a2d8b737ddfa942f8c19d4e52ca2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=8B=8F=E6=9C=A8?= <594326199@qq.com> Date: Sat, 17 Oct 2026 10:24:00 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BE=9B=E5=BA=94=E5=95=86=E5=AF=B9=E8=B4=A6?= =?UTF-8?q?=EF=BC=9A=E9=80=80=E8=B4=A7=E6=98=8E=E7=BB=86=E6=8C=89=E5=AF=BC?= =?UTF-8?q?=E5=85=A5=E9=A1=BA=E5=BA=8F=E5=B1=95=E7=A4=BA=EF=BC=8C=E4=B8=8D?= =?UTF-8?q?=E5=86=8D=E6=8C=89=E9=87=91=E9=A2=9D=E6=8E=92=E5=BA=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 退货扣减确认表取消「金额从高到低」排序,按导入顺序分页展示(每页 15 行),页面说明同步调整。 --- .../View/SupplierReconciliationPageData.php | 4 +--- .../pages/supplier-reconciliation/supplier-data.blade.php | 2 +- tests/Feature/Business/SupplierReconciliationTest.php | 8 ++++---- 3 files changed, 6 insertions(+), 8 deletions(-) diff --git a/modules/EcommerceFinance/View/SupplierReconciliationPageData.php b/modules/EcommerceFinance/View/SupplierReconciliationPageData.php index 1ff7f2fa..d19fa4a5 100644 --- a/modules/EcommerceFinance/View/SupplierReconciliationPageData.php +++ b/modules/EcommerceFinance/View/SupplierReconciliationPageData.php @@ -205,9 +205,7 @@ class SupplierReconciliationPageData $rows[] = ['_key' => $key, 'status' => $status, 'deduction' => $deduction] + $row; } - usort($rows, static fn (array $a, array $b): int => $b['deduction'] <=> $a['deduction']); - - // 全部退货行按金额从高到低分页展示(每页 15 行)。 + // 全部退货行按导入顺序分页展示(每页 15 行),不做金额排序。 $perPage = self::PER_PAGE; $pages = max((int) ceil(count($rows) / $perPage), 1); $page = min(max((int) request()->query('return_page', 1), 1), $pages); diff --git a/resources/views/business/pages/supplier-reconciliation/supplier-data.blade.php b/resources/views/business/pages/supplier-reconciliation/supplier-data.blade.php index 39798417..e1c65c4b 100644 --- a/resources/views/business/pages/supplier-reconciliation/supplier-data.blade.php +++ b/resources/views/business/pages/supplier-reconciliation/supplier-data.blade.php @@ -239,7 +239,7 @@

列名取自《退货明细》原始表头(标记多标签、创建人、对账人、退货单备注等内部字段不展示),左右滑动查看全部。 - 退货共 {{ number_format($returnPanel['total_rows']) }} 行,按扣减金额从高到低排列,每页 {{ $returnPanel['per_page'] }} 行(第 {{ $returnPanel['page'] }} / {{ $returnPanel['pages'] }} 页)。 + 退货共 {{ number_format($returnPanel['total_rows']) }} 行,按导入顺序展示,每页 {{ $returnPanel['per_page'] }} 行(第 {{ $returnPanel['page'] }} / {{ $returnPanel['pages'] }} 页)。 金额列为空的行以预估金额参与扣减,与采购方记账口径一致。

@if ($returnPanel['pages'] > 1) diff --git a/tests/Feature/Business/SupplierReconciliationTest.php b/tests/Feature/Business/SupplierReconciliationTest.php index 7c0b4de4..0a3d1651 100644 --- a/tests/Feature/Business/SupplierReconciliationTest.php +++ b/tests/Feature/Business/SupplierReconciliationTest.php @@ -185,14 +185,14 @@ class SupplierReconciliationTest extends FeatureTestCase ->assertOk() ->assertSeeText('每页 15 行') ->assertSeeText('第 1 / 2 页') - ->assertSeeText('RT-20') - ->assertDontSeeText('RT-01'); + ->assertSeeText('RT-01') + ->assertDontSeeText('RT-20'); $this->loginAs()->get($pageUrl(2)) ->assertOk() ->assertSeeText('第 2 / 2 页') - ->assertSeeText('RT-01') - ->assertDontSeeText('RT-20'); + ->assertSeeText('RT-20') + ->assertDontSeeText('RT-01'); } public function test_return_rows_can_be_confirmed_disputed_and_confirmed_all(): void