fixed #3596
This commit is contained in:
parent
679b2a2b8e
commit
ce7b39c204
2 changed files with 7 additions and 4 deletions
|
@ -230,12 +230,12 @@ export function findComponentsUpward (context, componentName) {
|
|||
}
|
||||
|
||||
// Find brothers components
|
||||
export function findBrothersComponents (context, componentName) {
|
||||
export function findBrothersComponents (context, componentName, exceptMe = true) {
|
||||
let res = context.$parent.$children.filter(item => {
|
||||
return item.$options.name === componentName;
|
||||
});
|
||||
let index = res.indexOf(context);
|
||||
res.splice(index, 1);
|
||||
if (exceptMe) res.splice(index, 1);
|
||||
return res;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue