• Mohammad Rafi 5
  • NEWBIE
  • 0 Points
  • Member since 2018

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 2
    Questions
  • 1
    Replies
how to show multiple axes Highchart on pdf using visual (Using JavaScript)
Thanks
Hello,
I want to create automatic opportuinty line item when opportunity is created. How is this possible. I want to create of particular Product name suppose "Accomodation". I have written a code. 
trigger insertOppLineItem on Opportunity (after insert, after update) {
 system.debug('****************InTrigger**********************');
    
    if(trigger.isAfter && (trigger.isInsert || trigger.isUpdate)){
        String OpportunityID ;
        
    for(Opportunity o : Trigger.new){ 
        system.debug('OpportunityID 8 -->'+o.Id);
        OpportunityID = o.Id;
    
        if(OpportunityID  != null) 
        {
            List<Opportunity> opp = [select Id , No_of_Nights__c from Opportunity where ID =:  OpportunityID  ]; 
               system.debug('Opportunity 14.......... -->'+opp );

          //  List<OpportunityLineItem> vList = new List<OpportunityLineItem >();
           for(OpportunityLineItem v : trigger.new){
            o.No_of_Nights__c = v.Quantity;
        
                //vList.add(v);          
             }
               

        } 
        upsert v; 
    }   
}
}


How is this achivable?


Thanks &Regards,
Utkarsha