]> git.ipfire.org Git - thirdparty/paperless-ngx.git/commitdiff
Doc detail tab switch fixes
authorshamoon <4887959+shamoon@users.noreply.github.com>
Fri, 28 Apr 2023 15:14:24 +0000 (08:14 -0700)
committershamoon <4887959+shamoon@users.noreply.github.com>
Fri, 28 Apr 2023 15:14:24 +0000 (08:14 -0700)
src-ui/src/app/components/document-detail/document-detail.component.html
src-ui/src/app/components/document-detail/document-detail.component.ts

index 71092fe723993e51de40a2c2c2307e8bfeecd090..7b21d4b500c6ec29d1e322b1d07d48b3c3149d39 100644 (file)
                     <a ngbNavLink i18n>Metadata</a>
                     <ng-template ngbNavContent>
 
-                        <table class="table table-borderless">
+                        <table class="table table-borderless" *ngIf="document">
                             <tbody>
                                 <tr>
                                     <td i18n>Date modified</td>
index 6d03ec024870389edd4e8c3ed73ce611e5ea5a6c..9b23aa047663d3909d72760171b91742727a5f44 100644 (file)
@@ -317,6 +317,10 @@ export class DocumentDetailComponent
         if (navIDKey) {
           this.activeNavID = DocumentDetailNavIDs[navIDKey]
         }
+      } else if (paramMap.get('id')) {
+        this.router.navigate(['documents', +paramMap.get('id'), 'details'], {
+          replaceUrl: true,
+        })
       }
     })
   }