We have added a button to the Orders table grid and want to change button label dynamically based on order status.
- Insert button into grid and switch to HTML mode. Here is how button's HTML code look by default
<A class="rnr-button button" id="New_Button3" href="#" typeid="ib">
New_Button3
</A>
2. Modify it the following way
<A class="rnr-button button" id="New_Button3" href="#" typeid="ib">
{$button_label}
</A>
3. Now add the following code to List page: AfterRecordProcessed event:
if ($data["ShipCountry"]=="Germany")
$record["button_label"] = "Senden bestellen";
else
$record["button_label"] = "Archive order";
And this is how it looks in generated application: