• Dhaker Hassine
  • NEWBIE
  • 10 Points
  • Member since 2020

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 4
    Questions
  • 10
    Replies

Hello everyone, 

In wanted to refresh a div containing a full calendar. I put this div into aura:renderIf tag, and in the JS controller I make a window.setTimeout method. 

The div exists in page inspection, but doesn't reappear in the body of the page. 

Anyone knows this problem? 

Or any other suggestion to refresh this div?
Here are codes: 

1. Calend.cmp

<aura:renderIf isTrue="{!v.truthy}">
             
            <ltng:require scripts="{!join(',', 
            $Resource.fullcalendar + '/fullcalendar/jquery.min.js', 
            $Resource.fullcalendar + '/fullcalendar/jquery-ui.min.js',
            $Resource.fullcalendar + '/fullcalendar/moment.min.js',
            $Resource.fullcalendar + '/fullcalendar/fullcalendar.min.js')}"
   styles="{!$Resource.fullcalendar + '/fullcalendar/fullcalendar.min.css'}"
   
   afterScriptsLoaded="{!c.scriptsLoaded}" />
     <div>Hi from test div</div>
            <div id='calendar'></div>
        </aura:renderIf>


2.CalendController.js

component.set("v.truthy",false);
              window.setTimeout(
                  $A.getCallback(function() {   
                      component.set("v.truthy",true);
                     // setTimeout($('#calendar').fullCalendar(), 3000);
                      console.log("I'm in setTimeOut function");
                      console.log(component.get('v.truthy'));
                  })
                  ,3000);

Hello everyone! 

I createf a VF page, it works when I put preview, but when I put it as my website home page, it doesn't work. 

What must be the problem here? 


This is what it looks like when I overview my website home page:
User-added image
But when I put any other VF page as a home page, it works normally 

Hello everyone, 

I declared two lightning components "calend" et "SignIn" in the same lightning component "MainComponent". And I make SignIn as the sender of an event (Type = APPLICATION) , and the two others as listeners.

With the same code in hundleaction, I've got a result with MainComponent, but Calend doesn't recieve anything. How can I resolve this problem. 
Here MainComponent code : 
 

<aura:component >
    <aura:attribute name="variable" type="boolean" default="False"/>
   <aura:handler name="connResource" event="c:LoginEvent" action="{!c.handleLoginEvent}"/>
	 <aura:if isTrue="{!v.variable == False}">
         <c:SignIn/>
    <aura:set attribute="else">
       <c:Calend/>
    </aura:set>
  </aura:if> 
</aura:component>

Hello everyone,
I wanted to manipulate a couple of lightning components in the same VF page, I wanted to show one of them, and then recuperate a value and hide it to show the other one. 

1. The first Lightning Component is :A login Page (to deploy it in the home page of my website) 

2. The second one is : My Home page

Hello everyone, 

In wanted to refresh a div containing a full calendar. I put this div into aura:renderIf tag, and in the JS controller I make a window.setTimeout method. 

The div exists in page inspection, but doesn't reappear in the body of the page. 

Anyone knows this problem? 

Or any other suggestion to refresh this div?
Here are codes: 

1. Calend.cmp

<aura:renderIf isTrue="{!v.truthy}">
             
            <ltng:require scripts="{!join(',', 
            $Resource.fullcalendar + '/fullcalendar/jquery.min.js', 
            $Resource.fullcalendar + '/fullcalendar/jquery-ui.min.js',
            $Resource.fullcalendar + '/fullcalendar/moment.min.js',
            $Resource.fullcalendar + '/fullcalendar/fullcalendar.min.js')}"
   styles="{!$Resource.fullcalendar + '/fullcalendar/fullcalendar.min.css'}"
   
   afterScriptsLoaded="{!c.scriptsLoaded}" />
     <div>Hi from test div</div>
            <div id='calendar'></div>
        </aura:renderIf>


2.CalendController.js

component.set("v.truthy",false);
              window.setTimeout(
                  $A.getCallback(function() {   
                      component.set("v.truthy",true);
                     // setTimeout($('#calendar').fullCalendar(), 3000);
                      console.log("I'm in setTimeOut function");
                      console.log(component.get('v.truthy'));
                  })
                  ,3000);

Hello everyone! 

I createf a VF page, it works when I put preview, but when I put it as my website home page, it doesn't work. 

What must be the problem here? 


This is what it looks like when I overview my website home page:
User-added image
But when I put any other VF page as a home page, it works normally 

Hello everyone, 

I declared two lightning components "calend" et "SignIn" in the same lightning component "MainComponent". And I make SignIn as the sender of an event (Type = APPLICATION) , and the two others as listeners.

With the same code in hundleaction, I've got a result with MainComponent, but Calend doesn't recieve anything. How can I resolve this problem. 
Here MainComponent code : 
 

<aura:component >
    <aura:attribute name="variable" type="boolean" default="False"/>
   <aura:handler name="connResource" event="c:LoginEvent" action="{!c.handleLoginEvent}"/>
	 <aura:if isTrue="{!v.variable == False}">
         <c:SignIn/>
    <aura:set attribute="else">
       <c:Calend/>
    </aura:set>
  </aura:if> 
</aura:component>

Hello everyone,
I wanted to manipulate a couple of lightning components in the same VF page, I wanted to show one of them, and then recuperate a value and hide it to show the other one. 

1. The first Lightning Component is :A login Page (to deploy it in the home page of my website) 

2. The second one is : My Home page

I am using lighting out. when I preview my vf page, its working fine.
When I am trying same vf page running using site. I am getting bellow error.

Failed to load resource: the server responded with a status of 500 (Internal Server Error)

Could someone help me out. Thank you in advance.
I have to refresh a div in a Lightning Component, the same as how we use rerender in a Visualforce Page. How can I do so?