$loader->setPageName(implode('/', $pagePath));
$loader->getRes()->addSetting([
'afform' => [
+ 'name' => $pageArgs['afform'],
'open' => _afform_angular_module_name($pageArgs['afform'], 'dash'),
],
]);
}
});
if (toLoad) {
- crmApi4('Afform', 'prefill', {name: CRM.afform.open, args: $routeParams})
+ crmApi4('Afform', 'prefill', {name: CRM.afform.name, args: $routeParams})
.then(function(result) {
_.each(result, function(item) {
data[item.name] = _.extend(item.values, schema[item.name].data || {});
};
this.submit = function submit() {
- crmApi4('Afform', 'submit', {name: CRM.afform.open, args: $routeParams, values: data});
+ crmApi4('Afform', 'submit', {name: CRM.afform.name, args: $routeParams, values: data});
};
}
};