Ei kuvausta

TbkTpwdCreateRequest.php 1.6KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114
  1. <?php
  2. /**
  3. * TOP API: taobao.tbk.tpwd.create request
  4. *
  5. * @author auto create
  6. * @since 1.0, 2018.04.04
  7. */
  8. class TbkTpwdCreateRequest
  9. {
  10. /**
  11. * 扩展字段JSON格式
  12. **/
  13. private $ext;
  14. /**
  15. * 口令弹框logoURL
  16. **/
  17. private $logo;
  18. /**
  19. * 口令弹框内容
  20. **/
  21. private $text;
  22. /**
  23. * 口令跳转目标页
  24. **/
  25. private $url;
  26. /**
  27. * 生成口令的淘宝用户ID
  28. **/
  29. private $userId;
  30. private $apiParas = array();
  31. public function setExt($ext)
  32. {
  33. $this->ext = $ext;
  34. $this->apiParas["ext"] = $ext;
  35. }
  36. public function getExt()
  37. {
  38. return $this->ext;
  39. }
  40. public function setLogo($logo)
  41. {
  42. $this->logo = $logo;
  43. $this->apiParas["logo"] = $logo;
  44. }
  45. public function getLogo()
  46. {
  47. return $this->logo;
  48. }
  49. public function setText($text)
  50. {
  51. $this->text = $text;
  52. $this->apiParas["text"] = $text;
  53. }
  54. public function getText()
  55. {
  56. return $this->text;
  57. }
  58. public function setUrl($url)
  59. {
  60. $this->url = $url;
  61. $this->apiParas["url"] = $url;
  62. }
  63. public function getUrl()
  64. {
  65. return $this->url;
  66. }
  67. public function setUserId($userId)
  68. {
  69. $this->userId = $userId;
  70. $this->apiParas["user_id"] = $userId;
  71. }
  72. public function getUserId()
  73. {
  74. return $this->userId;
  75. }
  76. public function getApiMethodName()
  77. {
  78. return "taobao.tbk.tpwd.create";
  79. }
  80. public function getApiParas()
  81. {
  82. return $this->apiParas;
  83. }
  84. public function check()
  85. {
  86. RequestCheckUtil::checkNotNull($this->text,"text");
  87. RequestCheckUtil::checkNotNull($this->url,"url");
  88. }
  89. public function putOtherTextParam($key, $value) {
  90. $this->apiParas[$key] = $value;
  91. $this->$key = $value;
  92. }
  93. }