mirror of
https://github.com/appwrite/console.git
synced 2026-11-18 20:47:21 +00:00
fix: sort options on related columns.
This commit is contained in:
1 parent
7b09d7561e
commit
c6b437d4ae
1 file changed
+6
+6
@@ -37,6 +37,7 @@
|
||||
IconTrash
|
||||
} from '@appwrite.io/pink-icons-svelte';
|
||||
import { type Columns, databaseColumnSheetOptions } from './store';
|
||||
import { isRelationship } from './rows/store';
|
||||
|
||||
interface MenuItem {
|
||||
label?: string;
|
||||
@@ -122,6 +123,11 @@
|
||||
if (['delete', 'update', 'duplicate-header'].includes(item.action) && isSystemColumn) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// hide sort options for relationship columns
|
||||
if (isRelationship(column) && ['sort-asc', 'sort-desc'].includes(item.action ?? '')) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
|
||||
Reference in new issue
Block a user