Add the ability to take attendance for each gradebook daily.
Features
- per class/gradebook
- once per day
- admin interface to reconcile attendance at the end of day
- integrate with views
Implementation
Basically this would add either a link or button to take attendance right above the gradebook when viewing it. If attendance had already been taken that day then the link won't show up. The page that takes the attendance will get the students in the gradebook using the gradebook api (possibly og_gradebook). Then it will allow the teacher to input for each student present, absent, or tardy. At the end of day a secretary of the school can go to an administrative interface to reconcile the attendance for that day. Basically this person would choose whether the absence/tardy was excused or unexcused. Finally students/teachers will be able to view the atttendance records on the user page of the student.
I would love to create this module to extend gradebook but I would like some suggestions. One of the things I am deliberating about is whether these attendance records should be nodes. I would like to hear what everyone thinks about this and other aspects.
| Comment | File | Size | Author |
|---|---|---|---|
| #21 | gradebook_attendance.zip | 2.13 KB | jdwfly |
Comments
Comment #1
MGN commentedSounds like this would be a helpful addition.
A couple of thoughts:
I like the idea of a connection between the gradebook and attendance record. Is it possible that the attendance record itself might also factor in the grade? Should it have an associated taxonomy term in the gradebook vocabulary?
The frequency of classes may not be daily - it might meet twice a week or three times a week, so this should be part of the configuration. Optionally, the teacher might not need to select the date at all. Just add an attendance entry whenever the teacher decides to take attendance (i.e. it needn't be at regular intervals).
Rather than above the gradebook, you might want to pop open a new window that closes when class attendance is submitted.
Are additional permissions necessary, or is 'administer gradebook' not too broad for the person selecting excused/tardy? You could either handle this through drupal role, or gradebook roles...
What is the argument for the attendance records being nodes? I am not sure I see the benefit in that.
Comment #2
jdwfly commentedThe attendance could factor into the grade. I am not exactly sure how one would grade attendance. There would obviously be a total amount of days they should have been present. That could be divided by the days they were present plus excused absences. They should obviously not get credit for days they were unexcused. If that is linked with a taxonomy term then someone could easily set it as a certain percentage of their grade.
I realize that the frequency of the classes may not be daily, but the link would be there every day until they take attendance for that day. If the class doesn't meet then they don't need to take attendance. So attendance will only be taken whenever the teacher takes it and the date it is taken is the date of the record.
My suggestion was for a link to be above the gradebook, which when clicked it would lead to a page to take attendance. The attendance would not be taken on the same page. Once the attendance is submitted they go back to the gradebook page. I don't know that I would like the pop-up idea, but if others mention it I may be inclined to take that route.
The problem with selecting excused/unexcused for an absence or tardy is that most likely a teacher will not know this. This will need to be done by an administrative secretary that is keeping track of this. This may be unnecessary if you are just wanting to keep track of absences in a smaller setting, but if a school is using this to manage attendance I believe they will have a secretary keeping track of excused/unexcused absences/tardies.
I didn't want them to be nodes either.
Comment #3
MGN commentedIt sounds like we agree. I think this will make a nice submodule. If you want to try to code this, I would be happy to help out as needed and evaluate the code when it is ready.
Comment #4
jdwfly commentedI'll begin work immediately and I'll post it as soon as I can get it's basic functionality working.
Comment #5
jdwfly commentedI am trying to figure out where the best place would be to insert the link to take attendance for a certain gradebook. So what do you think about that link on the gradebook page? Do you think that is a good idea? I really don't know where else I would put it.
The only way I know how to put that link there is to add some code into gradebook.module. Is there a way around this or do you think the link should go somewhere else?
Comment #6
MGN commentedYes. I figured you would be getting to that question soon. I agree that gradebook needs a hook to allow submodules to insert links on the gradebook page. How about adding something like the following block in theme_gradebook_page()
and then in the submodules we can do something like (I am working on roster now, so you'll want to adopt your own version of this function appropriate to attendance)
What do you think? Would this be sufficient?
Comment #7
jdwfly commentedI think that is exactly what I was trying to suggest. I haven't actually made any modules that had their own custom hooks. Is this how you are going to name the hook? I just want to be accurate when I am creating my module.
Comment #8
MGN commentedI think this name can work. It makes for long function names, but its also clear what they do. This code also makes it easy to customize the format via gradebook.css.
Comment #9
jdwfly commentedWhat does your hook_menu function look like for the roster module? I keep getting an access denied error and my hook_menu function should probably look very similar to yours.
Comment #10
MGN commentedLooks like the wildcard is off....gradebookapi_is_teacher needs the taxonomy term, not the term id....
Comment #11
jdwfly commentedThanks, this helped me figure it out.
Comment #12
MGN commented@jdwfly. I've just updated Gradebook and a few things have changed that might affect your development of this submodule. 1. Submodules are now in their own subdirectories for better organization. 2. I've changed hook_gradebookapi_get_students and hook_gradebookapi_get_teachers a little (see CVS messages, Changelog file, etc for more information).
You can continue developing with the pre-April 1, 2009 version, and I can adjust things to work with the new dev. I just wanted to let you know that there has been some changes to the api...
Comment #13
MGN commentedAlso note that this affects og_gradebook as well. Next time you get the latest gradebook-6.x.2.x-dev, be sure to also get the latest og_gradebook-6.x.2.x-dev release!
Comment #14
jdwfly commentedThanks, I'll make sure to check out the new version. I haven't been able to get very far in development (actual coding), so it shouldn't be a huge issue. I'll have some time over the next few days, and I am hoping to have a working version.
Comment #15
jdwfly commentedI have made good progress on the module so far, but the theme process is a little tricky. Basically I am using a form, but in order to make it look nice I really want to lay it out in a table some what similar to what the permissions page looks like. I have been reading the code for that, but I haven't been able to make it work yet.
All the attendance page needs to have on it is the student name in a column and then a select field with the options to choose (absent, present, tardy). It's easy to use the default layout of a drupal form, but it would look nicer if I could use the theme('table',...) function on it. Maybe you are doing something similar with your roster page?
Comment #16
MGN commentedYou can follow the example in gradebook.module and gradebook.pages.inc for the gradebook_grade_form (which is a themed table). The key steps to theming the form are to specify the theme function in the $form array like
$form = array('#theme' => 'gradebook_grade_form');,and then theme the form in a function like
function theme_gradebook_grade_form(&$form), using drupal_render to render the form elements. These can be placed in the rows of a table, which can also be themed. Have a look at theme_gradebook_grade_form to see how this is done.Finally, remember to use hook_theme (as is done in gradebook.module) to tell the theme layer about your new theme function.
That should do it.
Comment #17
jdwfly commentedThanks for the help MGN! I was able to follow your code and make my own theme function for my form. I now have the basic functionality done. I'll be working on the admin interface to it as well as integrating a page in with the user page.
Comment #18
zietbukuel commentedsubscribing
very interested in this module, any news?
Comment #19
jdwfly commentedActually I finished this months ago, but never put it up here because I didn't think it anyone wanted it. Let me go fish it off my hard drive and see what needs to be done to make it ready to go.
Comment #20
MGN commentedThanks jdwfly. I am also still interested - just been working on other things lately. I'll be happy to have a look and work it into the 6.x-2.x-dev release when its ready.
Comment #21
jdwfly commentedHere is what I found. I don't think this was my most recent development though. Sorry, but this is all I've got.
Comment #22
MGN commentedThanks, I am reviewing this now. Do you have a gradebook_attendance.install file to create the new database table? If you do, please attache it. Otherwise, I am sure I could figure it out from the module file.
Comment #23
MGN commentedReading through the code, I think this is a good start. I think it would also be helpful to provide an attendance summary page, with an option for including attendance in the gradebook (i.e. either as an attendance category so it can be counted as an assignment and tallied into the course grade). The summary page should be accessible from the gradebook link, available for the teacher as well as the student.
Comment #24
MGN commentedThe gradebook attendance module is now part of the 6.x-2.x-dev package. I started with jdwfly's code and then further developed it. One significant addition is the option to create attendance assignments - automatically assigning points to a gradebook category for student attendance. Here are some details that are now part of the README.txt file.
I think that everything, except views integration, from jdwfly's initial feature list is present. I'll leave this issue open as a reminder to follow up with views integration.
Comment #25
AntiNSA commentedAwesome. I am wondering a bit if you can go into detail about the daily attendance assignment part? I
I am trying to give my students a daily blog writing assignment. Is this how the attendance assignment functions?
Also, can you create different than teacher permission levels to allow class monitors to take attendance, but not let them alter grades?
Comment #26
MGN commentedThe attendance assignment was designed with the idea of taking class attendance, but I suppose it could also be used for your daily blog writing assignment. There are only three levels of grades provided - present, absent and tardy. If that is sufficient then each day that a blog writing assignment is do, you can "record attendance" and give each student a grade. You specify how many points for each grade category, and the gradebook possible points and earned are automatically updated for each student.
I think I could generalize this module to better provide for use cases similar to this. Perhaps changing "attendance" to "repeating" would make sense. Then attendance would be one way to specialize it.
I also like your idea to grant some gradebook roster roles the ability to take attendance.
Comment #27
AntiNSA commentedhmm.. Maybe attendance and repeating should be kept different submodules. If possible create a task/assignment category, which gives set number of points for automatic task completion, and you could set the number of allowed tasks per day and maximum allowed task responses. if possible a drop down box of allowed points in the range of the daily automatically given points.....
That way you can say a daily blog would automatically be scored a 10, however during random spot checks and assigned peer monitor checks , they could use a drop down box with points 1,2,3,4,5,6.7.8.9.10 to edit the automatically scored blog. The drop down box would save steps required to edit a commonly reoccurring process.
Comment #28
marilynmorado commentedIf you need an attendance recording system I recommend using http://www.ghg.com I use them for my company for my employees and when we have festivals to keep track of people, supplies, etc.
Comment #29
AntiNSA commentedIm going to try the gradebook attendance module... I really need it integrated and it is now.. I just havent had a chance to test this yet. I need to it is on my l ist of things to do.
Comment #30
karensmallwood commentedGreat module - thanks
Comment #31
MGN commented