-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
36 changed files
with
1,194 additions
and
443 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
[] checkout time check, if checkout-checkin > conf.duration only log conf.duration |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
RewriteEngine On | ||
|
||
# Some hosts may require you to use the `RewriteBase` directive. | ||
# If you need to use the `RewriteBase` directive, it should be the | ||
# absolute physical path to the directory that contains this htaccess file. | ||
# | ||
RewriteBase /public_html/attend | ||
|
||
RewriteCond %{REQUEST_FILENAME} !-f | ||
RewriteRule ^ index.php [QSA,L] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
<? | ||
function getTodaysConferences($checkins = NULL) { | ||
$conference_beans = R::find('conference', ' start LIKE ? ORDER BY start ASC ', array(date("Y-m-d").'%')); | ||
$conferences = array(); | ||
foreach ($conference_beans as $bean) { | ||
// only include if current time is earlier than one hour after finish time | ||
if (strtotime($bean->finish) - time() > -3600) { $conferences[] = getConferenceAsArray($bean, $checkins); } | ||
} | ||
|
||
return $conferences; | ||
} | ||
|
||
// UPCOMING CONFERENCES X3 | ||
$future_conferences = R::find('conference', ' start >= ? ORDER BY start ASC ', array(date("Y-m-d"))); | ||
|
||
$data = array( | ||
'future_conferences' => $future_conferences, | ||
'upcoming_conferences' => array_slice($future_conferences, 0, 3), | ||
); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
<? | ||
$postVars = $app->request->post(); | ||
$formErrors = array(); | ||
|
||
if ($postVars["name"] == '') { | ||
$formErrors[] = "Name is required."; | ||
} | ||
|
||
if ($postVars['address'] == '') { | ||
$formErrors[] = "Address is required."; | ||
} | ||
|
||
$nameTest = R::findOne('location', ' name = ? ', array($postVars["name"])); | ||
if (isset($nameTest)) { | ||
$formErrors[] = "That name is already in use."; | ||
} | ||
|
||
$addressTest = R::findOne('location', ' address = ? ', array($postVars["address"])); | ||
if (isset($addressTest)){ | ||
$formErrors[] = "That address is already in use."; | ||
} | ||
|
||
if (empty($formErrors)) { | ||
$location = R::dispense('location'); | ||
$location->name = $postVars["name"]; | ||
$location->address = $postVars["address"]; | ||
$location->lat = $postVars["lat"]; | ||
$location->lng = $postVars["lng"]; | ||
$location->radius = $postVars["radius"]; | ||
$location->favorite = $postVars["favorite"]; | ||
$loc_id = R::store($location); | ||
} | ||
|
||
if (isset($loc_id)) { | ||
$app->flash('message', 'Added location: '.$location->name); | ||
$app->redirect(BASE_URL . '/admin/locations'); | ||
} else { | ||
$app->flash('formErrors', $formErrors); | ||
$app->render('admin/location.html'); | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
<? | ||
$postVars = $app->request->post(); | ||
|
||
$location = R::load('location', $id); | ||
if ($location->id == 0) { | ||
echo ajaxRespond('error', 'Location not found'); | ||
$app->stop(); | ||
} | ||
|
||
if ($postVars["name"] == '') { | ||
echo ajaxRespond('error', 'Location name is required'); | ||
$app->stop(); | ||
} | ||
|
||
if ($postVars['address'] == '') { | ||
echo ajaxRespond('error', 'Location address is required'); | ||
$app->stop(); | ||
} | ||
|
||
$location->name = $postVars["name"]; | ||
$location->address = $postVars["address"]; | ||
$location->lat = $postVars["lat"]; | ||
$location->lng = $postVars["lng"]; | ||
$location->radius = $postVars["radius"]; | ||
$location->favorite = $postVars["favorite"]; | ||
$loc_id = R::store($location); | ||
|
||
if (isset($loc_id)) { | ||
echo ajaxRespond('success', 'Location updated'); | ||
} else { | ||
echo ajaxRespond('error', 'Unable to save updates'); | ||
} | ||
|
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.