63 Commits

Author SHA1 Message Date
as-op ed2881f594 [#74746] Avoid additional journal background jobs to be started by Jira import job
https://community.openproject.org/wp/74746
2026-05-07 14:59:44 +02:00
Dombi Attila 38488e2993 [#65866] NoMethodError in GET::API::V3::Queries::QueriesAPI#/queries/:id/
https://community.openproject.org/work_packages/65866

Set journal timestamp method to explcitly pass utc string to the query.

This will force the UTC timezone to be applied on the date instead of
letting postgresql to decide on the timezone.
2025-07-23 19:22:47 +03: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 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
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 934cc626ed Do not change send_notifications value if passing nil 2023-02-24 16:07:12 +01:00
Mir Bhatia 3fe2a6b81f Update incorrect spec and pass it 2023-02-21 13:41:35 +01:00
Mir Bhatia 29414f75d6 Correct subproject activity items 2023-02-21 12:47:21 +01:00
Mir Bhatia fe859654b3 Change failing test to pending 2023-02-21 12:47:21 +01:00
Mir Bhatia 6003f8f403 Update project journal specs to check for the required formats 2023-02-21 12:41:16 +01:00
Sebastian Fiedlschuster 56a699eab0 Merge branch 'dev' into https://github.com/opf/openproject/pull/11243 2023-02-09 13:29:31 +01:00
Christophe Bliard 5570e2cb2d Render parent field in Project activity details
Reuse NamedAssociation formatter instead of defining a new one.
2023-02-06 09:30:28 +01:00
Christophe Bliard 5d52fc0e97 Remove title attribute on i tag
HTML attribute 'title' does not help accessibility, making it useless and repetitive in this case.

See https://www.a11yproject.com/posts/title-attributes/
2023-02-06 09:30:28 +01:00
Mir Bhatia eedb2372ed Add project journal attribute for name 2023-01-26 13:53:15 +01:00
Christophe Bliard c4cb87b520 Reuse PlaintextFormatter for ProjectJournal identifier field 2023-01-26 09:01:54 +01:00
Sebastian Fiedlschuster dd8d44d0c9 Merge branch 'dev' into https://github.com/opf/openproject/pull/11243 2023-01-18 14:11:44 +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
Sebastian Fiedlschuster 3d390a8d76 at_timestamp: refactoring with rubocop 2022-11-21 14:02:40 +01:00
Sebastian Fiedlschuster 19f63301a6 at_timestamp: adding reference to pull request
for documenting background information

https://github.com/opf/openproject/pull/11243
2022-09-04 14:43:22 +02:00
Sebastian Fiedlschuster 72238709f4 implementing Journal.at_timestamp
in order to retrieve journal entries that correspond to a certain point in time.

If you have journals for Monday, Wednesday, and Friday, then `Journal.at_timestamp(Thursday)` will only include the Wednesday journal because that one is the most current on Thursday.

This is a step towards the baseline-queries feature:
- https://community.openproject.org/projects/openproject/work_packages/43483
- https://community.openproject.org/projects/openproject/work_packages/26448
2022-09-04 12:56:22 +02: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 2a015eeac3 Feature/journal aggregation on write (#9396)
* aggregate journals on write - simple implementation

* remove references to aggregated journals on read

* rewrite existing journals to be aggregated

* remove aggregated journal reference

* only delete predecessor if it can be aggregated

* fix aggregation condition

* adapt specs

* remove aggregated journal functionality from production code

The code is still necessary in a migration for the time being

* adapt specs

* use polymorphic belongs_to for journal data

The association can then be employed for eager loading

* eager load for activity rendering
2021-06-17 20:08:58 +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
ulferts 983709db89 rewrite acts as journalized to create journals in sql 2020-05-25 10:43:04 +02:00
ulferts f6d60ca6dc Merge branch 'release/10.5' into dev 2020-05-06 17:46:10 +02:00
ulferts 79409370ee ensure thread safety of journal notifications 2020-05-06 12:42:33 +02:00
ulferts a6689a9006 let first notification setting dominate child setting 2020-05-06 10:46:25 +02:00
ulferts 2ed7a69943 rely on caller to reset the journal notification setting
By forcing the caller to disable mail sending via a block, we can also
ensure that the value is reset.

But by it, we can allso allow disabling mail sending for multiple
save_hook runs which was not possible before.
2020-05-06 10:46:25 +02:00
ulferts 67ade5002d extract journal notification setting to separate class 2020-05-06 10:46:25 +02:00
ulferts 64d0f57d85 Feature/aggregated activities (#8221)
* use cte for aggregated journal

* Revert "use cte for aggregated journal"

This reverts commit 5fedefefdd.

* add another subselect that could later on be provided from the outside

* allow passing a nukleous sql to aggregated journals

* wip - using aggregated journal for activity

* new sql for aggregated journals

* start implementing new aggregated query

* additional documentation

* consolidate activity functionality

* simplify by turing into instance methods

* move activity fetcher out of redmine

* remove verb verification made obsolete

Without catchall routes, the dispatching handles it

* remove duplicate authorize check

* refactor activities controller

* refactory activity fetcher

* cache avatar file

* sort choosable events

* remove legacy spec covered by contemporary

* speed up aggregated journals via CTE

* instance var might never have been set

* ensure the event_types are always transmitted

* correctly reset the avatar cache

* fix avatar fetcher expectation regarding wiki pages

* adapt spec

[ci skip]
2020-04-27 08:04:28 +02:00
Henriette Dinger bd7f4e4814 Update copyright notice 2020-01-15 11:31:26 +01:00
ulferts d37bdb71f0 extract methods 2019-10-29 08:02:04 +01:00
Oliver Günther 4666fbb4e0 [30415] Fix missing project reference in journal
https://community.openproject.com/wp/30415
2019-06-25 07:59:19 +02:00
Henriette Dinger 46050bf7b1 Attempt to stabilise test 2019-01-31 14:39:56 +01:00
Jens Ulferts c703249bae avoid attempts to send mail on journal tests 2018-10-05 10:01:50 +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
Jens Ulferts 690e0ffc60 wp create/update/destroy via services 2017-11-29 15:27:29 +01:00
ulferts 2f9d7f408a Fix/wp table switch to milestone (#5825)
* map date name in changeset

* handle date switch in wp form

* Don't stub_const for services that may exist before hand

This will cause the const to be evaluated already, so that stub_const
has no effect there. This is why this fails depending on the order on
travis, but not locally/isolated.

[ci skip]
2017-08-06 08:43:02 +02:00
Oliver Günther 7cf11bb689 Update copyright notice 2017-01-10 15:11:43 +01:00
Jens Ulferts dd05cf297c add capability to move work package accross projects to service 2016-03-23 09:33:00 +01:00
Jan Sandbrink 3fe8b33f78 enforce disabled aggregations
due to limited time resolution we can't assume that a setting of 0 will implicitly disable aggregation
2015-08-06 16:12:15 +02:00
Jan Sandbrink f9051bba3e display diff of containing aggregated journal
... instead of displaying the diff for the requested journal only

- this should provide the best forward compatibility of links
- even when aggregation timeframes are changed intermittently
2015-08-06 09:32:16 +02:00