Settings.php 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081
  1. <?php
  2. /**
  3. * [WeEngine System] Copyright (c) 2014 WE7.CC
  4. * WeEngine is NOT a free software, it under the license terms, visited http://www.we7.cc/ for more details.
  5. */
  6. namespace We7\Table\Uni;
  7. class Settings extends \We7Table {
  8. protected $tableName = 'uni_settings';
  9. protected $primaryKey = 'uniacid';
  10. protected $field = array(
  11. 'uniacid',
  12. 'passport',
  13. 'oauth',
  14. 'jsauth_acid',
  15. 'notify',
  16. 'creditnames',
  17. 'creditbehaviors',
  18. 'welcome',
  19. 'default',
  20. 'default_message',
  21. 'payment',
  22. 'stat',
  23. 'default_site',
  24. 'sync',
  25. 'recharge',
  26. 'tplnotice',
  27. 'grouplevel',
  28. 'mcplugin',
  29. 'exchange_enable',
  30. 'coupon_type',
  31. 'statistics',
  32. 'bind_domain',
  33. 'comment_status',
  34. 'reply_setting',
  35. 'default_module',
  36. 'attachment_limit',
  37. 'attachment_size',
  38. 'sync_member',
  39. 'remote'
  40. );
  41. protected $default = array(
  42. 'uniacid' => 0,
  43. 'passport' => '',
  44. 'oauth' => '',
  45. 'jsauth_acid' => 0,
  46. 'notify' => '',
  47. 'creditnames' => '',
  48. 'creditbehaviors' => '',
  49. 'welcome' => '',
  50. 'default' => '',
  51. 'default_message' => '',
  52. 'payment' => '',
  53. 'stat' => '',
  54. 'default_site' => 0,
  55. 'sync' => '',
  56. 'recharge' => '',
  57. 'tplnotice' => '',
  58. 'grouplevel' => 1,
  59. 'mcplugin' => '',
  60. 'exchange_enable' => 0,
  61. 'coupon_type' => 1,
  62. 'statistics' => '',
  63. 'bind_domain' => '',
  64. 'comment_status' => 0,
  65. 'reply_setting' => 0,
  66. 'default_module' => '',
  67. 'attachment_limit' => 0,
  68. 'attachment_size' => '',
  69. 'sync_member' => 0,
  70. 'remote' => ''
  71. );
  72. public function searchWithUniAccountAndAccount(){
  73. return $this->query->from($this->tableName, 'a')
  74. ->leftjoin('uni_account', 'b')
  75. ->on('a.uniacid', 'b.uniacid')
  76. ->leftjoin('account', 'c')
  77. ->on('a.uniacid', 'c.uniacid');
  78. }
  79. }