Skip to content

Commit

Permalink
Merge pull request #3 from blackice2999/7.x
Browse files Browse the repository at this point in the history
7.x
  • Loading branch information
Eugen Mayer committed Nov 11, 2011
2 parents ac9d2a8 + f3ff902 commit 05de69b
Show file tree
Hide file tree
Showing 7 changed files with 17 additions and 40 deletions.
6 changes: 6 additions & 0 deletions js/tagging.init.js
Expand Up @@ -12,4 +12,10 @@
obj.attach();
return obj;
};

Drupal.behaviors.tagging_d7 = {
attach: function(context, settings) {
$('input.tagging-widget-input:not(.tagging-processed)').tagging();
}
};
})(jQuery);
Expand Up @@ -3,7 +3,7 @@
name = Drupal Wiki tagging suggestions
description = Suggesting terms for the Tagging-Module based on the current content and a algorythm developed for Drupal Wiki
package = Tagging
core = 6.x
core = 7.x
dependencies[] = taxonomy
dependencies[] = tagging
files[] = drupalwiki_extractor.inc
Expand Down
@@ -1,26 +1,7 @@
name = Tagging opencalais suggestions
description = This tagging module exposes suggestions based on the current content (body) using the semantic opencalais service
package = "Taxonomy"
core = 6.x
core = 7.x
dependencies[] = taxonomy
dependencies[] = tagging
dependencies[] = calais_api
; Information added by drupal.org packaging script on 2009-12-04
version = "6.x-2.0"
core = "6.x"
project = "tagging_opencalais_suggest"
datestamp = "1259920274"

; Information added by drupal.org packaging script on 2010-03-18
version = "6.x-2.1"
core = "6.x"
project = "tagging"
datestamp = "1268902508"


; Information added by drupal.org packaging script on 2010-10-17
version = "6.x-2.5"
core = "6.x"
project = "tagging"
datestamp = "1287311492"

9 changes: 1 addition & 8 deletions modules/tagging_vocab_suggest/tagging_vocab_suggest.info
@@ -1,14 +1,7 @@
name = Tagging full-vocabular suggestion
description = This tagging module exposes all vocabulary terms of a the vocabulary as suggestions (no matter what is in the content).
package = "Taxonomy"
core = 6.x
core = 7.x
dependencies[] = taxonomy
dependencies[] = tagging


; Information added by drupal.org packaging script on 2010-10-17
version = "6.x-2.5"
core = "6.x"
project = "tagging"
datestamp = "1287311492"

8 changes: 7 additions & 1 deletion modules/tagging_vocab_suggest/tagging_vocab_suggest.module
Expand Up @@ -7,7 +7,13 @@ function tagging_vocab_suggest_tagging_suggestions($vid, $node) {
$suggestions = array();

if(strpos(VERSION, '7') === 0) {
$result = db_query('select * from {taxonomy_term_data} where vid=:vid', array(':vid' => $vid));
$query = db_select('taxonomy_term_data', 't');
$query->fields('t');
$query->condition('vid', $vid);
$query->addTag('translatable');
$query->addTag('term_access');
$result = $query->execute();

foreach($result as $term) {
$suggestions[] = array('#weight' => $term->weight, '#name' => $term->name);
}
Expand Down
10 changes: 1 addition & 9 deletions tagging.info
@@ -1,14 +1,6 @@
name = Tagging
description = This widget is replacing the default Drupal-Tagging-Interface with a more visual driven one, to make tagging even easier. (by <a href="http://kontextwork.de"KontextWork</a>)
package = "Drupal Wiki"
version = "6.x-2.4"
core = 6.x
core = 7.x
dependencies[] = taxonomy
project = "tagging"

; Information added by drupal.org packaging script on 2010-10-17
version = "6.x-2.5"
core = "6.x"
project = "tagging"
datestamp = "1287311492"

1 change: 0 additions & 1 deletion tagging_d7.class.inc
Expand Up @@ -55,7 +55,6 @@ class tagging_d7 extends tagging_d6 {

public function _tagging_widget_javascript($form_element = null, &$form_state = array()) {
$form_element = parent::_tagging_widget_javascript($form_element, $form_state);
drupal_add_js('jQuery(document).ready(function () {Drupal.behaviors.tagging_d7 = Drupal.behaviors.tagging_d6();});', array('type' => 'inline', 'scope' => 'footer'));
return $form_element;
}
}

0 comments on commit 05de69b

Please sign in to comment.