Example #1
0
 public function classLeaderAction()
 {
     $this->util_->requireArg('Account', $_POST);
     $arg = array('Class_ID', 'Class_name');
     $req = array();
     $req[0] = array('key' => 'Stu_ID', 'Stu_ID' => $_POST['Account'], 'table' => 'studentInfoItem');
     $lk = array('Class_ID');
     require_once './model/studentInfoItem.php';
     $item = new studentInfoItem();
     $res = $item->stuLinkClass($req, $lk, $arg);
     $arg = array('Stu_ID', 'Stu_name', 'Position', 'Power');
     $lk = array('Stu_ID');
     $req[0] = array('key' => 'Class_ID', 'Class_ID' => $res[0]['Class_ID'], 'table' => 'classLeaderItem');
     require_once './model/classLeaderItem.php';
     $item = new classLeaderItem();
     $list = $item->leaderLinkStudent($req, $lk, $arg);
     $num = count($list);
     $list['Class_ID'] = $res[0]['Class_ID'];
     $list['Class_name'] = $res[0]['Class_name'];
     $list['count'] = $num;
     return $list;
 }
Example #2
0
 public function showDetailLogAction()
 {
     require $_SERVER['DOCUMENT_ROOT'] . '/school' . '/model/studentInfoItem.php';
     $item = new studentInfoItem();
     $req[0] = array('key' => 'Stu_ID', 'Stu_ID' => $res['Stu_ID']);
     $arg = array('Stu_name');
     unset($res['Stu_ID']);
     $res['Stu_name'] = $item->search(req, arg);
 }