规则 2 开发的文档似乎(至少对我而言)比版本 1 更令人困惑。我试图为转换为 drupal 7/rules 2 的新规则操作获取用户贡献的模块。可以在此处找到原始帖子:http ://drupal.org/node/675010#comment-4135238
这是实际的操作信息部分,因为它看起来像 drupal.org 现在已经关闭。
function paction_rules_action_info() {
return array(
'paction_mail_node' => array(
'label' => t('Send node as HTML formated email'),
'arguments' => array(
'node' => array('type' => 'node', 'label' => t('Content')),
),
'eval input' => array('to', 'from', 'subject', 'message'),
),
'module' => 'Node',
);
}
我的问题是,这是否需要为 drupal 7 完全重写,还是可以显示代码的快速转换?