1

This is my HTML code, pressing the update button does not register any error and the data shown are the old ones. Any ideas why it would not work? A few days ago it worked without problems.

                        <lightning-record-edit-form record-id={recordId}
                                object-api-name="DCABM_obj_sol__c">
                                <lightning-messages>
                                </lightning-messages>
                                <div class="slds-grid slds-gutters">
                                    <div class="slds-col">
                                        <lightning-input-field
                                            field-name="DCABM_fld_name__c">
                                        </lightning-input-field>
                                    </div>
                                    <div class="slds-col">
                                        <lightning-input-field
                                            field-name="DCABM_fld_sName__c">
                                        </lightning-input-field>
                                    </div>
                                </div>
                                <div class="slds-grid slds-gutters">
                                    <div class="slds-col">
                                        <lightning-input-field
                                            field-name="DCABM_fld_email__c">
                                        </lightning-input-field>
                                    </div>
                                    <div class="slds-col">
                                        <lightning-input-field
                                            field-name="DCABM_fld_user__c">
                                        </lightning-input-field>
                                    </div>
                                </div>
                                <div class="slds-align_absolute-center">
                                    <lightning-button
                                        class="slds-m-top_small
                                        slds-p-right_xx-small"
                                        onclick={handleControllerChanges}
                                        variant="neutral"
                                        name="cancel"
                                        label="cancel">
                                    </lightning-button>
                                    <lightning-button
                                        class="slds-m-top_small
                                        slds-p-left_xx-small"
                                        onclick={updateUserData}
                                        variant="brand"
                                        type="submit"
                                        name="update"
                                        label="update">
                                    </lightning-button>
                                </div>
                            </lightning-record-edit-form>
  • can you add your Javascipt code? – Pranay Jaiswal Jun 25 '19 at 16:08
  • You don't need JS code, it's lightning data @PranayJaiswal – Alex M. Jun 25 '19 at 16:59
  • i think he refers especially to updateUserData (but also other potential clashes in e. g. hooks) - submit type is already invoking an action but you have a handler on top – Renji-xD Jun 26 '19 at 11:20
  • Ah, updateUserData is just an dispatchEvent @Renji-xD – Alex M. Jun 26 '19 at 11:49
  • maybe check the developer tools and see if you discover sth. in the actual network request / response or enable to pause on exceptions and see if sth is thrown somewhere. Otherwise If you are saying you have nothing special in your controller i think you have to request sfdc for support as nobody here has your object / user / permissions etc. to give much more hints - your shared code looks fine and therefore its hard for externals to comment on it – Renji-xD Jun 26 '19 at 13:26
0

Deleting the "onclick" event of the "submit" button it's works perfectly

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.