diff options
author | Angie Byron <webchick@24967.no-reply.drupal.org> | 2009-08-21 00:21:48 +0000 |
---|---|---|
committer | Angie Byron <webchick@24967.no-reply.drupal.org> | 2009-08-21 00:21:48 +0000 |
commit | db61b2603918d582afad82b8036fac7f5240a627 (patch) | |
tree | 7d5cc8f01eb970dc80e65fc4fdf9bfa9c1c59cd5 /modules/comment/comment-node-form.js | |
parent | bf49ab721394036a9e3396236cab76ae6db0594f (diff) | |
download | brdo-db61b2603918d582afad82b8036fac7f5240a627.tar.gz brdo-db61b2603918d582afad82b8036fac7f5240a627.tar.bz2 |
#439798 by Rob Loach: Added Vertical Tabs to the Node Type Form.
Diffstat (limited to 'modules/comment/comment-node-form.js')
-rw-r--r-- | modules/comment/comment-node-form.js | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/modules/comment/comment-node-form.js b/modules/comment/comment-node-form.js index 20d8729f4..0f51884a2 100644 --- a/modules/comment/comment-node-form.js +++ b/modules/comment/comment-node-form.js @@ -7,6 +7,25 @@ Drupal.behaviors.commentFieldsetSummaries = { $('fieldset#edit-comment-settings', context).setSummary(function (context) { return Drupal.checkPlain($('input:checked', context).parent().text()); }); + // Provide the summary for the node type form. + $('fieldset#edit-comment', context).setSummary(function(context) { + var vals = []; + + // Default comment setting. + vals.push($("select[name='comment'] option:selected", context).text()); + + // Threading. + var threading = $("input[name='comment_default_mode']:checked", context).parent().text(); + if (threading) { + vals.push(threading); + } + + // Comments per page. + var number = $("select[name='comment_default_per_page'] option:selected", context).val(); + vals.push(Drupal.t('@number comments per page', {'@number': number})); + + return Drupal.checkPlain(vals.join(', ')); + }); } }; |