src/Models/Database/Product.php
public function getVariableProduct($attributeDropdownOption)
    {
        $productAttributeIntegerValue = ProductAttributeIntegerValue::
                                                whereAttributeId($attributeDropdownOption->attribute_id)
                                                ->whereValue($attributeDropdownOption->id)->first();

        if (null === $productAttributeIntegerValue) {
            return;
        }

        return self::findorfail($productAttributeIntegerValue->product_id);
    }
public function getVariableProduct($attributeDropdownOption)
    {
        $productAttributeIntegerValue = ProductAttributeIntegerValue::
                                                whereAttributeId($attributeDropdownOption->attribute_id)
                                                ->whereValue($attributeDropdownOption->id)->first();

        if (null === $productAttributeIntegerValue) {
            return;
        }

        return self::findorfail($productAttributeIntegerValue->product_id);
    }
public function getVariableProduct ( $ attributeDropdownOption ) { $ productAttributeIntegerValue = ProductAttributeIntegerValue :: whereAttributeId ( $ attributeDropdownOption -> attribute_id ) -> whereValue ( $ attributeDropdownOption -> id ) -> first ( ) ; if ( null === $ productAttributeIntegerValue ) { return ; } return self :: findorfail ( $ productAttributeIntegerValue -> product_id ) ; }
Get Variable Product by Attribute Drop down Option.

@param \AvoRed\Framework\Models\Database\AttributeDropdownOption
@return \AvoRed\Framework\Models\Database\ProductVariation
Get Variable Product by Attribute Drop down Option .