• Richard Cook
  • NEWBIE
  • 0 Points
  • Member since 2014

  • Chatter
    Feed
  • 0
    Best Answers
  • 1
    Likes Received
  • 0
    Likes Given
  • 3
    Questions
  • 5
    Replies
I have a lightning component I've simplified down to having one ui:inputNumber. This is working when I surround it with a standalone Lightning app but it is giving errors when I embed it in a VisualForce page. The error I get displayed on my page is 
afterRender threw an error in 'markup://ui:inputNumber' : this.ld.zeroDigit is undefined
I'm on Winter '16 and am following the standard example to embed a Lightning app & component in a VisualForce page.

Component:
<aura:component implements="flexipage:availableForAllPageTypes" controller="Pcmp_DiscountCalculatorController">

<aura:attribute name="derivedPrice" type="double" default="1000.00"/>
<div>
    <div >
        Derived Price: 
        <ui:inputNumber value="{!v.derivedPrice}" />
    </div>
</div>
VisualForce Page:
<apex:page showHeader="false" standardStylesheets="false" sidebar="false" applyHtmlTag="false" applyBodyTag="false" docType="html-5.0">
<!-- Script needed to embed Lightning Components in Visualforce pages. -->
<apex:includeScript value="/lightning/lightning.out.js" />

<!-- Lightning Desktop extra styles and loading of Lightning Component-->
<script type="text/javascript">
  $Lightning.use("c:DiscountCalcVF", function() {
    $Lightning.createComponent("c:DiscountCalculatorPad",
    { accountId: "{!$CurrentPage.parameters.accountId}" ,
      opportunityProductId : "{!$CurrentPage.parameters.productId}" },
    "pricingpage",
    function(cmp) {
      // do some stuff
    });
  });

</script>
<html xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">    

 <head>
 <title>Change this title</title>
 <apex:stylesheet value="{!URLFOR($Resource.SLDS0101, 'assets/styles/salesforce-lightning-design-system-vf.css')}" />
 </head>    

 <body>    

 <!-- REQUIRED SLDS WRAPPER -->
<div class="slds">    
<!-- PRIMARY CONTENT WRAPPER -->
<div class="myapp">    
  <div >
    <div id="pricingpage"></div>
  </div>
  <!-- / PRIMARY CONTENT WRAPPER -->    

</div>
</div>
 <!-- / REQUIRED SLDS WRAPPER -->    
</body>
</html>
</apex:page>



 
I have two dev orgs set up and have been experimenting with Lightning Connect in them. Recently in one of my dev orgs I cannot delete the external object associated with the external data source. I can still do so in the other. When I try to delete the external object I get the message "Insufficient Privileges - You do not have the level of access necessary to perform the operation you requested. Please contact the owner of the record or your administrator if access is necessary." It's a dev org; I am the administrator. Any suggestions on who to contact or troubleshoot would be appreciated.
In Pat Patterson's article,"Calling the Force.com REST API from Visualforce Pages, Revisited", https://developer.salesforce.com/blogs/developer-relations/2013/06/calling-the-force-com-rest-api-from-visualforce-pages-revisited.html, he points out that since Summer '13 the REST API is directly accessible from VisualForce pages, and gives examples of doing so with JQuery. I translated the example to use AngularJS for the JavaScript engine.
Code can be found at https://gist.github.com/rrcook/0f07838bc3d35d017206
In Pat Patterson's article,"Calling the Force.com REST API from Visualforce Pages, Revisited", https://developer.salesforce.com/blogs/developer-relations/2013/06/calling-the-force-com-rest-api-from-visualforce-pages-revisited.html, he points out that since Summer '13 the REST API is directly accessible from VisualForce pages, and gives examples of doing so with JQuery. I translated the example to use AngularJS for the JavaScript engine.
Code can be found at https://gist.github.com/rrcook/0f07838bc3d35d017206
I have a lightning component I've simplified down to having one ui:inputNumber. This is working when I surround it with a standalone Lightning app but it is giving errors when I embed it in a VisualForce page. The error I get displayed on my page is 
afterRender threw an error in 'markup://ui:inputNumber' : this.ld.zeroDigit is undefined
I'm on Winter '16 and am following the standard example to embed a Lightning app & component in a VisualForce page.

Component:
<aura:component implements="flexipage:availableForAllPageTypes" controller="Pcmp_DiscountCalculatorController">

<aura:attribute name="derivedPrice" type="double" default="1000.00"/>
<div>
    <div >
        Derived Price: 
        <ui:inputNumber value="{!v.derivedPrice}" />
    </div>
</div>
VisualForce Page:
<apex:page showHeader="false" standardStylesheets="false" sidebar="false" applyHtmlTag="false" applyBodyTag="false" docType="html-5.0">
<!-- Script needed to embed Lightning Components in Visualforce pages. -->
<apex:includeScript value="/lightning/lightning.out.js" />

<!-- Lightning Desktop extra styles and loading of Lightning Component-->
<script type="text/javascript">
  $Lightning.use("c:DiscountCalcVF", function() {
    $Lightning.createComponent("c:DiscountCalculatorPad",
    { accountId: "{!$CurrentPage.parameters.accountId}" ,
      opportunityProductId : "{!$CurrentPage.parameters.productId}" },
    "pricingpage",
    function(cmp) {
      // do some stuff
    });
  });

</script>
<html xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">    

 <head>
 <title>Change this title</title>
 <apex:stylesheet value="{!URLFOR($Resource.SLDS0101, 'assets/styles/salesforce-lightning-design-system-vf.css')}" />
 </head>    

 <body>    

 <!-- REQUIRED SLDS WRAPPER -->
<div class="slds">    
<!-- PRIMARY CONTENT WRAPPER -->
<div class="myapp">    
  <div >
    <div id="pricingpage"></div>
  </div>
  <!-- / PRIMARY CONTENT WRAPPER -->    

</div>
</div>
 <!-- / REQUIRED SLDS WRAPPER -->    
</body>
</html>
</apex:page>



 
I have two dev orgs set up and have been experimenting with Lightning Connect in them. Recently in one of my dev orgs I cannot delete the external object associated with the external data source. I can still do so in the other. When I try to delete the external object I get the message "Insufficient Privileges - You do not have the level of access necessary to perform the operation you requested. Please contact the owner of the record or your administrator if access is necessary." It's a dev org; I am the administrator. Any suggestions on who to contact or troubleshoot would be appreciated.
In Pat Patterson's article,"Calling the Force.com REST API from Visualforce Pages, Revisited", https://developer.salesforce.com/blogs/developer-relations/2013/06/calling-the-force-com-rest-api-from-visualforce-pages-revisited.html, he points out that since Summer '13 the REST API is directly accessible from VisualForce pages, and gives examples of doing so with JQuery. I translated the example to use AngularJS for the JavaScript engine.
Code can be found at https://gist.github.com/rrcook/0f07838bc3d35d017206