#NEWLINE# @ classmethod #NEWLINE# def latest( cls , case_id , section_id , product_id ) : #NEWLINE# #INDENT# relevant = cls . get_ordered_transactions_for_stock ( case_id , relevant , product_id ) #NEWLINE# try : #NEWLINE# #INDENT# return relevant . select_related ( ) [ 0 ] #NEWLINE# #UNINDENT# except IndexError : #NEWLINE# #INDENT# return None