ConfigController.php 1.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576
  1. <?php
  2. /**
  3. * Created by PhpStorm.
  4. * User: wangzhiqiang
  5. * Date: 2019/4/24
  6. * Time: 9:36
  7. */
  8. namespace App\Http\Controllers;
  9. use App\Traits\CommunityTrait;
  10. class ConfigController extends Controller
  11. {
  12. use CommunityTrait;
  13. /**
  14. * Create a new controller instance.
  15. *
  16. * @return void
  17. */
  18. public function __construct()
  19. {
  20. //
  21. }
  22. public function index()
  23. {
  24. $reportCategory = [
  25. [
  26. 'id' => 0,
  27. 'name' => '广告内容',
  28. ],
  29. [
  30. 'id' => 1,
  31. 'name' => '搬运抄袭',
  32. ],
  33. [
  34. 'id' => 2,
  35. 'name' => '不友善内容',
  36. ],
  37. [
  38. 'id' => 3,
  39. 'name' => '造谣,伪科学',
  40. ],
  41. [
  42. 'id' => 4,
  43. 'name' => '虚假互动数据',
  44. ],
  45. [
  46. 'id' => 5,
  47. 'name' => '色情低俗',
  48. ],
  49. [
  50. 'id' => 6,
  51. 'name' => '违法违规',
  52. ],
  53. [
  54. 'id' => 7,
  55. 'name' => '其它',
  56. ]
  57. ];
  58. $data = [
  59. //商品类型
  60. 'order_expired_time' => config('customer.order_expired_time'),
  61. 'virus_url' => config('customer.VIRUS_URL'),
  62. 'virus_app_id' => config('customer.VIRUS_APP_ID'),
  63. 'virus_app_secret' => config('customer.VIRUS_APP_SECRET'),
  64. 'virus' => $this->getAllBehavior(),
  65. 'find_friend_img' => config('customer.find_friend_img'),
  66. 'suggest_img' => config('customer.suggest_img'),
  67. 'share_post_bean' => (int) config('customer.share_post_bean'),
  68. 'share_invite_bean' => (int) config('customer.share_invite_bean'),
  69. 'report_category' => $reportCategory,
  70. ];
  71. return $this->jsonSuccess($data, '成功');
  72. }
  73. }