Add xlvask_parser_h_nger helper class for handling specific XLVask product parsing
This commit is contained in:
@@ -0,0 +1,28 @@
|
||||
<?php
|
||||
|
||||
namespace helpers;
|
||||
|
||||
use Exception;
|
||||
use objects\products_o;
|
||||
|
||||
class xlvask_parser_h_nger extends xlvask_product_parser
|
||||
{
|
||||
use xlvask_product_parser_t;
|
||||
|
||||
public function __construct()
|
||||
{
|
||||
$this->setup('Hænger');
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @inheritDoc
|
||||
* @throws Exception
|
||||
*/
|
||||
protected function parse(xlvask_wash_item $wash_item, xlvask_usage_log $xlvask_usage_log): products_o
|
||||
{
|
||||
// For some reason, in XLVask the primary product is stored as vask_h_nger in some cases,
|
||||
// This is a workaround to handle that case. (Since the functionality is exactly the same as // xlvask_parser_stor_bil)
|
||||
return (new xlvask_parser_stor_bil())->parseProduct(...func_get_args());
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user