Commit Graph

61 Commits

Author SHA1 Message Date
Jake Dallimore bbaab1bae7 Merge branch 'MDL-44081-master' of git://github.com/zig-moodle/moodle 2018-07-04 10:50:25 +08:00
Zig Tan bc87f6a2e3 MDL-44081 assign: Fix Grader annotation button accessibility ordering 2018-06-29 09:26:58 +08:00
Eva Davitasvili 88c77c8ea3 MDL-60014 assign: Annotate PDF - catch no permission error 2018-06-25 14:11:24 -04:00
Tony Butler 8e64242131 MDL-62225 assignfeedback_editpdf: Add alt text for nav button shortcuts 2018-05-30 15:58:18 +01:00
Marina Glancy 468c8d39c3 MDL-62351 privacy: check that subsystem/plugintype exist 2018-05-09 17:37:31 +08:00
Jun Pataleta c166b700d8 Merge branch 'MDL-61194-master' of git://git.cameron1729.xyz/moodle 2018-05-03 17:07:57 +08:00
Cameron Ball 23fe1e2bed MDL-61194 assignfeedback_editpdf: Check if we can convert online text
This patch adds a check to make sure there is a converter available that
will be able to handle html->pdf conversion before adding onlinetext
submissions to the list of files to combine.
2018-05-03 16:44:27 +08:00
Adrian Greeve f8650bb7a3 MDL-61308 assign_feedback: Privacy code for user rights. 2018-04-26 14:17:55 +08:00
Cameron Ball 5e6a36f845 MDL-59885 assignfeedback_editpdf: Correctly report combination status 2017-08-21 15:32:02 +08:00
Tony Butler 23990a0a80 MDL-55459 assignfeedback_editpdf: Make comments collapsible in editor 2017-03-27 15:13:37 +01:00
Tony Butler 2c153c5649 MDL-55459 assignfeedback_editpdf: Add linked comments and markers to PDF 2017-03-24 09:48:42 +00:00
Damyon Wiese 3e6adcd69c MDL-40759 icons: Rename activity_icon
image_icon is a better name because there are some valid uses for these other than for activity icons.

E.g. Old JS code that is not worth re-writing.
2017-03-17 15:52:18 +08:00
Damyon Wiese 8857c715d1 MDL-40759 icons: Behat fixes for font-awesome 2017-03-17 15:52:18 +08:00
Andrew Nicols 357712eabe MDL-55528 assignfeedback_editpdf: Remove unnecessary escapes 2017-03-10 10:45:47 +08:00
Andrew Nicols f7a9f1dd0e MDL-55528 assignfeedback_editpdf: Update to use fileconverter_unoconv 2017-03-10 10:45:46 +08:00
Ankit Agarwal 1f3556b010 MDL-55762 assignpdf: Handle errored pages better 2017-02-27 09:24:07 +05:30
Ankit Agarwal b6d06a5f78 MDL-55762 assignpdf: Fix bug in phpdocs 2017-02-27 09:24:07 +05:30
David Monllao ab1058247c MDL-56122 editpdf: Fix ghostscript checking 2017-02-14 13:45:21 +01:00
Tony Butler fecfb4c6fb MDL-56122 assignfeedback_editpdf: Regenerate PDF & page images if blank 2017-02-13 17:23:42 +00:00
Matt Davidson 6be2b79b9c MDL-56810 unoconv: task fails if user removed
If the user is removed from a course after a submission has been made,
the task will crash and never continue.  This removes submissions from
the cron task if the user isn't enrolled in the course.
2016-12-12 08:22:51 -05:00
Tony Butler c156b7b76d MDL-56345 assignfeedback_editpdf: Use correct strings for tool alt text 2016-10-10 16:13:37 +01:00
Damyon Wiese f5ba9ac995 MDL-45969 editpdf: The logic for showing a previous attempt is wrong
It originally was only ever going to show static pdfs for older versions,
but this doesn't make sense in the UI for 3.1.
2016-09-30 13:15:00 +08:00
Damyon Wiese fca211bf05 MDL-55374 mod_assign: Force utf-8 for DOMDocument
This prevents charset issues on some sites.
2016-07-29 10:43:25 +08:00
Damyon Wiese 55907a738a MDL-53822 editpdf: Add a new tool for scrolling
I added a new tool to the toolbar to allow click and drag scrolling (especially useful for touchscreens).
2016-05-06 16:33:31 +08:00
Mark Nelson fcc9218fb8 MDL-53811 mod_assign: fixed error in convert submissions task 2016-04-19 13:08:27 +08:00
Damyon Wiese 6853cd5ed4 MDL-52954 assign: Fix the reasonable cibot warnings. 2016-03-30 14:07:28 +08:00
Damyon Wiese bb690849c9 MDL-52954 assign: Rebuild the assignment single grade page. 2016-03-30 13:47:21 +08:00
Damyon Wiese 1356d85151 MDL-52954 core: Change from pandoc to unoconv - it gives better results
Most importantly it retains formatting better, and supports different charsets far better than pandoc.
2016-03-30 11:48:39 +08:00
Damyon Wiese 2e76c14e11 MDL-52954 core: Add a document converter to file_storage
This lets us convert between common office formats. E.g. docx -> pdf
html -> pdf, html -> ods.

This commit also updates assignment editpdf plugin to use this converter
on all compatible submission files.
2016-03-30 11:48:39 +08:00
Syxton 626d833543 MDL-51779 assign: PDF annotate quality
Fixes the quality of pdf content when annotating.
2015-10-23 09:22:38 -04:00
Jun Pataleta 0bf75ff15f MDL-49864 mod_assign: Fix missing annotations when viewing PDF
Added 'draft = 1' criteria for the delete query in
page_editor::set_annotations in order to prevent the deletion of non-draft
annotations while the PDF is being edited.
2015-08-03 09:07:03 +08:00
Eloy Lafuente (stronk7) 46686eafeb MDL-49998 editpdf: Clean code to make it more readable.
There was a big proliferation and reuse of $pdf variable
that was making the code hard to read/review. This commit
does change nothing but makes it more readable.

Also adds a couple of Close() calls, not strictly needed
because they don't have opened files. But think it makes
really clearer the scope of every variable. And, for sure
it frees some resources. That cannot be bad.
2015-04-30 10:55:08 +02:00
Eloy Lafuente (stronk7) a916d557cf MDL-49998 unit tests: Close the pdf objects when needed.
When a pdf object is instantiated and any file is loaded
with set_pdf() or load_pdf(), the files remain open until
the pdf is saved with pdf_save() or outputted with Output()..

In that cases is needed to perform an explicit Close() in
order to free resources, parsers and, ultimately, fclose()
the files.

Note that only the uses detected in the editpdf unit tests have
been fixed. I'd recommend to analyse every instance of the tcpdf
libs.

Also, there was one incorrecly reused pdf instance in then
generate_combined_pdf_for_attempt() method. Apparently it was not
leading to problems, but better use a separate instance (#246).
2015-04-28 19:46:50 +02:00
Dan Poltawski 861265b43a Merge branch 'MDL-43462_landscape_pdf' of git://github.com/davosmith/moodle 2014-12-16 19:20:22 +00:00
Davo Smith 50c12f01bc MDL-43462 assignfeedback_editpdf: fix display of landscape PDFs
The size of the drawing canvas is now set from the size of the generated page image, with automatic
scrolling if it is too wide to display
Absolutely-positioned nodes (comments + stamps) are repositioned as the drawing canvas is scrolled
2014-12-15 22:01:26 +00:00
Andrew Nicols 9b65a08095 MDL-47475 mod_assign: Copy files to other group members for editpdf 2014-12-15 08:50:31 +08:00
Frederic Massart 20942dd702 MDL-47397 assignfeedback_editpdf: Copy stamps to other students in team
During a team submission the stamps were attached to the user that
was graded and not to the other users. This could lead to errors when
generating the PDF for each user.
2014-10-24 15:09:06 +01:00
Frederic Massart 7dbbb848c6 MDL-45580 assignfeedback_editpdf: Delete draft content on new submission 2014-06-23 14:17:24 +08:00
Frederic Massart 098f7dd438 MDL-45580 assignfeedback_editpdf: Store a readonly version of the PDF 2014-06-23 14:16:49 +08:00
Damyon Wiese e192e37f51 MDL-45582 EditPDF: whitespace fix 2014-06-17 10:27:19 +08:00
Gregory Faller 028c9d20b9 MDL-45582: Apply grades and feedback to entire group does not work with Annotate PDF feature 2014-06-16 18:09:21 +09:30
Rajesh Taneja 1bce3a70d9 MDL-44839 admin: Moved all system executable paths to config
AMOS BEGIN
 MOV ['gspath','assignfeedback_editpdf'],['pathtogs','admin']
 MOV ['gspath_help','assignfeedback_editpdf'],['pathtogs_help','admin']
AMOS END
2014-06-03 17:33:49 +08:00
Adam Olley 9f7674bddc MDL-44822 assignfeedback_editpdf: Stop test generation in is_enabled()
This change also moves one of the checks in test_gs_path. If
generateimage is false, there's no need to stat for the fixture file.
2014-03-27 10:16:53 +10:30
Damyon Wiese ac2b4ffc8c MDL-43593 Assign editpdf: More robust handling of errors from TCPDF.
This includes a check to see if there are 0 pages in the combined pdf,
catching exceptions and suppressing php warnings and errors from bad pdf files.

Also - Use TCPDF directly to check if pdfs are compatible. The previous check was
letting dodgy PDFs through which then failed at generation time. This way dodgy
pdfs will get run through ghostscript early and cleaned up.
2014-01-24 16:16:38 +08:00
Eloy Lafuente (stronk7) 1f71f7685a Merge branch 'MDL-43025-master' of git://github.com/damyon/moodle 2013-12-17 22:58:51 +01:00
Damyon Wiese 4fe9950ba6 MDL-43025 EditPDF: Increase memory limit when reading source pdfs. 2013-12-09 12:58:40 +08:00
Damyon Wiese 1f738c8c0c MDL-43074 assignfeedback_editpdf: Use escapeshellarg for all args in exec command.
This is to fix a reported problem with windows compatibility (e.g. when ghostscript is installed in
a folder with spaces in the name).
2013-12-09 10:52:35 +08:00
Rajesh Taneja baf881b803 MDL-42799 Assignment: Min. width/height for widget is set to 1
It was possible for user to add widgets with width/height = 0
which were not displayed to user and doesn't have much meaning to it
This patch will set min. width/height to 1
2013-11-12 16:17:40 +08:00
Marina Glancy bdb7c88635 Merge branch 'MDL-42031-master' of git://github.com/mouneyrac/moodle
Conflicts:
	mod/assign/feedback/editpdf/yui/build/moodle-assignfeedback_editpdf-editor/moodle-assignfeedback_editpdf-editor-min.js
2013-11-06 17:18:38 +11:00
Jerome Mouneyrac d40ce26f05 MDL-42031 assginfeedback_editpdf: fix next/previous/select page 2013-11-06 14:13:19 +08:00