Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Links: Add links on homepage - refs #4767 #4788

Closed

Conversation

christianbeeznest
Copy link
Contributor

No description provided.

@codeclimate
Copy link

codeclimate bot commented Jul 5, 2023

An error occurred when fetching issues.

View more on Code Climate.

Comment on lines +147 to 156
<div v-for="(link, index) in links" :key="'link-' + index" class="flex items-center gap-2">
<i class="mdi mdi-link-variant text-gray-500"></i>
<a :href="link.url" :target="link.target" :title="link.title" class="text-primary">
{{ link.title }}
</a>
</div>

<ShortCutList
v-for="(shortcut, index) in shortcuts"
:key="'shortcut-' + index.toString()"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Creo que para estos casos en que se manda algo desde una herramienta, se deben registrar como ShortCut

Comment on lines +232 to +247
// Links to display on homepage
$qb = $linkRepo->getResourcesByCourse($course, $this->getSession());
$qb->andWhere('resource.onHomepage = 1');
$qb->addOrderBy('resource.displayOrder', 'ASC');
$linkEntities = $qb->getQuery()->getResult();

$links = [];
/* @var CLink $linkEntity */
foreach ($linkEntities as $linkEntity) {
$links[] = [
'title' => $linkEntity->getTitle(),
'url' => $linkEntity->getUrl(),
'description' => $linkEntity->getDescription(),
'target' => $linkEntity->getTarget(),
];
}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Esto debería hacerlo el $shortcutRepository, líneas más abajo

@ywarnier ywarnier added this to the 2.0 milestone Jan 15, 2024
@AngelFQC AngelFQC linked an issue Jan 18, 2024 that may be closed by this pull request
@christianbeeznest
Copy link
Contributor Author

I close this PR to avoid the conflicting files

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

C2: Add migration for links/tools on homepage from C1 to C2
3 participants