You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

SpLuGetUserSetting.php 1.0KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. <?php
  2. /**
  3. * AUTO GENERATED BY LUTICATE GENERATOR
  4. * ANY CHANGES WILL BE OVERWRITTEN
  5. */
  6. namespace Luticate\Auth\DataAccess\SP;
  7. use Luticate\Utils\LuSpModel;
  8. use Luticate\Utils\LuMultipleDbo;
  9. use Luticate\Utils\LuStringUtils;
  10. use Illuminate\Support\Facades\DB;
  11. class SpLuGetUserSetting extends LuSpModel {
  12. protected static function damToDbo($dam)
  13. {
  14. if (is_null($dam))
  15. return null;
  16. $dbo = new SpLuGetUserSetting();
  17. $dbo->setSetting($dam->setting);
  18. return $dbo;
  19. }
  20. public static function execute($_user_id, $_setting_name)
  21. {
  22. $values = DB::select('SELECT * FROM sp_lu_get_user_setting(:_user_id, :_setting_name)', array(":_user_id" => $_user_id, ":_setting_name" => $_setting_name));
  23. return self::damToDbo($values[0]);
  24. }
  25. /**
  26. * @var json
  27. */
  28. protected $_setting;
  29. public function getSetting()
  30. {
  31. return $this->_setting;
  32. }
  33. public function setSetting($value)
  34. {
  35. $this->_setting = $value;
  36. }
  37. }