Locking a portal is not handled on the portal's own definition - it's handled in the position script of the layout that places that portal on the tab.
This is what I was trying to direct you to earlier:
Code:
<layout
id="abilities">
<portalref portal="abAbility" taborder="10"/>
<!-- This script sizes and positions the layout and its child visual elements. -->
<position><![CDATA[
~freeze our table in advancement mode to disable adding new choices
~Note: All freezing must be done *before* any positioning is performed.
if (state.iscreate = 0) then
portal[abAbility].freeze = 1
endif