query( "select count(*) as count from pre_pro where code = $code" ); } else { $result = $mySqlDb->query( "select count(*) as count from pre_pro where code = $code and protypeid = $type" ); } $rs = $mySqlDb->getRows( $result ); $total = $rs[0]['count']; $perPage = 8; $fileName = "list.php"; $paraList = ""; pageft( $total, $perPage, $fileName, $paraList ); if ( $perPage < $total ) { $smarty->assign( 'pagenav', $pagenav ); } //--------------------------------分页结束------------------------ $returnInfo = $visit->getProductList( $firstcount, $displaypg, $type , $code); if ( ! is_array( $returnInfo ) ) { $smarty->assign( 'isNull', 1 ); } else { $smarty->assign( 'isNull', 0 ); } $smarty->assign( 'list', $returnInfo ); $smarty->display( 'lease/list.tpl.html' ); include_once ( '../bottom.php' ); ?>