Merge pull request #283 from Reena-cell/develop

Remove Include_system_data checkbox
This commit is contained in:
Simon Redfern 2023-02-06 15:41:30 +01:00 committed by GitHub
commit 57d697b806
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
9 changed files with 12 additions and 95 deletions

View File

@ -222,7 +222,8 @@ class CustomSummaryForm(forms.Form):
required=False,
initial='API-Manager',
)
include_obp_apps = forms.BooleanField(required=False, label=_('Include System Data'))
#include_obp_apps = forms.BooleanField(required=False, label=_('Include System Data'))
include_obp_apps = forms.BooleanField(required=False)
def __init__(self, *args, **kwargs):
kwargs.setdefault('label_suffix', '')
@ -246,7 +247,8 @@ class MonthlyMetricsSummaryForm(forms.Form):
required=False,
initial='API-Manager',
)
include_obp_apps = forms.BooleanField(required=False, label=_('Include System Data'))
#include_obp_apps = forms.BooleanField(required=False, label=_('Include System Data'))
include_obp_apps = forms.BooleanField(required=False)
def __init__(self, *args, **kwargs):
kwargs.setdefault('label_suffix', '')

View File

@ -1,13 +0,0 @@
document.getElementsByClassName("include_system_calls")[0].innerHTML=`<div>
<input type="checkbox" id="include_system_calls_id" name="Include System Calls">
<label for="systemCalls">Include System Calls</label>
</div>`
function systemCalls(){
let checkbox = document.getElementById('include_system_calls_id');
if (checkbox.checked == false) {
document.getElementById("obp_app_table").style.display = "none";
}else{
document.getElementById("obp_app_table").style.display = "";
}
}

View File

@ -56,18 +56,11 @@
{{ form.exclude_app_names }}
</div>
</div>
<div class="col-xs-4 col-sm-3">
<div class="form-group include_system_calls">
{{ form.include_obp_apps }}
{{ form.include_obp_apps.label_tag }}
</div>
</div>
</div>
<button type="submit" class="btn btn-primary" onclick="systemCalls()">{% trans "Update Filter" %}</button>
<button type="submit" class="btn btn-primary">{% trans "Update Filter" %}</button>
</form>
</div>
<div class="tab-content">
{% if form.include_obp_apps.value %}
{% block tab_content %}
<div class="tab-pane active">
<h2>{% trans "Period" %}: {% trans "From: " %}{{ from_date }} {% trans "To: " %}{{ to_date }} </h2>
@ -145,9 +138,6 @@
</table>
</div>
{% endblock tab_content %}
{% else %}
<h2>{% trans "Period: " %} : {% trans "From: " %} {{ from_date }} {% trans "To: " %} {{ to_date }}</h2>
{% endif %}
</div>
</div>

View File

@ -56,12 +56,6 @@
{{ form.exclude_app_names }}
</div>
</div>
<div class="col-xs-4 col-sm-3">
<div class="form-group include_system_calls">
{{ form.include_obp_apps }}
{{ form.include_obp_apps.label_tag }}
</div>
</div>
</div>
<button type="submit" class="btn btn-primary">{% trans "Update Filter" %}</button>
</form>
@ -69,12 +63,11 @@
</div>
<div class="tab-content">
{% if form.include_obp_apps.value %}
{% block tab_content %}
<div class="tab-pane active">
<h2>{% trans "Period" %} : {% trans "From" %} {{ from_date }} {% trans "to" %} {{ to_date }}</h2>
<table border="1" id="obp_app_table">
<table border="1">
<tr>
<th></th>
<th></th>
@ -148,9 +141,6 @@
</table>
</div>
{% endblock tab_content %}
{% else %}
<h2>{% trans "Period" %} : {% trans "From" %} {{ from_date }} {% trans "to" %} {{ to_date }}</h2>
{% endif %}
</div>
</div>

View File

@ -55,12 +55,6 @@
{{ form.exclude_app_names }}
</div>
</div>
<div class="col-xs-4 col-sm-3">
<div class="form-group include_system_calls">
{{ form.include_obp_apps }}
{{ form.include_obp_apps.label_tag }}
</div>
</div>
</div>
<button type="submit" class="btn btn-primary">{% trans "Update Filter" %}</button>
</form>
@ -68,12 +62,11 @@
</div>
<div class="tab-content">
{% if form.include_obp_apps.value %}
{% block tab_content %}
<div class="tab-pane active">
<h2>{% trans "Period" %}: {% trans "From" %}{{ from_date }} {% trans "to" %} {{ to_date }}</h2>
<table border="1" id="obp_app_table" summary="Table about call APIs in every hours">
<table border="1" summary="Table about call APIs in every hours">
<tr>
<th></th>
<th></th>
@ -147,9 +140,6 @@
</table>
</div>
{% endblock tab_content %}
{% else %}
<h2>{% trans "Period" %} : {% trans "From" %} {{ from_date }} {% trans "to" %} {{ to_date }}</h2>
{% endif %}
</div>
</div>

View File

@ -51,12 +51,6 @@
{{ form.exclude_app_names }}
</div>
</div>
<div class="col-xs-4 col-sm-3">
<div class="form-group include_system_calls">
{{ form.include_obp_apps }}
{{ form.include_obp_apps.label_tag }}
</div>
</div>
</div>
<button type="submit" class="btn btn-primary">{% trans "Update Filter" %}</button>
</form>
@ -64,12 +58,11 @@
</div>
<div class="tab-content">
{% if form.include_obp_apps.value %}
{% block tab_content %}
<div class="tab-pane active">
<h2>{% trans "Period" %}: {% trans "From" %} {{ from_date }} {% trans "to" %} {{ to_date }}</h2>
<table border="1" id="obp_app_table">
<table border="1">
<tr>
<th></th>
<th></th>
@ -142,9 +135,6 @@
</table>
</div>
{% endblock tab_content %}
{% else %}
<h2>{% trans "Period" %} : {% trans "From" %} {{ from_date }} {% trans "to" %} {{ to_date }}</h2>
{% endif %}
</div>
</div>

View File

@ -55,12 +55,6 @@
{{ form.exclude_app_names }}
</div>
</div>
<div class="col-xs-4 col-sm-3">
<div class="form-group include_system_calls">
{{ form.include_obp_apps }}
{{ form.include_obp_apps.label_tag }}
</div>
</div>
</div>
<button type="submit" class="btn btn-primary">{% trans "Update Filter" %}</button>
</form>
@ -68,12 +62,11 @@
</div>
<div class="tab-content">
{% if form.include_obp_apps.value %}
{% block tab_content %}
<div class="tab-pane active">
<h2>{% trans "Period" %}:{% trans "From" %} {{ from_date }} {% trans "to" %} {{ to_date }}</h2>
<table border="1" id="obp_app_table">
<table border="1">
<tr>
<th></th>
<th></th>
@ -151,9 +144,6 @@
</table>
</div>
{% endblock tab_content %}
{% else %}
<h2>{% trans "Period" %} : {% trans "From" %} {{ from_date }} {% trans "to" %} {{ to_date }}</h2>
{% endif %}
</div>
</div>

View File

@ -57,23 +57,16 @@
{{ form.exclude_app_names }}
</div>
</div>
<div class="col-xs-4 col-sm-3">
<div class="form-group include_system_calls">
{{ form.include_obp_apps }}
{{ form.include_obp_apps.label_tag }}
</div>
</div>
</div>
<button type="submit" class="btn btn-primary">{% trans "Update Filter" %}</button>
</form>
</div>
<div class="tab-content">
{% if form.include_obp_apps.value %}
{% block tab_content %}
<div class="tab-pane active">
<h2>{% trans "Period" %} : {% trans "From" %} {{ from_date }} {% trans "to" %} {{ to_date }}</h2>
<table border="1" id="obp_app_table">
<table border="1">
<tr>
<th></th>
<th></th>
@ -147,9 +140,6 @@
</table>
</div>
{% endblock tab_content %}
{% else %}
<h2>{% trans "Period" %} : {% trans "From" %} {{ from_date }} {% trans "to" %} {{ to_date }}</h2>
{% endif %}
</div>
</div>

View File

@ -57,24 +57,15 @@
{{ form.exclude_app_names }}
</div>
</div>
<div class="col-xs-4 col-sm-3">
<div class="form-group include_system_calls">
{{ form.include_obp_apps }}
{{ form.include_obp_apps.label_tag }}
</div>
</div>
</div>
<button type="submit" class="btn btn-primary" onclick="systemCalls()">{% trans "Update Filter" %}</button>
<button type="submit" class="btn btn-primary">{% trans "Update Filter" %}</button>
</form>
</div>
<div class="tab-content">
{% if form.include_obp_apps.value %}
{% block tab_content %}
<div class="tab-pane active">
<h2>{% trans "Period" %} : {% trans "From" %} {{ from_date }} {% trans "to" %} {{ to_date }}</h2>
<table border="1" id="obp_app_table">
<table border="1">
<tr>
<th></th>
<th></th>
@ -149,9 +140,6 @@
</table>
</div>
{% endblock tab_content %}
{% else %}
<h2>{% trans "Period" %} : {% trans "From" %} {{ from_date }} {% trans "to" %} {{ to_date }}</h2>
{% endif %}
</div>
</div>
</div>