mengw15 commented on code in PR #4043:
URL: https://github.com/apache/texera/pull/4043#discussion_r2509230820


##########
frontend/src/app/dashboard/component/admin/user/admin-user.component.ts:
##########
@@ -149,6 +149,8 @@ export class AdminUserComponent implements OnInit {
   public sortByEmail: NzTableSortFn<User> = (a: User, b: User) => (b.email || 
"").localeCompare(a.email);
   public sortByComment: NzTableSortFn<User> = (a: User, b: User) => (b.comment 
|| "").localeCompare(a.comment);
   public sortByRole: NzTableSortFn<User> = (a: User, b: User) => 
b.role.localeCompare(a.role);
+  public sortByAccountCreation: NzTableSortFn<User> = (a: User, b: User) =>
+    (b.accountCreation || 0) - (a.accountCreation || 0);

Review Comment:
   In my opinion, this comparator should yield oldest → newest when ascending, 
and newest → oldest when descending. what do you think? the question here is 
should we change the order here.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to