$row = this.first().closest('.crm-entity');
ret.entity = $row.data('entity') || $row[0].id.split('-')[0];
ret.id = $row.data('id') || $row[0].id.split('-')[1];
- ret.action = $row.attr('data-entity-action') || 'setvalue';
+ ret.action = $row.data('action') || 'setvalue';
if (!ret.entity || !ret.id) {
return false;
field: info.field,
value: checked ? 1 : 0
};
- CRM.api(info.entity, 'setvalue', params, {
+ CRM.api(info.entity, info.action, params, {
context: this,
error: function(data) {
editableSettings.error.call(this, info.entity, info.field, checked, data);
var
info = $i.crmEditableEntity(),
params = {},
- action = $i.data('action') || 'setvalue';
+ action = $i.data('action') || info.action;
if (!info.field) {
return false;
}
{foreach from=$recurRows item=row}
{assign var=id value=$row.id}
- <tr id="contribution_recur-{$row.id}" data-entity-action="cancel" class="crm-entity {cycle values="even-row,odd-row"}{if NOT $row.is_active} disabled{/if}">
+ <tr id="contribution_recur-{$row.id}" data-action="cancel" class="crm-entity {cycle values="even-row,odd-row"}{if NOT $row.is_active} disabled{/if}">
<td>{$row.amount|crmMoney}{if $row.is_test} ({ts}test{/ts}){/if}</td>
<td>{ts}Every{/ts} {$row.frequency_interval} {$row.frequency_unit} </td>
<td>{$row.start_date|crmDate}</td>