Let $G$ be a finite group, and let $A$ and $B$ be two abelian subgroups of $G$. Let $K$ be a number field such that all characters of $A$ and of $B$ take values in $K$. Let $\mathcal{O}_K$ be the ring of algebraic integers in $K$. Write $\{e_1,\ldots, e_n\}$ for the set of primitive idempotents of $KA$ and $\{f_1,\ldots, f_m\}$ for the set of primitive idempotents of $KB$.
Assume now that the $\mathcal{O}_K$-algebra generated by $\{e_1,\ldots, e_n,f_1,\ldots f_m\}$ is a finite $\mathcal{O}_K$-module.
Question: Must $A$ and $B$ commute under this assumption?
Edit: here is a motivating example: When both $A$ and $B$ are of order 2, the group they generate is isomorphic to $D_{2n}$ for some $n$. By considering some irreducible representations, the finiteness of the algebra becomes equivalent to the integrality of $\cos(\pi/n)$, and I believe this is not an algebraic integer for $n>2$.