Sort items in list and label pdf creation