feat: Add board setting to expand task lists by default

Closes #683, closes #1333
This commit is contained in:
Maksim Eltyshev
2025-09-05 23:21:08 +02:00
parent b47a337a4f
commit 984b789e2e
39 changed files with 78 additions and 3 deletions
+5 -2
View File
@@ -33,15 +33,16 @@ module.exports = {
defaultCardType: {
type: 'string',
isIn: Object.values(Card.Types),
allowNull: true,
},
limitCardTypesToDefaultOne: {
type: 'boolean',
allowNull: true,
},
alwaysDisplayCardCreator: {
type: 'boolean',
},
expandTaskListsByDefault: {
type: 'boolean',
},
isSubscribed: {
type: 'boolean',
},
@@ -79,6 +80,7 @@ module.exports = {
'defaultCardType',
'limitCardTypesToDefaultOne',
'alwaysDisplayCardCreator',
'expandTaskListsByDefault',
);
}
if (isBoardMember) {
@@ -96,6 +98,7 @@ module.exports = {
'defaultCardType',
'limitCardTypesToDefaultOne',
'alwaysDisplayCardCreator',
'expandTaskListsByDefault',
'isSubscribed',
]);
+5
View File
@@ -61,6 +61,11 @@ module.exports = {
defaultsTo: false,
columnName: 'always_display_card_creator',
},
expandTaskListsByDefault: {
type: 'boolean',
defaultsTo: false,
columnName: 'expand_task_lists_by_default',
},
// ╔═╗╔╦╗╔╗ ╔═╗╔╦╗╔═╗
// ║╣ ║║║╠╩╗║╣ ║║╚═╗
@@ -0,0 +1,21 @@
/*!
* Copyright (c) 2024 PLANKA Software GmbH
* Licensed under the Fair Use License: https://github.com/plankanban/planka/blob/master/LICENSE.md
*/
exports.up = async (knex) => {
await knex.schema.alterTable('board', (table) => {
/* Columns */
table.boolean('expand_task_lists_by_default').notNullable().defaultTo(false);
});
return knex.schema.alterTable('board', (table) => {
table.boolean('expand_task_lists_by_default').notNullable().alter();
});
};
exports.down = (knex) =>
knex.schema.table('board', (table) => {
table.dropColumn('expand_task_lists_by_default');
});