aboutsummaryrefslogtreecommitdiff
path: root/app/views/lti/_tool_info.php
blob: fb9657e19f39d91dfd710a9628cb77079e302a9f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
<?php
/**
 * @var LtiTool $tool
 * @var \LtiResourceLink $link
 * @var StudipController $controller
 */
?>
<? if (!empty($tool)) : ?>
    <article class="studip">
        <header>
            <? if ($link) : ?>
                <h1><?= htmlReady($link->title) ?></h1>
            <? else : ?>
                <h1><?= htmlReady($tool->name) ?></h1>
            <? endif ?>
        </header>
        <dl>
            <dt><?= _('Launch-URL') ?></dt>
            <dd>
                <? if ($link && $link->launch_url) : ?>
                    <a href="<?= htmlReady($link->launch_url) ?>">
                        <?= Icon::create('link-extern')->asImg(['class' => 'text-bottom']) ?>
                        <?= htmlReady($link->launch_url) ?>
                    </a>
                <? else : ?>
                    <a href="<?= htmlReady($tool->launch_url) ?>">
                        <?= Icon::create('link-extern')->asImg(['class' => 'text-bottom']) ?>
                        <?= htmlReady($tool->launch_url) ?>
                    </a>
                <? endif ?>
            </dd>

            <? if ($tool->terms_of_use_url) : ?>
                <dt><?= _('Nutzungsbedingungen') ?></dt>
                <dd>
                    <a href="<?= htmlReady($tool->terms_of_use_url) ?>">
                        <?= Icon::create('link-extern') ?>
                        <?= htmlReady($tool->terms_of_use_url) ?>
                    </a>
                </dd>
            <? endif ?>
            <? if ($tool->privacy_policy_url) : ?>
                <dt><?= _('Datenschutzerklärung') ?></dt>
                <dd>
                    <a href="<?= htmlReady($tool->privacy_policy_url) ?>">
                        <?= Icon::create('link-extern') ?>
                        <?= htmlReady($tool->terms_of_use_url) ?>
                    </a>
                </dd>
            <? endif ?>

            <? if ($tool) : ?>
                <dt><?= _('Client-ID') ?></dt>
                <dd><?= htmlReady($tool->id) ?></dd>
            <? endif ?>

            <? if (!empty($link->deployment->id)) : ?>
                <dt><?= _('Deployment-ID') ?></dt>
                <dd><?= htmlReady($link->deployment->id) ?></dd>

                <? if ($parameters = $link->getCustomParameters()) : ?>
                    <dt><?= _('LTI custom parameters') ?></dt>
                    <dd><?= htmlReady($parameters) ?></dd>
                <? endif ?>
            <? endif ?>
            <? if ($link) : ?>
                <dt><?= _('Direktlink zum LTI-Tool') ?></dt>
                <dd>
                    <ul>
                        <li>
                            <a href="<?= $controller->link_for('course/lti/iframe', $link->id) ?>">
                                <?= Icon::create('link-extern')->asImg(['class' => 'text-bottom']) ?>
                                <?= $controller->link_for('course/lti/iframe', $link->id) ?>
                            </a>
                        </li>
                    </ul>
                </dd>
            <? endif ?>
        </dl>
    </article>
    <article class="studip">
        <header><h1><?= _('Plattform-Konfiguration') ?></h1></header>
        <?= $this->render_partial('lti/_platform_data', ['platform' => \Studip\LTI13a\PlatformManager::getPlatformConfiguration($tool->id)]) ?>
    </article>
<? endif ?>