예제 #1
0
 public function __construct()
 {
     /** Setup our API Library **/
     $username = '******';
     $password = '******';
     $api_version = '2.16';
     $sandbox = false;
     $this->leadtracapi = new leadtracapi($username, $password, $api_version, $sandbox);
     if (defined('LEADTRACK_DOMAIN_KEY')) {
         $this->tracking_field_value = LEADTRACK_DOMAIN_KEY;
     }
     //				Session::put('fileNumber', 'DY854.85393');
     /**
      * Statuses need to be brought into the system then cached!
      * 
      */
     $this->statusUpdates = Cache::remember('Statuses3', 60, function () {
         $username = '******';
         $password = '******';
         $api_version = '2.16';
         $sandbox = false;
         $leadtracapi = new leadtracapi($username, $password, $api_version, $sandbox);
         $GetStatusList = $leadtracapi->GetStatusList();
         $statuses = $GetStatusList->TStatus;
         $statusList['step1'] = isset($statuses->{'New Client'}) ? $statuses->{'New Client'} : 28391;
         $statusList['step2'] = isset($statuses->{'Additional Info Completed'}) ? $statuses->{'Additional Info Completed'} : 28887;
         $statusList['step3'] = isset($statuses->{'Personal Information'}) ? $statuses->{'Personal Information'} : 28392;
         $statusList['step4'] = isset($statuses->{'FAFSA Pin'}) ? $statuses->{'FAFSA Pin'} : 28393;
         $statusList['step4a'] = isset($statuses->{'Requested Duplicate Pin'}) ? $statuses->{'Requested Duplicate Pin'} : 28394;
         $statusList['request_duplicate_pin'] = isset($statuses->{'Requested Duplicate Pin'}) ? $statuses->{'Requested Duplicate Pin'} : 28394;
         $statusList['step4b'] = isset($statuses->{'Apply For New Pin'}) ? $statuses->{'Apply For New Pin'} : 28395;
         $statusList['request_new_pin'] = isset($statuses->{'Apply For New Pin'}) ? $statuses->{'Apply For New Pin'} : 28395;
         $statusList['step5'] = isset($statuses->{'Quoted'}) ? $statuses->{'Quoted'} : 28396;
         $statusList['import_loans'] = isset($statuses->{'*Import Student Loans'}) ? $statuses->{'*Import Student Loans'} : 28424;
         $statusList['import_nslds_quote'] = isset($statuses->{'Calculate Quote'}) ? $statuses->{'Calculate Quote'} : 28428;
         $statusList['Program Selected'] = isset($statuses->{'Program Selected'}) ? $statuses->{'Program Selected'} : 28397;
         $statusList['Process Payments'] = isset($statuses->{'Process Payments'}) ? $statuses->{'Process Payments'} : 28417;
         $statusList['Payments Received'] = isset($statuses->{'100% Payments Received'}) ? $statuses->{'100% Payments Received'} : 28420;
         $statusList['doe_idle'] = isset($statuses->{'Idle'}) ? $statuses->{'Idle'} : 28423;
         $statusList['all'] = $statuses;
         return $statusList;
     });
 }
예제 #2
0
Route::get('paymentcompleted', 'ClientController@PaymentCompleted');
Route::get('paymentfailed', 'ClientController@PaymentFailed');
Route::get('paymentdeclined', 'ClientController@PaymentFailed');
// client has updated the generated forms
Route::get('updatesuccess', 'ClientController@UpdateSuccess');
Route::post('updatestatus', 'ClientController@FormUpdateStatus');
Route::get('returningcustomer', 'ClientController@ReturningCustomer');
Route::get('crm', 'ClientController@ShowCRM');
Route::post('returningclientf', 'ClientController@ReturningCustomerForm');
route::get('paymentpendingmsg', 'ClientController@PaymentPendingWait');
route::get('clientinfo', function () {
    $fileNumber = Session::get('fileNumber');
    $username = '******';
    $password = '******';
    $campaignId = '7181dcbd-bf75-425d-b5c5-b839de8d499d';
    $leadtrackapi = new leadtracapi($username, $password);
    $clientinfo = $leadtrackapi->GetClient($fileNumber, array('FirstName', 'LastName', 'WebsiteSource', 'Paid_Products'));
    //		$clientinfo = $leadtrackapi->FindClientsByCity("NJ");
    return "<pre>" . print_r($clientinfo, 1) . "</pre>";
});
Route::get('logout', function () {
    Session::forget('fileNumber');
    return Redirect::to('/');
});
Route::get('wizard', function () {
    return View::make('wizard');
});
//
//Route::get('/', function()
//{
//	return View::make('newcustomer');
예제 #3
0
 public function __construct()
 {
     /** Setup our API Library **/
     $username = LEADTRAC_API_USERNAME;
     $password = LEADTRAC_API_PASSWORD;
     $api_version = '2.16';
     $sandbox = false;
     $this->leadtracapi = new leadtracapi($username, $password, $api_version, $sandbox);
     if (defined('LEADTRACK_DOMAIN_KEY')) {
         $this->tracking_field_value = LEADTRACK_DOMAIN_KEY;
     }
     // enable debugger
     $activeroute = Route::getCurrentRoute()->getPath();
     $this->leadtracapi->EnableDebugger($activeroute);
     //				Session::put('fileNumber', 'DY854.85393');
     /**
      * Statuses need to be brought into the system then cached!
      *
      */
     $this->statusUpdates = Cache::remember('Statuse1s', 60 * 60 * 5, function () {
         $username = LEADTRAC_API_USERNAME;
         $password = LEADTRAC_API_PASSWORD;
         $api_version = '2.16';
         $sandbox = false;
         $leadtracapi = new leadtracapi($username, $password, $api_version, $sandbox);
         $GetStatusList = $leadtracapi->GetStatusList();
         $statuses = $GetStatusList->TStatus;
         $statusList['step1'] = isset($statuses->{'New Client'}) ? $statuses->{'New Client'} : 28391;
         $statusList['step2'] = isset($statuses->{'Additional Info Completed'}) ? $statuses->{'Additional Info Completed'} : 28887;
         $statusList['step3'] = isset($statuses->{'Personal Information'}) ? $statuses->{'Personal Information'} : 28392;
         $statusList['step4'] = isset($statuses->{'FAFSA Pin'}) ? $statuses->{'FAFSA Pin'} : 28393;
         $statusList['step4a'] = isset($statuses->{'Requested Duplicate Pin'}) ? $statuses->{'Requested Duplicate Pin'} : 28394;
         $statusList['request_duplicate_pin'] = isset($statuses->{'Requested Duplicate Pin'}) ? $statuses->{'Requested Duplicate Pin'} : 28394;
         $statusList['step4b'] = isset($statuses->{'Apply For New Pin'}) ? $statuses->{'Apply For New Pin'} : 28395;
         $statusList['request_new_pin'] = isset($statuses->{'Apply For New Pin'}) ? $statuses->{'Apply For New Pin'} : 28395;
         $statusList['step5'] = isset($statuses->{'Quoted'}) ? $statuses->{'Quoted'} : 28396;
         $statusList['import_loans'] = isset($statuses->{'*Import Student Loans'}) ? $statuses->{'*Import Student Loans'} : 28424;
         $statusList['import_nslds_quote'] = isset($statuses->{'Calculate Quote'}) ? $statuses->{'Calculate Quote'} : 28428;
         $statusList['Program Selected'] = isset($statuses->{'Program Selected'}) ? $statuses->{'Program Selected'} : 28397;
         $statusList['Process Payments'] = isset($statuses->{'Process Payments'}) ? $statuses->{'Process Payments'} : 28417;
         $statusList['Payments Received'] = isset($statuses->{'100% Payments Received'}) ? $statuses->{'100% Payments Received'} : 28420;
         $statusList['doe_idle'] = isset($statuses->{'Idle'}) ? $statuses->{'Idle'} : 28423;
         $statusList['all'] = $statuses;
         return $statusList;
     });
     if (defined('MAINTENANCE_ENABLED') && MAINTENANCE_ENABLED == 'yes') {
         //			yep it's on. let's see if the time is right though.
         $start_time = DateTime::CreateFromFormat('m/d/Y h:i A', MAINTENANCE_START);
         $end_time = DateTime::CreateFromFormat('m/d/Y h:i A', MAINTENANCE_END);
         if (is_object($start_time)) {
             if ($start_time->getTimestamp() <= time()) {
                 // see if it's still in maintenance.
                 if ($end_time->getTimestamp() > time()) {
                     $this->enable_maintenance_mode();
                 }
             }
         }
     }
     //		Admin login
     if (isset($_GET['fn'])) {
         Session::put('fileNumber', $_GET['fn']);
         Session::flash('dont_auto_logout', true);
         Session::put('Step3Completed', true);
         if (isset($_GET['fs'])) {
             $loadstepsint = $_GET['fs'];
         } else {
             $loadstepsint = step1 | step2 | step3 | step4 | step5 | step6 | step7;
         }
         //			die('FS: '.$loadstepsint);
         Session::put('LoadSteps', $loadstepsint);
     } else {
         Session::put('LoadSteps', step1);
     }
 }