MetaModels / core

MetaModels Core Module
GNU Lesser General Public License v3.0
96 stars 42 forks source link

Add ordering of sort options for backend list view #1430

Closed cliffparnitzky closed 3 years ago

cliffparnitzky commented 3 years ago

Currently the sort options of a backend list view are ordered by ID (I suppose). The easiest and most Contao like improvement will be sorting alphabetically. But I think in some cases a custom manual order will be nice.

zonky2 commented 3 years ago

@cliffparnitzky you mean the same like this? https://github.com/MetaModels/core/issues/74#issuecomment-14895886

cliffparnitzky commented 3 years ago

Sorry. I corrected the titel an description.

Meant was the backend view image

zonky2 commented 3 years ago

may be this is a part of DCG ... @baumannsven ?

cliffparnitzky commented 3 years ago

may be this is a part of DCG ... @baumannsven ?

Generally yes ... but if we want a manual ordering, we need it the MM view, where the sortings a displayed. Maybe we need a separate field in the rendering mask, to define the sorting.

zonky2 commented 3 years ago

O.K. - I skipped that it's about sorting - you could make the items of the sorting sortable and use this order for the dropdown

cliffparnitzky commented 3 years ago

... you could make the items of the sorting sortable and use this order for the dropdown

Yes, that's the feature request 😀

zonky2 commented 3 years ago

dca_metamodels_sortgroup.php

    'list'                  => [
        'sorting'           => [
            'mode'         => 4,
-           'fields'       => ['name'], 
+           'fields'       => ['sorting'],
            'panelLayout'  => 'limit',
            'headerFields' => ['name'],
-            //'flag'         => 1,
        ],

thats all - you can add a PR or I implemented this in MM 2.2

zonky2 commented 3 years ago

fixed