• Nitul Deori 4
  • NEWBIE
  • 0 Points
  • Member since 2021

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 0
    Questions
  • 1
    Replies

Hello,

 

EXTJS library is being used by many people these days to enhace the standard VF functionality.

Here is one example of how to create a EXTJS Datagrid in a VF page (from Appirio):  link

 

My question is related to the interaction between different pieces used in the approach: Apex (Controller) <-> Visualforce components <-> EXTJS components:

 

1. The first type of interaction is following:

 

a. Apex fetches data  (either SFDC data or makes a WS callout to get data)

b. Visualforce components, such as <apex:repeat> are involved into formatting the data to be provided to EXTJS component

c. EXTJS component shows data that was formatted properly using Visualforce components (you'll get a better understanding if you look at a link above)

 

2. Second type of interaction is the point where questions comes: when data is displayed within EXTJS components, how do we link events that happen on EXTJS components to Apex? To make it clear, here is an example:

 

There is a <apex:commandButton> Visualforce component that has an 'action' attribute that links to a method within a Controller. Whenever a user presses the button a method is invoked. - this is all clear because we are using Visualforce only.

However, when it comes to EXTJS - its components have their own buttons and links, or any other GUI controls that can generate events. The question is - how to link a button on EXTJS component to a method within a Controller?

 

Generally speaking, the question would sound like: "How to link events, such as button clicks, in a custom javascipt code to a method within a Controller?"

 

 

 

Many thanks!

  • January 24, 2009
  • Like
  • 0