Commit 485b7c99 authored by 杨培's avatar 杨培

增加获取考试API

parent c09e5b85
...@@ -7,4 +7,4 @@ require __DIR__.'/_init.php'; ...@@ -7,4 +7,4 @@ require __DIR__.'/_init.php';
Thread::setDebug(true); Thread::setDebug(true);
$thread = Thread::getHotThreads(5); $thread = Thread::getHotThreads(5);
var_dump($thread); print_r($thread);
\ No newline at end of file \ No newline at end of file
...@@ -22,5 +22,7 @@ $sourceId = 3; ...@@ -22,5 +22,7 @@ $sourceId = 3;
//$result = Favorite::delete(2); //$result = Favorite::delete(2);
$result = Favorite::isFavorite('xue','course',[2,3,4]); Favorite::delete('bbs', 'thread', 121, 18);
print_r($result);
\ No newline at end of file //$result = Favorite::isFavorite('xue','course',[2,3,4]);
//print_r($result);
\ No newline at end of file
...@@ -8,4 +8,6 @@ require __DIR__.'/_init.php'; ...@@ -8,4 +8,6 @@ require __DIR__.'/_init.php';
$list = CourseList::getRecommendList(); $list = CourseList::getRecommendList();
//$list = \internalApi\xue\Exam::getExam(4);
print_r($list); print_r($list);
\ No newline at end of file
<?php
/**
* Created by PhpStorm.
* User: pader
* Date: 2017/8/8
* Time: 13:58
*/
namespace internalApi\xue;
use internalApi\base\Client;
class Exam extends Client
{
/**
* 获取一个考试的基本信息
*
* @param int $examId
* @return array
*/
public static function getExam($examId)
{
return self::call('exam.getExam', compact('examId'));
}
}
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment