mirror of
https://github.com/usmannasir/cyberpanel.git
synced 2026-03-03 19:00:45 +01:00
commit message
This commit is contained in:
@@ -302,7 +302,7 @@
|
||||
<div class="scroll-sidebar">
|
||||
<ul id="sidebar-menu">
|
||||
<li class="header"><span>{% trans "Overview ABC" %}</span>
|
||||
<a href="{% url 'exampleZarak' %}">Example Page</a>
|
||||
<a href="{% url 'dashboardV2' %}">Cyber Panel V2</a>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
@@ -76,7 +76,7 @@
|
||||
|
||||
<p class="text-white text-sm font-semibold">65.108.159.129</p>
|
||||
</button>
|
||||
<a href="{% url 'exampleZarak' %}"
|
||||
<a href="{% url 'dashboardV2' %}"
|
||||
class="flex justify-start items-center space-x-6 hover:text-white focus:bg-cyan-400 focus:text-white hover:bg-cyan-400 text-gray-400 rounded px-3 py-1 w-full md:w-52">
|
||||
|
||||
<svg width="24" height="24" viewBox="0 0 40 40" fill="white"
|
||||
@@ -328,7 +328,7 @@
|
||||
</div>
|
||||
<ul id="dropdown-example-2" class="hidden py-2 space-y-2">
|
||||
<li>
|
||||
<a href="#"
|
||||
<a href="{% url 'createWordpressV2' %}"
|
||||
class="flex items-center w-full text-base font-normal text-white transition duration-75 rounded-lg group hover:bg-cyan-400 dark:text-white dark:hover:bg-gray-700 pl-11">•
|
||||
Deploy Wordpress</a>
|
||||
</li>
|
||||
@@ -426,17 +426,17 @@
|
||||
List Sub-Domains</a>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"
|
||||
<a href="{% url 'modifyWebsiteV2' %}"
|
||||
class="flex items-center w-full text-base font-normal text-white transition duration-75 rounded-lg group hover:bg-cyan-400 dark:text-white dark:hover:bg-gray-700 pl-11">•
|
||||
Modify Website</a>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"
|
||||
<a href="{% url 'siteStateV2' %}"
|
||||
class="flex items-center w-full text-base font-normal text-white transition duration-75 rounded-lg group hover:bg-cyan-400 dark:text-white dark:hover:bg-gray-700 pl-11">•
|
||||
Suspend/Unsuspend</a>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#"
|
||||
<a href="{% url 'deleteWebsiteV2' %}"
|
||||
class="flex items-center w-full text-base font-normal text-white transition duration-75 rounded-lg group hover:bg-cyan-400 dark:text-white dark:hover:bg-gray-700 pl-11">•
|
||||
Delete Website</a>
|
||||
</li>
|
||||
|
||||
@@ -13,24 +13,24 @@
|
||||
<p class="text-xl font-semibold">CyberPanel</p>
|
||||
<div class="py-6">
|
||||
<div class="border border-gray-300 shadow-lg rounded-lg px-6 py-4">
|
||||
<table class="flex">
|
||||
<table class="flex overflow-x-auto">
|
||||
<thead>
|
||||
<tr class="flex justify-start mb-2">
|
||||
<tr class="flex justify-start mb-2 w-32">
|
||||
<th>Current Version:</th>
|
||||
</tr>
|
||||
<tr class="flex justify-start mb-2">
|
||||
<tr class="flex justify-start mb-2 w-32">
|
||||
<th>Build:</th>
|
||||
</tr>
|
||||
<tr class="flex justify-start mb-2">
|
||||
<tr class="flex justify-start mb-2 w-32">
|
||||
<th>Current Commit:</th>
|
||||
</tr>
|
||||
<tr class="flex justify-start mb-2">
|
||||
<tr class="flex justify-start mb-2 w-32">
|
||||
<th>Latest Version:</th>
|
||||
</tr>
|
||||
<tr class="flex justify-start mb-2">
|
||||
<tr class="flex justify-start mb-2 w-32">
|
||||
<th>Current Biuld:</th>
|
||||
</tr>
|
||||
<tr class="flex justify-start mb-2">
|
||||
<tr class="flex justify-start mb-2 w-32">
|
||||
<th>Current Version:</th>
|
||||
</tr>
|
||||
</thead>
|
||||
|
||||
@@ -8,7 +8,7 @@ urlpatterns = [
|
||||
url(r'^getLoadAverage',views.getLoadAverage, name='getLoadAverage'),
|
||||
url(r'^versionManagment',views.versionManagment, name='versionManagment'),
|
||||
url(r'^design', views.design, name='design'),
|
||||
url(r'^exampleZarak', views.exampleZarak, name='exampleZarak'),
|
||||
url(r'^dashboardV2', views.dashboardV2, name='dashboardV2'),
|
||||
url(r'^visionManagementV2', views.visionManagementV2, name='visionManagementV2'),
|
||||
|
||||
url(r'^getthemedata', views.getthemedata, name='getthemedata'),
|
||||
|
||||
@@ -31,8 +31,8 @@ def renderBase(request):
|
||||
proc = httpProc(request, template, finaData)
|
||||
return proc.render()
|
||||
|
||||
def exampleZarak(request):
|
||||
template = 'baseTemplate/example.html'
|
||||
def dashboardV2(request):
|
||||
template = 'baseTemplate/dashboardV2.html'
|
||||
proc = httpProc(request, template)
|
||||
return proc.render()
|
||||
|
||||
|
||||
@@ -2608,4 +2608,568 @@ newapp.controller('listChildDomainsMainV2', function ($scope, $http, $timeout) {
|
||||
|
||||
};
|
||||
|
||||
});
|
||||
});
|
||||
|
||||
newapp.controller('modifyWebsitesControllerV2', function ($scope, $http) {
|
||||
|
||||
$scope.fetchWebsites = function () {
|
||||
|
||||
$("#modifyWebsiteLoading").show();
|
||||
|
||||
|
||||
var websiteToBeModified = $scope.websiteToBeModified;
|
||||
|
||||
url = "/websites/getWebsiteDetails";
|
||||
|
||||
var data = {
|
||||
websiteToBeModified: websiteToBeModified,
|
||||
};
|
||||
|
||||
var config = {
|
||||
headers: {
|
||||
'X-CSRFToken': getCookie('csrftoken')
|
||||
}
|
||||
};
|
||||
|
||||
$http.post(url, data, config).then(ListInitialDatas, cantLoadInitialDatas);
|
||||
|
||||
|
||||
function ListInitialDatas(response) {
|
||||
|
||||
if (response.data.modifyStatus === 0) {
|
||||
console.log(response.data);
|
||||
$scope.errorMessage = response.data.error_message;
|
||||
$("#websiteModifyFailure").fadeIn();
|
||||
$("#websiteModifySuccess").hide();
|
||||
$("#modifyWebsiteButton").hide();
|
||||
$("#modifyWebsiteLoading").hide();
|
||||
$("#canNotModify").hide();
|
||||
|
||||
|
||||
} else {
|
||||
console.log(response.data);
|
||||
$("#modifyWebsiteButton").fadeIn();
|
||||
|
||||
$scope.adminEmail = response.data.adminEmail;
|
||||
$scope.currentPack = response.data.current_pack;
|
||||
$scope.webpacks = JSON.parse(response.data.packages);
|
||||
$scope.adminNames = JSON.parse(response.data.adminNames);
|
||||
$scope.currentAdmin = response.data.currentAdmin;
|
||||
|
||||
$("#webSiteDetailsToBeModified").fadeIn();
|
||||
$("#websiteModifySuccess").fadeIn();
|
||||
$("#modifyWebsiteButton").fadeIn();
|
||||
$("#modifyWebsiteLoading").hide();
|
||||
$("#canNotModify").hide();
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
function cantLoadInitialDatas(response) {
|
||||
$("#websiteModifyFailure").fadeIn();
|
||||
}
|
||||
|
||||
};
|
||||
|
||||
|
||||
$scope.modifyWebsiteFunc = function () {
|
||||
|
||||
var domain = $scope.websiteToBeModified;
|
||||
var packForWeb = $scope.selectedPack;
|
||||
var email = $scope.adminEmail;
|
||||
var phpVersion = $scope.phpSelection;
|
||||
var admin = $scope.selectedAdmin;
|
||||
|
||||
|
||||
$("#websiteModifyFailure").hide();
|
||||
$("#websiteModifySuccess").hide();
|
||||
$("#websiteSuccessfullyModified").hide();
|
||||
$("#canNotModify").hide();
|
||||
$("#modifyWebsiteLoading").fadeIn();
|
||||
|
||||
|
||||
url = "/websites/saveWebsiteChanges";
|
||||
|
||||
var data = {
|
||||
domain: domain,
|
||||
packForWeb: packForWeb,
|
||||
email: email,
|
||||
phpVersion: phpVersion,
|
||||
admin: admin
|
||||
};
|
||||
|
||||
var config = {
|
||||
headers: {
|
||||
'X-CSRFToken': getCookie('csrftoken')
|
||||
}
|
||||
};
|
||||
|
||||
$http.post(url, data, config).then(ListInitialDatas, cantLoadInitialDatas);
|
||||
|
||||
|
||||
function ListInitialDatas(response) {
|
||||
|
||||
if (response.data.saveStatus === 0) {
|
||||
$scope.errMessage = response.data.error_message;
|
||||
|
||||
$("#canNotModify").fadeIn();
|
||||
$("#websiteModifyFailure").hide();
|
||||
$("#websiteModifySuccess").hide();
|
||||
$("#websiteSuccessfullyModified").hide();
|
||||
$("#modifyWebsiteLoading").hide();
|
||||
|
||||
|
||||
} else {
|
||||
$("#modifyWebsiteButton").hide();
|
||||
$("#canNotModify").hide();
|
||||
$("#websiteModifyFailure").hide();
|
||||
$("#websiteModifySuccess").hide();
|
||||
|
||||
$("#websiteSuccessfullyModified").fadeIn();
|
||||
$("#modifyWebsiteLoading").hide();
|
||||
|
||||
$scope.websiteModified = domain;
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
function cantLoadInitialDatas(response) {
|
||||
$scope.errMessage = response.data.error_message;
|
||||
$("#canNotModify").fadeIn();
|
||||
}
|
||||
|
||||
|
||||
};
|
||||
|
||||
});
|
||||
|
||||
newapp.controller('suspendWebsiteControlV2', function ($scope, $http) {
|
||||
|
||||
$scope.suspendLoading = true;
|
||||
$scope.stateView = true;
|
||||
|
||||
$scope.websiteSuspendFailure = true;
|
||||
$scope.websiteUnsuspendFailure = true;
|
||||
$scope.websiteSuccess = true;
|
||||
$scope.couldNotConnect = true;
|
||||
|
||||
$scope.showSuspendUnsuspend = function () {
|
||||
|
||||
$scope.stateView = false;
|
||||
|
||||
|
||||
};
|
||||
|
||||
$scope.save = function () {
|
||||
|
||||
$scope.suspendLoading = false;
|
||||
|
||||
var websiteName = $scope.websiteToBeSuspended
|
||||
var state = $scope.state;
|
||||
|
||||
|
||||
url = "/websites/submitWebsiteStatus";
|
||||
|
||||
var data = {
|
||||
websiteName: websiteName,
|
||||
state: state,
|
||||
};
|
||||
|
||||
var config = {
|
||||
headers: {
|
||||
'X-CSRFToken': getCookie('csrftoken')
|
||||
}
|
||||
};
|
||||
|
||||
$http.post(url, data, config).then(ListInitialDatas, cantLoadInitialDatas);
|
||||
|
||||
|
||||
function ListInitialDatas(response) {
|
||||
|
||||
if (response.data.websiteStatus === 1) {
|
||||
if (state == "Suspend") {
|
||||
|
||||
$scope.suspendLoading = true;
|
||||
$scope.stateView = false;
|
||||
|
||||
$scope.websiteSuspendFailure = true;
|
||||
$scope.websiteUnsuspendFailure = true;
|
||||
$scope.websiteSuccess = false;
|
||||
$scope.couldNotConnect = true;
|
||||
|
||||
$scope.websiteStatus = websiteName;
|
||||
$scope.finalStatus = "Suspended";
|
||||
|
||||
} else {
|
||||
$scope.suspendLoading = true;
|
||||
$scope.stateView = false;
|
||||
|
||||
$scope.websiteSuspendFailure = true;
|
||||
$scope.websiteUnsuspendFailure = true;
|
||||
$scope.websiteSuccess = false;
|
||||
$scope.couldNotConnect = true;
|
||||
|
||||
$scope.websiteStatus = websiteName;
|
||||
$scope.finalStatus = "Un-suspended";
|
||||
|
||||
}
|
||||
|
||||
} else {
|
||||
|
||||
if (state == "Suspend") {
|
||||
|
||||
$scope.suspendLoading = true;
|
||||
$scope.stateView = false;
|
||||
|
||||
$scope.websiteSuspendFailure = false;
|
||||
$scope.websiteUnsuspendFailure = true;
|
||||
$scope.websiteSuccess = true;
|
||||
$scope.couldNotConnect = true;
|
||||
|
||||
|
||||
} else {
|
||||
$scope.suspendLoading = true;
|
||||
$scope.stateView = false;
|
||||
|
||||
$scope.websiteSuspendFailure = true;
|
||||
$scope.websiteUnsuspendFailure = false;
|
||||
$scope.websiteSuccess = true;
|
||||
$scope.couldNotConnect = true;
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
$scope.errorMessage = response.data.error_message;
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
function cantLoadInitialDatas(response) {
|
||||
$scope.couldNotConnect = false;
|
||||
$scope.suspendLoading = true;
|
||||
$scope.stateView = true;
|
||||
|
||||
$scope.websiteSuspendFailure = true;
|
||||
$scope.websiteUnsuspendFailure = true;
|
||||
$scope.websiteSuccess = true;
|
||||
|
||||
}
|
||||
|
||||
|
||||
};
|
||||
|
||||
});
|
||||
|
||||
newapp.controller('deleteWebsiteControlV2', function ($scope, $http) {
|
||||
|
||||
|
||||
$scope.deleteWebsite = function () {
|
||||
|
||||
$("#deleteWebsiteButton").fadeIn();
|
||||
|
||||
|
||||
};
|
||||
|
||||
$scope.deleteWebsiteFinal = function () {
|
||||
|
||||
$("#deleteLoading").show();
|
||||
|
||||
var websiteName = $scope.websiteToBeDeleted;
|
||||
|
||||
|
||||
url = "/websites/submitWebsiteDeletion";
|
||||
|
||||
var data = {
|
||||
websiteName: websiteName
|
||||
};
|
||||
|
||||
var config = {
|
||||
headers: {
|
||||
'X-CSRFToken': getCookie('csrftoken')
|
||||
}
|
||||
};
|
||||
|
||||
$http.post(url, data, config).then(ListInitialDatas, cantLoadInitialDatas);
|
||||
|
||||
|
||||
function ListInitialDatas(response) {
|
||||
|
||||
if (response.data.websiteDeleteStatus === 0) {
|
||||
$scope.errorMessage = response.data.error_message;
|
||||
$("#websiteDeleteFailure").fadeIn();
|
||||
$("#websiteDeleteSuccess").hide();
|
||||
$("#deleteWebsiteButton").hide();
|
||||
|
||||
|
||||
$("#deleteLoading").hide();
|
||||
|
||||
} else {
|
||||
$("#websiteDeleteFailure").hide();
|
||||
$("#websiteDeleteSuccess").fadeIn();
|
||||
$("#deleteWebsiteButton").hide();
|
||||
$scope.deletedWebsite = websiteName;
|
||||
$("#deleteLoading").hide();
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
function cantLoadInitialDatas(response) {
|
||||
}
|
||||
|
||||
|
||||
};
|
||||
|
||||
});
|
||||
|
||||
newapp.controller('createWordpressV2', function ($scope, $http, $timeout, $compile, $window) {
|
||||
$scope.webSiteCreationLoading = true;
|
||||
$scope.installationDetailsForm = false;
|
||||
$scope.installationProgress = true;
|
||||
$scope.errorMessageBox = true;
|
||||
$scope.success = true;
|
||||
$scope.couldNotConnect = true;
|
||||
$scope.goBackDisable = true;
|
||||
|
||||
|
||||
var statusFile;
|
||||
|
||||
$scope.createWordPresssite = function () {
|
||||
|
||||
$scope.webSiteCreationLoading = false;
|
||||
$scope.installationDetailsForm = true;
|
||||
$scope.installationProgress = false;
|
||||
$scope.errorMessageBox = true;
|
||||
$scope.success = true;
|
||||
$scope.couldNotConnect = true;
|
||||
$scope.goBackDisable = true;
|
||||
|
||||
|
||||
$scope.currentStatus = "Starting creation..";
|
||||
|
||||
var apacheBackend = 0;
|
||||
|
||||
if ($scope.apacheBackend === true) {
|
||||
apacheBackend = 1;
|
||||
} else {
|
||||
apacheBackend = 0
|
||||
}
|
||||
|
||||
var package = $scope.packageForWebsite;
|
||||
var websiteOwner = $scope.websiteOwner;
|
||||
var WPtitle = $scope.WPtitle;
|
||||
|
||||
// if (domain_check == 0) {
|
||||
// var Part2_domainNameCreate = document.getElementById('Part2_domainNameCreate').value;
|
||||
// var domainNameCreate = document.getElementById('TestDomainNameCreate').value + Part2_domainNameCreate;
|
||||
// }
|
||||
// if (domain_check == 1) {
|
||||
//
|
||||
// var domainNameCreate = $scope.own_domainNameCreate;
|
||||
// }
|
||||
|
||||
var domainNameCreate = $scope.domainNameCreate;
|
||||
|
||||
|
||||
var WPUsername = $scope.WPUsername;
|
||||
var adminEmail = $scope.adminEmail;
|
||||
var WPPassword = $scope.WPPassword;
|
||||
var WPVersions = $scope.WPVersions;
|
||||
var pluginbucket = $scope.pluginbucket;
|
||||
var autoupdates = $scope.autoupdates;
|
||||
var pluginupdates = $scope.pluginupdates;
|
||||
var themeupdates = $scope.themeupdates;
|
||||
|
||||
if (domain_check == 0) {
|
||||
|
||||
var path = "";
|
||||
|
||||
}
|
||||
if (domain_check = 1) {
|
||||
|
||||
var path = $scope.installPath;
|
||||
|
||||
}
|
||||
|
||||
|
||||
var home = "1";
|
||||
|
||||
if (typeof path != 'undefined') {
|
||||
home = "0";
|
||||
}
|
||||
|
||||
//alert(domainNameCreate);
|
||||
var data = {
|
||||
|
||||
title: WPtitle,
|
||||
domain: domainNameCreate,
|
||||
WPVersion: WPVersions,
|
||||
pluginbucket: pluginbucket,
|
||||
adminUser: WPUsername,
|
||||
Email: adminEmail,
|
||||
PasswordByPass: WPPassword,
|
||||
AutomaticUpdates: autoupdates,
|
||||
Plugins: pluginupdates,
|
||||
Themes: themeupdates,
|
||||
websiteOwner: websiteOwner,
|
||||
package: package,
|
||||
home: home,
|
||||
path: path,
|
||||
apacheBackend: apacheBackend
|
||||
}
|
||||
|
||||
var config = {
|
||||
headers: {
|
||||
'X-CSRFToken': getCookie('csrftoken')
|
||||
}
|
||||
};
|
||||
var url = "/websites/submitWorpressCreation";
|
||||
|
||||
$http.post(url, data, config).then(ListInitialDatas, cantLoadInitialDatas);
|
||||
|
||||
|
||||
function ListInitialDatas(response) {
|
||||
$scope.webSiteCreationLoading = true;
|
||||
if (response.data.status === 1) {
|
||||
statusFile = response.data.tempStatusPath;
|
||||
getCreationStatus();
|
||||
|
||||
} else {
|
||||
$scope.goBackDisable = false;
|
||||
new PNotify({
|
||||
title: 'Operation Failed!',
|
||||
text: response.data.error_message,
|
||||
type: 'error'
|
||||
});
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
function cantLoadInitialDatas(response) {
|
||||
|
||||
alert("Error..." + response)
|
||||
|
||||
}
|
||||
|
||||
};
|
||||
$scope.goBack = function () {
|
||||
$scope.webSiteCreationLoading = true;
|
||||
$scope.installationDetailsForm = false;
|
||||
$scope.installationProgress = true;
|
||||
$scope.errorMessageBox = true;
|
||||
$scope.success = true;
|
||||
$scope.couldNotConnect = true;
|
||||
$scope.goBackDisable = true;
|
||||
$("#installProgress").css("width", "0%");
|
||||
};
|
||||
|
||||
function getCreationStatus() {
|
||||
|
||||
url = "/websites/installWordpressStatus";
|
||||
|
||||
var data = {
|
||||
statusFile: statusFile
|
||||
};
|
||||
|
||||
var config = {
|
||||
headers: {
|
||||
'X-CSRFToken': getCookie('csrftoken')
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
$http.post(url, data, config).then(ListInitialDatas, cantLoadInitialDatas);
|
||||
|
||||
|
||||
function ListInitialDatas(response) {
|
||||
|
||||
if (response.data.abort === 1) {
|
||||
|
||||
if (response.data.installStatus === 1) {
|
||||
|
||||
$scope.webSiteCreationLoading = true;
|
||||
$scope.installationDetailsForm = true;
|
||||
$scope.installationProgress = false;
|
||||
$scope.errorMessageBox = true;
|
||||
$scope.success = false;
|
||||
$scope.couldNotConnect = true;
|
||||
$scope.goBackDisable = false;
|
||||
|
||||
$("#installProgress").css("width", "100%");
|
||||
$scope.installPercentage = "100";
|
||||
$scope.currentStatus = response.data.currentStatus;
|
||||
$timeout.cancel();
|
||||
|
||||
} else {
|
||||
|
||||
$scope.webSiteCreationLoading = true;
|
||||
$scope.installationDetailsForm = true;
|
||||
$scope.installationProgress = false;
|
||||
$scope.errorMessageBox = false;
|
||||
$scope.success = true;
|
||||
$scope.couldNotConnect = true;
|
||||
$scope.goBackDisable = false;
|
||||
|
||||
$scope.errorMessage = response.data.error_message;
|
||||
|
||||
$("#installProgress").css("width", "0%");
|
||||
$scope.installPercentage = "0";
|
||||
$scope.goBackDisable = false;
|
||||
|
||||
}
|
||||
|
||||
} else {
|
||||
$scope.webSiteCreationLoading = false;
|
||||
$("#installProgress").css("width", response.data.installationProgress + "%");
|
||||
$scope.installPercentage = response.data.installationProgress;
|
||||
$scope.currentStatus = response.data.currentStatus;
|
||||
$timeout(getCreationStatus, 1000);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
function cantLoadInitialDatas(response) {
|
||||
|
||||
$scope.webSiteCreationLoading = true;
|
||||
$scope.installationDetailsForm = true;
|
||||
$scope.installationProgress = false;
|
||||
$scope.errorMessageBox = true;
|
||||
$scope.success = true;
|
||||
$scope.couldNotConnect = false;
|
||||
$scope.goBackDisable = false;
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
});
|
||||
|
||||
// function openModalDelete() {
|
||||
// document.getElementById('modal').classList.remove('hidden');
|
||||
// }
|
||||
//
|
||||
// function closeModalDelete() {
|
||||
// document.getElementById('modal').classList.add('hidden');
|
||||
// }
|
||||
|
||||
|
||||
// function openModal() {
|
||||
// document.getElementById('settings').classList.remove('hidden');
|
||||
// }
|
||||
//
|
||||
// function closeModal() {
|
||||
// document.getElementById('settings').classList.add('hidden');
|
||||
// }
|
||||
|
||||
|
||||
177
websiteFunctions/templates/websiteFunctions/WPCreateV2.html
Normal file
177
websiteFunctions/templates/websiteFunctions/WPCreateV2.html
Normal file
@@ -0,0 +1,177 @@
|
||||
{% extends "baseTemplate/newBase.html" %}
|
||||
{% load i18n %}
|
||||
{% block titleNew %}{% trans "Home - CyberPanel" %}{% endblock %}
|
||||
{% block newContent %}
|
||||
|
||||
{% load static %}
|
||||
|
||||
<div ng-controller="createWordpressV2" class="p-8">
|
||||
<div>
|
||||
<p class="text-4xl font-bold">Create Wordpress Site</p>
|
||||
<p class="text-xs text-gray-600 py-2 font-semibold">On this page you can launch,list,modify and
|
||||
delete websites
|
||||
from your server</p>
|
||||
</div>
|
||||
<div>
|
||||
<div class="py-4">
|
||||
<p class="text-xl font-bold">Website Details</p>
|
||||
</div>
|
||||
<hr>
|
||||
<div>
|
||||
<div ng-hide="installationDetailsForm" class="flex mt-4 py-2 px-6">
|
||||
<div>
|
||||
<p class="font-semibold w-48">Select Package</p>
|
||||
</div>
|
||||
<div>
|
||||
<select ng-model="packageForWebsite" class="form-control w-80 bg-gray-100 rounded px-2 py-1">
|
||||
{% for items in packageList %}
|
||||
<option>{{ items }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div ng-hide="installationDetailsForm" class="flex py-2 px-6">
|
||||
<div>
|
||||
<p class="font-semibold w-48">Select Owner</p>
|
||||
</div>
|
||||
<div>
|
||||
<select ng-model="websiteOwner" class="form-control w-80 bg-gray-100 rounded px-2 py-1">
|
||||
{% for items in owernList %}
|
||||
<option>{{ items }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div ng-hide="installationDetailsForm" class="flex py-2 px-6">
|
||||
<div>
|
||||
<p class="font-semibold w-48">Title</p>
|
||||
</div>
|
||||
<div>
|
||||
<input type="text" name="WPtitle" class="form-control w-80 bg-gray-100 rounded px-2 py-1"
|
||||
ng-model="WPtitle" required>
|
||||
</div>
|
||||
</div>
|
||||
<div ng-hide="installationDetailsForm" class="flex py-2 px-6">
|
||||
<div>
|
||||
<p class="font-semibold w-48">Domain Name</p>
|
||||
</div>
|
||||
<div>
|
||||
<input name="dom" type="text" class="form-control w-80 bg-gray-100 rounded px-2 py-1"
|
||||
ng-model="domainNameCreate"
|
||||
placeholder="{% trans "Do not enter WWW, it will be auto created!" %}" required>
|
||||
</div>
|
||||
</div>
|
||||
<div ng-hide="installationDetailsForm" class="flex py-2 px-6">
|
||||
<div class="w-48">
|
||||
<p class="font-semibold w-48">Additional Features</p></label>
|
||||
</div>
|
||||
<div class="text-gray-500 font-semibold">
|
||||
<label class="col-sm-3 control-label"></label>
|
||||
<div class="col-sm-9">
|
||||
<div class="checkbox">
|
||||
<label>
|
||||
{% if test_domain_data %}
|
||||
<input ng-model="apacheBackend" type="checkbox" value="">
|
||||
OpenLiteSpeed + Apache (Backend) (For Ubuntu 22 and AlmaLinux 8)
|
||||
{% else %}
|
||||
|
||||
<input ng-model="apacheBackend" type="checkbox" value="" disabled>
|
||||
OpenLiteSpeed + Apache (Backend) (For Ubuntu 22 and AlmaLinux 8) -
|
||||
<strong><a href="https://go.cyberpanel.net/ApacheRev">Premium Feature</a> <i
|
||||
class="p fa fa-external-link btn-icon"> </i></strong>
|
||||
{% endif %}
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div ng-hide="installationDetailsForm" class="flex py-2 px-6">
|
||||
<div>
|
||||
<p class="font-semibold w-48">Username</p>
|
||||
</div>
|
||||
<div>
|
||||
<input name="Username" type="text" class="form-control w-80 bg-gray-100 rounded px-2 py-1"
|
||||
ng-model="WPUsername"
|
||||
required>
|
||||
</div>
|
||||
</div>
|
||||
<div ng-hide="installationDetailsForm" class="flex py-2 px-6">
|
||||
<div>
|
||||
<p class="font-semibold w-48">Email</p>
|
||||
</div>
|
||||
<div>
|
||||
<input type="email" name="email" class="form-control w-80 bg-gray-100 rounded px-2 py-1"
|
||||
ng-model="adminEmail" required>
|
||||
</div>
|
||||
</div>
|
||||
<div ng-hide="installationDetailsForm" class="flex py-2 px-6">
|
||||
<div>
|
||||
<p class="font-semibold w-48">Select WP Version</p>
|
||||
</div>
|
||||
<div>
|
||||
<select ng-model="WPVersions" class="form-control w-80 bg-gray-100 rounded px-2 py-1">
|
||||
{% for wp in WPVersions %}
|
||||
<option>{{ wp }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div ng-hide="installationDetailsForm" class="flex py-2 px-6">
|
||||
<div>
|
||||
<p class="font-semibold w-48">Plugin/Theme</p>
|
||||
</div>
|
||||
<div>
|
||||
<select ng-model="pluginbucket" class="form-control w-80 bg-gray-100 rounded px-2 py-1">
|
||||
<option value="-1" selected>Select Plugin Bucket</option>
|
||||
{% for wp in Plugins %}
|
||||
<option value="{{ wp.id }}">{{ wp.Name }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div ng-hide="installationDetailsForm" class="flex py-2 px-6">
|
||||
<div>
|
||||
<p class="font-semibold w-48">Automatic Updates</p>
|
||||
</div>
|
||||
<div>
|
||||
<select ng-model="autoupdates" class="form-control w-80 bg-gray-100 rounded px-2 py-1">
|
||||
<option>Disabled</option>
|
||||
<option>All minor and major</option>
|
||||
<option>Minor and Security Updates</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div ng-hide="installationDetailsForm" class="flex py-2 px-6">
|
||||
<div>
|
||||
<p class="font-semibold w-48">Plugin Updates</p>
|
||||
</div>
|
||||
<div>
|
||||
<select ng-model="pluginupdates" class="form-control w-80 bg-gray-100 rounded px-2 py-1">
|
||||
|
||||
<option>Enabled</option>
|
||||
<option>Disabled</option>
|
||||
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div ng-hide="installationDetailsForm" class="flex py-2 px-6">
|
||||
<div>
|
||||
<p class="font-semibold w-48">Theme Updates</p>
|
||||
</div>
|
||||
<div>
|
||||
<select ng-model="themeupdates" class="form-control w-80 bg-gray-100 rounded px-2 py-1">
|
||||
<option>Enabled</option>
|
||||
<option>Disabled</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div ng-hide="installationDetailsForm" class="flex justify-center mt-3">
|
||||
<button ng-click="createWordPresssite()"
|
||||
class="bg-orange-500 px-3 py-4 rounded-lg text-xl font-semibold text-white">
|
||||
Create Website
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
{% endblock %}
|
||||
@@ -0,0 +1,42 @@
|
||||
{% extends "baseTemplate/newBase.html" %}
|
||||
{% load i18n %}
|
||||
{% block titleNew %}{% trans "Home - CyberPanel" %}{% endblock %}
|
||||
{% block newContent %}
|
||||
|
||||
{% load static %}
|
||||
|
||||
<div ng-controller="deleteWebsiteControlV2" class="p-8">
|
||||
<div>
|
||||
<p class="text-4xl font-bold">Delete Website</p>
|
||||
<p class="text-xs text-gray-600 py-2 font-semibold">This page can be used to delete website, once deleted it
|
||||
can not be recovered.</p>
|
||||
</div>
|
||||
<div>
|
||||
<div class="py-4">
|
||||
<p class="text-xl font-bold">Delete Website</p>
|
||||
</div>
|
||||
<hr>
|
||||
<div>
|
||||
<div class="flex mt-4 py-2 px-6">
|
||||
<div>
|
||||
<p class="font-semibold w-60">Select Website</p>
|
||||
</div>
|
||||
<div>
|
||||
<select ng-change="fetchDetails()" ng-model="websiteToBeDeleted"
|
||||
class="form-control w-80 bg-gray-100 rounded px-2 py-1">
|
||||
{% for items in websiteList %}
|
||||
<option>{{ items }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="flex justify-center mt-4">
|
||||
<button ng-click="deleteWebsite()"
|
||||
class="bg-orange-500 px-3 py-4 rounded-lg text-xl font-semibold text-white">
|
||||
Delete Website
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
{% endblock %}
|
||||
@@ -135,7 +135,7 @@
|
||||
data-placement="right"
|
||||
title="Convert to Website"> </i>
|
||||
<span><a data-toggle="modal" data-target="#settings" href=""
|
||||
style="text-transform: none" ng-click="initConvert(web.domain)">Convert to Website</a></span>
|
||||
style="text-transform: none" >Convert to Website</a></span>
|
||||
<div id="settings" class="modal fade" role="dialog">
|
||||
<div class="modal-dialog">
|
||||
|
||||
|
||||
@@ -40,238 +40,205 @@
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div ng-repeat="web in WebSitesList track by $index" class="panel col-md-12"
|
||||
style="padding: 0px; box-shadow: 0px 0px 1px 0px #888888;">
|
||||
<div class="">
|
||||
<div class="table-responsive no-gutter text-nowrap" style="overflow-x: hidden;">
|
||||
|
||||
<div style="border-bottom: 1px solid #888888" class="col-md-12">
|
||||
<div class="col-lg-10 content-box-header" style="text-transform: none;">
|
||||
<a href="http://{$ web.domain $}" target="_blank" title="Visit Site">
|
||||
<h2 style="display: inline; color: #414C59;" ng-bind="web.domain"></h2>
|
||||
</a>
|
||||
<a target="_blank" href="/filemanager/{$ web.masterDomain $}" title="Open File Manager">
|
||||
--
|
||||
File Manager</a>
|
||||
</div>
|
||||
<div class="col-md-2 content-box-header" style="text-transform: none;">
|
||||
<a href="/websites/{$ web.masterDomain $}/{$ web.domain $}" target="_blank"
|
||||
title="Manage Website">
|
||||
<i class="p fa fa-external-link btn-icon"> </i>
|
||||
<span>Manage</span>
|
||||
</a>
|
||||
</div>
|
||||
|
||||
<div class="py-8">
|
||||
<div class="border shadow-lg rounded-lg px-3">
|
||||
<div ng-repeat="web in WebSitesList track by $index" class="px-2">
|
||||
<div class="bg-gray-200 mt-6 w-full rounded-t-lg border-b-2 border-gray-400">
|
||||
<p class="font-bold px-4 py-1" ng-bind="web.domain"></p>
|
||||
</div>
|
||||
<div class="py-3 mb-3 rounded-b-lg border-b-2 border-gray-400 overflow-x-auto">
|
||||
<table>
|
||||
<tbody>
|
||||
<div>
|
||||
<tr>
|
||||
<th class="w-32 pt-2">
|
||||
<a href="/websites/{$ web.masterDomain $}/{$ web.domain $}"
|
||||
class="flex items-center ml-3">
|
||||
<svg width="20" height="20" viewBox="0 0 30 30" fill="none"
|
||||
xmlns="http://www.w3.org/2000/svg">
|
||||
<path
|
||||
d="M22.5 16.25V23.75C22.5 24.413 22.2366 25.0489 21.7678 25.5178C21.2989 25.9866 20.663 26.25 20 26.25H6.25C5.58696 26.25 4.95107 25.9866 4.48223 25.5178C4.01339 25.0489 3.75 24.413 3.75 23.75V10C3.75 9.33696 4.01339 8.70107 4.48223 8.23223C4.95107 7.76339 5.58696 7.5 6.25 7.5H13.75"
|
||||
stroke="#3A6A7E" stroke-width="2" stroke-linecap="round"
|
||||
stroke-linejoin="round"/>
|
||||
<path d="M18.75 3.75H26.25V11.25" stroke="#3A6A7E" stroke-width="2"
|
||||
stroke-linecap="round"
|
||||
stroke-linejoin="round"/>
|
||||
<path d="M12.5 17.5L26.25 3.75" stroke="#3A6A7E" stroke-width="2"
|
||||
stroke-linecap="round"
|
||||
stroke-linejoin="round"/>
|
||||
</svg>
|
||||
<p class="ml-2 text-blue-600 font-semibold">Manage</p>
|
||||
</a>
|
||||
</th>
|
||||
<th ng-click="initConvert(web.domain)"
|
||||
class="w-36 pt-2 font-semibold text-green-700 text-sm">
|
||||
<div class="col-md-4 content-box-header">
|
||||
<i class="p fa fa-arrows-h btn-icon text-muted" data-toggle="tooltip"
|
||||
data-placement="right" title="Convert to Website"> </i>
|
||||
<span>
|
||||
<a onclick="openModal()" href="#" style="text-transform: none">Convert to Website</a>
|
||||
</span>
|
||||
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-4 content-box-header">
|
||||
<i class="p fa fa-trash-o btn-icon text-muted" data-toggle="tooltip"
|
||||
data-placement="right"
|
||||
title="Delete Child Domain"> </i>
|
||||
<span><a ng-click='deleteDomainInit(web.domain)' data-toggle="modal"
|
||||
data-target="#DeleteChild" href=""
|
||||
style="text-transform: none">Delete</a></span>
|
||||
<div id="DeleteChild" class="modal fade" role="dialog">
|
||||
<div class="modal-dialog">
|
||||
<!-- Modal content-->
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal">×
|
||||
</button>
|
||||
<h4 class="modal-title">Delete Child Domain
|
||||
<img ng-hide="$parent.cyberPanelLoading"
|
||||
src="/static/images/loading.gif"
|
||||
style="display: none;">
|
||||
</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<form name="DeleteDocumentRootForm" action="/" class="form-horizontal">
|
||||
|
||||
<div ng-hide="installationDetailsForm" class="form-group">
|
||||
<label class="col-sm-2 control-label">{% trans "" %}</label>
|
||||
<div class="col-sm-8">
|
||||
<input ng-model="$parent.DeleteDocRoot" type="checkbox"
|
||||
value="">
|
||||
Delete Document Root
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-primary"
|
||||
ng-click="deleteChildDomain()">Delete Now
|
||||
</button>
|
||||
<button type="button" ng-disabled="savingSettings"
|
||||
class="btn btn-default" data-dismiss="modal">
|
||||
Close
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4 content-box-header">
|
||||
<i class="p fa fa-map-marker btn-icon text-muted" data-toggle="tooltip"
|
||||
data-placement="right" title="IP Address"> </i>
|
||||
<span ng-bind="web.ipAddress"></span>
|
||||
</div>
|
||||
<div class="col-md-4 content-box-header">
|
||||
<i class="p fa fa-lock btn-icon text-muted" data-toggle="tooltip" data-placement="right"
|
||||
title="SSL"> </i>
|
||||
<span><a ng-click="issueSSL(web.domain)" href=""
|
||||
style="text-transform: none">Issue SSL</a></span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-4 content-box-header">
|
||||
<i class="p fa fa-cubes btn-icon text-muted" data-toggle="tooltip"
|
||||
data-placement="right"
|
||||
title="Packages"> </i>
|
||||
<span ng-bind="web.package" style="text-transform: none"></span>
|
||||
</div>
|
||||
<div class="col-md-4 content-box-header">
|
||||
<i class="p fa fa-user btn-icon text-muted" data-toggle="tooltip" data-placement="right"
|
||||
title="Owner"> </i>
|
||||
<span ng-bind="web.admin" style="text-transform: none"></span>
|
||||
</div>
|
||||
<div class="col-md-4 content-box-header">
|
||||
<i class="p fa fa-arrows-h btn-icon text-muted" data-toggle="tooltip"
|
||||
data-placement="right"
|
||||
title="Convert to Website"> </i>
|
||||
<span><a data-toggle="modal" data-target="#settings" href=""
|
||||
style="text-transform: none"
|
||||
ng-click="initConvert(web.domain)">Convert to Website</a></span>
|
||||
<div id="settings" class="modal fade" role="dialog">
|
||||
<div class="modal-dialog">
|
||||
|
||||
<!-- Modal content-->
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal">×
|
||||
</button>
|
||||
<h4 class="modal-title">Convert Child Domain to normal Website
|
||||
<img ng-hide="$parent.cyberPanelLoading"
|
||||
src="/static/images/loading.gif"
|
||||
style="display: none;">
|
||||
</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
|
||||
<form name="containerSettingsForm" action="/" class="form-horizontal">
|
||||
|
||||
<div ng-hide="installationDetailsForm" class="form-group">
|
||||
<label class="col-sm-3 control-label">{% trans "Domain Name" %}</label>
|
||||
<div class="col-sm-6">
|
||||
<input name="dom" type="text" class="form-control"
|
||||
ng-model="domainName"
|
||||
placeholder="{% trans "Do not enter WWW, it will be auto created!" %}"
|
||||
readonly>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div ng-hide="installationDetailsForm" class="form-group">
|
||||
<label class="col-sm-3 control-label">{% trans "Select Owner" %}</label>
|
||||
<div class="col-sm-6">
|
||||
<select ng-model="$parent.websiteOwner"
|
||||
class="form-control">
|
||||
{% for items in owernList %}
|
||||
<option>{{ items }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<hr ng-hide="installationDetailsForm">
|
||||
|
||||
<div ng-hide="installationDetailsForm" class="form-group">
|
||||
<label class="col-sm-3 control-label">{% trans "Select Package" %}</label>
|
||||
<div class="col-sm-6">
|
||||
<select ng-model="$parent.packageForWebsite"
|
||||
class="form-control">
|
||||
{% for items in packageList %}
|
||||
<option>{{ items }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<hr ng-hide="installationDetailsForm">
|
||||
<div ng-hide="installationDetailsForm" class="form-group">
|
||||
<label class="col-sm-3 control-label">{% trans "Email" %}</label>
|
||||
<div class="col-sm-6">
|
||||
<input type="email" name="email" class="form-control"
|
||||
ng-model="$parent.adminEmail" required>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<hr ng-hide="installationDetailsForm">
|
||||
<div ng-hide="installationDetailsForm" class="form-group">
|
||||
<label class="col-sm-3 control-label">{% trans "Select PHP" %}</label>
|
||||
<div class="col-sm-6">
|
||||
<select ng-model="$parent.phpSelection"
|
||||
class="form-control">
|
||||
{% for php in phps %}
|
||||
<option>{{ php }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div ng-hide="installationProgress" class="form-group">
|
||||
<label class="col-sm-1 control-label"></label>
|
||||
<div class="col-sm-10">
|
||||
|
||||
<div class="alert alert-success text-center">
|
||||
<h2>{$ currentStatus $}</h2>
|
||||
</div>
|
||||
|
||||
<div class="progress">
|
||||
<div id="installProgress" class="progress-bar"
|
||||
role="progressbar" aria-valuenow="70"
|
||||
aria-valuemin="0" aria-valuemax="100"
|
||||
style="width:0%">
|
||||
<span class="sr-only">70% Complete</span>
|
||||
<!-- Modal -->
|
||||
<div id="modal"
|
||||
class="fixed inset-0 overflow-auto bg-black bg-opacity-50 hidden flex items-center justify-center">
|
||||
<div class="bg-white p-8 rounded shadow-lg w-full md:w-1/2">
|
||||
<button onclick="closeModal()"
|
||||
class="absolute top-4 right-4 text-gray-700 hover:text-gray-900">
|
||||
<i class="fa fa-times"></i>
|
||||
</button>
|
||||
<h1 class="text-2xl font-bold mb-4 text-black">Convert Child Domain
|
||||
to Normal
|
||||
Website
|
||||
</h1>
|
||||
<form name="containerSettingsForm" action="/" class="mb-4">
|
||||
<div>
|
||||
<div ng-hide="installationDetailsForm"
|
||||
class="flex py-2 px-6">
|
||||
<div>
|
||||
<p class="font-semibold w-48">Domain Name</p>
|
||||
</div>
|
||||
<div>
|
||||
<input name="dom" type="text"
|
||||
class="form-control w-80 bg-gray-100 rounded px-2 py-1"
|
||||
ng-model="domainName"
|
||||
placeholder="{% trans "Do not enter WWW, it will be auto created!" %}"
|
||||
readonly>
|
||||
</div>
|
||||
</div>
|
||||
<div ng-hide="installationDetailsForm"
|
||||
class="flex py-2 px-6">
|
||||
<div>
|
||||
<p class="font-semibold w-48">Select Owner</p>
|
||||
</div>
|
||||
<div>
|
||||
<select ng-model="$parent.websiteOwner"
|
||||
class="form-control w-80 bg-gray-100 rounded px-2 py-1">
|
||||
{% for items in owernList %}
|
||||
<option>{{ items }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div ng-hide="installationDetailsForm"
|
||||
class="flex mt-4 py-2 px-6">
|
||||
<div>
|
||||
<p class="font-semibold w-48">Select Package</p>
|
||||
</div>
|
||||
<div>
|
||||
<select ng-model="$parent.packageForWebsite"
|
||||
class="form-control w-80 bg-gray-100 rounded px-2 py-1">
|
||||
{% for items in packageList %}
|
||||
<option>{{ items }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div ng-hide="installationDetailsForm"
|
||||
class="flex py-2 px-6">
|
||||
<div>
|
||||
<p class="font-semibold w-48">Email</p>
|
||||
</div>
|
||||
<div>
|
||||
<input type="email" name="email"
|
||||
class="form-control w-80 bg-gray-100 rounded px-2 py-1"
|
||||
ng-model="$parent.adminEmail" required>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div ng-hide="installationDetailsForm" class="flex py-2 px-6">
|
||||
<div>
|
||||
<p class="font-semibold w-48">Select PHP</p>
|
||||
</div>
|
||||
<div>
|
||||
<select ng-model="$parent.phpSelection"
|
||||
class="form-control w-80 bg-gray-100 rounded px-2 py-1">
|
||||
{% for php in phps %}
|
||||
<option>{{ php }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="flex justify-end mt-3">
|
||||
<button ng-click="convert()"
|
||||
class="bg-blue-500 hover:bg-blue-700 text-white font-bold py-2 px-4 rounded">
|
||||
Convert
|
||||
</button>
|
||||
<button onclick="closeModal()"
|
||||
class="ml-2 bg-gray-300 hover:bg-gray-400 text-gray-800 font-bold py-2 px-4 rounded">
|
||||
Close
|
||||
</button>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</th>
|
||||
<th class="w-32 pt-2 font-semibold text-sm"><span ng-bind="web.admin"
|
||||
style="text-transform: none"></span>
|
||||
</th>
|
||||
<th class="w-32 pt-2 font-semibold text-sm"><span ng-bind="web.ipAddress"></span>
|
||||
</th>
|
||||
<th class="w-32 pt-2 font-semibold text-sm"><span ng-bind="web.package"
|
||||
style="text-transform: none"></span>
|
||||
</th>
|
||||
<th class="w-32 pt-2 font-semibold text-sm"><span><a ng-click="issueSSL(web.domain)"
|
||||
href=""
|
||||
style="text-transform: none">Issue SSL</a></span>
|
||||
</th>
|
||||
<th class="w-32 pt-2 font-semibold text-red-700 text-sm">
|
||||
<div class="col-md-4 content-box-header">
|
||||
<i class="p fa fa-arrows-h btn-icon text-muted" data-toggle="tooltip"
|
||||
data-placement="right" title="Delete"> </i>
|
||||
<span>
|
||||
<a onclick="openModal()" href="#" style="text-transform: none">Delete</a>
|
||||
|
||||
<!-- Modal -->
|
||||
<div id="modal"
|
||||
class="fixed inset-0 z-50 hidden overflow-auto bg-black bg-opacity-50">
|
||||
<div class="flex items-center justify-center h-full">
|
||||
<div class="bg-white p-8 rounded shadow-lg">
|
||||
<button onclick="closeModal()"
|
||||
class="absolute top-4 right-4 text-gray-700 hover:text-gray-900">
|
||||
<i class="fa fa-times"></i>
|
||||
</button>
|
||||
<h1 class="text-2xl font-bold mb-4">Delete Child Domain</h1>
|
||||
<form class="mb-4">
|
||||
<!-- Your form content here -->
|
||||
<div class="mb-4">
|
||||
<input type="checkbox" id="deleteDocRoot"
|
||||
name="deleteDocRoot" class="mr-2">
|
||||
<label for="deleteDocRoot">Delete Document Root</label>
|
||||
</div>
|
||||
</form>
|
||||
<div class="flex justify-end">
|
||||
<button ng-click="deleteChildDomain()"
|
||||
class="bg-red-500 hover:bg-red-700 text-white font-bold py-2 px-4 rounded">
|
||||
Delete Now
|
||||
</button>
|
||||
<button onclick="closeModal()"
|
||||
class="ml-2 bg-gray-300 hover:bg-gray-400 text-gray-800 font-bold py-2 px-4 rounded">
|
||||
Close
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div ng-hide="installationProgress" class="form-group">
|
||||
<label class="col-sm-3 control-label"></label>
|
||||
<div class="col-sm-4">
|
||||
<button type="button" ng-disabled="goBackDisable"
|
||||
ng-click="goBack()"
|
||||
class="btn btn-primary btn-lg">{% trans "Go Back" %}</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</form>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-primary"
|
||||
ng-click="convert()">Convert
|
||||
</button>
|
||||
<button type="button" ng-disabled="savingSettings"
|
||||
class="btn btn-default" data-dismiss="modal">
|
||||
Close
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</th>
|
||||
</tr>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="listFail" class="alert alert-danger">
|
||||
<p>{% trans "Cannot list websites. Error message:" %} {$ errorMessage $}</p>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="flex justify-end mt-4">
|
||||
<select ng-model="currentPage" ng-change="getFurtherWebsitesFromDB()"
|
||||
class="w-36 bg-gray-200 py-3 px-2 rounded" id="example-select">
|
||||
|
||||
@@ -48,53 +48,65 @@
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div ng-repeat="web in WebSitesList track by $index" class="py-8">
|
||||
<div class="py-8">
|
||||
<div class="border shadow-lg rounded-lg px-3">
|
||||
<div>
|
||||
<div class="px-2">
|
||||
<div class="pl-44 gap-20 py-5 flex font-bold">
|
||||
<div>Owner</div>
|
||||
<div>IP Address</div>
|
||||
<div>Disk Usage</div>
|
||||
<div>Package</div>
|
||||
<div>SSL</div>
|
||||
<div class="pl-4">State</div>
|
||||
</div>
|
||||
<div ng-repeat="web in WebSitesList track by $index" class="px-2">
|
||||
<div class="bg-gray-200 mt-6 w-full rounded-t-lg border-b-2 border-gray-400">
|
||||
<p class="font-bold px-4 py-1" ng-bind="web.domain"></p>
|
||||
</div>
|
||||
<div class="px-2">
|
||||
<div class="bg-gray-200 w-full rounded-t-lg border-b-2 border-gray-400">
|
||||
<p class="font-bold px-4 py-1" ng-bind="web.domain"></p>
|
||||
</div>
|
||||
<div class="w-full rounded-b-lg border-b-2 border-gray-400">
|
||||
<div class="pl-4 py-5 gap-20 flex items-center text-sm">
|
||||
<a href="/websites/{$ web.domain $}" class="flex items-center">
|
||||
<svg width="25" height="25" viewBox="0 0 30 30" fill="none"
|
||||
xmlns="http://www.w3.org/2000/svg">
|
||||
<path
|
||||
d="M22.5 16.25V23.75C22.5 24.413 22.2366 25.0489 21.7678 25.5178C21.2989 25.9866 20.663 26.25 20 26.25H6.25C5.58696 26.25 4.95107 25.9866 4.48223 25.5178C4.01339 25.0489 3.75 24.413 3.75 23.75V10C3.75 9.33696 4.01339 8.70107 4.48223 8.23223C4.95107 7.76339 5.58696 7.5 6.25 7.5H13.75"
|
||||
stroke="#3A6A7E" stroke-width="2" stroke-linecap="round"
|
||||
stroke-linejoin="round"/>
|
||||
<path d="M18.75 3.75H26.25V11.25" stroke="#3A6A7E" stroke-width="2"
|
||||
stroke-linecap="round"
|
||||
stroke-linejoin="round"/>
|
||||
<path d="M12.5 17.5L26.25 3.75" stroke="#3A6A7E" stroke-width="2"
|
||||
stroke-linecap="round"
|
||||
stroke-linejoin="round"/>
|
||||
</svg>
|
||||
<p class="ml-2 text-blue-600 font-semibold">Manage</p>
|
||||
</a>
|
||||
<div><span ng-bind="web.admin" style="text-transform: none"></span></div>
|
||||
<div><span ng-bind="web.ipAddress"></span></div>
|
||||
<div class="pl-3"><span ng-bind="web.diskUsed" style="text-transform: none"></span>
|
||||
</div>
|
||||
<div class="pl-7"><span ng-bind="web.package" style="text-transform: none"></span></div>
|
||||
<div> <span><a ng-click="issueSSL(web.domain)" href=""
|
||||
style="text-transform: none">Issue SSL</a></span></div>
|
||||
<div class="text-green-700 font-bold"><span ng-bind="web.state"
|
||||
style="text-transform: none"></span></div>
|
||||
<div class="py-3 mb-3 rounded-b-lg border-b-2 border-gray-400 overflow-x-auto">
|
||||
<table>
|
||||
<thead>
|
||||
<div>
|
||||
<tr>
|
||||
<th class="w-32"></th>
|
||||
<th class="w-32">Owner</th>
|
||||
<th class="w-32">IP Address</th>
|
||||
<th class="w-32">Disk Usage</th>
|
||||
<th class="w-32">Package</th>
|
||||
<th class="w-32">SSL</th>
|
||||
<th class="w-32">State</th>
|
||||
</tr>
|
||||
</div>
|
||||
</div>
|
||||
</thead>
|
||||
<tbody>
|
||||
<div>
|
||||
<tr>
|
||||
<th class="w-32 pt-2">
|
||||
<a href="/websites/{$ web.domain $}" class="flex items-center ml-3">
|
||||
<svg width="20" height="20" viewBox="0 0 30 30" fill="none"
|
||||
xmlns="http://www.w3.org/2000/svg">
|
||||
<path
|
||||
d="M22.5 16.25V23.75C22.5 24.413 22.2366 25.0489 21.7678 25.5178C21.2989 25.9866 20.663 26.25 20 26.25H6.25C5.58696 26.25 4.95107 25.9866 4.48223 25.5178C4.01339 25.0489 3.75 24.413 3.75 23.75V10C3.75 9.33696 4.01339 8.70107 4.48223 8.23223C4.95107 7.76339 5.58696 7.5 6.25 7.5H13.75"
|
||||
stroke="#3A6A7E" stroke-width="2" stroke-linecap="round"
|
||||
stroke-linejoin="round"/>
|
||||
<path d="M18.75 3.75H26.25V11.25" stroke="#3A6A7E" stroke-width="2"
|
||||
stroke-linecap="round"
|
||||
stroke-linejoin="round"/>
|
||||
<path d="M12.5 17.5L26.25 3.75" stroke="#3A6A7E" stroke-width="2"
|
||||
stroke-linecap="round"
|
||||
stroke-linejoin="round"/>
|
||||
</svg>
|
||||
<p class="ml-2 text-blue-600 font-semibold">Manage</p>
|
||||
</a>
|
||||
</th>
|
||||
<th class="w-32 pt-2 font-semibold text-sm"><span ng-bind="web.admin"
|
||||
style="text-transform: none"></span></th>
|
||||
<th class="w-32 pt-2 font-semibold text-sm"><span ng-bind="web.ipAddress"></span></th>
|
||||
<th class="w-32 pt-2 font-semibold text-sm"><span ng-bind="web.diskUsed"
|
||||
style="text-transform: none"></span></th>
|
||||
<th class="w-32 pt-2 font-semibold text-sm"><span ng-bind="web.package"
|
||||
style="text-transform: none"></span></th>
|
||||
<th class="w-32 pt-2 font-semibold text-sm"><span><a ng-click="issueSSL(web.domain)" href=""
|
||||
style="text-transform: none">Issue SSL</a></span>
|
||||
</th>
|
||||
<th class="w-32 pt-2 font-semibold text-green-700 text-sm"><span ng-bind="web.state"
|
||||
style="text-transform: none"></span>
|
||||
</th>
|
||||
</tr>
|
||||
</div>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -0,0 +1,85 @@
|
||||
{% extends "baseTemplate/newBase.html" %}
|
||||
{% load i18n %}
|
||||
{% block titleNew %}{% trans "Home - CyberPanel" %}{% endblock %}
|
||||
{% block newContent %}
|
||||
|
||||
{% load static %}
|
||||
|
||||
<div ng-controller="modifyWebsitesControllerV2" class="p-8">
|
||||
<div>
|
||||
<p class="text-4xl font-bold">Modify Website</p>
|
||||
<p class="text-xs text-gray-600 py-2 font-semibold">Packages define resources for your websites, you need to
|
||||
add package before creating a website.</p>
|
||||
</div>
|
||||
<div>
|
||||
<div class="py-4">
|
||||
<p class="text-xl font-bold">Modify Website</p>
|
||||
</div>
|
||||
<hr>
|
||||
<div>
|
||||
<div class="flex mt-4 py-2 px-6">
|
||||
<div>
|
||||
<p class="font-semibold w-60">Select Website</p>
|
||||
</div>
|
||||
<div>
|
||||
<select ng-change="fetchWebsites()" ng-model="websiteToBeModified"
|
||||
class="form-control w-80 bg-gray-100 rounded px-2 py-1">
|
||||
{% for items in websiteList %}
|
||||
<option>{{ items }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div id="webSiteDetailsToBeModified">
|
||||
<div class="flex py-2 px-6">
|
||||
<div>
|
||||
<p class="font-semibold w-60">Select Package</p>
|
||||
</div>
|
||||
<div>
|
||||
<select ng-model="selectedPack" class="form-control w-80 bg-gray-100 rounded px-2 py-1">
|
||||
<option ng-repeat="pack in webpacks">{$ pack.pack $}</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="flex py-2 px-6">
|
||||
<div>
|
||||
<p class="font-semibold w-60">Select Owner</p>
|
||||
</div>
|
||||
<div>
|
||||
<select ng-model="selectedAdmin" class="form-control w-80 bg-gray-100 rounded px-2 py-1">
|
||||
<option ng-repeat="admins in adminNames">{$ admins.adminNames $}</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="flex py-2 px-6">
|
||||
<div>
|
||||
<p class="font-semibold w-60">Email</p>
|
||||
</div>
|
||||
<div>
|
||||
<input type="email" class="form-control w-80 bg-gray-100 rounded px-2 py-1"
|
||||
ng-model="adminEmail" required>
|
||||
</div>
|
||||
</div>
|
||||
<div class="flex py-2 px-6">
|
||||
<div>
|
||||
<p class="font-semibold w-60">Select PHP</p>
|
||||
</div>
|
||||
<div>
|
||||
<select ng-model="phpSelection" class="form-control w-80 bg-gray-100 rounded px-2 py-1">
|
||||
{% for php in phps %}
|
||||
<option>{{ php }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="flex justify-center mt-4">
|
||||
<button id="modifyWebsiteButton" ng-click="modifyWebsiteFunc()"
|
||||
class="bg-orange-500 px-3 py-4 rounded-lg text-xl font-semibold text-white">
|
||||
Modify Website
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
{% endblock %}
|
||||
@@ -0,0 +1,52 @@
|
||||
{% extends "baseTemplate/newBase.html" %}
|
||||
{% load i18n %}
|
||||
{% block titleNew %}{% trans "Home - CyberPanel" %}{% endblock %}
|
||||
{% block newContent %}
|
||||
|
||||
{% load static %}
|
||||
|
||||
<div ng-controller="suspendWebsiteControlV2" class="p-8">
|
||||
<div>
|
||||
<p class="text-4xl font-bold">Suspend/Unsuspend Website</p>
|
||||
<p class="text-xs text-gray-600 py-2 font-semibold">This page can be used to suspend/unsuspend website</p>
|
||||
</div>
|
||||
<div>
|
||||
<div class="py-4">
|
||||
<p class="text-xl font-bold">Suspend/Unsuspend Website</p>
|
||||
</div>
|
||||
<hr>
|
||||
<div>
|
||||
<div class="flex mt-4 py-2 px-6">
|
||||
<div>
|
||||
<p class="font-semibold w-60">Select Website</p>
|
||||
</div>
|
||||
<div>
|
||||
<select ng-change="showSuspendUnsuspend()" ng-model="websiteToBeSuspended"
|
||||
class="form-control w-80 bg-gray-100 rounded px-2 py-1">
|
||||
{% for items in websiteList %}
|
||||
<option>{{ items }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="flex mt-4 py-2 px-6">
|
||||
<div>
|
||||
<p class="font-semibold w-60">Suspend/Unsuspend Website</p>
|
||||
</div>
|
||||
<div>
|
||||
<select ng-model="state" class="form-control w-80 bg-gray-100 rounded px-2 py-1">
|
||||
<option>{% trans "Suspend" %}</option>
|
||||
<option>{% trans "Un-Suspend" %}</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="flex justify-center mt-4">
|
||||
<button ng-click="save()"
|
||||
class="bg-orange-500 px-3 py-4 rounded-lg text-xl font-semibold text-white">
|
||||
Save
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
{% endblock %}
|
||||
@@ -8,8 +8,11 @@ urlpatterns = [
|
||||
url(r'^listChildDomains$', views.listChildDomains, name='listChildDomains'),
|
||||
url(r'^listChildDomainsV2$', views.listChildDomainsV2, name='listChildDomainsV2'),
|
||||
url(r'^modifyWebsite$', views.modifyWebsite, name='modifyWebsite'),
|
||||
url(r'^modifyWebsiteV2$', views.modifyWebsiteV2, name='modifyWebsiteV2'),
|
||||
url(r'^deleteWebsite$', views.deleteWebsite, name='deleteWebsite'),
|
||||
url(r'^deleteWebsiteV2$', views.deleteWebsiteV2, name='deleteWebsiteV2'),
|
||||
url(r'^siteState$', views.siteState, name='siteState'),
|
||||
url(r'^siteStateV2$', views.siteStateV2, name='siteStateV2'),
|
||||
url(r'^createWebsiteV2$', views.createWebsiteV2, name='createWebsiteV2'),
|
||||
url(r'^listWebsitesV2$', views.listWebsitesV2, name='listWebsitesV2'),
|
||||
|
||||
@@ -19,6 +22,7 @@ urlpatterns = [
|
||||
|
||||
### WordPress
|
||||
url(r'^createWordpress$', views.WPCreate, name='createWordpress'),
|
||||
url(r'^createWordpressV2$', views.WPCreateV2, name='createWordpressV2'),
|
||||
url(r'^ListWPSites$', views.ListWPSites, name='ListWPSites'),
|
||||
url(r'^WPHome$', views.WPHome, name='WPHome'),
|
||||
url(r'^RestoreBackups$', views.RestoreBackups, name='RestoreBackups'),
|
||||
|
||||
@@ -49,6 +49,13 @@ def WPCreate(request):
|
||||
except KeyError:
|
||||
return redirect(loadLoginPage)
|
||||
|
||||
def WPCreateV2(request):
|
||||
try:
|
||||
userID = request.session['userID']
|
||||
wm = WebsiteManager()
|
||||
return wm.WPCreateV2(request, userID, )
|
||||
except KeyError:
|
||||
return redirect(loadLoginPage)
|
||||
|
||||
def ListWPSites(request):
|
||||
try:
|
||||
@@ -832,6 +839,17 @@ def modifyWebsite(request):
|
||||
except KeyError:
|
||||
return redirect(loadLoginPage)
|
||||
|
||||
def modifyWebsiteV2(request):
|
||||
try:
|
||||
userID = request.session['userID']
|
||||
wm = WebsiteManager()
|
||||
return wm.modifyWebsiteV2(request, userID)
|
||||
except BaseException as msg:
|
||||
return HttpResponse(str(msg))
|
||||
|
||||
except KeyError:
|
||||
return redirect(loadLoginPage)
|
||||
|
||||
|
||||
def deleteWebsite(request):
|
||||
try:
|
||||
@@ -841,7 +859,13 @@ def deleteWebsite(request):
|
||||
except KeyError:
|
||||
return redirect(loadLoginPage)
|
||||
|
||||
|
||||
def deleteWebsiteV2(request):
|
||||
try:
|
||||
userID = request.session['userID']
|
||||
wm = WebsiteManager()
|
||||
return wm.deleteWebsiteV2(request, userID)
|
||||
except KeyError:
|
||||
return redirect(loadLoginPage)
|
||||
def CreateNewDomain(request):
|
||||
try:
|
||||
userID = request.session['userID']
|
||||
@@ -866,6 +890,14 @@ def siteState(request):
|
||||
except KeyError:
|
||||
return redirect(loadLoginPage)
|
||||
|
||||
def siteStateV2(request):
|
||||
try:
|
||||
userID = request.session['userID']
|
||||
wm = WebsiteManager()
|
||||
return wm.siteStateV2(request, userID)
|
||||
except KeyError:
|
||||
return redirect(loadLoginPage)
|
||||
|
||||
|
||||
def listWebsites(request):
|
||||
try:
|
||||
|
||||
@@ -161,6 +161,54 @@ class WebsiteManager:
|
||||
from django.shortcuts import reverse
|
||||
return redirect(reverse('pricing'))
|
||||
|
||||
def WPCreateV2(self, request=None, userID=None, data=None):
|
||||
url = "https://platform.cyberpersons.com/CyberpanelAdOns/Adonpermission"
|
||||
data = {
|
||||
"name": "wp-manager",
|
||||
"IP": ACLManager.GetServerIP()
|
||||
}
|
||||
|
||||
import requests
|
||||
response = requests.post(url, data=json.dumps(data))
|
||||
Status = response.json()['status']
|
||||
|
||||
if (Status == 1) or ProcessUtilities.decideServer() == ProcessUtilities.ent:
|
||||
currentACL = ACLManager.loadedACL(userID)
|
||||
adminNames = ACLManager.loadAllUsers(userID)
|
||||
packagesName = ACLManager.loadPackages(userID, currentACL)
|
||||
FinalVersions = []
|
||||
userobj = Administrator.objects.get(pk=userID)
|
||||
counter = 0
|
||||
try:
|
||||
import requests
|
||||
WPVersions = json.loads(requests.get('https://api.wordpress.org/core/version-check/1.7/').text)[
|
||||
'offers']
|
||||
|
||||
for versions in WPVersions:
|
||||
if counter == 7:
|
||||
break
|
||||
if versions['current'] not in FinalVersions:
|
||||
FinalVersions.append(versions['current'])
|
||||
counter = counter + 1
|
||||
except:
|
||||
FinalVersions = ['5.6', '5.5.3', '5.5.2']
|
||||
|
||||
Plugins = wpplugins.objects.filter(owner=userobj)
|
||||
rnpss = randomPassword.generate_pass(10)
|
||||
|
||||
##
|
||||
|
||||
test_domain_status = 1
|
||||
|
||||
Data = {'packageList': packagesName, "owernList": adminNames, 'WPVersions': FinalVersions,
|
||||
'Plugins': Plugins, 'Randam_String': rnpss.lower(), 'test_domain_data': test_domain_status}
|
||||
proc = httpProc(request, 'websiteFunctions/WPCreateV2.html',
|
||||
Data, 'createWebsite')
|
||||
return proc.render()
|
||||
else:
|
||||
from django.shortcuts import reverse
|
||||
return redirect(reverse('pricing'))
|
||||
|
||||
def ListWPSites(self, request=None, userID=None, DeleteID=None):
|
||||
currentACL = ACLManager.loadedACL(userID)
|
||||
|
||||
@@ -716,6 +764,15 @@ class WebsiteManager:
|
||||
{'websiteList': websitesName, 'phps': phps}, 'modifyWebsite')
|
||||
return proc.render()
|
||||
|
||||
def modifyWebsiteV2(self, request=None, userID=None, data=None):
|
||||
currentACL = ACLManager.loadedACL(userID)
|
||||
|
||||
websitesName = ACLManager.findAllSites(currentACL, userID)
|
||||
phps = PHPManager.findPHPVersions()
|
||||
proc = httpProc(request, 'websiteFunctions/modifyWebsiteV2.html',
|
||||
{'websiteList': websitesName, 'phps': phps}, 'modifyWebsite')
|
||||
return proc.render()
|
||||
|
||||
def deleteWebsite(self, request=None, userID=None, data=None):
|
||||
currentACL = ACLManager.loadedACL(userID)
|
||||
websitesName = ACLManager.findAllSites(currentACL, userID)
|
||||
@@ -723,6 +780,13 @@ class WebsiteManager:
|
||||
{'websiteList': websitesName}, 'deleteWebsite')
|
||||
return proc.render()
|
||||
|
||||
def deleteWebsiteV2(self, request=None, userID=None, data=None):
|
||||
currentACL = ACLManager.loadedACL(userID)
|
||||
websitesName = ACLManager.findAllSites(currentACL, userID)
|
||||
proc = httpProc(request, 'websiteFunctions/deleteWebsiteV2.html',
|
||||
{'websiteList': websitesName}, 'deleteWebsite')
|
||||
return proc.render()
|
||||
|
||||
def CreateNewDomain(self, request=None, userID=None, data=None):
|
||||
currentACL = ACLManager.loadedACL(userID)
|
||||
websitesName = ACLManager.findAllSites(currentACL, userID)
|
||||
@@ -780,6 +844,15 @@ class WebsiteManager:
|
||||
{'websiteList': websitesName}, 'suspendWebsite')
|
||||
return proc.render()
|
||||
|
||||
def siteStateV2(self, request=None, userID=None, data=None):
|
||||
currentACL = ACLManager.loadedACL(userID)
|
||||
|
||||
websitesName = ACLManager.findAllSites(currentACL, userID)
|
||||
|
||||
proc = httpProc(request, 'websiteFunctions/suspendWebsiteV2.html',
|
||||
{'websiteList': websitesName}, 'suspendWebsite')
|
||||
return proc.render()
|
||||
|
||||
def listWebsites(self, request=None, userID=None, data=None):
|
||||
currentACL = ACLManager.loadedACL(userID)
|
||||
pagination = self.websitePagination(currentACL, userID)
|
||||
|
||||
Reference in New Issue
Block a user