[Openfirst-cvscommit] projects groups.php,1.3,1.4 index.php,1.4,1.5 meetings.php,NONE,1.1 mytask.php
Brought to you by:
xtimg
Update of /cvsroot/openfirst/projects In directory sc8-pr-cvs1:/tmp/cvs-serv3421 Added Files: groups.php index.php meetings.php mytask.php notes.php preferences.php projects.php tasks.php today.php viewmeeting.php Log Message: initial upload --- NEW FILE: meetings.php --- <?php /* * openFIRST.projects - meetings.php * * Copyright (C) 2003, * openFIRST Project * Original Author: David Di Biase <dav...@ea...> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ include("../config/globals.php"); $header_condense = true; include($header); if(ISSET($_POST['create'])){ if(! ISSET($_POST['assign'])){ echo "<br><br>You must assign an arranged for field to this meeting! Click back to continue.<br><br><br>"; die(include($footer)); } if(is_array($_POST['assign'])){ $assign = implode(",",$_POST['assign']); }else{ $assign = $_POST['assign']; } $fordate = strtotime($_POST['month']." ".$_POST['day'].",".$_POST['year']." ".$_POST['hour'].":".$_POST['minute']." ".$_POST['ampm']); mysql_query("INSERT INTO ofirst_projects_meetings SET ForDate = '".$fordate."', Description = '".$_POST['description']."', ArrangedFor = '".$assign."', AbsentList = 'none', Status = 'wait', Dates = '".time()."'") or die(mysql_error()); echo "<br><br>Meeting created! [ <a href='meetings.php'>Meetings</a> ]<br><br>"; die(include($footer)); } if(ISSET($_POST['remove'])){ if(! ISSET($_POST['confirm'])){ echo "<br><br>Your request to remove the project was denied because you have not confirmed! [ <a href='projects.php?GroupID=".$_GET['GroupID']."'>Projects</a> ]<br><br>"; die(include($footer)); } mysql_query("DELETE FROM ofirst_projects_meetings WHERE ID = '".$_POST['project']."'") or die(mysql_error()); echo "<br><br>Meetings removed! [ <a href='meetings.php'>Meetings</a> ]<br><br>"; die(include($footer)); } ?> <h2><font face="Verdana, Arial, Helvetica, sans-serif"> Meetings Organizer</font></h2> <table width="100%"> <tr> <th>Upcoming Meetings</th> </tr> </table> <table width="100%"> <tr bgcolor="#999999"> <td width="6%"> </td> <td width="21%"><div align="center"><strong>Date</strong></div></td> <td width="52%"><div align="center"><strong>Description</strong></div></td> <td width="21%"><div align="center"><strong>Arranged For</strong></div></td> </tr> <?php $meetquery = mysql_query("SELECT * FROM ofirst_projects_meetings WHERE Status='wait'"); while($meeting = mysql_fetch_object($meetquery)){ ?> <tr> <td><div align="center"><a href="viewmeeting.php?ID=<?php echo $meeting->ID; ?>"><img src="../members/icons/apps/date.png" width="32" height="32" border="0"></a></div></td> <td><?php echo date("F j, Y",$meeting->ForDate); ?></td> <td><?php echo $meeting->Description; ?></td> <td> <?php $assign = explode(",",$meeting->ArrangedFor); foreach($assign as $assign){ $query = mysql_query("SELECT * FROM ofirst_projects_groups WHERE ID = '".$assign."'"); $group = mysql_fetch_object($query); echo "<br>".$group->GroupName; } ?> </td> </tr> <?php } if(mysql_num_rows($meetquery) == 0){ echo "<tr><td> </td><td> </td><td>There are no planned meetings!</td><td> </td></tr>"; } ?> </table> <table width="100%"> <tr> <th>Past Meetings</th> </tr> </table> <table width="100%"> <tr bgcolor="#999999"> <td width="6%"> </td> <td width="21%"><div align="center"><strong>Date</strong></div></td> <td width="52%"><div align="center"><strong>Description</strong></div></td> <td width="21%"><div align="center"><strong>Arranged For</strong></div></td> </tr> <?php $query = mysql_query("SELECT * FROM ofirst_projects_meetings WHERE Status='done'"); while($meeting = mysql_fetch_object($query)){ ?> <tr> <td><div align="center"><a href="viewmeeting.php?ID=<?php echo $meeting->ID; ?>"><img src="../members/icons/apps/date.png" width="32" height="32" border="0"></a></div></td> <td><?php echo date("F j, Y",$meeting->ForDate); ?></td> <td><?php echo $meeting->Description; ?></td> <td> <?php $assign = explode(",",$meeting->ArrangedFor); foreach($assign as $assign){ $query = mysql_query("SELECT * FROM ofirst_projects_groups WHERE ID = '".$assign."'"); $group = mysql_fetch_object($query); echo $group->GroupName; } ?> </td> </tr> <?php } if(mysql_num_rows($query) == 0){ echo "<tr><td> </td><td> </td><td>There are no past meetings!</td><td> </td></tr>"; } ?> </table> <br> <form onsubmit="return dhtmlEditorPrepareSubmit();" action='meetings.php' method='POST'> <table width="64%"> <tr> <th width="19%"> </th> <th width="31%">Plan New Meeting</th> </tr> <tr> <td valign="top"> <div align="right">Description:</div></td> <td> <?php if (function_exists("make_wysiwyg")) { make_wysiwyg("description",500,255,""); }else{ echo "<textarea name='description'></textarea>"; } ?> </td> </tr> <tr> <td><div align="right">Meeting Date:</div></td> <td><select name="month" id="month"> <option selected><?php echo date("F",time()); ?></option> <option>----</option> <option>January</option> <option>February</option> <option>March</option> <option>April</option> <option>May</option> <option>June</option> <option>July</option> <option>August</option> <option>September</option> <option>October</option> <option>November</option> <option>December</option> </select> <select name="day" id="day"> <option selected><?php echo date("j",time()); ?></option> <option>----</option> <option>1</option> <option>2</option> <option>3</option> <option>4</option> <option>5</option> <option>6</option> <option>7</option> <option>8</option> <option>9</option> <option>10</option> <option>11</option> <option>12</option> <option>13</option> <option>14</option> <option>15</option> <option>16</option> <option>17</option> <option>18</option> <option>19</option> <option>20</option> <option>21</option> <option>22</option> <option>23</option> <option>24</option> <option>25</option> <option>26</option> <option>27</option> <option>28</option> <option>29</option> <option>30</option> <option>31</option> </select> , <select name="year" id="year"> <option selected><?php echo date("Y",time()); ?></option> <option>----</option> <option>2003</option> <option>2004</option> <option>2005</option> <option>2006</option> <option>2007</option> <option>2008</option> <option>2009</option> <option>2010</option> </select> <input name="hour" type="text" id="hour" size="2"> : <input name="minute" type="text" id="minute" size="2"> <select name="ampm" id="ampm"> <option selected>AM</option> <option>PM</option> </select> </td> </tr> <tr> <td><div align="right">Arranged For:</div></td> <td><p> <select name="assign[]" width='40' size="6" multiple id="assign"> <?php $query = mysql_query("SELECT * FROM ofirst_projects_groups"); while($group = mysql_fetch_object($query)){ echo "<option value='".$group->ID."'>".$group->GroupName."</option>"; } ?> </select> <font size="2"></font></p></td> </tr> <tr> <td> </td> <td><input name="create" type="submit" id="create2" value="Create Meeting"> <input type="reset" name="Reset" value="Reset"> </td> </tr> <tr> <th> </th> <th>Remove Meeting</th> </tr> <tr> <td><div align="right">Meeting Date:</div></td> <td><select name="project" id="project"> <?php $query = mysql_query("SELECT * FROM ofirst_projects_meetings"); while($meeting = mysql_fetch_object($query)){ echo "<option value='".$meeting->ID."'>".date("F j, Y h:i a",$meeting->ForDate)."</option>"; } ?> </select></td> </tr> <tr> <td><div align="right"> <input name="confirm" type="checkbox" id="confirm" value="checkbox"> </div></td> <td>Click here to confirm the removal of this meeting. Without checking the meeting will not be removed.</td> </tr> <tr> <td> </td> <td><input name="remove" type="submit" id="remove" value="Remove"></td> </tr> </table> <br> <?php include($footer); ?> --- NEW FILE: mytask.php --- <?php /* * openFIRST.projects - mytask.php * * Copyright (C) 2003, * openFIRST Project * Original Author: David Di Biase <dav...@ea...> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ include("../config/globals.php"); $header_condense = true; include($header); ?> <h2>My Tasks Summarized</h2> <p>The information listed below is a list of summarized tasks that you have been assigned to.</p> <table width="100%" border="0" cellspacing="0" cellpadding="6"> <tr> <td bgcolor="#666666"> <div align="center"><font color="#FFFFFF">Your Current Tasks </font></div></td> </tr> </table> <table width="100%" bordercolor="#999999"> <tr bgcolor="#999999"> <td width="4%"> </td> <td width="20%">Task Name</td> <td width="13%">Target Date</td> <td width="33%">Description</td> <td width="30%">Assigned</td> </tr> <?php $query = mysql_query("SELECT * FROM ofirst_projects_tasks"); while($tasks = mysql_fetch_object($query)){ $showtask = false; $assigned = explode(",",$tasks->Assigned); foreach($assigned As $member){ if($member == $user->user){ $showtask = true; } } if($showtask){ if($tasks->Pend == "none"){ $pend = false; }else{ $taskquery = mysql_query("SELECT * FROM ofirst_projects_tasks WHERE ID = '".$tasks->Pend."'"); $pendtask = mysql_fetch_object($taskquery); if($pendtask->Completion == 100){ $pend = false; }else{ $pend = true; } } } ?> <tr onMouseOver="this.style.backgroundColor='#cccccc'" onMouseOut="this.style.backgroundColor='#ffffff'" <?php if(date("F j, Y",time()) == date("F j, Y",$tasks->Dates)){ echo "bgColor='#CCCCCC'"; } ?>> <td><a href="notes.php?GroupID=<?php echo $_GET['GroupID']; ?>&TaskID=<?php echo $tasks->ID; ?>&ProjectID=<?php echo $_GET['ProjectID']; ?>"> <?php if($pend){ echo "<img src='../members/icons/actions/encrypted.png' border='0'>"; }else{ echo "<a href='notes.php?GroupID=".$tasks->GroupID."&TaskID=".$tasks->ID."&ProjectID=".$tasks->ProjectID."'><img src='../members/icons/filesystems/desktop.png' border='0'></a>"; } ?> </a></td> <td> <?php echo $tasks->TaskName." ("; if(! $pend){ echo $tasks->Completion."%"; }else{ echo "PEND ON: ".$pendtask->TaskName; } echo ")"; ?> </td> <td> <?php echo date("F j, Y",$tasks->TarDate); ?> </td> <td><?php echo $tasks->Description; ?></td> <td><?php echo $tasks->Assigned; ?></td> </tr> <? } if(mysql_num_rows($query) == 0){ echo "\n <tr>\n <td> </td>\n <td> </td>\n <td> </td>\n <td>There are no tasks for this project!</td>\n <td> </td>"; } ?> </table> <br> <?php include($footer); ?> --- NEW FILE: today.php --- <?php /* * openFIRST.projects - today.php * * Copyright (C) 2003, * openFIRST Project * Original Author: David Di Biase <dav...@ea...> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ include("../config/globals.php"); $header_condense = true; include($header); if(ISSET($_POST['viewdate'])){ $selectdate = $_POST['month']." ".$_POST['day'].", ".$_POST['year']; }else{ $selectdate = date("F j, Y",time()); } ?> <h2>Todays Changes</h2> <form method="post" action="today.php"> <p>View Updates For: <select name="month" id="month"> <option selected><?php echo date("F",time()); ?></option> <option>----</option> <option>January</option> <option>February</option> <option>March</option> <option>April</option> <option>May</option> <option>June</option> <option>July</option> <option>August</option> <option>September</option> <option>October</option> <option>November</option> <option>December</option> </select> / <select name="day" id="day"> <option selected><?php echo date("j",time()); ?></option> <option>----</option> <option>1</option> <option>2</option> <option>3</option> <option>4</option> <option>5</option> <option>6</option> <option>7</option> <option>8</option> <option>9</option> <option>10</option> <option>11</option> <option>12</option> <option>13</option> <option>14</option> <option>15</option> <option>16</option> <option>17</option> <option>18</option> <option>19</option> <option>20</option> <option>21</option> <option>22</option> <option>23</option> <option>24</option> <option>25</option> <option>26</option> <option>27</option> <option>28</option> <option>29</option> <option>30</option> <option>31</option> </select> / <select name="year" id="year"> <option selected><?php echo date("Y",time()); ?></option> <option>----</option> <option>2004</option> <option>2003</option> <option>2002</option> <option>2001</option> <option>2000</option> </select> <input name="viewdate" type="submit" id="viewdate" value="View Date"> </p> </form> <table width="100%" border="0" cellspacing="0" cellpadding="6"> <tr> <th> <div align="center">Notes commited on <strong><?php echo $selectdate; ?></strong></div></th> </tr> </table> <?php $groupquery = mysql_query("SELECT * FROM ofirst_projects_groups"); while($group = mysql_fetch_object($groupquery)){ ?> <table width="100%" border="0" cellspacing="0" cellpadding="6"> <tr> <td bgcolor="#CCCCCC"> <div align="center"><font color="#000000"><strong><?php echo $group->GroupName; ?></strong></font></div></td> </tr> </table> <table width="100%"> <tr bgcolor="#999999"> <td width="4%"> </td> <td width="14%">Change</td> <td width="15%">Project</td> <td width="14%">Task</td> <td width="35%">Decsription</td> <td width="18%">Assigned/Commiter</td> </tr> <?php $projectquery = mysql_query("SELECT * FROM ofirst_projects_projects WHERE GroupID = '".$group->ID."'"); while($project = mysql_fetch_object($projectquery)){ if($selectdate == date("F j, Y",$project->Dates)){ ?> <tr onMouseOver="this.style.backgroundColor='#cccccc'" onMouseOut="this.style.backgroundColor='#ffffff'"> <td><img src="../members/icons/actions/project_open.png" width="32" height="32"></td> <td>New Project</td> <td><font color='red'><?php echo $project->ProjectName; ?></font></td> <td>--</td> <td><?php echo $project->Description; ?></td> <td><?php echo $project->Assigned; ?></td> </tr> <?php } } $taskquery = mysql_query("SELECT * FROM ofirst_projects_tasks WHERE GroupID = '".$group->ID."'"); while($task = mysql_fetch_object($taskquery)){ $taskprojquery = mysql_query("SELECT ProjectName FROM ofirst_projects_projects WHERE ID = '".$task->ProjectID."'"); $taskproject = mysql_fetch_object($taskprojquery); if($selectdate == date("F j, Y",$task->Dates)){ ?> <tr onMouseOver="this.style.backgroundColor='#cccccc'" onMouseOut="this.style.backgroundColor='#ffffff'"> <td><img src="../members/icons/filesystems/desktop.png" width="32" height="32"></td> <td>New Task</td> <td><?php echo $taskproject->ProjectName; ?></td> <td><font color='red'><?php echo $task->TaskName; ?></font></td> <td><?php echo $task->Description; ?></td> <td><?php echo $task->Assigned; ?></td> </tr> <?php } } $notequery = mysql_query("SELECT * FROM ofirst_projects_notes WHERE GroupID = '".$group->ID."'"); while($note = mysql_fetch_object($notequery)){ $noteprojquery = mysql_query("SELECT ProjectName FROM ofirst_projects_projects WHERE ID = '".$note->ProjectID."'"); $noteproject = mysql_fetch_object($noteprojquery); $notetasquery = mysql_query("SELECT * FROM ofirst_projects_tasks WHERE ID = '".$note->TaskID."'"); $notetask = mysql_fetch_object($notetasquery); if($selectdate == date("F j, Y",$note->Dates)){ ?> <tr onMouseOver="this.style.backgroundColor='#cccccc'" onMouseOut="this.style.backgroundColor='#ffffff'"> <td><img src="../members/icons/filesystems/files.png" width="32" height="32"></td> <td>New Note Commited</td> <td><?php echo $noteproject->ProjectName; ?></td> <td><?php echo $notetask->TaskName; ?></td> <td><font color='red'><?php echo $note->Description; ?></font></td> <td><?php echo $note->Commiter; ?></td> </tr> <?php } } ?> </table> <?php } ?> <br><br> <?php include($footer); ?> --- NEW FILE: viewmeeting.php --- <?php /* * openFIRST.projects - viewmeeting.php * * Copyright (C) 2003, * openFIRST Project * Original Author: David Di Biase <dav...@ea...> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ include("../config/globals.php"); $header_condense = true; include($header); if(ISSET($_POST['update'])){ if(! ISSET($_POST['absent'])){ echo "<br><br>You must select users who were absent of click none! Click back to continue.<br><br><br>"; die(include($footer)); } if(is_array($_POST['absent'])){ $absentlist = implode(",",$_POST['absent']); }else{ $absentlist = $_POST['absent']; } mysql_query("UPDATE ofirst_projects_meetings SET Notes = '".$_POST['notes']."', AbsentList = '$absentlist', Status = 'done' WHERE ID = '".$_GET['ID']."'") or die(mysql_error()); echo "<br><br>Meeting updated! [ <a href='meetings.php'>Meetings</a> ]<br><br>"; die(include($footer)); } $query = mysql_query("SELECT * FROM ofirst_projects_meetings WHERE ID = '".$_GET['ID']."'"); $meeting = mysql_fetch_object($query); ?> <h2>Meeting Viewer</h2> <table width="64%"> <tr> <th width="24%"> </th> <th width="76%">Meeting for <?php echo date("F j, Y",$meeting->ForDate); ?></th> </tr> <tr> <td valign="top"> <div align="right"><strong>Description:</strong></div></td> <td><?php echo $meeting->Description; ?></td> </tr> <tr> <td><div align="right"><strong>Arranged For:</strong></div></td> <td><p> <?php $assign = explode(",",$meeting->ArrangedFor); foreach($assign as $assign){ $query = mysql_query("SELECT * FROM ofirst_projects_groups WHERE ID = '".$assign."'"); $group = mysql_fetch_object($query); echo "<br>".$group->GroupName; } ?> </p></td> </tr> <?php if($meeting->Status == "done"){ ?> <tr> <td><div align="right"><strong>Notes:</strong></div></td> <td><?php echo $meeting->Notes; ?></td> </tr> <tr> <td><div align="right"><strong>Absent List:</strong></div></td> <td><?php echo $meeting->AbsentList; ?></td> </tr> <?php } ?> </table> <br> <?php if($meeting->Status != "done"){ ?> <form onsubmit="return dhtmlEditorPrepareSubmit();" action='viewmeeting.php?ID=<?php echo $_GET['ID']; ?>' method='POST'> <table width="48%"> <tr> <th width="19%"> </th> <th width="31%">Plan New Meeting</th> </tr> <tr> <td valign="top"> <div align="right">Notes:</div></td> <td> <?php if (function_exists("make_wysiwyg")) { make_wysiwyg("description",500,255,""); }else{ echo "<textarea name='description'></textarea>"; } ?> </td> </tr> <tr> <td><div align="right">Please list the people who were <strong>NOT</strong> present::</div></td> <td><p> <select name="absent[]" width='60' size="6"> <option>none</option><?php $assign = explode(",",$meeting->ArrangedFor); foreach($assign as $assign){ $query = mysql_query("SELECT * FROM ofirst_projects_groups WHERE ID = '".$assign."'"); $group = mysql_fetch_object($query); $people = explode(",",$group->Members); $people = array_unique($people); } foreach($people as $people){ echo "\n <option>$people</option>"; } ?> </select> <font size="2"></font></p></td> </tr> <tr> <td> </td> <td><input name="update" type="submit" id="update" value="Update Meeting"> <input type="reset" name="Reset" value="Reset"> </td> </tr> </table></form> <p><br> <?php } include($footer); ?> </p> |