• Sai Ram A
  • SMARTIE
  • 631 Points
  • Member since 2012
  • Salesforce Developer/ Technical Lead
  • Birlasoft

  • Chatter
    Feed
  • 16
    Best Answers
  • 6
    Likes Received
  • 4
    Likes Given
  • 20
    Questions
  • 133
    Replies

Working the "Handle Actions with Controllers" trailhead module and I'm not getting past the validation.
If I put the component in a test jig, I can see the button function and set the check box as expected.
 

Here is the code I'm using to set the item as packed...

component.set("v.item.Packed__c", true );

I'm assuming the validator does not like my syntax. Can you give me a hint to get past this?

Thanks.
John

I am on the 3rd challenge of the lightning connect project on trailhead. I have followed the instructions as stated, however when i try to create am indirect lookup relationship between customerID and account, account ( nor any other object)  does not show up on the drop down list. 


Quick Start: Lightning ConnectCreate an Indirect Lookup Relationship 
 
Hi everyone,

I'm getting too many redirects error on the page when I preview lightning apps. It was working fine until last night and I'm suddenly getting this, I tried on all different browsers Chrome, Safari, and FireFox without luck. I also tried on incognito window but it didn't help. The app from trailhead tutorial is also displaying the same error when I click preview. Any ideas?

Thanks in advance!
Hi All

Please Suggest the approaches or help in optimizing the Logic/ Query to reduce time Consuming in executing the Order Object Query ( which is taking 10 minutes), this is effecting user experience 
 
//ListMethod

public list<orders__c> getstart() {
	Map<Id,UserTerritory> UserTerritoryCurrentUserMap = new  Map<Id,UserTerritory>([Select u.UserId, u.TerritoryId, u.IsActive, u.Id  From UserTerritory u Where u.isActive=true and u.userId =: UserInfo.getUserId()]);
    system.debug('-----UserTerritoryCurrentUserMap SIZE-------'+UserTerritoryCurrentUserMap.size());
    
    set<Id> TerritoryIdSet = new set<Id>();
    for(UserTerritory ut:UserTerritoryCurrentUserMap.values())
    {
          TerritoryIdSet.add(ut.TerritoryId);
    }    
    
    List<Territory> childTerritories = [Select Id from Territory where ParentTerritoryID in :TerritoryIdSet];
   
    for(Territory ct : childTerritories) {
         TerritoryIdSet.add(ct.Id);
    }
    
    system.debug('-----TerritoryIdSet -------'+TerritoryIdSet);
    system.debug('-----TerritoryIdSet SIZE-------'+TerritoryIdSet.size());

    list<Group> map_group = [Select Id, RelatedId from Group where (Type='Territory' OR Type='TerritoryAndSubordinates') AND RelatedId IN : TerritoryIdSet];
    system.debug('-----map_group -------'+map_group);
	
	Set<String> tempList = new Set<String>();

    for(My_Custom_Object__c s : [SELECT Legacy_Field__c , Account__c FROM My_Custom_Object__c WHERE Account__c IN (Select  AccountId FROM AccountShare where ( UserOrGroupId IN : map_group OR  UserOrGroupId =:UserInfo.getUserId()) AND RowCause IN ('Territory', 'TerritoryManual', 'TerritoryRule')) ]) {
        tempList.add(s.Legacy_Field__c);
    }
    
    system.debug('-----tempList-------'+tempList);
    system.debug('-----tempList-------'+tempList.size()); 
	
	List<orders__c> orders =[SELECT id, Name, Orders__c, Bill_to__c, Payer__c, Ship_To__c, Sold_to__c FROM orders__c WHERE Bill_to__c IN: tempList OR Payer__c IN: tempList OR Ship_To__c IN: tempList OR Sold_to__c IN: tempList];                                     
	system.debug('-----orders-------'+orders);
	
	return orders;
	
}

How to Optimize below Query
 
List<orders__c> orders =[SELECT id, Name, Orders__c, Bill_to__c, Payer__c, Ship_To__c, Sold_to__c FROM orders__c WHERE Bill_to__c IN: tempList OR Payer__c IN: tempList OR Ship_To__c IN: tempList OR Sold_to__c IN: tempList]; 
system.debug('-----orders-------'+orders);

Thank you in Advance
Hi All,

I was going through the site http://www.datatables.net/.There is an example which is shown in the site.
User-added image

When this particular example is seen in TAB or mobile the columns are sorted out like below - 
User-added image

Can anyone help me out how this can be achieved in visualforce page. 
 
How to Remove --None-- from Picklist values which is on VisualForce Page?

Removing --None-- from the Picklist Values.
screenshot of the error message that i am getting
hi i am getting the attached error while rendering the page.
I checked in the debug logs i can see the content in the blob string but it is not getting rendered also the pdf is getting attached with the document object to and the mime type is also shown as application/pdf still i am facing the above error.
Please help

Thanks
hi,
i am new to salesforce, i want to know the set and get method ...
what would happen when we declare the variables like this..
please kindly help me.. please.........

public Cat3__c cat {get;set;}
public String message {get;set;}

 
I an a newbie to salesforce, and was following workbook on apex classes.
This is what i did:
Debug-> Open Exceture Anonymous Window.
System.debug('Hello');

Unchecked "open log". Execute

Alas, i couldnt see any log entries, while the workbook says that log entries will appear.
Do i need to make changes somewhere? or
Am i doing it wrong way?
 
Hi folks,
How to make visualforce page responsive?
Hi friends,

Is there any way to create a master-detail relationship between Product2 and Junction Object.
diff b/w reports and dashboards
Hi folks,

On click of a custom link, i wanna open the new link. How can v achieve this? Any code help.

I'm following a well written tutorial written by @andymahood__c: http://www.tquila.com/blog/2014/11/17/setting-lightning-connect-and-your-first-external-object

When I get to the step #3 ... "Select Edit on the CustomerID field, ...", I don't see Account (or any objects to relate) listed in the drop down box. I have created the custom field on ACCOUNT named CusotmerID Text(5) and marked it as External ID as follows:

CustomerID CustomerID__c Text(5) (External ID) [Checked]

Any ideas?
Dear SF experts,
I am currently trying to implement Remote Objects in Javascript to retrieve Accounts but having difficulty finding a workaround to query for more than the maximum limit of 100 records. Salesforce states that the maximum limit to return one batch of results is 100 but there is more than 2000 records that I need to query.  

Would I have to use offsets and batch query 100 records at a time?
Here is some sample code that I was working with:
j$(document).ready(function() {
            var acctTable = j$('[id$="accounttable"]').DataTable({
                "ajax": function(data, callback, settings) {
                    var acct = new SObjectModel.Account();
                    acct.retrieve({
                        orderby: [{
                            Name: 'ASC'
                        }],
                        limit: 1000
                    }, function(err, records) {
                        if (err) alert(err.message);
                        else {
                            callback({
                                'data': records
                            });
                        };
                    });
                },

Any advice would be appreciated!
Thanks.
  How would I go about doing it?

The usage is as follows:

For example, if an account has 10 contacts, instead of editing one at a time. I want  to be  able to display a table of  with just First Name, Last Name, phone, e-mail, Title

The dataTable object - is there any option to create an editable grid?