0

I am trying to understand why the ownerid field shows up as an uneditable field

<lightning:recordEditForm aura:id="recordViewForm" 
                                  objectApiName="Case"
                              recordId="{!v.simpleRecord.Id}" >
    <div class="Record Details">
        <lightning:card iconName="action:edit" title="Reassign Case" >
            <lightning:messages aura:id="inputFormMessages" />
            <div class="slds-p-horizontal--small">
                <lightning:inputField aura:id="caseLookup" fieldName="OwnerId" disabled="false" />
                <lightning:textarea aura:id="internalComments" label="Internal Comments" value="{!v.internalComments}" required="true" />
               <br/>
                <lightning:button label="Save Case 4" variant="brand" onclick="{!c.handleSaveRecord}" />
            </div>
        </lightning:card>
    </div>
    </lightning:recordEditForm> 

enter image description here

3

OwnerId is not supported in lightning:inputField. Refer to the excerpt below from documentation:

Lookup: Displays an input field for creating a relationship between two objects, for example, the account associated to a contact record. The lookup type is supported in Lightning Experience only. Mobile lookups are not supported. When used in the mobile app, the lookup type is rendered as an input text field. The Owner, CreatedBy, and LastModifiedBy fields are not supported for lookups.

  • Thanks > Jayant Das. Could you please suggest any workaround I could try? – amol kulkarni Oct 6 '18 at 19:50
  • I could only think to use those fields as text with lightning:input instead. You will need to try that out to see if that serves your use case. – Jayant Das Oct 7 '18 at 3:15

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.