set messageid and date if not nil in render method