• Sourav Pradhan 3
  • NEWBIE
  • 0 Points
  • Member since 2021

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 3
    Questions
  • 0
    Replies
After the summer 21 release, I'm getting this error.

Please resolve and thanks in advanceUser-added image
lightning-datatable is known to have issues on mobile devices. Consider these options: • Find a mobile-ready replacement in the Component Reference of the Lightning Web Components Dev Guide. Filter the list using "Salesforce Mobile App" as the target. 
thirdParty.apxc
============
@RestResource(urlMapping='/v1/GetAccount/')
 global with sharing class thirdParty {
     @HttpGet
     global static Case__c getCaseById() {
          Case__c acc=new Case__c();
      Map <String,String> mapparam= RestContext.request.params;
        String dataId=mapparam.get('Id');
        acc=[SELECT Date__c,Case_Origin__c,Case_Reason__c,Case_Status__c,Name,Products__c,Subject__c FROM Case__c WHERE Id = :dataId];
         return acc;
     }
     @HttpPost
    global static Case__c addAccount(String origin,String reason,String status,String product,String subject,string cus){
        Case__c acc=new Case__c(Case_Origin__c=origin, 
                             Case_Reason__c=reason,
                             Case_Status__c=status,
                             Products__c=product,
                             Subject__c=subject,
                             Customer_Name__c= cus );
        insert acc;
        return acc;
    }
}

thirdPartyTest.apxc
==================
@istest
public class thirdPartyTest{
 @isTest 
   static void getCaseById() {
        //Id recordId = createTestRecord();
        RestRequest request = new RestRequest();
        request.requestUri =
            'https://yourInstance.salesforce.com/services/apexrest/Cases/'
            ;
        request.httpMethod = 'GET';
        RestContext.request = request;
        
        Case__c thisCase = thirdParty.getCaseById();
        
        System.assert(thisCase != null);
        System.assertEquals('Test record', thisCase.Subject__c);
        
    }
       @isTest 
   static void addAccount() {
        
        thirdParty.addAccount(
            'Web', 'Damage', 'Approved', 'Yamaha Fascino 125','Damage Issue','a005g00002t5vqdAAA');
       
        //System.assert(thisCaseId != null);
        Case__c thisCase = [SELECT Id,Subject__c FROM Case__c ];
        System.assert(thisCase != null);
        System.assertEquals(thisCase.Subject__c, 'Damage Issue');
    }
}User-added image
This page has an error. You might just need to refresh it. First, would you giveUser-added image us some details? (We're reporting this as error ID: -1284455686)