wpstagingui

This commit is contained in:
Hassan Hashmi
2022-06-05 17:55:49 +05:00
parent b7bb03b06f
commit 2e61794c50
6 changed files with 294 additions and 132 deletions

View File

@@ -18,7 +18,7 @@
src="{% static 'images/loading.gif' %}"></p>
</div>
<div class="panel" >
<div class="panel">
<div class="panel-body">
<h3 class="content-box-header">
{% trans "WordPress Manager" %}
@@ -338,30 +338,29 @@
</div>
</div>
<div ng-hide="installationProgress" class="form-group">
<label class="col-sm-3 control-label"></label>
<div class="col-sm-4">
<div ng-hide="installationProgress" class="form-group center-div">
<div class="col-sm-12">
<button type="button" ng-disabled="goBackDisable"
ng-click="goBack()"
class="btn btn-primary btn-lg center-div">{% trans "Go Back" %}</button>
</div>
</div>
<div class="form-group">
<table class="table table-condensed">
<thead>
<tr>
<th>Name</th>
<th>Domain</th>
<th>Path</th>
<th>Action</th>
</tr>
</thead>
<tbody id="StagingBody">
</tbody>
</table>
</div>
<br>
<br>
<h3>List staging site</h3>
<table class="table table-condensed">
<thead>
<tr>
<th>Name</th>
<th>Domain</th>
<th>Path</th>
<th>Action</th>
</tr>
</thead>
<tbody id="StagingBody">
</tbody>
</table>
</div>
</div>
</div>
@@ -479,4 +478,39 @@
</div>
</div>
<div id="DeployToProduction" 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">&times;
</button>
<h4 class="modal-title">DeployToProduction
<img ng-hide="$parent.cyberPanelLoading"
src="/static/images/loading.gif"
style="display: none;">
</h4>
</div>
<div class="modal-body">
<p class="no-margin">When you deploy a
staging site to production, the main
site is completely restored with the
staging site, so if you have made
any changes to main site they will
be lost.</p>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-primary"
onclick="FinalDeployToProduction()">Yes
</button>
<button type="button" ng-disabled="savingSettings"
class="btn btn-default" data-dismiss="modal">
Cancel
</button>
</div>
</div>
</div>
</div>
{% endblock %}

View File

@@ -14,72 +14,74 @@
</script>
<style>
table { /* tables still need 'cellspacing="0"' in the markup */
border-collapse: separate;
border-spacing: 0;
}
table { /* tables still need 'cellspacing="0"' in the markup */
border-collapse: separate;
border-spacing: 0;
}
.table-spacing {
border-spacing: 0em .9em;
}
.table-spacing {
border-spacing: 0em .9em;
}
table th:nth-child(1) {
table th:nth-child(1) {
/* Safari 3-4, iOS 1-3.2, Android 1.6- */
-webkit-border-radius: 3px 0px 0px 3px;
/* Safari 3-4, iOS 1-3.2, Android 1.6- */
-webkit-border-radius: 3px 0px 0px 3px;
/* Firefox 1-3.6 */
-moz-border-radius: 3px 0px 0px 3px;
/* Firefox 1-3.6 */
-moz-border-radius: 3px 0px 0px 3px;
/* Opera 10.5, IE 9, Safari 5, Chrome, Firefox 4, iOS 4, Android 2.1+ */
border-radius: 3px 0px 0px 3px;
}
table th:nth-child(1){
/* Opera 10.5, IE 9, Safari 5, Chrome, Firefox 4, iOS 4, Android 2.1+ */
border-radius: 3px 0px 0px 3px;
}
/* Safari 3-4, iOS 1-3.2, Android 1.6- */
-webkit-border-radius: 20px 0px 0px 20px;
table th:nth-child(1) {
/* Firefox 1-3.6 */
-moz-border-radius: 20px 0px 0px 20px;
/* Safari 3-4, iOS 1-3.2, Android 1.6- */
-webkit-border-radius: 20px 0px 0px 20px;
/* Opera 10.5, IE 9, Safari 5, Chrome, Firefox 4, iOS 4, Android 2.1+ */
border-radius: 20px 0px 0px 20px;
}
/* Firefox 1-3.6 */
-moz-border-radius: 20px 0px 0px 20px;
table th:nth-last-child(1) {
/* Safari 3-4, iOS 1-3.2, Android 1.6- */
-webkit-border-radius: 0px 20px 20px 0px;
/* Opera 10.5, IE 9, Safari 5, Chrome, Firefox 4, iOS 4, Android 2.1+ */
border-radius: 20px 0px 0px 20px;
}
/* Firefox 1-3.6 */
-moz-border-radius: 0px 20px 20px 0px;
table th:nth-last-child(1) {
/* Safari 3-4, iOS 1-3.2, Android 1.6- */
-webkit-border-radius: 0px 20px 20px 0px;
/* Opera 10.5, IE 9, Safari 5, Chrome, Firefox 4, iOS 4, Android 2.1+ */
border-radius:0px 20px 20px 0px;
}
table td:nth-child(1){
/* Firefox 1-3.6 */
-moz-border-radius: 0px 20px 20px 0px;
/* Safari 3-4, iOS 1-3.2, Android 1.6- */
-webkit-border-radius: 20px 0px 0px 20px;
/* Opera 10.5, IE 9, Safari 5, Chrome, Firefox 4, iOS 4, Android 2.1+ */
border-radius: 0px 20px 20px 0px;
}
/* Firefox 1-3.6 */
-moz-border-radius: 20px 0px 0px 20px;
table td:nth-child(1) {
/* Opera 10.5, IE 9, Safari 5, Chrome, Firefox 4, iOS 4, Android 2.1+ */
border-radius: 20px 0px 0px 20px;
}
/* Safari 3-4, iOS 1-3.2, Android 1.6- */
-webkit-border-radius: 20px 0px 0px 20px;
table td:nth-last-child(1) {
/* Safari 3-4, iOS 1-3.2, Android 1.6- */
-webkit-border-radius: 0px 20px 20px 0px;
/* Firefox 1-3.6 */
-moz-border-radius: 20px 0px 0px 20px;
/* Firefox 1-3.6 */
-moz-border-radius: 0px 20px 20px 0px;
/* Opera 10.5, IE 9, Safari 5, Chrome, Firefox 4, iOS 4, Android 2.1+ */
border-radius: 20px 0px 0px 20px;
}
/* Opera 10.5, IE 9, Safari 5, Chrome, Firefox 4, iOS 4, Android 2.1+ */
border-radius: 0px 20px 20px 0px;
}
table td:nth-last-child(1) {
/* Safari 3-4, iOS 1-3.2, Android 1.6- */
-webkit-border-radius: 0px 20px 20px 0px;
</style>
/* Firefox 1-3.6 */
-moz-border-radius: 0px 20px 20px 0px;
/* Opera 10.5, IE 9, Safari 5, Chrome, Firefox 4, iOS 4, Android 2.1+ */
border-radius: 0px 20px 20px 0px;
}
</style>
<div ng-controller="listWebsites" class="container">
@@ -94,86 +96,85 @@
</div>
<table class="table-spacing" style="width: 100%">
<thead style="color: white; background-color: #0a6ebd">
<tr>
<th style="padding: 18px; color: white; width: 161px; font-size: 12px;">WordPress Site Title
</th>
<th style="padding: 18px; color: white; width: 161px; font-size: 12px;">Domain
</th>
<th style="padding: 18px; color: white; width: 161px; font-size: 12px;">Action
</th>
<table class="table-spacing" style="width: 100%">
<thead style="color: white; background-color: #0a6ebd">
<tr>
<th style="padding: 18px; color: white; width: 161px; font-size: 12px;">WordPress Site Title
</th>
<th style="padding: 18px; color: white; width: 161px; font-size: 12px;">Domain
</th>
<th style="padding: 18px; color: white; width: 161px; font-size: 12px;">Action
</th>
</tr>
</thead>
<tbody style="background-color: #d9eefa">
{% for sub in wpsite %}
</tr>
</thead>
<tr>
<td style="padding: 13px;">
<a href="{% url 'WPHome' %}?ID={{ sub.id }}">
<p style="font-weight: bold; text-transform: uppercase; ">{{ sub.title }}</p>
</a>
</td>
<td style="padding: 13px;">
<a target="_blank" style="color: #6aa7ff"
href="http://{{ sub.url }}">Visit
<i class="glyph-icon icon-external-link-square" title="{{ sub.url }}"></i></a>
</td>
<tbody style="background-color: #d9eefa">
{% for sub in wpsite %}
<td style="padding: 13px;">
<tr >
<td style="padding: 13px;">
<a href="{% url 'WPHome'%}?ID={{sub.id}}">
<p style="font-weight: bold; text-transform: uppercase; ">{{ sub.title }}</p>
</a>
</td>
<td style="padding: 13px;">
<a target="_blank" style="color: #6aa7ff"
href="http://{{ sub.url }}">Visit
<i class="glyph-icon icon-external-link-square" title="{{ sub.url }}"></i></a>
</td>
<button
data-toggle="modal"
data-target="#DeleteMember" aria-label=""
onclick="DeleteWPNow('{% url 'ListWPSites' %}?DeleteID={{ sub.id }}')"
type="button" class="btn btn-border btn-alt border-red btn-link font-red">
Delete
</button>
<div id="DeleteMember" 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">&times;
</button>
<h4 class="modal-title">Delete WordPress Site
<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">
<td style="padding: 13px;">
<button
data-toggle="modal"
data-target="#DeleteMember" aria-label=""
onclick="DeleteWPNow('{% url 'ListWPSites' %}?DeleteID={{ sub.id }}')"
type="button" class="btn btn-border btn-alt border-red btn-link font-red">
Delete
</button>
<div id="DeleteMember" 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">&times;
</button>
<h4 class="modal-title">Delete WordPress Site
<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">
<span>Do you want to delete the site?</span>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-primary"
onclick="FinalDeleteWPNow()">Yes
</button>
<button type="button" ng-disabled="savingSettings"
class="btn btn-default" data-dismiss="modal">
Cancel
</button>
</div>
<span>Do you want to delete the site?</span>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-primary"
onclick="FinalDeleteWPNow()">Yes
</button>
<button type="button" ng-disabled="savingSettings"
class="btn btn-default" data-dismiss="modal">
Cancel
</button>
</div>
</div>
</div>
</div>
</td>
</td>
</tr>
{% endfor %}
</tr>
{% endfor %}
</tbody>
</table>
</tbody>
</table>
</div>