供应商对账:厂家端退货汇总改为件数与金额 #401
@ -346,6 +346,9 @@ class SupplierReconciliationPageData
|
||||
$total = 0.0;
|
||||
$confirmedAmount = 0.0;
|
||||
$disputedAmount = 0.0;
|
||||
$returnQuantity = 0.0;
|
||||
$confirmedQuantity = 0.0;
|
||||
$disputedQuantity = 0.0;
|
||||
$disputedCount = 0;
|
||||
$confirmedCount = 0;
|
||||
|
||||
@ -356,14 +359,18 @@ class SupplierReconciliationPageData
|
||||
$deduction = $row['_accounting_target'] === '不记账'
|
||||
? 0.0
|
||||
: (float) $row['_supplier_amount'];
|
||||
$quantity = (float) $row['_supplier_qty'];
|
||||
$status = (string) ($row['_status'] ?? '');
|
||||
|
||||
$total += $deduction;
|
||||
$returnQuantity += $quantity;
|
||||
if ($status === SupplierReturnConfirmation::STATUS_CONFIRMED) {
|
||||
$confirmedAmount += $deduction;
|
||||
$confirmedQuantity += $quantity;
|
||||
$confirmedCount++;
|
||||
} elseif ($status === SupplierReturnConfirmation::STATUS_DISPUTED) {
|
||||
$disputedAmount += $deduction;
|
||||
$disputedQuantity += $quantity;
|
||||
$disputedCount++;
|
||||
}
|
||||
|
||||
@ -386,6 +393,11 @@ class SupplierReconciliationPageData
|
||||
'total_rows' => count($returnRows),
|
||||
'all_rows' => $allRows,
|
||||
'total_amount' => round($total, 2),
|
||||
'return_qty' => round($returnQuantity, 2),
|
||||
'confirmed_qty' => round($confirmedQuantity, 2),
|
||||
'disputed_qty' => round($disputedQuantity, 2),
|
||||
'pending_qty' => round(max($returnQuantity - $confirmedQuantity - $disputedQuantity, 0), 2),
|
||||
'pending_amount' => round(max($total - $confirmedAmount - $disputedAmount, 0), 2),
|
||||
'confirmed_count' => $confirmedCount,
|
||||
'confirmed_amount' => round($confirmedAmount, 2),
|
||||
'disputed_count' => $disputedCount,
|
||||
|
||||
@ -1,4 +1,11 @@
|
||||
<div class="supplier-reconciliation-page">
|
||||
@php
|
||||
$formatReturnQty = static function (mixed $value): string {
|
||||
$quantity = (float) $value;
|
||||
|
||||
return number_format($quantity, abs($quantity - round($quantity)) < 0.00001 ? 0 : 2);
|
||||
};
|
||||
@endphp
|
||||
<style>
|
||||
.supplier-reconciliation-page { display: grid; gap: 16px; }
|
||||
.supplier-reconciliation-page .sr-card { min-width: 0; max-width: 100%; padding: 16px; border: 1px solid var(--vip-border, #D8D2C7); border-radius: 8px; background: var(--vip-surface, #fff); display: grid; gap: 12px; }
|
||||
@ -30,14 +37,23 @@
|
||||
}
|
||||
.supplier-reconciliation-page .sr-return-banner .material-icons-outlined { color: var(--vip-content-accent-dark, #856632); font-size: 18px; }
|
||||
.supplier-reconciliation-page .sr-return-status { display: flex; flex-wrap: wrap; gap: 4px 10px; color: var(--vip-content-muted, #595959); font-size: .75rem; }
|
||||
.supplier-reconciliation-page .sr-return-summary { display: grid; grid-template-columns: repeat(5, minmax(145px, 1fr)); gap: 12px; }
|
||||
.supplier-reconciliation-page .sr-return-stat { min-width: 0; padding: 16px 18px; border: 1px solid var(--vip-border, #D8D2C7); border-radius: 10px; background: #fff; display: grid; gap: 8px; }
|
||||
.supplier-reconciliation-page .sr-return-stat.is-total { border-color: #E4DCCB; background: var(--vip-content-accent-soft, #F7F0DE); }
|
||||
.supplier-reconciliation-page .sr-return-stat > span { color: var(--vip-content-muted, #595959); font-size: .75rem; font-weight: 600; }
|
||||
.supplier-reconciliation-page .sr-return-stat strong { color: var(--vip-content-ink, #171717); font-size: 1.375rem; font-weight: 700; line-height: 1.2; font-variant-numeric: tabular-nums; white-space: nowrap; }
|
||||
.supplier-reconciliation-page .sr-return-stat strong small { margin-left: 3px; color: var(--vip-content-muted, #595959); font-size: .75rem; font-weight: 500; }
|
||||
.supplier-reconciliation-page .sr-return-stat em { color: var(--vip-content-muted, #595959); font-size: .8125rem; font-style: normal; font-variant-numeric: tabular-nums; }
|
||||
.supplier-reconciliation-page .sr-return-table { min-width: 1420px; }
|
||||
.supplier-reconciliation-page .sr-filter { display: grid; grid-template-columns: minmax(220px, 1.6fr) repeat(2, minmax(135px, .8fr)) minmax(150px, 1fr) minmax(125px, .75fr); gap: 10px 12px; align-items: end; padding: 12px; border: 1px solid #EFEAE0; border-radius: 8px; background: #FCFAF5; }
|
||||
.supplier-reconciliation-page .sr-filter-actions { display: flex; flex-wrap: wrap; gap: 8px; grid-column: 1 / -1; }
|
||||
@media (max-width: 960px) {
|
||||
.supplier-reconciliation-page .sr-filter { grid-template-columns: repeat(2, minmax(0, 1fr)); }
|
||||
.supplier-reconciliation-page .sr-return-summary { grid-template-columns: repeat(3, minmax(0, 1fr)); }
|
||||
}
|
||||
@media (max-width: 560px) {
|
||||
.supplier-reconciliation-page .sr-filter { grid-template-columns: minmax(0, 1fr); }
|
||||
.supplier-reconciliation-page .sr-return-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
|
||||
}
|
||||
.supplier-reconciliation-page .sr-type-tag {
|
||||
display: inline-flex; align-items: center; height: 22px; padding: 0 8px;
|
||||
@ -194,27 +210,51 @@
|
||||
</div>
|
||||
|
||||
<div class="sr-card sr-return-panel">
|
||||
<div class="sr-return-summary" aria-label="退货汇总">
|
||||
<div class="sr-return-stat is-total">
|
||||
<span>退货件数</span>
|
||||
<strong>{{ $formatReturnQty($returnPanel['return_qty']) }}<small>件</small></strong>
|
||||
</div>
|
||||
<div class="sr-return-stat is-total">
|
||||
<span>退货金额</span>
|
||||
<strong>¥{{ number_format($returnPanel['total_amount'], 2) }}</strong>
|
||||
</div>
|
||||
<div class="sr-return-stat">
|
||||
<span>已确认</span>
|
||||
<strong>{{ $formatReturnQty($returnPanel['confirmed_qty']) }}<small>件</small></strong>
|
||||
<em>¥{{ number_format($returnPanel['confirmed_amount'], 2) }}</em>
|
||||
</div>
|
||||
<div class="sr-return-stat">
|
||||
<span>异议中</span>
|
||||
<strong>{{ $formatReturnQty($returnPanel['disputed_qty']) }}<small>件</small></strong>
|
||||
<em>¥{{ number_format($returnPanel['disputed_amount'], 2) }}</em>
|
||||
</div>
|
||||
<div class="sr-return-stat">
|
||||
<span>待确认</span>
|
||||
<strong>{{ $formatReturnQty($returnPanel['pending_qty']) }}<small>件</small></strong>
|
||||
<em>¥{{ number_format($returnPanel['pending_amount'], 2) }}</em>
|
||||
</div>
|
||||
@if ($returnPanel['accounting_summary']['logistics_rows'] > 0)
|
||||
<div class="sr-return-stat">
|
||||
<span>转物流记账</span>
|
||||
<strong>{{ $formatReturnQty($returnPanel['accounting_summary']['logistics_qty']) }}<small>件</small></strong>
|
||||
<em>¥{{ number_format($returnPanel['accounting_summary']['logistics_amount'], 2) }}</em>
|
||||
</div>
|
||||
@endif
|
||||
</div>
|
||||
<div class="sr-return-banner" role="note">
|
||||
<span class="material-icons-outlined" aria-hidden="true">info</span>
|
||||
<span>
|
||||
<strong>① 退货扣减确认</strong>
|
||||
@if ($returnPanel['is_filtered'])
|
||||
(筛选出 {{ number_format($returnPanel['total_rows']) }} 行,全部 {{ number_format($returnPanel['all_rows']) }} 行,筛选结果合计扣减 ¥{{ number_format($returnPanel['total_amount'], 2) }})。
|
||||
(当前筛选 {{ $formatReturnQty($returnPanel['return_qty']) }} 件,退货金额 ¥{{ number_format($returnPanel['total_amount'], 2) }})。
|
||||
如当前筛选结果核对无误,可点「全部确认当前筛选」;其他退货行不受影响。
|
||||
@else
|
||||
(共 {{ number_format($returnPanel['total_rows']) }} 行,合计扣减 ¥{{ number_format($returnPanel['total_amount'], 2) }})。
|
||||
(共 {{ $formatReturnQty($returnPanel['return_qty']) }} 件,退货金额 ¥{{ number_format($returnPanel['total_amount'], 2) }})。
|
||||
核对无误请点「全部确认无异议」;个别有问题的行,在该行单独点「异议」,复核通过前该行暂不扣减。
|
||||
@endif
|
||||
</span>
|
||||
</div>
|
||||
<div class="sr-return-status">
|
||||
<span>已确认 {{ $returnPanel['confirmed_count'] }} 行(¥{{ number_format($returnPanel['confirmed_amount'], 2) }})</span>
|
||||
<span>· 异议 {{ $returnPanel['disputed_count'] }} 行(暂不扣减 ¥{{ number_format($returnPanel['disputed_amount'], 2) }})</span>
|
||||
<span>· 待确认 {{ max($returnPanel['total_rows'] - $returnPanel['confirmed_count'] - $returnPanel['disputed_count'], 0) }} 行</span>
|
||||
@if ($returnPanel['accounting_summary']['logistics_rows'] > 0)
|
||||
<span>· 转物流记账 {{ $returnPanel['accounting_summary']['logistics_rows'] }} 行,{{ number_format($returnPanel['accounting_summary']['logistics_qty'], 2) }} 件(¥{{ number_format($returnPanel['accounting_summary']['logistics_amount'], 2) }})</span>
|
||||
@endif
|
||||
</div>
|
||||
<form method="GET"
|
||||
action="{{ route('business.pages.show', ['section' => $section['slug'], 'page' => $page['slug']]) }}"
|
||||
class="sr-filter"
|
||||
@ -254,7 +294,7 @@
|
||||
href="{{ route('business.pages.show', ['section' => $section['slug'], 'page' => $page['slug'], 'supplier' => $selectedSupplier]) }}">重置</a>
|
||||
<a class="sr-button"
|
||||
href="{{ route('business.supplier-reconciliation.returns.export', array_merge(['supplier' => $selectedSupplier], $returnPanel['filter_query'])) }}">
|
||||
导出当前筛选结果({{ number_format($returnPanel['total_rows']) }} 行)
|
||||
导出当前筛选结果
|
||||
</a>
|
||||
</div>
|
||||
</form>
|
||||
@ -326,9 +366,9 @@
|
||||
<p class="sr-hint">
|
||||
厂家端只展示核对退货所需的字段,左右滑动查看全部。
|
||||
@if ($returnPanel['is_filtered'])
|
||||
当前筛选出 {{ number_format($returnPanel['total_rows']) }} 行(全部 {{ number_format($returnPanel['all_rows']) }} 行),导出包含当前查询条件下的全部数据。
|
||||
当前筛选结果:{{ $formatReturnQty($returnPanel['return_qty']) }} 件,退货金额 ¥{{ number_format($returnPanel['total_amount'], 2) }},导出包含当前查询条件下的全部数据。
|
||||
@else
|
||||
退货共 {{ number_format($returnPanel['total_rows']) }} 行,导出包含该厂家的全部退货数据。
|
||||
退货共 {{ $formatReturnQty($returnPanel['return_qty']) }} 件,退货金额 ¥{{ number_format($returnPanel['total_amount'], 2) }},导出包含该厂家的全部退货数据。
|
||||
@endif
|
||||
按导入顺序展示,每页 {{ $returnPanel['per_page'] }} 行(第 {{ $returnPanel['page'] }} / {{ $returnPanel['pages'] }} 页)。
|
||||
</p>
|
||||
|
||||
@ -3,6 +3,13 @@
|
||||
|
||||
<x-slot name="content">
|
||||
<div class="supplier-portal-page">
|
||||
@php
|
||||
$formatReturnQty = static function (mixed $value): string {
|
||||
$quantity = (float) $value;
|
||||
|
||||
return number_format($quantity, abs($quantity - round($quantity)) < 0.00001 ? 0 : 2);
|
||||
};
|
||||
@endphp
|
||||
<style>
|
||||
.supplier-portal-page { display: grid; gap: 16px; color: var(--vip-content-ink, #171717); }
|
||||
.supplier-portal-page .sp-card { min-width: 0; max-width: 100%; padding: 16px; border: 1px solid var(--vip-border, #D8D2C7); border-radius: 12px; background: #fff; display: grid; gap: 12px; }
|
||||
@ -28,6 +35,13 @@
|
||||
.supplier-portal-page .sp-alert.is-error { border-color: #E8C4C0; background: #FBEBE9; color: #A6392F; }
|
||||
.supplier-portal-page .sp-upload { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
|
||||
.supplier-portal-page .sp-summary { display: flex; flex-wrap: wrap; gap: 6px 16px; color: var(--vip-content-muted, #595959); font-size: .75rem; }
|
||||
.supplier-portal-page .sp-return-summary { display: grid; grid-template-columns: repeat(5, minmax(145px, 1fr)); gap: 12px; }
|
||||
.supplier-portal-page .sp-return-stat { min-width: 0; padding: 16px 18px; border: 1px solid var(--vip-border, #D8D2C7); border-radius: 10px; background: #fff; display: grid; gap: 8px; }
|
||||
.supplier-portal-page .sp-return-stat.is-total { border-color: #E4DCCB; background: var(--vip-content-accent-soft, #F7F0DE); }
|
||||
.supplier-portal-page .sp-return-stat > span { color: var(--vip-content-muted, #595959); font-size: .75rem; font-weight: 600; }
|
||||
.supplier-portal-page .sp-return-stat strong { color: var(--vip-content-ink, #171717); font-size: 1.375rem; font-weight: 700; line-height: 1.2; font-variant-numeric: tabular-nums; white-space: nowrap; }
|
||||
.supplier-portal-page .sp-return-stat strong small { margin-left: 3px; color: var(--vip-content-muted, #595959); font-size: .75rem; font-weight: 500; }
|
||||
.supplier-portal-page .sp-return-stat em { color: var(--vip-content-muted, #595959); font-size: .8125rem; font-style: normal; font-variant-numeric: tabular-nums; }
|
||||
.supplier-portal-page .sp-return-table { min-width: 1420px; }
|
||||
.supplier-portal-page .sp-filter { display: grid; grid-template-columns: minmax(220px, 1.6fr) repeat(2, minmax(135px, .8fr)) minmax(150px, 1fr) minmax(125px, .75fr); gap: 10px 12px; align-items: end; padding: 12px; border: 1px solid #EFEAE0; border-radius: 8px; background: #FCFAF5; }
|
||||
.supplier-portal-page .sp-filter-actions { display: flex; flex-wrap: wrap; gap: 8px; grid-column: 1 / -1; }
|
||||
@ -42,9 +56,11 @@
|
||||
.supplier-portal-page .sp-actions { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 6px; }
|
||||
@media (max-width: 960px) {
|
||||
.supplier-portal-page .sp-filter { grid-template-columns: repeat(2, minmax(0, 1fr)); }
|
||||
.supplier-portal-page .sp-return-summary { grid-template-columns: repeat(3, minmax(0, 1fr)); }
|
||||
}
|
||||
@media (max-width: 560px) {
|
||||
.supplier-portal-page .sp-filter { grid-template-columns: minmax(0, 1fr); }
|
||||
.supplier-portal-page .sp-return-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
|
||||
}
|
||||
</style>
|
||||
|
||||
@ -80,7 +96,8 @@
|
||||
@else
|
||||
<span>当前还没有上传过对账单。</span>
|
||||
@endif
|
||||
<span>退货明细:共 {{ number_format($returnPanel['total_rows']) }} 行</span>
|
||||
<span>退货件数:{{ $formatReturnQty($returnPanel['return_qty']) }} 件</span>
|
||||
<span>退货金额:¥{{ number_format($returnPanel['total_amount'], 2) }}</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@ -89,17 +106,39 @@
|
||||
<p class="sp-hint">
|
||||
这里展示本厂家的全部退货数据(包含待确认、已确认和异议中),按导入顺序排列。
|
||||
@if ($returnPanel['is_filtered'])
|
||||
当前筛选出 {{ number_format($returnPanel['total_rows']) }} 行。
|
||||
当前筛选结果:{{ $formatReturnQty($returnPanel['return_qty']) }} 件,退货金额 ¥{{ number_format($returnPanel['total_amount'], 2) }}。
|
||||
@endif
|
||||
</p>
|
||||
<div class="sp-summary">
|
||||
<span>退货合计 {{ number_format($returnPanel['total_rows']) }} 行</span>
|
||||
<span>扣减合计 ¥{{ number_format($returnPanel['total_amount'], 2) }}</span>
|
||||
<span>已确认 {{ $returnPanel['confirmed_count'] }} 行(¥{{ number_format($returnPanel['confirmed_amount'], 2) }})</span>
|
||||
<span>异议 {{ $returnPanel['disputed_count'] }} 行(暂不扣减 ¥{{ number_format($returnPanel['disputed_amount'], 2) }})</span>
|
||||
<span>待确认 {{ max($returnPanel['total_rows'] - $returnPanel['confirmed_count'] - $returnPanel['disputed_count'], 0) }} 行</span>
|
||||
<div class="sp-return-summary" aria-label="退货汇总">
|
||||
<div class="sp-return-stat is-total">
|
||||
<span>退货件数</span>
|
||||
<strong>{{ $formatReturnQty($returnPanel['return_qty']) }}<small>件</small></strong>
|
||||
</div>
|
||||
<div class="sp-return-stat is-total">
|
||||
<span>退货金额</span>
|
||||
<strong>¥{{ number_format($returnPanel['total_amount'], 2) }}</strong>
|
||||
</div>
|
||||
<div class="sp-return-stat">
|
||||
<span>已确认</span>
|
||||
<strong>{{ $formatReturnQty($returnPanel['confirmed_qty']) }}<small>件</small></strong>
|
||||
<em>¥{{ number_format($returnPanel['confirmed_amount'], 2) }}</em>
|
||||
</div>
|
||||
<div class="sp-return-stat">
|
||||
<span>异议中</span>
|
||||
<strong>{{ $formatReturnQty($returnPanel['disputed_qty']) }}<small>件</small></strong>
|
||||
<em>¥{{ number_format($returnPanel['disputed_amount'], 2) }}</em>
|
||||
</div>
|
||||
<div class="sp-return-stat">
|
||||
<span>待确认</span>
|
||||
<strong>{{ $formatReturnQty($returnPanel['pending_qty']) }}<small>件</small></strong>
|
||||
<em>¥{{ number_format($returnPanel['pending_amount'], 2) }}</em>
|
||||
</div>
|
||||
@if ($returnPanel['accounting_summary']['logistics_rows'] > 0)
|
||||
<span>转物流记账 {{ $returnPanel['accounting_summary']['logistics_rows'] }} 行,{{ number_format($returnPanel['accounting_summary']['logistics_qty'], 2) }} 件(¥{{ number_format($returnPanel['accounting_summary']['logistics_amount'], 2) }})</span>
|
||||
<div class="sp-return-stat">
|
||||
<span>转物流记账</span>
|
||||
<strong>{{ $formatReturnQty($returnPanel['accounting_summary']['logistics_qty']) }}<small>件</small></strong>
|
||||
<em>¥{{ number_format($returnPanel['accounting_summary']['logistics_amount'], 2) }}</em>
|
||||
</div>
|
||||
@endif
|
||||
</div>
|
||||
|
||||
@ -140,7 +179,7 @@
|
||||
<a class="sp-button" href="{{ route('portal.supplier-reconciliation.index') }}">重置</a>
|
||||
<a class="sp-button"
|
||||
href="{{ route('portal.supplier-reconciliation.returns.export', $returnPanel['filter_query']) }}">
|
||||
导出当前筛选结果({{ number_format($returnPanel['total_rows']) }} 行)
|
||||
导出当前筛选结果
|
||||
</a>
|
||||
</div>
|
||||
</form>
|
||||
|
||||
@ -132,7 +132,7 @@ class SupplierReconciliationTest extends FeatureTestCase
|
||||
->assertSeeText('厂家对账单 · 上传与实时数据')
|
||||
->assertSeeText('上传记录')
|
||||
->assertSeeText('退货扣减确认')
|
||||
->assertSeeText('合计扣减')
|
||||
->assertSeeText('退货金额')
|
||||
->assertSeeText('全部确认无异议')
|
||||
->assertSeeText('待确认')
|
||||
->assertSeeText('条形码')
|
||||
@ -525,11 +525,11 @@ class SupplierReconciliationTest extends FeatureTestCase
|
||||
|
||||
$this->loginAs()->get(route('business.pages.show', $filters))
|
||||
->assertOk()
|
||||
->assertSeeText('筛选出 19 行,全部 21 行')
|
||||
->assertSeeText('当前筛选 19 件,退货金额 ¥1,900.00')
|
||||
->assertSeeText('MATCH-01')
|
||||
->assertDontSeeText('MATCH-20')
|
||||
->assertDontSeeText('OTHER-01')
|
||||
->assertSeeText('导出当前筛选结果(19 行)');
|
||||
->assertSeeText('导出当前筛选结果');
|
||||
|
||||
$this->loginAs()->get(route('business.pages.show', $filters + ['return_page' => 2]))
|
||||
->assertOk()
|
||||
@ -539,6 +539,66 @@ class SupplierReconciliationTest extends FeatureTestCase
|
||||
->assertSee('return_status=pending', false);
|
||||
}
|
||||
|
||||
public function test_return_summary_uses_quantity_and_amount_without_row_counts(): void
|
||||
{
|
||||
$store = app(SupplierPayableOverrideStore::class);
|
||||
$companyId = (int) $this->company->id;
|
||||
$rows = [
|
||||
'summary:1' => ['qty' => '2', 'amount' => '200'],
|
||||
'summary:2' => ['qty' => '3', 'amount' => '300'],
|
||||
'summary:3' => ['qty' => '1', 'amount' => '50'],
|
||||
'summary:4' => ['qty' => '4', 'amount' => '400'],
|
||||
];
|
||||
foreach ($rows as $key => $values) {
|
||||
$store->save('final:supplier:return-reconciliation', $key, $values + [
|
||||
'summary_month' => '2026-09',
|
||||
'send_time' => '2026-09-20',
|
||||
'supplier' => '晨丰',
|
||||
'barcode' => strtoupper($key),
|
||||
'unit_price' => '100',
|
||||
], $companyId, null);
|
||||
}
|
||||
|
||||
$confirmations = app(\Modules\EcommerceFinance\Services\SupplierReturnConfirmation::class);
|
||||
$confirmations->mark('晨丰', 'summary:1', 'confirmed', $companyId, null);
|
||||
$confirmations->mark('晨丰', 'summary:3', 'disputed', $companyId, null);
|
||||
|
||||
$vendor = $this->createVendorPortalUser('晨丰');
|
||||
$portal = $this->loginAs($vendor)->get(route('portal.supplier-reconciliation.index', [
|
||||
'company_id' => $companyId,
|
||||
]));
|
||||
$portal->assertOk()
|
||||
->assertSeeText('退货件数')
|
||||
->assertSeeText('退货金额')
|
||||
->assertSee('10<small>件</small>', false)
|
||||
->assertSeeText('¥950.00')
|
||||
->assertSee('2<small>件</small>', false)
|
||||
->assertSeeText('¥200.00')
|
||||
->assertSee('1<small>件</small>', false)
|
||||
->assertSeeText('¥50.00')
|
||||
->assertSee('7<small>件</small>', false)
|
||||
->assertSeeText('¥700.00')
|
||||
->assertDontSeeText('退货合计')
|
||||
->assertDontSeeText('扣减合计')
|
||||
->assertDontSeeText('已确认 2 行')
|
||||
->assertDontSeeText('异议 1 行')
|
||||
->assertDontSeeText('待确认 3 行');
|
||||
|
||||
$this->loginAs()->get(route('business.pages.show', [
|
||||
'company_id' => $companyId,
|
||||
'section' => 'supplier-reconciliation',
|
||||
'page' => 'supplier-data',
|
||||
'supplier' => '晨丰',
|
||||
]))
|
||||
->assertOk()
|
||||
->assertSeeText('退货件数')
|
||||
->assertSeeText('退货金额')
|
||||
->assertSee('10<small>件</small>', false)
|
||||
->assertSeeText('¥950.00')
|
||||
->assertDontSeeText('退货合计')
|
||||
->assertDontSeeText('扣减合计');
|
||||
}
|
||||
|
||||
public function test_confirm_all_only_applies_to_the_current_return_filter(): void
|
||||
{
|
||||
$store = app(SupplierPayableOverrideStore::class);
|
||||
@ -655,7 +715,7 @@ class SupplierReconciliationTest extends FeatureTestCase
|
||||
'supplier' => '晨丰',
|
||||
]))->assertOk();
|
||||
|
||||
$page()->assertSeeText('合计扣减 ¥2,653.00');
|
||||
$page()->assertSeeText('退货金额')->assertSeeText('¥2,653.00');
|
||||
|
||||
$this->loginAs()
|
||||
->post(route('business.supplier-reconciliation.return.confirm'), ['supplier' => '晨丰', 'key' => 'return:1'])
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user