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
94c0108a
Commit
94c0108a
authored
Apr 08, 2019
by
Ulises Morales Ramírez
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
descripcion reportes
parent
b52513bd
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
10 additions
and
6 deletions
+10
-6
Platform.html
administration/templates/Platform.html
+2
-2
Process.html
administration/templates/Process.html
+3
-3
views.py
administration/views.py
+3
-1
models.py
catalog/models.py
+2
-0
No files found.
administration/templates/Platform.html
View file @
94c0108a
...
...
@@ -145,10 +145,10 @@
<td>
<input
type=
"checkbox"
name=
"is_superuser"
value=
"1"
{%
if
not
request
.
user
.
is_superuser
%}
disabled
{%
endif
%}
{%
if
user
.
superuser
=
=
True
%}
checked
{%
endif
%}
>
{%
if
platform
.
status
=
=
True
%}
checked
{%
endif
%}
>
</td>
<td>
<button
title=
"save"
type=
"submit"
class=
"btn btn-success"
><i
<button
{%
if
not
request
.
user
.
is_superuser
%}
disabled
{%
endif
%}
title=
"save"
type=
"submit"
class=
"btn btn-success"
><i
class=
"fa fa-save"
></i></button>
</td>
</form>
...
...
administration/templates/Process.html
View file @
94c0108a
...
...
@@ -145,12 +145,12 @@
<input
type=
"hidden"
name=
"user_id"
value=
"{{ user.user_id }}"
>
<td>
<input
type=
"checkbox"
name=
"
is_superuser
"
value=
"1"
<input
type=
"checkbox"
name=
"
status
"
value=
"1"
{%
if
not
request
.
user
.
is_superuser
%}
disabled
{%
endif
%}
{%
if
user
.
superuser
=
=
True
%}
checked
{%
endif
%}
>
{%
if
process
.
status
=
=
True
%}
checked
{%
endif
%}
>
</td>
<td>
<button
title=
"save"
type=
"submit"
class=
"btn btn-success"
><i
<button
{%
if
not
request
.
user
.
is_superuser
%}
disabled
{%
endif
%}
title=
"save"
type=
"submit"
class=
"btn btn-success"
><i
class=
"fa fa-save"
></i></button>
</td>
</form>
...
...
administration/views.py
View file @
94c0108a
...
...
@@ -259,13 +259,14 @@ def all_Platform (request):
"id"
:
platform
.
id
,
"name"
:
platform
.
name
,
"acronym"
:
platform
.
acronym
,
"status"
:
platform
.
status
,
})
return
render
(
request
,
"Platform.html"
,{
'platforms'
:
platforms_list
})
#------------------------------------------------
def
all_Process
(
request
):
process
=
Process
.
objects
.
values
(
'id'
,
'name'
,
'platform__name'
,
'productLevel'
)
process
=
Process
.
objects
.
values
(
'id'
,
'name'
,
'
status'
,
'
platform__name'
,
'productLevel'
)
process_list
=
[]
for
process
in
process
:
process_list
.
append
({
...
...
@@ -273,6 +274,7 @@ def all_Process (request):
"name"
:
process
[
'name'
],
"platform_id"
:
process
[
'platform__name'
],
"product_level"
:
process
[
'productLevel'
],
"status"
:
process
[
'status'
],
})
return
render
(
request
,
"Process.html"
,
{
'process'
:
process_list
})
...
...
catalog/models.py
View file @
94c0108a
...
...
@@ -10,6 +10,7 @@ from django.db import models
class
Platform
(
models
.
Model
):
name
=
models
.
CharField
(
max_length
=
64
)
acronym
=
models
.
CharField
(
max_length
=
16
)
status
=
models
.
BooleanField
(
default
=
True
)
class
Polygon
(
models
.
Model
):
...
...
@@ -53,6 +54,7 @@ class Process(models.Model):
name
=
models
.
CharField
(
max_length
=
50
)
platform
=
models
.
ForeignKey
(
Platform
,
on_delete
=
models
.
CASCADE
,
default
=
''
)
productLevel
=
models
.
CharField
(
max_length
=
8
,
default
=
''
)
status
=
models
.
BooleanField
(
default
=
True
)
class
Search
(
models
.
Model
):
...
...
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