{if !empty($result.attempted)} {* * Action is performed: hide dialog and modify products in the list *} {else} {* * Show dialog *} {/if}