Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
W
web app
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
ICNML
web app
Commits
20be4c2f
Commit
20be4c2f
authored
4 years ago
by
Marco De Donno
Browse files
Options
Downloads
Patches
Plain Diff
Use the NIST segments_position_code labels instead of recreating them
parent
0483aa71
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
views/afis/__init__.py
+4
-6
4 additions, 6 deletions
views/afis/__init__.py
views/afis/templates/admin/folder_list.html
+1
-1
1 addition, 1 deletion
views/afis/templates/admin/folder_list.html
with
5 additions
and
7 deletions
views/afis/__init__.py
+
4
−
6
View file @
20be4c2f
...
@@ -7,6 +7,9 @@ import config
...
@@ -7,6 +7,9 @@ import config
from
utils.decorator
import
login_required
,
admin_required
from
utils.decorator
import
login_required
,
admin_required
from
utils.template
import
my_render_template
from
utils.template
import
my_render_template
from
NIST.fingerprint.labels
import
FINGER_POSITION_CODE
,
PALM_POSITION_CODE
segments_position_code
=
dict
(
FINGER_POSITION_CODE
,
**
PALM_POSITION_CODE
)
afis_view
=
Blueprint
(
"
afis
"
,
__name__
,
template_folder
=
"
templates
"
)
afis_view
=
Blueprint
(
"
afis
"
,
__name__
,
template_folder
=
"
templates
"
)
@afis_view.route
(
"
/admin/afis/list
"
)
@afis_view.route
(
"
/admin/afis/list
"
)
...
@@ -81,15 +84,10 @@ def admin_show_target_list( uuid ):
...
@@ -81,15 +84,10 @@ def admin_show_target_list( uuid ):
"""
"""
segments_list
=
config
.
db
.
query_fetchall
(
sql
,
(
uuid
,
)
)
segments_list
=
config
.
db
.
query_fetchall
(
sql
,
(
uuid
,
)
)
finger_names
=
[]
for
laterality
in
[
"
Right
"
,
"
Left
"
]:
for
finger
in
[
"
thumb
"
,
"
index
"
,
"
middle
"
,
"
ring
"
,
"
little
"
]:
finger_names
.
append
(
"
{} {}
"
.
format
(
laterality
,
finger
)
)
return
my_render_template
(
return
my_render_template
(
"
admin/folder_list.html
"
,
"
admin/folder_list.html
"
,
segments_list
=
segments_list
,
segments_list
=
segments_list
,
finger_names
=
finger_names
segments_position_code
=
segments_position_code
)
)
@afis_view.route
(
"
/admin/<uuid>/target/<pc>
"
)
@afis_view.route
(
"
/admin/<uuid>/target/<pc>
"
)
...
...
This diff is collapsed.
Click to expand it.
views/afis/templates/admin/folder_list.html
+
1
−
1
View file @
20be4c2f
...
@@ -51,7 +51,7 @@
...
@@ -51,7 +51,7 @@
<div
class=
"icnml_list_of_boxes"
>
<div
class=
"icnml_list_of_boxes"
>
{% for n in [ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 22, 24, 25, 27 ] %}
{% for n in [ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 22, 24, 25, 27 ] %}
<div
style=
"margin-bottom: 20px"
id=
"segment_outer_div"
>
<div
style=
"margin-bottom: 20px"
id=
"segment_outer_div"
>
<div
class=
"ui-widget-header ui-corner-top icnml_box_top"
>
S
egment
{{ n }}
</div>
<div
class=
"ui-widget-header ui-corner-top icnml_box_top"
>
{{ s
egment
s_position_code.get( n ) }} (F
{{ n }}
)
</div>
<div
class=
"ui-widget-content ui-corner-bottom icnml_box_content"
>
<div
class=
"ui-widget-content ui-corner-bottom icnml_box_content"
>
<div
id=
"segment_{{ n }}"
class=
"icnml_pointer"
>
<div
id=
"segment_{{ n }}"
class=
"icnml_pointer"
>
segment not available
segment not available
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment