• sai first
  • NEWBIE
  • 5 Points
  • Member since 2015


  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 1
    Questions
  • 4
    Replies
I want to call a url in javascript from visualforce page , but I am getting an error that Salesforce doesnot allow Http type url in javascript .what is the solution

Want to create a rollup summary on lookup relationship:
Parent object: Invoice

Child Object:InvoiceLineItems

---Class----
Public Class InvoiceLineItemsTriggerHandler
{
public static CalculateAmount(List<InvoiceLineItem__c> LineItem = New List<InvoiceLineItem__c>())
{
List<Invoice__c> Invoice=new <Invoice__c>();

Query={Select Id,Product_Price__c from InvoiceLineItem__c GROUP BY Invoice__c];

for(InvoiceLineItems__c key:Query)
{
Invoice.Total_Amount__c=add(key.Product_Price__c);
}
}
}
}

I have a requirement for exporting data of few objects before deployment. How effective is Batch Apex for this ? I need to automate this process for a large number of objects. Is it better to use Data loader CLI with Bulk Api or Batch Apex for this ?
Hi all, I have trigger but I'm stuggling to write the test class (I still don't have the experience to do this on my own yet!) Could anyone point me in the right direction please?
 
trigger DoctorTicket on Zendesk__Zendesk_Ticket__c (before insert, before update){
    Zendesk__Zendesk_Ticket__c ticket = trigger.new[0];
    String opname = ticket.Doctor_Name__c;

    // if there's a value populated, get the ID of the record to be related and update the lookup field
    if(opname != null && opname != ''){
        Doctor__c o = [SELECT Id FROM Doctor__c where Name=:opname LIMIT 1]; //query SFDC for a record

        // if an object was returned and that object is different from the current object, update the field
        if(o.ID != null){
            if(o.ID != ticket.Doctor__c){
                ticket.Doctor__c = o.Id;
            }
        }
    }
}