(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[881],{190:e=>{e.exports={starWrapper:"Star_starWrapper__AQOHy",starIcon:"Star_starIcon__wX3Cc",starText:"Star_starText__I8WlY",mid:"Star_mid__46G4C",big:"Star_big__svUyZ",partial:"Star_partial__vqiZ8"}},881:(e,a,t)=>{"use strict";t.r(a),t.d(a,{CompanyDetailRating:()=>b});var n=t(95155),i=t(66216),r=t(94589),o=t(24104),s=t(23712),l=t(2191),p=t(84685),c=t(17436),m=t(28009),_=t(43899),g=t(6896),d=t(4779),v=t(26180);let x=e=>`${e} ${(0,c.td)(e,"отзыв","отзыва","отзывов")} на Финуслугах`;var w=t(74516),y=t.n(w);let f=e=>{let a=x(e.reviewsCount);return(0,n.jsxs)("div",{className:y().ratingInfo,children:[(0,n.jsxs)("div",{className:y().ratingTop,children:[(0,n.jsxs)("div",{className:y().ratingTitle,children:[(0,n.jsx)(p.Zv1,{size:24,className:y().ratingIcon}),(0,n.jsx)("span",{children:"Рейтинг отсутствует"})]}),(0,n.jsx)(r.e,{className:y().ratingLink,text:a,mainPageUrl:l.mu,href:e.reviewsHref,target:"_self",offPadding:!0})]}),(0,n.jsxs)("div",{className:y().ratingDescription,children:["Для расчета рейтинга нужно не менее ",5," отзывов"]})]})};var I=t(29722),R=t(16378),h=t(190),j=t.n(h);let u=e=>(0,n.jsxs)("div",{className:(0,I.A)(j().starWrapper,{[j().mid]:e.mid,[j().big]:e.big,[j().partial]:!e.total}),children:[(0,n.jsx)(p.Zv1,{size:e.big?20:16,className:j().starIcon}),(0,R.Y)(e.ratingValue),e.total?`/${e.total}`:"",e.text?"/":"",(0,n.jsx)("span",{className:j().starText,children:e.text})]});var C=t(58551),N=t.n(C);let D=({organization:e,organizationType:a})=>{let t=(0,m.q)("m"),i=l.wY[a],o=e.reviewsInfo,s=a!==g.Ls.mfo,w=[e.url],y=(0,_.D9)({type:a,com:w}),I=Object.entries(o?.serviceMap??{}).map(([e,a])=>({name:a.serviceName,count:a.count||0,rating:a.rating||0,serviceId:a.serviceCategoryId})).filter(({count:e})=>e>0);return(0,n.jsxs)("div",{className:N().component,children:[(0,n.jsxs)("p",{className:N().description,children:["Составляется на основе отзывов клиентов ",i.name_rs]}),(0,n.jsxs)("div",{className:N().peopleRatingWrapper,children:[(0,n.jsx)("div",{className:N().peopleRatingTopInfo,children:5>(o?.totalCount||0)?(0,n.jsx)(f,{reviewsCount:o?.totalCount||0,reviewsHref:y}):(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(u,{ratingValue:o?.totalRating||0,text:"5",big:!0}),(0,n.jsx)(r.e,{className:N().peopleRatingTopFullInfoLink,text:x(o?.totalCount||0),mainPageUrl:l.mu,href:y,target:"_self"})]})}),s&&I.map(({serviceId:e,name:i,count:r,rating:o})=>{let s=r?`${r} ${(0,c.td)(r,"отзыв","отзыва","отзывов")}`:"",m=(0,_.D9)({type:a,com:w,service:String(e)});return(0,n.jsx)("a",{href:m,className:N().rowItem,onClick:()=>{(0,d._)({eventCategory:l.mu,eventActionType:d.y.block,eventActionText:(0,v.y)(i),eventLabel:m})},children:(0,n.jsxs)("div",{className:N().rowTitleWrapper,children:[!t&&(0,n.jsx)(u,{ratingValue:o,total:5,mid:!0}),(0,n.jsx)("div",{className:N().rowTitle,children:i}),(0,n.jsxs)("div",{className:N().rowLink,children:[t&&(0,n.jsx)(u,{ratingValue:o,mid:!0}),s&&(t?`/${s}`:`(${s})`)]}),(0,n.jsx)(p.JuQ,{size:26,className:N().rowItemIcon})]})},e)})]}),!t&&(0,n.jsxs)("p",{className:N().disclaimer,children:["Рейтинги ",e.info.naming.nameR||e.name," составлены на основании наиболее актуальных данных за ",new Date().getFullYear()," год"]})]})};var L=t(86254),T=t.n(L);let b=({organization:e,organizationType:a})=>(0,n.jsx)(i.m,{children:(0,n.jsxs)("div",{className:T().wrapper,children:[(0,n.jsxs)("div",{className:T().container,children:[(0,n.jsx)("div",{className:T().body,children:(0,n.jsxs)("div",{className:T().info,children:[(0,n.jsx)("h2",{className:T().title,children:"Пользовательский рейтинг"}),(0,n.jsx)(D,{organization:e,organizationType:a})]})}),(0,n.jsxs)("div",{className:T().bannerWrapper,children:[(0,n.jsx)(o.c,{company:e.url,orgType:a,eventCategory:"companyDetail"}),(0,n.jsx)(s.N,{})]})]}),(0,n.jsx)(r.e,{className:T().partnersLink,text:`Вы представитель ${l.wY[a].name_r}?`,mainPageUrl:l.mu,href:"/partners",target:"_self",iconColor:"white"})]})})},28009:(e,a,t)=>{"use strict";t.d(a,{q:()=>i});var n=t(14347);let i=e=>{let a=(0,n.nu)(e);return(0,n.qK)()&&a}},43899:(e,a,t)=>{"use strict";t.d(a,{D9:()=>o,Q8:()=>r});var n=t(6896),i=t(5805);let r=e=>{let a=new URLSearchParams(e);return{type:a.get("type")||void 0,com:a.get("com")||void 0,service:a.get("service")||void 0,page:a.get("page")||void 0}},o=e=>{let{type:a,com:t,service:r}=e,o=a===n.Ls.insurance?"sk":a===n.Ls.mfo?"mfo":"",s="",l="";s=window.location.search,l=window.location.hash;let p=new URLSearchParams(s);o?p.set("type",o):p.delete("type"),t?.length?p.set("com",t.join("~")):p.delete("com"),r?p.set("service",r):p.delete("service");let c=p.toString();return(0,i.Ss)(`/otzyvy${c?`?${c}`:""}${l}`)}},58551:e=>{e.exports={component:"CompanyDetailRatingInfo_component__A_Lxa",description:"CompanyDetailRatingInfo_description__SEljL",peopleRatingWrapper:"CompanyDetailRatingInfo_peopleRatingWrapper__COUqP",peopleRatingTopInfo:"CompanyDetailRatingInfo_peopleRatingTopInfo__eILm7",peopleRatingTopFullInfoLink:"CompanyDetailRatingInfo_peopleRatingTopFullInfoLink__1nil_",rowItem:"CompanyDetailRatingInfo_rowItem__rEHPR",rowItemIcon:"CompanyDetailRatingInfo_rowItemIcon__QyrL0",rowTitleWrapper:"CompanyDetailRatingInfo_rowTitleWrapper__6zcHu",rowTitle:"CompanyDetailRatingInfo_rowTitle__0Mb0n",rowLink:"CompanyDetailRatingInfo_rowLink__bS0LP",disclaimer:"CompanyDetailRatingInfo_disclaimer__T2rpw"}},74516:e=>{e.exports={ratingInfo:"CompanyDetailRatingInfoLowReview_ratingInfo__P8Ug4",ratingTop:"CompanyDetailRatingInfoLowReview_ratingTop__dpUTi",ratingTitle:"CompanyDetailRatingInfoLowReview_ratingTitle__86KMu",ratingIcon:"CompanyDetailRatingInfoLowReview_ratingIcon__dIhH8",ratingLink:"CompanyDetailRatingInfoLowReview_ratingLink__WrtlY",ratingDescription:"CompanyDetailRatingInfoLowReview_ratingDescription__y8Ikr"}},86254:e=>{e.exports={wrapper:"CompanyDetailRating_wrapper__70Uhb",container:"CompanyDetailRating_container__PhNeV",body:"CompanyDetailRating_body__XuNWn",info:"CompanyDetailRating_info__2ec85",title:"CompanyDetailRating_title__i4FWa",bannerWrapper:"CompanyDetailRating_bannerWrapper__GaEwP"}}}]);