import{_ as h}from"./NoDataFound-BCWTwO3P.js";import{d as b,s as f,k,q as g,m as y,r as v,c as o,o as n,a as t,b as i,e as w,t as s,F as c,g as N,u as C}from"./app-Do7K7VDV.js";import{_ as A}from"./UserLayout-B1erUghk.js";import{_ as B}from"./Paginate-BZTS8QtF.js";import"./AssetModal-C18ToIEK.js";import"./_plugin-vue_export-helper-DlAUqK2U.js";import"./InputFieldError-0BmYlL24.js";import"./ToastrContainer-CtYDvNPN.js";const $={class:"table-responsive mt-6 w-full"},j={class:"table"},D={class:"whitespace-nowrap"},F={class:"!text-right"},I={key:0,class:"tbody"},R={class:"capitalize"},S={class:"!text-right"},T=["onClick"],V=b({layout:A}),K=Object.assign(V,{__name:"Show",props:["record","scraped_data"],setup(r){const{deleteRow:u}=f(),_=r,l=k([]);g(()=>{l.value=_.scraped_data.data.map(a=>({id:a.id,...a.data}))});const d=y(()=>l.value);return(a,q)=>{const m=v("Icon");return n(),o(c,null,[t("div",$,[t("table",j,[t("thead",null,[t("tr",null,[t("th",null,s(a.trans("Name")),1),t("th",D,s(a.trans("Phone Number")),1),t("th",null,s(a.trans("Address")),1),t("th",null,s(a.trans("Rating")),1),t("th",null,s(a.trans("Types")),1),t("th",F,s(a.trans("Action")),1)])]),d.value.length?(n(),o("tbody",I,[(n(!0),o(c,null,N(d.value,(e,p)=>(n(),o("tr",{key:p},[t("td",null,s(e.name),1),t("td",null,[t("span",null,s(e.phone_number||"N/A"),1)]),t("td",null,s(e.formatted_address),1),t("td",null,s(e.rating||"N/A"),1),t("td",R,s(e.types.join(", ")),1),t("td",S,[t("button",{class:"btn btn-danger btn-sm",onClick:z=>C(u)(a.route("admin.web-scraping.destroy_data",e.id))},[i(m,{icon:"bx:trash"})],8,T)])]))),128))])):(n(),w(h,{key:1,forTable:!0}))])]),i(B,{links:r.scraped_data.links},null,8,["links"])],64)}}});export{K as default};
