function onSignInCallback(){gapi.client.load("plus","v1",apiClientLoaded)}function apiClientLoaded(){gapi.client.plus.people.get({userId:"me"}).execute(handleEmailResponse)}function handleEmailResponse(n){n!=null&&n!=undefined&&$.ajax({type:"POST",url:"/GoogleAuth",data:JSON.stringify({GoogleResponse:n}),contentType:"application/json; charset=utf-8",dataType:"json",async:!1,success:function(n){n.d==!0&&(window.location.href="/Dashboard")},error:function(){}})}function LoginGoogle(){gapi.auth.signIn({clientid:"1043863343632-1s0bl6q7cr8ef08sl9o9q87u155qr738.apps.googleusercontent.com",cookiepolicy:"none",callback:"onSignInCallback",scope:"email"})}function LoginFacebook(){FB.login(function(n){n.authResponse?FB.api("/me",{fields:"id,name,email,gender"},function(n){n!=null&&n!=undefined&&$.ajax({type:"POST",url:"/FacebookAuth",data:JSON.stringify({FacebookResponse:n}),contentType:"application/json; charset=utf-8",dataType:"json",async:!1,success:function(n){n.d=="1"?window.location.href="/Dashboard":n.d=="0"?radalert("Falha no login. Entre em contato com nosso suporte técnico",420,220,"CARFACTS"):radalert(n.d,420,220,"CARFACTS")},error:function(){}})}):console.log("User cancelled login or did not fully authorize.")},{scope:"public_profile,email"})}window.fbAsyncInit=function(){FB.init({appId:"607901992681643",cookie:!1,xfbml:!0,version:"v2.5"})},function(n,t,i){var r,u=n.getElementsByTagName(t)[0];n.getElementById(i)||(r=n.createElement(t),r.id=i,r.src="//connect.facebook.net/en_US/sdk.js",u.parentNode.insertBefore(r,u))}(document,"script","facebook-jssdk")