37 Commits

Author SHA1 Message Date
Henriette Darge d7282755ed Cache the AttributeHelpTexts type dependent 2026-03-23 13:16:33 +01:00
ulferts 608cc40e68 replace old visible methods on wp cf 2026-02-24 14:31:40 +01:00
Alexander Brandon Coles 33de48f8c7 Normalize AttributeHelpText#attribute_name
Uses `ActiveRecord::Normalization` API to normalize `attribute_name`.
2025-06-09 14:15:07 +01:00
Jan Sandbrink 0b87e7543f Freeze string literals in specs
Rolling out frozen string literals further by freezing all
string literals in core specs.
2025-05-05 09:29:55 +02: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 8fa8584538 Run rubocop --autocorrect on all files
Only the safe cops have run. rubocop version is 1.59.0.
2024-01-05 15:27:09 +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
ulferts 5b2bc41f41 Merge remote-tracking branch 'origin/dev' into easier-factory-role-setup 2023-10-12 12:09:27 +02:00
ulferts 2b2abf864a introduce ProjectRole model 2023-10-09 14:34:20 +02:00
Klaus Zanders 78c1e4fadb Switch all uses of principal factories to use new interface 2023-10-09 10:39:44 +02:00
Christophe Bliard 4c2a9d0aa8 Enable RSpec zero monkey patching mode
The plan for RSpec 4.0 is to disable monkey patching.

See https://github.com/rspec/rspec-core/blob/main/features/configuration/zero_monkey_patching_mode.feature for details.
2023-05-31 19:22:29 +02:00
Christophe Bliard aa23106c11 lint: autocorrect RSpec/FactoryBot/ConsistentParenthesesStyle
command is

    rubocop -A --only RSpec/FactoryBot/ConsistentParenthesesStyle modules spec
2023-03-07 15:04:32 +01:00
Christophe Bliard 10085736da refactor: Rename and generalize #accessor_name as #attribute_name
Also extract #attribute_getter and #attribute_setter when
using #attribute_name in the context of calling the getter/setter
methods.
2023-01-17 09:39:27 +01:00
Christophe Bliard 85b3258a29 Autocorrect with some rubocop cops
RSpec/Rails/InferredSpecType and Style/RedundantConstantBase

rubocop --autocorrect-all --only RSpec/Rails/InferredSpecType,Style/RedundantConstantBase spec modules/*/spec
2023-01-13 14:28:59 +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 bc8d423ec2 update copyright information for 2022 2022-03-01 17:05:59 +01:00
Christophe Bliard 47a297daae Fix argument alignment since f08bea3467 (#10129)
* Fix argument alignment since f08bea3467

The FactoryBot.* prefix has been removed in f08bea3467. Since then
rubocop complains about Layout/ArgumentAlignment. This commit fixes it.

* do not fix alignments for modules/*/spec yet

hoping to be under the limit of 65535 characters for reviewdog to report on rubocop errors
2022-02-02 21:48:06 +01:00
Oliver Günther f08bea3467 Remove FactoryBot.* prefix where applicable 2022-01-25 08:19:06 +01:00
ulferts 3429ecb7bf attempt to fix flickering spec 2021-11-22 11:09:52 +01:00
ulferts af5d400bb2 linting 2021-11-22 11:09:39 +01:00
Oliver Günther 7333742902 [40027] Delete attribute help text when custom field destroyed
https://community.openproject.org/work_packages/40027
2021-11-17 20:55:36 +01:00
ulferts 7040d2bc53 alter permission for custom fields in even more wp representers 2021-11-02 11:01:39 +01:00
ulferts 67f3b2533c adapt permission for wp custom field visibility check 2021-11-01 22:30:07 +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 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
Oliver Günther b1a99353e2 Extend attribute help text for projects and allow images
Attribute help text so far could only be added to work packages.
This commit adds support for projects and adds the help texts to
widget headers for status and description modals in the overview tab
as well as extending the attachable mixin to allow uploading images.

Uploaded attachments are to be expected to be visible regardless of permissions,
thus this also adds an option to make attachments visible to all
2020-07-13 13:10:14 +02:00
Henriette Dinger bd7f4e4814 Update copyright notice 2020-01-15 11:31:26 +01:00
ulferts a880c85a1d partial caching for wp schema attribute groups 2019-08-09 13:31:47 +02:00
Oliver Günther 059770f533 FactoryGirl => FactoryBot
Removes the deprecation
2018-05-07 22:38:20 +02:00
Oliver Günther 6ef4211e77 Bump copyright to 2018 (#6171)
[ci skip]
2018-02-12 08:51:12 +01:00
ulferts 4b7e3ff26d Feature/limit attribute help text visibility (#5749)
* code prettification

* avoid help text for newly added cf requiring restart

When using the class method statically, the values are determined upon reading the class. By that, a restart is required before newly added custom fields are added to the list and removed custom fields will still be listed

* limit visibility of attribute help texts

[ci skip]
2017-07-12 21:13:28 +02:00
Oliver Günther 9fabaaaf13 Show only attributes from the type attributes and status, project 2017-07-06 14:21:31 +02:00
Oliver Günther 39e11c72dc Create backend for help text CRUD 2017-07-06 14:20:57 +02:00