Is lightning:recordForm is supporting for custom settings?

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP





.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty margin-bottom:0;







up vote
2
down vote

favorite












I need to create a lightning component to Edit a particular Custom settings Record using the lightning:recordForm. But I couldn't able to achieve it and got the following error. I will share my code below,



The Error I got when I click SAVE button



Component:



<aura:component description="EL_Error_Log_Settings">
<aura:attribute name="recordId" type="String" description="The Settings Id" deafult='a073E000005bZ5d'/>
<aura:attribute name="fieldsArray" type="String" default="['Error_Log_Activated__c','Error_Log_Include_Executing_User__c','Error_Log_Recipients__c','Error_Log_Send_Notification_Email__c','Error_Log_Storage_Duration__c']"/>

<aura:handler name="init" value="!this" action="!c.handleInit" />

<lightning:card iconName="custom:custom19" title="Edit lightning:recordForm">
<div class="slds-p-left_large slds-p-right_medium">
<lightning:recordForm aura:id="recordViewForm"
objectApiName="Sample__Settings__c"
columns="2"
fields="!v.fieldsArray"
recordId="!v.recordId"
mode="Edit"
onsuccess="!c.onSuccess"
onsubmit="!c.onSubmit"
onload="!c.onLoad"
onerror="!c.onError"
/>

</div>
</lightning:card>


<soco:EL_Configuration_Service aura:id="ErrorLogService" />
</aura:component>


Controller:



(
handleInit : function(cmp, event, helper)
helper.getSampleSettings(cmp, event, helper);
,

onSuccess : function(component, event, helper)
var toastEvent = $A.get("e.force:showToast");
toastEvent.setParams(
"title": "Success!",
"message": "The record has been Saved successfully."
);
toastEvent.fire();
,

onSubmit : function(component, event, helper)
,

onLoad : function(component, event, helper)
var toastEvent = $A.get("e.force:showToast");
toastEvent.setParams(
"title": "Loaded!",
"message": "The record has been Loaded successfully ."
);
toastEvent.fire();
,

onError : function(component, event, helper)
var toastEvent = $A.get("e.force:showToast");
toastEvent.setParams(
"title": "Error!",
"message": "Error."
);
toastEvent.fire();

)


helper



(
getSampleSettings : function(cmp, event, helper)
var service = cmp.find("ErrorLogService");
service.getCustomSetting().then($A.getCallback(function(response)
var responses = response.Error_Log_Activated__c;
alert(responses);
var recordId = response.Id;
alert(recordId);
cmp.set("v.recordId", recordId);
)
);

)


Please give any suggestions to overcome this issue.










share|improve this question







New contributor




Hariprasath is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.

























    up vote
    2
    down vote

    favorite












    I need to create a lightning component to Edit a particular Custom settings Record using the lightning:recordForm. But I couldn't able to achieve it and got the following error. I will share my code below,



    The Error I got when I click SAVE button



    Component:



    <aura:component description="EL_Error_Log_Settings">
    <aura:attribute name="recordId" type="String" description="The Settings Id" deafult='a073E000005bZ5d'/>
    <aura:attribute name="fieldsArray" type="String" default="['Error_Log_Activated__c','Error_Log_Include_Executing_User__c','Error_Log_Recipients__c','Error_Log_Send_Notification_Email__c','Error_Log_Storage_Duration__c']"/>

    <aura:handler name="init" value="!this" action="!c.handleInit" />

    <lightning:card iconName="custom:custom19" title="Edit lightning:recordForm">
    <div class="slds-p-left_large slds-p-right_medium">
    <lightning:recordForm aura:id="recordViewForm"
    objectApiName="Sample__Settings__c"
    columns="2"
    fields="!v.fieldsArray"
    recordId="!v.recordId"
    mode="Edit"
    onsuccess="!c.onSuccess"
    onsubmit="!c.onSubmit"
    onload="!c.onLoad"
    onerror="!c.onError"
    />

    </div>
    </lightning:card>


    <soco:EL_Configuration_Service aura:id="ErrorLogService" />
    </aura:component>


    Controller:



    (
    handleInit : function(cmp, event, helper)
    helper.getSampleSettings(cmp, event, helper);
    ,

    onSuccess : function(component, event, helper)
    var toastEvent = $A.get("e.force:showToast");
    toastEvent.setParams(
    "title": "Success!",
    "message": "The record has been Saved successfully."
    );
    toastEvent.fire();
    ,

    onSubmit : function(component, event, helper)
    ,

    onLoad : function(component, event, helper)
    var toastEvent = $A.get("e.force:showToast");
    toastEvent.setParams(
    "title": "Loaded!",
    "message": "The record has been Loaded successfully ."
    );
    toastEvent.fire();
    ,

    onError : function(component, event, helper)
    var toastEvent = $A.get("e.force:showToast");
    toastEvent.setParams(
    "title": "Error!",
    "message": "Error."
    );
    toastEvent.fire();

    )


    helper



    (
    getSampleSettings : function(cmp, event, helper)
    var service = cmp.find("ErrorLogService");
    service.getCustomSetting().then($A.getCallback(function(response)
    var responses = response.Error_Log_Activated__c;
    alert(responses);
    var recordId = response.Id;
    alert(recordId);
    cmp.set("v.recordId", recordId);
    )
    );

    )


    Please give any suggestions to overcome this issue.










    share|improve this question







    New contributor




    Hariprasath is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
    Check out our Code of Conduct.





















      up vote
      2
      down vote

      favorite









      up vote
      2
      down vote

      favorite











      I need to create a lightning component to Edit a particular Custom settings Record using the lightning:recordForm. But I couldn't able to achieve it and got the following error. I will share my code below,



      The Error I got when I click SAVE button



      Component:



      <aura:component description="EL_Error_Log_Settings">
      <aura:attribute name="recordId" type="String" description="The Settings Id" deafult='a073E000005bZ5d'/>
      <aura:attribute name="fieldsArray" type="String" default="['Error_Log_Activated__c','Error_Log_Include_Executing_User__c','Error_Log_Recipients__c','Error_Log_Send_Notification_Email__c','Error_Log_Storage_Duration__c']"/>

      <aura:handler name="init" value="!this" action="!c.handleInit" />

      <lightning:card iconName="custom:custom19" title="Edit lightning:recordForm">
      <div class="slds-p-left_large slds-p-right_medium">
      <lightning:recordForm aura:id="recordViewForm"
      objectApiName="Sample__Settings__c"
      columns="2"
      fields="!v.fieldsArray"
      recordId="!v.recordId"
      mode="Edit"
      onsuccess="!c.onSuccess"
      onsubmit="!c.onSubmit"
      onload="!c.onLoad"
      onerror="!c.onError"
      />

      </div>
      </lightning:card>


      <soco:EL_Configuration_Service aura:id="ErrorLogService" />
      </aura:component>


      Controller:



      (
      handleInit : function(cmp, event, helper)
      helper.getSampleSettings(cmp, event, helper);
      ,

      onSuccess : function(component, event, helper)
      var toastEvent = $A.get("e.force:showToast");
      toastEvent.setParams(
      "title": "Success!",
      "message": "The record has been Saved successfully."
      );
      toastEvent.fire();
      ,

      onSubmit : function(component, event, helper)
      ,

      onLoad : function(component, event, helper)
      var toastEvent = $A.get("e.force:showToast");
      toastEvent.setParams(
      "title": "Loaded!",
      "message": "The record has been Loaded successfully ."
      );
      toastEvent.fire();
      ,

      onError : function(component, event, helper)
      var toastEvent = $A.get("e.force:showToast");
      toastEvent.setParams(
      "title": "Error!",
      "message": "Error."
      );
      toastEvent.fire();

      )


      helper



      (
      getSampleSettings : function(cmp, event, helper)
      var service = cmp.find("ErrorLogService");
      service.getCustomSetting().then($A.getCallback(function(response)
      var responses = response.Error_Log_Activated__c;
      alert(responses);
      var recordId = response.Id;
      alert(recordId);
      cmp.set("v.recordId", recordId);
      )
      );

      )


      Please give any suggestions to overcome this issue.










      share|improve this question







      New contributor




      Hariprasath is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.











      I need to create a lightning component to Edit a particular Custom settings Record using the lightning:recordForm. But I couldn't able to achieve it and got the following error. I will share my code below,



      The Error I got when I click SAVE button



      Component:



      <aura:component description="EL_Error_Log_Settings">
      <aura:attribute name="recordId" type="String" description="The Settings Id" deafult='a073E000005bZ5d'/>
      <aura:attribute name="fieldsArray" type="String" default="['Error_Log_Activated__c','Error_Log_Include_Executing_User__c','Error_Log_Recipients__c','Error_Log_Send_Notification_Email__c','Error_Log_Storage_Duration__c']"/>

      <aura:handler name="init" value="!this" action="!c.handleInit" />

      <lightning:card iconName="custom:custom19" title="Edit lightning:recordForm">
      <div class="slds-p-left_large slds-p-right_medium">
      <lightning:recordForm aura:id="recordViewForm"
      objectApiName="Sample__Settings__c"
      columns="2"
      fields="!v.fieldsArray"
      recordId="!v.recordId"
      mode="Edit"
      onsuccess="!c.onSuccess"
      onsubmit="!c.onSubmit"
      onload="!c.onLoad"
      onerror="!c.onError"
      />

      </div>
      </lightning:card>


      <soco:EL_Configuration_Service aura:id="ErrorLogService" />
      </aura:component>


      Controller:



      (
      handleInit : function(cmp, event, helper)
      helper.getSampleSettings(cmp, event, helper);
      ,

      onSuccess : function(component, event, helper)
      var toastEvent = $A.get("e.force:showToast");
      toastEvent.setParams(
      "title": "Success!",
      "message": "The record has been Saved successfully."
      );
      toastEvent.fire();
      ,

      onSubmit : function(component, event, helper)
      ,

      onLoad : function(component, event, helper)
      var toastEvent = $A.get("e.force:showToast");
      toastEvent.setParams(
      "title": "Loaded!",
      "message": "The record has been Loaded successfully ."
      );
      toastEvent.fire();
      ,

      onError : function(component, event, helper)
      var toastEvent = $A.get("e.force:showToast");
      toastEvent.setParams(
      "title": "Error!",
      "message": "Error."
      );
      toastEvent.fire();

      )


      helper



      (
      getSampleSettings : function(cmp, event, helper)
      var service = cmp.find("ErrorLogService");
      service.getCustomSetting().then($A.getCallback(function(response)
      var responses = response.Error_Log_Activated__c;
      alert(responses);
      var recordId = response.Id;
      alert(recordId);
      cmp.set("v.recordId", recordId);
      )
      );

      )


      Please give any suggestions to overcome this issue.







      lightning lightning-record-form






      share|improve this question







      New contributor




      Hariprasath is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.











      share|improve this question







      New contributor




      Hariprasath is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.









      share|improve this question




      share|improve this question






      New contributor




      Hariprasath is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.









      asked 24 mins ago









      Hariprasath

      1134




      1134




      New contributor




      Hariprasath is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.





      New contributor





      Hariprasath is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.






      Hariprasath is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.




















          1 Answer
          1






          active

          oldest

          votes

















          up vote
          4
          down vote



          accepted










          From official documentation




          Supported Objects



          This component doesn't support all Salesforce
          standard objects. For example, the Event and Task objects are not
          supported.



          For a list of supported objects, see the User Interface API Developer
          Guide.




          and reading Supported Objects article:




          User Interface API supports all custom objects and many standard
          objects.




          So answer is: no, lightning:recordForm dosn't support custom settings






          share|improve this answer




















          • Yeah correct and got it. Is there any other way to edit a custom settings using predefined lightning component or we need to do this manually?
            – Hariprasath
            14 mins ago






          • 1




            @Hariprasath as far as I know, the only option for now is to develop such component manually.
            – Alexander Berehovskiy
            11 mins ago










          Your Answer







          StackExchange.ready(function()
          var channelOptions =
          tags: "".split(" "),
          id: "459"
          ;
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function()
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled)
          StackExchange.using("snippets", function()
          createEditor();
          );

          else
          createEditor();

          );

          function createEditor()
          StackExchange.prepareEditor(
          heartbeatType: 'answer',
          convertImagesToLinks: false,
          noModals: false,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: null,
          bindNavPrevention: true,
          postfix: "",
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          );



          );






          Hariprasath is a new contributor. Be nice, and check out our Code of Conduct.









           

          draft saved


          draft discarded


















          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsalesforce.stackexchange.com%2fquestions%2f232895%2fis-lightningrecordform-is-supporting-for-custom-settings%23new-answer', 'question_page');

          );

          Post as a guest






























          1 Answer
          1






          active

          oldest

          votes








          1 Answer
          1






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes








          up vote
          4
          down vote



          accepted










          From official documentation




          Supported Objects



          This component doesn't support all Salesforce
          standard objects. For example, the Event and Task objects are not
          supported.



          For a list of supported objects, see the User Interface API Developer
          Guide.




          and reading Supported Objects article:




          User Interface API supports all custom objects and many standard
          objects.




          So answer is: no, lightning:recordForm dosn't support custom settings






          share|improve this answer




















          • Yeah correct and got it. Is there any other way to edit a custom settings using predefined lightning component or we need to do this manually?
            – Hariprasath
            14 mins ago






          • 1




            @Hariprasath as far as I know, the only option for now is to develop such component manually.
            – Alexander Berehovskiy
            11 mins ago














          up vote
          4
          down vote



          accepted










          From official documentation




          Supported Objects



          This component doesn't support all Salesforce
          standard objects. For example, the Event and Task objects are not
          supported.



          For a list of supported objects, see the User Interface API Developer
          Guide.




          and reading Supported Objects article:




          User Interface API supports all custom objects and many standard
          objects.




          So answer is: no, lightning:recordForm dosn't support custom settings






          share|improve this answer




















          • Yeah correct and got it. Is there any other way to edit a custom settings using predefined lightning component or we need to do this manually?
            – Hariprasath
            14 mins ago






          • 1




            @Hariprasath as far as I know, the only option for now is to develop such component manually.
            – Alexander Berehovskiy
            11 mins ago












          up vote
          4
          down vote



          accepted







          up vote
          4
          down vote



          accepted






          From official documentation




          Supported Objects



          This component doesn't support all Salesforce
          standard objects. For example, the Event and Task objects are not
          supported.



          For a list of supported objects, see the User Interface API Developer
          Guide.




          and reading Supported Objects article:




          User Interface API supports all custom objects and many standard
          objects.




          So answer is: no, lightning:recordForm dosn't support custom settings






          share|improve this answer












          From official documentation




          Supported Objects



          This component doesn't support all Salesforce
          standard objects. For example, the Event and Task objects are not
          supported.



          For a list of supported objects, see the User Interface API Developer
          Guide.




          and reading Supported Objects article:




          User Interface API supports all custom objects and many standard
          objects.




          So answer is: no, lightning:recordForm dosn't support custom settings







          share|improve this answer












          share|improve this answer



          share|improve this answer










          answered 19 mins ago









          Alexander Berehovskiy

          6,07111532




          6,07111532











          • Yeah correct and got it. Is there any other way to edit a custom settings using predefined lightning component or we need to do this manually?
            – Hariprasath
            14 mins ago






          • 1




            @Hariprasath as far as I know, the only option for now is to develop such component manually.
            – Alexander Berehovskiy
            11 mins ago
















          • Yeah correct and got it. Is there any other way to edit a custom settings using predefined lightning component or we need to do this manually?
            – Hariprasath
            14 mins ago






          • 1




            @Hariprasath as far as I know, the only option for now is to develop such component manually.
            – Alexander Berehovskiy
            11 mins ago















          Yeah correct and got it. Is there any other way to edit a custom settings using predefined lightning component or we need to do this manually?
          – Hariprasath
          14 mins ago




          Yeah correct and got it. Is there any other way to edit a custom settings using predefined lightning component or we need to do this manually?
          – Hariprasath
          14 mins ago




          1




          1




          @Hariprasath as far as I know, the only option for now is to develop such component manually.
          – Alexander Berehovskiy
          11 mins ago




          @Hariprasath as far as I know, the only option for now is to develop such component manually.
          – Alexander Berehovskiy
          11 mins ago










          Hariprasath is a new contributor. Be nice, and check out our Code of Conduct.









           

          draft saved


          draft discarded


















          Hariprasath is a new contributor. Be nice, and check out our Code of Conduct.












          Hariprasath is a new contributor. Be nice, and check out our Code of Conduct.











          Hariprasath is a new contributor. Be nice, and check out our Code of Conduct.













           


          draft saved


          draft discarded














          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsalesforce.stackexchange.com%2fquestions%2f232895%2fis-lightningrecordform-is-supporting-for-custom-settings%23new-answer', 'question_page');

          );

          Post as a guest













































































          Comments

          Popular posts from this blog

          What does second last employer means? [closed]

          List of Gilmore Girls characters

          One-line joke