コード例 #1
0
        $cursort_type = 'ASC';
    } else {
        $cursort_type = 'DESC';
    }
    $orderBy = " {$cursort} {$cursort_type}";
} else {
    $orderBy = " dCreatedDate DESC ";
}
## ENDS HERE ###
/*	if(trim($stype) != '') {
		// if($stype == 'act')
	}
*/
$limit = " LIMIT " . ($page - 1) * $REC_LIMIT_FRONT . ", " . $REC_LIMIT_FRONT . " ";
$jtbl = "LEFT JOIN " . PRJ_DB_PREFIX . "_country_master cm on BINARY org.vCountry=cm.vCountryCode";
$orglist = $orgObj->getJoinTableInfo($jtbl, "org.iOrganizationID,org.vCompanyName,org.vOrganizationCode,org.eOrganizationType,cm.vCountry,org.eStatus,cm.vCountry", $where, $orderBy, '', $limit, 'yes');
//$orglist = $orgObj->getDetails_PG('*',$where,$orderBy,'',$limit);
$count = $orglist['tot'];
//prints($count);exit;
// print "A".$count."A";
unset($orglist['tot']);
if (!isset($pgajxobj)) {
    require_once SITE_CLASS_GEN . "class.paging-ajax.php";
}
$pgajxobj = new Paging($count, $page, "listorgs", $REC_LIMIT_FRONT);
$paging = $pgajxobj->getListPG($page);
$pgmsg = $pgajxobj->setMessage("Records");
$smarty->assign('orglist', $orglist);
$smarty->assign('count', $count);
$smarty->assign('paging', $paging);
$smarty->assign('pgmsg', $pgmsg);
コード例 #2
0
ファイル: smdashboard.php プロジェクト: nstungxd/F2CA5
//echo $where;
$sql_res = 'CALL GetInbox("SM"," ' . $where . '","","' . $orderBy . '","' . $limit . '")';
// echo $sql_res; exit;
$res = $dbobj->Onlyquery($sql_res);
$smarty->assign("res", $res);
//Prints($res);exit;
// --- Organizations -----------------------------------------------------------------------------------------
if (!isset($orgObj)) {
    require_once SITE_CLASS_APPLICATION . "organization/class.Organization.php";
    $orgObj = new Organization();
}
//	$jTable = Array(" LEFT JOIN ".PRJ_DB_PREFIX."_country_master cm "," LEFT JOIN ".PRJ_DB_PREFIX."_security_manager sm ");
//	$jOn = Array(" org.vCountry=cm.vCountryCode "," org.iVerifiedSMID=sm.iSMID ");
//	$activeorgs = $orgObj->getJoinTableInfo($jTable,$jOn,"org.*,cm.vCountry as vCountryName,CONCAT(sm.vFirstName,' ',sm.vLastName) as vVerifiedBy"," AND org.eStatus='Active'"," dVerifiedDate DESC ",''," LIMIT 0,3",'yes');
$jtbl = " LEFT JOIN " . PRJ_DB_PREFIX . "_country_master cm on org.vCountry=cm.vCountryCode LEFT JOIN " . PRJ_DB_PREFIX . "_security_manager sm on org.iVerifiedSMID=sm.iSMID ";
$activeorgs = $orgObj->getJoinTableInfo($jtbl, "org.*,cm.vCountry as vCountryName,CONCAT(sm.vFirstName,' ',sm.vLastName) as vVerifiedBy", " AND org.eStatus='Active'", " org.dVerifiedDate DESC ", ' org.iOrganizationID ', " LIMIT 0,3", 'yes');
$tot_activeorgs = $activeorgs['tot'];
unset($activeorgs['tot']);
//	$orgstoverify = $orgObj->getDetails("*"," AND (eStatus='Need to Verify' OR eStatus='Modified')"," dVerifiedDate DESC ",''," LIMIT 0,3");
$jtbl = " LEFT JOIN " . PRJ_DB_PREFIX . "_country_master cm on org.vCountry=cm.vCountryCode ";
$orgstoverify = $orgObj->getJoinTableInfo($jtbl, "org.*,cm.vCountry as vCountryName", " AND (org.eStatus='Need to Verify' OR org.eStatus='Modified')", " org.dCreatedDate DESC ", ' org.iOrganizationID ', " LIMIT 0,3", 'yes');
$tot_orgstoverify = $orgstoverify['tot'];
unset($orgstoverify['tot']);
// prints($activeorgs); exit;
$smarty->assign("activeorgs", $activeorgs);
$smarty->assign("tot_activeorgs", $tot_activeorgs);
$smarty->assign("orgstoverify", $orgstoverify);
$smarty->assign("tot_orgstoverify", $tot_orgstoverify);
// -----------------------------------------------------------------------------------------------------------
// --- Organization Associations -----------------------------------------------------------------------------
if (!isset($orgAssocObj)) {