当前位置: 首页>>代码示例>>PHP>>正文


PHP ListOutput函数代码示例

本文整理汇总了PHP中ListOutput函数的典型用法代码示例。如果您正苦于以下问题:PHP ListOutput函数的具体用法?PHP ListOutput怎么用?PHP ListOutput使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了ListOutput函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: DBGet

$begin_year = DBGet(DBQuery("SELECT min(unix_timestamp(SCHOOL_DATE)) as SCHOOL_DATE FROM ATTENDANCE_CALENDAR WHERE SCHOOL_ID='" . UserSchool() . "' AND SYEAR='" . UserSyear() . "'"));
$begin_year = $begin_year[1]['SCHOOL_DATE'];
if ($start && $begin_year) {
    $date_select = "<OPTION value={$start}>" . date('M d, Y', $start) . ' - ' . date('M d, Y', $end) . '</OPTION>';
    for ($i = $start - 60 * 60 * 24 * 7; $i >= $begin_year; $i -= 60 * 60 * 24 * 7) {
        $date_select .= "<OPTION value={$i}" . ($i + 86400 >= $start_time && $i - 86400 <= $start_time ? ' SELECTED' : '') . ">" . date('M d, Y', $i) . ' - ' . date('M d, Y', $i + 1 + ($END_DAY - $START_DAY) * 60 * 60 * 24) . '</OPTION>';
    }
}
DrawHeaderHome('<SELECT name=start_date>' . $date_select . '</SELECT>' . $period_select, '<INPUT type=submit class=btn_medium value=Go onclick=\'formload_ajax("teach_comp");\'>');
echo '</FORM>';
$sql = "SELECT CONCAT(s.LAST_NAME,', ',s.FIRST_NAME) AS FULL_NAME,sp.TITLE,cp.PERIOD_ID,s.STAFF_ID \n\t\tFROM STAFF s,COURSE_PERIODS cp,SCHOOL_PERIODS sp \n\t\tWHERE \n\t\t\tsp.PERIOD_ID = cp.PERIOD_ID\n\t\t\tAND cp.TEACHER_ID=s.STAFF_ID AND cp.MARKING_PERIOD_ID IN (" . GetAllMP('QTR', UserMP()) . ")\n\t\t\tAND cp.SYEAR='" . UserSyear() . "' AND cp.SCHOOL_ID='" . UserSchool() . "' AND s.PROFILE='teacher'\n\t\t\t" . ($_REQUEST['period'] ? " AND cp.PERIOD_ID='{$_REQUEST['period']}'" : '') . "\n\t\t\tAND NOT EXISTS (SELECT '' FROM ELIGIBILITY_COMPLETED ac WHERE ac.STAFF_ID=cp.TEACHER_ID AND ac.PERIOD_ID = sp.PERIOD_ID AND ac.SCHOOL_DATE BETWEEN '" . date('Y-m-d', $start_time) . "' AND '" . date('Y-m-d', $start_time + 60 * 60 * 24 * 7) . "')";
$RET = DBGet(DBQuery($sql), array(), array('STAFF_ID', 'PERIOD_ID'));
$i = 0;
if (count($RET)) {
    foreach ($RET as $staff_id => $periods) {
        $i++;
        $staff_RET[$i]['FULL_NAME'] = $periods[key($periods)][1]['FULL_NAME'];
        foreach ($periods as $period_id => $period) {
            $staff_RET[$i][$period_id] = '<IMG SRC=assets/x.gif>';
        }
    }
}
$columns = array('FULL_NAME' => 'Teacher');
if (!$_REQUEST['period']) {
    foreach ($periods_RET as $period) {
        $columns[$period['PERIOD_ID']] = $period['TITLE'];
    }
}
echo '<div style=" width:800px; background-color:transparent; overflow-x:scroll; overflow-y:hidden;">';
ListOutput($staff_RET, $columns, 'Teacher who hasn\'t entered eligibility', 'Teachers who haven\'t entered eligibility');
echo "</div>";
开发者ID:SoftScape,项目名称:opensis,代码行数:31,代码来源:TeacherCompletion.php

示例2: con_date

    $org_start_date = $_REQUEST['day_start'] . '-' . $_REQUEST['month_start'] . '-' . $_REQUEST['year_start'];
    $conv_st_date = con_date($org_start_date);
}
if ($_REQUEST['day_end'] && $_REQUEST['month_end'] && $_REQUEST['year_end']) {
    $end_date = $_REQUEST['day_end'] . '-' . $_REQUEST['month_end'] . '-' . substr($_REQUEST['year_end'], 2, 4);
    $org_end_date = $_REQUEST['day_end'] . '-' . $_REQUEST['month_end'] . '-' . $_REQUEST['year_end'];
    $conv_end_date = con_date_end($org_end_date);
}
if ($_REQUEST['modfunc'] == 'generate') {
    if (isset($conv_st_date) && isset($conv_end_date)) {
        #$alllogs_RET = DBGet(DBQuery("SELECT DISTINCT FIRST_NAME,LAST_NAME,LOGIN_TIME,PROFILE,FAILLOG_COUNT,FAILLOG_TIME,USER_NAME,IP_ADDRESS,STATUS FROM login_records WHERE LOGIN_TIME >='".$conv_st_date."' AND LOGIN_TIME <='".$conv_end_date."' AND SCHOOL_ID=".UserSchool()." OR STATUS='Failed'  ORDER BY LOGIN_TIME DESC"));
        $alllogs_RET = DBGet(DBQuery('SELECT DISTINCT FIRST_NAME,LAST_NAME,LOGIN_TIME,PROFILE,FAILLOG_COUNT,FAILLOG_TIME,USER_NAME,IP_ADDRESS,STATUS FROM login_records WHERE LOGIN_TIME >=\'' . $conv_st_date . '\' AND LOGIN_TIME <=\'' . $conv_end_date . '\' AND SCHOOL_ID=' . UserSchool() . ' ORDER BY LOGIN_TIME DESC'));
        if (count($alllogs_RET)) {
            echo '<div>';
            #ListOutput($alllogs_RET,array('LOGIN_TIME'=>'Login Time','USER_NAME'=>'User Name','FIRST_NAME'=>'First Name','LAST_NAME'=>'Last Name','FAILLOG_COUNT'=>'Failure Count','STATUS'=>'Status','IP_ADDRESS'=>'IP Address'),'login record','login records',array(),array(),array('count'=>true,'save'=>true));
            ListOutput($alllogs_RET, array('LOGIN_TIME' => 'Login Time', 'USER_NAME' => 'User Name', 'FIRST_NAME' => 'First Name', 'LAST_NAME' => 'Last Name', 'PROFILE' => 'Profile', 'FAILLOG_COUNT' => 'Failure Count', 'STATUS' => 'Status', 'IP_ADDRESS' => 'IP Address'), 'login record', 'login records', array(), array(), array('count' => true, 'save' => true));
            echo '</div>';
        } else {
            echo '<table border=0 width=90%><tr><td class="alert"></td><td class="alert_msg"><b>No login records were found.</b></td></tr></table>';
        }
    }
    if (!isset($conv_st_date) || !isset($conv_end_date)) {
        echo '<center><font color="red"><b>You have to select date from the date range</b></font></center>';
    }
}
function con_date($date)
{
    $mother_date = $date;
    $year = substr($mother_date, 7);
    $temp_month = substr($mother_date, 3, 3);
    if ($temp_month == 'JAN') {
开发者ID:26746647,项目名称:openSIS,代码行数:31,代码来源:LogDetails.php

示例3: DBGet

         }
     }
     if ($_REQUEST['modfunc'] != 'remove') {
         $maintain_RET = DBGet(DBQuery("SELECT SYSTEM_MAINTENANCE_SWITCH FROM system_preference_misc LIMIT 1"));
         $maintain = $maintain_RET[1];
         echo "<FORM name=maintenance id=maintenance action=Modules.php?modname={$_REQUEST['modname']}&modfunc=update&page_display=MAINTENANCE method=POST>";
         echo '<table>';
         echo '<tr><td align=left><span style="font-size:12px; font-weight:bold;">' . _('Under Maintenance') . ' :</td><td><span style="font-weight:bold;">' . CheckboxInput($maintain['SYSTEM_MAINTENANCE_SWITCH'], 'maintain[SYSTEM_MAINTENANCE_SWITCH]') . '</span></td></tr>';
         $sql = 'SELECT ID,MESSAGE,DISPLAY FROM login_message ORDER BY ID';
         $QI = DBQuery($sql);
         $login_MESSAGE = DBGet($QI, array('MESSAGE' => '_makeContentInput', 'DISPLAY' => '_makeRadio'));
         $link['add']['html'] = array('MESSAGE' => _makeContentInput('', 'MESSAGE'), 'DISPLAY' => _makeRadio('', 'DISPLAY'));
         $link['remove']['link'] = "Modules.php?modname={$_REQUEST['modname']}&modfunc=remove&page_display=MAINTENANCE";
         $link['remove']['variables'] = array('id' => 'ID');
         $columns = array('MESSAGE' => '' . _('Login Message') . '', 'DISPLAY' => '' . _('Display') . '');
         ListOutput($login_MESSAGE, $columns, _('Message'), _('Messages'), $link, true, array('search' => false));
         echo '<tr><td><CENTER>' . SubmitButton(_('Save'), '', 'class=btn_medium') . '</CENTER></td></tr>';
         echo '</table>';
         echo '</FORM>';
     }
 } else {
     if (clean_param($_REQUEST['page_display'], PARAM_ALPHAMOD) == 'INACTIVITY') {
         PopTable('header', _('User Inactivity Days'));
         include "User_activity_days.php";
         PopTable('footer');
     } else {
         if (clean_param($_REQUEST['page_display'], PARAM_ALPHAMOD) == 'FAILURE') {
             PopTable('header', '' . _('Login Failure Allowance') . '');
             include "Failure_count.php";
             PopTable('footer');
         } else {
开发者ID:SysBind,项目名称:opensis-ml,代码行数:31,代码来源:system_preference.php

示例4: foreach

foreach ($schools_RET as $syear => $schools) {
    foreach ($schools as $school) {
        $schools_select[$syear][$school['ID']] = $school['TITLE'];
    }
}
//echo '<pre>'; var_dump($schools_select); echo '</pre>';
$students_RET = DBGet(DBQuery("SELECT fst.TRANSACTION_ID,fst.ACCOUNT_ID,fst.SYEAR," . db_case(array('fst.STUDENT_ID', "''", 'NULL', "(SELECT FIRST_NAME||' '||LAST_NAME FROM STUDENTS WHERE STUDENT_ID=fst.STUDENT_ID)")) . " AS FULL_NAME,fst.ACCOUNT_ID AS STUDENTS,fst.SCHOOL_ID FROM FOOD_SERVICE_TRANSACTIONS fst WHERE fst.SCHOOL_ID IS NULL"), array('STUDENTS' => '_students', 'SCHOOL_ID' => '_make_school'));
$staff_RET = DBGet(DBQuery("SELECT fst.TRANSACTION_ID,fst.STAFF_ID,fst.SYEAR,(SELECT FIRST_NAME||' '||LAST_NAME FROM STAFF WHERE STAFF_ID=fst.STAFF_ID) AS FULL_NAME,fst.SCHOOL_ID FROM FOOD_SERVICE_STAFF_TRANSACTIONS fst WHERE fst.SCHOOL_ID IS NULL"), array('SCHOOL_ID' => '_make_staff_school'));
//echo '<pre>'; var_dump($students_RET); echo '</pre>';
//echo '<pre>'; var_dump($users_RET); echo '</pre>';
echo "<FORM action=Modules.php?modname={$_REQUEST['modname']}&modfunc=update method=POST>";
DrawHeader('', SubmitButton(_('Save')));
$columns = array('TRANSACTION_ID' => _('ID'), 'ACCOUNT_ID' => _('Account ID'), 'SYEAR' => _('School Year'), 'FULL_NAME' => _('Student'), 'STUDENTS' => _('Students'), 'SCHOOL_ID' => _('School'));
ListOutput($students_RET, $columns, _('Student Transaction w/o School'), _('Student Transactions w/o School'), false, array(), array('save' => false, 'search' => false));
$columns = array('TRANSACTION_ID' => _('ID'), 'SYEAR' => _('School Year'), 'FULL_NAME' => _('User'), 'SCHOOL_ID' => _('School'));
ListOutput($staff_RET, $columns, _('User Transaction w/o School'), _('User Transactions w/o School'), false, array(), array('save' => false, 'search' => false));
echo '<CENTER>' . SubmitButton(_('Save')) . '</CENTER>';
echo '</FORM>';
function _students($value, $column)
{
    $RET = DBGet(DBQuery("SELECT s.FIRST_NAME||' '||s.LAST_NAME AS FULL_NAME FROM STUDENTS s,FOOD_SERVICE_STUDENT_ACCOUNTS fsa WHERE s.STUDENT_ID=fsa.STUDENT_ID AND fsa.ACCOUNT_ID='" . $value . "'"));
    foreach ($RET as $student) {
        $ret .= $student['FULL_NAME'] . '<br>';
    }
    $ret = substr($ret, 0, -4);
    return $ret;
}
function _make_school($value, $column)
{
    global $THIS_RET, $schools_select;
    return SelectInput($value, "student[{$THIS_RET['TRANSACTION_ID']}]", '', $schools_select[$THIS_RET['SYEAR']]);
开发者ID:linil,项目名称:centreSIS,代码行数:31,代码来源:AssignSchool.php

示例5: DrawBC

#  along with this program.  If not, see <http://www.gnu.org/licenses/>.
#
#***************************************************************************************
include '../../Redirect_modules.php';
DrawBC("Gradebook > " . ProgramTitle());
if (!$_REQUEST['mp']) {
    $_REQUEST['mp'] = UserMP();
}
$sem = GetParentMP('SEM', UserMP());
echo "<FORM action=Modules.php?modname={$_REQUEST['modname']} method=POST>";
$mp_select = "<SELECT name=mp onchange='document.forms[0].submit();'><OPTION value=" . UserMP() . ">" . GetMP(UserMP()) . "</OPTION><OPTION value=" . $sem . ($sem == $_REQUEST['mp'] ? ' SELECTED' : '') . ">" . GetMP($sem) . "</OPTION><OPTION value=E" . $sem . ('E' . $sem == $_REQUEST['mp'] ? ' SELECTED' : '') . ">" . GetMP($sem) . ' Exam</OPTION></SELECT>';
DrawHeaderHome($mp_select);
echo '</FORM>';
$sql = "SELECT CONCAT(s.LAST_NAME,', ',s.FIRST_NAME) as FULL_NAME,s.STAFF_ID,g.REPORT_CARD_GRADE_ID FROM STUDENT_REPORT_CARD_GRADES g,STAFF s,COURSE_PERIODS cp WHERE g.COURSE_PERIOD_ID=cp.COURSE_PERIOD_ID AND cp.TEACHER_ID=s.STAFF_ID AND cp.SYEAR=s.SYEAR AND cp.SYEAR=g.SYEAR AND cp.SYEAR='" . UserSyear() . "' AND g.MARKING_PERIOD_ID='" . $_REQUEST['mp'] . "'";
$grouped_RET = DBGet(DBQuery($sql), array(), array('STAFF_ID', 'REPORT_CARD_GRADE_ID'));
$grades_RET = DBGet(DBQuery("SELECT rg.ID,rg.TITLE FROM REPORT_CARD_GRADES rg,REPORT_CARD_GRADE_SCALES rs WHERE rg.SCHOOL_ID='" . UserSchool() . "' AND rg.SYEAR='" . UserSyear() . "' AND rs.ID=rg.GRADE_SCALE_ID ORDER BY rs.SORT_ORDER,rs.ID,rg.BREAK_OFF IS NOT NULL DESC,rg.BREAK_OFF DESC,rg.SORT_ORDER"));
if (count($grouped_RET)) {
    foreach ($grouped_RET as $staff_id => $grades) {
        $i++;
        $teachers_RET[$i]['FULL_NAME'] = $grades[key($grades)][1]['FULL_NAME'];
        foreach ($grades_RET as $grade) {
            $teachers_RET[$i][$grade['ID']] = count($grades[$grade['ID']]);
        }
    }
}
$columns = array('FULL_NAME' => 'Teacher');
foreach ($grades_RET as $grade) {
    $columns[$grade['ID']] = $grade['TITLE'];
}
ListOutput($teachers_RET, $columns, 'Teacher', 'Teachers');
开发者ID:26746647,项目名称:Belize-openSIS,代码行数:30,代码来源:GradeBreakdown.php

示例6: UserSyear

										s.STUDENT_ID,concat(c.TITLE, \' - \', s.COURSE_WEIGHT) AS COURSE,cp.PERIOD_ID,cp.COURSE_PERIOD_ID,p.TITLE AS PERIOD_TITLE,
										\'' . '' . '\' AS ATTENDANCE_CODE,\'' . '' . '\' AS ATTENDANCE_TEACHER_CODE,\'' . '' . '\' AS ATTENDANCE_REASON 
									FROM 
										schedule s,courses c,course_periods cp,school_periods p 
									WHERE 
										s.SYEAR=\'' . UserSyear() . '\' AND s.SCHOOL_ID=\'' . UserSchool() . '\' AND s.MARKING_PERIOD_ID IN (' . GetAllMP('QTR', GetCurrentMP('QTR', $date)) . ')
										AND s.COURSE_ID=c.COURSE_ID 
										AND s.COURSE_PERIOD_ID=cp.COURSE_PERIOD_ID AND cp.PERIOD_ID=p.PERIOD_ID AND cp.DOES_ATTENDANCE=\'Y.\'
										AND s.STUDENT_ID=\'' . optional_param('student_id', '', PARAM_ALPHANUM) . '\' AND (\'' . $date . '\' BETWEEN s.START_DATE AND s.END_DATE OR s.END_DATE IS NULL)
									ORDER BY p.SORT_ORDER'), $functions);
    $columns = array('PERIOD_TITLE' => '' . _('Period') . '', 'COURSE' => '' . _('Course') . '', 'ATTENDANCE_CODE' => '' . _('Attendance Code') . '', 'ATTENDANCE_TEACHER_CODE' => '' . _('Teacher\'s Entry') . '', 'ATTENDANCE_REASON' => '' . _('Comments') . '');
    //echo "<FORM action=Modules.php?modname=$_REQUEST[modname]&modfunc=student&student_id=$_REQUEST[student_id] method=POST>";
    echo "<FORM action=Modules.php?modname={$_REQUEST['modname']}&modfunc=student&student_id=" . optional_param('student_id', '', PARAM_ALPHANUM) . " method=POST>";
    DrawHeader(ProgramTitle(), '<INPUT type=submit value=Update>');
    DrawHeader(PrepareDate($date, '_date'));
    ListOutput($schedule_RET, $columns, _('Course'), _('Courses'));
    echo '</FORM>';
} else {
    $extra['WHERE'] = ' AND EXISTS (SELECT \'' . '' . '\' FROM attendance_period ap,attendance_codes ac WHERE ap.SCHOOL_DATE=\'' . $date . '\' AND ap.STUDENT_ID=ssm.STUDENT_ID AND ap.ATTENDANCE_CODE=ac.ID AND ac.SCHOOL_ID=ssm.SCHOOL_ID AND ac.SYEAR=ssm.SYEAR ';
    if (count($_REQUEST['codes'])) {
        $REQ_codes = $_REQUEST['codes'];
        foreach ($REQ_codes as $key => $value) {
            if (!$value) {
                unset($REQ_codes[$key]);
            } elseif ($value == 'A') {
                $abs = true;
            }
        }
    } else {
        $abs = true;
    }
开发者ID:SysBind,项目名称:opensis-ml,代码行数:31,代码来源:Administration_fast.php

示例7: UserCoursePeriod

$course_period_id = UserCoursePeriod();
$course_id = DBGet(DBQuery("SELECT COURSE_ID FROM COURSE_PERIODS WHERE COURSE_PERIOD_ID='{$course_period_id}'"));
$course_id = $course_id[1]['COURSE_ID'];
$max_allowed = Preferences('ANOMALOUS_MAX', 'Gradebook') / 100;
$extra['SELECT'] = ",ga.ASSIGNMENT_ID,gt.TITLE AS TYPE_TITLE,ga.TITLE,ga.POINTS AS TOTAL_POINTS,'' AS LETTER_GRADE";
$extra['SELECT'] .= ',(SELECT POINTS FROM GRADEBOOK_GRADES WHERE STUDENT_ID=s.STUDENT_ID AND ASSIGNMENT_ID=ga.ASSIGNMENT_ID) AS POINTS';
$extra['SELECT'] .= ',(SELECT COMMENT FROM GRADEBOOK_GRADES WHERE STUDENT_ID=s.STUDENT_ID AND ASSIGNMENT_ID=ga.ASSIGNMENT_ID) AS COMMENT';
$extra['FROM'] = ",GRADEBOOK_ASSIGNMENTS ga,GRADEBOOK_ASSIGNMENT_TYPES gt";
$extra['WHERE'] = 'AND ((SELECT POINTS FROM GRADEBOOK_GRADES WHERE STUDENT_ID=s.STUDENT_ID AND ASSIGNMENT_ID=ga.ASSIGNMENT_ID) IS NULL AND (ga.ASSIGNED_DATE IS NULL OR CURRENT_DATE>=ga.ASSIGNED_DATE) AND (ga.DUE_DATE IS NULL OR CURRENT_DATE>=ga.DUE_DATE) OR (SELECT POINTS FROM GRADEBOOK_GRADES WHERE STUDENT_ID=s.STUDENT_ID AND ASSIGNMENT_ID=ga.ASSIGNMENT_ID)<0 OR (SELECT POINTS FROM GRADEBOOK_GRADES WHERE STUDENT_ID=s.STUDENT_ID AND ASSIGNMENT_ID=ga.ASSIGNMENT_ID)>ga.POINTS*' . $max_allowed . ') AND ((ga.COURSE_ID=\'' . $course_id . '\' AND ga.STAFF_ID=\'' . User('STAFF_ID') . '\') OR ga.COURSE_PERIOD_ID=\'' . $course_period_id . '\') AND ga.MARKING_PERIOD_ID=\'' . UserMP() . '\' AND gt.ASSIGNMENT_TYPE_ID=ga.ASSIGNMENT_TYPE_ID';
$extra['functions'] = array('POINTS' => '_makePoints');
$students_RET = GetStuList($extra);
//echo '<pre>'; var_dump($students_RET); echo '</pre>';
if (AllowUse('Grades/Grades.php')) {
    $link = array('FULL_NAME' => array('link' => "Modules.php?modname=Grades/Grades.php&include_ianctive={$_REQUEST['include_inactive']}&assignment_id=all", 'variables' => array('student_id' => 'STUDENT_ID')), 'TITLE' => array('link' => "Modules.php?modname=Grades/Grades.php&include_inactive={$_REQUEST['include_inactive']}", 'variables' => array('assignment_id' => 'ASSIGNMENT_ID', 'student_id' => 'STUDENT_ID')));
}
$columns = array('FULL_NAME' => 'Name', 'STUDENT_ID' => 'Student ID', 'POINTS' => 'Problem', 'TYPE_TITLE' => 'Category', 'TITLE' => 'Assignment', 'COMMENT' => 'Comment');
ListOutput($students_RET, $columns, 'Anomalous Grade', 'Anomalous Grades', $link, array(), array('center' => false, 'save' => false, 'search' => false));
function _makePoints($value, $column)
{
    global $THIS_RET;
    if ($value == '') {
        return '<FONT class=red>Missing</FONT>';
    } elseif ($value == '-1') {
        return '<FONT color=#00a000>Excused</FONT>';
    } elseif ($value < 0) {
        return '<FONT class=red>Negative!</FONT>';
    } elseif ($THIS_RET['TOTAL_POINTS'] == 0) {
        return '<FONT color=#0000ff>Extra Credit</FONT>';
    }
    return Percent($value / $THIS_RET['TOTAL_POINTS'], 0);
}
开发者ID:26746647,项目名称:Belize-openSIS,代码行数:31,代码来源:AnomalousGrades.php

示例8: DBGet

    echo '</TD>';
    // FIELDS
    if ($_REQUEST['category_id'] && $_REQUEST['category_id'] != 'new' && count($categories_RET)) {
        $sql = "SELECT ID,TITLE,TYPE,SORT_ORDER FROM CUSTOM_FIELDS WHERE CATEGORY_ID='" . $_REQUEST['category_id'] . "' ORDER BY SORT_ORDER,TITLE";
        $fields_RET = DBGet(DBQuery($sql), array('TYPE' => '_makeType'));
        if (count($fields_RET)) {
            if ($_REQUEST['id'] && $_REQUEST['id'] != 'new') {
                foreach ($fields_RET as $key => $value) {
                    if ($value['ID'] == $_REQUEST['id']) {
                        $fields_RET[$key]['row_color'] = Preferences('HIGHLIGHT');
                    }
                }
            }
        }
        echo '<TD class="valign-top">';
        $columns = array('TITLE' => _('Student Field'), 'SORT_ORDER' => _('Order'), 'TYPE' => _('Data Type'));
        $link = array();
        $link['TITLE']['link'] = "Modules.php?modname={$_REQUEST['modname']}&category_id={$_REQUEST['category_id']}";
        $link['TITLE']['variables'] = array('id' => 'ID');
        $link['add']['link'] = "Modules.php?modname={$_REQUEST['modname']}&category_id={$_REQUEST['category_id']}&id=new";
        $fields_RET = ParseMLArray($fields_RET, 'TITLE');
        ListOutput($fields_RET, $columns, 'Student Field', 'Student Fields', $link, array(), $LO_options);
        echo '</TD>';
    }
    echo '</TR></TABLE>';
}
function _makeType($value, $name)
{
    $options = array('radio' => _('Checkbox'), 'text' => _('Text'), 'autos' => _('Auto Pull-Down'), 'edits' => _('Edit Pull-Down'), 'select' => _('Pull-Down'), 'codeds' => _('Coded Pull-Down'), 'exports' => _('Export Pull-Down'), 'date' => _('Date'), 'numeric' => _('Number'), 'textarea' => _('Long Text'), 'multiple' => _('Select Multiple'));
    return $options[$value];
}
开发者ID:fabioassuncao,项目名称:rosariosis,代码行数:31,代码来源:StudentFields.php

示例9: DBGet

    $end_date = DBGet(DBQuery('SELECT END_DATE FROM student_enrollment WHERE STUDENT_ID=\'' . $_REQUEST['student_id'] . '\' AND SYEAR=\'' . UserSyear() . '\' AND SCHOOL_ID=\'' . UserSchool() . '\' AND ID=\'' . $enroll_id . '\''));
    if ($end_date[1]['END_DATE']) {
        $end_date = $end_date[1]['END_DATE'];
        DBQuery('UPDATE schedule SET END_DATE=\'' . $end_date . '\' WHERE STUDENT_ID=\'' . $_REQUEST['student_id'] . '\' AND SYEAR=\'' . UserSyear() . '\' AND SCHOOL_ID=\'' . UserSchool() . '\' AND (END_DATE IS NULL OR \'' . $end_date . '\' < END_DATE )');
        DBQuery('CALL SEAT_COUNT()');
    }
}
if ($_REQUEST['student_id'] != 'new') {
    if (count($RET)) {
        $id = $RET[count($RET)]['ID'];
    } else {
        $id = 'new';
    }
    echo '<div style="overflow:auto; width:820px;">';
    echo '<div id="students" >';
    ListOutput($RET, $columns, 'Enrollment Record', 'Enrollment Records', $link);
    echo "</div>";
    echo "</div>";
    if ($id != 'new') {
        $next_school = $RET[count($RET)]['NEXT_SCHOOL'];
    }
    if ($id != 'new') {
        $calendar = $RET[count($RET)]['CALENDAR_ID'];
    }
    $div = true;
} else {
    $id = 'new';
    echo '<div style="overflow:auto; width:820px;">';
    echo '<div id="students" >';
    ListOutputMod($RET, $columns, 'Enrollment Record', 'Enrollment Records', $link, array(), array('count' => false));
    echo "</div>";
开发者ID:jeffthestampede,项目名称:excelsior,代码行数:31,代码来源:EnrollmentInfoInc.php

示例10: array

}
if (!$_REQUEST['modfunc']) {
    $count = 0;
    $count++;
    $LO_options = array('save' => false, 'search' => false, 'add' => true);
    echo '<TABLE><TR>';
    echo '<TD valign=top>';
    $columns = array('TITLE' => 'School Fields', 'TYPE' => 'Field Type');
    $link = array();
    $arr = array('School Name', 'Address', 'City', 'State', 'Zip/Postal Code', 'Principal', 'Base Grading Scale', 'E-Mail', 'CEEB', 'Website', 'School Logo');
    $RET = DBGet(DBQuery("SELECT * FROM school_custom_fields WHERE SCHOOL_ID=" . UserSchool() . " ORDER BY SORT_ORDER"));
    foreach ($arr as $key => $value) {
        $fields_RET1[$count] = array('ID' => '', 'TITLE' => $value, 'TYPE' => '<span style="color:#ea8828;">Default</span>');
        $count++;
    }
    $count2 = 1;
    foreach ($fields_RET1 as $key2) {
        $dd[$count2] = $key2;
        $count2++;
    }
    foreach ($RET as $row) {
        $dd[$count2] = $row;
        $count2++;
    }
    $link['TITLE']['link'] = "Modules.php?modname={$_REQUEST['modname']}";
    $link['add']['link'] = "#" . " onclick='check_content(\"ajax.php?modname={$_REQUEST['modname']}&id=new\");'";
    $link['TITLE']['variables'] = array('id' => 'ID');
    ListOutput($dd, $columns, 'School Field', 'School Fields', $link, array(), $LO_options);
    echo '</TD>';
    echo '</TR></TABLE>';
}
开发者ID:26746647,项目名称:openSIS,代码行数:31,代码来源:school_custom_fields.php

示例11: ListOutput

     echo '<TABLE><TR><TD valign=top>';
     ListOutput($table, array('STUDENT_ID' => 'Student', 'UNSCHEDULED' => 'Unfilled Requests'), '.', '.', '', '', array('sort' => false, 'search' => false));
     echo '</TD><TD valign=top>';
     $i = 0;
     foreach ($courses as $course_id => $count) {
         $courses_list[++$i] = array('COURSE' => _getCourse(substr($course_id, 0, strpos($course_id, '-'))) . substr($course_id, strpos($course_id, '-')), 'COUNT' => $count);
     }
     ListOutput($courses_list, array('COURSE' => 'Course', 'COUNT' => '#'), 'Course with Unscheduled Requests', 'Courses with Unscheduled Requests', '', '', array('sort' => false, 'search' => false));
     $i = 0;
     $courses_list = array();
     if (count($course_seats)) {
         foreach ($course_seats as $course_id => $count) {
             $courses_list[++$i] = array('COURSE' => _getCourse(substr($course_id, 0, strpos($course_id, '-'))) . substr($course_id, strpos($course_id, '-')), 'COUNT' => $count);
         }
     }
     ListOutput($courses_list, array('COURSE' => 'Course', 'COUNT' => '#'), 'Course with No Seats', 'Courses with No Seats', '', '', array('sort' => false, 'search' => false));
     echo '</TD></TR></TABLE>';
 }
 if (!$_SCHEDULER['dont_run']) {
     $connection = db_start();
     db_trans_start($connection);
     unset($_SESSION['SCHEDULE']);
     if (count($insert)) {
         foreach ($insert as $student_id => $requests) {
             foreach ($requests as $request) {
                 $sql = "INSERT INTO SCHEDULE (SYEAR,SCHOOL_ID,STUDENT_ID,START_DATE,MODIFIED_DATE,COURSE_ID,COURSE_WEIGHT,COURSE_PERIOD_ID,MP,MARKING_PERIOD_ID) values('" . UserSyear() . "','" . UserSchool() . "','" . $request['STUDENT_ID'] . "','" . DBDate() . "','" . DBDate() . "','" . $request['COURSE_ID'] . "','" . $request['COURSE_WEIGHT'] . "','" . $request['COURSE_PERIOD_ID'] . "','" . $request['MP'] . "','" . $request['MARKING_PERIOD_ID'] . "')";
                 db_trans_query($connection, $sql);
             }
         }
     }
     foreach ($periods_RET as $course_id => $weights) {
开发者ID:linil,项目名称:centreSIS,代码行数:31,代码来源:Scheduler_old.php

示例12: unset

$assignment_select .= '</SELECT>';
echo "<FORM action=Modules.php?modname={$_REQUEST['modname']}&student_id={$_REQUEST['student_id']} method=POST>";
$tmp_REQUEST = $_REQUEST;
unset($tmp_REQUEST['include_inactive']);
//-----------------------------------
//if(($_REQUEST['assignment_id'] == "all") && count($assignments_RET) == '0')
if (count($stu_RET) == 0) {
    DrawHeaderHome($assignment_select, '', '<INPUT type=checkbox name=include_inactive value=Y' . ($_REQUEST['include_inactive'] == 'Y' ? " CHECKED onclick='document.location.href=\"" . PreparePHP_SELF($tmp_REQUEST) . "&include_inactive=\";'" : " onclick='document.location.href=\"" . PreparePHP_SELF($tmp_REQUEST) . "&include_inactive=Y\";'") . '>Include Inactive Students');
} else {
    DrawHeaderHome($assignment_select, $_REQUEST['assignment_id'] ? SubmitButton('Save', '', 'class=btn_medium') : '', '<INPUT type=checkbox name=include_inactive value=Y' . ($_REQUEST['include_inactive'] == 'Y' ? " CHECKED onclick='document.location.href=\"" . PreparePHP_SELF($tmp_REQUEST) . "&include_inactive=\";'" : " onclick='document.location.href=\"" . PreparePHP_SELF($tmp_REQUEST) . "&include_inactive=Y\";'") . '>Include Inactive Students');
}
if (!$_REQUEST['student_id'] && $_REQUEST['assignment_id'] == 'all') {
    $options = array('yscroll' => true);
}
echo '<div style="overflow:auto; width:850px;">';
ListOutput($stu_RET, $LO_columns, $item, $items, $link, array(), $options);
echo '</div>';
if (count($assignments_RET) != 0) {
    echo $_REQUEST['assignment_id'] ? '<CENTER>' . SubmitButton('Save', '', 'class=btn_medium') . '</CENTER>' : '';
}
echo '</FORM>';
function _makeExtraAssnCols($assignment_id, $column)
{
    global $THIS_RET, $total_points, $current_RET, $points_RET, $tabindex, $max_allowed;
    $rounding = DBGet(DBQuery('SELECT VALUE FROM program_user_config WHERE USER_ID=\'' . User('STAFF_ID') . '\' AND TITLE=\'ROUNDING\' AND PROGRAM=\'Gradebook\' '));
    if (count($rounding)) {
        $_SESSION['ROUNDING'] = $rounding[1]['VALUE'];
    }
    switch ($column) {
        case 'POINTS':
            $tabindex++;
开发者ID:26746647,项目名称:openSIS,代码行数:31,代码来源:Grades.php

示例13: substr

    case 'Sun':
        $day = 'U';
        break;
    case 'Thu':
        $day = 'H';
        break;
    default:
        $day = substr($day, 0, 1);
        break;
}
$sql = "SELECT CONCAT(s.LAST_NAME,', ',s.FIRST_NAME) AS FULL_NAME,sp.TITLE,cp.PERIOD_ID,s.STAFF_ID\n\t\tFROM STAFF s,COURSE_PERIODS cp,SCHOOL_PERIODS sp\n\t\tWHERE\n\t\t\tsp.PERIOD_ID = cp.PERIOD_ID\n\t\t\tAND cp.TEACHER_ID=s.STAFF_ID AND cp.MARKING_PERIOD_ID IN (" . GetAllMP('QTR', GetCurrentMP('QTR', $date)) . ")\n\t\t\tAND cp.SYEAR='" . UserSyear() . "' AND cp.SCHOOL_ID='" . UserSchool() . "' AND s.PROFILE='teacher'\n\t\t\tAND cp.DOES_ATTENDANCE='Y' AND instr(cp.DAYS,'{$day}')>0" . ($_REQUEST['period'] ? " AND cp.PERIOD_ID='{$_REQUEST['period']}'" : '') . "\n\t\t\tAND NOT EXISTS (SELECT '' FROM ATTENDANCE_COMPLETED ac WHERE ac.STAFF_ID=cp.TEACHER_ID AND ac.SCHOOL_DATE='" . date('Y-m-d', strtotime($date)) . "' AND ac.PERIOD_ID=sp.PERIOD_ID)\n\t\t";
$RET = DBGet(DBQuery($sql), array(), array('STAFF_ID', 'PERIOD_ID'));
if (count($RET)) {
    foreach ($RET as $staff_id => $periods) {
        $i++;
        $staff_RET[$i]['FULL_NAME'] = $periods[key($periods)][1]['FULL_NAME'];
        foreach ($periods as $period_id => $period) {
            $staff_RET[$i][$period_id] = '<IMG SRC=assets/x.gif>';
        }
    }
}
$columns = array('FULL_NAME' => 'Teacher');
if (!$_REQUEST['period']) {
    foreach ($periods_RET as $id => $period) {
        $columns[$id] = $period[1]['TITLE'];
    }
} else {
    $period_title = $periods_RET[$_REQUEST['period']][1]['TITLE'] . ' ';
}
ListOutput($staff_RET, $columns, 'Teacher who hasn\'t taken ' . $period_title . 'attendance', 'Teachers who haven\'t taken ' . $period_title . 'attendance');
开发者ID:SoftScape,项目名称:opensis,代码行数:30,代码来源:TeacherCompletion.php

示例14: IN

    									FROM 
    										SCHEDULE s,COURSES c,COURSE_PERIODS cp,SCHOOL_PERIODS p 
    									WHERE 
    										s.SYEAR='".UserSyear()."' AND s.SCHOOL_ID='".UserSchool()."' AND s.MARKING_PERIOD_ID IN (".GetAllMP('QTR',GetCurrentMP('QTR',$date)).")
    										AND s.COURSE_ID=c.COURSE_ID 
    										AND s.COURSE_PERIOD_ID=cp.COURSE_PERIOD_ID AND cp.PERIOD_ID=p.PERIOD_ID AND cp.DOES_ATTENDANCE='Y'
    										AND s.STUDENT_ID='".$_REQUEST['student_id']."' AND ('$date' BETWEEN s.START_DATE AND s.END_DATE OR s.END_DATE IS NULL)
    									ORDER BY p.SORT_ORDER"),$functions);
    	*/
    $schedule_RET = DBGet(DBQuery("SELECT \r\n\t\t\t\t\t\t\t\t\t\ts.STUDENT_ID,concat(c.TITLE, ' - ', s.COURSE_WEIGHT) AS COURSE,cp.PERIOD_ID,cp.COURSE_PERIOD_ID,p.TITLE AS PERIOD_TITLE,\r\n\t\t\t\t\t\t\t\t\t\t'' AS ATTENDANCE_CODE,'' AS ATTENDANCE_TEACHER_CODE,'' AS ATTENDANCE_REASON \r\n\t\t\t\t\t\t\t\t\tFROM \r\n\t\t\t\t\t\t\t\t\t\tSCHEDULE s,COURSES c,COURSE_PERIODS cp,SCHOOL_PERIODS p \r\n\t\t\t\t\t\t\t\t\tWHERE \r\n\t\t\t\t\t\t\t\t\t\ts.SYEAR='" . UserSyear() . "' AND s.SCHOOL_ID='" . UserSchool() . "' AND s.MARKING_PERIOD_ID IN (" . GetAllMP('QTR', GetCurrentMP('QTR', $date)) . ")\r\n\t\t\t\t\t\t\t\t\t\tAND s.COURSE_ID=c.COURSE_ID \r\n\t\t\t\t\t\t\t\t\t\tAND s.COURSE_PERIOD_ID=cp.COURSE_PERIOD_ID AND cp.PERIOD_ID=p.PERIOD_ID AND cp.DOES_ATTENDANCE='Y'\r\n\t\t\t\t\t\t\t\t\t\tAND s.STUDENT_ID='" . optional_param('student_id', '', PARAM_ALPHANUM) . "' AND ('{$date}' BETWEEN s.START_DATE AND s.END_DATE OR s.END_DATE IS NULL)\r\n\t\t\t\t\t\t\t\t\tORDER BY p.SORT_ORDER"), $functions);
    $columns = array('PERIOD_TITLE' => 'Period', 'COURSE' => 'Course', 'ATTENDANCE_CODE' => 'Attendance Code', 'ATTENDANCE_TEACHER_CODE' => 'Teacher\'s Entry', 'ATTENDANCE_REASON' => 'Comments');
    //echo "<FORM action=Modules.php?modname=$_REQUEST[modname]&modfunc=student&student_id=$_REQUEST[student_id] method=POST>";
    echo "<FORM action=Modules.php?modname={$_REQUEST['modname']}&modfunc=student&student_id=" . optional_param('student_id', '', PARAM_ALPHANUM) . " method=POST>";
    DrawHeader(ProgramTitle(), '<INPUT type=submit value=Update>');
    DrawHeader(PrepareDate($date, '_date'));
    ListOutput($schedule_RET, $columns, 'Course', 'Courses');
    echo '</FORM>';
} else {
    $extra['WHERE'] = " AND EXISTS (SELECT '' FROM ATTENDANCE_PERIOD ap,ATTENDANCE_CODES ac WHERE ap.SCHOOL_DATE='" . $date . "' AND ap.STUDENT_ID=ssm.STUDENT_ID AND ap.ATTENDANCE_CODE=ac.ID AND ac.SCHOOL_ID=ssm.SCHOOL_ID AND ac.SYEAR=ssm.SYEAR ";
    if (count($_REQUEST['codes'])) {
        $REQ_codes = $_REQUEST['codes'];
        foreach ($REQ_codes as $key => $value) {
            if (!$value) {
                unset($REQ_codes[$key]);
            } elseif ($value == 'A') {
                $abs = true;
            }
        }
    } else {
        $abs = true;
    }
开发者ID:26746647,项目名称:Belize-openSIS,代码行数:31,代码来源:Administration_fast.php

示例15: foreach

    if (substr($_REQUEST['mp'], 0, 1) != 'E' && GetMP($_REQUEST['mp'], 'DOES_COMMENTS') == 'Y') {
        foreach ($commentsA_RET as $value) {
            $columns += array('CA' . $value['ID'] => $value['TITLE']);
        }
        for ($i = 1; $i <= $max_current_commentsB; $i++) {
            $columns += array('CB' . $i => 'Comment ' . $i);
        }
        if (count($commentsB_select) && AllowEdit() && !isset($_REQUEST['_openSIS_PDF'])) {
            $columns += array('CB' . $i => 'Add Comment');
        }
        $columns += array('COMMENT' => 'Comment');
    }
    echo "<center>";
    PopTable_wo_header('header');
    echo '<div style="width:800px; overflow-x:scroll;">';
    ListOutput($stu_RET, $columns, 'Student', 'Students', false, false, array('yscroll' => true));
    echo '</div>';
    PopTable('footer');
    echo "</center>";
    if (count($stu_RET) != 0) {
        echo '<CENTER>' . SubmitButton('Save', 'submit[save]', 'class=btn_medium') . '</CENTER>';
    }
    echo "</FORM>";
}
/////////////////sg customization////////
function _makeGrade($value, $column)
{
    global $THIS_RET, $current_RET, $import_RET, $grades_RET, $grades_select, $student_count, $tabindex;
    $tc_grade = 'n';
    if ($column == 'REPORT_CARD_GRADE') {
        if (!isset($_REQUEST['_openSIS_PDF'])) {
开发者ID:26746647,项目名称:openSIS,代码行数:31,代码来源:InputFinalGrades.php


注:本文中的ListOutput函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。