Moodle
  1. Moodle
  2. MDL-28019

Implement file management for HTML-related file areas

    Details

    • Type: Improvement Improvement
    • Status: Closed
    • Priority: Blocker Blocker
    • Resolution: Fixed
    • Affects Version/s: 2.0, 2.1, 2.2, 2.3, 2.3.2, 2.4.3, 2.5
    • Fix Version/s: 2.6
    • Component/s: Files API, Repositories
    • Labels:
    • Testing Instructions:
      Hide

      Test required for two new plugins: tinymce_managefiles and repository_areafiles.

      Test 1. Basic editor

      1. Open any form with empty texteditor (HTML edtor using TinyMCE)
      2. Add images, upload files to link to.
      3. Check that you can pick those files again using repository "Embedded files"
      4. Check that you can manage those files using "Manage files" button in TinyMCE
      5. Try replacing, removing, renaming files, adding new there.
      6. Make sure error is displayed when file is missing
      7. Delete links to the embedded files
      8. Open "Manage files" window, make sure it offers to delete the files as well
      9. Make sure the form is saved with all files, files are displayed in view mode and text can be edited again

      Test 2. Textareas with supported subdirs:
      editors in all classes extending question_edit_form support subfolders. They are not used now but may contain files in subfolders after the upgrade from ancient versions of Moodle.

      1. Create quesiton
      2. Enter some text, embed files
      3. Open "Manage files" and create subfolders, place files in them
      4. Make sure you can link to those files using "Embedded files" repository
      5. Make sure form can be saved, files are properly displayed, text can be edited again.
      6. Try placing extra files in subfolders or removing used files
      7. Make sure all warnings/information appear in "Manage files" form.
      Show
      Test required for two new plugins: tinymce_managefiles and repository_areafiles. Test 1. Basic editor Open any form with empty texteditor (HTML edtor using TinyMCE) Add images, upload files to link to. Check that you can pick those files again using repository "Embedded files" Check that you can manage those files using "Manage files" button in TinyMCE Try replacing, removing, renaming files, adding new there. Make sure error is displayed when file is missing Delete links to the embedded files Open "Manage files" window, make sure it offers to delete the files as well Make sure the form is saved with all files, files are displayed in view mode and text can be edited again Test 2. Textareas with supported subdirs: editors in all classes extending question_edit_form support subfolders. They are not used now but may contain files in subfolders after the upgrade from ancient versions of Moodle. Create quesiton Enter some text, embed files Open "Manage files" and create subfolders, place files in them Make sure you can link to those files using "Embedded files" repository Make sure form can be saved, files are properly displayed, text can be edited again. Try placing extra files in subfolders or removing used files Make sure all warnings/information appear in "Manage files" form.
    • Workaround:
      Hide

      Use plugins:
      Moodle 2.4-2.5:

      Moodle 2.0-2.3:

      Show
      Use plugins: Moodle 2.4-2.5: Repository "Embedded files" https://moodle.org/plugins/view.php?plugin=repository_areafiles TinyMCE plugin "Manage embedded files" https://moodle.org/plugins/view.php?plugin=tinymce_managefiles Moodle 2.0-2.3: Repository "Embedded files plus": https://moodle.org/plugins/view.php?plugin=repository_areafilesplus
    • Difficulty:
      Difficult
    • Affected Branches:
      MOODLE_20_STABLE, MOODLE_21_STABLE, MOODLE_22_STABLE, MOODLE_23_STABLE, MOODLE_24_STABLE, MOODLE_25_STABLE
    • Fixed Branches:
      MOODLE_26_STABLE
    • Pull Master Branch:
      wip-MDL-28019-master

      Description

      User are not able to:
      1/ delete "uploaded" file
      2/ user can not find out what files were already uploaded
      3/ users can not link again already existing image

      The reason is that there is no way to manage the files that are uploaded to the file area referenced from the text in tinymce editor. Attempts to work around this missing feature (overriding of files, link from forms, etc.) were only creating regressions.

      Possible solution - add a new tab "Used files" to the file picker, this would solve all 3 issues above. I have proposed several different solutions before, but I think this is the best one.

        Gliffy Diagrams

        1. debugging_using_embedded.png
          31 kB
        2. picker.png
          23 kB
        3. picker2.png
          307 kB
        4. question_from_1_9_backup.png
          35 kB

          Issue Links

            Activity

            Petr Skoda created issue -
            Martin Dougiamas made changes -
            Field Original Value New Value
            Link This issue has a clone MDL-26388 [ MDL-26388 ]
            Martin Dougiamas made changes -
            Link This issue is duplicated by MDL-26107 [ MDL-26107 ]
            Martin Dougiamas made changes -
            Link This issue is duplicated by MDL-26090 [ MDL-26090 ]
            Martin Dougiamas made changes -
            Link This issue is duplicated by MDL-25585 [ MDL-25585 ]
            Martin Dougiamas made changes -
            Link This issue is duplicated by MDL-25518 [ MDL-25518 ]
            Martin Dougiamas made changes -
            Link This issue is duplicated by MDL-26650 [ MDL-26650 ]
            Martin Dougiamas made changes -
            Link This issue is duplicated by MDL-27297 [ MDL-27297 ]
            Martin Dougiamas made changes -
            Link This issue has been marked as being related by MDL-27381 [ MDL-27381 ]
            Martin Dougiamas made changes -
            Link This issue will help resolve MDL-26832 [ MDL-26832 ]
            Martin Dougiamas made changes -
            Link This issue will help resolve MDL-23989 [ MDL-23989 ]
            Martin Dougiamas made changes -
            Labels pullweek-2011-18
            Eloy Lafuente (stronk7) made changes -
            Integration date 4/May/11
            Eloy Lafuente (stronk7) made changes -
            Pull Master Diff URL https://github.com/dongsheng/moodle/compare/master...s9_MDL-26388_filepicker_existing_files_master
            Pull Master Branch s9_MDL-26388_filepicker_existing_files_master
            Pull 2.0 Diff URL https://github.com/dongsheng/moodle/compare/MOODLE_20_STABLE...s9_MDL-26388_filepicker_existing_files_20
            Pull 2.0 Branch s9_MDL-26388_filepicker_existing_files_20
            Integrator samhemelryk
            Fix Version/s DEV backlog [ 10464 ]
            Fix Version/s 2.0.3 [ 10537 ]
            Peer reviewer nebgor
            Testing Instructions Hello testers
            This issue needs to test in html editor and file manager.

            HTML Editor
            1. Adding a picture to html editor with name for example: test.jpg
            2. Adding another picture with the same name by using upload/local/recent/private repository plugins, you should see a dialog pop up asking you want to overwrite/rename or cancel, try all options to see if it works as expected.


            File manager, for example in your private file management page
            1. Adding a picture to filemanager with name for example: test.jpg
            2. Adding another picture with the same name using upload/local/recent/private repository plugins, you should see a dialog pop up asking you want to overwrite/rename or cancel, try all options to see if it works as expected.
            Pull from Repository git://github.com/dongsheng/moodle.git
            Labels triaged
            Assignee Dongsheng Cai [ dongsheng ] moodle.com [ moodle.com ]
            Affects Version/s 2.1 [ 10370 ]
            Affects Version/s 2.0.1 [ 10420 ]
            Difficulty Difficult
            Tester tsala
            Petr Skoda made changes -
            Attachment safari.png [ 24182 ]
            Petr Skoda made changes -
            Attachment mdl_26388.jpg [ 24179 ]
            Petr Skoda made changes -
            Attachment 2011-04-11 12.01.bmml [ 24177 ]
            Petr Skoda made changes -
            Attachment 2011-04-11 12.01.png [ 24178 ]
            Petr Skoda made changes -
            Link This issue has been marked as being related by MDL-31145 [ MDL-31145 ]
            Michael de Raadt made changes -
            Link This issue will help resolve MDL-31145 [ MDL-31145 ]
            Michael Penney made changes -
            Labels triaged partner triaged
            Jean-Michel Vedrine made changes -
            Affects Version/s 2.3 [ 10657 ]
            Affects Version/s 2.2 [ 10656 ]
            Jean-Michel Vedrine made changes -
            Affects Version/s 2.3.2 [ 12353 ]
            Martin Dougiamas made changes -
            Assignee moodle.com [ moodle.com ] Marina Glancy [ marina ]
            Jean-Michel Vedrine made changes -
            Affects Version/s 2.4.3 [ 12569 ]
            Affects Version/s 2.5 [ 12452 ]
            Martin Dougiamas made changes -
            Fix Version/s FRONTEND [ 12581 ]
            Marina Glancy made changes -
            Link This issue is duplicated by MDL-39919 [ MDL-39919 ]
            Martin Dougiamas made changes -
            Rank Ranked higher
            Marina Glancy made changes -
            Workaround Use plugins:
            Moodle 2.4-2.5:
            - Repository "Embedded files" https://moodle.org/plugins/view.php?plugin=repository_areafiles
            - TinyMCE plugin "Manage embedded files" https://moodle.org/plugins/view.php?plugin=tinymce_managefiles

            Moodle 2.0-2.3:
            - Repository "Embedded files plus": https://moodle.org/plugins/view.php?plugin=repository_areafilesplus
            Petr Skoda made changes -
            Status Open [ 1 ] Peer review in progress [ 10013 ]
            Peer reviewer skodak
            Petr Skoda made changes -
            Status Peer review in progress [ 10013 ] Development in progress [ 3 ]
            Helen Foster made changes -
            Labels partner triaged docs_required partner triaged
            Jean-Michel Vedrine made changes -
            Attachment question_from_1_9_backup.png [ 33349 ]
            Marina Glancy made changes -
            Link This issue blocks MDL-40766 [ MDL-40766 ]
            Marina Glancy made changes -
            Pull Master Diff URL https://github.com/marinaglancy/moodle/compare/moodle:master...wip-MDL-28019-master
            Pull Master Branch wip-MDL-28019-master
            Testing Instructions Test required for two new plugins: tinymce_managefiles and repository_areafiles.

            Test 1. Basic editor

            # Open any form with empty texteditor (HTML edtor using TinyMCE)
            # Add images, upload files to link to.
            # Check that you can pick those files again using repository "Embedded files"
            # Check that you can manage those files using "Manage files" button in TinyMCE
            # Try replacing, removing, renaming files, adding new there.
            # Make sure error is displayed when file is missing
            # Delete links to the embedded files
            # Open "Manage files" window, make sure it offers to delete the files as well
            # Make sure the form is saved with all files, files are displayed in view mode and text can be edited again

            Test 2. Textareas with supported subdirs:
            editors in all classes extending question_edit_form support subfolders. They are not used now but may contain files in subfolders after the upgrade from ancient versions of Moodle.

            # Create quesiton
            # Enter some text, embed files
            # Open "Manage files" and create subfolders, place files in them
            # Make sure you can link to those files using "Embedded files" repository
            # Make sure form can be saved, files are properly displayed, text can be edited again.
            # Try placing extra files in subfolders or removing used files
            # Make sure all warnings/information appear in "Manage files" form.
            Pull from Repository git://github.com/marinaglancy/moodle.git
            Marina Glancy made changes -
            Status Development in progress [ 3 ] Waiting for integration review [ 10010 ]
            CiBoT made changes -
            Labels docs_required partner triaged ci docs_required partner triaged
            Eloy Lafuente (stronk7) made changes -
            Labels ci docs_required partner triaged docs_required partner triaged
            Damyon Wiese made changes -
            Currently in integration Yes [ 10041 ]
            Damyon Wiese made changes -
            Status Waiting for integration review [ 10010 ] Integration review in progress [ 10004 ]
            Integrator damyon
            Damyon Wiese made changes -
            Status Integration review in progress [ 10004 ] Waiting for testing [ 10005 ]
            Fix Version/s 2.6 [ 12579 ]
            Fix Version/s DEV backlog [ 10464 ]
            Fix Version/s FRONTEND [ 12581 ]
            David Monllaó made changes -
            Tester skodak
            David Monllaó made changes -
            Tester skodak davmon
            David Monllaó made changes -
            Status Waiting for testing [ 10005 ] Testing in progress [ 10011 ]
            David Monllaó made changes -
            Attachment debugging_using_embedded.png [ 33652 ]
            David Monllaó made changes -
            Status Testing in progress [ 10011 ] Tested [ 10006 ]
            Damyon Wiese made changes -
            Status Tested [ 10006 ] Closed [ 6 ]
            Resolution Fixed [ 1 ]
            Currently in integration Yes [ 10041 ]
            Integration date 26/Jul/13
            Tim Hunt made changes -
            Link This issue caused a regression MDL-41034 [ MDL-41034 ]
            Marina Glancy made changes -
            Link This issue testing discovered HQ-375 [ HQ-375 ]
            Mary Cooch made changes -
            Labels docs_required partner triaged partner triaged

              People

              • Votes:
                145 Vote for this issue
                Watchers:
                57 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: