UserAuthMiniappTicketRequest.php 4.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201
  1. <?php
  2. class UserAuthMiniappTicketRequest extends SdkRequest {
  3. const REQUEST_URL = "/v2/personalauth/miniappexchange";
  4. private $mode; // 认证模式
  5. private $user; // 用户信息
  6. private $username; // 指定用户姓名
  7. private $idCardNo; // 指定用户身份证号码
  8. private $bankNo; // 指定银行卡号
  9. private $bankMobile; // 指定银行卡预留手机号
  10. private $callbackUrl; // 指定回调地址
  11. private $paperType;
  12. private $otherModes; // 降级认证方式可选项
  13. private $modifyFields; //认证可修改项
  14. public function getUrl() {
  15. return self::REQUEST_URL;
  16. }
  17. public function getHttpParamers() {
  18. $paramSwitcher = ParamSwitcher::instanceParam();
  19. $paramSwitcher->addParam('mode', $this->mode);
  20. $paramSwitcher->addParam('user', $this->user);
  21. $paramSwitcher->addParam('username', $this->username);
  22. $paramSwitcher->addParam('idCardNo', $this->idCardNo);
  23. $paramSwitcher->addParam('bankNo', $this->bankNo);
  24. $paramSwitcher->addParam('bankMobile', $this->bankMobile);
  25. $paramSwitcher->addParam('callbackUrl', $this->callbackUrl);
  26. $paramSwitcher->addParam('paperType', $this->paperType);
  27. $paramSwitcher->addParam('otherModes', $this->otherModes);
  28. $paramSwitcher->addParam('modifyFields', $this->modifyFields);
  29. $httpParameter = HttpParameter::httpPostParamer();
  30. $httpParameter->setJsonParams(json_encode($paramSwitcher->getParams()));
  31. return $httpParameter;
  32. }
  33. /**
  34. * @return mixed
  35. */
  36. public function getMode()
  37. {
  38. return $this->mode;
  39. }
  40. /**
  41. * @param mixed $mode
  42. */
  43. public function setMode($mode)
  44. {
  45. $this->mode = $mode;
  46. }
  47. /**
  48. * @return mixed
  49. */
  50. public function getUser()
  51. {
  52. return $this->user;
  53. }
  54. /**
  55. * @param mixed $mode
  56. */
  57. public function setUser($user)
  58. {
  59. $this->user = $user;
  60. }
  61. /**
  62. * @return mixed
  63. */
  64. public function getUsername()
  65. {
  66. return $this->username;
  67. }
  68. /**
  69. * @param mixed $mode
  70. */
  71. public function setUsername($username)
  72. {
  73. $this->username = $username;
  74. }
  75. /**
  76. * @return mixed
  77. */
  78. public function getIdCardNo()
  79. {
  80. return $this->idCardNo;
  81. }
  82. /**
  83. * @param mixed $mode
  84. */
  85. public function setIdCardNo($idCardNo)
  86. {
  87. $this->idCardNo = $idCardNo;
  88. }
  89. /**
  90. * @return mixed
  91. */
  92. public function getBankNo()
  93. {
  94. return $this->bankNo;
  95. }
  96. /**
  97. * @param mixed $mode
  98. */
  99. public function setBankNo($bankNo)
  100. {
  101. $this->bankNo = $bankNo;
  102. }
  103. /**
  104. * @return mixed
  105. */
  106. public function getBankMobile()
  107. {
  108. return $this->bankMobile;
  109. }
  110. /**
  111. * @param mixed $mode
  112. */
  113. public function setBankMobile($bankMobile)
  114. {
  115. $this->bankMobile = $bankMobile;
  116. }
  117. /**
  118. * @return mixed
  119. */
  120. public function getCallbackUrl()
  121. {
  122. return $this->callbackUrl;
  123. }
  124. /**
  125. * @param mixed $mode
  126. */
  127. public function setCallbackUrl($callbackUrl)
  128. {
  129. $this->callbackUrl = $callbackUrl;
  130. }
  131. /**
  132. * @return mixed
  133. */
  134. public function getPaperType()
  135. {
  136. return $this->paperType;
  137. }
  138. /**
  139. * @param mixed $paperType
  140. */
  141. public function setPaperType($paperType)
  142. {
  143. $this->paperType = $paperType;
  144. }
  145. /**
  146. * @return mixed
  147. */
  148. public function getOtherModes()
  149. {
  150. return $this->otherModes;
  151. }
  152. /**
  153. * @param mixed $otherModes
  154. */
  155. public function setOtherModes($otherModes)
  156. {
  157. $this->otherModes = $otherModes;
  158. }
  159. /**
  160. * @return mixed
  161. */
  162. public function getModifyFields()
  163. {
  164. return $this->modifyFields;
  165. }
  166. /**
  167. * @param mixed $modifyFields
  168. */
  169. public function setModifyFields($modifyFields)
  170. {
  171. $this->modifyFields = $modifyFields;
  172. }
  173. }