diff -uprN nat-6x-dev/nat.admin.inc nat/nat.admin.inc
--- nat-6x-dev/nat.admin.inc	2009-03-01 09:27:52.000000000 +0200
+++ nat/nat.admin.inc	2009-10-30 11:39:11.000000000 +0200
@@ -50,6 +50,12 @@ function nat_settings_form() {
       '#default_value' => isset($nat_config['related'][$type]) ? $nat_config['related'][$type] : 0,
       '#parents' => array('related', $type)
     );
+    $form['nat_'. $type]['parent_term_'. $type] = array(
+      '#type' => 'checkbox',
+      '#title' => t('Allow users to define parent term when they create and edit nodes.'),
+      '#default_value' => isset($nat_config['parent_term'][$type]) ? $nat_config['parent_term'][$type] : 0,
+      '#parents' => array('parent_term', $type)
+    );
     $form['nat_'. $type]['node_links_'. $type] = array(
       '#type' => 'checkbox',
       '#title' => t('Make NAT terms in %type node views point to the associated node rather than the taxonomy page.', array('%type' => $type)),
@@ -74,6 +80,7 @@ function nat_settings_form_submit($form,
   $form_values['delete'] = array_filter($form_values['delete']);
   $form_values['node_links'] = array_filter($form_values['node_links']);
   $form_values['related'] = array_filter($form_values['related']);
+  $form_values['parent_term'] = array_filter($form_values['parent_term']);
 
   variable_set('nat_config', $form_values);
 
@@ -157,3 +164,4 @@ function _nat_sync_associations($associa
   }
   drupal_set_message(t('NAT sync complete: %count nodes synced.', array('%count' => $counter)));
 }
+
diff -uprN nat-6x-dev/nat.module nat/nat.module
--- nat-6x-dev/nat.module	2009-03-01 09:27:52.000000000 +0200
+++ nat/nat.module	2009-10-30 11:45:11.000000000 +0200
@@ -121,6 +121,11 @@ function nat_form_alter(&$form, &$form_s
       if (count($associations) && $form_id == $type .'_node_form') {
         $nat_terms = array();
 
+        if (!$form['nid']['#value']) { // if create new node
+        	// after saving node let's redirect user to terms listing page instead of node page
+        	$form['#redirect'] = array('admin/content/taxonomy/'.key($associations));
+        }
+
         // If this is a node update, remove this node's associated terms from
         // its associated vocabularies.
         // N.B. Free-tag vocabularies are unaffected by this.
@@ -144,8 +149,7 @@ function nat_form_alter(&$form, &$form_s
           }
         }
 
-        // Related terms.
-        if (isset($config['related'][$type])) {
+        if (isset($config['related'][$type]) || isset($config['parent_term'][$type])) {
           $form['nat'] = array(
             '#type' => 'fieldset',
             '#title' => t('Term information'),
@@ -157,13 +161,14 @@ function nat_form_alter(&$form, &$form_s
 
           foreach ($associations as $vocabulary_id) {
             $vocabulary = taxonomy_vocabulary_load($vocabulary_id);
-            if ($vocabulary->relations) {
+            $exclude = (isset($nat_terms[$vocabulary_id])) ? array($nat_terms[$vocabulary_id]) : array();
+
+            if (isset($config['related'][$type]) && ($vocabulary->relations)) {
               if (isset($nat_terms[$vocabulary_id])) {
                 $default = array_keys(taxonomy_get_related($nat_terms[$vocabulary_id]));
-                $exclude = array($nat_terms[$vocabulary_id]);
               }
               else {
-                $default = $exclude = array();
+                $default = array();
               }
 
               $form['nat']['related'][$vocabulary_id] = _taxonomy_term_select(
@@ -176,24 +181,46 @@ function nat_form_alter(&$form, &$form_s
                 t('<none>'),
                 $exclude
               );
+		          // Synonyms: It is assumed that the synonyms for NAT terms in
+		          // different vocabularies are the same.
+		          if (!empty($nat_terms)) {
+		            $tid = array_pop($nat_terms);
+		            $default = implode("\n", taxonomy_get_synonyms($tid));
+		          }
+		          else {
+		            $default = '';
+		          }
+		          $form['nat']['synonyms'] = array(
+		            '#type' => 'textarea',
+		            '#title' => t('Synonyms'),
+		            '#default_value' => $default,
+		            '#description' => t('Synonyms of this term; one synonym per line.')
+		          );
             }
-          }
+		        if (isset($config['parent_term'][$type])) {
+		        	$parent = array_keys(taxonomy_get_parents($term->tid));
 
-          // Synonyms: It is assumed that the synonyms for NAT terms in
-          // different vocabularies are the same.
-          if (!empty($nat_terms)) {
-            $tid = array_pop($nat_terms);
-            $default = implode("\n", taxonomy_get_synonyms($tid));
+		        	// exlude this term itself
+		        	$exclude_childs[] = $term->tid;
+		        	// find and exlude any child terms
+		        	$child_tree = taxonomy_get_tree($term->vid, $term->tid);
+		        	if (!empty($child_tree)) {
+		        		foreach ($child_tree as $num => $child_term) {
+		        			$exclude_childs[]=$child_term->tid;
+		        		}
+		        	}
+		        	$form['nat']['parent_term'][$vocabulary_id] = _taxonomy_term_select(
+		            t('Parent term'),
+		            'relations',
+		            $parent,  
+		            $vocabulary_id,
+		            NULL,
+		            0,
+		            t('<none>'),
+		            $exclude_childs
+		          );
+		        }
           }
-          else {
-            $default = '';
-          }
-          $form['nat']['synonyms'] = array(
-            '#type' => 'textarea',
-            '#title' => t('Synonyms'),
-            '#default_value' => $default,
-            '#description' => t('Synonyms of this term; one synonym per line.')
-          );
         }
 
         // This can only match once, so we just break the foreach.
@@ -201,6 +228,33 @@ function nat_form_alter(&$form, &$form_s
       }
     }
   }
+  
+  if($form_id == 'taxonomy_form_term') {
+    // $vid = $form['#term']['vid'];
+    $vid = $form['#vocabulary']['vid'];
+
+    $config = _nat_variable_get();
+    foreach ($config['types'] as $type => $vocabs){
+    	if (in_array($vid, $vocabs)){
+        $url = '/';
+        if ($form['#term']['tid']!=null) {
+          $nids = nat_get_nids(array($form['#term']['tid']));
+          if (!empty($nids)){
+            $url = '/node/'.key($nids).'/edit?'.drupal_get_destination();;
+          }
+        }
+    		else {
+          $url = '/node/add/'.$type;
+        }
+
+        // next function didn't working and I don't know why
+        // drupal_goto($url); 
+        // that's why I write next:
+        header('Location: ' . $url, TRUE, 302);
+        exit();
+      }
+    }
+  }
 }
 
 /**
@@ -503,7 +557,7 @@ function _nat_add_terms($node, $vids = a
       $edit['parent'] = $hierarchy[$vid];
     }
     else {
-      $edit['parent'] = array();
+      $edit['parent'] = isset($node->nat) && isset($node->nat['parent_term'][$vid]) ? $node->nat['parent_term'][$vid] : array();
     }
     $edit['relations'] = isset($node->nat) && isset($node->nat['related'][$vid]) ? $node->nat['related'][$vid] : array();
     $edit['synonyms'] = isset($node->nat) ? $node->nat['synonyms'] : '';
@@ -530,12 +584,14 @@ function _nat_update_terms($node) {
   );
 
   $hierarchy = isset($node->taxonomy) ? $node->taxonomy : array();
+  $vocab_id = key($nat_config['types'][$node->type]);
+  $parent_term = isset($node->nat) && isset($node->nat['parent_term'][$vocab_id]) ? $node->nat['parent_term'][$vocab_id] : array();
   $terms = nat_get_terms($node->nid);
   foreach ($terms as $term) {
     $edit['tid'] = $term->tid;
     $edit['vid'] = $term->vid;
     $edit['weight'] = $term->weight;
-    $edit['parent'] = isset($hierarchy[$term->vid]) ? $hierarchy[$term->vid] : array();
+    $edit['parent'] = isset($hierarchy[$term->vid]) ? $hierarchy[$term->vid] : $parent_term;
     $edit['relations'] = isset($node->nat) && isset($node->nat['related'][$term->vid]) ? $node->nat['related'][$term->vid] : array();
     $edit['synonyms'] = isset($node->nat) ? $node->nat['synonyms'] : '';
 
