Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
GeoInt_SIDT
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Mario Chirinos Colunga
GeoInt_SIDT
Commits
f857f0c7
Commit
f857f0c7
authored
Feb 12, 2019
by
Ulises Morales Ramírez
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
paginacion y botones en reportes
parent
8da5fe05
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
3 deletions
+8
-3
Reports.html
reports/templates/Reports.html
+4
-3
views.py
reports/views.py
+4
-0
No files found.
reports/templates/Reports.html
View file @
f857f0c7
...
@@ -161,7 +161,7 @@
...
@@ -161,7 +161,7 @@
</td>
</td>
<td>
{{product.size}}
</td>
<td>
{{product.size}}
</td>
<td
class=
"text-center"
>
<td
class=
"text-center"
>
<a
title=
"View Report"
{%
if
product
.
progress =
=
10
0
%}
<a
title=
"View Report"
{%
if
product
.
progress =
=
6
0
%}
href=
"{{ BASE_URL }}/reports/T15QZD_sclData/{{product.purchase_id}}"
href=
"{{ BASE_URL }}/reports/T15QZD_sclData/{{product.purchase_id}}"
{%
else
%}
{%
else
%}
href=
"#"
href=
"#"
...
@@ -183,7 +183,7 @@
...
@@ -183,7 +183,7 @@
</td>
</td>
</tr>
</tr>
{% endfor %}
{% endfor %}
</tbody>
</tbody>
</table>
</table>
<ul
class=
"pagination"
>
<ul
class=
"pagination"
>
{% if productList.has_previous %}
{% if productList.has_previous %}
...
@@ -283,8 +283,9 @@
...
@@ -283,8 +283,9 @@
{% block scripts %}
{% block scripts %}
<script>
<script>
function
openmodal
(
info
)
{
function
openmodal
(
info
)
{
info2
=
info
.
split
(
";"
);
$
(
"#myModal"
).
modal
();
$
(
"#myModal"
).
modal
();
$
(
"#log_info"
).
append
(
info
);
$
(
"#log_info"
).
append
(
info
2
);
}
}
</script>
</script>
{% endblock%}
{% endblock%}
\ No newline at end of file
reports/views.py
View file @
f857f0c7
...
@@ -96,8 +96,12 @@ def Reports(request):
...
@@ -96,8 +96,12 @@ def Reports(request):
progress
=
50
progress
=
50
if
'Extracting SCL information...'
in
open
(
log_info
)
.
read
():
if
'Extracting SCL information...'
in
open
(
log_info
)
.
read
():
progress
=
60
progress
=
60
with
open
(
log_info
,
'r'
)
as
myfile
:
with
open
(
log_info
,
'r'
)
as
myfile
:
log
=
myfile
.
read
()
.
replace
(
'
\n
'
,
''
)
log
=
myfile
.
read
()
.
replace
(
'
\n
'
,
''
)
for
p
in
json
.
loads
(
producto
[
'productList'
]):
for
p
in
json
.
loads
(
producto
[
'productList'
]):
size
=
size
+
float
(
p
[
'info'
][
'size'
][:
-
3
])
size
=
size
+
float
(
p
[
'info'
][
'size'
][:
-
3
])
if
size
>
1000
:
if
size
>
1000
:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment