1. My payment system (oscommerce) stores the student record over three tables:
- customer id and password are on one table
- order id and customer id are on a second table
- product id (course) and order id are on a third table
Can I map across the full three tables using some sort of join? Or do I have to run a job first that extracts this information and loads it into a new table so all the details are in one place for Moodle to use?
2. What happens if you are using external database enrollment and a student purchases a new course? This would mean they would then have two records on the external database. Can Moodle figure out on its own that the student has access to two courses or does this cause some problems?
We have been successful in integrating oscommerce and moodle to sell courses,accreditation examinations and quizzes
It is an automatical solution that takes the user automatically to the moodle site and autoenrolls for credit card payments.
I have managed to get the external authorisation working so Moodle is now looking on the oscommerce customers table to find its enrolments. Is this how your system works as well? I am trying to figure out how I do the enrolment into each course. Do you use an external table for that as well or supply enrolment keys instead? If enrolment keys, how do you send these to the student? Are they sent an email when their credit card is processed that has the enrolment key in it?
I would love to know how you manage the auto log in to Moodle. Do you have any code you would be willing to share on this?
One question on passwords and subsequent course pruchasing. Lets say we have the following scenario.
Student logs on to oscommerce and purchase course A. They set their oscommerce account up with the password "first". After the course is paid for and the credit cared authorised, they are logged into Moodle. moodle uses external authorization to check the oscommerce database (I am assuming you have Moodle use the customers table for this). The following day the student then changes their password in moodle to "second". Moodle updates the Moodle tables but does not affect oscommerce. The following week the student then logs on to oscommerce and purchases course B. They have to log on to oscommerce using the password "first". Now they have two courses they have purchased but different passwords on the Moodle and customer tables. When they next log on to Moodle, will it check the Moodle tables first to see if the user is there or will it go straight to the oscommerce tables? If it goes to oscommerce, will they need to use "first" or "second" to log on to Moodle? Confused?
I guess what I am struggling with is if you are using external checking for the user access, does Moodle still check the Moodle tables first to see if the user exists?
Any suggestions you have on how I can integrate this smoothly would be greatly appreciated!
We've done a full OSCommerce integration that I'm hoping on merging into 1.6 -- it doesn't read OSCommerce tables directly, it uses an enrolment token instead to enrol users.
The patchlog is here, but it shows all the merges too: http://locke.catalyst.net.nz/gitweb?p=moodle.git;a=shortlog;h=mdl-osc-ceed
I have tried to work out which files in the list work with moodle but am not having a lot of luck! Is there a cvs anywhere with a download of all the files needed and documentation? I have figured out how to get the user authorization to use the oscommerce table customers to check for users. It is the next part where a student can enrol in the courses they have paid for I am struggling with!
Do your students always go to moodle first and then enrol or can they just go stright into oscommerce and purchase their course and then be taken to the moodle system?
One other question for yourself or anyone using an external table for user authorization. Do I need to add all my existing students to the oscommerce table customer in order to keep their access or will moodle check its owqn tables first and only go to the external one if the user cannot be found?
Appreciate any help available here!
the link I provided is showing you a list of commits - unfortunately, there commits are merged with all the commits happening in Moodle 1.5.x so it's pretty hard to spot the stuff you need. I don't have a way to provide this easily at this time for you to try. At any rate, you'll need a programmer to set things up.
WRT the 'workflow', users enrol in Moodle normally -- internally we create a record in OSC when the user logs in for the first time. When the user wants to enrol in a course marked for OSC, we send the user to OSC. Once the user has paid for one or more courses, OSC gives them one encrypted token per course. The tokens are used as proof of purchase and to actually enrol.
From the transaction complete page, the user clicks on a link that takes her back to Moodle and passes the tokens along. When Moodle sees the tokens, it enrols the user accordingly.
There is also an addition to the 'Participants' page to allow teachers to grant extensions to the enrolment (as we used enrolment periods with the OSC-enabled courses).
It is a fairly clean job (thanks to Patrick Li!). It does not use auth/db or enrol/database plugins; instead, it is based on SSO plugins. This has the added advantage that you can run it in parallel with different auth and enrolment plugins.
The code is available using Cogito/GIT (a new version control system developed by the creator of Linux). To check it out you'll need a Linux or MacOSX system, you'll need to install GIT and Cogito, and do
This was custom developed for the TurboCASH Accounting Project.
I have to revert back to the programmer and just discuss the licencing issues on this.Again ,I myself am not a programmer.But I can find out about your issues.
The Project Leader of TurboCASH which is an open souce accounting package, is very keen on Open-sourcing the Oscommerce Moodle Intergration, if we can overcome the licencing issues.
It has the advantage of being seemless for credit card transactions.We could have done this with EFT as well but we decided that we would land up debt-collecting unpaid courses. So there is a manual log-in for Bank Transfers.
All the programming is done on the OSC side. The basic thought process is to use the model field in OSC as the ID field to compare to the course ID field in moodle,and authenticate with the enrollments
The moodle login is firstname ,oscommerce password.
I believe a user can purchase multiple courses in oscommerce.
But you bring up a very relevant point now, i.e. Can user re-take a course.
We never considered this aspect . But since we are going to sell accreditation courses which users will have to repurchase if they fail ,this will be necessary.