let notIdList = data.filter(item => !!!item.lineId); let ids = notIdList.map(ro=>ro.itemId).join(",")