برای فرزند
$(this).find('li').each(function(){
console.log( $(this).attr('id') );
});


برای پدر هم بجای find بزار parents