discourse-ai/assets/javascripts/discourse/admin-discourse-ai-plugin-route-map.js
Krzysztof Kotlarek 04c4ff8cf0
UX: No admin header for edit personas tools or llms (#1021)
In this PR, we added functionality to hide the admin header for edit/new actions - https://github.com/discourse/discourse/pull/30175

To make it work properly, we have to rename `show` to `edit` which is also a more accurate name.
2024-12-12 10:48:58 +11:00

24 lines
685 B
JavaScript

export default {
resource: "admin.adminPlugins.show",
path: "/plugins",
map() {
this.route("discourse-ai-personas", { path: "ai-personas" }, function () {
this.route("new");
this.route("edit", { path: "/:id/edit" });
});
this.route("discourse-ai-llms", { path: "ai-llms" }, function () {
this.route("new");
this.route("edit", { path: "/:id/edit" });
});
this.route("discourse-ai-tools", { path: "ai-tools" }, function () {
this.route("new");
this.route("edit", { path: "/:id/edit" });
});
this.route("discourse-ai-spam", { path: "ai-spam" });
this.route("discourse-ai-usage", { path: "ai-usage" });
},
};