PageSourceSearch

https://visitbursa.org/_next/static/chunks/pages/hesap/rotalarim/[id]-8e175bee6fe22851.js

js visitbursa.org collected 2026-10-09 05:07:51 UTC 5,603 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[507],{8219:function(e,l,a){(window.__NEXT_P=window.__NEXT_P||[]).push(["/hesap/rotalarim/[id]",function(){return a(8995)}])},2736:function(e,l,a){"use strict";var t=a(7294);let s=e=>{let[l,a]=(0,t.useState)(e),s=e=>{a(l=>({...l,[e]:!0}))},n=e=>{a(l=>({...l,[e]:!1}))};return{modal:l,handleOpen:s,handleClose:n}};l.Z=s},8995:function(e,l,a){"use strict";a.r(l),a.d(l,{__N_SSP:function(){return S}});var t=a(5893),s=a(7887),n=a(319),i=a(9834),d=a(579),o=a(2615),r=a(4491),c=a(61),u=a(7248),m=a(2545),x=a(8377),h=a(8089),p=a(6162),v=a(2736),j=a(3293),b=a(9573),f=a(9527),g=a.n(f),N=a(1664),k=a.n(N),w=a(1163),y=a(7294),_=a(5948);let P=()=>{var e;let l=(0,w.useRouter)(),{id:a}=l.query,{t:f}=(0,b.$G)("common"),[N,P]=(0,y.useState)(null),[S,M]=(0,y.useState)(null),{handleClose:C,handleOpen:E,modal:I}=(0,v.Z)({createModal:!1,deleteModal:!1}),[R,D]=(0,y.useState)(),{data:A,loading:O,refetch:T}=(0,s.a)(x.Is,{variables:{client_route_id:a},skip:!a}),[V]=(0,n.D)(m.js),[z]=(0,n.D)(m.wO),J=(0,u.c)({initialValues:{name:null,about:null}}),L=J.onSubmit(async e=>{M(!0);try{var a,t,s;let n=await V({variables:{input:{name:null==e?void 0:e.name,about:null==e?void 0:e.about,id:null==l?void 0:null===(a=l.query)||void 0===a?void 0:a.id}}});(null===(t=n.data)||void 0===t?void 0:null===(s=t.updateClientRoute)||void 0===s?void 0:s.status)==200&&(C("createModal"),T())}catch(e){console.error(e)}finally{M(!1)}}),[Z,{loading:q}]=(0,n.D)(m.xc),F=async()=>{try{await Z({variables:{input:{item_id:null==N?void 0:N.id}}}),C("deleteModal"),P(null),await T()}catch(e){console.error(e)}},H=async e=>{if(!e.destination)return;let l=Array.from(R),[a]=l.splice(e.source.index,1);l.splice(e.destination.index,0,a);let t=null==l?void 0:l.map((e,l)=>({id:null==e?void 0:e.id,order:l}));D(l);try{await z({variables:{input:{detail_json:JSON.stringify(t)}}}),await T()}catch(e){console.error(e)}},X=null==A?void 0:A.getClientRouteDetail;return(0,y.useEffect)(()=>{D((null==X?void 0:X.places)||[])},[X]),(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(g(),{children:(0,t.jsx)("title",{children:"Bursa - ".concat(null==X?void 0:X.name)})}),(0,t.jsxs)("div",{className:"",children:[(0,t.jsx)("div",{className:"mb-4",children:(0,t.jsx)(h.u5,{className:"!w-fit default-button !h-10",component:k(),href:"/hesap/rotalarim",leftIcon:(0,t.jsx)(j.Hg,{}),variant:"default",children:(0,t.jsxs)("span",{className:"text-black",children:[" ",f("geri-gel")]})})}),X&&(0,t.jsxs)("div",{className:"flex gap-4 items-center pb-4 border-b mb-4",children:[(0,t.jsx)("h2",{className:"font-semibold  text-lg sm:text-xl lg:text-2xl",children:null==X?void 0:X.name}),(0,t.jsx)(i.A,{className:" hover:bg-gray-100",onClick:()=>{E("createModal"),J.setValues({name:null==X?void 0:X.name,about:null==X?void 0:X.about})},children:(0,t.jsx)(j.$U,{className:"w-3 h-3"})})]}),(0,t.jsxs)(d.m,{classNames:{tabLabel:"!font-semibold"},defaultValue:"rota",children:[(0,t.jsxs)(d.m.List,{children:[(0,t.jsx)(d.m.Tab,{value:"rota",children:f("rota")}),(0,t.jsx)(d.m.Tab,{value:"hakkında",children:(0,t.jsx)("span",{onClick:()=>J.setValues({name:null==X?void 0:X.name,about:null==X?void 0:X.about}),children:f("hakkında")})})]}),(0,t.jsxs)(d.m.Panel,{value:"rota",pt:"xs",children:[!!R&&(null==R?void 0:R.length)>0&&(0,t.jsx)(_.Z5,{onDragEnd:H,children:(0,t.jsx)(_.bK,{droppableId:"places",children:e=>(0,t.jsx)("div",{...e.droppableProps,ref:e.innerRef,className:"mt-4 flex flex-col gap-3 w-full",children:null==R?void 0:R.map((e,l)=>(0,t.jsx)(_._l,{draggableId:e.id.toString(),index:l,children:l=>(0,t.jsxs)("div",{ref:l.innerRef,...l.draggableProps,className:"flex justify-between gap-2 items-center p-2 rounded-xl border w-full bg-white shadow-sm",children:[(0,t.jsx)("div",{...l.dragHandleProps,className:"cursor-pointer",children:(0,t.jsx)(j.JF,{})}),(0,t.jsx)("img",{className:"w-12 h-12 rounded-full mr-2",src:"".concat("https://belediye-assets.s3.eu-central-1.amazonaws.com/public/").concat(e.image),alt:e.title}),(0,t.jsx)("div",{className:"w-full font-medium",children:(0,t.jsx)(k(),{href:"/mekanlar/"+e.seolink,children:e.title})}),(0,t.jsx)(i.A,{onClick:()=>{E("deleteModal"),P(e)},children:(0,t.jsx)(j.Ji,{})})]})},e.id))})})}),!O&&((null===(e=X.places)||void 0===e?void 0:e.length)==0||!X.places)&&(0,t.jsx)("div",{children:(0,t.jsx)("p",{className:"text-sm text-center py-10",children:f("empty-rota-detail")})}),O&&(0,t.jsx)("div",{className:"my-12",children:(0,t.jsx)(h.gb,{})})]}),(0,t.jsx)(d.m.Panel,{value:"hakkında",pt:"xs",children:(0,t.jsx)("form",{onSubmit:L,children:(0,t.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,t.jsx)(o.g,{...J.getIn
1putProps("about"),autosize:!0,maxRows:6,minRows:3}),(0,t.jsx)(h.u5,{type:"submit",className:"!h-10 !w-fit",loading:S,children:f("kaydet")})]})})})]})]}),(0,t.jsx)(r.u,{centered:!0,opened:I.createModal,onClose:()=>{C("createModal")},title:f("rotayı-duzenle"),children:(0,t.jsx)("form",{onSubmit:L,children:(0,t.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,t.jsx)(c.o,{...J.getInputProps("name"),"data-autofocus":!0,label:f("rota-adı"),placeholder:f("rota-adı")}),(0,t.jsx)(c.o,{...J.getInputProps("about"),label:f("rota")+" "+f("hakkında"),placeholder:f("rota")+f("hakkında")}),(0,t.jsx)(h.u5,{type:"submit",className:"!h-10",loading:S,children:f("kaydet")})]})})}),(0,t.jsx)(p.eS,{text:f("mekan-sil"),loading:q,opened:I.deleteModal,close:()=>C("deleteModal"),confirmCheckbox:F})]})};var S=!0;l.default=P,P.layout="L4",P.isAuthProtected=!0}},function(e){e.O(0,[630,997,774,888,179],function(){return e(e.s=8219)}),_N_E=e.O()}]);

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.