CompanyAuthLicenseMiniappTicketRequest.php 3.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178
  1. <?php
  2. /**
  3. * 获取小程序企业认证页面
  4. */
  5. class CompanyAuthLicenseMiniappTicketRequest extends SdkRequest {
  6. const REQUEST_URL = "/companyauth/miniappexchangewithlicense";
  7. private $companyName; // 待认证公司名称
  8. private $registerNo; // 待认证公司注册号
  9. private $legalPerson; // 待认证公司法人姓名
  10. private $callbackUrl; // 认证回调地址
  11. private $platformName; // 平台名称
  12. private $closeButton;
  13. private $license;
  14. private $applicantInfo;
  15. function getUrl() {
  16. return self::REQUEST_URL;
  17. }
  18. function getHttpParamers() {
  19. $paramSwitcher = ParamSwitcher::instanceParam();
  20. $paramSwitcher->addParam('companyName', $this->companyName);
  21. $paramSwitcher->addParam('registerNo', $this->registerNo);
  22. $paramSwitcher->addParam('legalPerson', $this->legalPerson);
  23. $paramSwitcher->addParam('platformName', $this->platformName);
  24. $paramSwitcher->addParam('callbackUrl', $this->callbackUrl);
  25. if(is_string($this->applicantInfo)) {
  26. $paramSwitcher->addParam('applicantInfo', $this->applicantInfo);
  27. } else {
  28. $paramSwitcher->addParam('applicantInfo', json_encode($this->applicantInfo));
  29. }
  30. if($this->license !== null){
  31. $paramSwitcher->addParam('license', $this->license);
  32. }
  33. if($this->closeButton == null){
  34. $paramSwitcher->addParam('closeButton', true);
  35. }else{
  36. $paramSwitcher->addParam('closeButton', $this->closeButton);
  37. }
  38. $httpParameters = HttpParameter::httpPostParamer();
  39. $httpParameters->setParams($paramSwitcher->getParams());
  40. return $httpParameters;
  41. }
  42. /**
  43. * @return mixed
  44. */
  45. public function getCompanyName()
  46. {
  47. return $this->companyName;
  48. }
  49. /**
  50. * @param mixed $companyName
  51. */
  52. public function setCompanyName($companyName)
  53. {
  54. $this->companyName = $companyName;
  55. }
  56. /**
  57. * @return mixed
  58. */
  59. public function getRegisterNo()
  60. {
  61. return $this->registerNo;
  62. }
  63. /**
  64. * @param mixed $registerNo
  65. */
  66. public function setRegisterNo($registerNo)
  67. {
  68. $this->registerNo = $registerNo;
  69. }
  70. /**
  71. * @return mixed
  72. */
  73. public function getLegalPerson()
  74. {
  75. return $this->legalPerson;
  76. }
  77. /**
  78. * @param mixed $legalPerson
  79. */
  80. public function setLegalPerson($legalPerson)
  81. {
  82. $this->legalPerson = $legalPerson;
  83. }
  84. /**
  85. * @return mixed
  86. */
  87. public function getCallbackUrl()
  88. {
  89. return $this->callbackUrl;
  90. }
  91. /**
  92. * @param mixed $callbackUrl
  93. */
  94. public function setCallbackUrl($callbackUrl)
  95. {
  96. $this->callbackUrl = $callbackUrl;
  97. }
  98. /**
  99. * @return mixed
  100. */
  101. public function getPlatformName()
  102. {
  103. return $this->platformName;
  104. }
  105. /**
  106. * @param mixed $platformName
  107. */
  108. public function setPlatformName($platformName)
  109. {
  110. $this->platformName = $platformName;
  111. }
  112. /**
  113. * @return mixed
  114. */
  115. public function getCloseButton()
  116. {
  117. return $this->closeButton;
  118. }
  119. /**
  120. * @param mixed $closeButton
  121. */
  122. public function setCloseButton($closeButton)
  123. {
  124. $this->closeButton = $closeButton;
  125. }
  126. /**
  127. * @return mixed
  128. */
  129. public function getLicense()
  130. {
  131. return $this->license;
  132. }
  133. /**
  134. * @param mixed $license
  135. */
  136. public function setLicense($license)
  137. {
  138. $this->license = $license;
  139. }
  140. /**
  141. * @return mixed
  142. */
  143. public function getApplicantInfo()
  144. {
  145. return $this->applicantInfo;
  146. }
  147. /**
  148. * @param mixed $applicantInfo
  149. */
  150. public function setApplicantInfo($applicantInfo)
  151. {
  152. $this->applicantInfo = $applicantInfo;
  153. }
  154. }