Merge branch 'spidev' into 'master'
Kalender See merge request fronk/thetool!707
This commit is contained in:
@@ -62,15 +62,19 @@ class CalendarModel
|
||||
{
|
||||
$dbcal = self::dbKalender();
|
||||
$termstring = trim($r->term);
|
||||
$calendars = $r->calendars;
|
||||
|
||||
$termExplode = explode(" ", $termstring);
|
||||
$where = "";
|
||||
foreach ($termExplode as $term) {
|
||||
$where .= " AND (name LIKE '%" . $term . "%' OR location LIKE '%" . $term . "%') ";
|
||||
}
|
||||
$where .= " AND calendar_id IN (" . implode(",",$calendars) . ")";
|
||||
|
||||
|
||||
$res = $dbcal->select("cal_events", "id, uuid, calendar_id, user_id, start_time, end_time, timezone, all_day_event, name, description, location, repeat_end_time, reminder, ctime, mtime, muser_id, busy, status, resource_event_id, private, rrule, background, files_folder_id, read_only, category_id, exception_for_event_id, recurrence_id, is_organizer,event_type", "1=1 $where ORDER BY name");
|
||||
|
||||
|
||||
$rows=array();
|
||||
while ($data = $dbcal->fetch_array($res)) {
|
||||
if ($data['location']) {
|
||||
$searchName = $data['name'] . " @" . $data['location'];
|
||||
|
||||
Reference in New Issue
Block a user