Thread: [Openfirst-cvscommit] projects/admin editgroups.php,1.2,1.3 editprojects.php,1.1,1.2 edittasks.php,1
Brought to you by:
xtimg
From: <dav...@us...> - 2003-10-13 23:09:46
|
Update of /cvsroot/openfirst/projects/admin In directory sc8-pr-cvs1:/tmp/cvs-serv1617/admin Modified Files: editgroups.php editprojects.php edittasks.php Log Message: Fixed many script bugs and problems. They are not set to work accordingly. Index: editgroups.php =================================================================== RCS file: /cvsroot/openfirst/projects/admin/editgroups.php,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** editgroups.php 13 Oct 2003 03:32:33 -0000 1.2 --- editgroups.php 13 Oct 2003 23:09:43 -0000 1.3 *************** *** 61,64 **** --- 61,65 ---- $group = mysql_fetch_object($group_query); + // Edit assigned moderators if(isset($_POST['editmods'])){ *************** *** 72,75 **** --- 73,77 ---- } + // Edit assigned members to this task if(isset($_POST['editmembers'])){ *************** *** 92,108 **** </tr> </table> ! <p> </p> <form action="editgroups.php?GroupID=<?php echo $_GET['GroupID']; ?>" method="POST"> - <p><strong>Group Moderator List </strong></p> <p> ! <textarea name="moderators" cols="60" rows="10" id="moderators"><?php echo $group->Members; ?></textarea> ! </p> <p> <input name="editmods" type="submit" id="editmods" value="Edit Moderators"> ! </p> <p><strong>Group Member List</strong> </p> <p> <textarea name="members" cols="60" rows="10" id="members"><?php echo $group->Members; ?></textarea> ! </p> <p> <input name="editmembers" type="submit" id="editmembers" value="Edit Members"> --- 94,109 ---- </tr> </table> ! <p><strong>Group Moderator List </strong></p> <form action="editgroups.php?GroupID=<?php echo $_GET['GroupID']; ?>" method="POST"> <p> ! <textarea name="moderators" cols="60" rows="10" id="textarea"><?php echo $group->Moderators; ?></textarea> ! </p> <p> <input name="editmods" type="submit" id="editmods" value="Edit Moderators"> ! </p> <p><strong>Group Member List</strong> </p> <p> <textarea name="members" cols="60" rows="10" id="members"><?php echo $group->Members; ?></textarea> ! </p> <p> <input name="editmembers" type="submit" id="editmembers" value="Edit Members"> Index: editprojects.php =================================================================== RCS file: /cvsroot/openfirst/projects/admin/editprojects.php,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** editprojects.php 13 Oct 2003 22:48:28 -0000 1.1 --- editprojects.php 13 Oct 2003 23:09:43 -0000 1.2 *************** *** 42,53 **** // If a remove confirm is selected then allow the process to continue if(! isset($_POST['confirm'])){ ! echo "<br><br>Your request to remove the task was denied because you have not confirmed! [ <a href='tasks.php?GroupID=".$_GET['GroupID']."&ProjectID=".$_GET['ProjectID']."'>Tasks</a> ]<br><br>"; die(include($footer)); } // Remove every task related value in the database ! ofirst_dbquery("DELETE FROM ofirst_projects_projects WHERE ID = '".$_POST['task']."'") or die(ofirst_dberror()); ! ofirst_dbquery("DELETE FROM ofirst_projects_tasks WHERE ID = '".$_POST['task']."'") or die(ofirst_dberror()); ! ofirst_dbquery("DELETE FROM ofirst_projects_notes WHERE TaskID = '".$_POST['task']."'") or die(ofirst_dberror()); echo "<br><br>Project removed! [ <a href='index.php'>Main</a> ]<br><br>"; --- 42,53 ---- // If a remove confirm is selected then allow the process to continue if(! isset($_POST['confirm'])){ ! echo "<br><br>Your request to remove the task was denied because you have not confirmed! [ <a href='editprojects.php?&ProjectID=".$_GET['ProjectID']."'>Projects</a> ]<br><br>"; die(include($footer)); } // Remove every task related value in the database ! ofirst_dbquery("DELETE FROM ofirst_projects_projects WHERE ID = '".$_GET['ProjectID']."'") or die(ofirst_dberror()); ! ofirst_dbquery("DELETE FROM ofirst_projects_tasks WHERE ID = '".$_GET['ProjectID']."'") or die(ofirst_dberror()); ! ofirst_dbquery("DELETE FROM ofirst_projects_notes WHERE TaskID = '".$_GET['ProjectID']."'") or die(ofirst_dberror()); echo "<br><br>Project removed! [ <a href='index.php'>Main</a> ]<br><br>"; *************** *** 56,68 **** } ! $task_query = mysql_query("SELECT * FROM ofirst_projects_tasks WHERE ID = '".$_GET['ProjectID']."'"); ! $task = mysql_fetch_object($task_query); if(isset($_POST['editmembers'])){ ! mysql_query("UPDATE ofirst_projects_projects SET Assigned = '".$_POST['members']."' WHERE ID = '".$_GET['TaskID']."';"); ! $task_query = mysql_query("SELECT * FROM ofirst_projects_projects WHERE ID = '".$_GET['TaskID']."'"); ! $task = mysql_fetch_object($group_query); echo "<br>Members list has been updated!"; --- 56,69 ---- } ! $project_query = mysql_query("SELECT * FROM ofirst_projects_projects WHERE ID = '".$_GET['ProjectID']."'"); ! $project = mysql_fetch_object($project_query); + // Edit assigned members to project if(isset($_POST['editmembers'])){ ! mysql_query("UPDATE ofirst_projects_projects SET Assigned = '".$_POST['members']."' WHERE ID = '".$_GET['ProjectID']."';"); ! $project_query = mysql_query("SELECT * FROM ofirst_projects_projects WHERE ID = '".$_GET['ProjectID']."'"); ! $project = mysql_fetch_object($project_query); echo "<br>Members list has been updated!"; *************** *** 71,75 **** ?> ! <h2>Edit Project <font color="red"><?php echo $task->TaskName; ?></font></h2> <h2><font color="red"></font></h2> <table width="600"> --- 72,76 ---- ?> ! <h2>Edit Project <font color="red"><?php echo $project->ProjectName; ?></font></h2> <h2><font color="red"></font></h2> <table width="600"> *************** *** 81,88 **** </table> <p> </p> ! <form action="editgroups.php?GroupID=<?php echo $_GET['GroupID']; ?>" method="POST"> ! <p><strong>Group Member List</strong> </p> <p> ! <textarea name="members" cols="60" rows="10" id="members"><?php echo $task->Assigned; ?></textarea> </p> <p> --- 82,89 ---- </table> <p> </p> ! <form action="editprojects.php?ProjectID=<?php echo $_GET['ProjectID']; ?>" method="POST"> ! <p><strong>Assigned Members To Project </strong> </p> <p> ! <textarea name="members" cols="60" rows="10" id="members"><?php echo $project->Assigned; ?></textarea> </p> <p> Index: edittasks.php =================================================================== RCS file: /cvsroot/openfirst/projects/admin/edittasks.php,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** edittasks.php 13 Oct 2003 03:32:33 -0000 1.2 --- edittasks.php 13 Oct 2003 23:09:43 -0000 1.3 *************** *** 42,54 **** // If a remove confirm is selected then allow the process to continue if(! isset($_POST['confirm'])){ ! echo "<br><br>Your request to remove the task was denied because you have not confirmed! [ <a href='tasks.php?GroupID=".$_GET['GroupID']."&ProjectID=".$_GET['ProjectID']."'>Tasks</a> ]<br><br>"; die(include($footer)); } // Remove every task related value in the database ! ofirst_dbquery("DELETE FROM ofirst_projects_tasks WHERE ID = '".$_POST['task']."'") or die(ofirst_dberror()); ! ofirst_dbquery("DELETE FROM ofirst_projects_notes WHERE TaskID = '".$_POST['task']."'") or die(ofirst_dberror()); ! echo "<br><br>Task removed! [ <a href='tasks.php?GroupID=".$_GET['GroupID']."&ProjectID=".$_GET['ProjectID']."'>Projects</a> ]<br><br>"; die(include($footer)); --- 42,54 ---- // If a remove confirm is selected then allow the process to continue if(! isset($_POST['confirm'])){ ! echo "<br><br>Your request to remove the task was denied because you have not confirmed! [ <a href='edittasks.php?GroupID=".$_GET['TaskID']."'>Tasks</a> ]<br><br>"; die(include($footer)); } // Remove every task related value in the database ! ofirst_dbquery("DELETE FROM ofirst_projects_tasks WHERE ID = '".$_GET['TaskID']."'") or die(ofirst_dberror()); ! ofirst_dbquery("DELETE FROM ofirst_projects_notes WHERE TaskID = '".$_GET['TaskID']."'") or die(ofirst_dberror()); ! echo "<br><br>Task removed! [ <a href='../groups.php'>Main</a> ]<br><br>"; die(include($footer)); *************** *** 58,61 **** --- 58,63 ---- $task = mysql_fetch_object($task_query); + + // Edit assigned members to task if(isset($_POST['editmembers'])){ *************** *** 63,67 **** $task_query = mysql_query("SELECT * FROM ofirst_projects_tasks WHERE ID = '".$_GET['TaskID']."'"); ! $task = mysql_fetch_object($group_query); echo "<br>Members list has been updated!"; --- 65,69 ---- $task_query = mysql_query("SELECT * FROM ofirst_projects_tasks WHERE ID = '".$_GET['TaskID']."'"); ! $task = mysql_fetch_object($task_query); echo "<br>Members list has been updated!"; *************** *** 79,85 **** </tr> </table> ! <p> </p> ! <form action="editgroups.php?GroupID=<?php echo $_GET['GroupID']; ?>" method="POST"> ! <p><strong>Group Member List</strong> </p> <p> <textarea name="members" cols="60" rows="10" id="members"><?php echo $task->Assigned; ?></textarea> --- 81,86 ---- </tr> </table> ! <p><strong>Group Member List</strong> </p> ! <form action="edittasks.php?TaskID=<?php echo $_GET['TaskID']; ?>" method="POST"> <p> <textarea name="members" cols="60" rows="10" id="members"><?php echo $task->Assigned; ?></textarea> |