56 Commits

Author SHA1 Message Date
Jan Sandbrink f9d8bc6614 Introduce SubclassResponsibility error
This error is intended for cases when a method is
intentionally not implemented, because the module/class defining
it expects a subclass (or class including the module) to implement
the method.

This is intended to distinguish it from other cases, such as:
* feature not implemented yet
* edge case of a method call not yet supported

Notably it avoids the misuse of the Ruby-defined NotImplementedError,
which is only intended for much more specific scenarios:

> Raised when a feature is not implemented on the current platform. For example, methods depending on the fsync or fork system calls may raise this exception [...]

Also see https://docs.ruby-lang.org/en/master/NotImplementedError.html
2026-03-27 08:14:56 +01:00
Klaus Zanders 1d7faaf650 Merge branch 'release/17.2' into merge-release/17.1-20260226081619 2026-02-26 09:16:53 +01:00
ulferts 34e577421d prevent deletion of other users˚ queries via overview 2026-02-25 13:14:24 +01:00
Henriette Darge fe7d4f950d Migrate description widget from Angular to Rails 2026-02-11 09:09:55 +01:00
Henriette Darge 88bdd95201 Make project status BETA widget the default one 2026-02-11 09:09:55 +01:00
Alexander Brandon Coles 2145865aeb [#68279] Move Widgets to Grids module
Moves components (including templates, styles, I18n strings), associated
controllers and routing under the grids module.

This change reflects the fact that widgets may be (re)used
across various different grids, e.g. Overviews/Dashboard, My Page and
Homescreen.
2025-10-13 17:32:47 +01:00
Behrokh Satarnejad 6144a00c55 replace beta news widget with news widget component (#20392)
* replace beta news widget with news widget component

* remove feature flag for beta component

* Add a migration to remove the beta_news component and remove beta component feature flag

* change migration file name
2025-09-23 12:24:53 +02:00
Henriette Darge 43b2e01fe7 Move news widget code to overviews module 2025-09-23 08:32:04 +02:00
Alexander Brandon Coles 586106dc67 Move News (BETA) widget to Grids module
Since this widget will be shared between grids implementations, moves
widget, routes, controllers and views to Grids module.

Also fixes widget permission.
2025-09-15 16:18:51 +01:00
Oliver Günther d0c18aec6d [#67291] Primerized News (BETA) widget in projects 2025-09-15 16:12:55 +01:00
Alexander Brandon Coles 7f72b3f161 Put BETA widgets behind a feature flag 2025-09-02 16:59:08 +01:00
Alexander Brandon Coles 4c55748cd8 [#66122] Initial server rendered widgets support
Provides Project Status (BETA) widget as a Reference Implementation -
this widget is currently based on the design of the Status form on the
Project Settings > General page.

In detail:

- introduces a base `WidgetController` from which widget implementations
  should inherit.
- adds `Overviews::Widgets::ProjectStatusComponent` and accompanying
  specs. Reuses existing forms.
- adds `Overviews::Widgets::StatusController`` with custom `#update`
  action, routes and accompanying permissions.
- makes the Project Status (BETA) widget available by registering in ng
  `OpenProjectGridsModule` and Rails grid modules configuration.

N.B. The Project Status (BETA) widget is EXPERIMENTAL - it will require
further visual refinement (in a follow up work package).
2025-09-02 16:59:07 +01:00
Oliver Günther 993b180708 Remove widget enterprise add-on
https://community.openproject.org/work_packages/63619
2025-04-28 10:54:33 +02:00
ulferts 594a64831e remove project_details widget 2024-10-28 11:56:15 +01:00
Ivan Kuchin 4911b8a149 remove years from copyrights (except for COPYRIGHT file) 2024-07-31 15:02:49 +02:00
ulferts 3b2121f733 Revert "Merge remote-tracking branch 'origin/release/13.4' into dev"
This reverts commit 40b2bbeb09, reversing
changes made to b4c6cb17cc.
2024-03-21 11:31:17 +01:00
Ivan Kuchin 7787e457a3 Revert "Merge branch 'dev' into release/13.4"
This reverts commit a901541269, reversing
changes made to e573ca00b7.
2024-03-20 20:19:08 +01:00
Ivan Kuchin 9e4934cd0a change quotes using rubocop --only Style/StringLiterals,Style/QuotedSymbols -a 2024-03-20 18:05:22 +01:00
Christophe Bliard 4e80ee4057 [42646] Fix untranslated "Spent time" widget name
The widget was registered with the identifier `time_entries_project`
which did not match the i18n key
`js.grid.widgets.time_entries_list.title`, so the presented title was
the `widget.options.name` value which is the translation at the widget
creation time. For instance if French was the locale when the widget is
added then the title would be in French.

Using the correct identifier `time_entries_list` fixes the issue and
translates it for all users.
2024-01-15 12:34:27 +01:00
Christophe Bliard c795874f7f Update copyright year for 2024
command used: `rg -l 'Copyright \(C\) 2012-202\d the OpenProject' | xargs -n 100 sed -i -r 's/Copyright \(C\) 2012-202. the OpenProject/Copyright (C) 2012-2024 the OpenProject/'`
2024-01-02 16:23:54 +01:00
Klaus Zanders 8a22000520 Do not filter widgets 2023-12-06 12:42:10 +01:00
Klaus Zanders 830e9c3a90 Filter Widgets in the API to only return which are allowed for the user 2023-12-06 11:00:12 +01:00
Klaus Zanders 9ecf3a1b49 More remaining permission check removals 2023-10-31 15:03:00 +01:00
Christophe Bliard 21a696ef9b Update copyright information for 2023 2022-12-30 15:51:26 +01:00
Christophe Bliard 48a4f1b6ad lint with rubocop --autocorrect (safe cops only) 2022-06-02 10:40:10 +02:00
Christophe Bliard c413ee5a21 reload grid/widgets classes cache on reloading
without it, the list of allowed widgets on a grid would be empty because the grid class being used is different from the grid class registered, because the class was reloaded
2022-05-02 07:47:53 +02:00
ulferts ee652cb6b4 Merge pull request #10254 from opf/fix/alternate-filter-registration
Refactor: register query filters without repeating query arg
2022-03-18 09:00:50 +01:00
Christophe Bliard a33524ef6d remove ruby magic comment for utf-8
ruby interprets source encoding as utf-8 since 2.0.0, making magic comment redundant and useless
2022-03-10 19:36:58 +01:00
Christophe Bliard a403a89867 refactor: use Queries::Register.register helper to avoid repetition 2022-03-07 09:16:51 +01:00
Christophe Bliard bc8d423ec2 update copyright information for 2022 2022-03-01 17:05:59 +01:00
Oliver Günther ccfa29c728 Move license and copyright docs to root, fix names and references 2021-09-02 21:50:46 +02:00
ulferts 1bdd2ab9ae safe automatic fixes by rubocop (#8994) 2021-02-11 16:02:18 +01:00
ulferts 6140f4c7e9 update copyright to 2021 (#8925)
Updates the copyright to 2021 for all files that have a copyright. Files in our source code without the copyright header still do not receive one automatically. Additionally, backlisted files are also excluded.

Previously the copyright of chiliproject which references redmine stated a copyright of redmine up to and including 2017 which is not true for the code we have in here. Because of that I changed that to 2013
2021-01-13 17:47:45 +01:00
Henriette Dinger bd7f4e4814 Update copyright notice 2020-01-15 11:31:26 +01:00
Wieland Lindenthal b533bbd70a Basic read only project status widget 2019-09-24 19:04:39 +02:00
ulferts fdbcdc45bf restrict wp_graph widget to be ee only 2019-09-16 08:32:20 +02:00
Oliver Günther 2dffd5b0f3 Remove isolate namespace 2019-09-06 12:54:24 +02:00
ulferts 08391c7807 replace my_project_page by grid implementation 2019-08-27 11:22:35 +02:00
ulferts c3c197bc24 attachments for custom_text widgets on dashboard 2019-08-14 09:27:18 +02:00
ulferts 6d8918cd09 add custom text widget to dashboard 2019-07-19 13:19:26 +02:00
ulferts 7482e4dc70 add dashboard module 2019-07-10 16:21:47 +02:00
Oliver Günther 142e2ef956 [30053] Fix writable scope check
https://community.openproject.com/wp/30053
2019-04-17 15:49:00 +02:00
Henriette Dinger b757b3f193 Merge pull request #7188 from opf/fix/29902/permissions-without-gon
[29902] Avoid using gon for boards permissions
2019-04-09 15:54:23 +02:00
Oliver Günther 24b663948d Avoid using gon for boards permissions 2019-04-09 14:12:54 +02:00
Jens Ulferts aaa7216d80 split my_page module off of grids 2019-04-09 06:51:12 +02:00
Jens Ulferts 1f01189ede wp widget only selectable with save_query permission 2019-04-09 06:51:11 +02:00
Jens Ulferts f32393e435 correctly denote allowed widgets in schema/form 2019-04-09 06:51:11 +02:00
Jens Ulferts 9b1e7618f9 extract into own files 2019-04-09 06:51:11 +02:00
Jens Ulferts 1181d1d4ec destroy query if table widget is removed 2019-04-09 06:51:11 +02:00
Jens Ulferts 323487bee0 start on work_packages_table widget 2019-04-09 06:51:10 +02:00