public int CompareTo(Shipment other) { if (ReferenceEquals(this, other)) { return(0); } if (ReferenceEquals(null, other)) { return(1); } return(IdMonth.CompareTo(other.IdMonth)); }
public int CompareTo(ExportAccounting other) { if (ReferenceEquals(this, other)) { return(0); } if (ReferenceEquals(null, other)) { return(1); } var idMonthComparison = IdMonth.CompareTo(other.IdMonth); if (idMonthComparison != 0) { return(idMonthComparison); } var monthComparison = string.Compare(Month, other.Month, StringComparison.OrdinalIgnoreCase); if (monthComparison != 0) { return(monthComparison); } var nearMonthOldComparison = NearMonthOld.CompareTo(other.NearMonthOld); if (nearMonthOldComparison != 0) { return(nearMonthOldComparison); } var nearMonthUsdOldComparison = NearMonthUsdOld.CompareTo(other.NearMonthUsdOld); if (nearMonthUsdOldComparison != 0) { return(nearMonthUsdOldComparison); } var fartherMonthOldComparison = FartherMonthOld.CompareTo(other.FartherMonthOld); if (fartherMonthOldComparison != 0) { return(fartherMonthOldComparison); } var fartherMonthUsdOldComparison = FartherMonthUsdOld.CompareTo(other.FartherMonthUsdOld); if (fartherMonthUsdOldComparison != 0) { return(fartherMonthUsdOldComparison); } var nearYearOldComparison = NearYearOld.CompareTo(other.NearYearOld); if (nearYearOldComparison != 0) { return(nearYearOldComparison); } var nearYearUsdOldComparison = NearYearUsdOld.CompareTo(other.NearYearUsdOld); if (nearYearUsdOldComparison != 0) { return(nearYearUsdOldComparison); } var fartherYearOldComparison = FartherYearOld.CompareTo(other.FartherYearOld); if (fartherYearOldComparison != 0) { return(fartherYearOldComparison); } var fartherYearUsdOldComparison = FartherYearUsdOld.CompareTo(other.FartherYearUsdOld); if (fartherYearUsdOldComparison != 0) { return(fartherYearUsdOldComparison); } var nearMonthTodayComparison = NearMonthToday.CompareTo(other.NearMonthToday); if (nearMonthTodayComparison != 0) { return(nearMonthTodayComparison); } var nearMonthUsdTodayComparison = NearMonthUsdToday.CompareTo(other.NearMonthUsdToday); if (nearMonthUsdTodayComparison != 0) { return(nearMonthUsdTodayComparison); } var fartherMonthTodayComparison = FartherMonthToday.CompareTo(other.FartherMonthToday); if (fartherMonthTodayComparison != 0) { return(fartherMonthTodayComparison); } var fartherMonthUsdTodayComparison = FartherMonthUsdToday.CompareTo(other.FartherMonthUsdToday); if (fartherMonthUsdTodayComparison != 0) { return(fartherMonthUsdTodayComparison); } var nearYearTodayComparison = NearYearToday.CompareTo(other.NearYearToday); if (nearYearTodayComparison != 0) { return(nearYearTodayComparison); } var nearYearUsdTodayComparison = NearYearUsdToday.CompareTo(other.NearYearUsdToday); if (nearYearUsdTodayComparison != 0) { return(nearYearUsdTodayComparison); } var fartherYearTodayComparison = FartherYearToday.CompareTo(other.FartherYearToday); if (fartherYearTodayComparison != 0) { return(fartherYearTodayComparison); } return(FartherYearUsdToday.CompareTo(other.FartherYearUsdToday)); }