Class ConditionFilter

Removes offers based on condition/subcondition of item.

Class Summary

Conditions are grouped into classes - and can be filtered on as a class or a specific condition code.

  • new
    • 11 (New)
  • used
    • 1 (Used, Like New)
    • 2 (Used, Very Good)
    • 3 (Used, Good)
    • 4 (Used, Acceptable)
  • collectible
    • 5 (Collectible, Like New)
    • 6 (Collectible, Very Good)
    • 7 (Collectible, Good)
    • 8 (Collectible, Acceptable)

When filtering on the condition using the better/worse filters, this is the order (starting with the "best"):

  • 11 - New
  • 5 - Collectible, Like New
  • 1 - Used, Like New
  • 10 - Refurbished
  • 9 - Used, Refurbished
  • 6 - Collectible, Very Good
  • 2 - Used, Very Good
  • 7 - Collectible, Good
  • 3 - Used, Good
  • 8 - Collectible, Acceptable
  • 4 - Used, Acceptable

Using the Condition filter:

var amazon = FILLZ.SOURCE.AMAZONUS.v1;
var filter = FILLZ.FILTERS.v1;
var item = FILLZ.ITEM.v1;

var o1 = amazon.offers(filter.condition.is_new());
var o2 = amazon.offers(filter.condition.same_or_better_than(item.condition));
var o3 = amazon.offers(filter.condition.not_collectible());

Methods

  • is_new()

    Returns true if Offer condition is 'new'

  • is_used()

    Returns true if Offer condition is 'used'

  • is_collectible()

    Returns true if Offer condition is 'collectible'

  • not_collectible()

    Returns true if Offer condition is not 'collectible'

  • same(condition)

    Returns true if Offer condition is equal to condition

  • same_class(condition)

    Returns true if Offer condition is in the same class as condition (new, used, or collectible)

  • worse_than(condition)

    Returns true if Offer condition is worse than condition

  • same_or_worse_than(condition)

    Returns true if Offer condition is the same or worse than condition

  • better_than(condition)

    Returns true if Offer condition is better than condition

  • same_or_better_than(condition)

    Returns true if Offer condition is the same or better than condition