refactor(Home): 重构市场组件中的数据获取逻辑
-移除了对 parentCode 的判断,保留了所有列表项 -优化了代码格式,调整了缩进和空格 - 保留了原有的功能逻辑,没有引入新的变化
This commit is contained in:
@@ -25,9 +25,9 @@ const getTableList = async() => {
|
|||||||
const res = await getListScene();
|
const res = await getListScene();
|
||||||
if (res.data.code === 0) {
|
if (res.data.code === 0) {
|
||||||
res.data.data.forEach((item) => {
|
res.data.data.forEach((item) => {
|
||||||
if (item.parentCode && item.parentCode === 1) {
|
// if (item.parentCode && item.parentCode === 1) {
|
||||||
marketList.value.push(item);
|
marketList.value.push(item);
|
||||||
}
|
// }
|
||||||
});
|
});
|
||||||
getMarketInfo(marketList.value[0]);
|
getMarketInfo(marketList.value[0]);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user