Skip to content

Commit

Permalink
Add notice flash
Browse files Browse the repository at this point in the history
  • Loading branch information
oliverguenther authored and cbliard committed Jan 10, 2025
1 parent b2d0e65 commit 7369584
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions app/controllers/work_packages/dialogs_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ def create
call = WorkPackages::CreateService.new(user: current_user).call(create_params)

if call.success?
flash[:notice] = I18n.t("work_package_relations_tab.relations.label_new_child_created")
redirect_back fallback_location: project_work_package_path(@project, call.result), status: :see_other
else
form_component = WorkPackages::Dialogs::CreateFormComponent.new(work_package: call.result, project: @project)
Expand Down
1 change: 1 addition & 0 deletions config/locales/en.yml
Original file line number Diff line number Diff line change
Expand Up @@ -749,6 +749,7 @@ en:
title: "Lag (in days)"
caption: "The minimum number of working days to keep in between the two work packages."
relations:
label_new_child_created: "New work package created and added as a child"
label_relates_singular: "related to"
label_relates_plural: "related to"
label_relates_to_singular: "related to"
Expand Down

0 comments on commit 7369584

Please sign in to comment.