/**
* Resolves the association data for a single variant.
*
* @throws CustomValidationException
*
* @return array|mixed
*/
protected function prepareData(array
$data, ProductModel
$article, Detail
$variant) { $data =
$this->
prepareUnitAssociation($data);
if (!
empty($data['prices'
])) { $data['prices'
] =
$this->
preparePriceAssociation( $data,
$article,
$variant,
$article->
getTax() );
} if (isset($data['purchasePrice'
]) && \
is_string($data['purchasePrice'
])) {