diff --git a/resources/views/business/pages/courier-payables/courier-bills/statement.blade.php b/resources/views/business/pages/courier-payables/courier-bills/statement.blade.php index aa799a5d..e411918d 100644 --- a/resources/views/business/pages/courier-payables/courier-bills/statement.blade.php +++ b/resources/views/business/pages/courier-payables/courier-bills/statement.blade.php @@ -44,28 +44,8 @@ @php($target = \App\Support\CourierBills\SummaryMapper::classify($item->label)) {{ $item->label }} @if ($item->manual)手工@endif - @php($blankRow = ! $item->manual && $item->bill_amount === null && $item->self_amount === null) - @if ($open && $blankRow) - -
@csrf - - - -
- - @else {{ $billMoney($item->bill_amount) }} - - @if ($open && ($item->manual || (in_array(preg_replace('/\s+/u', '', $item->label), $cbFeeLabels ?? [], true) && $item->bill_amount !== null))) -
@csrf - - -
- @else - {{ $money($item->self_amount) }} - @endif - - @endif + {{ $money($item->self_amount) }} {{ $item->bill_amount === null && $item->self_amount === null ? '' : $money((float) $item->bill_amount - (float) $item->self_amount) }} {{ ['supplement' => '补给快递', 'waybill' => '面单'][$target] ?? \App\Support\CourierBills\SummaryMapper::DIFF_COLUMNS[$target] }} @@ -86,7 +66,7 @@ - 项目名称决定归到汇总哪一列,按平时手工汇总的叫法写。附加费(一张附加费表一行,名字就是账单里的表名)只读了快递金额,自算先是 0,手工核对后在上面直接回填;回填后变成手工行,删掉就恢复原样。 + 项目名称决定归到汇总哪一列,按平时手工汇总的叫法写。类目照上月小汇总排;系统还没有数据的类目先空着(以后接上记账、违约金等数据后自动带入,和配件补发扣款一样)。要手工改某一类目,在这里加一行同名项目,手工行优先,删掉就恢复系统的数。 @endif diff --git a/tests/Feature/Business/CourierBillPagesTest.php b/tests/Feature/Business/CourierBillPagesTest.php index 9e0adff8..743c653a 100644 --- a/tests/Feature/Business/CourierBillPagesTest.php +++ b/tests/Feature/Business/CourierBillPagesTest.php @@ -49,7 +49,7 @@ final class CourierBillPagesTest extends FeatureTestCase $this->get($statementUrl)->assertOk()->assertSeeText('8.0040')->assertSeeText('13.0040'); $this->post(route("business.$section.courier-bills.add-item", ['statement' => $statement->id]), ['label' => '上楼费', 'bill' => 20, 'self' => 15])->assertRedirect(); $manual = $db->table('courier_bill_summary_items')->where('statement_id', $statement->id)->where('label', '上楼费')->value('id'); - $this->get($statementUrl)->assertOk()->assertSee('回填'); + $this->get($statementUrl)->assertOk()->assertDontSee('>回填', false); $this->from($statementUrl)->post(route("business.$section.courier-bills.fill-item", ['statement' => $statement->id, 'item' => $manual]), ['self' => 15]) ->assertRedirect($statementUrl)->assertSessionHas('courier_bills_message'); // 导入手工小汇总类目:本月小汇总照它排,空行能回填快递金额和自算金额 @@ -57,7 +57,7 @@ final class CourierBillPagesTest extends FeatureTestCase ['运费10月', 1, 1, 0], ['快递记账', null, -3, 3], ['匹配不到', 1, null, 1], ['总计', 2, -2, 4]]]), '河北中通10月发送版.xlsx', null, null, true); $this->post(route("business.$section.courier-bills.import-summary-templates"), ['month' => '2026-10', 'files' => [$template]]) ->assertRedirect()->assertSessionHas('courier_bills_message', fn ($m) => str_contains($m, '记下 1 家')); - $this->get($statementUrl)->assertOk()->assertSeeText('运费10月')->assertSeeText('快递记账')->assertSee('placeholder="快递提供"', false); + $this->get($statementUrl)->assertOk()->assertSeeText('运费10月')->assertSeeText('快递记账')->assertDontSee('placeholder="快递提供"', false); $this->get(route('business.pages.show', ['section' => $section, 'page' => 'courier-bill-reconciliation', 'cb_view' => 'upload', 'month' => '2026-10'])) ->assertOk()->assertSeeText('导入手工小汇总'); $line = $db->table('courier_bill_lines')->where('waybill_no', 'ZT999')->first();