Línea 635... |
Línea 635... |
635 |
'link_comment_add' => $this->url()->fromRoute('microlearning/capsules-comments/add', ['capsule_id' => $capsule->uuid],['force_canonical' => true]),
|
635 |
'link_comment_add' => $this->url()->fromRoute('microlearning/capsules-comments/add', ['capsule_id' => $capsule->uuid],['force_canonical' => true]),
|
636 |
'link_slides' => $link_slides, // Usar enlace construido
|
636 |
'link_slides' => $link_slides, // Usar enlace construido
|
637 |
'total_comments' => strval($dataCountAndRatingAverage['total_comments']),
|
637 |
'total_comments' => strval($dataCountAndRatingAverage['total_comments']),
|
638 |
'total_rating' => strval($dataCountAndRatingAverage['total_rating']),
|
638 |
'total_rating' => strval($dataCountAndRatingAverage['total_rating']),
|
639 |
'progress' => 0,
|
639 |
'progress' => 0,
|
640 |
'link_get' => $this->url()->fromRoute('microlearning/get-capsule', ['id' => $capsule->uuid], ['force_canonical' => true]),
|
- |
|
641 |
'added_on' => $capsule->added_on,
|
640 |
'added_on' => $capsule->added_on,
|
642 |
'updated_on' => $capsule->updated_on,
|
641 |
'updated_on' => $capsule->updated_on,
|
643 |
]);
|
642 |
]);
|
644 |
}
|
643 |
}
|
Línea 775... |
Línea 774... |
775 |
'link_comment_add' => $this->url()->fromRoute('microlearning/capsules-comments/add', ['capsule_id' => $capsule->uuid],['force_canonical' => true]),
|
774 |
'link_comment_add' => $this->url()->fromRoute('microlearning/capsules-comments/add', ['capsule_id' => $capsule->uuid],['force_canonical' => true]),
|
776 |
'link_slides' => $link_slides,
|
775 |
'link_slides' => $link_slides,
|
777 |
'total_comments' => strval($dataCountAndRatingAverage['total_comments']),
|
776 |
'total_comments' => strval($dataCountAndRatingAverage['total_comments']),
|
778 |
'total_rating' => strval($dataCountAndRatingAverage['total_rating']),
|
777 |
'total_rating' => strval($dataCountAndRatingAverage['total_rating']),
|
779 |
'progress' => $userProgress->progress,
|
778 |
'progress' => $userProgress->progress,
|
780 |
'link_get' => $this->url()->fromRoute('microlearning/get-capsule', ['id' => $capsule->uuid], ['force_canonical' => true]),
|
- |
|
781 |
'added_on' => $capsule->added_on,
|
779 |
'added_on' => $capsule->added_on,
|
782 |
'last_access_on' => $userProgress->updated_on,
|
780 |
'last_access_on' => $userProgress->updated_on,
|
783 |
'updated_on' => $capsule->updated_on,
|
781 |
'updated_on' => $capsule->updated_on,
|
784 |
]);
|
782 |
]);
|
785 |
}
|
783 |
}
|
Línea 921... |
Línea 919... |
921 |
'link_comments' => $this->url()->fromRoute('microlearning/capsules-comments', ['capsule_id' => $capsule->uuid], ['force_canonical' => true]),
|
919 |
'link_comments' => $this->url()->fromRoute('microlearning/capsules-comments', ['capsule_id' => $capsule->uuid], ['force_canonical' => true]),
|
922 |
'link_comment_add' => $this->url()->fromRoute('microlearning/capsules-comments/add', ['capsule_id' => $capsule->uuid],['force_canonical' => true]),
|
920 |
'link_comment_add' => $this->url()->fromRoute('microlearning/capsules-comments/add', ['capsule_id' => $capsule->uuid],['force_canonical' => true]),
|
923 |
'link_slides' => $link_slides,
|
921 |
'link_slides' => $link_slides,
|
924 |
'total_comments' => strval($dataCountAndRatingAverage['total_comments']),
|
922 |
'total_comments' => strval($dataCountAndRatingAverage['total_comments']),
|
925 |
'total_rating' => strval($dataCountAndRatingAverage['total_rating']),
|
923 |
'total_rating' => strval($dataCountAndRatingAverage['total_rating']),
|
926 |
'progress' => $userProgress->progress, // Progreso real
|
924 |
'progress' => $userProgress->progress,
|
927 |
'link_get' => $this->url()->fromRoute('microlearning/get-capsule', ['id' => $capsule->uuid], ['force_canonical' => true]),
|
- |
|
928 |
'last_access_on' => $userProgress->updated_on, // Fecha del progreso
|
925 |
'last_access_on' => $userProgress->updated_on,
|
929 |
'added_on' => $capsule->added_on, // Fecha de la cápsula
|
926 |
'added_on' => $capsule->added_on,
|
930 |
'updated_on' => $capsule->updated_on, // Fecha de la cápsula
|
927 |
'updated_on' => $capsule->updated_on,
|
931 |
]);
|
928 |
]);
|
932 |
}
|
929 |
}
|
Línea 933... |
Línea 930... |
933 |
|
930 |
|
934 |
// 8. Ordenar (lógica de ordenación permanece igual, usando $capsulesData)
|
931 |
// 8. Ordenar (lógica de ordenación permanece igual, usando $capsulesData)
|