-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
FIX / Improve project creation via template with read-only preview of project tabs #22293
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
base: 11.0/bugfixes
Are you sure you want to change the base?
FIX / Improve project creation via template with read-only preview of project tabs #22293
Conversation
trasher
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, please fix Psalm issues
| if ($withtemplate == 2 && $item instanceof Project) { | ||
| echo '<div class="alert alert-info mb-3">'; | ||
| echo '<i class="ti ti-info-circle me-2"></i>'; | ||
| echo __('You are viewing contracts from the template. Save the project first to be able to add or modify contracts.'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| echo __('You are viewing contracts from the template. Save the project first to be able to add or modify contracts.'); | |
| echo __s('You are viewing contracts from the template. Save the project first to be able to add or modify contracts.'); |
| if ($withtemplate == 2 && $item instanceof Project) { | ||
| echo '<div class="alert alert-info mb-3">'; | ||
| echo '<i class="ti ti-info-circle me-2"></i>'; | ||
| echo __('You are viewing documents from the template. Save the project first to be able to add or modify documents.'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| echo __('You are viewing documents from the template. Save the project first to be able to add or modify documents.'); | |
| echo __s('You are viewing documents from the template. Save the project first to be able to add or modify documents.'); |
| if ($withtemplate == 2 && $item instanceof Project) { | ||
| echo '<div class="alert alert-info mb-3">'; | ||
| echo '<i class="ti ti-info-circle me-2"></i>'; | ||
| echo __('You are viewing items from the template. Save the project first to be able to add or modify linked items.'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| echo __('You are viewing items from the template. Save the project first to be able to add or modify linked items.'); | |
| echo __s('You are viewing items from the template. Save the project first to be able to add or modify linked items.'); |
| if ($withtemplate == 2 && $item instanceof Project) { | ||
| echo '<div class="alert alert-info mb-3">'; | ||
| echo '<i class="ti ti-info-circle me-2"></i>'; | ||
| echo __('You are viewing ITIL objects from the template. Save the project first to be able to add or modify linked tickets, problems or changes.'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| echo __('You are viewing ITIL objects from the template. Save the project first to be able to add or modify linked tickets, problems or changes.'); | |
| echo __s('You are viewing ITIL objects from the template. Save the project first to be able to add or modify linked tickets, problems or changes.'); |
| if ($withtemplate == 2 && $item instanceof Project) { | ||
| echo '<div class="alert alert-info mb-3">'; | ||
| echo '<i class="ti ti-info-circle me-2"></i>'; | ||
| echo __('You are viewing knowledge base items from the template. Save the project first to be able to add or modify linked articles.'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| echo __('You are viewing knowledge base items from the template. Save the project first to be able to add or modify linked articles.'); | |
| echo __s('You are viewing knowledge base items from the template. Save the project first to be able to add or modify linked articles.'); |
| if ($withtemplate == 2 && $item instanceof Project) { | ||
| echo '<div class="alert alert-info mb-3">'; | ||
| echo '<i class="ti ti-info-circle me-2"></i>'; | ||
| echo __('You are viewing notes from the template. Save the project first to be able to add or modify notes.'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| echo __('You are viewing notes from the template. Save the project first to be able to add or modify notes.'); | |
| echo __s('You are viewing notes from the template. Save the project first to be able to add or modify notes.'); |
| if ($withtemplate == 2) { | ||
| echo '<div class="alert alert-info mb-3">'; | ||
| echo '<i class="ti ti-info-circle me-2"></i>'; | ||
| echo __('You are viewing costs from the template. Save the project first to be able to add or modify costs.'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| echo __('You are viewing costs from the template. Save the project first to be able to add or modify costs.'); | |
| echo __s('You are viewing costs from the template. Save the project first to be able to add or modify costs.'); |
| if ($withtemplate == 2) { | ||
| echo '<div class="alert alert-info mb-3">'; | ||
| echo '<i class="ti ti-info-circle me-2"></i>'; | ||
| echo __('You are viewing tasks from the template. Save the project first to be able to add or modify tasks.'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| echo __('You are viewing tasks from the template. Save the project first to be able to add or modify tasks.'); | |
| echo __s('You are viewing tasks from the template. Save the project first to be able to add or modify tasks.'); |
| if ($withtemplate == 2) { | ||
| echo '<div class="alert alert-info mb-3">'; | ||
| echo '<i class="ti ti-info-circle me-2"></i>'; | ||
| echo __('You are viewing team members from the template. Save the project first to be able to add or modify team members.'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| echo __('You are viewing team members from the template. Save the project first to be able to add or modify team members.'); | |
| echo __s('You are viewing team members from the template. Save the project first to be able to add or modify team members.'); |
Description
It fixes !40258
Replace #22265
The project creation via templates workflow had a confusing UX where users could add elements as tasks and teams to templates, thinking they were creating actual projects.
This PR implements a comprehensive read-only preview of the project tabs when it is not registered :