• Bidhan
  • NEWBIE
  • 0 Points
  • Member since 2010

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

I have 2 developer orgs. My application looks different on different ORG. In one org, I see Summer 10 logo no matter what tab I am on -- and in the other org, I see SalesForce logo on for everytab except for setup screen. The tabs look different as well.

 

Any idea why they look different:

 

 

 

 

Hi,

 

I am using UserInfo.getSessionID() method in a trigger to figure out if the trigger was called within a

specif user context (see code below).

 

So, In a cotroller class, I store the session information in  a custom setting variable. In trigger code, I compare the stored sessionID with userInfo.getSessionID().

 

The issue is that I am getting different Session ID in the trigger code for the same user/session.

 

I don't understand how the sessionID could be different fro the same user in different place of the application.

 

I would appreicate any help in solving this problem.

 

Thanks,

\bidhan

 

Note: In the following trigger code, the if statement allways evalute to FALSE as SessionID__c never macthes with UserInfo.getSessionID().

 

 

trigger CreateSubEntity on Entity__c (after insert) {

Entity__c e = Trigger.new[0];


   Config1__c[] configs = [select id, name,SessionID__c,
                            parentID__c  from config1__c where SetupOwnerId = :UserInfo.getUserId()];
  
    
    if ((configs.size() >= 1)
         && (configs[0].parentID__c != '')
         &&(configs[0].SessionID__c == UserInfo.getSessionID())) {
       Sub_Entity__c aSubEntity = new Sub_Entity__c();
       aSubEntity.ParentEntity__c = configs[0].parentID__c;
       aSubEntity.child__c = e.id;
       insert aSubEntity;
     }
}

 

 

 

 

I am designing an application on force.com platform. The application includes


    • A base/core Object Model.
    • An application extension or template
    • Base object model is built using custom object, Relationships, a few  custom fields, apex classes, trigger, etc. Once installed, the base-object mode can not be modified by our customers. We intend to enhance and support the core-model through new releases and patch releases.

       

      The application extension is built on top of the base object model. Basically, extends the base object model by adding additional custom fields, reports, etc, The application extension is like a template that the customer can modify by adding additional attribute, deleting attribute, adding required fields, etc.  Our application code doesn’t depend on it hence, this as long as the core doesn’t change, we don’t care.

       

      How can I build a package that includes both the core-object model and extensions to the core.  The idea is that the user can install the package, make changes to the extension. Subsequently, the user can upgrade the core-object model when we make new releases.

       

      One approach I can think of is to develop 2 packages: A Managed  pacakge that includes the core-model Then create an un-managed packaged that extends the core model. The customer first has to install the core and then install the extension. But, that’s a 2 step process  . Ideally; I would have liked to do in one step and don;t want the user to go trhough addtional steps to install my app.

       

      I would appreciate any help /guidance.

       

       

    I am trying to model a recursive relationship in force.com. For example, let’s model Business Processes (for hereon forward I will refer to this as PROCESS). A PROCESS can have  0-many “sub” PROCESS (sub process is same object as  the Process) – and, a “sub”  PROCESS can belong to 1..Many PROCESS.

     

     PROCESS  (0,N) ----- (0..N) PROCESS (Sub-Process)

     

    The only way to model this in force.com is using a junction object – let’s call it SubProcess. SubProcess has 2 attibutes:

     

       PARENT  --> Parent PROCESS

       CHILD      --> child PROCESS.

     

    I am trying to figure out how to solve the following problems for the past 2 days without any luck.

     

    •   The user should be able to create a Sub-PROCESS from within the PROCESS detail page. The "new" button in SubProcess section should take me to a PROCESS NEW page (the default PROCESS creation page), once I create the process and save it, it should return to the parent PROCESS page. Now, the newly created process should be displayed on the parent's sub-process list. The subProcess junction table record creation process should be behind the scene and hidden from the user. Please note that the user could change fields for the PROCESS object – hence, I can’t directly use (hardcode) any field names within my code)
    • The process list page (tab), should only display top level parent PROCESSES – processes, that do not have any parent.

     

    I am very new to force.com. I have been looking around in discuss board and documetation – couldn’t find anything that helps.

     

    Any help is appreciated.

    Hi,

     

    I am using UserInfo.getSessionID() method in a trigger to figure out if the trigger was called within a

    specif user context (see code below).

     

    So, In a cotroller class, I store the session information in  a custom setting variable. In trigger code, I compare the stored sessionID with userInfo.getSessionID().

     

    The issue is that I am getting different Session ID in the trigger code for the same user/session.

     

    I don't understand how the sessionID could be different fro the same user in different place of the application.

     

    I would appreicate any help in solving this problem.

     

    Thanks,

    \bidhan

     

    Note: In the following trigger code, the if statement allways evalute to FALSE as SessionID__c never macthes with UserInfo.getSessionID().

     

     

    trigger CreateSubEntity on Entity__c (after insert) {

    Entity__c e = Trigger.new[0];


       Config1__c[] configs = [select id, name,SessionID__c,
                                parentID__c  from config1__c where SetupOwnerId = :UserInfo.getUserId()];
      
        
        if ((configs.size() >= 1)
             && (configs[0].parentID__c != '')
             &&(configs[0].SessionID__c == UserInfo.getSessionID())) {
           Sub_Entity__c aSubEntity = new Sub_Entity__c();
           aSubEntity.ParentEntity__c = configs[0].parentID__c;
           aSubEntity.child__c = e.id;
           insert aSubEntity;
         }
    }

     

     

     

     

    I am designing an application on force.com platform. The application includes


      • A base/core Object Model.
      • An application extension or template
      • Base object model is built using custom object, Relationships, a few  custom fields, apex classes, trigger, etc. Once installed, the base-object mode can not be modified by our customers. We intend to enhance and support the core-model through new releases and patch releases.

         

        The application extension is built on top of the base object model. Basically, extends the base object model by adding additional custom fields, reports, etc, The application extension is like a template that the customer can modify by adding additional attribute, deleting attribute, adding required fields, etc.  Our application code doesn’t depend on it hence, this as long as the core doesn’t change, we don’t care.

         

        How can I build a package that includes both the core-object model and extensions to the core.  The idea is that the user can install the package, make changes to the extension. Subsequently, the user can upgrade the core-object model when we make new releases.

         

        One approach I can think of is to develop 2 packages: A Managed  pacakge that includes the core-model Then create an un-managed packaged that extends the core model. The customer first has to install the core and then install the extension. But, that’s a 2 step process  . Ideally; I would have liked to do in one step and don;t want the user to go trhough addtional steps to install my app.

         

        I would appreciate any help /guidance.

         

         

      I am trying to model a recursive relationship in force.com. For example, let’s model Business Processes (for hereon forward I will refer to this as PROCESS). A PROCESS can have  0-many “sub” PROCESS (sub process is same object as  the Process) – and, a “sub”  PROCESS can belong to 1..Many PROCESS.

       

       PROCESS  (0,N) ----- (0..N) PROCESS (Sub-Process)

       

      The only way to model this in force.com is using a junction object – let’s call it SubProcess. SubProcess has 2 attibutes:

       

         PARENT  --> Parent PROCESS

         CHILD      --> child PROCESS.

       

      I am trying to figure out how to solve the following problems for the past 2 days without any luck.

       

      •   The user should be able to create a Sub-PROCESS from within the PROCESS detail page. The "new" button in SubProcess section should take me to a PROCESS NEW page (the default PROCESS creation page), once I create the process and save it, it should return to the parent PROCESS page. Now, the newly created process should be displayed on the parent's sub-process list. The subProcess junction table record creation process should be behind the scene and hidden from the user. Please note that the user could change fields for the PROCESS object – hence, I can’t directly use (hardcode) any field names within my code)
      • The process list page (tab), should only display top level parent PROCESSES – processes, that do not have any parent.

       

      I am very new to force.com. I have been looking around in discuss board and documetation – couldn’t find anything that helps.

       

      Any help is appreciated.

      After editing my apex class from within the Force.com IDE, i clicked "Save" button. Got an error "File saved locally, not to server". How can i get past this errror? Thanks!