--story=135438311 服务、配置、分组、脚本&模板等项目&环境改造#617
Conversation
There was a problem hiding this comment.
💡 Codex Review
When importing non-template config files while viewing a non-default environment, this branch still calls importNonTemplateConfigFile with only biz/app IDs, which posts to the legacy /biz/{biz}/apps/{app}/config_item/import/... route. The server's legacy route resolves the default project/env, while the rest of this dialog now operates on the selected project/env, so the conflict preview can classify files against the wrong environment and the subsequent add can fail or create the wrong set of items. Pass the current projectId and envId through this branch and update the API helper to use the v2 import URL.
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| const appId = ref(Number(route.params.appId)); | ||
| const appDataLoading = ref(true); | ||
| const env = ref<IEnvItem>(); | ||
| const envId = computed(() => String(route.params.envId)); |
There was a problem hiding this comment.
When a service detail URL does not include the new optional envId segment, String(route.params.envId) becomes the literal 'undefined', which is truthy. That makes the immediate watcher call getAppDetail(..., envId='undefined', ...), and the env selector also refuses to fall back to the first environment because its model value is non-empty. This affects old/bookmarked service URLs and any internal link that still only passes spaceId/appId/versionId, so those pages request /envs/undefined instead of selecting a real environment.
Useful? React with 👍 / 👎.
5fd9719 to
1c194b0
Compare
# Reviewed, transaction id: 83218
No description provided.