CompanyAuthPCPageRequest.php 3.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155
  1. <?php
  2. /**
  3. * 获取PC企业认证页面
  4. */
  5. class CompanyAuthPCPageRequest extends SdkRequest {
  6. const REQUEST_URL = '/companyauth/pcpage';
  7. private $companyName; // 待认证公司名称
  8. private $applicant; // 认证提交人,企业认证通过后,认证提交人会自动成为该企业的系统管理员
  9. private $registerNo; // 待认证公司注册号
  10. private $legalPerson; // 待认证公司法人姓名
  11. private $callbackUrl; // 认证回调地址
  12. private $closeButton; // 是否显示关闭按钮,默认为true
  13. public function __construct() {
  14. $count = func_num_args();
  15. $args=func_get_args();
  16. if (method_exists($this,$f='__construct'.$count)) {
  17. call_user_func_array(array($this,$f),$args);
  18. }
  19. }
  20. public function __construct0() {
  21. }
  22. /**
  23. * CompanyAuthH5PageRequest constructor.
  24. * @param $companyName
  25. * @param $applicant
  26. */
  27. public function __construct2($companyName, $applicant) {
  28. $this->companyName = $companyName;
  29. $this->applicant = $applicant;
  30. }
  31. function getUrl() {
  32. return self::REQUEST_URL;
  33. }
  34. function getHttpParamers() {
  35. $paramSwitcher = ParamSwitcher::instanceParam();
  36. $paramSwitcher->addParam('companyName', $this->companyName);
  37. $paramSwitcher->addParam('applicant', $this->applicant);
  38. $paramSwitcher->addParam('registerNo', $this->registerNo);
  39. $paramSwitcher->addParam('legalPerson', $this->legalPerson);
  40. $paramSwitcher->addParam('callbackUrl',$this->callbackUrl);
  41. if($this->closeButton == null){
  42. $paramSwitcher->addParam('closeButton', true);
  43. }else{
  44. $paramSwitcher->addParam('closeButton', $this->closeButton);
  45. }
  46. $httpParameter = HttpParameter::httpPostParamer();
  47. $httpParameter->setJsonParams(json_encode($paramSwitcher->getParams()));
  48. return $httpParameter;
  49. }
  50. /**
  51. * @return mixed
  52. */
  53. public function getCompanyName()
  54. {
  55. return $this->companyName;
  56. }
  57. /**
  58. * @param mixed $companyName
  59. */
  60. public function setCompanyName($companyName)
  61. {
  62. $this->companyName = $companyName;
  63. }
  64. /**
  65. * @return mixed
  66. */
  67. public function getApplicant()
  68. {
  69. return $this->applicant;
  70. }
  71. /**
  72. * @param mixed $applicant
  73. */
  74. public function setApplicant($applicant)
  75. {
  76. $this->applicant = $applicant;
  77. }
  78. /**
  79. * @return mixed
  80. */
  81. public function getRegisterNo()
  82. {
  83. return $this->registerNo;
  84. }
  85. /**
  86. * @param mixed $registerNo
  87. */
  88. public function setRegisterNo($registerNo)
  89. {
  90. $this->registerNo = $registerNo;
  91. }
  92. /**
  93. * @return mixed
  94. */
  95. public function getLegalPerson()
  96. {
  97. return $this->legalPerson;
  98. }
  99. /**
  100. * @param mixed $legalPerson
  101. */
  102. public function setLegalPerson($legalPerson)
  103. {
  104. $this->legalPerson = $legalPerson;
  105. }
  106. /**
  107. * @return mixed
  108. */
  109. public function getCallbackUrl()
  110. {
  111. return $this->callbackUrl;
  112. }
  113. /**
  114. * @param mixed $callbackUrl
  115. */
  116. public function setCallbackUrl($callbackUrl)
  117. {
  118. $this->callbackUrl = $callbackUrl;
  119. }
  120. /**
  121. * @return mixed
  122. */
  123. public function getCloseButton()
  124. {
  125. return $this->closeButton;
  126. }
  127. /**
  128. * @param mixed $closeButton
  129. */
  130. public function setCloseButton($closeButton)
  131. {
  132. $this->closeButton = $closeButton;
  133. }
  134. }