'name', 'description', 'format', 'courseid', 'groupid', 'userid',
'repeatid', 'modulename', 'instance', 'type', 'eventtype', 'timestart',
'timeduration', 'timesort', 'visible', 'uuid', 'sequence', 'timemodified',
- 'priority'));
+ 'priority', 'location'));
// Build the tree
$events->add_child($event);
'uuid' => $data->uuid,
'sequence' => $data->sequence,
'timemodified' => $data->timemodified,
- 'priority' => isset($data->priority) ? $data->priority : null);
+ 'priority' => isset($data->priority) ? $data->priority : null,
+ 'location' => isset($data->location) ? $data->location : null);
if ($this->name == 'activity_calendar') {
$params['instance'] = $this->task->get_activityid();
} else {
$event->get_id()
);
$data->descriptionformat = $event->get_description()->get_format();
+ $data->location = htmlspecialchars($event->get_location());
$data->groupid = $groupid;
$data->userid = $userid;
$data->categoryid = $categoryid;
'default' => null,
'null' => NULL_ALLOWED
],
+ 'location' => [
+ 'type' => PARAM_RAW_TRIMMED,
+ 'optional' => true,
+ 'default' => null,
+ 'null' => NULL_ALLOWED
+ ],
'categoryid' => [
'type' => PARAM_INT,
'optional' => true,
return $this->event->get_description();
}
+ public function get_location() {
+ return $this->event->get_location();
+ }
+
public function get_category() {
return $this->event->get_category();
}
*/
protected $description;
+ /**
+ * @var string $location Location of this event.
+ */
+ protected $location;
+
/**
* @var proxy_interface $category Category for this event.
*/
* @param times_interface $times The times associated with the event.
* @param bool $visible The event's visibility. True for visible, false for invisible.
* @param proxy_interface $subscription The event's subscription.
+ * @param string $location The event's location.
*/
public function __construct(
$id,
$type,
times_interface $times,
$visible,
- proxy_interface $subscription = null
+ proxy_interface $subscription = null,
+ $location = null
) {
$this->id = $id;
$this->name = $name;
$this->description = $description;
+ $this->location = $location;
$this->category = $category;
$this->course = $course;
$this->group = $group;
return $this->description;
}
+ public function get_location() {
+ return $this->location;
+ }
+
public function get_category() {
return $this->category;
}
*/
public function get_description();
+ /**
+ * Get the event's location.
+ *
+ * @return location_interface
+ */
+ public function get_location();
+
/**
* Get the category object associated with the event.
*
(new \DateTimeImmutable())->setTimestamp($dbrow->timemodified)
),
!empty($dbrow->visible),
- $subscription
+ $subscription,
+ $dbrow->location
);
$isactionevent = !empty($dbrow->type) && $dbrow->type == CALENDAR_EVENT_TYPE_ACTION;
$mform->setType('description', PARAM_RAW);
$mform->setAdvanced('description');
+ $mform->addElement('text', 'location', get_string('location', 'moodle'), 'size="50"');
+ $mform->setType('location', PARAM_RAW_TRIMMED);
+ $mform->setAdvanced('location');
+
// Add the variety of elements allowed for selecting event duration.
$this->add_event_duration_elements($mform);
'id' => $coalesce('id'),
'name' => $coalesce('name'),
'description' => $coalesce('description'),
+ 'location' => $coalesce('location'),
'format' => $coalesce('format'),
'categoryid' => $coalesce('categoryid'),
'courseid' => $coalesce('courseid'),
'name' => $event->get_name(),
'description' => $event->get_description()->get_value(),
'format' => $event->get_description()->get_format(),
+ 'location' => $event->get_location(),
'courseid' => $event->get_course() ? $event->get_course()->get('id') : null,
'categoryid' => $event->get_category() ? $event->get_category()->get('id') : null,
'groupid' => $event->get_group() ? $event->get_group()->get('id') : null,
$eventdetails = (object) [
'name' => $event->name,
'description' => $event->description,
+ 'location' => $event->location,
'eventtype' => $event->eventtype,
'timestart' => transform::datetime($event->timestart),
'timeduration' => $event->timeduration
details.id as eventid,
details.name as name,
details.description as description,
+ details.location as location,
details.eventtype as eventtype,
details.timestart as timestart,
details.timeduration as timeduration
$ev->add_property('class', 'PUBLIC'); // PUBLIC / PRIVATE / CONFIDENTIAL
$ev->add_property('last-modified', Bennu::timestamp_to_datetime($event->timemodified));
+
+ if (!empty($event->location)) {
+ $ev->add_property('location', $event->location);
+ }
+
$ev->add_property('dtstamp', Bennu::timestamp_to_datetime()); // now
if ($event->timeduration > 0) {
//dtend is better than duration, because it works in Microsoft Outlook and works better in Korganizer
\core_date::set_default_server_timezone();
}
+ $eventrecord->location = empty($event->properties['LOCATION'][0]->value) ? '' :
+ str_replace('\\', '', $event->properties['LOCATION'][0]->value);
$eventrecord->uuid = $event->properties['UID'][0]->value;
$eventrecord->timemodified = time();
</a>
{{/canedit}}
</div>
- {{#icon}}{{#pix}} {{key}}, {{component}}, {{alttext}} {{/pix}}{{/icon}}
- <h3 class="name d-inline-block">{{name}}</h3>
- <span class="date pull-xs-right m-r-1">{{{formattedtime}}}</span>
+ {{#icon}}<div class="d-inline-block mt-1 align-top">{{#pix}} {{key}}, {{component}}, {{alttext}} {{/pix}}</div>{{/icon}}
+ <div class="d-inline-block">
+ <h3 class="name d-inline-block">{{name}}</h3>
+ <span class="date pull-xs-right m-r-1">{{{formattedtime}}}</span>
+ <div class="location">{{#location}}{{{location}}}{{/location}}</div>
+ </div>
</div>
<div class="description card-block calendar_event_{{eventtype}}">
<p>{{{description}}}</p>
{
"timestart": 1490320388,
"description": "An random event description",
+ "location": "13th floor, building 42",
"eventtype": "User",
"source": "Ical imported",
"groupname": "Group 1"
<div class="description-content col-xs-11">{{{.}}}</div>
</div>
{{/description}}
+ {{#location}}
+ <div class="row m-t-1">
+ <div class="col-xs-1">{{#pix}} i/location, core, {{#str}} location {{/str}} {{/pix}}</div>
+ <div class="location-content col-xs-11">{{{.}}}</div>
+ </div>
+ {{/location}}
{{#isactionevent}}
<div class="row m-t-1">
<div class="col-xs-1">{{#pix}} i/courseevent, core, {{#str}} course {{/str}} {{/pix}}</div>
return new event_description('asdf', 1);
}
+ public function get_location() {
+ return 'Cube office';
+ }
+
public function get_category() {
return new \stdClass();
}
| Type of event | site |
| Event title | Really awesome event! |
| Description | Come join this awesome event, sucka! |
+ | Location | Cube office |
And I log out
And I log in as "student1"
And I am on "Course 1" course homepage
| Course | Course 1 |
| Event title | Really awesome event! |
| Description | Come join this awesome event, sucka! |
+ | Location | Cube office |
And I log out
And I log in as "student1"
When I am on "Course 1" course homepage
| Group | Group 1 |
| Event title | Really awesome event! |
| Description | Come join this awesome event |
+ | Location | Cube office |
And I log out
And I log in as "student1"
When I am on "Course 1" course homepage
| Type of event | user |
| Event title | Really awesome event! |
| Description | Come join this awesome event, sucka! |
+ | Location | Cube office |
And I log out
And I log in as "student1"
When I am on "Course 1" course homepage
| Type of event | user |
| Event title | Really awesome event! |
| Description | Come join this awesome event, sucka! |
+ | Location | Cube office |
And I am on "Course 1" course homepage
When I follow "This month"
And I click on "Really awesome event!" "link"
And I set the following fields to these values:
| Event title | Mediocre event :( |
| Description | Wait, this event isn't that great. |
+ | Location | The park |
And I press "Save"
Then I should see "Mediocre event"
And I set the following fields to these values:
| Event title | Event on 2-20-2017 |
| Description | Event on 2-20-2017 |
+ | Location | Some place |
| timestart[day] | 20 |
And I press "Save"
When I view the calendar for "2" "2017"
$this->assertEquals($dbrow->description, $event->get_description()->get_value());
$this->assertEquals($dbrow->format, $event->get_description()->get_format());
$this->assertEquals($dbrow->courseid, $event->get_course()->get('id'));
+ $this->assertEquals($dbrow->location, $event->get_location());
if ($dbrow->groupid == 0) {
$this->assertNull($event->get_group());
$event = new \stdClass();
$event->name = 'An event';
$event->description = 'Event description';
+ $event->location = 'Event location';
$event->format = FORMAT_HTML;
$event->eventtype = \core_completion\api::COMPLETION_EVENT_TYPE_DATE_COMPLETION_EXPECTED;
$event->userid = 1;
$event = new \stdClass();
$event->name = 'An event';
$event->description = 'Event description';
+ $event->location = 'Event location';
$event->format = FORMAT_HTML;
$event->eventtype = 'close';
$event->userid = $user->id;
'timesort' => 1486396800,
'visible' => 1,
'timemodified' => 1485793098,
- 'subscriptionid' => null
+ 'subscriptionid' => null,
+ 'location' => 'Test location',
]
],
'timesort' => 1486396800,
'visible' => 1,
'timemodified' => 1485793098,
- 'subscriptionid' => null
+ 'subscriptionid' => null,
+ 'location' => 'Test location',
]
]
];
'timesort' => 1486396800,
'visible' => 1,
'timemodified' => 1485793098,
- 'subscriptionid' => null
+ 'subscriptionid' => null,
+ 'location' => 'Test location',
];
foreach ((array) $skeleton as $key => $value) {
'timemodified' => 123456789,
'timesort' => 123456789,
'visible' => 1,
- 'subscriptionid' => 1
+ 'subscriptionid' => 1,
+ 'location' => 'Test location',
]
);
}
'timemodified' => 123456789,
'timesort' => 123456789,
'visible' => 1,
- 'subscriptionid' => 1
+ 'subscriptionid' => 1,
+ 'location' => 'Test location',
]
);
}
'timemodified' => 123456789,
'timesort' => 123456789,
'visible' => 1,
- 'subscriptionid' => 1
+ 'subscriptionid' => 1,
+ 'location' => 'Test location',
]
);
}
'timemodified' => 123456789,
'timesort' => 123456789,
'visible' => 1,
- 'subscriptionid' => 1
+ 'subscriptionid' => 1,
+ 'location' => 'Test location',
]
);
'timemodified' => 123456789,
'timesort' => 123456789,
'visible' => 1,
- 'subscriptionid' => 1
+ 'subscriptionid' => 1,
+ 'location' => 'Test location',
]
);
'timemodified' => 123456789,
'timesort' => 123456789,
'visible' => true,
- 'subscriptionid' => 1
+ 'subscriptionid' => 1,
+ 'location' => 'Test location',
],
'actioncallbackapplier' => function(event_interface $event) {
$event->testattribute = 'Hello';
'timemodified' => 123456789,
'timesort' => 123456789,
'visible' => true,
- 'subscriptionid' => 1
+ 'subscriptionid' => 1,
+ 'location' => 'Test location',
],
'actioncallbackapplier' => function(event_interface $event) {
$event->testattribute = 'Hello';
'timemodified' => 123456789,
'timesort' => 123456789,
'visible' => true,
- 'subscriptionid' => 1
+ 'subscriptionid' => 1,
+ 'location' => 'Test location',
],
'actioncallbackapplier' => function(event_interface $event) {
$event->testattribute = 'Hello';
return $this->event->get_description();
}
+ public function get_location() {
+ return $this->event->get_location();
+ }
+
public function get_category() {
return $this->event->get_category();
}
/**
* Constructor.
*
- * @param calendar_event $legacyevent Legacy event to exctract IDs etc from.
+ * @param calendar_event $legacyevent Legacy event to extract IDs etc from.
*/
public function __construct($legacyevent = null) {
if ($legacyevent) {
return new event_description('asdf', 1);
}
+ public function get_location() {
+ return 'Cube office';
+ }
+
public function get_category() {
return $this->categoryproxy;
}
$constructorparams['type'],
$constructorparams['times'],
$constructorparams['visible'],
- $constructorparams['subscription']
+ $constructorparams['subscription'],
+ $constructorparams['location']
);
foreach ($constructorparams as $name => $value) {
(new \DateTimeImmutable())->setTimestamp(time())
),
'visible' => true,
- 'subscription' => new std_proxy(1, $lamecallable)
+ 'subscription' => new std_proxy(1, $lamecallable),
+ 'location' => 'Test',
]
],
];
'text' => '',
'format' => 1,
],
+ 'location' => 'Test',
'duration' => 1,
'timedurationuntil' => [
'day' => $timedurationuntil->format('j'),
'format' => 1,
'itemid' => 0
],
+ 'location' => 'Test',
'duration' => 1,
'timedurationuntil' => [
'day' => $timedurationuntil->format('j'),
'text' => '',
'format' => 1,
],
+ 'location' => 'Test',
'duration' => 1,
'timedurationuntil' => [
'day' => $timedurationuntil->format('j'),
'format' => 1,
'itemid' => 0
],
+ 'location' => 'Test',
'duration' => 1,
'timedurationuntil' => [
'day' => $timedurationuntil->format('j'),
'text' => '',
'format' => 1,
],
+ 'location' => 'Test',
'duration' => 1,
'timedurationuntil' => [
'day' => $timedurationuntil->format('j'),
'format' => 1,
'itemid' => 0,
],
+ 'location' => 'Test',
'duration' => 1,
'timedurationuntil' => [
'day' => $timedurationuntil->format('j'),
'text' => '',
'format' => 1,
],
+ 'location' => 'Test',
'duration' => 1,
'timedurationuntil' => [
'day' => $timedurationuntil->format('j'),
'text' => '',
'format' => 1,
],
+ 'location' => 'Test',
'duration' => 1,
'timedurationuntil' => [
'day' => $timedurationuntil->format('j'),
'format' => 1,
'itemid' => 0
],
+ 'location' => 'Test',
'duration' => 1,
'timedurationuntil' => [
'day' => $timedurationuntil->format('j'),
'format' => 1,
'itemid' => 0
],
+ 'location' => 'Test',
'duration' => 1,
'timedurationuntil' => [
'day' => $timedurationuntil->format('j'),
'format' => 1,
'itemid' => 0
],
+ 'location' => 'Test',
'duration' => 1,
'timedurationuntil' => [
'day' => $timedurationuntil->format('j'),
'text' => '',
'format' => 1,
],
+ 'location' => 'Test',
'duration' => 1,
'timedurationuntil' => [
'day' => $timedurationuntil->format('j'),
DESCRIPTION:Event on 2-25-2017
CLASS:PUBLIC
LAST-MODIFIED:20170226T014258Z
+LOCATION:Some place
DTSTAMP:20170226T014355Z
DTSTART;VALUE=DATE:20170224
DTEND;VALUE=DATE:20170225
(new \DateTimeImmutable())->setTimestamp($record->timemodified)
),
!empty($record->visible),
- $subscription
+ $subscription,
+ $record->location
);
$action = new action(
[
'name' => 'Start of assignment',
'description' => '',
+ 'location' => 'Test',
'format' => 1,
'courseid' => $course->id,
'groupid' => 0,
], [
'name' => 'Start of lesson',
'description' => '',
+ 'location' => 'Test',
'format' => 1,
'courseid' => $course->id,
'groupid' => 0,
[
'name' => 'Assignment 1 due date',
'description' => '',
+ 'location' => 'Test',
'format' => 0,
'courseid' => $course->id,
'groupid' => 0,
], [
'name' => 'Assignment 1 due date - User override',
'description' => '',
+ 'location' => 'Test',
'format' => 1,
'courseid' => 0,
'groupid' => 0,
], [
'name' => 'Assignment 1 due date - Group A override',
'description' => '',
+ 'location' => 'Test',
'format' => 1,
'courseid' => $course->id,
'groupid' => $group1->id,
], [
'name' => 'Assignment 1 due date - Group B override',
'description' => '',
+ 'location' => 'Test',
'format' => 1,
'courseid' => $course->id,
'groupid' => $group2->id,
[
'name' => 'Repeating site event',
'description' => '',
+ 'location' => 'Test',
'format' => 1,
'courseid' => SITEID,
'groupid' => 0,
[
'name' => 'Repeating site event',
'description' => '',
+ 'location' => 'Test',
'format' => 1,
'courseid' => SITEID,
'groupid' => 0,
[
'name' => 'Start of assignment',
'description' => '',
+ 'location' => 'Test',
'format' => 1,
'courseid' => $course->id,
'groupid' => 0,
], [
'name' => 'Start of lesson',
'description' => '',
+ 'location' => 'Test',
'format' => 1,
'courseid' => $course->id,
'groupid' => 0,
[
'name' => 'Assignment 1 due date',
'description' => '',
+ 'location' => 'Test',
'format' => 0,
'courseid' => $course->id,
'groupid' => 0,
], [
'name' => 'Assignment 1 due date - User override',
'description' => '',
+ 'location' => 'Test',
'format' => 1,
'courseid' => 0,
'groupid' => 0,
], [
'name' => 'Assignment 1 due date - Group A override',
'description' => '',
+ 'location' => 'Test',
'format' => 1,
'courseid' => $course->id,
'groupid' => $group1->id,
], [
'name' => 'Assignment 1 due date - Group B override',
'description' => '',
+ 'location' => 'Test',
'format' => 1,
'courseid' => $course->id,
'groupid' => $group2->id,
[
'name' => 'Repeating site event',
'description' => '',
+ 'location' => 'Test',
'format' => 1,
'courseid' => SITEID,
'groupid' => 0,
[
'name' => 'Repeating site event',
'description' => '',
+ 'location' => 'Test',
'format' => 1,
'courseid' => SITEID,
'groupid' => 0,
[
'name' => 'Start of assignment',
'description' => '',
+ 'location' => 'Test',
'format' => 1,
'courseid' => $course->id,
'groupid' => 0,
], [
'name' => 'Start of lesson',
'description' => '',
+ 'location' => 'Test',
'format' => 1,
'courseid' => $course->id,
'groupid' => 0,
[
'name' => 'Assignment 1 due date',
'description' => '',
+ 'location' => 'Test',
'format' => 0,
'courseid' => $course->id,
'groupid' => 0,
], [
'name' => 'Assignment 1 due date - User override',
'description' => '',
+ 'location' => 'Test',
'format' => 1,
'courseid' => 0,
'groupid' => 0,
], [
'name' => 'Assignment 1 due date - Group A override',
'description' => '',
+ 'location' => 'Test',
'format' => 1,
'courseid' => $course->id,
'groupid' => $group1->id,
], [
'name' => 'Assignment 1 due date - Group B override',
'description' => '',
+ 'location' => 'Test',
'format' => 1,
'courseid' => $course->id,
'groupid' => $group2->id,
[
'name' => 'Repeating site event',
'description' => '',
+ 'location' => 'Test',
'format' => 1,
'courseid' => SITEID,
'groupid' => 0,
[
'name' => 'Repeating site event',
'description' => '',
+ 'location' => 'Test',
'format' => 1,
'courseid' => SITEID,
'groupid' => 0,
'name' => 'E1',
'eventtype' => 'category',
'description' => '',
+ 'location' => 'Test',
'format' => 1,
'categoryid' => $category1->id,
'userid' => 2,
'name' => 'E2',
'eventtype' => 'category',
'description' => '',
+ 'location' => 'Test',
'format' => 1,
'categoryid' => $category2->id,
'userid' => 2,
$this->assertCount(2, $events);
}
}
-
(new \DateTimeImmutable())->setTimestamp($dbrow->timemodified)
),
!empty($dbrow->visible),
- new std_proxy($dbrow->subscriptionid, $identity)
+ new std_proxy($dbrow->subscriptionid, $identity),
+ $dbrow->location
);
}
}
'core:i/item' => 'fa-circle',
'core:i/loading' => 'fa-circle-o-notch fa-spin',
'core:i/loading_small' => 'fa-circle-o-notch fa-spin',
+ 'core:i/location' => 'fa-map-marker',
'core:i/lock' => 'fa-lock',
'core:i/log' => 'fa-list-alt',
'core:i/mahara_host' => 'fa-id-badge',
<FIELD NAME="timemodified" TYPE="int" LENGTH="10" NOTNULL="true" DEFAULT="0" SEQUENCE="false"/>
<FIELD NAME="subscriptionid" TYPE="int" LENGTH="10" NOTNULL="false" SEQUENCE="false" COMMENT="The event_subscription id this event is associated with."/>
<FIELD NAME="priority" TYPE="int" LENGTH="10" NOTNULL="false" SEQUENCE="false" COMMENT="The event's display priority. For multiple events with the same module name, instance and eventtype (e.g. for group overrides), the one with the higher priority will be displayed."/>
+ <FIELD NAME="location" TYPE="text" NOTNULL="false" SEQUENCE="false" COMMENT="Meeting Location"/>
</FIELDS>
<KEYS>
<KEY NAME="primary" TYPE="primary" FIELDS="id"/>
// Automatically generated Moodle v3.5.0 release upgrade line.
// Put any upgrade step following this.
+ if ($oldversion < 2018062800.01) {
+ // Define field location to be added to event.
+ $table = new xmldb_table('event');
+ $field = new xmldb_field('location', XMLDB_TYPE_TEXT, null, null, null, null, null, 'priority');
+
+ // Conditionally launch add field location.
+ if (!$dbman->field_exists($table, $field)) {
+ $dbman->add_field($table, $field);
+ }
+
+ // Main savepoint reached.
+ upgrade_main_savepoint(true, 2018062800.01);
+ }
+
return true;
}
--- /dev/null
+<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd" [\r
+ <!ENTITY ns_flows "http://ns.adobe.com/Flows/1.0/">\r
+]><svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 16 16" preserveAspectRatio="xMinYMid meet" overflow="visible"><path d="M14.7 12.3c0-.1 0-.1 0 0 .2-.4.4-.6.5-.9 0-.1 0-.1.1-.2.1-.3.3-.6.4-1v-.1c.1-.3.1-.6.2-.9v-.3c0-.3.1-.7.1-1 0-4.4-3.6-8-8-8C3.6 0 0 3.6 0 8c0 4.4 3.4 8 7.8 8H9c.2 0 .4 0 .5-.1.7-.1 1.3-.4 1.9-.7.7-.3 1.3-.7 1.8-1.2.6-.6 1.1-1.1 1.5-1.7zm-5 1.4c-.1 0-.1-.1-.2-.1-.3-.1-.7-.2-.8-.5v-.4c0-.1.2-.2.2-.3 0-.1-.1-.3-.1-.4 0-.1 0-.3.1-.4.1-.1.3-.8.5-.6 0 0 .3.2.5.3.1 0 .2 0 .4-.1h.4c.1 0 .2.1.3.1.1 0 .3 0 .4-.1.3 0 .3.1.5.3.1 0 .3 0 .4.1.2.1.1.1.2.3l.1.1c-.9.7-1.8 1.4-2.9 1.7zM3.2 5c0-.2-.1-.3-.1-.5.9-1.2 2.3-2.1 3.8-2.4l-.1.1c-.1.3.5 0 .6.2 0 .1-.3.1-.3.1h-.4c0 .1-.1.2-.2.3 0 .1-.2.2-.2.4 0 .3.4.4.6.4.2 0 .3-.1.5 0 .2 0 0 .2.2.2.1-.1.1-.2.2-.3.1-.2.2-.3.1-.4 0-.1-.1 0-.1-.1l.1-.1v-.3h.8c.1.1 0 .2.2.1 0-.1.1-.3.2-.3s.2.1.3.2c.1.1.2.1.3.2 0 .1 0 .2.1.3.2-.1.4-.2.5 0 .2.2 0 .5-.2.6-.3.2-.5.1-.7.2-.2.1-.3.3-.4.5.1-.1.4-.3.6-.3.2 0 .3.2.4.2.1 0 .6-.1.4.1-.1.1-.3.2-.4.3 0 .1-.3-.1-.5 0-.1 0-.1.3-.2.4-.1.2-.4.4-.5.7 0 .1.1.3 0 .4 0 .2-.1.2-.3.3-.1.1-.3.3-.3.6s.3.5.3.8c-.3 0-.3-.2-.5-.5s-.5-.1-.8 0c-.1.1-.2.2-.4.3-.2 0-.1-.1-.1-.2s-.1-.2-.2-.1c-.1 0-.1.2-.1.3 0 .5-.6 1.1 0 1.4.3.1.6.1.8-.1.1-.2.3-.4.6-.4 0 .2-.2.5-.2.7.1.2.5 0 .7.1.3.1 0 .5.3.7.2.1-.4.3-.7-.1-.2-.3-.4-.3-.7-.4-.3-.1-.4 0-.7 0-.3 0-.6-.1-.8-.2-.2-.1-.3-.4-.5-.5l-.3-.3c-.1-.1-.2-.2-.2-.3-.2-.1-.1-.6-.4-.6 0 .3.2.5.3.7.1.1.1.2.2.3 0 .1.1.2.1.3h-.1c-.2-.1-.5-.3-.6-.5-.2-.2-.3-.4-.4-.7-.1-.2-.1-.5-.2-.7-.2-.2-.4-.4-.4-.6 0-.2.1-.5.1-.7.1-.3 0-.5-.1-.8zm5.5-2.8c-.1 0-.3-.1-.4-.1-.1 0-.2-.1-.2-.1h.6c.1.2.3.3 0 .2z" fill="#999"/></svg>
\ No newline at end of file
}
}
- .event .card-header img {
- vertical-align: baseline;
+ .event {
+ .card-header img {
+ vertical-align: baseline;
+ }
+
+ .location {
+ word-break: break-all;
+ overflow-wrap: break-word;
+ }
}
}
margin: 0;
}
}
+
+ .location-content {
+ overflow-wrap: break-word;
+ }
}
.side {
width: 22px;
}
+ .location {
+ clear: both;
+ word-break: break-all;
+ overflow-wrap: break-word;
+ }
.description {
background-color: @white;
clear: both;
margin: 0;
}
}
+
+ .location-content {
+ overflow-wrap: break-word;
+ }
}
.path-calendar .maincalendar .eventlist .event .side {
width: 22px;
}
+.path-calendar .maincalendar .eventlist .event .location {
+ clear: both;
+ word-break: break-all;
+ overflow-wrap: break-word;
+}
.path-calendar .maincalendar .eventlist .event .description {
background-color: #fff;
clear: both;
.summary-modal-container .description-content > p {
margin: 0;
}
+.summary-modal-container .location-content {
+ overflow-wrap: break-word;
+}
/* course.less */
/* COURSE CONTENT */
/* stylelint-disable unit-blacklist */
--- /dev/null
+{{!
+ This file is part of Moodle - http://moodle.org/
+
+ Moodle is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ Moodle is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with Moodle. If not, see <http://www.gnu.org/licenses/>.
+}}
+{{!
+ @template calendar/event_item
+
+ Calendar event item.
+
+ The purpose of this template is to render the event item.
+
+ Classes required for JS:
+ * none
+
+ Data attributes required for JS:
+ * none
+
+ Example context (json):
+ {
+ }
+}}
+<div{{!
+ }} data-type="event"{{!
+ }} data-course-id="{{course.id}}"{{!
+ }} data-event-id="{{id}}"{{!
+ }} class="event"{{!
+ }} data-eventtype-{{calendareventtype}}="1"{{!
+ }} data-event-title="{{name}}"{{!
+ }} data-event-count="{{eventcount}}"{{!
+ }}>
+ <div class="card">
+ <div class="box card-header clearfix p-y-1">
+ <div class="commands pull-xs-right">
+ {{#canedit}}
+ {{#candelete}}
+ <a href="{{deleteurl}}" data-action="delete">
+ {{#pix}}t/delete, core, {{#str}}delete{{/str}}{{/pix}}
+ </a>
+ {{/candelete}}
+ <a href="{{editurl}}" data-action="edit">
+ {{#pix}}t/edit, core, {{#str}}edit{{/str}}{{/pix}}
+ </a>
+ {{/canedit}}
+ </div>
+ {{#icon}}{{#pix}} {{key}}, {{component}}, {{alttext}} {{/pix}}{{/icon}}
+ <h3 class="name d-inline-block">{{name}}</h3>
+ <span class="date pull-xs-right m-r-1">{{{formattedtime}}}</span>
+ <div class="location">{{#location}}{{{location}}}{{/location}}</div>
+ </div>
+ <div class="description card-block calendar_event_{{eventtype}}">
+ <p>{{{description}}}</p>
+ {{#iscourseevent}}
+ <div><a href="{{url}}">{{course.fullname}}</a></div>
+ {{/iscourseevent}}
+ {{> core_calendar/event_subscription}}
+ {{#isactionevent}}
+ <a href="{{url}}">{{#str}} gotoactivity, core_calendar {{/str}}</a>
+ {{/isactionevent}}
+ {{#groupname}}
+ <div><a href="{{url}}">{{{course.fullname}}}</a></div>
+ <div>{{{groupname}}}</div>
+ {{/groupname}}
+ </div>
+ </div>
+</div>
\ No newline at end of file
{
"timestart": 1490320388,
"description": "An random event description",
+ "location": "13th floor, building 42",
"eventtype": "User",
"source": "Ical imported",
"groupname": "Group 1"
<div class="description-content span11">{{{.}}}</div>
</div>
{{/description}}
+ {{#location}}
+ <div class="row-fluid m-t-1">
+ <div class="span1">{{#pix}} i/location, core, {{#str}} location {{/str}} {{/pix}}</div>
+ <div class="location-content span11">{{{.}}}</div>
+ </div>
+ {{/location}}
{{#isactionevent}}
<div class="row-fluid m-t-1">
<div class="span1">{{#pix}} i/courseevent, core, {{#str}} course {{/str}} {{/pix}}</div>
defined('MOODLE_INTERNAL') || die();
-$version = 2018062800.00; // YYYYMMDD = weekly release date of this DEV branch.
+$version = 2018062800.01; // YYYYMMDD = weekly release date of this DEV branch.
// RR = release increments - 00 in DEV branches.
// .XX = incremental changes.