Gregory - 2024-05-06

I am looking at adding a new CI to iTop. (Zabbix Proxy)
This class has the FunctionalCI as its parent and has a few fields related to its configuration.

<class id="ZabbixProxy" _delta="define">
      <parent>FunctionalCI</parent>
      <properties>
        <category>bizmodel,searchable</category>
        <abstract>false</abstract>
        <key_type>autoincrement</key_type>
        <db_table>zabbixproxy</db_table>
        <db_key_field>id</db_key_field>
        <db_final_class_field/>
        <naming>
          <attributes>
            <attribute id="name"/>
          </attributes>
          <complementary_attributes>
            <attribute id="organization_name"></attribute>
          </complementary_attributes>
        </naming>
        <style>
          <icon>images/monitoring_icon.png</icon>
        </style>
        <reconciliation>
          <attributes>
            <attribute id="name"/>
            <attribute id="org_id"/>
            <attribute id="organization_name"/>
          </attributes>
        </reconciliation>
      </properties>
      <fields>
        <field id="proxy" xsi:type="AttributeString">
          <sql>name</sql>
          <is_null_allowed>true</is_null_allowed>
          <default_value/>
        </field>
        <field id="type" xsi:type="AttributeEnum">
          <values>
            <value id="active">
              <code>active</code>
            </value>            
            <value id="passive">
              <code>passive</code>
            </value>
          </values>
          <sql>type</sql>
          <default_value/>
          <is_null_allowed>false</is_null_allowed>
          <display_style>radio_horizontal</display_style>
        </field>
        <field id="functionalci_id" xsi:type="AttributeExternalKey">
          <sql>functionalci_id</sql>
          <filter><![CDATA[
            SELECT FunctionalCI WHERE finalclass IN ('Server', 'VirtualMachine')
          ]]></filter>
          <target_class>FunctionalCI</target_class>
          <is_null_allowed>false</is_null_allowed>
          <on_target_delete>DEL_MANUAL</on_target_delete>
          <tracking_level>all</tracking_level>
          <allow_target_creation>true</allow_target_creation>
        </field>
      </fields>

This all works as expected and i can create the new CI.
Next, i would like to be able to select this CI from each Server CI.
Essentially what this is doing it saying "This server is configured to use this proxy"

    <class id="Server" _delta="if_exists">
      <fields>
        <field id="zabbixproxy_id" xsi:type="AttributeExternalKey" _delta="define">
          <sql>zabbixproxy_id</sql>
          <target_class>ZabbixProxy</target_class>
          <is_null_allowed>true</is_null_allowed>
          <on_target_delete>DEL_MANUAL</on_target_delete>
          <filter><![CDATA[SELECT ZabbixProxy]]></filter>
          <allow_target_creation>true</allow_target_creation>
        </field>
        <field id="proxy_name" xsi:type="AttributeExternalField" _delta="define">
          <extkey_attcode>zabbixproxy_id</extkey_attcode>
          <target_attcode>name</target_attcode>
        </field>
      </fields>

Unfortunately, the field in iTop just displays "zabbixproxy_id->Name" with no dropdown selection.

Any idea what I may be missing? I can post the full extension code if required.