Here's a useful spreadsheet for comparing loans, you want to boil down the product to an internal rate of return.
https://www.mortgagesexposed.com/spreadsheets/Loan%20Comparator.xlsx
So for the first mortgage, I would compare these 2 loans, with a 24 year term, compared over 5 years.
2.3% for 10 months with a rate change in 10 months of 1.19% (an assumption being made, that you can get the same 1.19% deal in 10 months) = IRR 1.4048%
vs
1.19% for 5 years with a fee of 1922 (so the fee being the ERC from the other mortgage) = IRR 1.4245%
The spreadsheet helpfully boils down the answer to a net difference in cost, which for this one means you'll save, in total, £163.86 in net present value.
The 2nd loan is different
2.39% for 23 months with a rate change 23 months of 1.19% = 1.7026%
vs
1.19% for 5 years with a fee of 2222 (so the fee being the ERC from the other mortgage) = IRR 1.4599%
Switching this one saves you £2,017.04 in net present value terms over 5 years.