getTotal设置了宽窄屏的默认取值

This commit is contained in:
Xu Chang 2023-12-07 19:15:04 +08:00
parent f74766d17d
commit 1a466551d0
3 changed files with 21 additions and 0 deletions

View File

@ -66,6 +66,13 @@ export function onPathSet(option) {
}
}
}
else {
// 不设置的默认情况宽屏取100窄屏不取
const { width } = this.props;
if (width !== 'xs') {
getTotal2 = 100;
}
}
features.runningTree.createNode({
path: oakPath2,
entity: entity2,

View File

@ -69,6 +69,13 @@ function onPathSet(option) {
}
}
}
else {
// 不设置的默认情况宽屏取100窄屏不取
const { width } = this.props;
if (width !== 'xs') {
getTotal2 = 100;
}
}
features.runningTree.createNode({
path: oakPath2,
entity: entity2,

View File

@ -109,6 +109,13 @@ export function onPathSet<
}
}
}
else {
// 不设置的默认情况宽屏取100窄屏不取
const { width } = this.props;
if (width !== 'xs') {
getTotal2 = 100;
}
}
features.runningTree.createNode({
path: oakPath2,
entity: entity2,