Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
F
final_project
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
evilla_gomez_guian_principe
final_project
Commits
3a7c9976
Commit
3a7c9976
authored
Jul 20, 2016
by
Wills Gomez
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of
https://gitlab.discs.ateneo.edu/evilla_gomez_guian_principe/final_project
parents
9625922a
2e43fdba
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
33 additions
and
22 deletions
+33
-22
show.html.erb
Halalan-trial/app/views/admin/candidates/show.html.erb
+16
-7
show.html.erb
Halalan-trial/app/views/admin/positions/show.html.erb
+17
-5
index.html.erb
Halalan-trial/app/views/pages/index.html.erb
+0
-10
No files found.
Halalan-trial/app/views/admin/candidates/show.html.erb
View file @
3a7c9976
<%
provide
(
:candidate
,
"active"
)
%>
<%
provide
(
:candidate
,
"active"
)
%>
<%
provide
(
:title
,
"
#{
@candidate
.
full_name
}
"
)
%>
<%
provide
(
:title
,
"
#{
@candidate
.
full_name
}
"
)
%>
<style>
p
{
display
:
inline
;
}
h1
{
display
:
inline
}
</style>
<div
class=
"container"
>
<div
class=
"container"
>
<div
class=
"row"
>
<div
class=
"row"
>
<div
class=
"col-md-12"
>
<div
class=
"col-md-12"
>
<h1>
Name of the Candidate:
<%=
@candidate
.
full_name
%>
</h1>
<br>
<h1><font
size=
"20"
>
<%=
@candidate
.
full_name
%>
</font></h1>
<p>
<%=
link_to
"Edit"
,
edit_admin_candidate_path
(
@candidate
.
id
)
%>
<%=
link_to
"Edit"
,
edit_admin_candidate_path
(
@candidate
.
id
)
%>
<br>
<%=
link_to
"Delete"
,
admin_candidate_path
(
@candidate
.
id
),
method: :delete
%>
<%=
link_to
"Delete"
,
admin_candidate_path
(
@candidate
.
id
),
method: :delete
%>
<
br
>
<
/p
>
<h
3>
Position:
<%=
@candidate
.
position
.
name
%>
</h3
>
<h
2>
<%=
@candidate
.
position
.
name
%>
</h2
>
<%
<%
m
=
0
m
=
0
f
=
0
f
=
0
...
@@ -29,7 +40,7 @@
...
@@ -29,7 +40,7 @@
%>
%>
<%
end
%>
<%
end
%>
<br>
<br>
<h3>
Slogan:
<%=
@candidate
.
slogan
%>
</h3>
<h3>
"
<%=
@candidate
.
slogan
%>
"
</h3>
<br>
<br>
<center>
<center>
<table
class=
"table table-hover"
>
<table
class=
"table table-hover"
>
...
@@ -62,8 +73,6 @@
...
@@ -62,8 +73,6 @@
<%
end
%>
<%
end
%>
</ul>
</ul>
<hr>
<%=
link_to
"Back to Candidates"
,
admin_candidates_path
%>
</div>
</div>
</div>
</div>
</div>
</div>
\ No newline at end of file
Halalan-trial/app/views/admin/positions/show.html.erb
View file @
3a7c9976
<%
provide
(
:position
,
"active"
)
%>
<%
provide
(
:position
,
"active"
)
%>
<%
provide
(
:title
,
"
#{
@position
.
name
}
"
)
%>
<%
provide
(
:title
,
"
#{
@position
.
name
}
"
)
%>
<style>
p
{
margin-bottom
:
0
;
padding-bottom
:
0
;
display
:
inline
;
}
h1
{
display
:
inline
}
</style>
<div
class=
"container"
>
<div
class=
"container"
>
<div
class=
"row"
>
<div
class=
"row"
>
<div
class=
"col-md-12"
>
<div
class=
"col-md-12"
>
<h1>
<
%=
@position
.
name
%
>
</h1>
<h1><
font
size=
"20"
>
<%=
@position
.
name
%>
</font
></h1>
<p>
<%=
link_to
"Edit"
,
edit_admin_position_path
(
@position
.
id
)
%>
<%=
link_to
"Edit"
,
edit_admin_position_path
(
@position
.
id
)
%>
<br>
<%=
link_to
"Delete"
,
admin_position_path
(
@position
.
id
),
method: :delete
%>
<%=
link_to
"Delete"
,
admin_position_path
(
@position
.
id
),
method: :delete
%>
<br>
</p>
<hr>
<hr>
<h2>
Candidates for
<%=
@position
.
name
%>
</h2>
<h2>
Candidates for
<%=
@position
.
name
%>
</h2>
...
@@ -18,8 +29,9 @@
...
@@ -18,8 +29,9 @@
<li>
<%=
link_to
c
.
full_name
,
admin_candidate_path
(
c
.
id
)
%>
</li>
<li>
<%=
link_to
c
.
full_name
,
admin_candidate_path
(
c
.
id
)
%>
</li>
<%
end
%>
<%
end
%>
</ul>
</ul>
<br>
<%=
link_to
"Back to Positions"
,
admin_positions_path
%>
<%=
link_to
"
<
Back to Positions"
,
admin_positions_path
%>
</div>
</div>
</div>
</div>
</div>
</div>
\ No newline at end of file
Halalan-trial/app/views/pages/index.html.erb
View file @
3a7c9976
...
@@ -4,16 +4,6 @@
...
@@ -4,16 +4,6 @@
<div
class =
"container"
>
<div
class =
"container"
>
<div
class=
"row"
>
<div
class=
"row"
>
<div
class=
"col-md-12"
>
<div
class=
"col-md-12"
>
<%
if
user_signed_in?
%>
<%
case
current_user
.
role
%>
<%
when
'voter'
%>
<h3>
Welcome,
<%=
current_user
.
first_name
%>
!
</h3>
<%
when
'admin'
%>
<h3>
Welcome, Administrator
</h3>
<%
end
%>
<%
else
%>
<h3>
Welcome
</h3>
<%
end
%>
<h1><center>
Current Vote Tally
</center></h1>
<h1><center>
Current Vote Tally
</center></h1>
<hr>
<hr>
<%
@positions
.
each
do
|
p
|
%>
<%
@positions
.
each
do
|
p
|
%>
...
...
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