sent_prs.php 682 B

1234567891011121314151617181920212223242526272829303132
  1. <?php
  2. require_once __DIR__."/../model/sent_prs.php";
  3. require_once __DIR__."/controller.php";
  4. Class CtlSentPr extends Controller{
  5. public function index(){
  6. $result = SentPr::find($_GET["id"]);
  7. echo $result["content"];
  8. }
  9. public function create(){
  10. $result = SentPr::find($_GET["id"]);
  11. echo $result["content"];
  12. }
  13. public function show(){
  14. $result = SentPr::find($_GET["id"]);
  15. if($result){
  16. $this->ok($result);
  17. }else{
  18. $this->error("没有查询到数据");
  19. }
  20. }
  21. public function update(){
  22. $result = SentPr::find($_GET["id"]);
  23. echo $result["content"];
  24. }
  25. public function delete(){
  26. $result = SentPr::find($_GET["id"]);
  27. echo $result["content"];
  28. }
  29. }