You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

97 lines
3.2 KiB

{{!
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 core_message/message_drawer_view_contact_body_content
This template will render the content for the body section of the contact
page in the message drawer.
Classes required for JS:
* none
Data attributes required for JS:
* All data attributes are required
Context variables required for this template:
* userid The logged in user id
* urls The URLs for the popover
Example context (json):
{}
}}
<a class="align-self-center" href="#" data-route-back role="button">
{{> core_message/message_drawer_icon_back }}
</a>
<div class="px-3 pb-3">
<div class="text-center">
<a href="{{{profileurl}}}">
<img
class="rounded-circle"
src="{{profileimageurl}}"
alt="{{#str}} pictureof, moodle, {{fullname}} {{/str}}"
title="{{#str}} pictureof, moodle, {{fullname}} {{/str}}"
style="height: 100px; width: 100px"
>
</a>
</div>
<h2 class="mt-2 text-center text-truncate">{{fullname}}</h2>
<div class="px-4 mt-4">
<button
type="button"
class="btn btn-primary btn-block {{^isblocked}}hidden{{/isblocked}}"
data-route="view-conversation"
data-route-param-1=""
data-route-param-2="unblock"
data-route-param-3="{{id}}"
>
{{#str}}unblockuser, message{{/str}}
</button>
<button
type="button"
class="btn btn-danger btn-block {{#isblocked}}hidden{{/isblocked}}"
data-route="view-conversation"
data-route-param-1=""
data-route-param-2="block"
data-route-param-3="{{id}}"
>
{{#str}}blockuser, message{{/str}}
</button>
<button
type="button"
class="btn btn-danger btn-block {{^iscontact}}hidden{{/iscontact}}"
data-route="view-conversation"
data-route-param-1=""
data-route-param-2="remove-contact"
data-route-param-3="{{id}}"
>
{{#str}}removefromyourcontacts, message{{/str}}
</button>
<button
type="button"
class="btn btn-primary btn-block {{#iscontact}}hidden{{/iscontact}}"
data-route="view-conversation"
data-route-param-1=""
data-route-param-2="add-contact"
data-route-param-3="{{id}}"
>
{{#str}}addtoyourcontacts, message{{/str}}
</button>
</div>
</div>