(update+save)Install working correctly

Update Install works properly now. Changes made:

------------------------------------------------------------------------------------
idods.py:

------------------------------------------------------------------------------------
UpdateInstallRelPropertyByMap argument install_rel_id=None added. Now it
is possible to update installRelProperties of virtual relationships
(parent_install = child_install). The way this added parameter
influences updateInstallRelPropertyByMap is that it checks if
install_rel_id holds a value it doesn't search for it by other given
parameters, but it uses install_rel_id.

DeleteInstallRelProperty argument install_rel_prop_type_name=None for
deleting only relation properties with names as
install_rel_prop_type_name. If we use DeleteInstallRelProperty without
the optional argument, it deletes all properties for installRel with
given id. If we want to delete a property type name that does not exist
in database a ValueError is risen.

UpdateInstallRel now supports updating virtual relations. If we want to
do that, we have to add {'__virtual_rel__': "true"} to props.

RetrieveInstallRel now returns virtual relations if an
expected_property={"__virtual_rel__": "true"} is given.

------------------------------------------------------------------------------------
dataapi/test_idods.py

------------------------------------------------------------------------------------
New tests were made due to changes idods.py, to make sure everything
that was changed works properly.

tests added:
- testUpdateInstallRelPropertyByMap
- testDeleteInstallRelProperty

test updated:
- testRetrieveInstallRel

------------------------------------------------------------------------------------
views.py

------------------------------------------------------------------------------------
Parameter install_rel_id added for updateInstallRelPropertyByMap

------------------------------------------------------------------------------------
common.js

------------------------------------------------------------------------------------
Some semantic changes.

------------------------------------------------------------------------------------
controllers.js

------------------------------------------------------------------------------------
First thing that was done was to force a value "Real" for installs
(older ones) that do not yet have a property __node_type__.

$scope.saveOrUpdateInstallRel made to make things simpler and clearer.
While factory install makes sure of saving and updating installs,
factory installRel makes sure of saving and updating installRel and
installRelProps.

------------------------------------------------------------------------------------
values.js

------------------------------------------------------------------------------------
Added expected_property to list of parameters in InstallRel.

Install values changed so it now fully supports __node_type__,
__beamline__ and __project__.

------------------------------------------------------------------------------------
install.html

------------------------------------------------------------------------------------
Saveing/updating form changed due to changes in values.js, updating is
now the same as saving form.
Added InventoryToInstall to (update + save)Install

Added option to choose an inventory when making a new install to form a
new InventoryToInstall entry. Inventory to install is only available for
Real devices. We can
only choose between inventories that are currently not installed. If we
decide to remove a InventoryToInstall for selected Install, we can
simply use the x button and
press update.

Changes:

------------------------------------------------------------------------------------
idods.py:

------------------------------------------------------------------------------------
retrieveInventory optional parameter not_installed added. That enables
us now to return inventories that have not yet been installed.

retrieveInventoryTonstall all parameters are now optional, since a
retrieving method is supposed to be based on optional parameters and
because it was only useful if we
had all the parameters. But in that case we've already determined the
Install that we were looking for.

------------------------------------------------------------------------------------
dataapi/test_idods.py

------------------------------------------------------------------------------------
New tests were made due to changes idods.py, to make sure everything
that was changed works properly.

tests updated:
- testInventoryToInstall - added test for retrieving inventories that
are not installed.

------------------------------------------------------------------------------------
views.py

------------------------------------------------------------------------------------
Parameter not_installed added for retrieveInventory

------------------------------------------------------------------------------------
controllers.js

------------------------------------------------------------------------------------
Added $scope.inventories that holds all retrieved inventories.
If we are on an update form, we have to first retrieve an inventory that
is bound on that device via InventoryToInstall if such an inventory
exists.

------------------------------------------------------------------------------------
values.js

------------------------------------------------------------------------------------
Added not_installed to list of parameters in Install.

------------------------------------------------------------------------------------
install.html

------------------------------------------------------------------------------------
Added a <select> that shows all available inventories, together with an
X icon, that resets the <select> field.