ItemImgDeleteRequest.php 1.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283
  1. <?php
  2. /**
  3. * TOP API: taobao.item.img.delete request
  4. *
  5. * @author auto create
  6. * @since 1.0, 2015.05.08
  7. */
  8. class ItemImgDeleteRequest
  9. {
  10. /**
  11. * 商品图片ID
  12. **/
  13. private $id;
  14. /**
  15. * 标记是否要删除第6张图,因为第6张图与普通商品图片不是存储在同一个位置的无图片ID,所以要通过一个标记来判断是否为第6张图,目前第6张图业务主要用在女装业务下
  16. **/
  17. private $isSixthPic;
  18. /**
  19. * 商品数字ID
  20. **/
  21. private $numIid;
  22. private $apiParas = array();
  23. public function setId($id)
  24. {
  25. $this->id = $id;
  26. $this->apiParas["id"] = $id;
  27. }
  28. public function getId()
  29. {
  30. return $this->id;
  31. }
  32. public function setIsSixthPic($isSixthPic)
  33. {
  34. $this->isSixthPic = $isSixthPic;
  35. $this->apiParas["is_sixth_pic"] = $isSixthPic;
  36. }
  37. public function getIsSixthPic()
  38. {
  39. return $this->isSixthPic;
  40. }
  41. public function setNumIid($numIid)
  42. {
  43. $this->numIid = $numIid;
  44. $this->apiParas["num_iid"] = $numIid;
  45. }
  46. public function getNumIid()
  47. {
  48. return $this->numIid;
  49. }
  50. public function getApiMethodName()
  51. {
  52. return "taobao.item.img.delete";
  53. }
  54. public function getApiParas()
  55. {
  56. return $this->apiParas;
  57. }
  58. public function check()
  59. {
  60. RequestCheckUtil::checkNotNull($this->id,"id");
  61. RequestCheckUtil::checkMinValue($this->id,1,"id");
  62. RequestCheckUtil::checkNotNull($this->numIid,"numIid");
  63. RequestCheckUtil::checkMinValue($this->numIid,1,"numIid");
  64. }
  65. public function putOtherTextParam($key, $value) {
  66. $this->apiParas[$key] = $value;
  67. $this->$key = $value;
  68. }
  69. }