7 = 350 000 000 ?!

本文通过案例介绍了一种不同于传统营销手段的新型营销策略——口碑营销。文章讲述了奥兰多环球影城度假村如何仅通过告知少数几个人,就成功地让全球约3.5亿人得知其即将开设的“哈利·波特魔法世界”主题公园的消息。

<!-- [if gte mso 9]><xml> <w:WordDocument> <w:View>Normal</w:View> <w:Zoom>0</w:Zoom> <w:TrackMoves/> <w:TrackFormatting/> <w:DoNotShowPropertyChanges/> <w:PunctuationKerning/> <w:DrawingGridVerticalSpacing>7.8 磅</w:DrawingGridVerticalSpacing> <w:DisplayHorizontalDrawingGridEvery>0</w:DisplayHorizontalDrawingGridEvery> <w:DisplayVerticalDrawingGridEvery>2</w:DisplayVerticalDrawingGridEvery> <w:ValidateAgainstSchemas/> <w:SaveIfXMLInvalid>false</w:SaveIfXMLInvalid> <w:IgnoreMixedContent>false</w:IgnoreMixedContent> <w:AlwaysShowPlaceholderText>false</w:AlwaysShowPlaceholderText> <w:DoNotPromoteQF/> <w:LidThemeOther>EN-US</w:LidThemeOther> <w:LidThemeAsian>ZH-CN</w:LidThemeAsian> <w:LidThemeComplexScript>X-NONE</w:LidThemeComplexScript> <w:Compatibility> <w:SpaceForUL/> <w:BalanceSingleByteDoubleByteWidth/> <w:DoNotLeaveBackslashAlone/> <w:ULTrailSpace/> <w:DoNotExpandShiftReturn/> <w:AdjustLineHeightInTable/> <w:BreakWrappedTables/> <w:SnapToGridInCell/> <w:WrapTextWithPunct/> <w:UseAsianBreakRules/> <w:DontGrowAutofit/> <w:SplitPgBreakAndParaMark/> <w:DontVertAlignCellWithSp/> <w:DontBreakConstrainedForcedTables/> <w:DontVertAlignInTxbx/> <w:Word11KerningPairs/> <w:CachedColBalance/> <w:UseFELayout/> </w:Compatibility> <w:BrowserLevel>MicrosoftInternetExplorer4</w:BrowserLevel> <m:mathPr> <m:mathFont m:val="Cambria Math"/> <m:brkBin m:val="before"/> <m:brkBinSub m:val="&#45;-"/> <m:smallFrac m:val="off"/> <m:dispDef/> <m:lMargin m:val="0"/> <m:rMargin m:val="0"/> <m:defJc m:val="centerGroup"/> <m:wrapIndent m:val="1440"/> <m:intLim m:val="subSup"/> <m:naryLim m:val="undOvr"/> </m:mathPr></w:WordDocument> </xml><![endif]--><!-- [if gte mso 9]><xml> <w:LatentStyles DefLockedState="false" DefUnhideWhenUsed="true" DefSemiHidden="true" DefQFormat="false" DefPriority="99" LatentStyleCount="267"> <w:LsdException Locked="false" Priority="0" SemiHidden="false" UnhideWhenUsed="false" QFormat="true" Name="Normal"/> <w:LsdException Locked="false" Priority="9" SemiHidden="false" UnhideWhenUsed="false" QFormat="true" Name="heading 1"/> <w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 2"/> <w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 3"/> <w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 4"/> <w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 5"/> <w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 6"/> <w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 7"/> <w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 8"/> <w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 9"/> <w:LsdException Locked="false" Priority="39" Name="toc 1"/> <w:LsdException Locked="false" Priority="39" Name="toc 2"/> <w:LsdException Locked="false" Priority="39" Name="toc 3"/> <w:LsdException Locked="false" Priority="39" Name="toc 4"/> <w:LsdException Locked="false" Priority="39" Name="toc 5"/> <w:LsdException Locked="false" Priority="39" Name="toc 6"/> <w:LsdException Locked="false" Priority="39" Name="toc 7"/> <w:LsdException Locked="false" Priority="39" Name="toc 8"/> <w:LsdException Locked="false" Priority="39" Name="toc 9"/> <w:LsdException Locked="false" Priority="0" Name="footnote text"/> <w:LsdException Locked="false" Priority="35" QFormat="true" Name="caption"/> <w:LsdException Locked="false" Priority="0" Name="footnote reference"/> <w:LsdException Locked="false" Priority="10" SemiHidden="false" UnhideWhenUsed="false" QFormat="true" Name="Title"/> <w:LsdException Locked="false" Priority="1" Name="Default Paragraph Font"/> <w:LsdException Locked="false" Priority="11" SemiHidden="false" UnhideWhenUsed="false" QFormat="true" Name="Subtitle"/> <w:LsdException Locked="false" Priority="22" SemiHidden="false" UnhideWhenUsed="false" QFormat="true" Name="Strong"/> <w:LsdException Locked="false" Priority="20" SemiHidden="false" UnhideWhenUsed="false" QFormat="true" Name="Emphasis"/> <w:LsdException Locked="false" Priority="59" SemiHidden="false" UnhideWhenUsed="false" Name="Table Grid"/> <w:LsdException Locked="false" UnhideWhenUsed="false" Name="Placeholder Text"/> <w:LsdException Locked="false" Priority="1" SemiHidden="false" UnhideWhenUsed="false" QFormat="true" Name="No Spacing"/> <w:LsdException Locked="false" Priority="60" SemiHidden="false" UnhideWhenUsed="false" Name="Light Shading"/> <w:LsdException Locked="false" Priority="61" SemiHidden="false" UnhideWhenUsed="false" Name="Light List"/> <w:LsdException Locked="false" Priority="62" SemiHidden="false" UnhideWhenUsed="false" Name="Light Grid"/> <w:LsdException Locked="false" Priority="63" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Shading 1"/> <w:LsdException Locked="false" Priority="64" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Shading 2"/> <w:LsdException Locked="false" Priority="65" SemiHidden="false" UnhideWhenUsed="false" Name="Medium List 1"/> <w:LsdException Locked="false" Priority="66" SemiHidden="false" UnhideWhenUsed="false" Name="Medium List 2"/> <w:LsdException Locked="false" Priority="67" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Grid 1"/> <w:LsdException Locked="false" Priority="68" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Grid 2"/> <w:LsdException Locked="false" Priority="69" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Grid 3"/> <w:LsdException Locked="false" Priority="70" SemiHidden="false" UnhideWhenUsed="false" Name="Dark List"/> <w:LsdException Locked="false" Priority="71" SemiHidden="false" UnhideWhenUsed="false" Name="Colorful Shading"/> <w:LsdException Locked="false" Priority="72" SemiHidden="false" UnhideWhenUsed="false" Name="Colorful List"/> <w:LsdException Locked="false" Priority="73" SemiHidden="false" UnhideWhenUsed="false" Name="Colorful Grid"/> <w:LsdException Locked="false" Priority="60" SemiHidden="false" UnhideWhenUsed="false" Name="Light Shading Accent 1"/> <w:LsdException Locked="false" Priority="61" SemiHidden="false" UnhideWhenUsed="false" Name="Light List Accent 1"/> <w:LsdException Locked="false" Priority="62" SemiHidden="false" UnhideWhenUsed="false" Name="Light Grid Accent 1"/> <w:LsdException Locked="false" Priority="63" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Shading 1 Accent 1"/> <w:LsdException Locked="false" Priority="64" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Shading 2 Accent 1"/> <w:LsdException Locked="false" Priority="65" SemiHidden="false" UnhideWhenUsed="false" Name="Medium List 1 Accent 1"/> <w:LsdException Locked="false" UnhideWhenUsed="false" Name="Revision"/> <w:LsdException Locked="false" Priority="34" SemiHidden="false" UnhideWhenUsed="false" QFormat="true" Name="List Paragraph"/> <w:LsdException Locked="false" Priority="29" SemiHidden="false" UnhideWhenUsed="false" QFormat="true" Name="Quote"/> <w:LsdException Locked="false" Priority="30" SemiHidden="false" UnhideWhenUsed="false" QFormat="true" Name="Intense Quote"/> <w:LsdException Locked="false" Priority="66" SemiHidden="false" UnhideWhenUsed="false" Name="Medium List 2 Accent 1"/> <w:LsdException Locked="false" Priority="67" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Grid 1 Accent 1"/> <w:LsdException Locked="false" Priority="68" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Grid 2 Accent 1"/> <w:LsdException Locked="false" Priority="69" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Grid 3 Accent 1"/> <w:LsdException Locked="false" Priority="70" SemiHidden="false" UnhideWhenUsed="false" Name="Dark List Accent 1"/> <w:LsdException Locked="false" Priority="71" SemiHidden="false" UnhideWhenUsed="false" Name="Colorful Shading Accent 1"/> <w:LsdException Locked="false" Priority="72" SemiHidden="false" UnhideWhenUsed="false" Name="Colorful List Accent 1"/> <w:LsdException Locked="false" Priority="73" SemiHidden="false" UnhideWhenUsed="false" Name="Colorful Grid Accent 1"/> <w:LsdException Locked="false" Priority="60" SemiHidden="false" UnhideWhenUsed="false" Name="Light Shading Accent 2"/> <w:LsdException Locked="false" Priority="61" SemiHidden="false" UnhideWhenUsed="false" Name="Light List Accent 2"/> <w:LsdException Locked="false" Priority="62" SemiHidden="false" UnhideWhenUsed="false" Name="Light Grid Accent 2"/> <w:LsdException Locked="false" Priority="63" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Shading 1 Accent 2"/> <w:LsdException Locked="false" Priority="64" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Shading 2 Accent 2"/> <w:LsdException Locked="false" Priority="65" SemiHidden="false" UnhideWhenUsed="false" Name="Medium List 1 Accent 2"/> <w:LsdException Locked="false" Priority="66" SemiHidden="false" UnhideWhenUsed="false" Name="Medium List 2 Accent 2"/> <w:LsdException Locked="false" Priority="67" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Grid 1 Accent 2"/> <w:LsdException Locked="false" Priority="68" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Grid 2 Accent 2"/> <w:LsdException Locked="false" Priority="69" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Grid 3 Accent 2"/> <w:LsdException Locked="false" Priority="70" SemiHidden="false" UnhideWhenUsed="false" Name="Dark List Accent 2"/> <w:LsdException Locked="false" Priority="71" SemiHidden="false" UnhideWhenUsed="false" Name="Colorful Shading Accent 2"/> <w:LsdException Locked="false" Priority="72" SemiHidden="false" UnhideWhenUsed="false" Name="Colorful List Accent 2"/> <w:LsdException Locked="false" Priority="73" SemiHidden="false" UnhideWhenUsed="false" Name="Colorful Grid Accent 2"/> <w:LsdException Locked="false" Priority="60" SemiHidden="false" UnhideWhenUsed="false" Name="Light Shading Accent 3"/> <w:LsdException Locked="false" Priority="61" SemiHidden="false" UnhideWhenUsed="false" Name="Light List Accent 3"/> <w:LsdException Locked="false" Priority="62" SemiHidden="false" UnhideWhenUsed="false" Name="Light Grid Accent 3"/> <w:LsdException Locked="false" Priority="63" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Shading 1 Accent 3"/> <w:LsdException Locked="false" Priority="64" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Shading 2 Accent 3"/> <w:LsdException Locked="false" Priority="65" SemiHidden="false" UnhideWhenUsed="false" Name="Medium List 1 Accent 3"/> <w:LsdException Locked="false" Priority="66" SemiHidden="false" UnhideWhenUsed="false" Name="Medium List 2 Accent 3"/> <w:LsdException Locked="false" Priority="67" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Grid 1 Accent 3"/> <w:LsdException Locked="false" Priority="68" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Grid 2 Accent 3"/> <w:LsdException Locked="false" Priority="69" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Grid 3 Accent 3"/> <w:LsdException Locked="false" Priority="70" SemiHidden="false" UnhideWhenUsed="false" Name="Dark List Accent 3"/> <w:LsdException Locked="false" Priority="71" SemiHidden="false" UnhideWhenUsed="false" Name="Colorful Shading Accent 3"/> <w:LsdException Locked="false" Priority="72" SemiHidden="false" UnhideWhenUsed="false" Name="Colorful List Accent 3"/> <w:LsdException Locked="false" Priority="73" SemiHidden="false" UnhideWhenUsed="false" Name="Colorful Grid Accent 3"/> <w:LsdException Locked="false" Priority="60" SemiHidden="false" UnhideWhenUsed="false" Name="Light Shading Accent 4"/> <w:LsdException Locked="false" Priority="61" SemiHidden="false" UnhideWhenUsed="false" Name="Light List Accent 4"/> <w:LsdException Locked="false" Priority="62" SemiHidden="false" UnhideWhenUsed="false" Name="Light Grid Accent 4"/> <w:LsdException Locked="false" Priority="63" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Shading 1 Accent 4"/> <w:LsdException Locked="false" Priority="64" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Shading 2 Accent 4"/> <w:LsdException Locked="false" Priority="65" SemiHidden="false" UnhideWhenUsed="false" Name="Medium List 1 Accent 4"/> <w:LsdException Locked="false" Priority="66" SemiHidden="false" UnhideWhenUsed="false" Name="Medium List 2 Accent 4"/> <w:LsdException Locked="false" Priority="67" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Grid 1 Accent 4"/> <w:LsdException Locked="false" Priority="68" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Grid 2 Accent 4"/> <w:LsdException Locked="false" Priority="69" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Grid 3 Accent 4"/> <w:LsdException Locked="false" Priority="70" SemiHidden="false" UnhideWhenUsed="false" Name="Dark List Accent 4"/> <w:LsdException Locked="false" Priority="71" SemiHidden="false" UnhideWhenUsed="false" Name="Colorful Shading Accent 4"/> <w:LsdException Locked="false" Priority="72" SemiHidden="false" UnhideWhenUsed="false" Name="Colorful List Accent 4"/> <w:LsdException Locked="false" Priority="73" SemiHidden="false" UnhideWhenUsed="false" Name="Colorful Grid Accent 4"/> <w:LsdException Locked="false" Priority="60" SemiHidden="false" UnhideWhenUsed="false" Name="Light Shading Accent 5"/> <w:LsdException Locked="false" Priority="61" SemiHidden="false" UnhideWhenUsed="false" Name="Light List Accent 5"/> <w:LsdException Locked="false" Priority="62" SemiHidden="false" UnhideWhenUsed="false" Name="Light Grid Accent 5"/> <w:LsdException Locked="false" Priority="63" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Shading 1 Accent 5"/> <w:LsdException Locked="false" Priority="64" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Shading 2 Accent 5"/> <w:LsdException Locked="false" Priority="65" SemiHidden="false" UnhideWhenUsed="false" Name="Medium List 1 Accent 5"/> <w:LsdException Locked="false" Priority="66" SemiHidden="false" UnhideWhenUsed="false" Name="Medium List 2 Accent 5"/> <w:LsdException Locked="false" Priority="67" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Grid 1 Accent 5"/> <w:LsdException Locked="false" Priority="68" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Grid 2 Accent 5"/> <w:LsdException Locked="false" Priority="69" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Grid 3 Accent 5"/> <w:LsdException Locked="false" Priority="70" SemiHidden="false" UnhideWhenUsed="false" Name="Dark List Accent 5"/> <w:LsdException Locked="false" Priority="71" SemiHidden="false" UnhideWhenUsed="false" Name="Colorful Shading Accent 5"/> <w:LsdException Locked="false" Priority="72" SemiHidden="false" UnhideWhenUsed="false" Name="Colorful List Accent 5"/> <w:LsdException Locked="false" Priority="73" SemiHidden="false" UnhideWhenUsed="false" Name="Colorful Grid Accent 5"/> <w:LsdException Locked="false" Priority="60" SemiHidden="false" UnhideWhenUsed="false" Name="Light Shading Accent 6"/> <w:LsdException Locked="false" Priority="61" SemiHidden="false" UnhideWhenUsed="false" Name="Light List Accent 6"/> <w:LsdException Locked="false" Priority="62" SemiHidden="false" UnhideWhenUsed="false" Name="Light Grid Accent 6"/> <w:LsdException Locked="false" Priority="63" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Shading 1 Accent 6"/> <w:LsdException Locked="false" Priority="64" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Shading 2 Accent 6"/> <w:LsdException Locked="false" Priority="65" SemiHidden="false" UnhideWhenUsed="false" Name="Medium List 1 Accent 6"/> <w:LsdException Locked="false" Priority="66" SemiHidden="false" UnhideWhenUsed="false" Name="Medium List 2 Accent 6"/> <w:LsdException Locked="false" Priority="67" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Grid 1 Accent 6"/> <w:LsdException Locked="false" Priority="68" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Grid 2 Accent 6"/> <w:LsdException Locked="false" Priority="69" SemiHidden="false" UnhideWhenUsed="false" Name="Medium Grid 3 Accent 6"/> <w:LsdException Locked="false" Priority="70" SemiHidden="false" UnhideWhenUsed="false" Name="Dark List Accent 6"/> <w:LsdException Locked="false" Priority="71" SemiHidden="false" UnhideWhenUsed="false" Name="Colorful Shading Accent 6"/> <w:LsdException Locked="false" Priority="72" SemiHidden="false" UnhideWhenUsed="false" Name="Colorful List Accent 6"/> <w:LsdException Locked="false" Priority="73" SemiHidden="false" UnhideWhenUsed="false" Name="Colorful Grid Accent 6"/> <w:LsdException Locked="false" Priority="19" SemiHidden="false" UnhideWhenUsed="false" QFormat="true" Name="Subtle Emphasis"/> <w:LsdException Locked="false" Priority="21" SemiHidden="false" UnhideWhenUsed="false" QFormat="true" Name="Intense Emphasis"/> <w:LsdException Locked="false" Priority="31" SemiHidden="false" UnhideWhenUsed="false" QFormat="true" Name="Subtle Reference"/> <w:LsdException Locked="false" Priority="32" SemiHidden="false" UnhideWhenUsed="false" QFormat="true" Name="Intense Reference"/> <w:LsdException Locked="false" Priority="33" SemiHidden="false" UnhideWhenUsed="false" QFormat="true" Name="Book Title"/> <w:LsdException Locked="false" Priority="37" Name="Bibliography"/> <w:LsdException Locked="false" Priority="39" QFormat="true" Name="TOC Heading"/> </w:LatentStyles> </xml><![endif]--><!-- [if gte mso 10]> <style> /* Style Definitions */ table.MsoNormalTable {mso-style-name:普通表格; mso-tstyle-rowband-size:0; mso-tstyle-colband-size:0; mso-style-noshow:yes; mso-style-priority:99; mso-style-qformat:yes; mso-style-parent:""; mso-padding-alt:0cm 5.4pt 0cm 5.4pt; mso-para-margin:0cm; mso-para-margin-bottom:.0001pt; mso-pagination:widow-orphan; font-size:10.5pt; mso-bidi-font-size:11.0pt; font-family:"Calibri","sans-serif"; mso-ascii-font-family:Calibri; mso-ascii-theme-font:minor-latin; mso-fareast-font-family:宋体; mso-fareast-theme-font:minor-fareast; mso-hansi-font-family:Calibri; mso-hansi-theme-font:minor-latin; mso-bidi-font-family:"Times New Roman"; mso-bidi-theme-font:minor-bidi; mso-font-kerning:1.0pt;} </style> <![endif]-->

——摘自《口碑:引爆网络狂欢效应的锦囊妙计

假设你是一家主题公园的营销部主管,目前你的主要任务是推广一个能吸引游客的新景点。你该怎么做?

若是按照旧的营销规则,那么这意味着你要花大钱了。要想引起人们的注意,你很可能要将数百万资金花费在电视广告和高速公路旁的广告牌上,还要使出那些麦迪逊大街的广告公司所惯用的“创造性”的广告技巧。接着,你还会聘请一家大型的公关代理公司,他们的公关代表会想方设法让你的新景点在媒体上曝光。除此之外,你还要策划一场充满自我吹捧意味的新闻发布会,出席发布会的公司重量级人物声称新景点将会拉近家人之间的距离,从而促进世界和平。

然而,辛迪 · 戈登( Cindy Gordon )并没有这么做。作为奥兰多环球影城度假村负责新媒体营销的副总裁,在推广新项目“哈利 · 波特魔法世界”时,她并没有像其他大型娱乐公司那样采用旧的营销方式,花费几百万美元来“骚扰”全国民众:超级碗 [1] 直播期间的电视广告、飞艇广告、直邮广告和杂志广告,等等。相反,戈登只是将新景点即将开放的消息告诉了 7 个人。

而就是这屈指可数的 7 个人,将这个消息传递给了成千上万的人。

上万民众的关注,使得报纸、杂志、电视、电台等主流媒体争先恐后地报道这一消息,博主们也纷纷以此为主题发表博文。戈登估计,全球大约有 3.5 亿人听说了奥兰多环球影城度假村将要建设“哈利 · 波特魔法世界”主题公园的消息。而实际上,她只告诉了 7 个人。

口碑




[1] Super Bowl ,美国橄榄球联盟的年度冠军赛,伴随比赛还会举行盛大的庆祝活动。

——译者注

优化下列代码 import AuroraService from '@aurora/service'; import Turbo from '@turboui/turbo-ui-sdk'; import { Modal } from '@aurora/vue'; import { praGateWay } from '@/commons/utils/fns'; import Enum from '@/commons/enum'; const { network } = new AuroraService(); // 改进的发布订阅类 class EventEmitter { constructor() { this.events = new Map(); } on(type, cbResolve, cbReject) { if (!this.events.has(type)) { this.events.set(type, []); } this.events.get(type).push({ cbResolve, cbReject }); } emit(type, res, ansType) { if (this.events.has(type)) { this.events.get(type).forEach((cbObj) => { ansType === 'resolve' ? cbObj.cbResolve(res) : cbObj.cbReject(res); }); this.events.delete(type); } } } // 生成请求键 const generateRequestKey = (config) => { const { method, url, params, data } = config; return [method, url, JSON.stringify(params), JSON.stringify(data), Turbo?.i18n?.locale ?? ''].join('&'); }; // 存储已发送但未响应的请求 const pendingRequest = new Set(); // 发布订阅容器 const ev = new EventEmitter(); // 处理响应 const handleResponse = (reqKey, response, isResolve) => { if (pendingRequest.has(reqKey)) { const data = JSON.parse(JSON.stringify(response)); pendingRequest.delete(reqKey); ev.emit(reqKey, data, isResolve ? 'resolve' : 'reject'); } }; // 处理成功响应 const handleSuccessResponseLimit = (response) => { const reqKey = response.config.pendKey; handleResponse(reqKey, response, true); }; // 处理错误响应 const handleErrorResponseLimit = (error) => { const reqKey = error?.config?.pendKey; if (reqKey && pendingRequest.has(reqKey)) { const errorData = JSON.parse(JSON.stringify(error)); handleResponse(reqKey, errorData, false); } modelErrorTips(error); return Promise.reject(error); }; // 提示接口错误 const modelErrorTips = (error) => { const errorData = error?.response?.data; if (errorData) { if (errorData?.status === Enum.NETWORK_ERRORCODE_NOPREMISSION || errorData.httpCode === Enum.NETWORK_ERRORCODE_NOPREMISSION) { const message = errorData.message || Turbo.i18n.$t('pra.common.no'); Modal.message({ message, status: 'error', id: Enum.NETWORK_ERRORCODE_NOPREMISSION }); } } }; // 添加请求拦截器 network.interceptors.request.use( (config) => { config.url = config.url.replace(/(?!^)\/+/g, '/'); if (!config.connectLocal && !config.url.includes(praGateWay())) { config.url = praGateWay() + config.url; } const reqKey = generateRequestKey(config); if (pendingRequest.has(reqKey)) { return new Promise((resolve, reject) => { ev.on(reqKey, resolve, reject); }) .then((res) => { throw { type: 'limitResSuccess', val: res }; }) .catch((err) => { throw { type: 'limitResError', val: err }; }); } else { config.pendKey = reqKey; pendingRequest.add(reqKey); } return config; }, (error) => Promise.reject(error) ); network.interceptors.response.use( (response) => { handleSuccessResponseLimit(response); return response; }, (error) => handleErrorResponseLimit(error) ); export default network; // 提供给有配置取消的接口catch时处理缓存,避免后续调用不了 export const deleteCancelReqCache = (config) => { const reqKey = generateRequestKey(config); pendingRequest.delete(reqKey); };
08-28
<svg width="800" height="700" viewBox="0 0 800 700" xmlns="http://www.w3.org/2000/svg"> <!-- 背景 --> <rect width="800" height="700" fill="#f9f9f9"/> <!-- 标题 --> <text x="400" y="40" font-family="Arial" font-size="24" text-anchor="middle" font-weight="bold">层次分析法(AHP)一致性矩阵算法流程图</text> <!-- 流程框样式 --> <defs> <marker id="arrowhead" markerWidth="10" markerHeight="7" refX="9" refY="3.5" orient="auto"> <polygon points="0 0, 10 3.5, 0 7" fill="#333"/> </marker> <!-- 渐变定义 --> <linearGradient id="startGradient" x1="0%" y1="0%" x2="100%" y2="0%"> <stop offset="0%" stop-color="#4CAF50"/> <stop offset="100%" stop-color="#388E3C"/> </linearGradient> <linearGradient id="processGradient" x1="0%" y1="0%" x2="100%" y2="0%"> <stop offset="0%" stop-color="#2196F3"/> <stop offset="100%" stop-color="#1976D2"/> </linearGradient> <linearGradient id="calcGradient" x1="0%" y1="0%" x2="100%" y2="0%"> <stop offset="0%" stop-color="#9C27B0"/> <stop offset="100%" stop-color="#7B1FA2"/> </linearGradient> <linearGradient id="resultGradient" x1="0%" y1="0%" x2="100%" y2="0%"> <stop offset="0%" stop-color="#26A69A"/> <stop offset="100%" stop-color="#009688"/> </linearGradient> </defs> <!-- 开始 --> <rect x="350" y="80" width="100" height="40" rx="20" fill="url(#startGradient)" stroke="#388E3C" stroke-width="2"/> <text x="400" y="105" font-family="Arial" font-size="14" text-anchor="middle" fill="white">开始</text> <!-- 设置参数 --> <rect x="350" y="150" width="100" height="40" fill="url(#processGradient)" stroke="#1976D2" stroke-width="2"/> <text x="400" y="175" font-family="Arial" font-size="14" text-anchor="middle" fill="white">设置n=6</text> <!-- 构建矩阵 --> <rect x="300" y="220" width="200" height="60" fill="url(#processGradient)" stroke="#1976D2" stroke-width="2"/> <text x="400" y="245" font-family="Arial" font-size="14" text-anchor="middle" fill="white">构建一致性矩阵</text> <text x="400" y="265" font-family="Arial" font-size="12" text-anchor="middle" fill="white">C(i,j)=9^((i-j)/(n-1))</text> <!-- 计算特征值 --> <rect x="350" y="310" width="100" height="40" fill="url(#calcGradient)" stroke="#7B1FA2" stroke-width="2"/> <text x="400" y="335" font-family="Arial" font-size="14" text-anchor="middle" fill="white">计算特征值和特征向量</text> <!-- 提取最大特征值 --> <rect x="350" y="380" width="100" height="40" fill="url(#calcGradient)" stroke="#7B1FA2" stroke-width="2"/> <text x="400" y="405" font-family="Arial" font-size="14" text-anchor="middle" fill="white">提取最大特征值λ_max</text> <!-- 计算CI --> <rect x="350" y="450" width="100" height="40" fill="url(#calcGradient)" stroke="#7B1FA2" stroke-width="2"/> <text x="400" y="475" font-family="Arial" font-size="14" text-anchor="middle" fill="white">计算CI=(λ_max-n)/(n-1)</text> <!-- 计算CR --> <rect x="350" y="520" width="100" height="40" fill="url(#calcGradient)" stroke="#7B1FA2" stroke-width="2"/> <text x="400" y="545" font-family="Arial" font-size="14" text-anchor="middle" fill="white">计算CR=CI/RI</text> <!-- 判断一致性 --> <rect x="350" y="590" width="100" height="40" fill="url(#resultGradient)" stroke="#009688" stroke-width="2"/> <text x="400" y="615" font-family="Arial" font-size="14" text-anchor="middle" fill="white">CR<0.1? 是/否</text> <!-- 决策结果 --> <rect x="200" y="660" width="400" height="30" rx="15" fill="#FFC107" stroke="#FFA000" stroke-width="2"/> <text x="400" y="680" font-family="Arial" font-size="14" text-anchor="middle" fill="#333">一致性可接受 → 使用计算权重</text> <rect x="200" y="695" width="400" height="30" rx="15" fill="#FF5722" stroke="#E64A19" stroke-width="2"/> <text x="400" y="715" font-family="Arial" font-size="14" text-anchor="middle" fill="white">一致性不可接受 → 重新调整判断矩阵</text> <!-- 连接线 --> <line x1="400" y1="120" x2="400" y2="150" stroke="#333" stroke-width="2" marker-end="url(#arrowhead)"/> <line x1="400" y1="190" x2="400" y2="220" stroke="#333" stroke-width="2" marker-end="url(#arrowhead)"/> <line x1="400" y1="280" x2="400" y2="310" stroke="#333" stroke-width="2" marker-end="url(#arrowhead)"/> <line x1="400" y1="360" x2="400" y2="380" stroke="#333" stroke-width="2" marker-end="url(#arrowhead)"/> <line x1="400" y1="430" x2="400" y2="450" stroke="#333" stroke-width="2" marker-end="url(#arrowhead)"/> <line x1="400" y1="500" x2="400" y2="520" stroke="#333" stroke-width="2" marker-end="url(#arrowhead)"/> <line x1="400" y1="570" x2="400" y2="590" stroke="#333" stroke-width="2" marker-end="url(#arrowhead)"/> <!-- 决策结果连接线 --> <line x1="300" y1="620" x2="200" y2="645" stroke="#333" stroke-width="2" marker-end="url(#arrowhead)" stroke-dasharray="5,5"/> <line x1="500" y1="620" x2="600" y2="645" stroke="#333" stroke-width="2" marker-end="url(#arrowhead)" stroke-dasharray="5,5"/> <!-- 算法细节说明 --> <text x="20" y="180" font-family="Arial" font-size="12" fill="#333">1. 设置影响因素数量n=6</text> <text x="20" y="210" font-family="Arial" font-size="12" fill="#333">2. 构建6×6一致性矩阵</text> <text x="20" y="240" font-family="Arial" font-size="12" fill="#333">3. 计算矩阵的特征值和特征向量</text> <text x="20" y="270" font-family="Arial" font-size="12" fill="#333">4. 提取最大特征值λ_max</text> <text x="20" y="300" font-family="Arial" font-size="12" fill="#333">5. 计算一致性指标CI</text> <text x="20" y="330" font-family="Arial" font-size="12" fill="#333">6. 查表获取RI值(RI[6]=1.24)</text> <text x="20" y="360" font-family="Arial" font-size="12" fill="#333">7. 计算一致性比率CR</text> <text x="20" y="390" font-family="Arial" font-size="12" fill="#333">8. 判断CR是否小于0.1</text> <text x="20" y="420" font-family="Arial" font-size="12" fill="#333">9. 根据一致性结果进行决策</text> </svg> 生成此图
05-17
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值