https://docs.moodle.org/310/en/api.php?action=feedcontributions&user=Gallegre&feedformat=atomMoodleDocs - User contributions [en]2024-03-28T17:15:17ZUser contributionsMediaWiki 1.39.6https://docs.moodle.org/310/en/index.php?title=Activity_report&diff=36959Activity report2008-06-02T20:09:26Z<p>Gallegre: +fr link</p>
<hr />
<div>To access an activity report:<br />
<br />
==Full Activity Report==<br />
<br />
# Log in as a teacher or administrator<br />
# Select a course to generate a report on<br />
# Go to the "Administration" box on the left side of the page<br />
# Select "Reports"<br />
# If desired, use one or more of the pull down menus as a filter to narrow your report<br />
# On the new screen, select "Activity report". It will be approximately in the middle of the screen. <br />
# You will have an activity report sorted by topic<br />
<br />
[[Image:Reports Logs screen 19.PNG|Where to click for a full report. Groups has not been enabled in this course]]<br />
<br />
===Example of Activity Report===<br />
An activity report will show all activity in the course, sorted by topic. Each item will be shown with its type and name.<br />
[[Image:Activity-report-view.PNG|A full activity report]]<br />
<br />
==Individual Activity Report==<br />
<br />
# Log in as a teacher or administrator<br />
# Select a course to generate a report on<br />
# Go to the "People" box on the left side of the page<br />
# Select "Participants"<br />
# Click the person's name<br />
# Select the "Activity Reports" tab<br />
From here you can select an outline report (which looks similar to an activity report on all students), full report, grade report, or select today's logs or all logs. Again, reports are sorted by topic. <br />
A detailed report on a person will show each item, organized by topic, with what that person has done involving that item. For example, a forum will be listed with how many posts to that forum a person has made.<br />
<br />
[[Image:Individual-activity-report.png|How to get an individual report]]<br />
<br />
== See also ==<br />
*[[Participation report]]<br />
*[[Reports]] <br />
*[http://www.moodletutorials.org/view_video.php?viewkey=80faf6fb5e6087eb1b2d Screencast: Demonstrating Course Activity and Participation Reports] <br />
<br />
[[Category:Teacher]]<br />
[[Category:Report]]<br />
<br />
[[eu:Jardueraren_txostena]]<br />
[[fr:Rapport d'activité]]</div>Gallegrehttps://docs.moodle.org/310/en/index.php?title=Participation_report&diff=36958Participation report2008-06-02T20:08:39Z<p>Gallegre: + fr link</p>
<hr />
<div>A participation report provides any easy way to monitor students' participation. <br />
<br />
An Example Report:<br />
[[Image:Participation_report_example.jpg]]<br />
<br />
The definition of View and Post for the selected Activity type will be given on screen.<br />
For example:<br />
Forum View: View Discussion, Search, Forum, Forums, Subscribers<br />
Forum Post: Add Discussion, Add Post, Delete Discussion, Delete Post, Move Discussion, Prune Post, Update Post<br />
<br />
Users matching the Show (Student or Teacher) criteria will be listed in tabular format by Name/ID Number and whether (and how many times) they have completed the Action searched upon. e.g. (Yes (n) or No). <br />
<br />
==Bulk email==<br />
An extremely useful feature of the Participation Report is the ability to email students or teachers who have not completed a certain action in bulk. <br />
<br />
==Report options==<br />
<br />
[[Image:Report-highlighting-particpation-report.jpg]]<br />
<br />
<br />
'''Close up:'''<br />
[[Image:Participation report settings.jpg]]<br />
<br />
Activity Module - Select the Activity type on which you wish to report (eg Chat, Forum, Quiz etc). Note that only the Modules used in the course will be listed in this dropdown menu.<br />
<br />
Look Back - Select the period on which you wish to report.<br />
<br />
Show Only - Choose whether to run the report on Student or Teacher activity.<br />
<br />
Show Actions - Choose whether to report on Activity Views, Posts or Both (All Actions).<br />
<br />
Once you have entered values for the above parameters, choose Go.<br />
<br />
A list of all of the occurrences of the selected Activity Module in this course will be generated. Choose the item on which you want to report and choose Go.<br />
<br />
== See also ==<br />
*[[Reports]] <br />
*[[Activity report]]<br />
*[http://www.moodletutorials.org/How-to-use-the-Activity-Participation-Reports-in-Moodle.html Screencast: Demonstrating Course Activity and Participation Reports] <br />
<br />
[[Category:Report]]<br />
<br />
[[fr:Rapport de participation]]</div>Gallegrehttps://docs.moodle.org/310/en/index.php?title=Capabilities/moodle/site:viewreports&diff=36690Capabilities/moodle/site:viewreports2008-05-23T21:53:17Z<p>Gallegre: +fr link</p>
<hr />
<div>*This allows a user to view [[Reports|reports/logs]] in the given context (system, front page, course category or course context)<br />
<br />
[[Category:Capabilities|Site]]<br />
[[Category:Report]]<br />
<br />
[[fr:Capabilities/moodle/site:viewreports]]</div>Gallegrehttps://docs.moodle.org/310/en/index.php?title=Capabilities/moodle/site:sendmessage&diff=36687Capabilities/moodle/site:sendmessage2008-05-23T16:57:56Z<p>Gallegre: + fr link</p>
<hr />
<div>{{Moodle 1.8}}<br />
*This allows a user to send messages to any other user.<br />
*This capability may only be applied in the system context.<br />
*The default [[Authenticated user]] role has this capability set to allow.<br />
<br />
[[Category:Capabilities|Site]]<br />
[[Category:Messaging]]<br />
<br />
[[eu:Capabilities/moodle/site:sendmessage]]<br />
[[fr:Capabilities/moodle/site:sendmessage]]</div>Gallegrehttps://docs.moodle.org/310/en/index.php?title=Messaging_permissions&diff=36686Messaging permissions2008-05-23T16:42:30Z<p>Gallegre: + fr link</p>
<hr />
<div>{{Messaging}}<br />
The following capabilities are related to messaging:<br />
<br />
* [[Capabilities/moodle/course:bulkmessaging|moodle/course:bulkmessaging]]<br />
* [[Capabilities/moodle/site:readallmessages|moodle/site:readallmessages]]<br />
* [[Capabilities/moodle/site:sendmessage|moodle/site:sendmessage]] (Moodle 1.8 onwards)<br />
<br />
==See also==<br />
<br />
*Using Moodle [http://moodle.org/mod/forum/discuss.php?d=74170 Allowing students to send bulk messages] forum discussion<br />
<br />
[[Category:Roles]]<br />
<br />
[[eu:Mezularitzaren_baimenak]]<br />
[[de:Mitteilungsspezifische Rechte]]<br />
[[fr:Permissions de messagerie]]</div>Gallegrehttps://docs.moodle.org/310/en/index.php?title=Messages_block&diff=36680Messages block2008-05-23T09:53:21Z<p>Gallegre: + fr link</p>
<hr />
<div>{{Messaging}}<br />
The message block displays a list of new messages you have received, with a link to your Messages window.<br />
<br />
To add a Messages block to your course page:<br />
#Click on the "Turn editing on" button.<br />
#Select Messages from the Add blocks menu.<br />
#If appropriate, move the Messages block up and/or left, using the arrow icons under the block title.<br />
<br />
[[Category:Block]]<br />
<br />
[[es:Mensajes]]<br />
[[fr:Bloc Messages]]</div>Gallegrehttps://docs.moodle.org/310/en/index.php?title=Online_users_block&diff=36678Online users block2008-05-23T09:26:37Z<p>Gallegre: fr link</p>
<hr />
<div>[[Image:Block_online_users.gif|right]]The '''Online Users''' block shows a list of users who have been logged into the current course. This block can be added or deleted by a teacher. The list is updated on a regular basis (the default is every 5 minutes). The time frame can be modified for the entire Moodle site in Administration >> Configuration >> Blocks >> Online Users by the site administrator.<br />
<br />
Note that even though a user may have been logged into a course within the last 5 minutes, it does not necessarily mean that this user is still online.<br />
<br />
* Bold type indicates a teacher<br />
* If you hold the cursor over somebody's name, you will see how long ago that person was last "seen" in the course<br />
* If you click on the envelope icon next to somebody's name, you will be able to send a private message to that person (using Moodle's messaging system)<br />
* You must keep your messaging window open to receive notice of messages being sent to you<br />
<br />
<br />
==Messaging window==<br />
Within the messaging window you can:<br />
* Add or Remove Contact with another person logged into the course (if the face icon is showing, you have contact)<br />
* Block or Unblock Contact with another person (if the green dot is showing, you have Unblocked contact)<br />
* View your Message History with another person (the message history is only for the person whose messaging window you have open)<br />
<br />
Note that if you close the messaging window, your current messages will be removed from the window and become part of the messaging history.<br />
<br />
==See also==<br />
* Using Moodle [http://moodle.org/mod/forum/discuss.php?d=32461#151290 The Lonely People Block] forum discussion and code for combining the Online Users block and [[People block]]<br />
*See forum post [http://moodle.org/mod/forum/discuss.php?d=33172#244755 tweaking code to add icon after teachers name] for site administrators<br />
<br />
[[Category:Block]]<br />
<br />
[[fr:Bloc Utilisateurs en ligne]]</div>Gallegrehttps://docs.moodle.org/310/en/index.php?title=People_block&diff=36677People block2008-05-23T08:25:58Z<p>Gallegre: fr link</p>
<hr />
<div>[[Image:ParticBlock.jpg|right]]<br />
<br />
The '''People''' block contains a link to the list of course [[Participants|participants]].<br />
<br />
You can view participants' profiles from this block. <br />
<br />
==See also==<br />
<br />
* Using Moodle [http://moodle.org/mod/forum/discuss.php?d=32461#151290 The Lonely People Block] forum discussion and code for combining the People block and [[Online Users block]]<br />
<br />
[[Category:Block]]<br />
<br />
[[fr:Bloc Personnes]]</div>Gallegrehttps://docs.moodle.org/310/en/index.php?title=User:Allegre_Guillaume&diff=36564User:Allegre Guillaume2008-05-22T14:14:24Z<p>Gallegre: first english version</p>
<hr />
<div>Hello,<br />
<br />
I use Moodle in a professional context : I am co-leader of [http://www.silecs.info SILECS],<br />
a small free software IT service company based in Grenoble, France. <br />
We propose to our customers Moodle installation, customization and support.<br />
<br />
For the documentation effort, I try to participate in the french documentation, by <br />
updating obsolete translations and beginning new ones.<br />
I also have already added small details to the english documentation.<br />
<br />
[https://docs.moodle.org/fr/index.php?title=Utilisateur:Allegre_Guillaume French version of my homepage]</div>Gallegrehttps://docs.moodle.org/310/en/index.php?title=Student_FAQ&diff=36457Student FAQ2008-05-20T11:20:07Z<p>Gallegre: /* How do I get back to the homepage? */ nav. trail -> nav. bar + link</p>
<hr />
<div>{{FAQ}}<br />
<br />
This article is intended to prepare teachers for the kinds of questions their students may ask about their Moodle courses. The article could also be given to students (either printed, copied electronically or simply linked to) but the contents may need to be modified depending upon the age / ability of the students concerned.<br />
<br />
<br />
==Access and Navigation==<br />
<br />
===Why can't I log in?===<br />
There could be many reasons but the most probably is you have simply forgotton your password, are trying the wrong one or are entering it incorrectly. Some other things to think about include:<br />
* Does you username or password contain a mixture of upper and lower case letter? It should be entered exactly<br />
* Are cookies enabled on your browser<br />
<br />
===How do I gain access to a course?===<br />
Locate or search for the desired course (you can click 'All courses...' in the 'My courses' block) and click on the course name. If your teacher has given you an enrollment key, enter it when prompted, and click '''Enroll me in this course'''. Once you are enrolled in a course, it will appear under "My courses" any time that your are logged into that Moodle site.<br />
<br />
===How do I jump between my courses?===<br />
<br />
* 'My Courses' block if it has been added to the page you are on<br />
* Go back to the homepage (see below) and then use the main course block (if it has been added!)<br />
<br />
===How do I get back to the homepage?===<br />
<br />
Use the [[Navigation bar|navigation bar]] at the top left of the page or the button at the very bottom of the course<br />
<br />
===How do I find course X?===<br />
If you are not already enrolled in a course you can search for it by name and description.<br />
<br />
==Course content==<br />
===Where have all of the weeks / topics gone?===<br />
You have probably clicked on the [[Image:One.gif]] icon. To reveal all of the other weeks / topics you need to click on the [[Image:All.gif]] icon which you will see in the right margin of the week / topic.<br />
You can also use the dropdown box underneath the displayed week / topic to jump to a hidden section<br />
<br />
==Emails and forums==<br />
<br />
===Why am I not getting any e-mails and others are?===<br />
Chances are your email address in your profile is either wrong or disabled. It could also be that you are not subscribed to the forums that are generating emails. AOL users may also not receive e-mails if the administrator has banned the use of AOL email addresses.<br />
<br />
===How can I stop all of these e-mails?===<br />
E-mails are an essential part of the way Moodle works. They are used to keep you up to date with what is going on. If you wish to reduce the amount of emails you get you could:<br />
* Edit your profile and change your e-mail settings to digest<br />
* Unsubscribe from non-essential forums (although they are there for a reason!)<br />
* Disable your e-mail address in your profile although this is not recommended and may go against in house rules.<br />
<br />
==Assignments and grades==<br />
<br />
===Why is there no upload box?===<br />
This is either because:<br />
* The assignment has now closed<br />
* The assignment is not yet open<br />
* You already uploaded something and the settings prevent resubmissions<br />
<br />
===How can I see my recent assignment feedback?===<br />
There are many ways you can access their feedback. <br />
The most common method is by simply going to the same place where you uploaded the work. <br />
Another common method is to follow the link in the recent activity block (if the teacher has included it on the course).<br />
Another method would be to access the grade book and then follow the link for the required assignment.<br />
Depending upon how the assignment was set up, you may receive an email when it has been marked with a direct link to the feedback.<br />
<br />
===Why is my course average so low?===<br />
Don't panic! The Moodle gradebook takes into account unmarked and unsubmitted work. In other words, you start with zero and as you progress through the course and complete graded activities the percentage will steadily rise<br />
<br />
==Quizzes==<br />
<br />
===Which button do I press when I have finished a quiz?===<br />
That depends upon what you want to do ....<br />
<br />
==See also==<br />
*[[Student documentation]]<br />
*[[Student documentation examples]]<br />
*[http://moodle.org/mod/forum/discuss.php?d=43084 AOL - no friend of education!] forum discussion<br />
<br />
[[Category:Teacher]]<br />
[[Category:Student]]<br />
[[Category:FAQ]]<br />
<br />
[[es:FAQ Estudiante]]<br />
[[fr:FAQ d'étudiant]]</div>Gallegrehttps://docs.moodle.org/310/en/index.php?title=Navigation_bar&diff=36456Navigation bar2008-05-20T11:09:49Z<p>Gallegre: + why "breadcrumbs" is misleading</p>
<hr />
<div>The navigation bar is the row of links you will find at the top left of you Moodle site.<br />
<br />
The navigation bar is sometimes (mistakenly) referred to as breadcrumbs. This term is confusing,<br />
since the navigation bar doesn't necessarily reflect the path followed by the user to reach the <br />
current page.<br />
<br />
[[Category: Teacher]]<br />
<br />
[[eu:Nabigazio-barra]]<br />
[[fr:Barre de navigation]]<br />
[[ja:ナビゲーションバー]]</div>Gallegrehttps://docs.moodle.org/310/en/index.php?title=Development_talk:Repository_API&diff=33207Development talk:Repository API2008-03-05T23:04:17Z<p>Gallegre: /* Editing Repository Files / Version Control ? */</p>
<hr />
<div>(Ideas will be deleted from the comments section as they are resolved or merged into the main spec)<br />
<br />
===Missing concept of trusted files===<br />
Files are not created equal, some of them are to be trusted, some can not be trusted at all. Web browsers trust everything received from the server, files from server may access cookie information and thus scripting technologies may allow them to do anything user can do. We do have to trust our teachers because they are supposed to create the learning content, but we definitely can not trust all students.<br />
<br />
Imagine if students were allowed to upload arbitrary files to server, like html file loaded with javascript and the server would happily serve them to all Moodle users. Our solution is to use html cleaning filters for submitted texts and force downloads of student uploaded files. To do this we must know if we trust the files or not. Unfortunately the forced downloads of student uploaded files and cleaning of html texts does not solve all problems, because bugs in browsers and especially browser plug-ins may sometimes be used to work around our protections.<br />
<br />
The best solution would be to use separate web addresses for trusted and not trusted files (two wwwroots in config.php), not all sites may afford two different addresses but we should be imo prepared for this. [[User:Skodak|Skodak]] 16:42, 28 February 2008 (CST)<br />
<br />
Great idea, yes. In fact couldn't all the files be served via $CFG->fileroot all the time? <br />
[[User:Martin Dougiamas|Martin Dougiamas]] 07:08, 29 February 2008 (CST)<br />
<br />
userid field could be used for this, but separate flag might be better in order to allow teachers to upload untrusted files (teacher uploads assignment submission for the student).<br />
<br />
===Relative file links===<br />
Flash, Java and SCORM require relative links and directory hierarchy in general - we must support it. Some SCORM packages load hundreds of files per page which means the file serving must be very fast with minimum of db access.<br />
<br />
Reading the proposal above it seems the API is about serving of isolated files referenced by repository ids. HTML requires to use relative or absolute locators with file names, we can not use repository ids directly in relative links. In case of scorm we have absolute path to base of SCORM package of given activity and SCORM files use relative links inside the package.<br />
Solution could be to store relative paths directly in filename field ex:directory1/directory2/filename.ext.<br />
<br />
Yes I agree, we definitely need to support (virtual) directories and slasharguments.<br />
We could just match the file argument to a path in the db. Perhaps add the fileid <br />
to the argument path as a primary key: fileid/directory1/directory2/filename.ext<br />
[[User:Martin Dougiamas|Martin Dougiamas]] 07:08, 29 February 2008 (CST)<br />
<br />
===Virtual directories and files===<br />
Sometimes the content of files is generated on the fly (csv exports, etc.), there are many special files spread through codebase doing nearly the same, it should be imho possible to use the same file API for these.<br />
<br />
Another virtual example is assignment submissions and webdav. I would like to see an option to browse the assignment submissions as directory structure, the top directory would be a list of names of users, inside html files with online assignment and uploaded files. This would allow us to implement simple zip&go or webdav based offline grading solutions. The problem here is that the content of this virtual submissions directly needs to be created on the fly based on user references, the proposed repository structure can not be used for this.<br />
<br />
Very interesting idea! [[User:Martin Dougiamas|Martin Dougiamas]] 07:08, 29 February 2008 (CST)<br />
<br />
===Backup/restore relinking===<br />
We are supporting relinking inside courses only. Till now it was easy to guess if absolute link will work after restore on another server.<br />
There are several types of files:<br />
*course files - relinked during restore, works on any server if from the same course<br />
*module files - not relinked, urls are not permanent, link can not be copypasted (assignments, forum attachments, rss files, etc.)<br />
*user files - not relinked, links work only on original server (blog attachments, personal files, etc.)<br />
<br />
I think all this will be simplified in the proposed system because everything is <br />
represented using the same system: a file with an ACL (backup can quickly <br />
determine all the files in one course, probably using one SQL query). <br />
[[User:Martin Dougiamas|Martin Dougiamas]] 07:08, 29 February 2008 (CST)<br />
<br />
===Access needed for both file and its instances===<br />
We need two types of access control - first who can create instances (link files), second who can access the instance (download the file).<br />
<br />
For the first don't we already have those capabilities? (like mod/forum:createattachment,<br />
moodle/course:managefiles) but they probably could use rationalising. We'll need new <br />
ones per repository, too, of course. <br />
[[User:Martin Dougiamas|Martin Dougiamas]] 07:08, 29 February 2008 (CST)<br />
<br />
===Cache lifetime===<br />
There should be a way to specify cache filetime for each instance of file. For example 0 for uploaded assignments, 1 day for resource file. It might be better to allow modules to decide about this, at present it is hardcoded in file.php.<br />
<br />
Great idea. [[User:Martin Dougiamas|Martin Dougiamas]] 07:08, 29 February 2008 (CST)<br />
<br />
== Hierarchy in tables ? ==<br />
<br />
It's possible that I don't undertand a key piece of the concept, but I wonder why there is no reference to any "parent id" in the file or file_instance table ?<br />
In other words, how the hierarchical structure is supposed to be "imported" from repository to Moodle ?<br />
If the hierarchy is reserved to the course context, and not to the repository context, it seems difficult to allow students to access<br />
to a complete directory, for example.<br />
<br />
On the other hand, maybe it's only a question for the "local" repository type, and not to the "generic" repository API ?<br />
[[User:Allegre Guillaume|Allegre Guillaume]] 16:43, 5 March 2008 (CST)<br />
<br />
== Editing Repository Files / Version Control ? ==<br />
<br />
How do you imagine to handle the "editing file" problem ? <br />
I can see several solutions :<br />
# the simplest way : write access to a file really allows to edit (re-upload) the file, each instance being modified<br />
# the "cheap copy" way : optionally, the modification is applied only to new file_instances (or those for which the teacher forces to). Here you have to handle two (then maybe more) revisions of this file.<br />
This triggers the file revisions (or version control) question.<br />
<br />
A related question is about versionned files : <br />
should it depend only upon the repository layer (for example, a plugin could implement a SVN "repository") ?<br />
Or should Moodle be aware of the file "revision number" ? <br />
[[User:Allegre Guillaume|Allegre Guillaume]] 17:00, 5 March 2008 (CST)</div>Gallegrehttps://docs.moodle.org/310/en/index.php?title=Development_talk:Repository_API&diff=33206Development talk:Repository API2008-03-05T23:00:50Z<p>Gallegre: Editing Repository Files / Version Control ?</p>
<hr />
<div>(Ideas will be deleted from the comments section as they are resolved or merged into the main spec)<br />
<br />
===Missing concept of trusted files===<br />
Files are not created equal, some of them are to be trusted, some can not be trusted at all. Web browsers trust everything received from the server, files from server may access cookie information and thus scripting technologies may allow them to do anything user can do. We do have to trust our teachers because they are supposed to create the learning content, but we definitely can not trust all students.<br />
<br />
Imagine if students were allowed to upload arbitrary files to server, like html file loaded with javascript and the server would happily serve them to all Moodle users. Our solution is to use html cleaning filters for submitted texts and force downloads of student uploaded files. To do this we must know if we trust the files or not. Unfortunately the forced downloads of student uploaded files and cleaning of html texts does not solve all problems, because bugs in browsers and especially browser plug-ins may sometimes be used to work around our protections.<br />
<br />
The best solution would be to use separate web addresses for trusted and not trusted files (two wwwroots in config.php), not all sites may afford two different addresses but we should be imo prepared for this. [[User:Skodak|Skodak]] 16:42, 28 February 2008 (CST)<br />
<br />
Great idea, yes. In fact couldn't all the files be served via $CFG->fileroot all the time? <br />
[[User:Martin Dougiamas|Martin Dougiamas]] 07:08, 29 February 2008 (CST)<br />
<br />
userid field could be used for this, but separate flag might be better in order to allow teachers to upload untrusted files (teacher uploads assignment submission for the student).<br />
<br />
===Relative file links===<br />
Flash, Java and SCORM require relative links and directory hierarchy in general - we must support it. Some SCORM packages load hundreds of files per page which means the file serving must be very fast with minimum of db access.<br />
<br />
Reading the proposal above it seems the API is about serving of isolated files referenced by repository ids. HTML requires to use relative or absolute locators with file names, we can not use repository ids directly in relative links. In case of scorm we have absolute path to base of SCORM package of given activity and SCORM files use relative links inside the package.<br />
Solution could be to store relative paths directly in filename field ex:directory1/directory2/filename.ext.<br />
<br />
Yes I agree, we definitely need to support (virtual) directories and slasharguments.<br />
We could just match the file argument to a path in the db. Perhaps add the fileid <br />
to the argument path as a primary key: fileid/directory1/directory2/filename.ext<br />
[[User:Martin Dougiamas|Martin Dougiamas]] 07:08, 29 February 2008 (CST)<br />
<br />
===Virtual directories and files===<br />
Sometimes the content of files is generated on the fly (csv exports, etc.), there are many special files spread through codebase doing nearly the same, it should be imho possible to use the same file API for these.<br />
<br />
Another virtual example is assignment submissions and webdav. I would like to see an option to browse the assignment submissions as directory structure, the top directory would be a list of names of users, inside html files with online assignment and uploaded files. This would allow us to implement simple zip&go or webdav based offline grading solutions. The problem here is that the content of this virtual submissions directly needs to be created on the fly based on user references, the proposed repository structure can not be used for this.<br />
<br />
Very interesting idea! [[User:Martin Dougiamas|Martin Dougiamas]] 07:08, 29 February 2008 (CST)<br />
<br />
===Backup/restore relinking===<br />
We are supporting relinking inside courses only. Till now it was easy to guess if absolute link will work after restore on another server.<br />
There are several types of files:<br />
*course files - relinked during restore, works on any server if from the same course<br />
*module files - not relinked, urls are not permanent, link can not be copypasted (assignments, forum attachments, rss files, etc.)<br />
*user files - not relinked, links work only on original server (blog attachments, personal files, etc.)<br />
<br />
I think all this will be simplified in the proposed system because everything is <br />
represented using the same system: a file with an ACL (backup can quickly <br />
determine all the files in one course, probably using one SQL query). <br />
[[User:Martin Dougiamas|Martin Dougiamas]] 07:08, 29 February 2008 (CST)<br />
<br />
===Access needed for both file and its instances===<br />
We need two types of access control - first who can create instances (link files), second who can access the instance (download the file).<br />
<br />
For the first don't we already have those capabilities? (like mod/forum:createattachment,<br />
moodle/course:managefiles) but they probably could use rationalising. We'll need new <br />
ones per repository, too, of course. <br />
[[User:Martin Dougiamas|Martin Dougiamas]] 07:08, 29 February 2008 (CST)<br />
<br />
===Cache lifetime===<br />
There should be a way to specify cache filetime for each instance of file. For example 0 for uploaded assignments, 1 day for resource file. It might be better to allow modules to decide about this, at present it is hardcoded in file.php.<br />
<br />
Great idea. [[User:Martin Dougiamas|Martin Dougiamas]] 07:08, 29 February 2008 (CST)<br />
<br />
== Hierarchy in tables ? ==<br />
<br />
It's possible that I don't undertand a key piece of the concept, but I wonder why there is no reference to any "parent id" in the file or file_instance table ?<br />
In other words, how the hierarchical structure is supposed to be "imported" from repository to Moodle ?<br />
If the hierarchy is reserved to the course context, and not to the repository context, it seems difficult to allow students to access<br />
to a complete directory, for example.<br />
<br />
On the other hand, maybe it's only a question for the "local" repository type, and not to the "generic" repository API ?<br />
[[User:Allegre Guillaume|Allegre Guillaume]] 16:43, 5 March 2008 (CST)<br />
<br />
== Editing Repository Files / Version Control ? ==<br />
<br />
How do you imagine to handle the "editing file" problem ? <br />
I can see several solutions :<br />
# the simplest way : write access to a file really allows to edit (re-upload) the file, each instance being modified<br />
# the "cheap copy" way : optionally, the modification is applied only to new file_instances (or those for which the teacher forces to).<br />
This triggers the file revisions (or version control) question.<br />
<br />
A related question is about versionned files : <br />
should it depend only upon the repository layer (for example, a plugin could implement a SVN "repository") ?<br />
Or should Moodle be aware of the file "revision number" ? <br />
[[User:Allegre Guillaume|Allegre Guillaume]] 17:00, 5 March 2008 (CST)</div>Gallegrehttps://docs.moodle.org/310/en/index.php?title=Development_talk:Repository_API&diff=33205Development talk:Repository API2008-03-05T22:43:01Z<p>Gallegre: Hierarchy in tables ?</p>
<hr />
<div>(Ideas will be deleted from the comments section as they are resolved or merged into the main spec)<br />
<br />
===Missing concept of trusted files===<br />
Files are not created equal, some of them are to be trusted, some can not be trusted at all. Web browsers trust everything received from the server, files from server may access cookie information and thus scripting technologies may allow them to do anything user can do. We do have to trust our teachers because they are supposed to create the learning content, but we definitely can not trust all students.<br />
<br />
Imagine if students were allowed to upload arbitrary files to server, like html file loaded with javascript and the server would happily serve them to all Moodle users. Our solution is to use html cleaning filters for submitted texts and force downloads of student uploaded files. To do this we must know if we trust the files or not. Unfortunately the forced downloads of student uploaded files and cleaning of html texts does not solve all problems, because bugs in browsers and especially browser plug-ins may sometimes be used to work around our protections.<br />
<br />
The best solution would be to use separate web addresses for trusted and not trusted files (two wwwroots in config.php), not all sites may afford two different addresses but we should be imo prepared for this. [[User:Skodak|Skodak]] 16:42, 28 February 2008 (CST)<br />
<br />
Great idea, yes. In fact couldn't all the files be served via $CFG->fileroot all the time? <br />
[[User:Martin Dougiamas|Martin Dougiamas]] 07:08, 29 February 2008 (CST)<br />
<br />
userid field could be used for this, but separate flag might be better in order to allow teachers to upload untrusted files (teacher uploads assignment submission for the student).<br />
<br />
===Relative file links===<br />
Flash, Java and SCORM require relative links and directory hierarchy in general - we must support it. Some SCORM packages load hundreds of files per page which means the file serving must be very fast with minimum of db access.<br />
<br />
Reading the proposal above it seems the API is about serving of isolated files referenced by repository ids. HTML requires to use relative or absolute locators with file names, we can not use repository ids directly in relative links. In case of scorm we have absolute path to base of SCORM package of given activity and SCORM files use relative links inside the package.<br />
Solution could be to store relative paths directly in filename field ex:directory1/directory2/filename.ext.<br />
<br />
Yes I agree, we definitely need to support (virtual) directories and slasharguments.<br />
We could just match the file argument to a path in the db. Perhaps add the fileid <br />
to the argument path as a primary key: fileid/directory1/directory2/filename.ext<br />
[[User:Martin Dougiamas|Martin Dougiamas]] 07:08, 29 February 2008 (CST)<br />
<br />
===Virtual directories and files===<br />
Sometimes the content of files is generated on the fly (csv exports, etc.), there are many special files spread through codebase doing nearly the same, it should be imho possible to use the same file API for these.<br />
<br />
Another virtual example is assignment submissions and webdav. I would like to see an option to browse the assignment submissions as directory structure, the top directory would be a list of names of users, inside html files with online assignment and uploaded files. This would allow us to implement simple zip&go or webdav based offline grading solutions. The problem here is that the content of this virtual submissions directly needs to be created on the fly based on user references, the proposed repository structure can not be used for this.<br />
<br />
Very interesting idea! [[User:Martin Dougiamas|Martin Dougiamas]] 07:08, 29 February 2008 (CST)<br />
<br />
===Backup/restore relinking===<br />
We are supporting relinking inside courses only. Till now it was easy to guess if absolute link will work after restore on another server.<br />
There are several types of files:<br />
*course files - relinked during restore, works on any server if from the same course<br />
*module files - not relinked, urls are not permanent, link can not be copypasted (assignments, forum attachments, rss files, etc.)<br />
*user files - not relinked, links work only on original server (blog attachments, personal files, etc.)<br />
<br />
I think all this will be simplified in the proposed system because everything is <br />
represented using the same system: a file with an ACL (backup can quickly <br />
determine all the files in one course, probably using one SQL query). <br />
[[User:Martin Dougiamas|Martin Dougiamas]] 07:08, 29 February 2008 (CST)<br />
<br />
===Access needed for both file and its instances===<br />
We need two types of access control - first who can create instances (link files), second who can access the instance (download the file).<br />
<br />
For the first don't we already have those capabilities? (like mod/forum:createattachment,<br />
moodle/course:managefiles) but they probably could use rationalising. We'll need new <br />
ones per repository, too, of course. <br />
[[User:Martin Dougiamas|Martin Dougiamas]] 07:08, 29 February 2008 (CST)<br />
<br />
===Cache lifetime===<br />
There should be a way to specify cache filetime for each instance of file. For example 0 for uploaded assignments, 1 day for resource file. It might be better to allow modules to decide about this, at present it is hardcoded in file.php.<br />
<br />
Great idea. [[User:Martin Dougiamas|Martin Dougiamas]] 07:08, 29 February 2008 (CST)<br />
<br />
== Hierarchy in tables ? ==<br />
<br />
It's possible that I don't undertand a key piece of the concept, but I wonder why there is no reference to any "parent id" in the file or file_instance table ?<br />
In other words, how the hierarchical structure is supposed to be "imported" from repository to Moodle ?<br />
If the hierarchy is reserved to the course context, and not to the repository context, it seems difficult to allow students to access<br />
to a complete directory, for example.<br />
<br />
On the other hand, maybe it's only a question for the "local" repository type, and not to the "generic" repository API ?<br />
[[User:Allegre Guillaume|Allegre Guillaume]] 16:43, 5 March 2008 (CST)</div>Gallegre