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

UI: PKI routes extend base Route #20179

Merged
merged 5 commits into from
Apr 17, 2023
Merged

UI: PKI routes extend base Route #20179

merged 5 commits into from
Apr 17, 2023

Conversation

hashishaw
Copy link
Contributor

This PR untangles the routing for the PKI engine. Extending other routes was causing confusion and it wasn't clear why some routes were even extended. As part of this PR, all the PKI models using openAPI are also instantiated at the engine application route so that the models are hydrated and available for the rest of the engine.

@hashishaw hashishaw added this to the 1.14 milestone Apr 14, 2023
@service secretMountPath;

model() {
return this.modelFor('issuers.issuer');
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is so much better than extending the PkiIssuerRoute!

setupController(controller, resolvedModel) {
super.setupController(controller, resolvedModel);
controller.breadcrumbs.push(

controller.breadcrumbs = [
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I had a question for my understanding. Previously we were pushing in the two breadcrumbs, but the new change is setting this to an array of breadcrumbs. Why are we doing that?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good question! Before, since we were extending the other route, it was first calling setupController on the extended route, which instantiated breadcrumbs on the controller. Then this route's setupController is called, which just pushes the new breadcrumbs to the parent's array. Hope that makes sense!

@hashishaw hashishaw enabled auto-merge (squash) April 17, 2023 15:31
@hashishaw hashishaw merged commit d518846 into main Apr 17, 2023
@hashishaw hashishaw deleted the ui/untangle-pki-routes branch May 6, 2024 14:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants