[% # Arguments # data - hash - # sorted_instances - array - of instances # url_to_install - string # url_to_install_admin - string # module - hash - # name - string - name of the module # version - string - version installed # meta - hash # miscurls - array - additional urls below the url_to_install # display - hash # versions - boolean - weather to display versions or not. %] [% IF has_instances; SET has_admin = 0; SET has_user = 0; SET module_name = module.name; FOR instances IN data.sorted_instances; has_admin = 1 IF instances.url_to_install_admin; has_user = 1 IF instances.url_to_install; LAST; # Since all the instances will have the same capabilities END; SET has_other = has_user && module.meta.miscurls.size > 0; %]
[% IF has_user %] [% END %] [% IF has_admin %] [% END %] [% IF has_other %] [% END %] [% IF module.meta.display.versions %] [% END %] [% FOR instance IN data.sorted_instances %] [% IF has_user %] [% END %] [% IF has_admin %] [% END %] [% IF has_other %] [% END %] [% IF module.meta.display.versions %] [% END %] [% END %]
[% locale.maketext('Site URL') %][% locale.maketext('Administrator [asis,URL]') %][% locale.maketext('Other [asis,URLs]') %][% locale.maketext('Version') %]
[% IF instance.url_to_install %] [% instance.url_to_install | html %] [% END %] [% IF instance.url_to_install_admin %] [% instance.url_to_install_admin | html %] [% END %] [% SET base = instance.url_to_install; base = base _ '/' IF !base.match('/$'); FOR relmiscurl IN meta.miscurls.keys; SET misc_url = base _ meta.miscurls.$relmiscurl %]
[% relmiscurl | html %]: [% misc_url | html %]
[% END;%]
v[% instance.version | html %]
[% # NOTE: There use to be a copy and remove copy. Not currently implemented %] [% FOR instance IN data.sorted_instances; END; IF module.meta.miscurls; END %] [% ELSE %] [% locale.maketext('There are no installed instances of this [asis,cPAddon].') %] [% END %]