in src/ImageSearch/V20180120/Traits/AddItemTrait.php [90:122]
private function buildPostContent()
{
$map = [];
if ($this->itemId === null || $this->itemId === ''
|| $this->cateId === null
|| $this->cateId === ''
|| empty($this->picMap)) {
return false;
}
$map['item_id'] = $this->itemId;
$map['cat_id'] = $this->cateId;
$map['cust_content'] = $this->custContent;
$picListStr = '';
foreach ($this->picMap as $key => $value) {
if ($key === null || $key === ''
|| $value === null
|| $value === '') {
return false;
}
$picListStr .= $key . ',';
$map[$key] = $value;
}
$map['pic_list'] = substr($picListStr, 0, -1);
$this->body($this->buildContent($map));
$this->format('JSON');
return true;
}