I have three tables :
I want join cart table and product table and get an additional column called total price that is the result of price in product *qty in cart
How to do this in django orm
I tried f function but it didn't work
You can try this.
Cart.objects.annotate(total_price=F('product__price')*F('qty'))