Profit = all sales − all expenses. Each partner gets their share of it (set in Settings).
Cash orders go into the galla. UPI orders go to the partner whose UPI you tapped.
An expense comes out of the pocket of whoever paid: a partner, or the galla.
Settle up compares the money each one holds now with their share, and shows who should give whom. When you have really given it, tap Mark settled. Everyone is then back to zero.