Esempio n. 1
0
    def input_types_table(self, instance):
        input_types = list(instance.input_types.all())
        html_args = []
        html = []
        if len(input_types) > 1:
            html.append('<table>')
            for input_type in input_types:
                html.append('<tr>')
                html.append('<td>')
                html.append(admin_change_link(input_type))
                html.append('</td>')
                html.append('</tr>')
            html.append('</table>')
        elif input_types:
            return admin_change_link(input_types[0])

        return format_html("\n".join(html), *html_args)
Esempio n. 2
0
 def output_type_link(self, instance):
     return admin_change_link(instance.output_type)
Esempio n. 3
0
 def responsibility_link(self, instance):
     return admin_change_link(instance.responsibility)
Esempio n. 4
0
 def deliverable_link(self, instance):
     return admin_change_link(instance.deliverable)
Esempio n. 5
0
 def role_link(self, instance):
     return admin_change_link(instance.role, label=lambda role: role.name)
Esempio n. 6
0
 def format_link(self, instance):
     return admin_change_link(instance.format)
Esempio n. 7
0
 def facet_link(self, instance):
     return admin_change_link(instance.facet)
Esempio n. 8
0
 def group_link(self, instance):
     return admin_change_link(instance.group)
Esempio n. 9
0
 def organization_link(self, instance):
     return admin_change_link(instance.organization)