예제 #1
0
 $dt['iRejectedById'] = $_SESSION['SESS_' . PRJ_CONST_PREFIX . '_ID'];
 $dt['eRejectedBy'] = $_SESSION['SESS_' . PRJ_CONST_PREFIX . '_USER_TYPE_SHORT'];
 $dt['dRejectedDate'] = calcGTzTime(date('Y-m-d H:i:s'), 'Y-m-d H:i:s');
 $dt['eStatus'] = $data['eStatus'] = "Active";
 $orgpfdtls = $orgprefObj->getDetails('*', " AND iOrganizationID={$iOrganizationID} ");
 if ($orgpfdtls[0]['eStatus'] == 'Need to Verify') {
     $dt['eStatus'] = $data['eStatus'] = "Inactive";
 } else {
     if ($orgpfdtls[0]['eStatus'] == 'Modified') {
         $dt['eStatus'] = $data['eStatus'] = "Active";
         $data['iModifiedByID'] = "";
         $data['eModifiedBy'] = "";
     }
 }
 $res = $orgprefObj->updateData($data, " iOrganizationID={$iOrganizationID} ");
 $rs = $orgObj->updateData($data, " iOrganizationID={$iOrganizationID} ");
 $verified = $orgvrfObj->getDetails('iVerifiedID', " AND iOrganizationID={$iOrganizationID} ", ' iVerifiedID DESC ', '', ' LIMIT 0,1 ');
 $iVerifiedID = $verified[0]['iVerifiedID'];
 $rs = $orgvrfObj->updateData($dt, " iVerifiedID={$iVerifiedID} ");
 $vrfydtls = $orgPrefVrfObj->getDetails('*', " AND iOrganizationID={$iOrganizationID} ", " AND iVerifiedID DESC", '', " LIMIT 0,1");
 $iVerifiedID = $vrfydtls[0]['iVerifiedID'];
 $rs = $orgPrefVrfObj->updateData($dt, " iVerifiedID={$iVerifiedID} ");
 if ($res) {
     $msg = "rus";
 } else {
     $msg = "ruserr";
 }
 $_SESSION['SESS_' . PRJ_CONST_PREFIX . '_MSG'] = $msg;
 if ($_SESSION['SESS_' . PRJ_CONST_PREFIX . '_USER_TYPE_SHORT'] == 'OA') {
     unset($_SESSION['from']);
     header("Location:" . SITE_URL_DUM . "createorganizationpref/" . $iOrganizationID . "/" . $msg);
예제 #2
0
$sess_usertype_short = $_SESSION['SESS_' . PRJ_CONST_PREFIX . '_USER_TYPE_SHORT'];
if ($mode == 'status') {
    $where = "AND iOrganizationID IN ({$val})";
    $arr = $orgObj->getDetails('*', $where);
    foreach ($arr as $k => $v) {
        $data = $v;
        $data['eNeedToVerify'] = 'Yes';
        $data['iModifiedByID'] = $sess_id;
        $data['eModifiedBy'] = $_SESSION['SESS_' . PRJ_CONST_PREFIX . '_USER_TYPE_SHORT'];
        $data['dModifiedDate'] = date('Y-m-d H:i:s');
        if ($v['eStatus'] == 'Active') {
            $data['eStatus'] = 'Inactive';
            //$orgObj->setAllVar($data);
            $where = "iOrganizationID = " . $v['iOrganizationID'] . "";
            $dtl['eNeedToVerify'] = 'Yes';
            $res = $orgObj->updateData($dtl, $where);
            $orgvrfObj->setAllVar($data);
            $res = $orgvrfObj->insert();
        } elseif ($v['eStatus'] == 'Inactive') {
            $data['eStatus'] = 'Active';
            //$orgObj->setAllVar($data);
            $where = "iOrganizationID = " . $v['iOrganizationID'] . "";
            $dtl['eNeedToVerify'] = 'Yes';
            $res = $orgObj->updateData($dtl, $where);
            //$res = $orgObj->updateData($data, $where);
            $orgvrfObj->setAllVar($data);
            $res = $orgvrfObj->insert();
        } elseif ($v['eStatus'] == 'Modified' || $v['eStatus'] == 'Need to Verify') {
            $var_msg = $smarty->get_template_vars('MSG_VERIFY_NEED_TO_VERIFY_OR_MODIFIED');
            echo $var_msg;
            exit;
예제 #3
0
if (!isset($orgPrefVrfObj)) {
    include_once SITE_CLASS_APPLICATION . "organization/class.OrganizationPreferenceToverify.php";
    $orgPrefVrfObj = new OrganizationPreferenceToverify();
}
$activationcode = GetVar('msg');
if (trim($activationcode) == '') {
    header("Location: " . SITE_URL_DUM . "home");
    exit;
}
//$id = $orgObj->getid($activationcode);
$where = " vActivationCode='{$activationcode}' ";
$data['eStatus'] = 'Active';
$data['vActivationCode'] = '';
$dtls = $orgObj->getDetails('*', ' AND ' . $where);
if (is_array($dtls) && count($dtls) > 0 && isset($dtls[0]['iOrganizationID']) && $dtls[0]['iOrganizationID'] > 0) {
    $rs = $orgObj->updateData($data, $where);
    $r = $orgUsrObj->updateData($data, $where);
    // unset($data['vActivationCode']);
    $s = $orgvrfObj->updateData($data, $where);
    $s = $userToVerifyObj->updateData($data, $where);
    unset($data['vActivationCode']);
    $where = " iOrganizationID = " . $dtls[0]['iOrganizationID'] . "";
    $s = $orgprefObj->updateData($data, $where);
    $opdtls = $orgprefObj->getDetails('*', ' AND ' . $where);
    if (isset($opdtls[0]['iAdditionalInfoID']) && $opdtls[0]['iAdditionalInfoID'] > 0) {
        $where = " iAdditionalInfoID = " . $opdtls[0]['iAdditionalInfoID'] . "";
        $s = $orgPrefVrfObj->updateData($data, $where);
    }
} else {
    header("Location: " . SITE_URL_DUM . "home");
    exit;
예제 #4
0
         } else {
             if ($orgdtls[0]['eStatus'] == 'Modified') {
                 $dt['eStatus'] = $data['eStatus'] = "Active";
                 $data['iModifiedByID'] = "";
                 $data['eModifiedBy'] = "";
             } else {
                 if ($orgdtls[0]['eStatus'] == 'Delete') {
                     $dt['eStatus'] = $data['eStatus'] = "Active";
                     $data['iModifiedByID'] = "";
                     $data['eModifiedBy'] = "";
                 }
             }
         }
     }
 }
 $res = $orgObj->updateData($data, " iOrganizationID={$iOrganizationID} ");
 $vrfydtls = $orgvrfObj->getDetails('*', " AND iOrganizationID={$iOrganizationID} ", " iVerifiedID DESC", '', " LIMIT 0,1");
 if (is_array($vrfydtls) && count($vrfydtls) > 0) {
     $ivrfId = $vrfydtls[0]['iVerifiedID'];
     $rs = $orgvrfObj->updateData($dt, " iVerifiedID={$ivrfId} ");
 }
 if ($res) {
     if (is_array($opf) && count($opf) > 0) {
         $rs = $orgprefObj->updateData($data, "iOrganizationID={$iOrganizationID}");
         $iVerifiedID = $orgPrefVrfObj->getDetails('iVerifiedID', " AND iOrganizationID={$iOrganizationID} ", ' iVerifiedID DESC ', '', ' LIMIT 0,1 ');
         if (is_array($iVerifiedID) && count($iVerifiedID) > 0) {
             $iVerifiedID = $iVerifiedID[0]['iVerifiedID'];
             $rs = $orgPrefVrfObj->updateData($dt, "iVerifiedID={$iVerifiedID}");
             // $iVerifiedID
         }
     }