Let \( P \) be a plane passing through the points \( (1,0,1) \), \( (1,-2,1) \) and \( (0,1,-2) \). Let a vector \( \vec{a}=\alpha \hat{i}+\beta \hat{j}+\gamma \hat{k} \) be such that \( \vec{a} \) is parallel to the plane \( P \), perpendicular to \( (\hat{i}+2\hat{j}+3\hat{k}) \) and \( \vec{a}\cdot(\hat{i}+\hat{j}+2\hat{k})=2 \), then \( (\alpha-\beta+\gamma)^{2} \) equals _______.