Index: C:/wamp/svn/glpi/branches/0.83-bugfixes/inc/ticket.class.php
===================================================================
--- C:/wamp/svn/glpi/branches/0.83-bugfixes/inc/ticket.class.php	(revision 17279)
+++ C:/wamp/svn/glpi/branches/0.83-bugfixes/inc/ticket.class.php	(working copy)
@@ -1037,6 +1037,13 @@
             if (!$item->getFromDB($input["items_id"])) {
                $item = NULL;
             }
+   			else
+			{
+				if (isset($item->fields['locations_id']))
+				{
+					$input['item_locations'] = $item->fields['locations_id'];
+				}
+			}
          }
       }
 
@@ -1177,6 +1184,21 @@
                                                     '', Ticket::INCIDENT_TYPE);
       }
 
+	  if (!isset($input['locations_id']) || $input['locations_id'] == 0)
+	  {
+		if (isset($input['item_locations']) && $input['item_locations'] != 0)
+		{
+			$input['locations_id'] = $input['item_locations'];
+		}
+		else
+		{
+			if (isset($input['users_locations']) && $input['users_locations'] != 0)
+			{
+				$input['locations_id'] = $input['users_locations'];
+			}
+		}
+	  }
+
       return $input;
    }
 
@@ -1668,6 +1690,10 @@
       $tab[3]['field']      = 'priority';
       $tab[3]['name']       = $LANG['joblist'][2];
       $tab[3]['searchtype'] = 'equals';
+	  
+	  $tab[4]['table'] = 'glpi_locations';
+      $tab[4]['field'] = 'completename';
+      $tab[4]['name']  = $LANG['common'][15];
 
       $tab[15]['table']         = $this->getTable();
       $tab[15]['field']         = 'date';
@@ -3585,6 +3611,12 @@
          echo "<table class='tab_cadre_fixe'>";
       }
 
+      echo "<tr class='tab_bg_1'><th>" . $LANG['common'][15] . "&nbsp;:</th><td>";
+      Dropdown::show('Location', array('value'  => $this->fields["locations_id"],
+                                       'entity' => $this->fields["entities_id"]));
+      echo "</td><td>&nbsp;</td><td>&nbsp;</td></tr>";
+
+
       echo "<tr class='tab_bg_1'>";
       echo "<th width='10%'>".$tt->getBeginHiddenFieldText('status').$LANG['joblist'][0]."&nbsp;:".
                 $tt->getMandatoryMark('status').$tt->getEndHiddenFieldText('status')."</th>";
