SaasApplyAppRequest.php 4.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222
  1. <?php
  2. class SaasApplyAppRequest extends SdkRequest {
  3. const REQUEST_URL = "/saas/v2/company/applyapp";
  4. private $companyId;
  5. private $appName;
  6. private $domain;
  7. private $loginUrl;
  8. private $casVerifyUrl;
  9. private $callbackUrl;
  10. private $contractCallbackUrl;
  11. private $messageStrategy;
  12. private $contractMessageCallbackUrl;
  13. private $contractByPage;
  14. private $callbackForPage;
  15. public function getUrl() {
  16. return self::REQUEST_URL;
  17. }
  18. public function getHttpParamers() {
  19. $paramSwitcher = ParamSwitcher::instanceParam();
  20. $paramSwitcher->addParam('companyId', $this->companyId);
  21. $paramSwitcher->addParam('appName', $this->appName);
  22. $paramSwitcher->addParam('domain', $this->domain);
  23. $paramSwitcher->addParam('loginUrl',$this->loginUrl);
  24. $paramSwitcher->addParam('casVerifyUrl',$this->casVerifyUrl);
  25. $paramSwitcher->addParam('callbackUrl',$this->callbackUrl);
  26. $paramSwitcher->addParam('contractCallbackUrl',$this->contractCallbackUrl);
  27. $paramSwitcher->addParam('messageStrategy',$this->messageStrategy);
  28. $paramSwitcher->addParam('contractMessageCallbackUrl',$this->contractMessageCallbackUrl);
  29. $paramSwitcher->addParam('contractByPage',$this->contractByPage);
  30. $paramSwitcher->addParam('callbackForPage',$this->callbackForPage);
  31. $httpParameters = HttpParameter::httpPostParamer();
  32. $httpParameters->setJsonParams(json_encode($paramSwitcher->getParams()));
  33. return $httpParameters;
  34. }
  35. /**
  36. * @return mixed
  37. */
  38. public function getCompanyId()
  39. {
  40. return $this->companyId;
  41. }
  42. /**
  43. * @param mixed $companyId
  44. */
  45. public function setCompanyId($companyId)
  46. {
  47. $this->companyId = $companyId;
  48. }
  49. /**
  50. * @return mixed
  51. */
  52. public function getAppName()
  53. {
  54. return $this->appName;
  55. }
  56. /**
  57. * @param mixed $appName
  58. */
  59. public function setAppName($appName)
  60. {
  61. $this->appName = $appName;
  62. }
  63. /**
  64. * @return mixed
  65. */
  66. public function getDomain()
  67. {
  68. return $this->domain;
  69. }
  70. /**
  71. * @param mixed $domain
  72. */
  73. public function setDomain($domain)
  74. {
  75. $this->domain = $domain;
  76. }
  77. /**
  78. * @return mixed
  79. */
  80. public function getLoginUrl()
  81. {
  82. return $this->loginUrl;
  83. }
  84. /**
  85. * @param mixed $loginUrl
  86. */
  87. public function setLoginUrl($loginUrl)
  88. {
  89. $this->loginUrl = $loginUrl;
  90. }
  91. /**
  92. * @return mixed
  93. */
  94. public function getCasVerifyUrl()
  95. {
  96. return $this->casVerifyUrl;
  97. }
  98. /**
  99. * @param mixed $casVerifyUrl
  100. */
  101. public function setCasVerifyUrl($casVerifyUrl)
  102. {
  103. $this->casVerifyUrl = $casVerifyUrl;
  104. }
  105. /**
  106. * @return mixed
  107. */
  108. public function getCallbackUrl()
  109. {
  110. return $this->callbackUrl;
  111. }
  112. /**
  113. * @param mixed $callbackUrl
  114. */
  115. public function setCallbackUrl($callbackUrl)
  116. {
  117. $this->callbackUrl = $callbackUrl;
  118. }
  119. /**
  120. * @return mixed
  121. */
  122. public function getContractCallbackUrl()
  123. {
  124. return $this->contractCallbackUrl;
  125. }
  126. /**
  127. * @param mixed $contractCallbackUrl
  128. */
  129. public function setContractCallbackUrl($contractCallbackUrl)
  130. {
  131. $this->contractCallbackUrl = $contractCallbackUrl;
  132. }
  133. /**
  134. * @return mixed
  135. */
  136. public function getMessageStrategy()
  137. {
  138. return $this->messageStrategy;
  139. }
  140. /**
  141. * @param mixed $messageStrategy
  142. */
  143. public function setMessageStrategy($messageStrategy)
  144. {
  145. $this->messageStrategy = $messageStrategy;
  146. }
  147. /**
  148. * @return mixed
  149. */
  150. public function getContractMessageCallbackUrl()
  151. {
  152. return $this->contractMessageCallbackUrl;
  153. }
  154. /**
  155. * @param mixed $contractMessageCallbackUrl
  156. */
  157. public function setContractMessageCallbackUrl($contractMessageCallbackUrl)
  158. {
  159. $this->contractMessageCallbackUrl = $contractMessageCallbackUrl;
  160. }
  161. /**
  162. * @return mixed
  163. */
  164. public function getContractByPage()
  165. {
  166. return $this->contractByPage;
  167. }
  168. /**
  169. * @param mixed $contractByPage
  170. */
  171. public function setContractByPage($contractByPage)
  172. {
  173. $this->contractByPage = $contractByPage;
  174. }
  175. /**
  176. * @return mixed
  177. */
  178. public function getCallbackForPage()
  179. {
  180. return $this->callbackForPage;
  181. }
  182. /**
  183. * @param mixed $callbackForPage
  184. */
  185. public function setCallbackForPage($callbackForPage)
  186. {
  187. $this->callbackForPage = $callbackForPage;
  188. }
  189. }