OapiAppstoreOrdersSpecialCanalCreateOrderRequest.php 3.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184
  1. <?php
  2. /**
  3. * dingtalk API: dingtalk.oapi.appstore.orders.special_canal.create_order request
  4. *
  5. * @author auto create
  6. * @since 1.0, 2021.10.12
  7. */
  8. class OapiAppstoreOrdersSpecialCanalCreateOrderRequest
  9. {
  10. /**
  11. * 下单企业id
  12. **/
  13. private $corpid;
  14. /**
  15. * 订购周期数量
  16. **/
  17. private $cycNum;
  18. /**
  19. * 订购的周期单位:1-年,2-月,3-日
  20. **/
  21. private $cycUnit;
  22. /**
  23. * 商品码
  24. **/
  25. private $goodsCode;
  26. /**
  27. * 规格码
  28. **/
  29. private $itemCode;
  30. /**
  31. * 下单人手机号
  32. **/
  33. private $mobile;
  34. /**
  35. * 联通订单id
  36. **/
  37. private $orderCenterId;
  38. /**
  39. * 订购价格
  40. **/
  41. private $price;
  42. /**
  43. * 订购数量
  44. **/
  45. private $quantity;
  46. private $apiParas = array();
  47. public function setCorpid($corpid)
  48. {
  49. $this->corpid = $corpid;
  50. $this->apiParas["corpid"] = $corpid;
  51. }
  52. public function getCorpid()
  53. {
  54. return $this->corpid;
  55. }
  56. public function setCycNum($cycNum)
  57. {
  58. $this->cycNum = $cycNum;
  59. $this->apiParas["cyc_num"] = $cycNum;
  60. }
  61. public function getCycNum()
  62. {
  63. return $this->cycNum;
  64. }
  65. public function setCycUnit($cycUnit)
  66. {
  67. $this->cycUnit = $cycUnit;
  68. $this->apiParas["cyc_unit"] = $cycUnit;
  69. }
  70. public function getCycUnit()
  71. {
  72. return $this->cycUnit;
  73. }
  74. public function setGoodsCode($goodsCode)
  75. {
  76. $this->goodsCode = $goodsCode;
  77. $this->apiParas["goods_code"] = $goodsCode;
  78. }
  79. public function getGoodsCode()
  80. {
  81. return $this->goodsCode;
  82. }
  83. public function setItemCode($itemCode)
  84. {
  85. $this->itemCode = $itemCode;
  86. $this->apiParas["item_code"] = $itemCode;
  87. }
  88. public function getItemCode()
  89. {
  90. return $this->itemCode;
  91. }
  92. public function setMobile($mobile)
  93. {
  94. $this->mobile = $mobile;
  95. $this->apiParas["mobile"] = $mobile;
  96. }
  97. public function getMobile()
  98. {
  99. return $this->mobile;
  100. }
  101. public function setOrderCenterId($orderCenterId)
  102. {
  103. $this->orderCenterId = $orderCenterId;
  104. $this->apiParas["order_center_id"] = $orderCenterId;
  105. }
  106. public function getOrderCenterId()
  107. {
  108. return $this->orderCenterId;
  109. }
  110. public function setPrice($price)
  111. {
  112. $this->price = $price;
  113. $this->apiParas["price"] = $price;
  114. }
  115. public function getPrice()
  116. {
  117. return $this->price;
  118. }
  119. public function setQuantity($quantity)
  120. {
  121. $this->quantity = $quantity;
  122. $this->apiParas["quantity"] = $quantity;
  123. }
  124. public function getQuantity()
  125. {
  126. return $this->quantity;
  127. }
  128. public function getApiMethodName()
  129. {
  130. return "dingtalk.oapi.appstore.orders.special_canal.create_order";
  131. }
  132. public function getApiParas()
  133. {
  134. return $this->apiParas;
  135. }
  136. public function check()
  137. {
  138. RequestCheckUtil::checkNotNull($this->corpid,"corpid");
  139. RequestCheckUtil::checkNotNull($this->cycNum,"cycNum");
  140. RequestCheckUtil::checkNotNull($this->cycUnit,"cycUnit");
  141. RequestCheckUtil::checkNotNull($this->goodsCode,"goodsCode");
  142. RequestCheckUtil::checkNotNull($this->itemCode,"itemCode");
  143. RequestCheckUtil::checkNotNull($this->mobile,"mobile");
  144. RequestCheckUtil::checkNotNull($this->orderCenterId,"orderCenterId");
  145. RequestCheckUtil::checkNotNull($this->price,"price");
  146. RequestCheckUtil::checkNotNull($this->quantity,"quantity");
  147. }
  148. public function putOtherTextParam($key, $value) {
  149. $this->apiParas[$key] = $value;
  150. $this->$key = $value;
  151. }
  152. }