-
Improvement
-
Resolution: Fixed
-
Minor
-
3.7, 3.8
-
MOODLE_37_STABLE, MOODLE_38_STABLE
-
MOODLE_38_STABLE
-
MDL-66061-master -
core_comment_get_comments has some flaws that should be amended on a the same or a new WS.
- total comments is missing, that makes that we have to all the WS multiple times to know the total comments value.
- Pagination is not complete: it needs a perpage param or a loadmore boolean to know if we should call it again to obtain more results.
- Sorting is wrong. This can be amended on website or on WS. The problem is that the sorting is different in both cases. In website it uses timecreated ASC and in WS timecreated DESC. Pagination makes different comment showing on top so we cannot re-sort).
About sorting: IMO it should be amended on website. JS rendering script is concatenating strings using html = (val+html);. This changes the sorting of the comments and makes pagination feel a bit strange: First page will show entries 3,4,5 and then second page will show 1,2. IMO it would be better to show: 5,4,3 and then 2,1. A new issue should be created if that seems reasonable. (Take numbers as creation date so 1 was created before 2).
- blocks
-
MOBILE-3130 Use perpage and count field in get_comments
-
- Closed
-
- has a non-specific relationship to
-
MDL-65092 comment: rewrite comment to use new web services
-
- Open
-