Skip to content

Instantly share code, notes, and snippets.

@kallepersson
Created June 29, 2012 17:36
Show Gist options
  • Save kallepersson/3019490 to your computer and use it in GitHub Desktop.
Save kallepersson/3019490 to your computer and use it in GitHub Desktop.
<table>
<tr>
<th><strong>Abonnemang</strong></th>
<th></th>
</tr>
<?
foreach($model->rules as $rule) {
echo '<tr>';
echo '<td>'.$rule->operator.' '.$rule->group_name.'</td>';
if(!$model->isUsedInOrder()) {
echo '<td>'.CHtml::ajaxLink(
'<i class="icon-remove"></i>',
array(
"packSubscriptionRule/delete",
'id' => $rule->id,
'rule_id' => $model->id),
array(
'type' => "POST",
"update" => '#PackSubscriptionRulePreview',
'data' => ''
),
array(
'live' => false,
'id' => 'rule'.$rule->id
)
).'</td>';
} else {
echo '<td></td>';
}
echo '</tr>';
}
?>
</table>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment