how to delete a entire row in readOnly grid?

Certified Associate Developer

how to delete a entire row in readonly grid?

  Discussion posts and replies are publicly visible

Parents Reply Children
  • 0
    Certified Senior Developer
    in reply to krishnav9816

    to delete from DB you have to use it's identifier which is a primary key.

    a!richTextIcon(
                      icon: "times",
                      color: "NEGATIVE",
                      link: a!dynamicLink(
                        saveInto: {
                          a!deleteFromDataStoreEntities(
                            dataToDelete: {
                              a!entityDataIdentifiers(
                                entity: cons!CDU_CAR_ITEM_DETAILS,
                                identifiers: fv!item.id /*Your primary key value by using fv!identifier in case of gridfield and fv!item.{primarykeyname} in case of gridLayout*/
                              )
                            }
                          ),
                          a!save(
                            ri!itemDetails, /*actual array from where we have to remove*/
                            remove(
                              ri!itemDetails,
                              fv!index
                            )
                          )
                        }
                      )
                    )