Skip to content

Commit

Permalink
Ver 7.1 release
Browse files Browse the repository at this point in the history
Ver 7.1 release
  • Loading branch information
openSISAdmin committed Dec 3, 2018
1 parent 4382c6c commit 1695484
Show file tree
Hide file tree
Showing 55 changed files with 4,135 additions and 532 deletions.
2 changes: 1 addition & 1 deletion Ajax.php
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@
array_rwalk($_REQUEST, 'strip_tags');
$title_set = '';

if (UserStudentID() && User('PROFILE') != 'parent' && User('PROFILE') != 'student' && substr(clean_param($_REQUEST['modname'], PARAM_NOTAGS), 0, 5) != 'Atten' && substr(clean_param($_REQUEST['modname'], PARAM_NOTAGS), 0, 5) != 'users' && clean_param($_REQUEST['modname'], PARAM_NOTAGS) != 'students/AddUsers.php' && (substr(clean_param($_REQUEST['modname'], PARAM_NOTAGS), 0, 10) != 'attendance' || clean_param($_REQUEST['modname'], PARAM_NOTAGS) == 'attendance/StudentSummary.php' || clean_param($_REQUEST['modname'], PARAM_NOTAGS) == 'attendance/DailySummary.php' || clean_param($_REQUEST['modname'], PARAM_NOTAGS) == 'attendance/AddAbsences.php')) {
if (UserStudentID() && User('PROFILE') != 'parent' && User('PROFILE') != 'student' && substr(clean_param($_REQUEST['modname'], PARAM_NOTAGS), 0, 5) != 'Atten' && substr(clean_param($_REQUEST['modname'], PARAM_NOTAGS), 0, 5) != 'users' && clean_param($_REQUEST['modname'], PARAM_NOTAGS) != 'students/AddUsers.php' && $_REQUEST['modname']!= 'tools/Backup.php' && (substr(clean_param($_REQUEST['modname'], PARAM_NOTAGS), 0, 10) != 'attendance' || clean_param($_REQUEST['modname'], PARAM_NOTAGS) == 'attendance/StudentSummary.php' || clean_param($_REQUEST['modname'], PARAM_NOTAGS) == 'attendance/DailySummary.php' || clean_param($_REQUEST['modname'], PARAM_NOTAGS) == 'attendance/AddAbsences.php')) {
$RET = DBGet(DBQuery("SELECT FIRST_NAME,LAST_NAME,MIDDLE_NAME,NAME_SUFFIX FROM students WHERE STUDENT_ID='" . UserStudentID() . "'"));
$count_student_RET = DBGet(DBQuery("SELECT COUNT(*) AS NUM FROM students"));
if ($count_student_RET[1]['NUM'] > 1) {
Expand Down
6 changes: 3 additions & 3 deletions ChooseCP.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

if ($_REQUEST['table_name'] != '' && $_REQUEST['table_name'] == 'course_periods') {

$sql = "SELECT COURSE_PERIOD_ID AS CHECKBOX,COURSE_PERIOD_ID,TITLE,COALESCE(TOTAL_SEATS-FILLED_SEATS,0) AS AVAILABLE_SEATS FROM course_periods WHERE COURSE_ID='$_REQUEST[id]'AND (marking_period_id IS NOT NULL AND marking_period_id IN(" . GetAllMP(GetMPTable(GetMP(UserMP(), 'TABLE')), UserMP()) . ") OR marking_period_id IS NULL AND '" . date('Y-m-d') . "' <= end_date) ORDER BY TITLE";
$sql = "SELECT COURSE_PERIOD_ID AS CHECKBOX,COURSE_PERIOD_ID,TITLE,SHORT_NAME,COALESCE(TOTAL_SEATS-FILLED_SEATS,0) AS AVAILABLE_SEATS FROM course_periods WHERE COURSE_ID='$_REQUEST[id]'AND (marking_period_id IS NOT NULL AND marking_period_id IN(" . GetAllMP(GetMPTable(GetMP(UserMP(), 'TABLE')), UserMP()) . ") OR marking_period_id IS NULL AND '" . date('Y-m-d') . "' <= end_date) ORDER BY TITLE";
$QI = DBQuery($sql);

$coursePeriods_RET = DBGet($QI);
Expand All @@ -23,7 +23,7 @@
$html.= '<table class="table table-bordered"><thead><tr class="alpha-grey"><th>&nbsp;</th><th>Course Periods</th><th>Available Seats</th></tr></thead>';
$html.= '<tbody>';
foreach ($coursePeriods_RET as $val) {
$html.= '<tr><td><input type="checkbox" id="course_' . $val['COURSE_PERIOD_ID'] . '" name="course_periods[' . $val['COURSE_PERIOD_ID'] . ']" value=' . $val['COURSE_PERIOD_ID'] . ' onchange="verify_schedule(this);"></td><td><a href=javascript:void(0); onclick="grab_coursePeriod(' . $val['COURSE_PERIOD_ID'] . ',\'course_periods\',\'subject_id\')">' . $val['TITLE'] . '</a></td><td>' . $val['AVAILABLE_SEATS'] . '</td></tr>';
$html.= '<tr><td><input type="checkbox" id="course_' . $val['COURSE_PERIOD_ID'] . '" name="course_periods[' . $val['COURSE_PERIOD_ID'] . ']" value=' . $val['COURSE_PERIOD_ID'] . ' onchange="verify_schedule(this);"></td><td><a href=javascript:void(0); onclick="grab_coursePeriod(' . $val['COURSE_PERIOD_ID'] . ',\'course_periods\',\'subject_id\')">' . $val['TITLE'].' - '.$val['SHORT_NAME'] . '</a></td><td>' . $val['AVAILABLE_SEATS'] . '</td></tr>';
// $html.= '<tr><td><input type="checkbox" id="course_'.$val['COURSE_PERIOD_ID'].'" name="course_periods['.$val['COURSE_PERIOD_ID'].']" value='.$val['COURSE_PERIOD_ID'].'></td><td><a href=javascript:void(0); onclick="scheduleCP('.$val['COURSE_PERIOD_ID'].')">'.$val['TITLE'].'</a></td><td>'.$val['AVAILABLE_SEATS'].'</td></tr>';
}
$html.='</tbody>';
Expand All @@ -47,7 +47,7 @@
$html.= '<tbody>';
foreach ($courses_RET as $val) {

$html.= '<tr><td><a href=javascript:void(0); onclick="grab_coursePeriod(' . $val['COURSE_ID'] . ',\'course_periods\',\'subject_id\')">' . $val['TITLE'] . '</a></td></tr>';
$html.= '<tr><td><a href=javascript:void(0); onclick="grab_coursePeriod(' . $val['COURSE_ID'] . ',\'course_periods\',\'subject_id\')">' . $val['GRADE_COURSE'] . '</a></td></tr>';
}
$html.= '</tbody>';
$html.= '</table>';
Expand Down
57 changes: 57 additions & 0 deletions CourseMoreInfo.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
<?php

#**************************************************************************
# openSIS is a free student information system for public and non-public
# schools from Open Solutions for Education, Inc. web: www.os4ed.com
#
# openSIS is web-based, open source, and comes packed with features that
# include student demographic info, scheduling, grade book, attendance,
# report cards, eligibility, transcripts, parent portal,
# student portal and more.
#
# Visit the openSIS web site at http://www.opensis.com to learn more.
# If you have question regarding this system or the license, please send
# an email to [email protected].
#
# This program is released under the terms of the GNU General Public License as
# published by the Free Software Foundation, version 2 of the License.
# See license.txt.
#
# 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, see <http://www.gnu.org/licenses/>.
#
#***************************************************************************************
include('RedirectRootInc.php');
include'ConfigInc.php';
include 'Warehouse.php';
$sql = 'SELECT
s.COURSE_ID,s.COURSE_PERIOD_ID,
s.MARKING_PERIOD_ID,s.START_DATE,s.END_DATE,s.MODIFIED_DATE,s.MODIFIED_BY,
UNIX_TIMESTAMP(s.START_DATE) AS START_EPOCH,UNIX_TIMESTAMP(s.END_DATE) AS END_EPOCH,sp.PERIOD_ID,
cpv.PERIOD_ID,s.MARKING_PERIOD_ID as COURSE_MARKING_PERIOD_ID,cp.MARKING_PERIOD_ID as mpa_id,cp.MP,sp.SORT_ORDER,
c.TITLE,cp.COURSE_PERIOD_ID AS PERIOD_PULLDOWN,
s.STUDENT_ID,r.TITLE AS ROOM,(SELECT GROUP_CONCAT(cpv.DAYS) FROM course_period_var cpv WHERE cpv.COURSE_PERIOD_ID=cp.COURSE_PERIOD_ID) as DAYS,SCHEDULER_LOCK,CONCAT(st.LAST_NAME, \'' . ' ' . '\' ,st.FIRST_NAME) AS MODIFIED_NAME
FROM courses c,course_periods cp,course_period_var cpv,rooms r,school_periods sp,schedule s
LEFT JOIN staff st ON s.MODIFIED_BY = st.STAFF_ID
WHERE
s.COURSE_ID = c.COURSE_ID AND s.COURSE_ID = cp.COURSE_ID
AND cp.COURSE_PERIOD_ID=cpv.COURSE_PERIOD_ID
AND r.ROOM_ID=cpv.ROOM_ID
AND s.COURSE_PERIOD_ID = cp.COURSE_PERIOD_ID
AND s.SCHOOL_ID = sp.SCHOOL_ID AND s.SYEAR = c.SYEAR AND sp.PERIOD_ID = cpv.PERIOD_ID
AND s.ID=' . $_REQUEST[id] . ' GROUP BY cp.COURSE_PERIOD_ID';

$QI = DBQuery($sql);
$schedule_RET = DBGet($QI, array('TITLE' => '_makeTitle', 'PERIOD_PULLDOWN' => '_makePeriodSelect', 'COURSE_MARKING_PERIOD_ID' => '_makeMPA', 'DAYS' => '_makeDays', 'SCHEDULER_LOCK' => '_makeViewLock', 'START_DATE' => '_makeViewDate', 'END_DATE' => '_makeViewDate', 'MODIFIED_DATE' => '_makeViewDate'));
$columns = array('TITLE' => 'Course ', 'PERIOD_PULLDOWN' => 'Period - Teacher', 'ROOM' => 'Room', 'DAYS' => 'Days of Week', 'COURSE_MARKING_PERIOD_ID' => 'Term', 'SCHEDULER_LOCK' => '<IMG SRC=assets/locked.gif border=0>', 'START_DATE' => 'Enrolled', 'END_DATE' => 'End Date/Drop Date', 'MODIFIED_NAME' => 'Modified By', 'MODIFIED_DATE' => 'Modified Date');
$options = array('search' => false, 'count' => false, 'save' => false, 'sort' => false);
ListOutput($schedule_RET, $columns, 'Course', 'Courses', $link, '', $options);

// echo '<br /><div align="center"><input type="button" class="btn btn-primary" value="Close" onclick="window.close();"></div>';
?>

2 changes: 1 addition & 1 deletion MassDropModal.php
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@
$html.='<tbody>';
foreach ($courses_RET as $val) {

$html.= '<tr><td><a href=javascript:void(0); onclick="MassDropModal(' . $val['COURSE_ID'] . ',\'course_periods\')">' . $val['TITLE'] . '</a></td></tr>';
$html.= '<tr><td><a href=javascript:void(0); onclick="MassDropModal(' . $val['COURSE_ID'] . ',\'course_periods\')">' . $val['GRADE_COURSE'] . '</a></td></tr>';
}
$html.='</tbody>';
$html.='</table>';
Expand Down
2 changes: 1 addition & 1 deletion MassScheduleModal.php
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@
$subject_id = DBGet(DBQuery('SELECT SUBJECT_ID FROM courses WHERE COURSE_ID=' . $val['COURSE_ID']));
// $html.= '<tr><td><a href=javascript:void(0); onclick="selectCpModal(\'course_div\',\''.$val['TITLE'].'\');">'.$val['TITLE'].'</a></td></tr>';
// $html.= '<tr><td><a href="Modules.php?modname=scheduling/MassSchedule.php&subject_id='.$subject_id[1]['SUBJECT_ID'].'&course_id='.$val['COURSE_ID'].'&modfunc=choose_course&course_period_id='.$val['COURSE_PERIOD_ID'].'" >'.$val['TITLE'].'</a></td></tr>';
$html.= '<tr><td><a href=javascript:void(0); onclick="MassScheduleSessionSet(\'' . $val['TITLE'] . '\',\'' . $subject_id[1]['SUBJECT_ID'] . '\',\'' . $val['COURSE_ID'] . '\',\'' . $val['COURSE_PERIOD_ID'] . '\');">' . $val['TITLE'] . '</a></td></tr>';
$html.= '<tr><td><a href=javascript:void(0); onclick="MassScheduleSessionSet(\'' . $val['TITLE'] . '\',\'' . $subject_id[1]['SUBJECT_ID'] . '\',\'' . $val['COURSE_ID'] . '\',\'' . $val['COURSE_PERIOD_ID'] . '\');">' . $val['TITLE'].' - '.$val['SHORT_NAME'] . '</a></td></tr>';
}
$html.='</tbody>';
$html.='</table>';
Expand Down
3 changes: 2 additions & 1 deletion Modules.php
Original file line number Diff line number Diff line change
Expand Up @@ -622,7 +622,8 @@
"eligibility" => "icon-checkmark3",
"messaging" => "icon-envelop5",
"tools" => "icon-hammer-wrench",
"billing" => "icon-calculator2"
"billing" => "icon-calculator2",
"discipline" => "icon-hammer2"
);

//echo "<li><a href='javascript:void(0)' onmouseup='check_content(\"Ajax.php?modname=miscellaneous/Portal.php\");' onmousedown='document.getElementById(\"header\").innerHTML = \"Home\";document.getElementById(\"cframe\").src = \"Bottom.php?modcat=home\"'><i class=\"icon-home4\"></i><span>" . "Home" . "</span></a></li>";
Expand Down
69 changes: 50 additions & 19 deletions TransferredOutModal.php
Original file line number Diff line number Diff line change
Expand Up @@ -104,8 +104,6 @@
}
else {

//echo '<BR>';
// PopTableforWindow('header', $title);
$sql = "SELECT ID,TITLE FROM schools WHERE ID !=" . UserSchool();
$sql2 = DBGet(DBQuery('SELECT ID,TITLE FROM schools WHERE ID !=' . UserSchool() . ' LIMIT 0,1'));
$sch_id = $sql2[1]['ID'];
Expand All @@ -122,22 +120,42 @@

$extraM .= 'onchange=grab_GradeLevel(this.value)';
$exg = 'id="grab_grade"';
echo "<FORM name=popform id=popform action=Modules.php?modname=$_REQUEST[modname]&modfunc=detail&student_id=" . UserStudentID() . "&drop_code=" . $_REQUEST['drop_code'] . " METHOD=POST>";
echo '<TABLE>';
echo '<TR><TD>Current school drop date</TD><TD>' . ' ' . DateInput_for_EndInputModal('', 'TRANSFER[STUDENT_ENROLLMENT_END_DATE]', '', $div, true) . '</TD></TR>';
echo '<TR><TD>Transferring to</TD><TD>' . SelectInputModal('', 'TRANSFER[SCHOOL]', '', $options, false, $extraM, 'class=cell_medium') . '</TD></TR>';
echo '<TR><TD>Grade Level</TD><TD>' . SelectInputModal('', 'TRANSFER[Grade_Level]', '', $options1, false, $exg, 'class=cell_medium') . '</TD></TR>';
echo '<TR><TD>New school\'s enrollment date</TD><TD>' . ' ' . DateInput_for_EndInputModal('', 'TRANSFER[STUDENT_ENROLLMENT_START]', '', $div, true) . '</TD></TR>';



echo '<TR><TD colspan=2 align=center><INPUT type=submit class="btn btn-primary" name=button value=Save>';
echo '&nbsp;';
echo '</TD></TR>';

echo '</TABLE>';
// PopTableWindow('footer');
echo '</FORM>';

echo '<div class="modal-header">';
echo '<button type="button" class="close" data-dismiss="modal">×</button>';
echo '<h5 class="modal-title">Transferred Out</h5>';
echo '</div>';
echo '<div class="modal-body">';
echo '<input type="hidden" name="values[student_enrollment]['.$_REQUEST['student_id'].'][DROP_CODE]" value="'.$_REQUEST['drop_code'].'" />';
echo '<div class="form-group datepicker-group">';
echo '<label class="control-label">Current school drop date</label>';
//echo DateInput_for_EndInputModal('', 'TRANSFER[STUDENT_ENROLLMENT_END_DATE]', '', $div, true);
echo custom_datepicker('222', 'TRANSFER[STUDENT_ENROLLMENT_END_DATE]');

echo '</div>';

echo '<div class="form-group">';
echo '<label class="control-label">Transferring to</label>';
echo SelectInputModal('', 'TRANSFER[SCHOOL]', '', $options, false, $extraM, 'class=cell_medium');
echo '</div>';

echo '<div class="form-group">';
echo '<label class="control-label">Grade Level</label>';
echo SelectInputModal('', 'TRANSFER[Grade_Level]', '', $options1, false, $exg, 'class=cell_medium');
echo '</div>';

echo '<div class="form-group">';
echo '<label class="control-label">New school\'s enrollment date</label>';
//echo DateInput_for_EndInputModal('', 'TRANSFER[STUDENT_ENROLLMENT_START]', '', $div, true);
echo custom_datepicker('223', 'TRANSFER[STUDENT_ENROLLMENT_START]');
echo '</div>';
echo '</div>'; //.modal-body

echo '<div class="modal-footer">';
echo '<INPUT type=submit class="btn btn-primary" name=button value=Save>';
echo '</div>';

//echo '</FORM>';

unset($_REQUEST['values']);
unset($_SESSION['_REQUEST_vars']['values']);
Expand All @@ -156,4 +174,17 @@
unset($_SESSION['_REQUEST_vars']['button']);
}
}
}
}

function custom_datepicker($id, $name) {
$dt.= '<div class="input-group datepicker-group" id="original_date_' . $id . '" value="" style="">';
$dt.= '<span class="input-group-addon"><i class="icon-calendar22"></i></span>';
$dt.= '<input id="date_' . $id . '" placeholder="Select Date" value="" class="form-control daterange-single" type="text">';
$dt.= '</div>';
$dt.= '<input value="" id="monthSelect_date_' . $id . '" name="month_' . $name . '" type="hidden">';
$dt.= '<input value="" id="daySelect_date_' . $id . '" name="day_' . $name . '" type="hidden">';
$dt.= '<input value="" id="yearSelect_date_' . $id . '" name="year_' . $name . '" type="hidden">';
echo $dt;
}

echo '<script type="text/javascript" src="assets/js/pages/picker_date.js"></script>';
Loading

0 comments on commit 1695484

Please sign in to comment.