PageSourceSearch

https://www.affittochiaro.it/build/assets/login-ad2307a5.js

js affittochiaro.it collected 2026-10-07 21:38:16 UTC 4,831 bytes, 1 lines download raw bytes

1import{l as e,j as t,V as s,a5 as o,q as a,s as r,t as i,z as l,A as c,U as n,a2 as d,x as u,u as m,v as h,E as g,a3 as p,a4 as b}from"./app-8e024fd5.js";const _={name:"Login",mixins:[t],data:()=>({login_data:{},errors:{},submitted:!1,success:!1,show_password:!1,errorMsg:""}),methods:{doLogin(){this.$store.doLogin(this.login_data).then((e=>{if(gtag("event","login",{method:"site_form"}),fbq("trackCustom","Login",{method:"site_form"}),this.submitted=!0,e.error)return this.errors=e.error,this.errorMsg=e.error,void setTimeout((()=>{const t=document.getElementById("otp_router_link");t&&t.addEventListener("click",(s=>{s.preventDefault(),this.$router.push(t.getAttribute("data-link")),e.token&&setTimeout((()=>{localStorage.setItem("token",e.token)}),1500)}))}),1e3);if("OK"==e.status){this.success=!0,localStorage.setItem("token",e.token),window.axios.defaults.headers.common.Authorization=`Bearer ${e.token}`,localStorage.removeItem("first_search_data");const t=this.$store.user;this.$route.query&&this.$route.query.then?this.$router.push(s(this.$route.query.then,t)):this.$route.query&&this.$route.query.redirect?this.$router.push(s(this.$route.query.redirect,t)):this.$router.push(o(t))}else this.success=!1}))},handleSocialLogin(e){localStorage.removeItem("oauth_redirect_after"),window.location.href=`/auth/${e}`}},mounted(){if(this.$route.query&&this.$route.query.error){let e="";if("account_inactive"===this.$route.query.error)e="Questo account non è attivo.";else e="Errore sconosciuto.";this.errorMsg=e,this.submitted=!0,this.success=!1}},unmounted(){const e=document.getElementById("otp_router_link");e&&e.removeEventListener("click",(t=>{t.preventDefault(),this.$router.push(e.getAttribute("href"))}))}},f=e=>(p("data-v-b711c6ec"),e=e(),b(),e),v={class:"page overlay_page login_page"},w={class:"container-fluid"},k={class:"row"},y={class:"col col-7 left"},$={class:"wrapper"},q=f((()=>l("h3",{class:"text_title_big_black mb-1 mt-sm-3 mb-sm-3 pt-0 ptm-sm-2"}," Accedi ",-1))),L=f((()=>l("div",{class:"line_black_separator mb-0 mb-sm-5"},null,-1))),x={class:"row mb-3 mb-sm-5"},A={class:"col col-12"},C=f((()=>l("label",{for:"email",class:"form-label"},"Email",-1))),E={class:"row mb-5"},I={class:"col col-12 position-relative"},S=f((()=>l("label",{for:"pwd",class:"form-label"},"Password",-1))),M=["type"],T={key:0,class:"bi bi-eye"},B={key:1,class:"bi bi-eye-slash"},H={class:"col col-12 forgot_password"},U=["innerHTML"],V=f((()=>l("div",{class:"or-divider mb-4"},[l("span",null,"oppure")],-1))),j=f((()=>l("img",{src:"https://static.affittochiaro.it/images/google.svg",alt:"Accedi con Google",style:{width:"24px","margin-right":"6px"}},null,-1))),z=f((()=>l("img",{src:"https://static.affittochiaro.it/images/facebook.svg",alt:"Accedi con Facebook",style:{width:"24px","margin-right":"6px"}},null,-1))),D={class:"mt-4 mb-5"},F=f((()=>l("p",{class:"back-home mb-3 hide-ts"},[l("a",{class:"btn white-btn mb-5",href:"/"},[l("i",{class:"bi bi-arrow-left me-2"}),u(" Torna alla Home")])],-1))),G=f((()=>l("div",{class:"col col-5 right"},[l("div",{class:"wrapper"},[l("h3",{class:"text_title_big_white"},"Affittochiaro.it")])],-1)));const P=e(_,[["render",function(e,t,s,o,p,b){const _=a("router-link");return r(),i("div",v,[l("div",w,[l("div",k,[l("div",y,[l("div",$,[q,L,l("div",x,[l("div",A,[C,c(l("input",{"onUpdate:modelValue":t[0]||(t[0]=e=>p.login_data.email=e),type:"email",class:"form-control",id:"email",placeholder:"[email protected]"},null,512),[[n,p.login_data.email]])])]),l("div",E,[l("div",I,[S,c(l("input",{"onUpdate:modelValue":t[1]||(t[1]=e=>p.login_data.password=e),type:p.show_password?"text":"password",class:"form-control",id:"pwd",placeholder:""},null,8,M),[[d,p.login_data.password]]),l("span",{class:"show_pwd",onClick:t[2]||(t[2]=e=>p.show_password=!p.show_password)},[p.show_password?(r(),i("i",B)):(r(),i("i",T))])]),l("div",H,[u(" Password dimenticata? "),m(_,{class:"green_link",to:{name:"password_recovery"}},{default:h((()=>[u("Recupera")])),_:1})])]),p.submitted&&!p.success?(r(),i("div",{key:0,class:"alert alert-danger",role:"alert",innerHTML:p.errorMsg},null,8,U)):g("",!0),l("button",{class:"btn green-btn mb-5",onClick:t[3]||(t[3]=(...e)=>b.doLogin&&b.doLogin(...e))}," Accedi "),V,l("a",{onClick:t[4]||(t[4]=e=>b.handleSocialLogin("google")),class:"btn btn-google mb-2",style:{cursor:"pointer"}},[j,u(" Continua con Google ")]),l("a",{onClick:t[5]||(t[5]=e=>b.handleSocialLogin("facebook")),class:"btn btn-google mb-2",style:{cursor:"pointer"}},[z,u(" Continua con Facebook ")]),l("p",D,[u(" Non hai ancora un account?     "),m(_,{class:"green_link",to:"/utente/signup"+(e.$route.query&&e.$route.query.redirect?"?redirect="+e.$route.query.redirect:"")},{default:h((()=>[u("Registrati ")])),_:1},8,["to"])]),F])]),G])])])}],["__scopeId","data-v-b711c6ec"]]);export{P as default};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.