public int CompareTo(Invoice other)
        {
            if (ReferenceEquals(this, other))
            {
                return(0);
            }
            if (ReferenceEquals(null, other))
            {
                return(1);
            }
            var serialNumberComparison = string.Compare(SerialNumber, other.SerialNumber, StringComparison.Ordinal);

            if (serialNumberComparison != 0)
            {
                return(serialNumberComparison);
            }
            var companyNameComparison = string.Compare(CompanyName, other.CompanyName, StringComparison.Ordinal);

            if (companyNameComparison != 0)
            {
                return(companyNameComparison);
            }
            var subtotalComparison = Subtotal.CompareTo(other.Subtotal);

            if (subtotalComparison != 0)
            {
                return(subtotalComparison);
            }
            var departmentComparison = Department.CompareTo(other.Department);

            if (departmentComparison != 0)
            {
                return(departmentComparison);
            }
            var issueDateComparison = IssueDate.CompareTo(other.IssueDate);

            if (issueDateComparison != 0)
            {
                return(issueDateComparison);
            }
            return(DueDate.CompareTo(other.DueDate));
        }