态势感知平台-武汉市开源生态建设接口字段修改
This commit is contained in:
@@ -58,9 +58,10 @@ const fetchStats = async () => {
|
||||
try {
|
||||
loading.value = true;
|
||||
const response = await hmStatsBarPage3();
|
||||
const businessData = response.data;
|
||||
|
||||
if (response.code === 200 && response.data) {
|
||||
const { developer, certificationDeveloper, wuhanCertificationDeveloper, project, company } = response.data;
|
||||
if (businessData.code === 200 && businessData) {
|
||||
const { developer, certificationDeveloper, wuhanCertificationDeveloper, project, company } = businessData.data;
|
||||
|
||||
// 格式化数据显示
|
||||
hmDevelopers.value = `${formatNumber(developer)}+`;
|
||||
@@ -69,7 +70,7 @@ const fetchStats = async () => {
|
||||
hmProjects.value = `${formatNumber(project)}`;
|
||||
hmCompanies.value = `${formatNumber(company)}+`;
|
||||
} else {
|
||||
console.error('获取鸿蒙统计数据失败:', response.msg || '未知错误');
|
||||
console.error('获取鸿蒙统计数据失败:', businessData.msg || '未知错误');
|
||||
// 设置默认值
|
||||
hmDevelopers.value = '1000万+';
|
||||
hmCertificationDevelopers.value = '60万+';
|
||||
|
||||
Reference in New Issue
Block a user