简体   繁体   English

Paypal 按钮未显示在 Dynamics CRM 营销活动网站中的 Angular 生产上

[英]Paypal Buttons Are Not Showing on Angular Production in Dynamics CRM Marketing Event Website

I've used Paypal Javascript-Sdk in Dynamics CRM Marketing Module Event Website Which is By Default on Angular So It is Working Fine on LocalHost我在 Dynamics CRM 营销模块事件网站中使用了 Paypal Javascript-Sdk,默认情况下在 Angular 上运行,所以它在 LocalHost 上运行良好

But When I Tried to Deploy This on Powerappsportals then Somehow it is not Loading & Giving The Following Error on Developer's Console但是当我尝试在 Powerappsportals 上部署它时,不知何故它没有加载并在开发者控制台上出现以下错误

main.js:2 ERROR ReferenceError: paypal is not defined
    at e.payment (main.js:2)
    at e.ngAfterViewInit (main.js:2)
    at fo (main.js:2)
    at ho (main.js:2)
    at po (main.js:2)
    at ai (main.js:2)
    at vi (main.js:2)
    at mi (main.js:2)
    at ai (main.js:2)
    at vi (main.js:2)

So I Realized That Somehow That Paypal SDK is Failed to Load on Production所以我意识到 Paypal SDK 无法在生产中加载

If Someone Has Already Resolved That Issue Please Help Me On This如果有人已经解决了这个问题,请帮助我

Thanks in Advance提前致谢

So Finally I Found a Solution By Myself.所以最后我自己找到了解决方案。

In Dynamics Portal Management Web Template Section There is a Index.html File Defined.动态门户管理 Web 模板部分有一个Index.html文件定义。 Somehow They Restricted Us to Use The Same Format.他们以某种方式限制我们使用相同的格式。 So, When I Tried To Deploy My Angular Application.所以,当我尝试部署我的 Angular 应用程序时。 Dynamics Was Expecting The Index File With The Same Format. Dynamics 期望索引文件具有相同的格式。 So It Neglected The Additional Scripts in Header Section.所以它忽略了 Header 部分中的附加脚本。

So, I Just Added The Paypal Script in That File in Header Section & Now Problem Is Resolved.因此,我刚刚在 Header 部分的该文件中添加了 Paypal 脚本,现在问题已解决。 It is Now Showing Button on Production As Well.它现在也显示生产按钮。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM