update pay ui
This commit is contained in:
@@ -28,6 +28,7 @@ import {
|
||||
} from '@chakra-ui/react';
|
||||
import { StarIcon, TriangleUpIcon } from '@chakra-ui/icons';
|
||||
import { logger } from '../../../utils/logger';
|
||||
import { getApiBase } from '../../../utils/apiConfig';
|
||||
|
||||
const HighPositionStocks = ({ dateStr }) => {
|
||||
const [highPositionData, setHighPositionData] = useState(null);
|
||||
@@ -43,7 +44,7 @@ const HighPositionStocks = ({ dateStr }) => {
|
||||
const fetchHighPositionStocks = async () => {
|
||||
setLoading(true);
|
||||
try {
|
||||
const API_URL = process.env.NODE_ENV === 'production' ? '/report-api' : 'http://111.198.58.126:5001';
|
||||
const API_URL = process.env.NODE_ENV === 'production' ? `${getApiBase()}/report-api` : 'http://111.198.58.126:5001';
|
||||
const response = await fetch(`${API_URL}/api/limit-analyse/high-position-stocks?date=${dateStr}`);
|
||||
const data = await response.json();
|
||||
|
||||
|
||||
@@ -33,8 +33,10 @@ import {
|
||||
// 注意:在实际使用中,这些组件应该被拆分到独立的文件中
|
||||
// 这里为了演示,我们假设它们已经被正确导出
|
||||
|
||||
import { getApiBase } from '../../utils/apiConfig';
|
||||
|
||||
// API配置
|
||||
const API_URL = process.env.NODE_ENV === 'production' ? '/report-api' : 'http://111.198.58.126:5001';
|
||||
const API_URL = process.env.NODE_ENV === 'production' ? `${getApiBase()}/report-api` : 'http://111.198.58.126:5001';
|
||||
|
||||
// 导入的组件(实际使用时应该从独立文件导入)
|
||||
// 恢复使用本页自带的轻量日历
|
||||
|
||||
Reference in New Issue
Block a user