public RecentCalibrationsViewModel(Document document, CustomerContact customerContact)
        {
            if (document == null)
            {
                return;
            }

            UserId           = document.UserId;
            Created          = document.Created;
            DocumentId       = document.Id;
            CompanyName      = document.CompanyName;
            DocumentTypeEnum = DocumentTypeHelper.Parse(document);
            DocumentType     = DocumentTypeEnum.AsDisplayString();
            DocumentIcon     = DocumentType.Replace(" ", "");
            Expiration       = document.InspectionDate.GetValueOrDefault().Date.AddYears(2);
            Registration     = document.RegistrationNumber;
            Technician       = document.Technician;
            Customer         = document.CustomerContact;
            DepotName        = document.DepotName;

            if (customerContact != null)
            {
                PrimaryEmailAddress   = customerContact.Email;
                SecondaryEmailAddress = customerContact.SecondaryEmail;
            }
        }
        public CalibrationsDueViewModel(Document document)
        {
            if (document == null)
            {
                return;
            }

            UserId           = document.UserId;
            Created          = document.Created;
            DocumentId       = document.Id;
            DocumentTypeEnum = DocumentTypeHelper.Parse(document);
            DocumentType     = DocumentTypeEnum.AsDisplayString();
            DocumentIcon     = DocumentType.Replace(" ", "");
            Date             = document.InspectionDate.GetValueOrDefault();
            Expiration       = document.InspectionDate.GetValueOrDefault().AddYears(2);
            Registration     = document.RegistrationNumber;
            Technician       = document.Technician;
            Customer         = document.CustomerContact;
            DepotName        = document.DepotName;

            var tachographDocument = document as TachographDocument;

            VehicleManufacturer = tachographDocument != null ? tachographDocument.VehicleMake : string.Empty;
        }