info("Import Step last"); $parenttab = getParenttab(); //This Buttons_List1.tpl is is called to display the add, search, import and export buttons ie., second level tabs $smarty = new vtigerCRM_Smarty; $smarty->assign("MOD", $mod_strings); $smarty->assign("APP", $app_strings); $smarty->assign("IMP", $import_mod_strings); $smarty->assign("THEME", $theme); $smarty->assign("IMAGE_PATH", $image_path); $smarty->assign("MODULE", vtlib_purify($_REQUEST['req_mod'])); $smarty->assign("SINGLE_MOD", vtlib_purify($_REQUEST['modulename'])); $smarty->assign("CATEGORY", vtlib_purify($_SESSION['import_parenttab'])); global $limit; global $list_max_entries_per_page; $implict_account = false; $import_modules_array = Array( "Leads"=>"Leads", "Accounts"=>"Accounts", "Contacts"=>"Contacts", "Potentials"=>"Potentials", "Products"=>"Products", "HelpDesk"=>"ImportTicket", "Vendors"=>"ImportVendors" ); if(!empty($_REQUEST['req_mod'])) { $req_mod = $_REQUEST['req_mod']; checkFileAccess("modules/$req_mod/$req_mod.php"); require_once("modules/$req_mod/$req_mod.php"); if(!isset($import_modules_array[$req_mod])) { $import_modules_array[$req_mod] = $req_mod; } } foreach($import_modules_array as $module_name => $object_name) { $seedUsersLastImport = new UsersLastImport(); $seedUsersLastImport->bean_type = $module_name; $list_query = $seedUsersLastImport->create_list_query($o,$w); $current_module_strings = return_module_language($current_language, $module_name); $object = new $object_name(); $seedUsersLastImport->list_fields = $object->list_fields; $list_result = $adb->query($list_query); //Retreiving the no of rows $noofrows = $adb->num_rows($list_result); if($noofrows < 1) { if($module_name == $_REQUEST['req_mod']) { echo ""; echo "
"; echo "
$app_strings[LBL_NO] $mod_strings[LBL_LAST_IMPORTED] $app_strings[$module_name]
"; echo "
"; } } else { if($module_name != 'Accounts') { $implict_account=true; } if($module_name == 'Accounts' && $implict_account==true) $display_header_msg = "Newly created Accounts"; else $display_header_msg = "".$mod_strings['LBL_LAST_IMPORTED']." ".$app_strings[$module_name].""; //Display the Header Message echo "
".$mod_strings['LBL_LAST_IMPORTED']." ".$app_strings[$module_name]."
"; $smarty = new vtigerCRM_Smarty; $smarty->assign("MOD", $mod_strings); $smarty->assign("APP", $app_strings); $smarty->assign("IMAGE_PATH",$image_path); $smarty->assign("MODULE",$module_name); $smarty->assign("SINGLE_MOD",$module_name); $smarty->assign("SHOW_MASS_SELECT",'false'); //Retreiving the start value from request if($module_name == $_REQUEST['nav_module'] && isset($_REQUEST['start']) && $_REQUEST['start'] != '') { $start = vtlib_purify($_REQUEST['start']); } else { $start = 1; } $info_message='&recordcount='.vtlib_purify($_REQUEST['recordcount']).'&noofrows='.vtlib_purify($_REQUEST['noofrows']).'&message='.vtlib_purify($_REQUEST['message']).'&skipped_record_count='.vtlib_purify($_REQUEST['skipped_record_count']); $url_string = '&modulename='.vtlib_purify($_REQUEST['modulename']).'&nav_module='.$module_name.$info_message; $viewid = ''; //Retreive the Navigation array $navigation_array = getNavigationValues($start, $noofrows, $list_max_entries_per_page); $navigationOutput = getTableHeaderNavigation($navigation_array, $url_string,"Import","ImportSteplast",$viewid); //Retreive the List View Header and Entries $listview_header = getListViewHeader($object,$module_name); $listview_entries = getListViewEntries($object,$module_name,$list_result,$navigation_array,"","","EditView","Delete",""); //commented to remove navigation buttons from import list view //$smarty->assign("NAVIGATION", $navigationOutput); $smarty->assign("HIDE_CUSTOM_LINKS", 1);//Added to hide the CustomView links in imported records ListView // Remove all the links for the list view header as they do not work in this page. for($i=0;$iassign("LISTHEADER", $listview_header); $smarty->assign("LISTENTITY", $listview_entries); // Include required scripts echo ''; echo ''; echo ''; echo ''; echo ''; $smarty->display("ListViewEntries.tpl"); } } ?>