  Self-dual codes over finite fields and over some finite rings have been of
interest and extensively studied due to their nice algebraic structures and
wide applications. Recently, characterization and enumeration of Euclidean
self-dual linear codes over the
ring~$\mathbb{F}_{q}+u\mathbb{F}_{q}+u^2\mathbb{F}_{q}$ with $u^3=0$ have been
established. In this paper, Hermitian self-dual linear codes over
$\mathbb{F}_{q}+u\mathbb{F}_{q}+u^2\mathbb{F}_{q}$ are studied for all square
prime powers~$q$. Complete characterization and enumeration of such codes are
given. Subsequently, algebraic characterization of $H$-quasi-abelian codes in
$\mathbb{F}_q[G]$ is studied, where $H\leq G$ are finite abelian groups and
$\mathbb{F}_q[H]$ is a principal ideal group algebra. General characterization
and enumeration of $H$-quasi-abelian codes and self-dual $H$-quasi-abelian
codes in $\mathbb{F}_q[G]$ are given. For the special case where the field
characteristic is $3$, an explicit formula for the number of self-dual $A\times
\mathbb{Z}_3$-quasi-abelian codes in $\mathbb{F}_{3^m}[A\times
\mathbb{Z}_3\times B]$ is determined for all finite abelian groups $A$ and $B$
such that $3\nmid |A|$ as well as their construction. Precisely, such codes can
be represented in terms of linear codes and self-dual linear codes over
$\mathbb{F}_{3^m}+u\mathbb{F}_{3^m}+u^2\mathbb{F}_{3^m}$.
