Files
wekan/client/lib/instanceFeatures.js
T
Lauri Ojansivu 18d57b2b8f Let administrators choose which optional features WeKan offers.
Admin Panel / Settings / Visibility has a new Features group. Each
optional group of board views (Table, Calendar, Time, Overview, Gantt,
Scrum, Flow charts, Map) can be turned off for the whole instance. A
disabled feature is removed from the Board View menu and from Board
Settings / Board View rather than greyed out, and a user who had it open
is moved to the board's default view. Its data and every permission stay
as they are.

Administrators can preview disabled features, and named pilot users see
them too. An opt-in policy keeps features added by later WeKan updates
disabled until an administrator enables them; the features present when
it is turned on stay as they were. Swimlanes and Lists are core and
cannot be disabled. The English texts are pending Transifex.

Thanks to nalilord and xet7 !

Fixes #6736.
2026-10-02 15:26:22 +03:00

11 lines
582 B
JavaScript

// #6736: the instance's feature decisions (Admin Panel / Settings / Visibility /
// Features) for the signed-in user, reactively. The decisions themselves are
// models/lib/instanceFeatures.js; this only supplies what the client knows -
// the published Settings document and the user's own preview flag.
import { ReactiveCache } from '/imports/reactiveCache';
const { isBoardViewAvailable } = require('/models/lib/instanceFeatures');
export function allowBoardView(view) {
return isBoardViewAvailable(ReactiveCache.getCurrentSetting(), ReactiveCache.getCurrentUser(), view);
}