when santa cruz and the peru bolivian confederation were dissolved he became a president