[opw-web] Fix up "View Accepted Projects" button
- From: Owen Taylor <otaylor src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [opw-web] Fix up "View Accepted Projects" button
- Date: Mon, 21 Apr 2014 14:50:27 +0000 (UTC)
commit 6084045beae391b9fb4577bf9d811da03f5e3996
Author: Owen W. Taylor <otaylor fishsoup net>
Date: Sun Apr 20 00:14:32 2014 -0400
Fix up "View Accepted Projects" button
* Show on the front page for all users logged in or not.
* Link to wiki.gnome.org accepted participants list.
modules/mod_program_home.php | 4 +++-
skins/easterngreen/html/tpl_program_home.html | 10 +++++-----
2 files changed, 8 insertions(+), 6 deletions(-)
---
diff --git a/modules/mod_program_home.php b/modules/mod_program_home.php
index 8dffe54..1ac0ffb 100644
--- a/modules/mod_program_home.php
+++ b/modules/mod_program_home.php
@@ -19,6 +19,7 @@ if ($program_data != null)
// Set object availability based on deadlines
$show_mentor = true;
+ $show_started = false;
$project_permissions = get_project_permissions($program_data, $role, null);
@@ -28,6 +29,7 @@ if ($program_data != null)
if ($core->timestamp >= $program_data['dl_mentor'])
{
$show_mentor = false;
+ $show_started = true;
}
// Set deadlines placeholders
@@ -99,7 +101,7 @@ if ($program_data != null)
'dl_student_visibility' => $skin->visibility($show_student),
'late_submission_visibility' => $skin->visibility($late_submission),
'dl_mentor_visibility' => $skin->visibility($show_mentor),
- 'started_visibility' => $skin->visibility($role == 'g' && !($show_student || $show_mentor)),
+ 'started_visibility' => $skin->visibility($show_started),
'prog_adm_visibility' => $skin->visibility($user->is_admin),
'modadm_visibility' => $skin->visibility($user->is_admin),
));
diff --git a/skins/easterngreen/html/tpl_program_home.html b/skins/easterngreen/html/tpl_program_home.html
index fd456f4..65fb872 100644
--- a/skins/easterngreen/html/tpl_program_home.html
+++ b/skins/easterngreen/html/tpl_program_home.html
@@ -148,10 +148,10 @@
[[role_message]]
</h4>
</div>
-
- <a href="?q=view_projects&prg=[[program_id]]&a=accepted" class="btn btn-large
[[started_visibility]]">
- <img src="[[skin_path]]/images/projects.png" width="26" height="26" alt="" />
- {{view_accepted}}
- </a>
</div>
+
+ <a href="https://wiki.gnome.org/OutreachProgramForWomen/2014/MayAugust#Accepted_Participants" class="btn
btn-large [[started_visibility]]">
+ <img src="[[skin_path]]/images/projects.png" width="26" height="26" alt="" />
+ {{view_accepted}}
+ </a>
</div>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]