Пример #1
0
 def _get_breadcrumbs(self):
     device = self.get_device()
     breadcrumbs = get_device_breadcrumbs(device, self.request.user)
     breadcrumbs.append(
         Breadcrumb('Non-Conformities',
                    reverse('gdrives:non-conformities', args=[device.pk])))
     return breadcrumbs
Пример #2
0
 def _get_breadcrumbs(self):
     device = self.get_device()
     breadcrumbs = get_device_breadcrumbs(device, self.request.user)
     breadcrumbs.append(
         Breadcrumb('Complaints',
                    reverse('gdrives:complaints', args=[device.pk])))
     return breadcrumbs
Пример #3
0
def recover_readings(request, device_id):
    device = GDrive.objects.get(pk=device_id)
    breadcrumbs = get_device_breadcrumbs(device, request.user)
    return generic_form(request,
                        form_class=RecoverReadingsForm,
                        form_kwargs={'device': device},
                        page_title='Recover Readings for Device {0}'.format(
                            device.meid),
                        breadcrumbs=breadcrumbs,
                        system_message="The readings have been recovered.")
Пример #4
0
 def get_breadcrumbs(self):
     device = self.get_device()
     breadcrumbs = get_device_breadcrumbs(device, self.request.user)
     return breadcrumbs
Пример #5
0
 def get_breadcrumbs(self):
     device = self.get_device()
     return get_device_breadcrumbs(device, self.request.user, False)