Browse Source
Merge pull request #20234 from abpframework/auto-merge/prerel-8-3/2807
Merge branch dev with prerel-8.3
pull/20261/head
maliming
2 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with
2 additions and
10 deletions
-
npm/ng-packs/packages/schematics/src/utils/model.ts
|
|
|
@ -91,16 +91,8 @@ export function createImportRefsToModelReducer(params: ModelGeneratorParams) { |
|
|
|
|
|
|
|
if (propType.isEnum) { |
|
|
|
toBeImported.push({ type: ref, isEnum: true }); |
|
|
|
} |
|
|
|
|
|
|
|
if (parseNamespace(solution, ref) !== model.namespace) { |
|
|
|
const isEnumImportAvailable = toBeImported.some(importValue => { |
|
|
|
return importValue.isEnum && importValue.type === ref; |
|
|
|
}); |
|
|
|
|
|
|
|
if (!isEnumImportAvailable) { |
|
|
|
toBeImported.push({ type: ref, isEnum: false }); |
|
|
|
} |
|
|
|
} else if (parseNamespace(solution, ref) !== model.namespace) { |
|
|
|
toBeImported.push({ type: ref, isEnum: false }); |
|
|
|
} |
|
|
|
}); |
|
|
|
}); |
|
|
|
|