thinkphp自定义业务逻辑有问题?
模型:
<!--Code highlighting produced by Actipro CodeHighlighter (freeware)http://www.CodeHighlighter.com/-->class DepartmentModel extends Model{ public function getIndexDepart() { return 1; }
<br> class IndexAction extends Action <br> { <br> public function index() <br> { <br> $a = D('Department'); <br> echo " <pre class="brush:php;toolbar:false">"; <br> print_r($a->getIndexDepart()); <br> echo "
class IndexAction extends Action{ public function index() { $a = D('Department');[color=#FF0000] get_class($a);[/color] echo "<pre class="brush:php;toolbar:false">"; print_r($a->getIndexDepart()); echo "