2023-03-15 17:39:33 +00:00
|
|
|
import { action } from "@ember/object";
|
2020-03-06 17:41:41 +01:00
|
|
|
import Controller, { inject as controller } from "@ember/controller";
|
2022-11-08 10:40:56 +10:00
|
|
|
import discourseComputed from "discourse-common/utils/decorators";
|
2014-08-20 18:48:56 +02:00
|
|
|
import ModalFunctionality from "discourse/mixins/modal-functionality";
|
|
|
|
|
2023-03-15 17:39:33 +00:00
|
|
|
export default class AdminStartBackupController extends Controller.extend(
|
|
|
|
ModalFunctionality
|
|
|
|
) {
|
|
|
|
@controller adminBackupsLogs;
|
2014-08-20 18:48:56 +02:00
|
|
|
|
2022-11-08 10:40:56 +10:00
|
|
|
@discourseComputed
|
|
|
|
warningMessage() {
|
|
|
|
// this is never shown here, but we may want to show different
|
|
|
|
// messages in plugins
|
|
|
|
return "";
|
2023-03-15 17:39:33 +00:00
|
|
|
}
|
2022-11-08 10:40:56 +10:00
|
|
|
|
|
|
|
@discourseComputed
|
|
|
|
yesLabel() {
|
|
|
|
return "yes_value";
|
2023-03-15 17:39:33 +00:00
|
|
|
}
|
2022-11-08 10:40:56 +10:00
|
|
|
|
2023-03-15 17:39:33 +00:00
|
|
|
@action
|
|
|
|
startBackupWithUploads() {
|
|
|
|
this.send("closeModal");
|
|
|
|
this.send("startBackup", true);
|
|
|
|
}
|
2014-08-20 18:48:56 +02:00
|
|
|
|
2023-03-15 17:39:33 +00:00
|
|
|
@action
|
|
|
|
startBackupWithoutUploads() {
|
|
|
|
this.send("closeModal");
|
|
|
|
this.send("startBackup", false);
|
|
|
|
}
|
2014-08-20 18:48:56 +02:00
|
|
|
|
2023-03-15 17:39:33 +00:00
|
|
|
@action
|
|
|
|
cancel() {
|
|
|
|
this.send("closeModal");
|
|
|
|
}
|
|
|
|
}
|