2019-12-12 19:54:32 -05:00
|
|
|
import Route from "@ember/routing/route";
|
2024-11-19 05:31:14 -05:00
|
|
|
import { service } from "@ember/service";
|
2019-10-27 23:05:58 -04:00
|
|
|
|
2024-11-29 10:42:50 -05:00
|
|
|
export default class UserBillingRoute extends Route {
|
|
|
|
@service router;
|
2024-01-16 11:51:44 -05:00
|
|
|
|
2024-11-29 10:42:50 -05:00
|
|
|
templateName = "user/billing";
|
2019-10-24 22:23:32 -04:00
|
|
|
|
|
|
|
setupController(controller, model) {
|
|
|
|
if (this.currentUser.id !== this.modelFor("user").id) {
|
2024-01-16 11:51:44 -05:00
|
|
|
this.router.replaceWith("userActivity");
|
2019-10-24 23:00:59 -04:00
|
|
|
} else {
|
2019-10-24 22:23:32 -04:00
|
|
|
controller.setProperties({ model });
|
2019-10-24 23:00:59 -04:00
|
|
|
}
|
2024-11-29 10:42:50 -05:00
|
|
|
}
|
|
|
|
}
|