• Antoine LELEU 10
  • NEWBIE
  • 40 Points
  • Member since 2015
  • CRM Consultant
  • Oxala Consulting

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 8
    Questions
  • 8
    Replies
Hello,

Using lightning component, the window.location is blocked by the lockerService.
Do you know how replace the window.location.hash and window.location.pathname ?

Thanks,
Antoine
Hi,

I would like aggregate dynamically variable in output value like this :

<aura:iteration items="{!v.Stocks}" var="article" indexVar="index">
<ui:inputNumber class="slds-input price-inputCurrency"  value="{!article.inventoryPricingArticle.Bottle_Number__c}"/>
<ui:outputNumber value="{!article.stock}"/>
           <ui:outputNumber value="{!article.stock - article.inventoryPricingArticle.Bottle_Number__c}"/>
</aura:iteration> 

The goal is to calculate the last outputNumber when the inputNumber change.

Thanks for your help.
Antoine
 
Hi,

i'm developed a lightning component using SLDS Framework. The component is load in Lightning App and Embedded in VF.
The result is correct but when i want inculde header and side bar in the Salesforce Classic UI, there are display issues :

User-added image
Please, find the code below :

the vf page :

<apex:page controller="AlineaSearchController" showHeader="false" standardStylesheets="false" sidebar="false" applyHtmlTag="false" applyBodyTag="false" docType="html-5.0">

    <!-- ADD LIGHTNING COMPONENT -->
    <apex:includeScript value="/lightning/lightning.out.js" />
    <div id="lightning" />
    <script>
        $Lightning.use("c:AlineaSearch_App", function() {
          $Lightning.createComponent("c:AlineaSearch",{ label : "" },"lightning",function(cmp) {
          });
        });
    </script>

</apex:page>


And the page display in classic loadinf the original page  :

<apex:page standardController="Case" tabStyle="Case">
     <apex:include pageName="AlineaSearchPage"/>
 </apex:page>

Thanks for your help,
Antoine
Hello,

I identified a SOQL request unusually long during an Execution Trigger :
17:53:37.3 (894756684)|SOQL_EXECUTE_BEGIN|[13]|Aggregations:0|SELECT Id, AccountId, StartDate, Date_de_fin__c, CONTRAT_EN_COURS_form__c FROM Contract WHERE (CONTRAT_EN_COURS_form__c = TRUE AND AccountId IN :tmpVar1) LIMIT 50000 17:53:50.852 (13852270691)|SOQL_EXECUTE_END|[13]|Rows:0 

I don't understand why this request is so long, about 13s.
For information, there is no Contract record in the org. All the contract are deleted each night.

Any ideas ?
Thank for your help.

Antoine 
Hello,

i would like to call 2 differents future methods from a Trigger. i use the ProcesorControl.InFutureContext call to prevent the recursive call, so the second method is not launched.

Is there a way to execute 2 future method from a trigger.

Thanks for your help.

Antoine
Hello,

I would like to migrate a visualforce page to lightning experience. i could implement it using quick action in account object but the VF page open in pop up.
Do you know if it exist a way to open vf from an record in a new page in lightning experience ?

Thanks,
Antoine  
Hello,

I would like to use this hash function in Apex. Is it possible to Mapp this java function in apex function ?

public string Hash(string ToHash)
        {
            ToHash = ToHash.ToLower();
            Encoder enc = System.Text.Encoding.ASCII.GetEncoder();
            byte[] data = new byte[ToHash.Length];
            enc.GetBytes(ToHash.ToCharArray(), 0, ToHash.Length, data, 0, true);
            SHA1 sha1 = new SHA1CryptoServiceProvider();
            byte[] result = sha1.ComputeHash(data);
            return BitConverter.ToString(result).Replace("-", "").ToLower();
        }

Thanks for your help !
Antoine
Hello,

I would like use a custom label to stock a custom field name. (ex: 'Custom_Value__c' on object Opportunity).
My Label :
          name = Opportunity_custom_field
          value  = Custom_Value__c

Then request this from apex and use it in my code :

String query = 'Select id, Name, Amount, '+ system.label.Opportunity_custom_field + 'From Opportunity';
List<oppportunity> ListOpps = Dabase.query(query);
For(opportunity opp : ListOpps){
      String Oppvalue = opp.system.label.Opportunity_custom_field;
}

This works for the query as string but not for 'opp.system.label.Opportunity_custom_field' in a loop.
Anyone know the syntaxe ? is it possible to do that ?

Thank you very much 
Antoine
 
Hi,

i'm developed a lightning component using SLDS Framework. The component is load in Lightning App and Embedded in VF.
The result is correct but when i want inculde header and side bar in the Salesforce Classic UI, there are display issues :

User-added image
Please, find the code below :

the vf page :

<apex:page controller="AlineaSearchController" showHeader="false" standardStylesheets="false" sidebar="false" applyHtmlTag="false" applyBodyTag="false" docType="html-5.0">

    <!-- ADD LIGHTNING COMPONENT -->
    <apex:includeScript value="/lightning/lightning.out.js" />
    <div id="lightning" />
    <script>
        $Lightning.use("c:AlineaSearch_App", function() {
          $Lightning.createComponent("c:AlineaSearch",{ label : "" },"lightning",function(cmp) {
          });
        });
    </script>

</apex:page>


And the page display in classic loadinf the original page  :

<apex:page standardController="Case" tabStyle="Case">
     <apex:include pageName="AlineaSearchPage"/>
 </apex:page>

Thanks for your help,
Antoine
Hello,

I identified a SOQL request unusually long during an Execution Trigger :
17:53:37.3 (894756684)|SOQL_EXECUTE_BEGIN|[13]|Aggregations:0|SELECT Id, AccountId, StartDate, Date_de_fin__c, CONTRAT_EN_COURS_form__c FROM Contract WHERE (CONTRAT_EN_COURS_form__c = TRUE AND AccountId IN :tmpVar1) LIMIT 50000 17:53:50.852 (13852270691)|SOQL_EXECUTE_END|[13]|Rows:0 

I don't understand why this request is so long, about 13s.
For information, there is no Contract record in the org. All the contract are deleted each night.

Any ideas ?
Thank for your help.

Antoine 
Hello,

I would like to migrate a visualforce page to lightning experience. i could implement it using quick action in account object but the VF page open in pop up.
Do you know if it exist a way to open vf from an record in a new page in lightning experience ?

Thanks,
Antoine  
Hello,

I would like to use this hash function in Apex. Is it possible to Mapp this java function in apex function ?

public string Hash(string ToHash)
        {
            ToHash = ToHash.ToLower();
            Encoder enc = System.Text.Encoding.ASCII.GetEncoder();
            byte[] data = new byte[ToHash.Length];
            enc.GetBytes(ToHash.ToCharArray(), 0, ToHash.Length, data, 0, true);
            SHA1 sha1 = new SHA1CryptoServiceProvider();
            byte[] result = sha1.ComputeHash(data);
            return BitConverter.ToString(result).Replace("-", "").ToLower();
        }

Thanks for your help !
Antoine
Hi,

I just ran into an issue using ui:textInput within aura:iteration
 
<aura:attribute name="test" type="String[]" default="test1, test2"></aura:attribute>

<aura:iteration items="{!v.test}" var="t">
      {!t}
      <ui:inputText value="{!t}"></ui:inputText>
</aura:iteration>

so when I type something in the input box and leave it, the output should change too, shouldnt it?
Any help?
Thanks!