refactor and add line items