add sort by level and position to ld activity dao