7. In $\triangle A B C$, it is known that
$$
\begin{array}{l}
|\overrightarrow{A B}|=\sqrt{3},|\overrightarrow{B C}|=1, \\
|\overrightarrow{A C}| \cos B=|\overrightarrow{B C}| \cos A \text {. } \\
\text { Then } \overrightarrow{A C} \cdot \overrightarrow{A B}=
\end{array}
$$
7.2.

Let the three sides of $\triangle A B C$ be $a, b, c$. From the given condition and using the Law of Sines, we have
$$
\begin{array}{l}
\sin B \cdot \cos B=\sin A \cdot \cos A \\
\Rightarrow \sin 2 B=\sin 2 A \\
\Rightarrow \angle B=\angle A \text { or } \angle B+\angle A=90^{\circ} .
\end{array}
$$

We will discuss two cases.
(1) If $\angle B=\angle A$, then
$$
b=a=1, c=\sqrt{3}, \angle A=30^{\circ} \text {. }
$$

Thus, $\overrightarrow{A C} \cdot \overrightarrow{A B}=b c \cos A=1 \times \sqrt{3} \times \frac{\sqrt{3}}{2}=\frac{3}{2}$.
(2) If $\angle B+\angle A=90^{\circ}$, then
$$
b=\sqrt{2}, c=\sqrt{3}, \cos A=\frac{\sqrt{2}}{\sqrt{3}} \text {. }
$$

Thus, $\overrightarrow{A C} \cdot \overrightarrow{A B}=b c \cos A=\sqrt{2} \times \sqrt{3} \times \frac{\sqrt{2}}{\sqrt{3}}=2$.