ZhimaMerchantCloseloopDataUploadRequest.php 5.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234
  1. <?php
  2. /**
  3. * ALIPAY API: zhima.merchant.closeloop.data.upload request
  4. *
  5. * @author auto create
  6. * @since 1.0, 2018-01-11 15:47:27
  7. */
  8. class ZhimaMerchantCloseloopDataUploadRequest
  9. {
  10. /**
  11. * 公用回传参数(非必填),该参数会透传给商户,商户可以用于业务逻辑处理,请使用json格式。
  12. **/
  13. private $bizExtParams;
  14. /**
  15. * 单条数据的数据列,多个列以逗号隔开。
  16. **/
  17. private $columns;
  18. /**
  19. * 传入的json格式的文件,其中records属性必填。json中的字段可以通过如下步骤获取:首先调用zhima.merchant.data.upload.initialize接口获取数据模板,该接口会返回一个数据模板文件的url地址,如:http://zmxymerchant-prod.oss-cn-shenzhen.zmxy.com.cn/openApi/openDoc/信用护航-负面记录和信用足迹商户数据模板V1.0.xlsx,该数据模板文件详细列出了需要传入的字段,及各字段的要求,data中的各字段就是该文件中列出的字段编码。
  20. **/
  21. private $file;
  22. /**
  23. * 文件的编码,如果文件格式是UTF-8,则填写UTF-8,如果文件格式是GBK,则填写GBK。
  24. **/
  25. private $fileCharset;
  26. /**
  27. * 芝麻平台服务商模式下的二级商户标识(即二级商户PID),如果是直连商户调用该接口,不需要设置
  28. **/
  29. private $linkedMerchantId;
  30. /**
  31. * 主键列使用传入字段进行组合,也可以使用传入的某个单字段(确保主键稳定,而且可以很好的区分不同的数据)。例如order_no,pay_month或者order_no,bill_month组合,对于一个order_no只会有一条数据的情况,直接使用order_no作为主键列。
  32. **/
  33. private $primaryKeyColumns;
  34. /**
  35. * 文件数据记录条数,如file字段中的record数组有10条数据,那么就填10。
  36. **/
  37. private $records;
  38. /**
  39. * 数据应用的场景编码,场景码和场景名称(数字或字符串为场景码)如下:
  40. 8:数据反馈
  41. 32:骑行
  42. CAR_RENTING:租车行业解决方案
  43. 每个场景码对应的数据模板不一样,请使用zhima.merchant.data.upload.initialize接口获取场景码对应的数据模板。
  44. **/
  45. private $sceneCode;
  46. private $apiParas = array();
  47. private $terminalType;
  48. private $terminalInfo;
  49. private $prodCode;
  50. private $apiVersion="1.0";
  51. private $notifyUrl;
  52. private $returnUrl;
  53. private $needEncrypt=false;
  54. public function setBizExtParams($bizExtParams)
  55. {
  56. $this->bizExtParams = $bizExtParams;
  57. $this->apiParas["biz_ext_params"] = $bizExtParams;
  58. }
  59. public function getBizExtParams()
  60. {
  61. return $this->bizExtParams;
  62. }
  63. public function setColumns($columns)
  64. {
  65. $this->columns = $columns;
  66. $this->apiParas["columns"] = $columns;
  67. }
  68. public function getColumns()
  69. {
  70. return $this->columns;
  71. }
  72. public function setFile($file)
  73. {
  74. $this->file = $file;
  75. $this->apiParas["file"] = $file;
  76. }
  77. public function getFile()
  78. {
  79. return $this->file;
  80. }
  81. public function setFileCharset($fileCharset)
  82. {
  83. $this->fileCharset = $fileCharset;
  84. $this->apiParas["file_charset"] = $fileCharset;
  85. }
  86. public function getFileCharset()
  87. {
  88. return $this->fileCharset;
  89. }
  90. public function setLinkedMerchantId($linkedMerchantId)
  91. {
  92. $this->linkedMerchantId = $linkedMerchantId;
  93. $this->apiParas["linked_merchant_id"] = $linkedMerchantId;
  94. }
  95. public function getLinkedMerchantId()
  96. {
  97. return $this->linkedMerchantId;
  98. }
  99. public function setPrimaryKeyColumns($primaryKeyColumns)
  100. {
  101. $this->primaryKeyColumns = $primaryKeyColumns;
  102. $this->apiParas["primary_key_columns"] = $primaryKeyColumns;
  103. }
  104. public function getPrimaryKeyColumns()
  105. {
  106. return $this->primaryKeyColumns;
  107. }
  108. public function setRecords($records)
  109. {
  110. $this->records = $records;
  111. $this->apiParas["records"] = $records;
  112. }
  113. public function getRecords()
  114. {
  115. return $this->records;
  116. }
  117. public function setSceneCode($sceneCode)
  118. {
  119. $this->sceneCode = $sceneCode;
  120. $this->apiParas["scene_code"] = $sceneCode;
  121. }
  122. public function getSceneCode()
  123. {
  124. return $this->sceneCode;
  125. }
  126. public function getApiMethodName()
  127. {
  128. return "zhima.merchant.closeloop.data.upload";
  129. }
  130. public function setNotifyUrl($notifyUrl)
  131. {
  132. $this->notifyUrl=$notifyUrl;
  133. }
  134. public function getNotifyUrl()
  135. {
  136. return $this->notifyUrl;
  137. }
  138. public function setReturnUrl($returnUrl)
  139. {
  140. $this->returnUrl=$returnUrl;
  141. }
  142. public function getReturnUrl()
  143. {
  144. return $this->returnUrl;
  145. }
  146. public function getApiParas()
  147. {
  148. return $this->apiParas;
  149. }
  150. public function getTerminalType()
  151. {
  152. return $this->terminalType;
  153. }
  154. public function setTerminalType($terminalType)
  155. {
  156. $this->terminalType = $terminalType;
  157. }
  158. public function getTerminalInfo()
  159. {
  160. return $this->terminalInfo;
  161. }
  162. public function setTerminalInfo($terminalInfo)
  163. {
  164. $this->terminalInfo = $terminalInfo;
  165. }
  166. public function getProdCode()
  167. {
  168. return $this->prodCode;
  169. }
  170. public function setProdCode($prodCode)
  171. {
  172. $this->prodCode = $prodCode;
  173. }
  174. public function setApiVersion($apiVersion)
  175. {
  176. $this->apiVersion=$apiVersion;
  177. }
  178. public function getApiVersion()
  179. {
  180. return $this->apiVersion;
  181. }
  182. public function setNeedEncrypt($needEncrypt)
  183. {
  184. $this->needEncrypt=$needEncrypt;
  185. }
  186. public function getNeedEncrypt()
  187. {
  188. return $this->needEncrypt;
  189. }
  190. }