feat: 添加合规

This commit is contained in:
zdl
2025-10-20 21:25:33 +08:00
parent d695f8ff7b
commit 6c96299b8f
42 changed files with 7118 additions and 289 deletions

View File

@@ -1,3 +1,4 @@
import { getApiBase } from '../utils/apiConfig';
// src/services/authService.js
/**
* 认证服务层 - 处理所有认证相关的 API 调用
@@ -6,7 +7,7 @@
import { logger } from '../utils/logger';
const isProduction = process.env.NODE_ENV === 'production';
const API_BASE_URL = isProduction ? "" : process.env.REACT_APP_API_URL;
const API_BASE_URL = getApiBase();
/**
* 统一的 API 请求处理

View File

@@ -1,3 +1,4 @@
import { getApiBase } from '../utils/apiConfig';
// src/services/financialService.js
/**
* 完整的财务数据服务层
@@ -7,7 +8,7 @@
import { logger } from '../utils/logger';
const isProduction = process.env.NODE_ENV === 'production';
const API_BASE_URL = isProduction ? "" : process.env.REACT_APP_API_URL;
const API_BASE_URL = getApiBase();
const apiRequest = async (url, options = {}) => {
try {

View File

@@ -1,3 +1,4 @@
import { getApiBase } from '../utils/apiConfig';
// src/services/industryService.js
import axios from 'axios';
@@ -5,7 +6,7 @@ import axios from 'axios';
const isProduction = process.env.NODE_ENV === 'production';
const API_BASE_URL = isProduction ? "" : process.env.REACT_APP_API_URL;
const API_BASE_URL = getApiBase();
// 配置 axios 默认包含 credentials
axios.defaults.withCredentials = true;

View File

@@ -1,3 +1,4 @@
import { getApiBase } from '../utils/apiConfig';
// src/services/marketService.js
/**
* 完整的市场行情数据服务层
@@ -7,7 +8,7 @@
import { logger } from '../utils/logger';
const isProduction = process.env.NODE_ENV === 'production';
const API_BASE_URL = isProduction ? "" : process.env.REACT_APP_API_URL;
const API_BASE_URL = getApiBase();
const apiRequest = async (url, options = {}) => {
try {