Index.php 613 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. <?php
  2. namespace app\index\controller;
  3. use think\Db;
  4. use think\Validate;
  5. class Index
  6. {
  7. public function index()
  8. {
  9. return 'index';
  10. }
  11. public function chatInfo() {
  12. }
  13. public function sendChatMsg() {
  14. $params = input();
  15. $rules = [
  16. 'userId' => 'require',
  17. 'otherUserId' => 'require',
  18. 'content' => 'require'
  19. ];
  20. new Validate($params);
  21. }
  22. public function chatList() {
  23. }
  24. public function hello($name = 'ThinkPHP5')
  25. {
  26. return 'hello,' . $name;
  27. }
  28. public function daka() {
  29. }
  30. }