mirror of
https://github.com/usmannasir/cyberpanel.git
synced 2025-11-09 23:06:16 +01:00
bug fix: git manager
This commit is contained in:
69
static/emailPremium/emailPremium.js
Executable file → Normal file
69
static/emailPremium/emailPremium.js
Executable file → Normal file
@@ -102,7 +102,6 @@ app.controller('listDomains', function($scope,$http) {
|
||||
/* Java script code to list accounts ends here */
|
||||
|
||||
|
||||
|
||||
/* Java script code for email domain page */
|
||||
|
||||
app.controller('emailDomainPage', function($scope,$http, $timeout, $window) {
|
||||
@@ -312,7 +311,6 @@ app.controller('emailDomainPage', function($scope,$http, $timeout, $window) {
|
||||
|
||||
/* Java script code for email domain page */
|
||||
|
||||
|
||||
/* Java script code for Email Page */
|
||||
|
||||
app.controller('emailPage', function($scope,$http, $timeout, $window) {
|
||||
@@ -670,7 +668,6 @@ app.controller('emailPage', function($scope,$http, $timeout, $window) {
|
||||
|
||||
/* Java script code for Email Page */
|
||||
|
||||
|
||||
/* Java script code for SpamAssassin */
|
||||
|
||||
app.controller('SpamAssassin', function($scope, $http, $timeout, $window) {
|
||||
@@ -956,10 +953,8 @@ app.controller('SpamAssassin', function($scope, $http, $timeout, $window) {
|
||||
|
||||
});
|
||||
|
||||
|
||||
/* Java script code for SpamAssassin */
|
||||
|
||||
|
||||
/* Java script code for Email Policy Server */
|
||||
|
||||
app.controller('policyServer', function($scope, $http, $timeout, $window) {
|
||||
@@ -1088,5 +1083,67 @@ app.controller('policyServer', function($scope, $http, $timeout, $window) {
|
||||
|
||||
});
|
||||
|
||||
|
||||
/* Java script code for Email Policy Server */
|
||||
|
||||
/* Java script code to manage mail queue */
|
||||
|
||||
app.controller('mailQueue', function($scope,$http) {
|
||||
|
||||
$scope.currentPage = 1;
|
||||
$scope.recordsToShow = 10;
|
||||
$scope.cyberpanelLoading = true;
|
||||
|
||||
$scope.fetchMailQueue = function () {
|
||||
$scope.cyberpanelLoading = false;
|
||||
var config = {
|
||||
headers: {
|
||||
'X-CSRFToken': getCookie('csrftoken')
|
||||
}
|
||||
};
|
||||
|
||||
var data = {
|
||||
folder: $scope.folder,
|
||||
page: $scope.currentPage,
|
||||
recordsToShow: $scope.recordsToShow
|
||||
};
|
||||
|
||||
dataurl = "/emailPremium/fetchMailQueue";
|
||||
|
||||
$http.post(dataurl, data, config).then(ListInitialDatas, cantLoadInitialDatas);
|
||||
|
||||
function ListInitialDatas(response) {
|
||||
$scope.cyberpanelLoading = true;
|
||||
if (response.data.status === 1) {
|
||||
new PNotify({
|
||||
title: 'Success',
|
||||
text: 'Successfully fetched.',
|
||||
type: 'success'
|
||||
});
|
||||
$scope.queues = JSON.parse(response.data.data);
|
||||
$scope.pagination = response.data.pagination;
|
||||
} else {
|
||||
new PNotify({
|
||||
title: 'Operation Failed!',
|
||||
text: response.data.error_message,
|
||||
type: 'error'
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
function cantLoadInitialDatas(response) {
|
||||
$scope.cyberpanelLoading = true;
|
||||
new PNotify({
|
||||
title: 'Operation Failed!',
|
||||
text: 'Could not connect to server, please refresh this page.',
|
||||
type: 'error'
|
||||
});
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
};
|
||||
$scope.fetchMailQueue();
|
||||
});
|
||||
|
||||
/* Java script code to manage mail queue ends here */
|
||||
@@ -6546,12 +6546,18 @@ app.controller('manageGIT', function ($scope, $http, $timeout, $window) {
|
||||
|
||||
var currentComit;
|
||||
var fetchFileCheck = 0;
|
||||
var initial = 1;
|
||||
|
||||
$scope.fetchFiles = function (commit) {
|
||||
|
||||
currentComit = commit;
|
||||
$scope.cyberpanelLoading = false;
|
||||
|
||||
if (initial === 1){
|
||||
initial = 0;
|
||||
}else {
|
||||
fetchFileCheck = 1;
|
||||
}
|
||||
|
||||
url = "/websites/fetchFiles";
|
||||
|
||||
@@ -6607,6 +6613,7 @@ app.controller('manageGIT', function ($scope, $http, $timeout, $window) {
|
||||
|
||||
$scope.fetchChangesInFile = function () {
|
||||
$scope.fileStatus = true;
|
||||
|
||||
if(fetchFileCheck === 1){
|
||||
fetchFileCheck = 0;
|
||||
return 0;
|
||||
|
||||
Reference in New Issue
Block a user