In the cash received book (although they could use a separate discounts allowed book if they wanted to) – because it is when the cash is received that we know whether or not they are entitled to the cash discount.
Certainly never in the sales day book – when the sale is first made, we don’t know whether or not they will be entitled to the cash discount.