Reverted Cards, custom fields are displayed in alphabetic order from Wekan v4.71

https://github.com/wekan/wekan/pulls/3417 because it caused board not loading.

Thanks to olivierlambert and xet7 !

Fixes #3367
This commit is contained in:
Lauri Ojansivu 2021-01-18 21:46:39 +02:00
parent fbb98e23c3
commit 413f91d0c8

View file

@ -689,11 +689,11 @@ Cards.helpers({
// match right definition to each field
if (!this.customFields) return [];
const ret = this.customFields.map(customField => {
return this.customFields.map(customField => {
const definition = definitions.find(definition => {
return definition._id === customField._id;
});
if (definition === undefined) {
if (!definition) {
return {};
}
//search for "True Value" which is for DropDowns other then the Value (which is the id)
@ -715,8 +715,6 @@ Cards.helpers({
definition,
};
});
ret.sort((a, b) => a.definition.name.localeCompare(b.definition.name));
return ret;
},
colorClass() {