OapiFinanceLoanNotifyCreditRequest.php 7.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370
  1. <?php
  2. /**
  3. * dingtalk API: dingtalk.oapi.finance.loan.notify.credit request
  4. *
  5. * @author auto create
  6. * @since 1.0, 2022.09.13
  7. */
  8. class OapiFinanceLoanNotifyCreditRequest
  9. {
  10. /**
  11. * 授信额度(单位:分),授信成功必需
  12. **/
  13. private $amount;
  14. /**
  15. * 可用授信额度
  16. **/
  17. private $availableAmount;
  18. /**
  19. * 授信金额变化值: 等于0(默认) 不变,大于0 增加,小于0 减少
  20. **/
  21. private $changeAmount;
  22. /**
  23. * 授信完成时间
  24. **/
  25. private $completeTime;
  26. /**
  27. * 授信编号
  28. **/
  29. private $creditNo;
  30. /**
  31. * 授信类型:null或0(默认) 授信额度无变化,1 授信额度有变化,变化值见changeAmount
  32. **/
  33. private $creditType;
  34. /**
  35. * 日利率(精确4位小数,百分之*),样例:0.0125
  36. **/
  37. private $dailyInterestRate;
  38. /**
  39. * 扩展信息
  40. **/
  41. private $extension;
  42. /**
  43. * 身份证号
  44. **/
  45. private $idCardNo;
  46. /**
  47. * 下一次申请日期
  48. **/
  49. private $nextApplyDay;
  50. /**
  51. * 渠道方名称
  52. **/
  53. private $openChannelName;
  54. /**
  55. * 渠道方产品码
  56. **/
  57. private $openProductCode;
  58. /**
  59. * 渠道方产品名称
  60. **/
  61. private $openProductName;
  62. /**
  63. * 渠道方产品类型
  64. **/
  65. private $openProductType;
  66. /**
  67. * 拒绝原因错误码,授信失败必需
  68. **/
  69. private $refuseCode;
  70. /**
  71. * 拒绝原因,授信失败必需
  72. **/
  73. private $refuseReason;
  74. /**
  75. * 授信结果:0 未提交,1 授信申请中,2 授信成功/审批通过,3 授信失败/审批拒绝
  76. **/
  77. private $status;
  78. /**
  79. * 授信提交/申请时间
  80. **/
  81. private $submitTime;
  82. /**
  83. * 手机号
  84. **/
  85. private $userMobile;
  86. /**
  87. * 年利率(精确2位小数,百分之*),样例:5.45
  88. **/
  89. private $yearInterestRate;
  90. private $apiParas = array();
  91. public function setAmount($amount)
  92. {
  93. $this->amount = $amount;
  94. $this->apiParas["amount"] = $amount;
  95. }
  96. public function getAmount()
  97. {
  98. return $this->amount;
  99. }
  100. public function setAvailableAmount($availableAmount)
  101. {
  102. $this->availableAmount = $availableAmount;
  103. $this->apiParas["available_amount"] = $availableAmount;
  104. }
  105. public function getAvailableAmount()
  106. {
  107. return $this->availableAmount;
  108. }
  109. public function setChangeAmount($changeAmount)
  110. {
  111. $this->changeAmount = $changeAmount;
  112. $this->apiParas["change_amount"] = $changeAmount;
  113. }
  114. public function getChangeAmount()
  115. {
  116. return $this->changeAmount;
  117. }
  118. public function setCompleteTime($completeTime)
  119. {
  120. $this->completeTime = $completeTime;
  121. $this->apiParas["complete_time"] = $completeTime;
  122. }
  123. public function getCompleteTime()
  124. {
  125. return $this->completeTime;
  126. }
  127. public function setCreditNo($creditNo)
  128. {
  129. $this->creditNo = $creditNo;
  130. $this->apiParas["credit_no"] = $creditNo;
  131. }
  132. public function getCreditNo()
  133. {
  134. return $this->creditNo;
  135. }
  136. public function setCreditType($creditType)
  137. {
  138. $this->creditType = $creditType;
  139. $this->apiParas["credit_type"] = $creditType;
  140. }
  141. public function getCreditType()
  142. {
  143. return $this->creditType;
  144. }
  145. public function setDailyInterestRate($dailyInterestRate)
  146. {
  147. $this->dailyInterestRate = $dailyInterestRate;
  148. $this->apiParas["daily_interest_rate"] = $dailyInterestRate;
  149. }
  150. public function getDailyInterestRate()
  151. {
  152. return $this->dailyInterestRate;
  153. }
  154. public function setExtension($extension)
  155. {
  156. $this->extension = $extension;
  157. $this->apiParas["extension"] = $extension;
  158. }
  159. public function getExtension()
  160. {
  161. return $this->extension;
  162. }
  163. public function setIdCardNo($idCardNo)
  164. {
  165. $this->idCardNo = $idCardNo;
  166. $this->apiParas["id_card_no"] = $idCardNo;
  167. }
  168. public function getIdCardNo()
  169. {
  170. return $this->idCardNo;
  171. }
  172. public function setNextApplyDay($nextApplyDay)
  173. {
  174. $this->nextApplyDay = $nextApplyDay;
  175. $this->apiParas["next_apply_day"] = $nextApplyDay;
  176. }
  177. public function getNextApplyDay()
  178. {
  179. return $this->nextApplyDay;
  180. }
  181. public function setOpenChannelName($openChannelName)
  182. {
  183. $this->openChannelName = $openChannelName;
  184. $this->apiParas["open_channel_name"] = $openChannelName;
  185. }
  186. public function getOpenChannelName()
  187. {
  188. return $this->openChannelName;
  189. }
  190. public function setOpenProductCode($openProductCode)
  191. {
  192. $this->openProductCode = $openProductCode;
  193. $this->apiParas["open_product_code"] = $openProductCode;
  194. }
  195. public function getOpenProductCode()
  196. {
  197. return $this->openProductCode;
  198. }
  199. public function setOpenProductName($openProductName)
  200. {
  201. $this->openProductName = $openProductName;
  202. $this->apiParas["open_product_name"] = $openProductName;
  203. }
  204. public function getOpenProductName()
  205. {
  206. return $this->openProductName;
  207. }
  208. public function setOpenProductType($openProductType)
  209. {
  210. $this->openProductType = $openProductType;
  211. $this->apiParas["open_product_type"] = $openProductType;
  212. }
  213. public function getOpenProductType()
  214. {
  215. return $this->openProductType;
  216. }
  217. public function setRefuseCode($refuseCode)
  218. {
  219. $this->refuseCode = $refuseCode;
  220. $this->apiParas["refuse_code"] = $refuseCode;
  221. }
  222. public function getRefuseCode()
  223. {
  224. return $this->refuseCode;
  225. }
  226. public function setRefuseReason($refuseReason)
  227. {
  228. $this->refuseReason = $refuseReason;
  229. $this->apiParas["refuse_reason"] = $refuseReason;
  230. }
  231. public function getRefuseReason()
  232. {
  233. return $this->refuseReason;
  234. }
  235. public function setStatus($status)
  236. {
  237. $this->status = $status;
  238. $this->apiParas["status"] = $status;
  239. }
  240. public function getStatus()
  241. {
  242. return $this->status;
  243. }
  244. public function setSubmitTime($submitTime)
  245. {
  246. $this->submitTime = $submitTime;
  247. $this->apiParas["submit_time"] = $submitTime;
  248. }
  249. public function getSubmitTime()
  250. {
  251. return $this->submitTime;
  252. }
  253. public function setUserMobile($userMobile)
  254. {
  255. $this->userMobile = $userMobile;
  256. $this->apiParas["user_mobile"] = $userMobile;
  257. }
  258. public function getUserMobile()
  259. {
  260. return $this->userMobile;
  261. }
  262. public function setYearInterestRate($yearInterestRate)
  263. {
  264. $this->yearInterestRate = $yearInterestRate;
  265. $this->apiParas["year_interest_rate"] = $yearInterestRate;
  266. }
  267. public function getYearInterestRate()
  268. {
  269. return $this->yearInterestRate;
  270. }
  271. public function getApiMethodName()
  272. {
  273. return "dingtalk.oapi.finance.loan.notify.credit";
  274. }
  275. public function getApiParas()
  276. {
  277. return $this->apiParas;
  278. }
  279. public function check()
  280. {
  281. RequestCheckUtil::checkNotNull($this->amount,"amount");
  282. RequestCheckUtil::checkNotNull($this->availableAmount,"availableAmount");
  283. RequestCheckUtil::checkNotNull($this->changeAmount,"changeAmount");
  284. RequestCheckUtil::checkNotNull($this->completeTime,"completeTime");
  285. RequestCheckUtil::checkNotNull($this->creditNo,"creditNo");
  286. RequestCheckUtil::checkNotNull($this->creditType,"creditType");
  287. RequestCheckUtil::checkNotNull($this->dailyInterestRate,"dailyInterestRate");
  288. RequestCheckUtil::checkNotNull($this->idCardNo,"idCardNo");
  289. RequestCheckUtil::checkNotNull($this->nextApplyDay,"nextApplyDay");
  290. RequestCheckUtil::checkNotNull($this->openChannelName,"openChannelName");
  291. RequestCheckUtil::checkNotNull($this->openProductCode,"openProductCode");
  292. RequestCheckUtil::checkNotNull($this->openProductName,"openProductName");
  293. RequestCheckUtil::checkNotNull($this->openProductType,"openProductType");
  294. RequestCheckUtil::checkNotNull($this->refuseCode,"refuseCode");
  295. RequestCheckUtil::checkNotNull($this->refuseReason,"refuseReason");
  296. RequestCheckUtil::checkNotNull($this->status,"status");
  297. RequestCheckUtil::checkNotNull($this->submitTime,"submitTime");
  298. RequestCheckUtil::checkNotNull($this->userMobile,"userMobile");
  299. RequestCheckUtil::checkNotNull($this->yearInterestRate,"yearInterestRate");
  300. }
  301. public function putOtherTextParam($key, $value) {
  302. $this->apiParas[$key] = $value;
  303. $this->$key = $value;
  304. }
  305. }