Skip to content

Commit

Permalink
Merge pull request opf#15823 from opf/impl/ui-router-backlogs
Browse files Browse the repository at this point in the history
Remove ui-router from backlogs
  • Loading branch information
HDinger authored Jun 13, 2024
2 parents 554fe35 + 5995f0a commit 0888e48
Show file tree
Hide file tree
Showing 18 changed files with 18 additions and 143 deletions.
8 changes: 6 additions & 2 deletions app/helpers/frontend_asset_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -46,16 +46,20 @@ def include_frontend_assets
concat nonced_javascript_include_tag variable_asset_path(file), skip_pipeline: true
end

concat stylesheet_link_tag variable_asset_path("styles.css"), media: :all, skip_pipeline: true
concat frontend_stylesheet_link_tag("styles.css")
end
end

def include_spot_assets
capture do
concat stylesheet_link_tag variable_asset_path("spot.css"), media: :all, skip_pipeline: true
concat frontend_stylesheet_link_tag("spot.css")
end
end

def frontend_stylesheet_link_tag(path)
stylesheet_link_tag variable_asset_path(path), media: :all, skip_pipeline: true
end

def nonced_javascript_include_tag(path, **)
javascript_include_tag(path, nonce: content_security_policy_script_nonce, **)
end
Expand Down
4 changes: 4 additions & 0 deletions frontend/angular.json
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,10 @@
"input": "src/spot.scss",
"bundleName": "spot"
},
{
"input": "src/backlogs.scss",
"bundleName": "backlogs"
},
"src/styles.scss",
"node_modules/codemirror/lib/codemirror.css",
"node_modules/jquery-ui/themes/base/core.css",
Expand Down
12 changes: 0 additions & 12 deletions frontend/src/app/core/routing/openproject.routes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -82,18 +82,6 @@ export const OPENPROJECT_ROUTES:Ng2StateDeclaration[] = [
url: '/bcf',
loadChildren: () => import('../../features/bim/ifc_models/openproject-ifc-models.module').then((m) => m.OpenprojectIFCModelsModule),
},
{
name: 'backlogs.**',
parent: 'optional_project',
url: '/backlogs',
loadChildren: () => import('../../features/backlogs/openproject-backlogs.module').then((m) => m.OpenprojectBacklogsModule),
},
{
name: 'backlogs_sprint.**',
parent: 'optional_project',
url: '/sprints',
loadChildren: () => import('../../features/backlogs/openproject-backlogs.module').then((m) => m.OpenprojectBacklogsModule),
},
{
name: 'reporting.**',
parent: 'optional_project',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -90,10 +90,6 @@ import {
TriggerActionsEntryComponent,
triggerActionsEntryComponentSelector,
} from 'core-app/shared/components/time_entries/edit/trigger-actions-entry.component';
import {
BacklogsPageComponent,
backlogsPageComponentSelector,
} from 'core-app/features/backlogs/backlogs-page/backlogs-page.component';
import {
AttributeHelpTextComponent,
attributeHelpTextSelector,
Expand Down Expand Up @@ -224,7 +220,6 @@ export const globalDynamicComponents:OptionalBootstrapDefinition[] = [
{ selector: opTeamPlannerSidemenuSelector, cls: TeamPlannerSidemenuComponent },
{ selector: opCalendarSidemenuSelector, cls: CalendarSidemenuComponent },
{ selector: triggerActionsEntryComponentSelector, cls: TriggerActionsEntryComponent, embeddable: true },
{ selector: backlogsPageComponentSelector, cls: BacklogsPageComponent },
{ selector: editableQueryPropsSelector, cls: EditableQueryPropsComponent },
{ selector: backupSelector, cls: BackupComponent },
{ selector: opInAppNotificationBellSelector, cls: InAppNotificationBellComponent },
Expand Down

This file was deleted.

46 changes: 0 additions & 46 deletions frontend/src/app/features/backlogs/openproject-backlogs.module.ts

This file was deleted.

51 changes: 0 additions & 51 deletions frontend/src/app/features/backlogs/openproject-backlogs.routes.ts

This file was deleted.

2 changes: 2 additions & 0 deletions frontend/src/backlogs.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
// Backlogs
@import "assets/sass/backlogs";
2 changes: 2 additions & 0 deletions frontend/src/global_styles/openproject/_index.sass
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,5 @@
@import working-days-admin-settings

@import ndc-dynamic

@import backlogs
12 changes: 4 additions & 8 deletions modules/backlogs/app/views/layouts/backlogs.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -31,14 +31,10 @@ See COPYRIGHT and LICENSE files for more details.
<%= nonced_javascript_tag do %>
<%= render(partial: 'shared/server_variables', formats: [:js]) %>
<% end %>
<%= frontend_stylesheet_link_tag "backlogs.css" %>
<% end %>

<% content_for :content_body do %>
<openproject-base></openproject-base>
<%# Allow projection pages to show rails rendered content after initialization %>
<div data-controller="backlogs" data-application-target="dynamic" id="projected-content" hidden>
<%= yield %>
</div>
<% end -%>
<% content_controller 'backlogs',
dynamic: true %>

<%= render template: 'layouts/base', locals: local_assigns.merge({ no_layout_yield: true }) %>
<%= render template: 'layouts/base', locals: local_assigns %>

0 comments on commit 0888e48

Please sign in to comment.