mirror of
https://github.com/OpenBankProject/API-Manager.git
synced 2026-02-06 12:46:54 +00:00
Merge pull request #153 from hongwei1/master
bugfix/fixed the bugs for sonarcloud
This commit is contained in:
commit
4d08501994
@ -19,9 +19,9 @@
|
||||
|
||||
<h2>Endpoints</h2>
|
||||
<div class="table-responsive">
|
||||
<table class="table table-striped">
|
||||
<table class="table table-striped" aria-describedby="api collection">
|
||||
<thead>
|
||||
<th>Operation Ids</th>
|
||||
<th scope="col">Operation Ids</th>
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for api_collection_endpoint in api_collection_endpoints %}
|
||||
|
||||
@ -206,7 +206,6 @@ table.tablesorter thead tr .headerSortDown, table.tablesorter thead tr .headerSo
|
||||
text-align: center;
|
||||
line-height: 24px;
|
||||
border-radius: 0;
|
||||
border: 0;
|
||||
padding: 9px 20px 11px;
|
||||
border: 1px solid #333333;
|
||||
}
|
||||
@ -155,13 +155,13 @@
|
||||
</form>
|
||||
|
||||
<div class="table-responsive">
|
||||
<table class="table table-hover tablesorter" id="branches-list">
|
||||
<table class="table table-hover tablesorter" id="branches-list" aria-describedby="branches list">
|
||||
<thead>
|
||||
<th>Branch Id</th>
|
||||
<th>Bank Id</th>
|
||||
<th>Branch Name</th>
|
||||
<th>More_info</th>
|
||||
<th>Update Button</th>
|
||||
<th scope="col">Branch Id</th>
|
||||
<th scope="col">Bank Id</th>
|
||||
<th scope="col">Branch Name</th>
|
||||
<th scope="col">More_info</th>
|
||||
<th scope="col">Update Button</th>
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for branch in branches_list %}
|
||||
|
||||
@ -50,13 +50,13 @@
|
||||
</ul>
|
||||
|
||||
<div class="table-responsive">
|
||||
<table class="table table-hover tablesorter" id="consumer-list">
|
||||
<table class="table table-hover tablesorter" id="consumer-list" aria-describedby="consumer list">
|
||||
<thead>
|
||||
<th>ID</th>
|
||||
<th>Name</th>
|
||||
<th>Description</th>
|
||||
<th>Created</th>
|
||||
<th>Action</th>
|
||||
<th scope="col">ID</th>
|
||||
<th scope="col">Name</th>
|
||||
<th scope="col">Description</th>
|
||||
<th scope="col">Created</th>
|
||||
<th scope="col">Action</th>
|
||||
</thead>
|
||||
|
||||
<tbody>
|
||||
|
||||
@ -116,9 +116,9 @@ class DetailView(LoginRequiredMixin, FormView):
|
||||
"""Put limits data to API"""
|
||||
try:
|
||||
data = ''
|
||||
form = ApiConsumersForm(self.request.POST)
|
||||
if form.is_valid():
|
||||
data = form.cleaned_data
|
||||
api_consumers_form = ApiConsumersForm(self.request.POST)
|
||||
if api_consumers_form.is_valid():
|
||||
data = api_consumers_form.cleaned_data
|
||||
|
||||
urlpath = '/management/consumers/{}/consumer/calls_limit'.format(data['consumer_id'])
|
||||
|
||||
@ -132,16 +132,16 @@ class DetailView(LoginRequiredMixin, FormView):
|
||||
user = self.api.put(urlpath, payload=payload)
|
||||
except APIError as err:
|
||||
messages.error(self.request, err)
|
||||
return super(DetailView, self).form_invalid(form)
|
||||
return super(DetailView, self).form_invalid(api_consumers_form)
|
||||
except Exception as err:
|
||||
messages.error(self.request, "{}".format(err))
|
||||
return super(DetailView, self).form_invalid(form)
|
||||
return super(DetailView, self).form_invalid(api_consumers_form)
|
||||
|
||||
msg = 'calls limit of consumer {} has been updated successfully.'.format(
|
||||
data['consumer_id'])
|
||||
messages.success(self.request, msg)
|
||||
self.success_url = self.request.path
|
||||
return super(DetailView, self).form_valid(form)
|
||||
return super(DetailView, self).form_valid(api_consumers_form)
|
||||
|
||||
def get_context_data(self, **kwargs):
|
||||
context = super(DetailView, self).get_context_data(**kwargs)
|
||||
|
||||
@ -22,14 +22,14 @@
|
||||
</div>
|
||||
|
||||
<div class="table-responsive">
|
||||
<table class="table table-hover tablesorter" id="entitementrequests-list">
|
||||
<table class="table table-hover tablesorter" id="entitementrequests-list" aria-describedby="entitlement requests list">
|
||||
<thead>
|
||||
<th>Role Name</th>
|
||||
<th>User name</th>
|
||||
<th>Bank ID</th>
|
||||
<th>Created</th>
|
||||
<th>Action</th>
|
||||
<th>Action</th>
|
||||
<th scope="col">Role Name</th>
|
||||
<th scope="col">User name</th>
|
||||
<th scope="col">Bank ID</th>
|
||||
<th scope="col">Created</th>
|
||||
<th scope="col">Action</th>
|
||||
<th scope="col">Action</th>
|
||||
</thead>
|
||||
|
||||
<tbody>
|
||||
|
||||
@ -135,15 +135,15 @@
|
||||
{% block tab_content %}
|
||||
<div class="tab-pane active">
|
||||
<div class="table-responsive">
|
||||
<table class="table table-hover tablesorter">
|
||||
<table class="table table-hover tablesorter" aria-describedby="api list">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>#</th>
|
||||
<th>Verb</th>
|
||||
<th>URL</th>
|
||||
<th>Date</th>
|
||||
<th>Duration(ms)</th>
|
||||
<th>Details</th>
|
||||
<th scope="col">#</th>
|
||||
<th scope="col">Verb</th>
|
||||
<th scope="col">URL</th>
|
||||
<th scope="col">Date</th>
|
||||
<th scope="col">Duration(ms)</th>
|
||||
<th scope="col">Details</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
||||
@ -78,15 +78,15 @@
|
||||
|
||||
<div id="metrics-data">
|
||||
<div class="table-responsive">
|
||||
<table class="table table-hover tablesorter">
|
||||
<table class="table table-hover tablesorter" aria-describedby="connector list">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>#</th>
|
||||
<th>Date</th>
|
||||
<th>Connector Name</th>
|
||||
<th>Function Name</th>
|
||||
<th>Correlation ID</th>
|
||||
<th>Duration (ms)</th>
|
||||
<th scope="col">#</th>
|
||||
<th scope="col">Date</th>
|
||||
<th scope="col">Connector Name</th>
|
||||
<th scope="col">Function Name</th>
|
||||
<th scope="col">Correlation ID</th>
|
||||
<th scope="col">Duration (ms)</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
||||
@ -76,6 +76,10 @@
|
||||
<h2>Period : From {{ from_date }} to {{ to_date }}</h2>
|
||||
|
||||
<table border="1">
|
||||
<tr>
|
||||
<th></th>
|
||||
<th></th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Total API calls:</td>
|
||||
<td>{{ api_calls }}</td>
|
||||
|
||||
@ -69,6 +69,10 @@
|
||||
<h2>Period : From {{ from_date }} to {{ to_date }}</h2>
|
||||
|
||||
<table border="1">
|
||||
<tr>
|
||||
<th></th>
|
||||
<th></th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Total API calls:</td>
|
||||
<td>{{ api_calls }}</td>
|
||||
|
||||
@ -68,6 +68,10 @@
|
||||
<h2>Period : From {{ from_date }} to {{ to_date }}</h2>
|
||||
|
||||
<table border="1">
|
||||
<tr>
|
||||
<th></th>
|
||||
<th></th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>API calls:</td>
|
||||
<td>{{ api_calls }}</td>
|
||||
|
||||
@ -79,6 +79,10 @@
|
||||
<h2>Period : From {{ from_date }} to {{ to_date }}</h2>
|
||||
|
||||
<table border="1">
|
||||
<tr>
|
||||
<th></th>
|
||||
<th></th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Total API calls:</td>
|
||||
<td>{{ api_calls }}</td>
|
||||
|
||||
@ -68,6 +68,10 @@
|
||||
<h2>Period : From {{ from_date }} to {{ to_date }}</h2>
|
||||
|
||||
<table border="1">
|
||||
<tr>
|
||||
<th></th>
|
||||
<th></th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Total API calls:</td>
|
||||
<td>{{ api_calls }}</td>
|
||||
|
||||
@ -70,6 +70,10 @@
|
||||
<h2>Period : From {{ from_date }} to {{ to_date }}</h2>
|
||||
|
||||
<table border="1">
|
||||
<tr>
|
||||
<th></th>
|
||||
<th></th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Total API calls:</td>
|
||||
<td>{{ api_calls }}</td>
|
||||
|
||||
@ -70,6 +70,10 @@
|
||||
<h2>Period : From {{ from_date }} to {{ to_date }}</h2>
|
||||
|
||||
<table border="1">
|
||||
<tr>
|
||||
<th></th>
|
||||
<th></th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Total API calls:</td>
|
||||
<td>{{ api_calls }}</td>
|
||||
|
||||
@ -88,11 +88,11 @@
|
||||
|
||||
<h2>Entitlements</h2>
|
||||
<div class="table-responsive">
|
||||
<table class="table table-striped">
|
||||
<table class="table table-striped" aria-describedby="uses table">
|
||||
<thead>
|
||||
<th>Role name</th>
|
||||
<th>Bank Id</th>
|
||||
<th>Action</th>
|
||||
<th scope="col">Role name</th>
|
||||
<th scope="col">Bank Id</th>
|
||||
<th scope="col">Action</th>
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for entitlement in apiuser.entitlements.list %}
|
||||
|
||||
@ -52,12 +52,12 @@
|
||||
</ul>
|
||||
|
||||
<div class="table-responsive">
|
||||
<table class="table table-hover tablesorter" id="users-list">
|
||||
<table class="table table-hover tablesorter" id="users-list" aria-describedby="users list">
|
||||
<thead>
|
||||
<th>User Id</th>
|
||||
<th>Username</th>
|
||||
<th>Email</th>
|
||||
<th>Action</th>
|
||||
<th scope="col">User Id</th>
|
||||
<th scope="col">Username</th>
|
||||
<th scope="col">Email</th>
|
||||
<th scope="col">Action</th>
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for user in users %}
|
||||
|
||||
@ -65,14 +65,14 @@
|
||||
|
||||
<input type="submit" value="Create" class="btn btn-primary" />
|
||||
<div class="table-responsive">
|
||||
<table class="table table-hover tablesorter" id="invitation-list">
|
||||
<table class="table table-hover tablesorter" id="invitation-list" aria-describedby="invitation list">
|
||||
<thead>
|
||||
<th>First Name</th>
|
||||
<th>Last Name</th>
|
||||
<th>Email</th>
|
||||
<th>company</th>
|
||||
<th>country</th>
|
||||
<th>status</th>
|
||||
<th scope="col">First Name</th>
|
||||
<th scope="col">Last Name</th>
|
||||
<th scope="col">Email</th>
|
||||
<th scope="col">company</th>
|
||||
<th scope="col">country</th>
|
||||
<th scope="col">status</th>
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for invitation in invitations %}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user