mirror of
https://gitee.com/eolink_admin/postcat.git
synced 2024-12-02 19:57:45 +08:00
fix: env modal auto open while page load
This commit is contained in:
parent
1093438402
commit
979b4c245c
@ -2,7 +2,7 @@
|
||||
<nz-sider nzTheme="light" nzWidth="250">
|
||||
<!-- <div class="side-container"> -->
|
||||
<nz-content>
|
||||
<nz-tabset nzCentered>
|
||||
<nz-tabset nzCentered [nzAnimated]="false">
|
||||
<nz-tab [nzTitle]="apiTitle">
|
||||
<ng-template #apiTitle>
|
||||
<iconpark-icon name="folder-open"></iconpark-icon>
|
||||
|
@ -59,15 +59,9 @@ export class EnvComponent implements OnInit, OnDestroy {
|
||||
return new Promise((resolve) => {
|
||||
this.storage.run('environmentLoadAllByProjectID', [projectID], async (result: StorageRes) => {
|
||||
if (result.status === StorageResStatus.success) {
|
||||
this.envList = result.data || [];
|
||||
if (!this.envList.length) {
|
||||
await this.handleAddEnv(projectID);
|
||||
resolve(true);
|
||||
return;
|
||||
}
|
||||
// await this.handleSwitchEnv(uuid ?? result.data[0].uuid);
|
||||
resolve(true);
|
||||
return resolve(result.data || []);
|
||||
}
|
||||
return resolve([]);
|
||||
});
|
||||
});
|
||||
}
|
||||
@ -162,6 +156,7 @@ export class EnvComponent implements OnInit, OnDestroy {
|
||||
|
||||
handleShowModal() {
|
||||
// this.handleAddEnv(null);
|
||||
console.log('==>>', new Error());
|
||||
this.isVisible = true;
|
||||
this.isOpen = false;
|
||||
// this.getAllEnv(this.envUuid);
|
||||
|
Loading…
Reference in New Issue
Block a user