Expand my Community achievements bar.

AEM preventing deletion of first row in form

Avatar

Level 1

We've just picked up an AEM implementation from another shop and came across this issue, which appears the original developers never tried to solve.  For some reason we're unable to remove first rows on AEM forms.

We did a bit of debugging and it turns out the  javascript code doing the event handling is actively preventing first rows from being removed.  The file that's doing is is called guideRuntime.min.js. So yeah, we're trying to understand why the odd behaviour.

 

I'll add more info to this ticket as I try to get all the deets about our AEM implementation (sorry not an AEM developer here). 

 

Hope anyone out there can give us some guidance!

 

4 Replies

Avatar

Employee Advisor

I was able to delete the roes using the UI 

when you add a table to the form you get header row and 2 rows which can be deleted using the UI

Avatar

Community Advisor

Your developer might have set the minCount to 1 for the table, if they set it to 0, they will be able to delete it.

Avatar

Level 1

Sorry for the late reply.
thanks for your suggestion. I'm looking at the table and there aren't any rules applied to it, or settings that might indicate the first row can't be deleted or something.

The only thing I can see, which I don't know what it is, is  a "SOM Expression" 

DoNotRemove_0-1685916884496.png
Even on edit mode, the moment the table renders (which is driven by the radio button above it) the first row gets added automatically

DoNotRemove_1-1685916979644.png

Here's the delete button click event

DoNotRemove_2-1685917073463.png

 

is there anywhere else that could be enforcing this behaviour?

 

Avatar

Level 1

I thought I'd add the code that's preventing the deletion. I can't find anything about that guideRuntime file. I was hoping it was some third party jquery plugging that we could update but can't find it anywhere.  The file does have some specific AEM wording so I guess it's just a "system file".   
The AEM version we got is 6.5. SP15

DoNotRemove_0-1685919244051.png