Skip to content

Commit e593168

Browse files
committed
fix
1 parent 0b8d7f0 commit e593168

13 files changed

Lines changed: 16 additions & 21 deletions

File tree

.kiro/specs/workwork-ledger-mvp/tasks.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -338,6 +338,6 @@
338338
- **属性 17: 稳定币收入聚合一致性**
339339
- **验证: 需求 7.3**
340340

341-
- [ ] 21. 最终检查点 - 确保所有测试通过
341+
- [] 21. 最终检查点 - 确保所有测试通过
342342
- 确保所有测试通过,如有问题请询问用户
343343

src/app/api/pay/[token]/crypto-status/route.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ import type { Chain } from '@/types/domain';
1515
* Returns the current status of a crypto payment
1616
*/
1717
export async function GET(
18-
request: NextRequest,
18+
_request: NextRequest,
1919
{ params }: { params: Promise<{ token: string }> }
2020
) {
2121
try {
@@ -51,8 +51,6 @@ export async function GET(
5151
);
5252
}
5353

54-
const { invoice } = result;
55-
5654
// Get the payment record with crypto details
5755
const payment = await prisma.payment.findFirst({
5856
where: {

src/app/dashboard/page.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ export default function DashboardPage() {
7272

7373
<StatCard
7474
title="交易笔数"
75-
value={stats?.periodAggregations?.reduce((sum, p) => sum + 1, 0).toString() || '0'}
75+
value={stats?.periodAggregations?.reduce((sum) => sum + 1, 0).toString() || '0'}
7676
subtitle="本期间"
7777
color="cyan"
7878
icon={

src/components/dashboard/income-chart.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ export function IncomeChart({ data, isLoading }: IncomeChartProps) {
6464
function formatPeriodLabel(period: string): string {
6565
// Handle month format: 2024-01
6666
if (/^\d{4}-\d{2}$/.test(period)) {
67-
const [year, month] = period.split('-');
67+
const [, month] = period.split('-');
6868
return `${month}月`;
6969
}
7070
// Handle week format: 2024-W01

src/components/payment/crypto-payment-section.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,6 @@ const ASSET_DISPLAY_NAMES: Record<StablecoinAsset, string> = {
4848
*/
4949
export function CryptoPaymentSection({
5050
token,
51-
invoiceId,
5251
amount,
5352
currency,
5453
}: CryptoPaymentSectionProps) {

src/server/blockchain/chain-service.test.ts

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
* **Validates: Requirements 7.1**
55
*/
66

7-
import { describe, it, expect, beforeEach, vi } from 'vitest';
7+
import { describe, it } from 'vitest';
88
import { fc } from '@/test/fc-config';
99
import { chainArb, stablecoinAssetArb, uuidArb } from '@/test/arbitraries';
1010
import type { Chain, StablecoinAsset } from '@/types/domain';
@@ -183,9 +183,7 @@ describe('Chain Abstraction Layer', () => {
183183
fc.property(
184184
uuidArb,
185185
uuidArb,
186-
chainArb,
187-
stablecoinAssetArb,
188-
(userId1, userId2, chain, asset) => {
186+
(userId1, userId2) => {
189187
// Skip if users are the same
190188
if (userId1 === userId2) return true;
191189

src/server/dashboard/dashboard.service.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
*/
55

66
import { prisma } from '@/lib/prisma';
7-
import type { Currency, PaymentMethod } from '@prisma/client';
7+
import type { PaymentMethod } from '@prisma/client';
88
import Decimal from 'decimal.js';
99

1010
// ============================================

src/server/dashboard/dashboard.test.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@ import {
1414
calculateTaxReserve,
1515
aggregateStablecoinIncome,
1616
type Chain,
17-
type StablecoinAsset,
1817
} from './dashboard.service';
1918
import {
2019
currencyArb,

src/server/ledger/ledger.test.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
* Tests for requirements 8.2, 8.4
44
*/
55

6-
import { describe, it, expect } from 'vitest';
6+
import { describe, it } from 'vitest';
77
import { fc } from '@/test/fc-config';
88
import Decimal from 'decimal.js';
99
import {
@@ -19,7 +19,6 @@ import {
1919
dateArb,
2020
decimalArb,
2121
} from '@/test/arbitraries';
22-
import type { Currency, PaymentMethod } from '@/types/domain';
2322

2423
// ============================================
2524
// Test Data Generators

src/server/payment/credentials.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
import { prisma } from '@/lib/prisma';
88
import type { PSPCredentials, PSPProvider } from './types';
9-
import { PaymentError, PaymentErrorCodes } from './types';
9+
import { PaymentError } from './types';
1010
import { getPaymentGateway } from './gateway-factory';
1111

1212
/**

0 commit comments

Comments
 (0)