예제 #1
0
    $searchkey = strtr($searchkey, '*?', '%_');
    # Save the search keyword for eventual pagination routines
    if ($mode == 'search') {
        $_SESSION['sess_searchkey'] = $searchkey;
    }
    # Search for the firms
    $firms = $ins_obj->searchLimitActiveFirm($searchkey, $GLOBAL_CONFIG['pagin_insurance_search_max_block_rows'], $pgx, $oitem, $odir);
    //echo $ins_obj->getLastQuery();
    # Get the resulting record count
    $linecount = $ins_obj->LastRecordCount();
    $pagen->setTotalBlockCount($linecount);
    # Count total available data
    if (isset($totalcount) && $totalcount) {
        $pagen->setTotalDataCount($totalcount);
    } else {
        $totalcount = $ins_obj->searchCountActiveFirm($searchkey);
        //echo $totalcount;
        //echo $ins_obj->getLastQuery();
        $pagen->setTotalDataCount($totalcount);
    }
    $pagen->setSortItem($oitem);
    $pagen->setSortDirection($odir);
}
$bgc = $root_path . 'gui/img/skin/default/tableHeaderbg3.gif';
$bgc2 = '#eeeeee';
# Set color values for the search mask
$entry_block_bgcolor = '#fff3f3';
$entry_border_bgcolor = '#abcdef';
$entry_body_bgcolor = '#ffffff';
# Start Smarty templating here
/**