Non-core contributed modules

Curriculum, through which course grouping, hierarchy and flow control can be maintained between modules within a course and between courses themselves

Details

  • Type: New Feature New Feature
  • Status: Closed Closed
  • Priority: Major Major
  • Resolution: Fixed
  • Affects Version/s: 1.9.3, 1.9.4, 1.9.5
  • Fix Version/s: None
  • Component/s: Patch: Curriculum
  • Labels:
    None
  • Database:
    MySQL
  • Affected Branches:
    MOODLE_19_STABLE

Description

Long awaited feature "Curriculum" for moodle 1.9.3,1.9.4,1.9.5.

Features:

Course hierarchy

1. There can be a tree hierarchy
2. There can be a parallel hierarchy
3. There can be a serial hierarchy

between courses inside the curriculum, the admin/teacher has the power to tailor the courses in any of above mentioned hierarchies.

Module hierarchy

1. There can be a tree hierarchy
2. There can be a parallel hierarchy
3. There can be a serial hierarchy

between Activity/resource inside a course or a curriculum,the admin/teacher has the power to tailor the activity/resource flow in any of above mentioned hierarchies.

Course completion:

Completion of a course for any student occurs on two ways,

1. Automatic
2. Manual

1. Automatic :

Any student is marked as he completed the course if he completes the dependencies within the course,Once he completes this course automatically the other courses which are dependent on this course opens up

Note: if the teacher did not place any locks/dependencies within the course any student who just visits the course will be marked as completed immediately

2. Manual :

A student take a course and even though he finished all locks/dependencies he will not be marked as he completed the course until the teacher manually does it using the participants page(which appears in the participants block).

And any student enrolled in a curriculum is enrolled in all the courses within the curriculum but denied access to courses as per the hierarchy structure designed by admin/teacher.

Teacher/admin has the facility to suspend the user for any single course or multiple courses in case he violates some rules for that course/curriculum itself.

Roles:

1. Curriculum wide (similar to site wide roles)
2. Course wide (similar to course wide)

  1. Curriculum_ver01.tar.gz
    07/Jun/10 8:04 PM
    793 kB
    Ravishankar Somasundaram
  2. ver1.0_curriculum_moodle1.9
    30/Dec/09 1:18 AM
    318 kB
    Ravishankar Somasundaram

Issue Links

Activity

Hide
Anthony Borrow added a comment -

Thanks for your patience and also sharing this code with the Moodle community. OK, I see that this is a patch. Generally speaking, it is preferred that patches be maintained as a single patch file; however, we have also provided the file structure and patched files for a particular version of Moodle to make it easier to use for folks who do not know how to work with patch files; however, the question always remains for me whether those users should really be using patched versions of Moodle. In any case, would you be able to create a patch (i.e. diff) file (you can check out http://docs.moodle.org/en/Development:How_to_create_a_patch if you need guidance with that process). The issue is how the patch can best work with various specific versions of Moodle. For that reason patch files tend to be more effective and less likely to produce versioning problems. If you need help creating the patch file just let me know. In the meantime, I will try to look through some of the changes and functionality and give you some other feedback. Peace - Anthony

Show
Anthony Borrow added a comment - Thanks for your patience and also sharing this code with the Moodle community. OK, I see that this is a patch. Generally speaking, it is preferred that patches be maintained as a single patch file; however, we have also provided the file structure and patched files for a particular version of Moodle to make it easier to use for folks who do not know how to work with patch files; however, the question always remains for me whether those users should really be using patched versions of Moodle. In any case, would you be able to create a patch (i.e. diff) file (you can check out http://docs.moodle.org/en/Development:How_to_create_a_patch if you need guidance with that process). The issue is how the patch can best work with various specific versions of Moodle. For that reason patch files tend to be more effective and less likely to produce versioning problems. If you need help creating the patch file just let me know. In the meantime, I will try to look through some of the changes and functionality and give you some other feedback. Peace - Anthony
Hide
Dickie Layden added a comment -

This sounds fantastic - I'm really interested but I'm having a problem (and you stated you wanted comments here )
I've installed it on a totally fresh 1.9.6 build (I previously tried it on 1.9.5 and had the same issue).

It looks like there should be a new column (coursecompletion) added to mdl_course - (visiting a course page throws up an error
"Unknown column 'coursecompletion' in 'where clause'
SELECT * FROM mdl_course WHERE coursecompletion ......"

Also, table mdl_user_track doesnt appear to have been created during the install process.

These may not be completely related to your project and they may be dependencies from other modules / activities

Any help will be much appreciated - I'd like to give this a good testing
Cheers

Show
Dickie Layden added a comment - This sounds fantastic - I'm really interested but I'm having a problem (and you stated you wanted comments here ) I've installed it on a totally fresh 1.9.6 build (I previously tried it on 1.9.5 and had the same issue). It looks like there should be a new column (coursecompletion) added to mdl_course - (visiting a course page throws up an error "Unknown column 'coursecompletion' in 'where clause' SELECT * FROM mdl_course WHERE coursecompletion ......" Also, table mdl_user_track doesnt appear to have been created during the install process. These may not be completely related to your project and they may be dependencies from other modules / activities Any help will be much appreciated - I'd like to give this a good testing Cheers
Hide
Ravishankar Somasundaram added a comment - - edited

Dear Dickie Layden,

Thank you for giving it a try and bringing this up, Have updated the zip package.

If you have already installed everthing you can just run these sql scripts and the error you faced will vanish

DROP TABLE IF EXISTS `mdl_user_track`;
CREATE TABLE `mdl_user_track` (
`id` int(9) NOT NULL AUTO_INCREMENT,
`userid` int(9) NOT NULL COMMENT 'students id',
`courseid` int(9) NOT NULL COMMENT 'course,curriculum id',
`completed` enum('0','1') NOT NULL DEFAULT '0' COMMENT 'completed flag',
`datetime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
PRIMARY KEY (`id`)
) Engine=InnoDB AUTO_INCREMENT=83 DEFAULT CHARSET=utf8;

ALTER TABLE `mdl_course` ADD `coursecompletion` INT( 2 ) NOT NULL COMMENT 'course completion type for the course';

if you are going to do a fresh installation, you can proceed with the instructions as the script will automatically install these things for you.

Let me know the proceedings.

Peace - Ravishankar somasundaram

Show
Ravishankar Somasundaram added a comment - - edited Dear Dickie Layden, Thank you for giving it a try and bringing this up, Have updated the zip package. If you have already installed everthing you can just run these sql scripts and the error you faced will vanish DROP TABLE IF EXISTS `mdl_user_track`; CREATE TABLE `mdl_user_track` ( `id` int(9) NOT NULL AUTO_INCREMENT, `userid` int(9) NOT NULL COMMENT 'students id', `courseid` int(9) NOT NULL COMMENT 'course,curriculum id', `completed` enum('0','1') NOT NULL DEFAULT '0' COMMENT 'completed flag', `datetime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP, PRIMARY KEY (`id`) ) Engine=InnoDB AUTO_INCREMENT=83 DEFAULT CHARSET=utf8; ALTER TABLE `mdl_course` ADD `coursecompletion` INT( 2 ) NOT NULL COMMENT 'course completion type for the course'; if you are going to do a fresh installation, you can proceed with the instructions as the script will automatically install these things for you. Let me know the proceedings. Peace - Ravishankar somasundaram
Hide
Ravishankar Somasundaram added a comment -

Have updated Readme file.

Show
Ravishankar Somasundaram added a comment - Have updated Readme file.
Hide
Anthony Borrow added a comment -

Ravishankar - Sorry for the delay, now that classes have finished I am enjoying some time over the holidays to begin catching up on items that I had fallen behind on. Thanks for your patience. Generally speaking on a patch, it is preferred that we provide the diff file which provides more flexibility in terms of versions. Ideally, having one patch file is ideal. I am open to maintaining the structure as you have it so that folks could have a zip file; however, it will require more frequent updates as any changes made (especially security related changes) will need to be incorporated. I find it especially helpful in these versions to note specifically which version of the file you were working with when you merged so that it is easier to determine what changes need to be made in order to bring the file up to date. If you have questions about how to create a patch file you can begin by reading http://docs.moodle.org/en/Development:How_to_create_a_patch although I suspect with a patch of this magnitude that you are already well familiar with how to work with patch files. Do not hesitate to let me know how I can be helpful and many thanks for sharing your work on the patch. Peace - Anthony

Show
Anthony Borrow added a comment - Ravishankar - Sorry for the delay, now that classes have finished I am enjoying some time over the holidays to begin catching up on items that I had fallen behind on. Thanks for your patience. Generally speaking on a patch, it is preferred that we provide the diff file which provides more flexibility in terms of versions. Ideally, having one patch file is ideal. I am open to maintaining the structure as you have it so that folks could have a zip file; however, it will require more frequent updates as any changes made (especially security related changes) will need to be incorporated. I find it especially helpful in these versions to note specifically which version of the file you were working with when you merged so that it is easier to determine what changes need to be made in order to bring the file up to date. If you have questions about how to create a patch file you can begin by reading http://docs.moodle.org/en/Development:How_to_create_a_patch although I suspect with a patch of this magnitude that you are already well familiar with how to work with patch files. Do not hesitate to let me know how I can be helpful and many thanks for sharing your work on the patch. Peace - Anthony
Hide
Anthony Borrow added a comment -

moving to patch component

Show
Anthony Borrow added a comment - moving to patch component
Hide
Ravishankar Somasundaram added a comment -

Dearn Anthony borrow,
Thanks for remembering, was waiting for your reply to get the status of this going.I created a diff file thought i should share things that went through my mind,

1. The volume of the diff file is very big to look into and isolate changes.
2. Incase the user has already made some changes to few files that i have hacked into, and it fails when trying to apply patch ? in this case he gets stuck ?

Show
Ravishankar Somasundaram added a comment - Dearn Anthony borrow, Thanks for remembering, was waiting for your reply to get the status of this going.I created a diff file thought i should share things that went through my mind, 1. The volume of the diff file is very big to look into and isolate changes. 2. Incase the user has already made some changes to few files that i have hacked into, and it fails when trying to apply patch ? in this case he gets stuck ?
Hide
Ravishankar Somasundaram added a comment -

And regarding the security issue,
I would like to correct it if any. but it returned whole negative when App scan was run on it.

Show
Ravishankar Somasundaram added a comment - And regarding the security issue, I would like to correct it if any. but it returned whole negative when App scan was run on it.
Hide
Anthony Borrow added a comment -

We could create a few patch files for each directory to keep the size of the patch files manageable. I realize that for folks installing this on a customized system that the patch file may not work but I would rather have a user run into problems at this point than to just blindly copy over changes without really understanding what they are doing. What I have advised in the past is that the diff file should assume the latest version of Moodle (1.9+). For users with other customizations the patch file is much better as the site admin will be more likely to see where any conflicts exist and resolve them in the way they desire, rather than copying over them and losing their own customizations. I realize that the patch file approach can seem a little daunting to some users but it is for their own good. For those who are using the latest vanilla version of Moodle they should be able to just copy and paste the files on top and have a working installation. In that way we more or less can keep everyone happy or at least equally unhappy. As for keeping up to date, the only thing you will have to do is periodically monitor the core files you have changed and see if there are any updates to that file. That ensures you are applying any security fixes that are made in core to your patch. Hopefully using CVS will not make it too difficult to maintain the patch. Having one good patch file goes a long way and is really the only way to offer your changes to many people. It is a bit of a methodical process at the beginning to document the modified files and the version you are using but once it is done it will save lots of time and confusion in the future. Let me know if you need help getting things together. Peace - Anthony

Show
Anthony Borrow added a comment - We could create a few patch files for each directory to keep the size of the patch files manageable. I realize that for folks installing this on a customized system that the patch file may not work but I would rather have a user run into problems at this point than to just blindly copy over changes without really understanding what they are doing. What I have advised in the past is that the diff file should assume the latest version of Moodle (1.9+). For users with other customizations the patch file is much better as the site admin will be more likely to see where any conflicts exist and resolve them in the way they desire, rather than copying over them and losing their own customizations. I realize that the patch file approach can seem a little daunting to some users but it is for their own good. For those who are using the latest vanilla version of Moodle they should be able to just copy and paste the files on top and have a working installation. In that way we more or less can keep everyone happy or at least equally unhappy. As for keeping up to date, the only thing you will have to do is periodically monitor the core files you have changed and see if there are any updates to that file. That ensures you are applying any security fixes that are made in core to your patch. Hopefully using CVS will not make it too difficult to maintain the patch. Having one good patch file goes a long way and is really the only way to offer your changes to many people. It is a bit of a methodical process at the beginning to document the modified files and the version you are using but once it is done it will save lots of time and confusion in the future. Let me know if you need help getting things together. Peace - Anthony
Hide
Ravishankar Somasundaram added a comment -

Dear Anthony,

As said have attached the patch for the curriculum code which was previously posted as a zip package.

anybody who is planning to use the patch file needs to use

git apply /path/to/the/patch

you will get some warnings regarding line endings, please do ignore it for now because it does'nt affect anything.

please try it out and let me know if i need to make any changes.

Show
Ravishankar Somasundaram added a comment - Dear Anthony, As said have attached the patch for the curriculum code which was previously posted as a zip package. anybody who is planning to use the patch file needs to use git apply /path/to/the/patch you will get some warnings regarding line endings, please do ignore it for now because it does'nt affect anything. please try it out and let me know if i need to make any changes.
Hide
Anthony Borrow added a comment -

Would it be too much trouble to get a CVS diff file rather than git? Peace - Anthony

Show
Anthony Borrow added a comment - Would it be too much trouble to get a CVS diff file rather than git? Peace - Anthony
Hide
Anthony Borrow added a comment -

I have started working with Netbeans (instead of Eclipse) and the functionality for working with diff files is much less controlled (from what I can tell). I find Eclipse much easier to work with in terms of working with diff files that do not completely apply. All I could tell was that the patch partially applied which does not tell me much. Because of the size of the patch it is hard to know what did and did not work. Thanks for your help in sorting things out so that I can give this a solid evaluation. Peace - Anthony

Show
Anthony Borrow added a comment - I have started working with Netbeans (instead of Eclipse) and the functionality for working with diff files is much less controlled (from what I can tell). I find Eclipse much easier to work with in terms of working with diff files that do not completely apply. All I could tell was that the patch partially applied which does not tell me much. Because of the size of the patch it is hard to know what did and did not work. Thanks for your help in sorting things out so that I can give this a solid evaluation. Peace - Anthony
Hide
Anthony Borrow added a comment -

p.s. Alternatively, if you could give me an updated zip file based off of the latest 1.9 stable version and let me know the exact version number then I should be able to figure things out. I just want to have an accurate idea of what is actually changing in the core code.

Show
Anthony Borrow added a comment - p.s. Alternatively, if you could give me an updated zip file based off of the latest 1.9 stable version and let me know the exact version number then I should be able to figure things out. I just want to have an accurate idea of what is actually changing in the core code.
Hide
Ravishankar Somasundaram added a comment -

Dear anthony borrow,

thanks for the evaluation, you can find the latest zip file with folder structures, you can read the readme file to get to know which core files have been altered,

and if you open the files from the zip and search for Ravi within the file you can find the editions i have made.

I have never worked on CVS but bringing in that shouldnt be a problem it would help you greatly.

And regarding the patch getting applied incompletely, is there an error it is throwing ? because when i applythe patch by saying "git apply /path/to/patch" i dont get any problems, please advise how i can proceed in replicating the scenario.

Show
Ravishankar Somasundaram added a comment - Dear anthony borrow, thanks for the evaluation, you can find the latest zip file with folder structures, you can read the readme file to get to know which core files have been altered, and if you open the files from the zip and search for Ravi within the file you can find the editions i have made. I have never worked on CVS but bringing in that shouldnt be a problem it would help you greatly. And regarding the patch getting applied incompletely, is there an error it is throwing ? because when i applythe patch by saying "git apply /path/to/patch" i dont get any problems, please advise how i can proceed in replicating the scenario.
Hide
Anthony Borrow added a comment -

OK, I am working with the version 1.0 file which is an actual patch. So that is good. One thing I noticed in terms of style is that you are using the old school /db/mysql.php file to create the tables rather than install.xml. Using install.xml will hopefully make the patch more database independent. Peace - Anthony

Show
Anthony Borrow added a comment - OK, I am working with the version 1.0 file which is an actual patch. So that is good. One thing I noticed in terms of style is that you are using the old school /db/mysql.php file to create the tables rather than install.xml. Using install.xml will hopefully make the patch more database independent. Peace - Anthony
Hide
Anthony Borrow added a comment -

I wanted to respond to your concern on 28/Dec/09 12:21 PM about someone not being able to apply the patch and getting stuck. Although it sounds counter-intuitive, my initial reaction is that if they run into a conflict we want them to be stuck and to sort it out (often manually). If you simply provide a zip file and they use it to overwrite what they have - they would lose any customizations that they have made to the file. So I would rather have them get stuck with a patch file. Does that make sense? I wonder if it is really helpful to folks if they start customizing their sites without having a real understanding of what they are doing. It seems risky and ultimately I think it can do more harm than good. So those are my thoughts on that question. I'm going to continue reviewing and commenting as things come up. Peace - Anthony

Show
Anthony Borrow added a comment - I wanted to respond to your concern on 28/Dec/09 12:21 PM about someone not being able to apply the patch and getting stuck. Although it sounds counter-intuitive, my initial reaction is that if they run into a conflict we want them to be stuck and to sort it out (often manually). If you simply provide a zip file and they use it to overwrite what they have - they would lose any customizations that they have made to the file. So I would rather have them get stuck with a patch file. Does that make sense? I wonder if it is really helpful to folks if they start customizing their sites without having a real understanding of what they are doing. It seems risky and ultimately I think it can do more harm than good. So those are my thoughts on that question. I'm going to continue reviewing and commenting as things come up. Peace - Anthony
Hide
Anthony Borrow added a comment -

OK, I tried to apply the patch with Eclipse to the latest version of 1.9 and it failed. I am going to go in and see with Eclipse if I can see exactly what was failing and why. Peace - Anthony

Show
Anthony Borrow added a comment - OK, I tried to apply the patch with Eclipse to the latest version of 1.9 and it failed. I am going to go in and see with Eclipse if I can see exactly what was failing and why. Peace - Anthony
Hide
Anthony Borrow added a comment -

OK, I quickly tried to see what was happening and here is what Eclipse identified as the rejected sections. I am not sure why but am not able to do much with it at the moment. Could you send me a patch file that seems to work with the latest 1.9 code? Otherwise, just send me the most updated files that you have and I'll see what I can do to get things working. Peace - Anthony

Show
Anthony Borrow added a comment - OK, I quickly tried to see what was happening and here is what Eclipse identified as the rejected sections. I am not sure why but am not able to do much with it at the moment. Could you send me a patch file that seems to work with the latest 1.9 code? Otherwise, just send me the most updated files that you have and I'll see what I can do to get things working. Peace - Anthony
Hide
Anthony Borrow added a comment -

OK, well I looked at edit_form.php.rej and compared it to edit_form and everything appears to have applied ok for that file. They could be false alarms. I'll continue to check and let you know. Peace - Anthony

Show
Anthony Borrow added a comment - OK, well I looked at edit_form.php.rej and compared it to edit_form and everything appears to have applied ok for that file. They could be false alarms. I'll continue to check and let you know. Peace - Anthony
Hide
Anthony Borrow added a comment -

with /course/view.php could you give me a good diff file. It looks like you may have changed some whitespace toward the beginning of the file and it shows taking out a bunch of lines and then adding them back in. I really want to see what changed without having to sort through that kind of stuff. Peace - Anthony

Show
Anthony Borrow added a comment - with /course/view.php could you give me a good diff file. It looks like you may have changed some whitespace toward the beginning of the file and it shows taking out a bunch of lines and then adding them back in. I really want to see what changed without having to sort through that kind of stuff. Peace - Anthony
Hide
Anthony Borrow added a comment -

In /lang/en_utf8/moodle.php I would not recommend changing that file. I would add your custom strings to a separate file. Any existing strings you want the users to change, then give them the instructions for doing that via the Moodle UI. Peace - Anthony

Show
Anthony Borrow added a comment - In /lang/en_utf8/moodle.php I would not recommend changing that file. I would add your custom strings to a separate file. Any existing strings you want the users to change, then give them the instructions for doing that via the Moodle UI. Peace - Anthony
Hide
Anthony Borrow added a comment -

with /lib/moodlelib.php it looks like some of the things just got moved around a bit so there are a few minor patches - mostly commenting things out that did not take. Could you make sure to generate a patch for /lib/moodle.lib php. Thanks.

Show
Anthony Borrow added a comment - with /lib/moodlelib.php it looks like some of the things just got moved around a bit so there are a few minor patches - mostly commenting things out that did not take. Could you make sure to generate a patch for /lib/moodle.lib php. Thanks.
Hide
Anthony Borrow added a comment -

OK, first accept my apologies for taking so long to review this. My impressions at this point are that we really should use the install.xml and avoid customizing /lang/en_utf8/moodle.php. Instructions can be given for changing existing strings to something else. Let's clean up these things and get a clean patch ready for the latest version of 1.9 and then we should be at a point that we can add it to contrib. In the interim, if you could email me a demo site or a site that is running the code and walk me through some of the changes and differences that will help me to know what I am looking at. Let me know when a good time for you might be. Peace - Anthony

Show
Anthony Borrow added a comment - OK, first accept my apologies for taking so long to review this. My impressions at this point are that we really should use the install.xml and avoid customizing /lang/en_utf8/moodle.php. Instructions can be given for changing existing strings to something else. Let's clean up these things and get a clean patch ready for the latest version of 1.9 and then we should be at a point that we can add it to contrib. In the interim, if you could email me a demo site or a site that is running the code and walk me through some of the changes and differences that will help me to know what I am looking at. Let me know when a good time for you might be. Peace - Anthony
Hide
Ravishankar Somasundaram added a comment -

Ok, wil work on the install.xml, didnt hear about it till now.

Can you please explain what do you expect with respect to moodle.php files for language strings ?

Show
Ravishankar Somasundaram added a comment - Ok, wil work on the install.xml, didnt hear about it till now. Can you please explain what do you expect with respect to moodle.php files for language strings ?
Hide
Anthony Borrow added a comment -

I would recommend removing any changes to /lang/en_utf8/moodle.php.

If you want to modify an existing string, instruct the user to do those manually by modifying their local strings. Alternatively if you wish you can include a local file which would include the changes to make it faster for folks.

For strings that are not initially in the file, add them to a separate file and change the get_string functions to use that file (for example, get_string('mycurricula','curriculum') would look up the mycurricula string from the /lang/en_utf8/curriculum.php file.

Does that make sense?

As for install.xml - check out http://docs.moodle.org/en/admin/xmldb/ and let me know if you have any questions. Peace - Anthony

Show
Anthony Borrow added a comment - I would recommend removing any changes to /lang/en_utf8/moodle.php. If you want to modify an existing string, instruct the user to do those manually by modifying their local strings. Alternatively if you wish you can include a local file which would include the changes to make it faster for folks. For strings that are not initially in the file, add them to a separate file and change the get_string functions to use that file (for example, get_string('mycurricula','curriculum') would look up the mycurricula string from the /lang/en_utf8/curriculum.php file. Does that make sense? As for install.xml - check out http://docs.moodle.org/en/admin/xmldb/ and let me know if you have any questions. Peace - Anthony
Hide
Ravishankar Somasundaram added a comment -

Regarding storing the strings in separate file and referencing that file in get_string Yes, but what happens in the case of strings which are edited ?

say for example, moodle's default string is "Course request" and i want to change it to "Course/Curriculum"

are you advising that to store those too in a separate file and call that file in get_string ??

As far install.xml played with it a little bit, will make a solution out of it sooner.

Show
Ravishankar Somasundaram added a comment - Regarding storing the strings in separate file and referencing that file in get_string Yes, but what happens in the case of strings which are edited ? say for example, moodle's default string is "Course request" and i want to change it to "Course/Curriculum" are you advising that to store those too in a separate file and call that file in get_string ?? As far install.xml played with it a little bit, will make a solution out of it sooner.
Hide
Anthony Borrow added a comment -

Thanks for your continued work on fixing things up. What I was suggesting for the language strings was to simply have the person manually go through and adjust the language strings on their server via the UI (i.e. Language -> Language editing -> Edit words or phrases. Then they select moodle.php and replace "Course request" with "Course/Curriculum". Alternatively you could provide the files with the suggested changes and simply instruct them to copy those to moodledata/lang/en_utf8_local. For example, in the "Course request" example you would have a single string definition in a file called moodle.php which would go in moodledata's /lang/en_utf8 folder. That would then override "Course request" throughout Moodle so the effect is the same as changing the core code but without changing the core code. My goal is to move things away from being a patch (where possible) to make it more of a strict plugin without loss of functionality. Does that make sense? If not, just let me know and I will try to explain more clearly. Do not hesitate to let me know how I can be supportive. Peace - Anthony

Show
Anthony Borrow added a comment - Thanks for your continued work on fixing things up. What I was suggesting for the language strings was to simply have the person manually go through and adjust the language strings on their server via the UI (i.e. Language -> Language editing -> Edit words or phrases. Then they select moodle.php and replace "Course request" with "Course/Curriculum". Alternatively you could provide the files with the suggested changes and simply instruct them to copy those to moodledata/lang/en_utf8_local. For example, in the "Course request" example you would have a single string definition in a file called moodle.php which would go in moodledata's /lang/en_utf8 folder. That would then override "Course request" throughout Moodle so the effect is the same as changing the core code but without changing the core code. My goal is to move things away from being a patch (where possible) to make it more of a strict plugin without loss of functionality. Does that make sense? If not, just let me know and I will try to explain more clearly. Do not hesitate to let me know how I can be supportive. Peace - Anthony
Hide
Ravishankar Somasundaram added a comment -

Hello Anthony i appreciate the prompt response, It is my pleasure to work on moodle.

Now regarding the above comment, my personal opinion is that we will make the user feel pain, if we are going to tell him to edit each language string using language editor tool in moodle.

The concept of making it a plugin is cool, in fact we are providing options above for the very same reason, people who want to completely adopt it can just go for the diff file and implement it in a single shot as a single piece, or people can go for the zip file, copy them (contents of files in the case of language strings) and paste them in their installation ?

Were you meaning that its missing instructions to do the same ??

And as another alternative adding them to _local directory,

say for example i have a string called "Course request" inside lang/en_utf8/moodle.php

and i have a string called "Course/Curriculum request" inside lang/en_utf8_local/moodle.php

now do you mean to say that the moodle engine will read the local directory first for the translations and then the default directories ? so the string Course/Curriculum request gets displayed instead of Course request ?

kindly clarify

And i have one more doubt, how does these string editions cause a loss in functionality ? may be am skipping things over here so please do explain.

Show
Ravishankar Somasundaram added a comment - Hello Anthony i appreciate the prompt response, It is my pleasure to work on moodle. Now regarding the above comment, my personal opinion is that we will make the user feel pain, if we are going to tell him to edit each language string using language editor tool in moodle. The concept of making it a plugin is cool, in fact we are providing options above for the very same reason, people who want to completely adopt it can just go for the diff file and implement it in a single shot as a single piece, or people can go for the zip file, copy them (contents of files in the case of language strings) and paste them in their installation ? Were you meaning that its missing instructions to do the same ?? And as another alternative adding them to _local directory, say for example i have a string called "Course request" inside lang/en_utf8/moodle.php and i have a string called "Course/Curriculum request" inside lang/en_utf8_local/moodle.php now do you mean to say that the moodle engine will read the local directory first for the translations and then the default directories ? so the string Course/Curriculum request gets displayed instead of Course request ? kindly clarify And i have one more doubt, how does these string editions cause a loss in functionality ? may be am skipping things over here so please do explain.
Hide
Anthony Borrow added a comment -

My intention with suggesting using the local language files was to avoid the user pain of having to manually make the changes via the UI as I realize that could be a significant amount of work. I think you understood perfectly what I meant about the local files. If a local file exists any strings in there will be used instead of what is in /lang/en_utf8 so in the example you provide you would wind up with Course/Curriculum. Does that help to clarify?

As for loss of function, I was simply saying that I would like to keep everything working smoothly but as much as possible to do things in a way that keeps them as plugins rather than patches. Sometimes I have suggested on other patches that certain features which could be considered optional and insignificant be included as an optional patch file which has allowed me to consider the code as a plugin with an optional patch included in it. I do not think you need to worry about it. I was perhaps getting ahead of myself or just thinking out loud.

Peace - Anthony

Show
Anthony Borrow added a comment - My intention with suggesting using the local language files was to avoid the user pain of having to manually make the changes via the UI as I realize that could be a significant amount of work. I think you understood perfectly what I meant about the local files. If a local file exists any strings in there will be used instead of what is in /lang/en_utf8 so in the example you provide you would wind up with Course/Curriculum. Does that help to clarify? As for loss of function, I was simply saying that I would like to keep everything working smoothly but as much as possible to do things in a way that keeps them as plugins rather than patches. Sometimes I have suggested on other patches that certain features which could be considered optional and insignificant be included as an optional patch file which has allowed me to consider the code as a plugin with an optional patch included in it. I do not think you need to worry about it. I was perhaps getting ahead of myself or just thinking out loud. Peace - Anthony
Hide
Ravishankar Somasundaram added a comment -

ah ha !

so users already have a way to achieve this, will update the zip file contents and the installation instructions in the readme file,

will work on the patch file for this too, so as planned user will have a choice to go about installing this in a single shot using the patch or customize to their needs using the source files from the zip.

Show
Ravishankar Somasundaram added a comment - ah ha ! so users already have a way to achieve this, will update the zip file contents and the installation instructions in the readme file, will work on the patch file for this too, so as planned user will have a choice to go about installing this in a single shot using the patch or customize to their needs using the source files from the zip.
Hide
ven added a comment -

Ravi,

I am glad that you have been developing this module. I am having moodle 1.9.8+ version in produciton, do you think this module would work for this version?

If you could you provide complete .zip format of the module that could use use?

Thanks

Show
ven added a comment - Ravi, I am glad that you have been developing this module. I am having moodle 1.9.8+ version in produciton, do you think this module would work for this version? If you could you provide complete .zip format of the module that could use use? Thanks
Hide
Ravishankar Somasundaram added a comment -

Ven,

personally havent tested in any other versions than specified in the "Affected versions" yet,

you are most welcomed to give it a try if interested

Show
Ravishankar Somasundaram added a comment - Ven, personally havent tested in any other versions than specified in the "Affected versions" yet, you are most welcomed to give it a try if interested
Hide
Ravishankar Somasundaram added a comment -

As requested, have made changes in the way its being installed, upgraded and used.

Have made it loosely coupled as much as possible for making it behave as a plugin.

Users can read the Readme.txt file inside appropriate directories to get to know their options and the flexibility which has been provided in adapting this into their existing systems.

Show
Ravishankar Somasundaram added a comment - As requested, have made changes in the way its being installed, upgraded and used. Have made it loosely coupled as much as possible for making it behave as a plugin. Users can read the Readme.txt file inside appropriate directories to get to know their options and the flexibility which has been provided in adapting this into their existing systems.
Hide
Anthony Borrow added a comment -

Ravi - My inclination is to create a curriculum.patch file in contrib/patches/curriculum rather than having it inside the patch folder. Also, I noticed that the activity_locking block was still using the mysql.php and mysql.sql files rather than the preferred install.xml file. Could you correct that and give me a new file. A small detail about file names, be consistent with casing. I would avoid Readme.txt and would prefer to see either readme.txt or README.txt. I do not see a need for plugin_base - I would just put those folders in root so that we would have contrib/patches/curriculum/admin, etc. For now, I am going to upload the curriculum.patch file so that it is created and I can grant your access to the directory. The reason I want to avoid adding the other stuff at the moment is because the mysql.php and mysql.sql files are not needed and there is no way to really delete them once we add them to CVS which is why I make a serious effort to get file names corrected from the very beginning. Thanks for your patience on this. Peace - Anthony

Show
Anthony Borrow added a comment - Ravi - My inclination is to create a curriculum.patch file in contrib/patches/curriculum rather than having it inside the patch folder. Also, I noticed that the activity_locking block was still using the mysql.php and mysql.sql files rather than the preferred install.xml file. Could you correct that and give me a new file. A small detail about file names, be consistent with casing. I would avoid Readme.txt and would prefer to see either readme.txt or README.txt. I do not see a need for plugin_base - I would just put those folders in root so that we would have contrib/patches/curriculum/admin, etc. For now, I am going to upload the curriculum.patch file so that it is created and I can grant your access to the directory. The reason I want to avoid adding the other stuff at the moment is because the mysql.php and mysql.sql files are not needed and there is no way to really delete them once we add them to CVS which is why I make a serious effort to get file names corrected from the very beginning. Thanks for your patience on this. Peace - Anthony
Hide
Anthony Borrow added a comment -

Ravi - I have bumped your privileges in the tracker so that you can manage issues related to the curriculum patch. I am moving this to the newly created Patch: Curriculum category in the tracker. New issues in this category will automatically be assigned to you. I have granted you CVS write access to contrib/patches/curriculum so that you can manage the patch. Please resolve the mysql.php and mysql.sql file issue and use README.txt for your readme files. You will need to slightly modify what is in the README.txt file I added to CVS. Also, please review http://docs.moodle.org/en/Development:Guidelines_for_contributed_code to make sure you have created a good Moodle Docs page for the patch and then create the Modules and Plugins database entry (http://moodle.org/mod/data/view.php?id=6009). Let me know what other questions you might have. I'm going to go ahead and resolve this issue on my end but feel free to continue to use this tracker issue for any questions. When making CVS commits, it is customary that they all begin with a Moodle tracker issue (unless it is a trivial typo correction). This goes a long way in helping to show why particular changes were made. I would also recommend adding the version of the file you used to merge from as a separate comment at the beginning of any modified core files. This will let folks know from which version you started. Keep up with those files is important as security issues are addressed. I would assume that those who want to install your patch are using the latest stable version. There is seldom any need to support anything else. Let me know if there is anything I can do to be of further assistance. Best of luck as you prepare to present this patch and many thanks for all your work, generosity, and especially patience in working through the various issues to get this ready to share. My goal is to help ensure that the end user experience is as consistent as possible. Peace - Anthony

Show
Anthony Borrow added a comment - Ravi - I have bumped your privileges in the tracker so that you can manage issues related to the curriculum patch. I am moving this to the newly created Patch: Curriculum category in the tracker. New issues in this category will automatically be assigned to you. I have granted you CVS write access to contrib/patches/curriculum so that you can manage the patch. Please resolve the mysql.php and mysql.sql file issue and use README.txt for your readme files. You will need to slightly modify what is in the README.txt file I added to CVS. Also, please review http://docs.moodle.org/en/Development:Guidelines_for_contributed_code to make sure you have created a good Moodle Docs page for the patch and then create the Modules and Plugins database entry (http://moodle.org/mod/data/view.php?id=6009). Let me know what other questions you might have. I'm going to go ahead and resolve this issue on my end but feel free to continue to use this tracker issue for any questions. When making CVS commits, it is customary that they all begin with a Moodle tracker issue (unless it is a trivial typo correction). This goes a long way in helping to show why particular changes were made. I would also recommend adding the version of the file you used to merge from as a separate comment at the beginning of any modified core files. This will let folks know from which version you started. Keep up with those files is important as security issues are addressed. I would assume that those who want to install your patch are using the latest stable version. There is seldom any need to support anything else. Let me know if there is anything I can do to be of further assistance. Best of luck as you prepare to present this patch and many thanks for all your work, generosity, and especially patience in working through the various issues to get this ready to share. My goal is to help ensure that the end user experience is as consistent as possible. Peace - Anthony
Hide
Anthony Borrow added a comment -

patch file added to CVS, tracker privileges bumped, CVS write access granted, tracker component created. I think that is it, so I am resolving. If I have overlooked something just let me know. Peace - Anthony

Show
Anthony Borrow added a comment - patch file added to CVS, tracker privileges bumped, CVS write access granted, tracker component created. I think that is it, so I am resolving. If I have overlooked something just let me know. Peace - Anthony
Hide
Ravishankar Somasundaram added a comment -

Latest package with few fixes on install.xml and other lib functions

Show
Ravishankar Somasundaram added a comment - Latest package with few fixes on install.xml and other lib functions
Hide
Anthony Borrow added a comment -

Ravi - Here is the file structure I am hoping to see in the zip file. Note the renamed README.txt (remember in Linux file names are case sensitive so Curriculum is not the same as curriculum). Let me know if you have questions. Also, looking at the en_utf8_local files those should really only need to contain the strings that changed. Are all of the string in admin.php and moodle.php really necessary? Peace - Anthony

Show
Anthony Borrow added a comment - Ravi - Here is the file structure I am hoping to see in the zip file. Note the renamed README.txt (remember in Linux file names are case sensitive so Curriculum is not the same as curriculum). Let me know if you have questions. Also, looking at the en_utf8_local files those should really only need to contain the strings that changed. Are all of the string in admin.php and moodle.php really necessary? Peace - Anthony
Hide
Ravishankar Somasundaram added a comment -

Anthony, will resolve the mysql.sql and mysql.php files issue soon, it contains entry for a single field addition which was not possible using the install.xml because it simply didnt support it.

I might need to work on the coding part to find a workaround,

Have it on top of my to do list.

And yeah, the Readme.txt was a mistake, correcting it now and will upload it with other changes.

As soon as i correct these will make a moodle doc entry and a entry in plugins page for the same.

And thanks for the wishes

Will do my best to make the end user experience as consistent as possible.

Show
Ravishankar Somasundaram added a comment - Anthony, will resolve the mysql.sql and mysql.php files issue soon, it contains entry for a single field addition which was not possible using the install.xml because it simply didnt support it. I might need to work on the coding part to find a workaround, Have it on top of my to do list. And yeah, the Readme.txt was a mistake, correcting it now and will upload it with other changes. As soon as i correct these will make a moodle doc entry and a entry in plugins page for the same. And thanks for the wishes Will do my best to make the end user experience as consistent as possible.
Hide
Anthony Borrow added a comment -

p.s. - Keep in mind that the local language files go in the Moodle data storage path so you need to give instructions in the README.txt file for how to install that. Also, I would only have one README.txt. Take the contents from the plugin_base one and put them in the other. I'm not sure what you mean about the install.xml not working. You can also use upgrade.php if you need to add a new field to an existing table.

Show
Anthony Borrow added a comment - p.s. - Keep in mind that the local language files go in the Moodle data storage path so you need to give instructions in the README.txt file for how to install that. Also, I would only have one README.txt. Take the contents from the plugin_base one and put them in the other. I'm not sure what you mean about the install.xml not working. You can also use upgrade.php if you need to add a new field to an existing table.
Hide
Ravishankar Somasundaram added a comment -

ok

Next upload will have the folder structure expected.

have noted the squashing of README.txt to be done too.

Yes thats how its been done in the uploaded package, have used install.xml for installling new tables and upgrade.php for other manipulations on existing tables.

Have a field which has default value as CURRENT_TIMESTAMP which is not supported, so need to change this to linux time stamp and remove the default parameter and handle the same through php code.

Show
Ravishankar Somasundaram added a comment - ok Next upload will have the folder structure expected. have noted the squashing of README.txt to be done too. Yes thats how its been done in the uploaded package, have used install.xml for installling new tables and upgrade.php for other manipulations on existing tables. Have a field which has default value as CURRENT_TIMESTAMP which is not supported, so need to change this to linux time stamp and remove the default parameter and handle the same through php code.
Hide
Anthony Borrow added a comment -

Sounds like you are on track and almost there. My goal is that the curriculum.zip file I uploaded is essentially what folks will get when they download from CVS. Let me know if you have questions and if you don't mind give me an idea of what you plan to upload to CVS before doing so just to make sure that all looks good. Peace - Anthony

Show
Anthony Borrow added a comment - Sounds like you are on track and almost there. My goal is that the curriculum.zip file I uploaded is essentially what folks will get when they download from CVS. Let me know if you have questions and if you don't mind give me an idea of what you plan to upload to CVS before doing so just to make sure that all looks good. Peace - Anthony
Hide
Ravishankar Somasundaram added a comment -

I will do that for sure, before uploading it to CVS il send you the zip file for validation on above mentioned issues

Show
Ravishankar Somasundaram added a comment - I will do that for sure, before uploading it to CVS il send you the zip file for validation on above mentioned issues
Hide
Anthony Borrow added a comment -

Thanks Ravi, I appreciate it!

Show
Anthony Borrow added a comment - Thanks Ravi, I appreciate it!
Hide
Anthony Borrow added a comment -

Closing all of my resolved issues. Peace - Anthony

Show
Anthony Borrow added a comment - Closing all of my resolved issues. Peace - Anthony

People

Vote (0)
Watch (3)

Dates

  • Created:
    Updated:
    Resolved: