• TylerBrooks
  • NEWBIE
  • 160 Points
  • Member since 2018

  • Chatter
    Feed
  • 3
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 8
    Questions
  • 31
    Replies
Hi...

Our student service department processes the student request through cases.
There are some requests that a payment is required. So, we associate Case with Order. One case can have one or more than one Orders.

REQUIREMENT:
The Case can only be closed when the Order(s) status is "Activated" 

QUESTION:
How can we aware of the user when she/he tries to close the Case that the Order(s) is not Activated yet?

We're thinking to develop the Case validation in the Trigger event (before update). How could we launch a pop up from the Trigger?

Thanks,
Pedro
 
I have a new flow where i launch from an opportunity to update selected custom object related records. The opportunity is a master detail relationship with the custom object.  when i click the select custom button on the opportunity instead of just getting the related records to the opportunity I get all records to that custom object. I've tried everything i can think of with this flow to only retrieve the relate records but nothing seems to work. below is a screenshot of my record choice set. Any help with this would be greatly appreciated.

User-added image
  • March 11, 2019
  • Like
  • 0
How can I add a functionality on the Service Console allowing Service Reps to easily set their Status (Available to work, Break, Lunch, etc..) so that:
  1. A System Admin can setup Case Assignment (Assign Cases to Users ONLY if their Status == Available to Work);
  2. Report on Time Spent by each Sales Rep on each Status;
The Product Owner is asking for a Button or field or some kind of functionality to let Sales Rep easily indicate their Status when from the Service Console.

In another hand, I have seen that the "Live Agent" functionality offers a little window where is it possible for the Agent to set his/her availability (as in the screenshot).Live Agent window on Service Cloud

Should I think of adding a picklist field somewhere on the Service Console? (How?)

 
  • March 08, 2019
  • Like
  • 0
Hey All,

I wrote a simple apex trigger to get Case Feed Items and after they're inserted create a new record which stores information for our Business analysts. The code works in my sandbox and does what I want it to do but when trying to create a test class I only get 18% coverage and I'm not sure how to adjust my test class to get the required code coverage.

TRIGGER: 
trigger CaseFeed on FeedItem (after insert) 
{
    List<Case> Cases = [SELECT Id, CaseNumber FROM Case];
    for(case myCase : Cases)
    {
    	for(FeedItem caseFeed : trigger.new)
    	{
        	if(caseFeed.ParentId == myCase.Id)
        	{
            	Case_History_and_Feed_Tracking__c chf = new Case_History_and_Feed_Tracking__c();
            	chf.Case__c = caseFeed.ParentId;
            	chf.TSR__c = caseFeed.CreatedById;
            	chf.Change_Made_Body__c = caseFeed.Body;
				insert chf;
        	}
    	}
    }

}

TEST CLASS:
@isTest
private class TestCaseFeed
{
    @isTest static void InsertCaseFeed()
    {
		FeedItem caseFeed = new FeedItem();
        caseFeed.Body= 'Testing my test class :D';
        caseFeed.ParentId = '5002a000004TOCrAAO';
        caseFeed.CreatedById = '0050y00000E1zyyAAB';
        insert caseFeed;
    }

}
The lines of code in the trigger saying they get coverage is
List<Case> Cases = [SELECT Id, CaseNumber FROM Case];
    for(case myCase : Cases)
Hey All,

I have a visualforce page that has 3 tabs for 3 different products that we offer subscriptions for. Each product has a status that's a picklist field on the account object (3 picklist fields) and I want to change the background color of a products tab based off of the picklist value of its respective Picklist. I know I could adjust the render settings based off of the picklist values and duplicated the code with a ton of pageblocks with conditional rendering but there are dozens of combinations that I would have to account for and I would like to have a jquery run when the page is loaded.

Here is the page without any query
<apex:page standardController="Account" showHeader="true" extensions="TestDisplayQueryResults" >
    <style>
    .TSMactiveTab {background-color: #4CAF50; color:white; background-image:none}
    .TSMNotactiveTab { background-color: #f44336; color:black; background-image:none}
    .TSMOnHoldTab { background-color: #ff9800; color:black; background-image:none}
    </style>        
    <apex:pageBlock id="Block1" rendered="{!AND(Account.TS_M_Status__c == 'Active', Account.SM_Status__c == 'Active', Account.RIPL_TSM_Status__c == 'Active')}">
    <apex:tabPanel switchType="client" selectedTab="name1" id="AccountTabPanel" >
        <apex:tab label="PCS" name="name1" id="tabOne" styleClass="TSMactiveTab">
        <apex:pageBlock title="PCS Subscription Items">
        <apex:outputField value="{!Account.TS_M_Status__c}"/>
        <apex:pageBlockTable value="{!PCSSubItems}" var="item">
            <apex:column value="{!item.Subscription_ID__c}"/>
            <apex:column value="{!item.name}"/>
            <apex:column value="{!item.Product__c}"/>
            <apex:column value="{!item.Item_Status__c}"/>
            <apex:column value="{!item.Quantity__c}"/>
        </apex:pageBlockTable>
        </apex:pageBlock>
        </apex:tab>
        <apex:tab label="Survey Manager" name="name2" id="tabTwo" styleClass="TSMactiveTab">
        <apex:pageBlock title="Survey Manager Subscription Items">
        <apex:pageBlockTable value="{!SMSubItems}" var="SMitem">
            <apex:column value="{!SMitem.Subscription_ID__c}"/>
            <apex:column value="{!SMitem.name}"/>
            <apex:column value="{!SMitem.Product__c}"/>
            <apex:column value="{!SMitem.Item_Status__c}"/>
            <apex:column value="{!SMitem.Quantity__c}"/>
        </apex:pageBlockTable>
    </apex:pageBlock>
        </apex:tab>
         <apex:tab label="RIPL" name="name3" id="tabThree" styleClass="TSMactiveTab">
        <apex:pageBlock title="RIPL Subscription Items">
        <apex:pageBlockTable value="{!RIPLSubItems}" var="item2">
            <apex:column value="{!item2.Subscription_ID__c}"/>
            <apex:column value="{!item2.name}"/>
            <apex:column value="{!item2.Product__c}"/>
            <apex:column value="{!item2.Item_Status__c}"/>
            <apex:column value="{!item2.Quantity__c}"/>
        </apex:pageBlockTable>
    </apex:pageBlock>
        </apex:tab>
    </apex:tabPanel>
    </apex:pageBlock>
</apex:page>

Right now everything is showing green because I don't have it adjusting anything and I can move through the tabs and view the data.


Here is the page with a query I found but I modified for an onload function.
<apex:page standardController="Account" showHeader="true" extensions="TestDisplayQueryResults" >
    <html>
    <body onload="loading('tabOne'); loading('tabTwo'); loading('tabThree');">
    <style>
    .PCSTab {background-color: #4CAF50; color:white; background-image:none}
    .SMTab { background-color: #f44336; color:white; background-image:none}
    .RIPLTab { background-color: #ff9800; color:white; background-image:none}
    </style>  
    <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
    <script>
       if(jQuery) 
       {
            jQuery.noConflict();
       }  
    function loading(tabname)
    { 
        var tabname = '[id$='+tabname+'_lbl]';
        var tabname2 = '[id$='+tabname2+'_lbl]';
        var tabname3 = '[id$='+tabname3+'_lbl]';
        if(Account.TS_M_Status__c == "Active")
        {
            jquery(tabname).css({"background-color": "#4CAF50"; "color":"white"; "background-image":"none"});
        } 
        if(Account.TS_M_Status__c == "Not Active")
        {
            jquery(tabname).css({"background-color": "#ff9800"; "color":"white"; "background-image":"none"});
        }
        if(Account.TS_M_Status__c == "On Hold")
        {
            jquery(tabname).css({"background-color": "#f44336"; "color":"white"; "background-image":"none"});
        }
        if(Account.SM_Status__c == "Active")
        {
            jquery(tabname2).css({"background-color": "#4CAF50"; "color":"white"; "background-image":"none"});
        } 
        if(Account.SM_Status__c == "Not Active")
        {
            jquery(tabname2).css({"background-color": "#ff9800"; "color":"white"; "background-image":"none"});
        }
        if(Account.SM_Status__c == "On Hold")
        {
            jquery(tabname2).css({"background-color": "#f44336"; "color":"white"; "background-image":"none"});
        }
        if(Account.RIPL_TSM_Status__c == "Active")
        {
            jquery(tabname3).css({"background-color": "#4CAF50"; "color":"white"; "background-image":"none"});
        } 
        if(Account.RIPL_TSM_Status__c == "Not Active")
        {
            jquery(tabname3).css({"background-color": "#ff9800"; "color":"white"; "background-image":"none"});
        }
        if(Account.RIPL_TSM_Status__c == "On Hold")
        {
            jquery(tabname3).css({"background-color": "#f44336"; "color":"white"; "background-image":"none"});
        }
      }
        </script>
    <apex:pageBlock id="Block1">
    <apex:tabPanel switchType="client" selectedTab="name1" id="AccountTabPanel" >
        <apex:tab label="PCS" name="name1" id="tabOne" styleClass="PCSTab">
        <apex:pageBlock title="PCS Subscription Items">
        <apex:outputField value="{!Account.TS_M_Status__c}"/>
        <apex:pageBlockTable value="{!PCSSubItems}" var="item">
            <apex:column value="{!item.Subscription_ID__c}"/>
            <apex:column value="{!item.name}"/>
            <apex:column value="{!item.Product__c}"/>
            <apex:column value="{!item.Item_Status__c}"/>
            <apex:column value="{!item.Quantity__c}"/>
        </apex:pageBlockTable>
        </apex:pageBlock>
        </apex:tab>
        <apex:tab label="Survey Manager" name="name2" id="tabTwo" styleClass="SMTab">
        <apex:pageBlock title="Survey Manager Subscription Items">
        <apex:pageBlockTable value="{!SMSubItems}" var="SMitem">
            <apex:column value="{!SMitem.Subscription_ID__c}"/>
            <apex:column value="{!SMitem.name}"/>
            <apex:column value="{!SMitem.Product__c}"/>
            <apex:column value="{!SMitem.Item_Status__c}"/>
            <apex:column value="{!SMitem.Quantity__c}"/>
        </apex:pageBlockTable>
    </apex:pageBlock>
        </apex:tab>
         <apex:tab label="RIPL" name="name3" id="tabThree" styleClass="RIPLTab">
        <apex:pageBlock title="RIPL Subscription Items">
        <apex:pageBlockTable value="{!RIPLSubItems}" var="item2">
            <apex:column value="{!item2.Subscription_ID__c}"/>
            <apex:column value="{!item2.name}"/>
            <apex:column value="{!item2.Product__c}"/>
            <apex:column value="{!item2.Item_Status__c}"/>
            <apex:column value="{!item2.Quantity__c}"/>
        </apex:pageBlockTable>
    </apex:pageBlock>
        </apex:tab>
    </apex:tabPanel>
    </apex:pageBlock>
    </body>
    </html>
</apex:page>

With this, I adjusted the tab classes and the tabs are the colors in the tab class and won't adjust and the tabs are not responsive.

Also here is the extension
public with sharing class TestDisplayQueryResults
{
    public String currentRecordId {get;set;}
    public Account acc{get;set;}
    public List<Subscription__c> PCSSubs{get; set;}
    public List<Subscription__c> SMSubs{get; set;}
    public List<Subscription__c> RIPLSubs{get; set;}
    public List<Subscription_Item__c> PCSSubItems{get; set;}
    public List<Subscription_Item__c> SMSubItems{get; set;}
    public List<Subscription_Item__c> RIPLSubItems{get; set;}
    public TestDisplayQueryResults(ApexPages.StandardController controller) 
    {
        currentRecordId  = ApexPages.CurrentPage().getparameters().get('id');
        PCSSubItems = new List<Subscription_Item__c>();
        SMSubItems = new List<Subscription_Item__c>();
        RIPLSubItems = new List<Subscription_Item__c>();
        acc = [select id ,name from Account where id =: currentRecordId ];
        PCSSubs = [select id, Name, (Select id, name, Product_Code_PCS_TSM__c, product__c, Quantity__c, Item_Status__c, Subscription_ID__c from Subscription_Items__r where Product_Code_PCS_TSM__c = true) from Subscription__c where Account_ID__c = :acc.Id];
        SMSubs = [select id, Name, (Select id, name, Product_is_Survey_Manager__c, product__c, Quantity__c, Item_Status__c, Subscription_ID__c from Subscription_Items__r where Product_is_Survey_Manager__c = true) from Subscription__c where Account_ID__c = :acc.Id];
        RIPLSubs = [select id, Name, (Select id, name, Product_is_RIPL_TSM__c, product__c, Quantity__c, Item_Status__c, Subscription_ID__c from Subscription_Items__r where Product_is_RIPL_TSM__c = true) from Subscription__c where Account_ID__c = :acc.Id];
        for(Subscription__c PCSSubs : [select id, Name, (Select id, name, Product_Code_PCS_TSM__c, product__c, Quantity__c, Item_Status__c, Subscription_ID__c from Subscription_Items__r where Product_Code_PCS_TSM__c = true) from Subscription__c where Account_ID__c= :acc.Id])
        {
            for(Subscription_Item__c items: PCSSubs.Subscription_Items__r)
            {
                PCSSubItems.add(items);
            }
        }
        for(Subscription__c SMSubs : [select id, Name, (Select id, name, Product_is_Survey_Manager__c, product__c, Quantity__c, Item_Status__c, Subscription_ID__c from Subscription_Items__r where Product_is_Survey_Manager__c = true) from Subscription__c where Account_ID__c = :acc.Id])
        {
            for(Subscription_Item__c items: SMSubs.Subscription_Items__r)
            {
                SMSubItems.add(items);
            }
        }
        for(Subscription__c RIPLSubs : [select id, Name, (Select id, name, Product_is_RIPL_TSM__c, product__c, Quantity__c, Item_Status__c, Subscription_ID__c from Subscription_Items__r where Product_is_RIPL_TSM__c = true) from Subscription__c where Account_ID__c = :acc.Id])
        {
            for(Subscription_Item__c items: RIPLSubs.Subscription_Items__r)
            {
                RIPLSubItems.add(items);
            }
        }
    }
}


Any help would be appreciated!
 
Hey guys,

I am trying to get the related list from a related object on a visualforce page, the flow of the object relationship is:

Account> Subscription>Subscriptions Items

I'd like to display a related list of Subscription Items on the Account page that meet my soql query. When I add the page to the layout I get "Attempt to de-reference a null object"

Below is my code:

VF Page
<apex:page standardController="Account" showHeader="true" extensions="TestDisplayQueryResults">
    <!-- Define Tab panel .css styles -->
    <style>
    .activeTab {background-color: #236FBD; color:white; background-image:none}
    .inactiveTab { background-color: lightgrey; color:black; background-image:none}
    </style>
            
    <!-- Create Tab panel -->
    <apex:tabPanel switchType="client" selectedTab="name2" id="AccountTabPanel"
        tabClass="activeTab" inactiveTabClass="inactiveTab">
        <apex:tab label="Subscriptions" name="name1" id="tabOne">
        <apex:relatedList list="Subscriptions__r"/>
        </apex:tab>
        <apex:tab label="PCS" name="name2" id="tabTwo">
        <apex:pageBlock title="My Content">
        <apex:pageBlockTable value="{!SubItems}" var="item">
            <apex:column value="{!item.name}"/>
            <apex:column value="{!item.id}"/>
        </apex:pageBlockTable>
    </apex:pageBlock>

        </apex:tab>
    </apex:tabPanel>
</apex:page>

Extension:
 
public with sharing class TestDisplayQueryResults
{
    public String currentRecordId {get;set;}
    public Account acc{get;set;}
    public List<Subscription__c> Subs{get; set;}
    public List<Subscription_Item__c> SubItems{get; set;}
    public TestDisplayQueryResults(ApexPages.StandardController controller) 
    {
        currentRecordId  = ApexPages.CurrentPage().getparameters().get('id');
        acc = [select id ,name from Account where id =: currentRecordId ];
        Subs = [select id, Name, (Select id, name, Product_Code_PCS_TSM__c from Subscription_Items__r where Product_Code_PCS_TSM__c = true) from Subscription__c where Account_ID__c = :acc.Id];
        for(Subscription__c Subs : [select id, Name, (Select id, name, Product_Code_PCS_TSM__c from Subscription_Items__r where Product_Code_PCS_TSM__c = true) from Subscription__c where Account_ID__c= :acc.Id])
        {
            for(Subscription_Item__c items: Subs.Subscription_Items__r)
            {
                SubItems.add(items);
            }
        }
    }
}


 
I want to have a user's current omnichannel status on a visualforce page displayed as our servers kick users out of omnichannel and they don't realize so I would like to have their status always displayed.

I have this button that gets the status and alerts the status in an alert window but I just want the status to be displayed without them having to click the button.

Here is my code currently:
 
<apex:page>
    <apex:includeScript value="/support/console/45.0/integration.js"/>
    <a href="#" onClick="testGetStatusId();return false;">Get Omni-Channel Status</a>
    
    <script type="text/javascript">
        function testGetStatusId() {
            sforce.console.presence.getServicePresenceStatusId(function(result) {
                if (result.success) {
                    alert('Status is: ' + result.statusName);
                } else {
                    alert('Current Status is Offline');
                }
            });
        }
    </script>
</apex:page>

Can anyone tell me how to just return the status without clicking the button?
Hey All,

I'm trying to add a visualforce page component to a lightning record page, however whenever I do it has a white background with the visualforce page name as a header. Like seen below:

User-added image
Link to picture: http://prntscr.com/mde5b8

Here's the code associated with it:
<apex:page standardStylesheets="false" showHeader="false">
<style type="text/css">
        p { font-weight: bold; background-color: #FF0000;}
    </style>
    <center>
    <p>TECH SUPPORT AND MAINTENENCE IS CURRENTLY NOT ACTIVE</p>
    </center>
</apex:page>

I also tried some other code that I'd found on here but that didn't fix my issue either. It resulted in this:

User-added image
Link to picture: http://prntscr.com/mde88d

And here is the code for that:
<apex:page cache="true" standardController="Account" pageStyle="Acount">
<script>

function resizeFrame() {
var sframe = parent.document.getElementById("{!$Component.myPage}"); 

if ({!Account.Inactive__c} == "false")
{

sframe.style.height = "0px";
} else {

sframe.style.height = document.body.scrollHeight - 10 + "px";
}

}

</script>

<body onLoad="resizeFrame()">
<apex:pageBlock id="myPage" tabStyle="Account">

<style type="text/css">
        p { font-weight: bold; background-color: #FF0000;}
    </style>
    <center>
    <p>TECH SUPPORT AND MAINTENENCE IS CURRENTLY NOT ACTIVE</p>
    </center>

</apex:pageBlock>


</body>

</apex:page>

Any help would be appreciated.

Thanks,
Tyler​​​​​​​
I have some code for a page and I have it to where the submit button is greyed out if a checkbox is unchecked. However whenever you check the box it doesn't enable the submit button like i'm wanting. 

Here is my code 
<apex:page standardController="RMA__c">
    <apex:form >
        <apex:outputPanel id="thePanel" rendered="{!(RMA__c.RLI_has_QUOTE_SO__c == true)}">
        <apex:pageBlock title="Confirm Information" mode="edit">
            <apex:pageBlockSection title="Confirm the  new field values" columns="2" rendered="{!(RMA__c.Show_the_box__c == true)}">
                <apex:outputfield value="{!RMA__c.Contact__c}"/>
                <apex:outputfield value="{!RMA__c.Shipping_Priority__c}"/>
                <apex:outputfield value="{!RMA__c.Ship_to_Address__c}"/>
                <apex:outputfield value="{!RMA__c.Bill_to_Address__c}"/>
                <apex:inputfield value="{!RMA__c.Request_Priority__c}"/>
                <apex:inputField value="{!RMA__c.Changes_are_reviewed__c}"/>
            </apex:pageBlockSection>
            <apex:pageBlockButtons >
                <apex:commandButton action="{!save}" value="Submit" disabled="false" rendered="{!(RMA__c.Changes_are_reviewed__c == true)}"/>
                <apex:commandButton action="{!save}" value="Submit" disabled="true" rendered="{!(RMA__c.Changes_are_reviewed__c != true)}"/>
            </apex:pageBlockButtons>
        </apex:pageBlock>
        </apex:outputPanel>
    </apex:form>
</apex:page>

And here is the page:

User-added image​​​​​​​
I have created a Visualforce page on my custom object and it shows up fine, however I only want it to be displayed if a checkbox on the object is checked.

Here is my code
<apex:page standardController="RMA__C">
    <apex:form >
        <apex:pageBlock title="Update RMA" mode="edit">
            <apex:pageBlockSection title="Confirm Field Values" columns="2">
                <apex:outputfield value="{!RMA__c.Contact__c}"/>
                <apex:outputfield value="{!RMA__c.Request_Priority__c}"/>
                <apex:outputfield value="{!RMA__c.Ship_to_Address__c}"/>
                <apex:outputfield value="{!RMA__c.Bill_to_Address__c}"/>
                <apex:outputfield value="{!RMA__c.Shipping_Priority__c}"/>
                <apex:inputField value="{!RMA__c.Changes_have_been_review__c}"/>
            </apex:pageBlockSection>
            <apex:pageBlockButtons >
                <apex:commandButton action="{!save}" value="Submit"/>
            </apex:pageBlockButtons>
        </apex:pageBlock>
    </apex:form>
</apex:page>
And here is the API name for the Field: RMA__c.RLI_has_QUOTE_SO__c.
Any help would be appreciated.

Thanks in advance,
Tyler
I'm creating a visualforce page that displays data for confirmation when changes are made to a record and I wanted an email to be triggered when the changes are confirmed/ submitted. I added a picklist to the object and reference it in the page using

<td><apex:inputField value="{!RMA__c.Changes_have_been_review__c}"/>        
            </td>

It shows up fine and has the values from the picklist field but whenever you select your value and hit submit it doesn't update the objects field. 

Any help would be appreciated.

-Tyler
Hi...

Our student service department processes the student request through cases.
There are some requests that a payment is required. So, we associate Case with Order. One case can have one or more than one Orders.

REQUIREMENT:
The Case can only be closed when the Order(s) status is "Activated" 

QUESTION:
How can we aware of the user when she/he tries to close the Case that the Order(s) is not Activated yet?

We're thinking to develop the Case validation in the Trigger event (before update). How could we launch a pop up from the Trigger?

Thanks,
Pedro
 
I have a flow that allows a users to select custom products so they can update the records associated with the opportunity. I want my flow screen to show any existing value that is popletating the field from the record. The screenshot below is the price field on the product record. Though I that field has a value, It does not populate on my flow screen.  How can I show that value in the feild so the user can see it from the flow screen. 

User-added image
  • April 05, 2019
  • Like
  • 0
All it says is to post to the community.  Would really like to get past this & move on in training 

Challenge Not yet complete... here's what's wrong: 
There was an unexpected error while verifying this challenge. Usually this is due to some pre-existing configuration or code in the challenge Org. We recommend using a new Developer Edition (DE) to check this challenge. If you're using a new DE and seeing this error, please post to the developer forums and reference error id: HUHTSAQP
Hi all, 
so on click of the "Create New Matrix" button, I need my modal to appear
Usually I do an aura:if, but I don't think that would work for this case

<div class="slds-align_absolute-center slds-m-around_small">
        <lightning:button variant="brand" disabled="{!!v.hasMtxSelected}" label="Add" title="Add" onclick="{! c.doAddCandidateToMatrix }" />
        <lightning:button variant="brand" label="Create New Matrix" title="Create New Matrix" onclick="{! c.doCreate }" />
        <lightning:button variant="brand" label="Cancel" title="Cancel" onclick="{! c.doCancel }" />
    </div>
    
    <!-- Deja B.-->   
    <!--SLIDE 6 on Wireframe-->
    
       <!-- <lightning:button variant="brand" label="Create New Matrix"  --> }" 
        <div aura:id="CreateMatrixModalState" onclick="{!v.displayCreateMatrixModalState}">
            <section role="dialog" tabindex="-1" aria-labelledby="modal-heading-01" aria-modal="true"
                     aria-describedby="modal-content-id-1" class="slds-modal slds-fade-in-open">
                <div class="slds-modal__container">
                    <header class="slds-modal__header">
                        <lightning:buttonIcon iconName="utility:close"
                                              onclick="{! c.doShowHideCreateMatrixModalState }" alternativeText="close"
                                              variant="bare-inverse" class="slds-modal__close" />
                        <h2 id="modal-heading-01" class="slds-text-heading_medium slds-hyphenate">
                            New Matrix Information</h2>
                    </header>
                    <div class="slds-modal__content slds-p-around_medium" id="modal-content-id-1">
                        <lightning:input aura:id="matrixName" name="Matrix Name" maxlength="80"
                                         label="Matrix Name" placeholder="Matrix Name" />
                        <aura:if isTrue="{!not(empty(v.inputError))}">
                            {!v.inputError}
                        </aura:if>
                    </div>
                    <footer class="slds-modal__footer">
                        
                        <button class="slds-button slds-button_brand"
                                onclick="{!c.doBack}">{!$Label.c.Back}</button>
                        
                        <!--Using doCreate as defined above-->
                        <button class="slds-button slds-button_brand" 
                                onclick="{!c.doCreate}">{!$Label.c.Create_New_Matrix_State}</button>
                        
                        <button class="slds-button slds-button_neutral"
                                onclick="{!c.doShowHideCreateMatrixModalState}">{!$Label.c.Cancel}</button>
                    </footer>
                </div>
            </section>
            <div class="slds-backdrop slds-backdrop_open"></div>
        </div>

Hence, when this button is clicked Create New Matrix
User-added image
This modal appears, 
User-added imageI think my onclicks are off because the modal appears without me clicking the button
 
I have a new flow where i launch from an opportunity to update selected custom object related records. The opportunity is a master detail relationship with the custom object.  when i click the select custom button on the opportunity instead of just getting the related records to the opportunity I get all records to that custom object. I've tried everything i can think of with this flow to only retrieve the relate records but nothing seems to work. below is a screenshot of my record choice set. Any help with this would be greatly appreciated.

User-added image
  • March 11, 2019
  • Like
  • 0
Hi Every one,

May i know about <apex:inlineedit support> 
where it is  used and why it is used .

if you know any one about it please tell me

Thank you
surenyder redd
How can I add a functionality on the Service Console allowing Service Reps to easily set their Status (Available to work, Break, Lunch, etc..) so that:
  1. A System Admin can setup Case Assignment (Assign Cases to Users ONLY if their Status == Available to Work);
  2. Report on Time Spent by each Sales Rep on each Status;
The Product Owner is asking for a Button or field or some kind of functionality to let Sales Rep easily indicate their Status when from the Service Console.

In another hand, I have seen that the "Live Agent" functionality offers a little window where is it possible for the Agent to set his/her availability (as in the screenshot).Live Agent window on Service Cloud

Should I think of adding a picklist field somewhere on the Service Console? (How?)

 
  • March 08, 2019
  • Like
  • 0
Is there a way to query all cases in an org using SOQL to see if there is a case with a specific order number particular to our business that has been submitted already?
I created a Visualforce page and Apex controller to clone a record. What I need now is to have the Save and Cancel button redirect back to the originating record. I have no experience with Apex or VF and was able to create this with the help of this developer forum. Can anyone help me with what code to add and where to put it, to get the Save Button and Cancel Button to redirect back to the original record? 

Here's the vf page code: 

<apex:page standardController="OpportunityLineItem" extensions="customcloneOpportunityLineItem">
<apex:form >
<apex:pageBlock title="Opportunity Product details">
<apex:pageBlockSection title="Opportunity Prodcut Edit" columns="1">
<apex:inputfield value="{!OpportunityLineItem.OpportunityId}"/>
<apex:inputField value="{!OpportunityLineItem.Product2Id}" />
<apex:inputField value="{!OpportunityLineItem.Quantity}" />
<apex:inputField value="{!OpportunityLineItem.Unit_List_Price__c}" />
<apex:inputfield value="{!OpportunityLineItem.Unit_Sales_Price__c}"/>
<apex:inputfield value="{!OpportunityLineItem.Unit_Cost__c}"/>
<apex:inputfield value="{!OpportunityLineItem.ProductCode}"/>
<apex:inputfield value="{!OpportunityLineItem.Product_Family__c}"/>
</apex:pageBlockSection>
<apex:pageBlockButtons >
<apex:commandButton action="{!cloneopportunitylineitem}" value="Save" />
<apex:commandButton action="{!cloneopportunitylineitem}" value="Cancel" />
</apex:pageBlockButtons>
        </apex:pageBlock>
</apex:form>
</apex:page>

Here's the Apex Class: 

public class customcloneOpportunityLineItem
{private opportunitylineitem l;
public customcloneOpportunityLineItem(apexpages.standardcontroller std){
this.l = (opportunitylineitem)std.getrecord();
}

public void cloneOpportunityLineItem(){
opportunitylineitem l1 = new OpportunityLineItem();
l1 =l.clone();
insert l1; 
}
}