"""Assigns the global IP to a target."""
# :license: MIT, see LICENSE for more details.

import click

import SoftLayer
from SoftLayer.CLI import environment


@click.command(epilog="More information about types and ")
@click.argument('identifier')
@click.option('--target',
              help='See SLDN docs. '
                   'E.g SoftLayer_Network_Subnet_IpAddress, SoftLayer_Hardware_Server,SoftLayer_Virtual_Guest')
@click.option('--router', help='An appropriate identifier for the specified $type. Some types have multiple identifier')
@environment.pass_env
def cli(env, identifier, target, router):
    """Assigns the global IP to a target."""

    mgr = SoftLayer.NetworkManager(env.client)
    mgr.route(identifier, target, router)

@@ -156,391 +156,680 @@
 nt%0A%0A
-%0A@click.command(epilog=%22More information about types and %22)%0A@click.argument('identifier')%0A@click.option('--target',%0A              help='See SLDN docs. '%0A                   'E.g SoftLayer_Network_Subnet_IpAddress, SoftLayer_Hardware_Server,SoftLayer_Virtual_Guest')%0A@click.option('--router', help='An appropriate identifier for the specified $type. Some types have multiple identifier
+target_types = %7B'vlan': 'SoftLayer_Network_Vlan',%0A                'ip': 'SoftLayer_Network_Subnet_IpAddress',%0A                'hardware': 'SoftLayer_Hardware_Server',%0A                'vsi': 'SoftLayer_Virtual_Guest'%7D%0A%0A%0A@click.command(epilog=%22More information about types and identifiers %22%0A                      %22on https://sldn.softlayer.com/reference/services/SoftLayer_Network_Subnet/route/%22)%0A@click.argument('identifier')%0A@click.option('--target', type=click.Choice(%5B'vlan', 'ip', 'hardware', 'vsi'%5D),%0A              help='choose the type. vlan, ip, hardware, vsi')%0A@click.option('--target-id', help='The identifier for the destination resource to route this subnet to. 
 ')%0A@
@@ -882,22 +882,25 @@
 target, 
-router
+target_id
 ):%0A    %22
@@ -909,33 +909,30 @@
 Assigns the 
-global IP
+subnet
  to a target
@@ -1020,14 +1020,35 @@
 rget
-, router
+_types.get(target), target_id
 )%0A

fix the team code review comments