1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7715],{7715:function(e,t,n){n.r(t),n.d(t,{default:function(){return m}});var i=n(57437),o=n(62069),a=n(30166),l=n(99376);const r=(0,a.default)((()=>Promise.all([n.e(89051),n.e(2549),n.e(69958),n.e(73261),n.e(93756),n.e(24070),n.e(42928),n.e(18610),n.e(82734),n.e(72291),n.e(25948),n.e(46407),n.e(58218),n.e(92663)]).then(n.bind(n,21134))),{loadableGenerated:{webpack:()=>[21134]}}),s=(0,a.default)((()=>Promise.all([n.e(20270),n.e(89051),n.e(24560),n.e(2549),n.e(36476),n.e(69958),n.e(44866),n.e(61720),n.e(87538),n.e(73261),n.e(93756),n.e(24070),n.e(42928),n.e(18610),n.e(82734),n.e(72291),n.e(25948),n.e(82264),n.e(48846),n.e(46407),n.e(58218),n.e(51702),n.e(53418)]).then(n.bind(n,4568))),{loadableGenerated:{webpack:()=>[4568]}}),d=(0,a.default)((()=>Promise.all([n.e(20270),n.e(89051),n.e(24560),n.e(2549),n.e(36476),n.e(69958),n.e(44866),n.e(61720),n.e(87538),n.e(73261),n.e(93756),n.e(24070),n.e(42928),n.e(18610),n.e(35321),n.e(82734),n.e(72291),n.e(82264),n.e(48846),n.e(46407),n.e(27113),n.e(58218),n.e(51702),n.e(65134)]).then(n.bind(n,72723))),{loadableGenerated:{webpack:()=>[72723]}});var c=()=>{const e=((0,l.useSearchParams)()||new URLSearchParams).get("meetingType");return"table"===e?(0,i.jsx)(r,{}):"newRegular"===e?(0,i.jsx)(d,{}):(0,i.jsx)(s,{})},u=n(14546);var m=()=>(0,i.jsx)(o.ZP,{item:!0,xs:12,children:(0,i.jsx)(u.bt,{children:(0,i.jsx)(c,{})})})},14546:function(e,t,n){n.d(t,{bt:function(){return F},SN:function(){return I}});var i=n(57437),o=n(2265),a=n(55788),l=n(99376),r=n(74663),s=n(29501),d=n(48236),c=n(21015),u=n(54656),m=n(14069),v=n(6551);const g=e=>({...e,title:e.name}),h=e=>{var t;return{...e,name:(null===(t=e.title)||void 0===t?void 0:t.replace(new RegExp("\\.".concat(e.format,"$"),"i"),""))||"",format:(0,v.BW)(e.title),image:(null===e||void 0===e?void 0:e.thumbnail)||(0,v.bj)(e.url,e.title||e.format)}},p=e=>"fulfilled"===e.status&&Array.isArray(e.value)?e.value:[],f=e=>{let{type:t,id:n,stopRequest:i}=e;return i||!n?Promise.resolve(null):(0,d.k_)("".concat((0,r.t)(),"/api/v1/exhibitors/").concat(t),{body:{id:n},hideError:!0,skipAuthRedirect:!0}).then((e=>{var t;return 200===(null===e||void 0===e?void 0:e.code)&&Array.isArray(null===(t=e.data)||void 0===t?void 0:t.list)?e.data.list:null}))};var _=()=>{var e;const{hiddenSections:t={}}=(0,m.CGy)(m.$h1),n=!!(null===t||void 0===t||null===(e=t.permissions)||void 0===e?void 0:e.marketing_content),[i,a]=(0,u.Z)(["content_fr","products_ex_fr"]);return(0,o.useCallback)(((e,t)=>{const o=[f({type:"products",id:e,stopRequest:!a}),f({type:"products",id:t,stopRequest:!a}),f({type:"content",id:e,stopRequest:!i||n}),f({type:"content",id:t,stopRequest:!i||n})];return Promise.allSettled(o).then((e=>{const t=p(e[0]),n=p(e[1]),i=p(e[2]),o=p(e[3]);return{productsTo:t.map(g),productsFrom:n.map(g),contentTo:i.map(h),contentFrom:o.map(h)}}))}),[i,n,a])},b=n(29943),y=n(35770),k=n(7220),w=n(66062),T=n(60891),A=n(94544);const P=new Map,x=(0,o.createContext)({}),I=()=>(0,o.useContext)(x),F=e=>{let{children:t}=e;const n=(0,l.useSearchParams)()||new URLSearchParams,u=n.get("ownerType"),m=Boolean(n.get("isReschedule")),g=n.get("id"),h="table"!==n.get("meetingType"),{t:p}=(0,a.$G)(),{showErrorMessage:f}=(0,k.Z)(),{moveToMainPage:I}=(0,b.Z)(),[F,C]=(0,o.useState)(!1),[E,M]=(0,o.useState)(!1),[R,S]=(0,o.useState)(!1),[L,N]=(0,o.useState)(!1),O=(0,s.cI)({defaultValues:w.sc}),{to:D,settings:q,productsFrom:V=[],productsTo:G=[],contentFrom:j=[],contentTo:U=[]}=O.getValues(),Z="online"===(0,s.qo)({control:O.control,name:"location"}),B=(0,o.useMemo)((()=>"meeting"===u?"id":u&&["product","exhibitor"].includes(u)?"".concat(u,"ID"):"accountID"),[u]),Y=(0,o.useMemo)((()=>{const{id:e,firstName:t,lastName:n,photoURL:i}=(null===D||void 0===D?void 0:D.account)||{},o=(0,c.q)(i,150,150);return{id:Number(e),name:(0,v.NG)([t,n]),photo:o,avatar:o}}),[D]),K=_();(0,o.useEffect)((()=>{if(!g)return;let e;return C(!0),(0,T.m6)({[B]:Number(g),isRegular:h}).then((e=>(0,y.gd)({...e,toType:B,t:p}))).then((e=>K(e.toExhibitorsId,e.fromExhibitorsId).then((t=>{O.reset({...e,...t})}
1)))).catch((t=>{f(p(t.message)),e=setTimeout(I,1500)})).finally((()=>{C(!1),M(!0)})),()=>{clearTimeout(e)}}),[K,O,I,g,h,C,M,f,p,B]);const $=(0,o.useCallback)((()=>(0,T.QP)(O.getValues("toParticipants").filter((e=>e!==w.FS)),O.getValues("delegatesEmail")).then((e=>{O.setValue("delegates",[...O.getValues("delegates"),...e]),O.setValue("delegatesEmail","")})).catch((e=>{f(p(e.message))}))),[O,f,p]),H=(0,o.useCallback)(((e,t)=>{const n=O.getValues("mediaFiles")||[],i={apiUrl:(0,r.t)()||"",files:n,addId:!0,id:e,title:null===t||void 0===t?void 0:t.title};(0,d.IL)(i).then((e=>{e.length&&O.setValue("mediaFiles",[{...null===n||void 0===n?void 0:n[0],name:null===t||void 0===t?void 0:t.title}])})).catch((e=>{f(p(e.message))}))}),[O,f,p]),z=(null===q||void 0===q?void 0:q.returnUrl)||"meeting_initiation",X=(0,A.Z)({returnPage:z,isReschedule:m}),Q=(0,o.useCallback)((e=>{var t,n;const i={start:e.start,end:e.end?e.end-((null===q||void 0===q?void 0:q.pause)||0):0,duration:e.duration,location:e.location,..."other"===e.location&&e.otherLocation&&{otherLocation:e.otherLocation},title:e.subject,description:e.message,...e.note&&{note:e.note},...e.meetingId&&{id:e.meetingId},...e.fromExhibitorsId&&{accountID:e.fromExhibitorsId},additionalContacts:e.delegates.mapByProperty("id"),fromContacts:e.members,...e.checkedProducts.length&&{products:e.checkedProducts},...e.checkedContent.length&&{content:{media:e.checkedContent}},...(null===q||void 0===q||null===(t=q.tags)||void 0===t?void 0:t.length)&&{tags:e.checkedTags},statistics:{...e.fromExhibitorsId&&{from:e.fromExhibitorsId},...g&&{to:+g}},...(null===(n=e.mediaFiles)||void 0===n?void 0:n.length)&&e.mediaFiles.length>0&&{mediaIds:e.mediaFiles.mapByProperty("id")},...(0,y.M7)(e.toParticipants,Y.id)};C(!0),X(i).finally((()=>{C(!1)}))}),[null===q||void 0===q?void 0:q.pause,null===q||void 0===q?void 0:q.tags,g,Y.id,X]);var W;const J=null!==(W=null===q||void 0===q?void 0:q.canAddMediaFile)&&void 0!==W&&W,ee=((null===G||void 0===G?void 0:G.length)||0)+((null===V||void 0===V?void 0:V.length)||0)>0&&Z,te=((null===U||void 0===U?void 0:U.length)||0)+((null===j||void 0===j?void 0:j.length)||0)>0&&Z,ne=(0,o.useCallback)((()=>{O.setValue("start",null),O.setValue("end",null)}),[O]),ie=(0,o.useCallback)((()=>{f(p("profile_meeting_request.meeting_request_context.please_select_other_time_for_this"))}),[]),oe=(0,o.useCallback)(((e,t)=>{const n="".concat(e,"-").concat(t),i=P.get(n);if(i)return void("unavailable"===i&&ie());const o={exhibitorId:O.getValues("toExhibitorsId"),start:e,end:t};N(!0),(0,d.k_)("".concat((0,r.t)(),"/api/v1/schedule/checkAvailableTeamMember"),{body:o}).then((e=>{var t;const i=Boolean(null===e||void 0===e||null===(t=e.data)||void 0===t?void 0:t.success);200===(null===e||void 0===e?void 0:e.code)&&i||ie(),S(i),P.set(n,i?"available":"unavailable")})).finally((()=>{N(!1)}))}),[O,ie]),ae=(0,o.useCallback)((function(e){let t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];const n=e+60*O.getValues("duration");O.setValue("start",e),O.setValue("end",n),t?S(!0):O.getValues("toParticipants").includes(w.FS)&&e&&n&&oe(e,n)}),[oe,O]),le=(0,o.useMemo)((()=>({toAccount:Y,isReschedule:m,switchActiveCells:ae,toType:B,setIsFetching:C,returnPage:z,resetTime:ne,handleFindDelegates:$,saveFiles:H,isMediaAllowed:J,handleSave:Q,showProductStep:ee,showContentStep:te,isFetching:F,isInitiated:E,isFetchingAnyAvailability:L,isTimeAvailableForAny:R,isMeetingOnline:Z})),[Y,m,ae,B,C,z,ne,$,H,J,Q,ee,te,F,E,L,R,Z]);return(0,i.jsx)(s.RV,{...O,children:(0,i.jsx)(x.Provider,{value:le,children:t})})}},66062:function(e,t,n){n.d(t,{FS:function(){return o},KI:function(){return c},PM:function(){return r},Zx:function(){return u},br:function(){return a},en:function(){return d},ig:function(){return s},k:function(){return l},sc:function(){return v}});var i=n(49329);const o="any-available-member",a="profile_meeting_request.meeting_steps.meeting_details",l="profile_meeting_request.meeting_steps.please_provide_the_meeting_details",r="profile_meeting_request.regular_meeting_wrapper.date_time",s="profile_meeting_request.regular_meeting_wrapper.select_an_available_date_and",d="profile_meeting_request.meeting_steps.table",c="profile_meeting_request.meeting_steps.select_table_to_request_a";var u;!function(e){e.GENERAL_FORM="general-form",e.PRODUCTS_FORM="products-form",e.MARKETING_CONTENT_FORM="marketing-content-form",e.CALENDAR_FORM="calendar-form",e.TABLE_FORM="table-form"}(u||(u={}));const m=()=>{},v={members:[],toParticipants:[],checkedTags:[],duration:15,settings:{},delegates:[],additional:[],from:{},meeting:{},to:{}
1,subject:"",message:"",note:"",start:null,end:null,selectedDay:(0,i.xz)((new Date).getTime(),"YYYY-MM-DD"),isFetchingAnyAvailability:!1,isTimeAvailableForAny:!1,isFetching:!1,isInitiated:!1,meetingId:null,fromOptions:[],toOptions:[],selectedToAccounts:[],mediaFiles:[],checkedContent:[],checkedProducts:[],tags:[],locationOptions:[],otherLocationOptions:[],location:"",otherLocation:"",delegatesEmail:"",checkedTable:null,checkedZone:null,toExhibitorsId:null,fromExhibitorsId:null,productsTo:[],productsFrom:[],contentTo:[],contentFrom:[],durationOptions:[{value:15,text:"15 min"}],toType:"accountID",isReschedule:!1,canConfirmOnlineMeeting:!1,canConfirmOfflineMeeting:!1,canCreateMeeting:!1,handleFindDelegates:m,saveFiles:m,isMediaAllowed:!1,handleSave:m,showProductStep:!1,showContentStep:!1,switchActiveCells:m,returnPage:"meeting_initiation",toContacts:{toAnyone:!1,toContacts:[]},resetTime:m,toAccount:{},setIsFetching:m,isMeetingOnline:!1}},60891:function(e,t,n){n.d(t,{QP:function(){return u},X7:function(){return c},_x:function(){return s},m6:function(){return r},uK:function(){return d}});var i=n(43974),o=n(48236),a=n(74663),l=n(35770);const r=e=>(0,o.k_)("".concat((0,a.t)(),"/api/v1/schedule/info"),{body:e}).then((e=>{if(200!==(null===e||void 0===e?void 0:e.code)||!(0,i.K)(e.data))throw new Error("Invalid schedule info response");return e.data})),s=e=>(0,o.k_)("".concat((0,a.t)(),"/api/v1/schedule/quickInfo"),{body:e}).then((e=>{if(200!==(null===e||void 0===e?void 0:e.code)||!(0,i.K)(e.data))throw new Error("Invalid quick schedule info response");return e.data})),d=e=>(0,o.k_)("".concat((0,a.t)(),"/api/v1/schedule/busyTimes"),{body:e}).then((e=>{if(200!==(null===e||void 0===e?void 0:e.code)||!Array.isArray(e.data))throw new Error("Invalid busy times response");return e.data})),c=e=>(0,o.k_)("".concat((0,a.t)(),"/api/v1/schedule/checkTimes"),{body:e}).then((e=>{var t;if(200!==(null===e||void 0===e?void 0:e.code)||!(0,i.K)(null===(t=e.data)||void 0===t?void 0:t.list))throw new Error("Invalid calendar times response");const{available_times:n,default_options:{time_step:o}={},all_times:a}=e.data.list;return{all:a||{},available:n,timeStep:o}})),u=(e,t)=>(0,o.k_)("".concat((0,a.t)(),"/api/v1/schedule/find"),{body:{toIds:e,email:t}}).then((e=>{if(!(0,i.K)(null===e||void 0===e?void 0:e.data)||200!==e.code)throw new Error("error.something_went_wrong");var t;if(!e.data.success)throw new Error(null!==(t=e.data.message)&&void 0!==t?t:"profile_meeting_request.fetch_meeting_info.not_found_delegates");return(0,l.Bh)(e.data.suggestions||[])}))},35770:function(e,t,n){n.d(t,{Bh:function(){return d},IM:function(){return m},M7:function(){return h},gd:function(){return g}});var i=n(49329),o=n(6551),a=n(66062);const l=e=>{var t,n;const{from:i,meeting:o}=e,a=(null===(t=e.from)||void 0===t?void 0:t.contacts)||[];let l=[];const r=1===o.from.length&&!a.some((e=>{let{id:t}=e;return t===o.from[0].id}));return(null===o||void 0===o||null===(n=o.from)||void 0===n?void 0:n.length)&&!r?l=o.from:1===a.length?l=a:a.length&&!i.isTeamMember||!(null===i||void 0===i?void 0:i.account)||(l=[i.account]),Array.isArray(l)?l.mapByProperty("id"):[]},r=e=>{var t;const{to:n,meeting:i}=e,o=(null===n||void 0===n?void 0:n.contacts)||[];let l=[];return(null===i||void 0===i||null===(t=i.to)||void 0===t?void 0:t.length)?l=i.to:o.length&&!(null===n||void 0===n?void 0:n.isTeamMember)||!(null===n||void 0===n?void 0:n.account)?(null===n||void 0===n?void 0:n.isExhibitorOwner)&&o.length>1?l=[{id:a.FS}]:o.length&&"accountID"!==e.toType?l=o.length>1?[]:o:o.length&&(l=o.length>1?[null===n||void 0===n?void 0:n.account]:o):l=[n.account],Array.isArray(l)?l.mapByProperty("id"):[]},s=e=>{var t,n;const{settings:i,meeting:o}=e;return(null===i||void 0===i||null===(t=i.tags)||void 0===t?void 0:t.length)&&(null===o||void 0===o||null===(n=o.tags)||void 0===n?void 0:n.length)?o.tags.mapByProperty("id"):[]},d=e=>Array.isArray(e)?e.map((e=>({...e,name:(0,o.NG)([e.firstName,e.lastName]),photo:e.photoURL||""}))):[],c=(e,t)=>{var n;return!Array.isArray(e)||e.length<1?t?[{id:null!==(n=t.id)&&void 0!==n?n:"",name:t.displayName||(0,o.NG)([t.firstName,t.lastName])||t.company_name||"",subtitle:t.position||"",avatar:t.photoURL}]:[]:e.map((e=>({id:e.id,name:(0,o.NG)([e.firstName,e.lastName])||t.company_name||"",subtitle:e.position||"",avatar:e.photoURL})))},u=e=>{var t;const n=e.locationsList.find((e=>{let{value:t}=e;return"number"===typeof t||"exhibitor_stand"===t}));if(n&&!e.meeting.id)return n.value;const i=null===(t=e.meeting)||void 0===t?void 0:t.location;return i?Number.isFinite(+i)?+i:i:""}
1,m=(e,t,n)=>(null===e||void 0===e?void 0:e.length)>0?e.map((e=>({value:e,text:n("profile_meeting_request.prepare_data.time_min",{time:e})}))):[{value:t,text:n("profile_meeting_request.prepare_data.time_min",{time:t})}],v=e=>{var t;return e.isTeamMember||e.isExhibitorOwner?null===e||void 0===e||null===(t=e.account)||void 0===t?void 0:t.exhibitor_id:null},g=e=>{var t,n,a;const g=(e=>{var t;const{settings:n}=e;return(null===n||void 0===n?void 0:n.selectedAppointmentLength)>0?n.selectedAppointmentLength:(null===n||void 0===n||null===(t=n.appointmentLengths)||void 0===t?void 0:t[0])||0})(e);return{...e,members:l(e),toParticipants:r(e),checkedTags:s(e),duration:g,settings:(p=e.settings,{...p,pause:p.pause_after_meeting||0,displayDayOfWeek:p.session_display_day_of_week,allTimes:p.all_times||{},meetingTimeStep:60*Number(p.meetingTimeStep)}),delegates:d(e.meeting.additional),subject:e.meeting.title||"",message:e.meeting.description||"",note:e.meeting.note||"",start:e.meeting.start||null,end:e.meeting.end||null,durationOptions:m(e.settings.appointmentLengths,g,e.t),fromOptions:c(e.from.contacts,e.from.account),toOptions:(h=e.to.contacts,Array.isArray(h)?h.map((e=>{var t;return{id:e.id,name:(0,o.NG)([e.firstName,e.lastName,e.company_name]),photo:e.photoURL,avatar:e.photoURL,subtitle:e.position||"",disabled:null!==(t=e.disabled)&&void 0!==t&&t}})):[]),selectedDay:e.meeting.start?(0,i.xz)(e.meeting.start,"YYYY-MM-DD"):(0,i.xz)((new Date).getTime(),"YYYY-MM-DD"),meetingId:e.meeting.id||null,locationOptions:e.locationsList,checkedProducts:e.selectedProducts||[],tags:e.settings.tags||[],checkedContent:e.selectedContent||[],otherLocationOptions:e.locationsListOther||[],location:u(e),otherLocation:e.meeting.otherLocation||"",...!e.meeting.location&&1===e.locationsList.length&&{location:e.locationsList[0].value},...(null===(t=e.settings)||void 0===t?void 0:t.canAddMediaFile)&&(null===(a=e.meeting)||void 0===a||null===(n=a.media)||void 0===n?void 0:n.length)&&{mediaFiles:e.meeting.media||[]},checkedTable:e.meeting.table_id||null,checkedZone:e.meeting.zone_id||null,toExhibitorsId:v(e.to),fromExhibitorsId:v(e.from)};var h,p},h=(e,t)=>e.includes(a.FS)?{toAnyone:!0,toContacts:[t]}:{toContacts:e}},94544:function(e,t,n){var i=n(99376),o=n(97910),a=n(55788),l=n(6551),r=n(48236),s=n(68167),d=n(49329),c=n(55595),u=n(61081),m=n(47807),v=n(23307),g=n(7220),h=n(14069),p=n(93223),f=n(74663);const _={exhibitor:u.rH.Exhibitor,product:u.rH.Product};t.Z=e=>{let{returnPage:t,isReschedule:n}=e;const b=(0,o.t)(),y=(0,i.useSearchParams)()||new URLSearchParams,k=y.get("location")||"",w=y.get("ownerType")||"",T=y.get("id")||"",{t:A}=(0,a.$G)(),P=(0,h.TL5)(),{showSuccessMessage:x}=(0,g.Z)(),I=(0,h.CGy)(h.RT$),F=(0,h.CGy)(h.OfE),C=(0,h.CGy)(h.zH$),E=c.Z.getPrevUrl(),M="meeting_initiation"===t,R={location:k,ownerType:w,id:T},S=(0,m.Z)({isUseFunction:!0}),L=(0,v.Z)(n?{}:R);return e=>(0,r.k_)("".concat((0,f.t)(),"/api/v1/schedule/save"),{body:e}).then((e=>{if(200!==(null===e||void 0===e?void 0:e.code)||!(0,l.Kn)(e.data))return;const{id:i,start:o}=e.data,a=_[w]||u.rH.Account,r={action:n?u.eX.Reschedule:u.eX.Create,objectId:+i,objectType:u.rH.Meeting,...!n&&{...T&&{additionalId:+T},additionalType:a}};S.handleSetStatistics(r,L),x(A("profile_meeting_request.use_meeting_request_save_handler.success"));const c=(0,d.hB)(o,C);n&&P((0,p.$V)(i,!0)),P((0,p.GH)({newScheduleDate:c,data:e.data}));const m={showRecommendationsPopup:F};if(M){if(!E)return void b.push("/profile/meetings");const[e,t]=E.replace((0,s.b)(),"").split("?"),n=Object.fromEntries(new URLSearchParams(t)),i=(0,l.rD)(e,n,m);return void b.push(i)}const v={meetings_page:"/profile/meetings",schedule_page:"/profile/".concat(I?"team-schedule":"schedule")},g={selectedDay:c},h=(0,l.rD)(v[t]||"",g,m);b.push(h)}))}}}]);
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.