From 534533425b15b183cea60fa162d9884e5d3c6243 Mon Sep 17 00:00:00 2001
From: gaoluyang <2820782392@qq.com>
Date: 星期二, 13 十月 2026 17:55:50 +0800
Subject: [PATCH] Merge branch 'dev_海西州_北京同仁堂' into dev_海西州_惠牧
---
src/api/erp/finance/statistics/index.ts | 60 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
1 files changed, 60 insertions(+), 0 deletions(-)
diff --git a/src/api/erp/finance/statistics/index.ts b/src/api/erp/finance/statistics/index.ts
new file mode 100644
index 0000000..2381d7b
--- /dev/null
+++ b/src/api/erp/finance/statistics/index.ts
@@ -0,0 +1,60 @@
+import { requestClient } from '#/api/request';
+
+export namespace FinStatisticsApi {
+ /** 浼氳鏍哥畻鐪嬫澘鏌ヨ鍙傛暟 */
+ export interface StatisticsParams {
+ startMonth?: string; // 璧峰鏈堜唤 yyyy-MM锛岀暀绌洪粯璁ゆ湰骞� 1 鏈�
+ endMonth?: string; // 缁撴潫鏈堜唤 yyyy-MM锛岀暀绌洪粯璁ゅ綋鍓嶆湀
+ }
+
+ /** 浼氳鏍哥畻鐪嬫澘鎬昏 */
+ export interface StatisticsOverview {
+ startDate: string; // 瀹為檯缁熻璧峰鏃ユ湡
+ endDate: string; // 瀹為檯缁熻缁撴潫鏃ユ湡
+ receiptPrice: number; // 鏀舵閲戦锛圗RP 宸插鏍告敹娆惧崟锛�
+ paymentPrice: number; // 浠樻閲戦锛圗RP 宸插鏍镐粯娆惧崟锛�
+ netProfit: number; // 鍑�鍒╂鼎 = 鏀舵 - 浠樻
+ saleOrderPrice: number; // 閿�鍞鍗曢噾棰濓紙宸插鏍革級
+ purchaseOrderPrice: number; // 閲囪喘璁㈠崟閲戦锛堝凡瀹℃牳锛�
+
+ fixedAssetOriginalValue: number; // 鍥哄畾璧勪骇鍘熷�煎悎璁�
+ fixedAssetAccumulatedDepreciation: number; // 鍥哄畾璧勪骇绱鎶樻棫鍚堣
+ fixedAssetNetValue: number; // 鍥哄畾璧勪骇鍑�鍊煎悎璁�
+ intangibleAssetOriginalValue: number; // 鏃犲舰璧勪骇鍘熷�煎悎璁�
+ intangibleAssetAccumulatedAmortization: number; // 鏃犲舰璧勪骇绱鎽婇攢鍚堣
+ intangibleAssetNetValue: number; // 鏃犲舰璧勪骇鍑�鍊煎悎璁�
+ totalAssetNetValue: number; // 璧勪骇鍑�鍊煎悎璁�
+
+ subjectCount: number; // 浼氳绉戠洰鏁伴噺
+ voucherCount: number; // 鍑瘉鎬绘暟
+ voucherUnpostedCount: number; // 鏈繃璐﹀嚟璇佹暟閲�
+ voucherPostedCount: number; // 宸茶繃璐﹀嚟璇佹暟閲�
+ voucherCancelledCount: number; // 宸蹭綔搴熷嚟璇佹暟閲�
+ }
+
+ /** 鏈堝害瓒嬪娍 */
+ export interface StatisticsTrend {
+ month: string; // 鏈堜唤 yyyy-MM
+ receiptPrice: number; // 鏀舵閲戦
+ paymentPrice: number; // 浠樻閲戦
+ netProfit: number; // 鍑�鍒╂鼎
+ saleOrderPrice: number; // 閿�鍞鍗曢噾棰�
+ purchaseOrderPrice: number; // 閲囪喘璁㈠崟閲戦
+ }
+}
+
+/** 鑾峰彇浼氳鏍哥畻鐪嬫澘鎬昏 */
+export function getStatisticsOverview(params?: FinStatisticsApi.StatisticsParams) {
+ return requestClient.get<FinStatisticsApi.StatisticsOverview>(
+ '/finance/statistics/overview',
+ { params },
+ );
+}
+
+/** 鑾峰彇鏈堝害鏀舵敮瓒嬪娍锛堟湡闂村唴鏃犳暟鎹殑鏈堜唤琛� 0锛� */
+export function getStatisticsTrend(params?: FinStatisticsApi.StatisticsParams) {
+ return requestClient.get<FinStatisticsApi.StatisticsTrend[]>(
+ '/finance/statistics/trend',
+ { params },
+ );
+}
--
Gitblit v1.9.3