We can use distribution property to multiply the polynomial by the monomial.
$$ \begin{aligned} \left( x^2-2x+1 \right) \cdot \left( \color{orangered}{-7} \right) &= x^2 \cdot \color{orangered}{-7} + \left( -2x\right) \cdot \color{orangered}{-7} + 1 \cdot \color{orangered}{-7} = \\ &= -7x^2+14x-7 \end{aligned} $$