mirror of
https://github.com/discourse/discourse.git
synced 2025-02-14 19:52:46 +08:00
![Joffrey JAFFEUX](/assets/img/avatar_default.png)
This work will allow us to have an {{outlet}} chat.channel route and use it for threads as a sidepanel.
17 lines
429 B
JavaScript
17 lines
429 B
JavaScript
import DiscourseRoute from "discourse/routes/discourse";
|
|
import { inject as service } from "@ember/service";
|
|
|
|
export default class ChatChannelLegacyRoute extends DiscourseRoute {
|
|
@service router;
|
|
|
|
redirect() {
|
|
const { channelTitle, channelId, messageId } = this.paramsFor(
|
|
this.routeName
|
|
);
|
|
|
|
this.router.replaceWith("chat.channel", channelTitle, channelId, {
|
|
queryParams: { messageId },
|
|
});
|
|
}
|
|
}
|