VirtueMart Forum

VirtueMart 2 + 3 + 4 => Virtuemart Development and bug reports => Topic started by: niosme on February 27, 2024, 08:37:36 AM

Title: Custom Search Plugin
Post by: niosme on February 27, 2024, 08:37:36 AM
   function sortSearchListQuery ($onlyPublished = TRUE, $virtuemart_category_id = FALSE, $group = FALSE, $nbrReturnProducts = FALSE, $params = array() ) {
      if($this->debug === 1) vmTrace('sortSearchListQuery',FALSE,3);
      $keyword = isset($params['keyword'])? $params['keyword'] : $this->keyword;
      /*
       * Plugins must return an array with product ids
       */
      $result = array();
-->      JPluginHelper::importPlugin('vmcustom');
      $used = vDispatcher::trigger('plgVmMySortSearchListProductsQuery',
         array(
            &$result,
            $keyword,
            $onlyPublished,
            $virtuemart_category_id,
            $group,$nbrReturnProducts,
            $params,
         ));

In administrator model product.php you have forgotten to say JPluginHelper::importPlugin('vmcustom'); before dispatch event for custom search plugin to develop.
Title: Re: Custom Search Plugin
Post by: niosme on March 13, 2024, 08:53:09 AM
Can this be included please?