% # Allow multiple subjects to be linked if it's an empty linker multiplicity = "many" if multiplicity.blank? if form.obj['ref'].blank? selected_json = (multiplicity === "many") ? "[]" : "{}" else multiplicity = "one" selected_json = form.obj['_resolved'].to_json end exclude_ids = [] if exclude_ids.blank? required = (defined? optional) ? !optional : true linkable_types = defined?(allowed_types) ? allowed_types : ["agent"] creatable_types = defined?(allowed_types) ? allowed_types : ["agent_person", "agent_family", "agent_corporate_entity", "agent_software"] hide_create = false if hide_create.blank? if !defined?(linker_label) linker_label = (multiplicity === "many") ? I18n.t("agent._plural") : I18n.t("agent._singular") end %>