doesn't like line 3

ryank76's picture
Offline
Joined: 01/16/2008
Juice: 61
doesn't like line 3
<?php
if ($node->type == 'product') {
 
$arr_sku = uc_stock_skus($node->nid);
 
$stock_html .='<table>';
  foreach(
$arr_sku as $sku){
   
$stocklevel = uc_stock_level($sku);
    if (
$stocklevel) {
      if (
$stocklevel < 1) {
       
$stocklevel = '<span class="nostock">'.$stocklevel.'</span>';
      }
     
$stock_html .='<tr><td>'.$sku.'</td><td>:&nbsp;&nbsp;'.$stocklevel.'</td></tr>';
    }
  }
 
$stock_html .='</table>';
}
?>

If I put this in the end of my node.tpl.php, I get:

Fatal error: Call to undefined function uc_stock_skus() in /var/www/drupal-6.14/themes/garland/node.tpl.php on line 36

Where line 36 is:
$arr_sku = uc_stock_skus($node->nid);

It doesn't seem to matter which theme I use. My setup is Drupal 6.14, Ubercart 6.x-2.0.

Stock level on catalog page By: opa001 (44 replies) Mon, 03/31/2008 - 16:11