Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[pull] dev from opf:dev #64

Merged
merged 24 commits into from
Nov 3, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
5ceaca7
Try to fix root_api
Oct 24, 2023
520bdee
First batch of API changes for authorization checks
Oct 24, 2023
9a53cbd
Use parentheses for all calls to authorize* methods
Oct 30, 2023
e9d1dea
Fix all other usages of `authorize` methods in API
Oct 30, 2023
d67c292
Get rid of `current_user_allowed_to` method in the API
Oct 30, 2023
49037c7
Replace all allowed_to? calls in the API
Oct 30, 2023
e7a91fb
Remove final usages of current_user_allowed_to method
Oct 30, 2023
68b06de
Fix tests after replacig method
Oct 30, 2023
a704445
Fix another typo
Oct 30, 2023
6dc97ac
Fix another permission check in a wrong context
Oct 30, 2023
1b8a7a8
Fix usage of `intersect?` on the Array intead of the relation
Oct 30, 2023
bf6e731
Use `Array.wrap` instead of `Array` as it does not deconstruct hashes
Oct 30, 2023
f39bd0b
Fix another typo
Oct 30, 2023
5908edd
Non Member permission checks better
Oct 30, 2023
7bd93a7
Add a temporary sleep to properly add roles to filter
Oct 31, 2023
0229513
Re-add docs for permission methods
Oct 31, 2023
fedb134
Replace `allowed_to?` calls in components
Oct 31, 2023
7395514
Bump the angular group in /frontend with 3 updates
dependabot[bot] Nov 2, 2023
fc6f39f
Merge pull request #14032 from opf/replace-allowed-to-in-api
oliverguenther Nov 2, 2023
029c059
[chore] bump backend node engine (#14034)
Kharonus Nov 2, 2023
811e835
Merge pull request #14064 from opf/replace-allowed-to-in-components
dombesz Nov 2, 2023
17480df
[50307] Timestamp overflows the BorderBox on Storages index page (#13…
bsatarnejad Nov 2, 2023
14f8721
Avoid assigning inactive time entry activity
oliverguenther Oct 27, 2023
e38cd8f
update locales from crowdin [ci skip]
openprojectci Nov 3, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions app/components/users/avatar_component.rb
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ class AvatarComponent < ApplicationComponent
include AvatarHelper
include OpPrimer::ComponentHelpers

def initialize(user:, show_name: true, link: true, size: 'default', classes: '', title: nil)
def initialize(user:, show_name: true, link: true, size: 'default', classes: '', title: nil, name_classes: '')
super

@user = user
Expand All @@ -41,6 +41,7 @@ def initialize(user:, show_name: true, link: true, size: 'default', classes: '',
@size = size
@title = title
@classes = classes
@name_classes = name_classes
end

def render?
Expand All @@ -54,7 +55,8 @@ def call
link: @link,
hide_name: !@show_name,
title: @title,
class: @classes
class: @classes,
name_classes: @name_classes
)
end
end
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ module Authorization

included do
def sharing_manageable?
User.current.allowed_to?(:share_work_packages, @work_package.project)
User.current.allowed_in_project?(:share_work_packages, @work_package.project)
end
end
end
Expand Down
1 change: 0 additions & 1 deletion app/models/users/permission_checks.rb
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,6 @@ def all_permissions_for(context)
end

# Old allowed_to? interface. Marked as deprecated, should be removed at some point ... Guessing 14.0?

def allowed_to?(action, context, global: false)
# OpenProject::Deprecation.deprecate_method(User, :allowed_to?)
user_allowed_service.call(action, context, global:)
Expand Down
22 changes: 11 additions & 11 deletions config/locales/crowdin/zh-CN.seeders.yml
Original file line number Diff line number Diff line change
Expand Up @@ -132,21 +132,21 @@ zh-CN:
welcome:
title: 欢迎使用 OpenProject!
text: |
OpenProject is the leading open source project management software. It supports classic, agile as well as hybrid project management and gives you full control over your data.
OpenProject是领先的开源项目管理软件。它支持经典、敏捷和混合型项目管理,并由您完全掌握自己的数据。

Core features and use cases:
核心功能和用例:

* [Project Portfolio Management](https://www.openproject.org/collaboration-software-features/project-portfolio-management/)
* [Project Planning and Scheduling](https://www.openproject.org/collaboration-software-features/project-planning-scheduling/)
* [Task Management and Issue Tracking](https://www.openproject.org/collaboration-software-features/task-management/)
* [Agile Boards (Scrum and Kanban)](https://www.openproject.org/collaboration-software-features/agile-project-management/)
* [Requirements Management and Release Planning](https://www.openproject.org/collaboration-software-features/product-development/)
* [Time and Cost Tracking, Budgets](https://www.openproject.org/collaboration-software-features/time-tracking/)
* [Team Collaboration and Documentation](https://www.openproject.org/collaboration-software-features/team-collaboration/)
* [项目组合管理](https://www.openproject.org/collaboration-software-features/project-portfolio-management/)
* [项目规划和调度](https://www.openproject.org/collaboration-software-features/project-planning-scheduling/)
* [任务管理和问题跟踪](https://www.openproject.org/collaboration-software-features/task-management/)
* [敏捷看板(Scrum和Kanban)](https://www.openproject.org/collaboration-software-features/agile-project-management/)
* [需求管理和发布计划](https://www.openproject.org/collaboration-software-features/product-development/)
* [时间和成本跟踪/预算](https://www.openproject.org/collaboration-software-features/time-tracking/)
* [团队协作和文档](https://www.openproject.org/collaboration-software-features/team-collaboration/)

Welcome to the future of project management.
欢迎来到项目管理的未来。

For Admins: You can change this welcome text [here]({{opSetting:base_url}}/admin/settings/general).
对于管理员:您可以[在此]({{opSetting:base_url}}/admin/settings/general)更改此欢迎文本。
projects:
demo-project:
name: 演示项目
Expand Down
2 changes: 1 addition & 1 deletion config/locales/crowdin/zh-CN.yml
Original file line number Diff line number Diff line change
Expand Up @@ -882,7 +882,7 @@ zh-CN:
attributes:
base:
user_limit_reached: "已达到用户限制。当前方案无法创建更多帐户。"
one_must_be_active: "Admin User cannot be locked/removed. At least one admin must be active."
one_must_be_active: "管理员用户无法被锁定/移除。必须至少有一个管理员处于激活状态。"
password_confirmation:
confirmation: "确认密码与密码不一致。"
format: "%{message}"
Expand Down
2 changes: 1 addition & 1 deletion docker/ci/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
ARG RUBY_VERSION
FROM ruby:${RUBY_VERSION}-bullseye

ENV NODE_VERSION="16.17.0"
ENV NODE_VERSION="20.9.0"
ENV BUNDLER_VERSION="2.4.21"
ENV DEBIAN_FRONTEND=noninteractive
ENV BUNDLE_WITHOUT="development:production:docker"
Expand Down
6 changes: 5 additions & 1 deletion docker/dev/backend/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ ARG DEV_GID=1001

ENV USER=dev
ENV RAILS_ENV=development
ENV NODE_MAJOR=20

ENV BUNDLER_VERSION "2.4.7"

Expand All @@ -27,7 +28,10 @@ RUN apt-get update -qq && \

# Setup node source and install nodejs. Needed for running certain scripts in backend container,
# as the `./scripts/api/validate_spec`.
RUN curl -fsSL https://deb.nodesource.com/setup_14.x | bash -
RUN mkdir -p /etc/apt/keyrings
RUN curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | gpg --dearmor -o /etc/apt/keyrings/nodesource.gpg
RUN echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_$NODE_MAJOR.x nodistro main" | tee /etc/apt/sources.list.d/nodesource.list
RUN apt-get update
RUN apt-get install -y nodejs

# Install watchexec for continuous test execution.
Expand Down
2 changes: 1 addition & 1 deletion docker/dev/frontend/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM node:16.15
FROM node:20.9
MAINTAINER [email protected]

ARG DEV_UID=1000
Expand Down
2 changes: 1 addition & 1 deletion docker/prod/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
ARG RUBY_VERSION="3.2.2"
ARG NODE_VERSION="16.17.0"
ARG NODE_VERSION="20.9.0"
ARG BUNDLER_VERSION="2.4.7"
ARG DEBIAN_FRONTEND=noninteractive

Expand Down
2 changes: 1 addition & 1 deletion docker/pullpreview-storybook/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM node:16.17 as build
FROM node:20.9 as build

COPY . /build
WORKDIR /build/frontend
Expand Down
10 changes: 5 additions & 5 deletions docs/development/development-environment-osx/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -104,11 +104,11 @@ $ nodenv init

You can find the latest LTS version here: [nodejs.org/en/download](https://nodejs.org/en/download/)

At the time of writing this is v16.17.0. Install and activate it with:
At the time of writing this is v20.9.0. Install and activate it with:

```shell
nodenv install 16.17.0
nodenv global 16.17.0
nodenv install 20.9.0
nodenv global 20.9.0
```

### Update NPM to the latest version
Expand All @@ -129,10 +129,10 @@ $ bundler --version
Bundler version 2.4.7

node --version
v16.17.0
v20.9.0

npm --version
8.12.1
10.1.0
```

# Install OpenProject
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ time to finish.
To check our Node installation we run `node --version`. It should output something very similar to:

```
v16.17.0
v20.9.0
```

## Installation of OpenProject
Expand Down
Loading
Loading