Fix Bug 2296: Newly Created Ns should come first in NG-UI
[osm/NG-UI.git] / src / app / instances / pdu-instances / PDUInstancesComponent.ts
index 5c25279..6a2ca34 100644 (file)
@@ -124,10 +124,13 @@ export class PDUInstancesComponent implements OnInit, OnDestroy {
     public generateTableColumn(): void {
         this.columnList = {
             identifier: { title: this.translateService.instant('IDENTIFIER'), width: '25%' },
-            name: { title: this.translateService.instant('NAME'), width: '20%', sortDirection: 'asc' },
+            name: { title: this.translateService.instant('NAME'), width: '20%' },
             type: { title: this.translateService.instant('TYPE'), width: '15%' },
             usageState: { title: this.translateService.instant('USAGESTATE'), width: '15%' },
-            CreatedAt: { title: this.translateService.instant('CREATEDAT'), width: '15%' },
+            CreatedAt: {
+                title: this.translateService.instant('CREATEDAT'), width: '15%', sortDirection: 'desc',
+                compareFunction: this.sharedService.compareFunction
+            },
             Actions: {
                 name: 'Action', width: '10%', filter: false, sort: false, type: 'custom',
                 title: this.translateService.instant('ACTIONS'),