PageSourceSearch

https://nhahang.ai/_next/static/chunks/pages/[tenant]/cai-dat/chi-nhanh-8bf54a29d3f54061.js

js nhahang.ai collected 2026-10-05 12:20:32 UTC 6,229 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[9414],{52074:function(e,a,n){(window.__NEXT_P=window.__NEXT_P||[]).push(["/[tenant]/cai-dat/chi-nhanh",function(){return n(7522)}])},3687:function(e,a,n){"use strict";n.d(a,{Z:function(){return E}});var t=n(85893),l=n(56023),c=n(33643),i=n(85524),s=n(93341),r=n(41739),d=n(47835),o=n(53367),h=n(87548),m=n(14711),u=n.n(m),x=n(78887),v=n(32856),b=n(9008),_=n.n(b),y=n(11163),f=n(67294),j=n(46607),p=n(37928),N=n(19506),S=n(39525),M=n(2566),g=n.n(M),C=e=>{let{buttonClassname:a,children:n}=e,[l,c]=(0,f.useState)(!1),{currentBranch:i,updateCurrentBranch:s,branchList:r}=(0,h.S)(),d=()=>c(!l);return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("div",{className:a,children:n?(0,t.jsx)("div",{onClick:d,children:n}):(0,t.jsx)(N.Z,{type:"text",onClick:d,icon:(0,t.jsx)(p.Z.Branch,{})})}),(0,t.jsx)(S.Z,{open:l,onClose:d,title:"Chọn chi nh\xe1nh",children:(0,t.jsx)("div",{className:g()["modal-branch-list"],children:null==r?void 0:r.map(e=>(0,t.jsxs)("div",{onClick:()=>{s(e),d()},className:(0,x.QH)(g()["modal-branch-item"],e.id===(null==i?void 0:i.id)&&g()["modal-branch-item-active"]),children:[(0,t.jsxs)("div",{className:"flex flex-col flex-1",children:[(0,t.jsx)("div",{className:g()["modal-branch-name"],children:e.name}),(0,t.jsx)("div",{className:g()["modal-branch-address"],children:(null==e?void 0:e.address)||"-"})]}),e.id===(null==i?void 0:i.id)&&(0,t.jsx)("div",{className:(0,x.QH)(e.id===(null==i?void 0:i.id)&&g()["modal-branch-dot-active"],g()["modal-branch-dot"]),children:(0,t.jsx)("div",{className:(0,x.QH)(e.id===(null==i?void 0:i.id)&&g()["modal-branch-dot-inner-active"],g()["modal-branch-dot-inner"])})})]},e.id))})})]})},w=n(37861),B=n(36764),Z=n(82433),k=n.n(Z),H=()=>{let e=(0,y.useRouter)(),{isMobile:a}=(0,w.a)(),{changeRoute:n}=(0,B.D)(),l=()=>{var a;let t=v.LC.find(a=>e.pathname.includes(a));n({path:t&&(null===(a=e.query)||void 0===a?void 0:a.id)?"cai-dat/".concat(t):"cai-dat/",isClearQuery:!!t})};return(0,t.jsxs)("div",{className:k()["setting-header"],children:[(0,t.jsxs)("div",{onClick:()=>l(),className:"flex gap-2",children:[(0,t.jsx)(p.Z.ArrowLeftPrimary,{className:"icon-gray"}),(0,t.jsx)("div",{children:"Quay lại"})]}),a&&!e.asPath.match("cai-dat/chi-nhanh")&&(0,t.jsx)(C,{})]})};function E(e){var a;let{children:n,ShowHeader:m=!1,IsManager:b=!0}
1=e,p=(0,y.useRouter)(),N=null==p?void 0:null===(a=p.query)||void 0===a?void 0:a.tenant,{account:S}=(0,o.c)(),M=(0,x.u8)();(0,s.l)({enabled:!(0,x._n)(),params:{root:"/".concat(N)}});let g=(0,r.H)(),C=(0,h.S)(e=>e.currentBranch),w=async()=>{if(!S||"/".concat(N)!==(null==S?void 0:S.Root)){p.push(v.P.login);return}};(0,f.useEffect)(()=>{p.isReady&&w()},[p,N,M,S]);let{setIsStore:B,isStore:Z}=(0,l.p)();(0,f.useEffect)(()=>{B(null)},[null==C?void 0:C.id]);let k=(0,c.B)(d.i.AllScreen,"".concat(d.i.AllScreen,"-").concat(null==C?void 0:C.id),!1);return g?(0,t.jsx)(i.Z,{}):(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)(_(),{children:[(0,t.jsx)("meta",{name:"apple-mobile-web-app-capable",content:"yes"}),(0,t.jsx)("meta",{name:"apple-mobile-web-app-status-bar-style",content:"black-translucent"}),(0,t.jsx)("meta",{name:"theme-color",content:"white"})]}),(0,t.jsxs)("div",{className:(0,x.QH)(u().className,"manager-layout"),children:[m&&(0,t.jsx)(t.Fragment,{children:(0,x._n)()?(0,t.jsx)(j.Z,{isSocketReady:k}):(0,t.jsx)(H,{})}),(0,t.jsx)("main",{className:"manager-layout-main",children:n})]})]})}},56023:function(e,a,n){"use strict";n.d(a,{p:function(){return l}});var t=n(1350);let l=(0,n(50161).F)()((0,t.d)(e=>({isStore:null,setIsStore:a=>e({isStore:a}),_hasHydrated:!1,setHasHydrated:a=>{e({_hasHydrated:a})}}),{name:"useMaterialLookupStore",onRehydrateStorage:e=>()=>e.setHasHydrated(!0)}))},72533:function(e,a,n){"use strict";var t=n(67294);a.Z=function(e,a){let[n,l]=(0,t.useState)(e);return(0,t.useEffect)(()=>{let n=setTimeout(()=>{l(e)},a);return()=>{clearTimeout(n)}},[e,a]),n}},7522:function(e,a,n){"use strict";n.r(a),n.d(a,{default:function(){return v}});var t=n(85893),l=n(3687),c=n(87548),i=n(80362),s=n(69216),r=n(96082),d=n(7610),o=n(53204),h=n(19506),m=n(34869),u=()=>{let{branchList:e,addOne:a}=(0,c.S)(),{showMessage:n}=(0,o.Z)(),{tenant:l}=(0,m.q)(),u=e=>{let a=document.getElementById(e);a&&a.click()},x=(0,r.D)({mutationKey:[d.Z.KeyCreate],mutationFn:async e=>d.Z.create(e),onSuccess:e=>(n({type:"success",content:"Tạo chi nh\xe1nh th\xe0nh c\xf4ng!"}),setTimeout(()=>{u(e.data.data.id)},700),e.data),onError:e=>n({type:"error",content:(null==e?void 0:e.message)||(null==e?void 0:e.Message)})}),v=async()=>{a((await x.mutateAsync({name:"Chi nh\xe1nh mới",phone:(null==l?void 0:l.phone)||""})).data.data)};return(0,t.jsxs)("div",{className:"flex flex-col gap-2 p-3 h-full overflow-auto",children:[(0,t.jsx)(s.Z,{}),(0,t.jsxs)("div",{className:"flex flex-col gap-2",children:[(0,t.jsxs)("div",{className:"py-3 flex justify-between items-center",children:[(0,t.jsx)("div",{className:"text-[14px]",children:"Danh s\xe1ch chi nh\xe1nh"}),(0,t.jsx)(h.Z,{type:"text",size:"small",className:"text-brand-600",onClick:v,children:"+ Th\xeam chi nh\xe1nh"})]}),null==e?void 0:e.map(e=>(0,t.jsx)(i.Z,{item:e},e.id))]})]})},x=()=>(0,t.jsx)(u,{});function v(){return(0,t.jsx)(x,{})}v.Layout=l.Z,v.Title="C\xe0i đặt chi nh\xe1nh",v.ShowHeader=!0,v.DisableClarity=!0},2566:function(e){e.exports={"modal-branch-list":"MySelectBranchMobile_modal-branch-list__BTJq1","modal-branch-item":"MySelectBranchMobile_modal-branch-item__Ed4Af","modal-branch-item-active":"MySelectBranchMobile_modal-branch-item-active__Gmm4M","modal-branch-name":"MySelectBranchMobile_modal-branch-name__ct26B","modal-branch-address":"MySelectBranchMobile_modal-branch-address__LXQ4D","modal-branch-dot":"MySelectBranchMobile_modal-branch-dot__ttSHb","modal-branch-dot-active":"MySelectBranchMobile_modal-branch-dot-active__otNw3","modal-branch-dot-inner":"MySelectBranchMobile_modal-branch-dot-inner__Cyk92","modal-branch-dot-inner-active":"MySelectBranchMobile_modal-branch-dot-inner-active___WyJt"}},82433:function(e){e.exports={"setting-header":"Header_setting-header__4QiNt"}}},function(e){e.O(0,[16876,88265,15434,29694,96917,71736,49774,92888,40179],function(){return e(e.s=52074)}),_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.