mirror of
https://github.com/yu-i-i/overleaf-cep.git
synced 2026-06-02 05:41:33 +02:00
Handle archive and leave action
This commit is contained in:
@@ -195,10 +195,11 @@ script(type='text/ng-template', id='deleteProjectsModalTemplate')
|
||||
h3(ng-if="action == 'archive'") #{translate("archive_projects")}
|
||||
h3(ng-if="action == 'leave'") #{translate("leave_projects")}
|
||||
h3(ng-if="action == 'delete-and-leave'") #{translate("delete_and_leave_projects")}
|
||||
h3(ng-if="action == 'archive-and-leave'") #{translate("archive_and_leave_projects")}
|
||||
.modal-body
|
||||
div(ng-show="projectsToDelete.length > 0")
|
||||
p(ng-if="action == 'delete'") #{translate("about_to_delete_projects")}
|
||||
p(ng-if="action == 'archive'") #{translate("about_to_archive_projects")}
|
||||
p(ng-if="action == 'delete' || action == 'delete-and-leave'") #{translate("about_to_delete_projects")}
|
||||
p(ng-if="action == 'archive' || action == 'archive-and-leave'") #{translate("about_to_archive_projects")}
|
||||
ul
|
||||
li(ng-repeat="project in projectsToDelete | orderBy:'name'")
|
||||
strong {{project.name}}
|
||||
|
||||
@@ -105,7 +105,10 @@ define [
|
||||
project.accessLevel == "owner" and !project.archived
|
||||
|
||||
if $scope.projectsToLeave.length > 0 and $scope.projectsToDelete.length > 0
|
||||
$scope.action = "delete-and-leave"
|
||||
if $scope.projectsToArchive.length > 0 and window.ExposedSettings.isOverleaf
|
||||
$scope.action = "archive-and-leave"
|
||||
else
|
||||
$scope.action = "delete-and-leave"
|
||||
else if $scope.projectsToLeave.length == 0 and $scope.projectsToDelete.length > 0
|
||||
if $scope.projectsToArchive.length > 0 and window.ExposedSettings.isOverleaf
|
||||
$scope.action = "archive"
|
||||
|
||||
Reference in New Issue
Block a user