1"use strict";(self["webpackChunkclient"]=self["webpackChunkclient"]||[]).push([[109],{80109:function(t,n,s){s.r(n),s.d(n,{default:function(){return v}});var e=s(20641),l=s(90033);const a={class:"o-minwidth"},o={class:"is-flex mb-5"},u={class:"title"};function c(t,n,s,c,i,r){const d=(0,e.g2)("Form");return(0,e.uX)(),(0,e.CE)("section",a,[(0,e.Lk)("div",o,[(0,e.Lk)("a",{class:"button is-rounded is-light is-small",onClick:n[0]||(n[0]=n=>t.$router.go(-1))}," â "+(0,l.v_)(t.$t("back")),1)]),(0,e.Lk)("h2",u,(0,l.v_)(t.$t("add"))+" "+(0,l.v_)(t.$t("Contact")),1),n[2]||(n[2]=(0,e.Lk)("hr",null,null,-1)),(0,e.bF)(d,{save:r.save,item:i.item},null,8,["save","item"]),(0,e.Lk)("button",{class:(0,l.C4)(["button is-primary is-rounded mt-5",{"is-loading":t.$store.state.isLoadingButton}]),onClick:n[1]||(n[1]=(...t)=>r.save&&r.save(...t))},(0,l.v_)(t.$t("save")),3)])}s(44114);var i=s(31830),r=s(40834),d={data(){return{item:{name:null,email:null,phone:null,town:null,country:null,status:null}}},created(){},methods:{save(){let t={...this.item};t.country=t.town?.country["@id"]?t.town.country["@id"]:null,t.town=t.town?t.town["@id"]:null,t.status=t.status?t.status["@id"]:null,t.localCenter=t.localCenter?t.localCenter["@id"]||`/api/v1/local_centers/${t.localCenter.id}`:null,this.$http.plain.post("/contacts",t).then(t=>this.saveSuccess(t)).catch(t=>console.error(t))},saveSuccess(t){this.$buefy.snackbar.open({message:this.$t("createdSuccessfully")}),this.$router.push({name:"ContactList"})}},computed:{...(0,r.L8)(["tenant","user","isGranted"])},components:{Form:i.A}},h=s(66262);const m=(0,h.A)(d,[["render",c]]);var v=m}}]);
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.