From 0077cb99704fe863cf731fc5cab792af2ede96c2 Mon Sep 17 00:00:00 2001 From: Joseph Hunkeler Date: Sun, 17 Apr 2011 20:13:07 -0400 Subject: Backporting retarded amount of changes outside of version control --- modules/rudi/views/view.roster.php | 82 +++++++++++++++++++++++++++----------- 1 file changed, 59 insertions(+), 23 deletions(-) (limited to 'modules/rudi/views/view.roster.php') diff --git a/modules/rudi/views/view.roster.php b/modules/rudi/views/view.roster.php index c0ee92d..6d7d14f 100644 --- a/modules/rudi/views/view.roster.php +++ b/modules/rudi/views/view.roster.php @@ -1,23 +1,59 @@ - -db->query("SELECT * FROM `rudi_combat_units` WHERE `detachment` = 0"); - $row = $this->db->fetch($result); - foreach($row as $unit){ - echo ""; -?> - - - - - - - - -printRoster($unit['unit_id'], $unit['leader_id']); - $this->displayUnitsRec($unit['unit_id']); - } - -?> -
{$unit['name']} : {$unit['callsign']}
RankNameRoleWeaponStatus
- +
+
'; + +?> +
+
+ + + + + + + + + + + +printPastRoster(); + + }else { + + $result = $this->db->query("SELECT * FROM `rudi_combat_units` WHERE `detachment` = 0"); + $row = $this->db->fetch($result); + foreach($row as $unit){ + $unit_id = $unit['unit_id']; + decho("SELECT `member_id` FROM `rudi_unit_members` WHERE `cunit_id` = '$unit_id' AND `date_discharged` IS NULL LIMIT 1"); + $num = 0; + $check = $this->db->Query("SELECT `member_id` FROM `rudi_unit_members` WHERE `cunit_id` = '$unit_id' AND `date_discharged` IS NULL LIMIT 1"); + $num = $this->db->Rows($check); + if($num >= 1){ + echo ""; +?> + + + + + + + + +printRoster($unit['unit_id'], $unit['leader_id']); + $this->displayUnitsRec($unit['unit_id']); + } + } + $this->printReserves(); + } + +?> +
Past Members Roster
RankNameRoleTime in ServiceStatus
{$unit['name']} : {$unit['callsign']}
RankNameRoleWeaponStatus
+
-- cgit