function radioactivity_rules_token_list in Radioactivity 6
File
- modules/
radioactivity_rules/ radioactivity_rules.module, line 158
Code
function radioactivity_rules_token_list($type = 'all') {
if ($type == 'node' || $type == 'all') {
$options_raw = radioactivity_get_decay_profiles();
foreach ($options_raw as $dpid => $profile) {
$tokens['node']['radioactivity-energy-' . $dpid] = t("Energy for decay profile @dp (@id)", array(
'@dp' => $profile['label'],
'@id' => $dpid,
));
$tokens['node']['radioactivity-energy-max-' . $dpid] = t("Maximum energy for decay profile @dp (@id, excluding current node)", array(
'@dp' => $profile['label'],
'@id' => $dpid,
));
$tokens['node']['radioactivity-initial-energy-' . $dpid] = t("Initial energy at the time of the node types creation on decay profile @dp (@id)", array(
'@dp' => $profile['label'],
'@id' => $dpid,
));
}
return $tokens;
}
}