mirror of
https://github.com/usmannasir/cyberpanel.git
synced 2025-11-10 23:36:11 +01:00
GitLab integration to websites.
This commit is contained in:
@@ -13,7 +13,9 @@
|
||||
<p>{% trans "Attach git to your website" %}</p>
|
||||
</div>
|
||||
|
||||
<div ng-controller="setupGit" class="panel">
|
||||
{% if not installed %}
|
||||
|
||||
<div ng-controller="setupGit" class="panel">
|
||||
<div class="panel-body">
|
||||
<h3 class="title-hero">
|
||||
<span id="domainNamePage">{{ domainName }}</span> - {% trans "Attach Git" %} <img ng-hide="gitLoading" src="{% static 'images/loading.gif' %}">
|
||||
@@ -24,7 +26,7 @@
|
||||
<li class="col-md-3 active">
|
||||
<a href="#tab-example-1" data-toggle="tab" class="list-group-item">
|
||||
<i class="glyph-icon icon-dashboard"></i>
|
||||
{% trans "Github" %}
|
||||
{% trans "Providers" %}
|
||||
</a>
|
||||
</li>
|
||||
|
||||
@@ -42,6 +44,23 @@
|
||||
<div class="tab-pane fade active in" id="tab-example-1">
|
||||
<div class="example-box-wrapper">
|
||||
|
||||
<ul class="list-group row">
|
||||
<li class="col-md-3">
|
||||
<a href="" ng-click="setProvider('github')" class="list-group-item">
|
||||
<i class="fa fa-github" aria-hidden="true"></i>
|
||||
Github
|
||||
<i class="glyph-icon icon-chevron-right"></i>
|
||||
</a>
|
||||
</li>
|
||||
<li class="col-md-3">
|
||||
<a href="" ng-click="setProvider('gitlab')" class="list-group-item">
|
||||
<i class="fa fa-gitlab" aria-hidden="true"></i>
|
||||
GitLab
|
||||
<i class="glyph-icon font-green icon-chevron-right"></i>
|
||||
</a>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<form action="/" class="form-horizontal bordered-row">
|
||||
|
||||
<div ng-hide="installationDetailsForm" class="form-group">
|
||||
@@ -49,7 +68,7 @@
|
||||
</div>
|
||||
|
||||
<div ng-hide="installationDetailsForm" class="form-group">
|
||||
<label class="col-sm-3 control-label">{% trans "Github Username" %}</label>
|
||||
<label class="col-sm-3 control-label">{% trans "Username" %}</label>
|
||||
<div class="col-sm-6">
|
||||
<input type="text" class="form-control" ng-model="githubUserName" required>
|
||||
</div>
|
||||
@@ -173,6 +192,102 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{% else %}
|
||||
|
||||
<div ng-controller="setupGit" class="panel">
|
||||
<div class="panel-body">
|
||||
<h3 class="title-hero">
|
||||
<span id="domainNamePage">{{ domainName }}</span> <img ng-hide="gitLoading" src="{% static 'images/loading.gif' %}">
|
||||
</h3>
|
||||
|
||||
<div class="example-box-wrapper">
|
||||
<ul class="list-group list-group-separator row list-group-icons">
|
||||
|
||||
<li class="col-md-3 active">
|
||||
<a href="#tab-example-1" data-toggle="tab" class="list-group-item">
|
||||
<i class="fa fa-git" aria-hidden="true"></i>
|
||||
{% trans 'Manage' %}
|
||||
</a>
|
||||
</li>
|
||||
<li class="col-md-3">
|
||||
<a href="#tab-example-3" data-toggle="tab" class="list-group-item">
|
||||
<i class="fa fa-tree" aria-hidden="true"></i>
|
||||
{% trans 'Change Branch' %}
|
||||
</a>
|
||||
</li>
|
||||
</ul>
|
||||
<div class="tab-content">
|
||||
<div class="tab-pane fade active in" id="tab-example-1">
|
||||
<ul class="list-group row">
|
||||
<li class="col-md-3">
|
||||
<a href="" ng-click="setProvider('github')" class="list-group-item">
|
||||
<i class="fa fa-github" aria-hidden="true"></i>
|
||||
Detach Repo
|
||||
<i class="glyph-icon icon-chevron-right"></i>
|
||||
</a>
|
||||
</li>
|
||||
</ul>
|
||||
<div class="alert alert-info">
|
||||
<h4 class="alert-title">{% trans 'Webhook URL' %}</h4>
|
||||
<p>{% trans "Add this URL to Webhooks section of your Git respository, if you've used hostname SSL then replace IP with your hostname. Otherwise use IP and disable SSL check while configuring webhook. This will initiate a pull from your resposity as soon as you commit some changes."%} <code>{{ webhookURL }}</code></p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div class="tab-pane fade" id="tab-example-3">
|
||||
|
||||
<form action="/" class="form-horizontal bordered-row">
|
||||
|
||||
<div ng-hide="installationDetailsForm" class="form-group">
|
||||
<label class="col-sm-3 control-label">{% trans "Branch" %}</label>
|
||||
<div class="col-sm-6">
|
||||
<input type="text" class="form-control" ng-model="githubBranch" required>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<div ng-hide="installationDetailsForm" class="form-group">
|
||||
<label class="col-sm-3 control-label"></label>
|
||||
<div class="col-sm-4">
|
||||
<button type="button" ng-click="attachRepo()" class="btn btn-primary btn-lg btn-block">{% trans "Change Branch" %}</button>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div ng-hide="" class="form-group">
|
||||
<label class="col-sm-2 control-label"></label>
|
||||
<div class="col-sm-7">
|
||||
|
||||
<div ng-hide="failedMesg" class="alert alert-danger">
|
||||
<p>{% trans "Error message:" %} {$ errorMessage $}</p>
|
||||
</div>
|
||||
|
||||
<div ng-hide="successMessage" class="alert alert-success">
|
||||
<p>{% trans "Branch successfully changed." %}</p>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div ng-hide="couldNotConnect" class="alert alert-danger">
|
||||
<p>{% trans "Could not connect to server. Please refresh this page." %}</p>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
</form>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{% endif %}
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user