Topic.php 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. <?php
  2. namespace app\index\controller;
  3. use think\Controller;
  4. class Topic extends Base
  5. {
  6. public function __construct()
  7. {
  8. parent::__construct();
  9. }
  10. public function index()
  11. {
  12. $this->label_topic_index();
  13. return $this->label_fetch('topic/index');
  14. }
  15. public function search()
  16. {
  17. $param = mac_param_url();
  18. $this->check_search($param);
  19. $this->label_search($param);
  20. return $this->label_fetch('topic/search');
  21. }
  22. public function ajax_search()
  23. {
  24. $param = mac_param_url();
  25. $this->check_ajax();
  26. $this->check_search($param,1);
  27. $this->label_search($param);
  28. return $this->label_fetch('topic/ajax_search');
  29. }
  30. public function detail()
  31. {
  32. $info = $this->label_topic_detail();
  33. return $this->label_fetch( mac_tpl_fetch('topic',$info['topic_tpl'],'detail') );
  34. }
  35. public function ajax_detail()
  36. {
  37. $this->check_ajax();
  38. $info = $this->label_topic_detail();
  39. return $this->label_fetch('topic/ajax_detail');
  40. }
  41. public function rss()
  42. {
  43. $info = $this->label_topic_detail();
  44. return $this->label_fetch('topic/rss');
  45. }
  46. }