July 2012 Update: a third party contractor built a phonebook for us using entities and Drupal7, therefore we no longer need this module. Unfortunately I am unable to share the phonebook work because it was not done in a way that is easy to share even if I had permission to do so. In the future we will be using features to build apps so that the work is easier to share.
For anyone who is still interested in finishing the port of this addressbook module (as a learning exercise perhaps) follow the information below:
Original post below (July 2011):
We have partially ported Addressbook to Drupal 7.x , it is incomplete but partially working in Drupal 7 using the following path: addressbook/family/list this invokes the familylist function that has been completely ported to Drupal 7 (more functions to work on, but this function can be used as a model for porting the rest)
To get to this point quickly we used the coder upgrade module on the code to help with the migration process, we made the necessary changes to the DB API calls and other API calls for the familylist function (it's working inside Drupal7)
The install file has not yet been tested, we copied the addressbook tables from Drupal 6 to Drupal 7 and didn't test the install file under Drupal 7 , so for dev purposes you might want to install the old version in Drupal 6 and then copy the attached updated module files then bring that into drupal 7 including the three addressbook tables.
There were some functionality changes/enhancements I made to the Addressbook prior to starting the port to Drupal 7 but those enhancements were not submitted to this project because the maintainer has vanished. If you complete the migration that I have started these enhancements will be available for Drupal 7.
I added search by first name capability. The module now also handles batch imports and I have tested a 250+ user csv file for importing a company directory prior to starting the code migration to Drupal7, so now those enhancements need to be upgraded to 7 as well (some may have already been upgraded as I'd say my updates are 60% working. Also, for companies everyone has the same address , the logic was changed to allow different individuals to have their own last names and not be related to someone and have the same address. Previously the functionality was indended for families, now the logic has been changed to handle organizations who have many employees at the same location. These were minor code changes.
The major code changes are in the porting of the module it'self (again, I'd say it's at 60% complete as no work has been done since July 2011).
To get this far, I ran coder review and had it automatically bring the coding standard to drupal coding standards (spacing, { openning brackets on same line after closing brackets of conditional statements, etcetera etcetera.
I will attach a zip with two new files:
addressbook.module and
addressbook.info
and addressbook.install
| Comment | File | Size | Author |
|---|---|---|---|
| #3 | addressbook_dev.zip | 90.1 KB | joseph.olstad |
| addressbook.zip | 29.09 KB | joseph.olstad |
Comments
Comment #1
joseph.olstadI have sent several e-mails to Willem van der Plaats and he has not responded to my request to take over ownership to maintain the module as no one else seems to be working on it and he hasn't been responding.
I will continue the porting to Drupal 7, if anyone has any questions about the above drupal 7 code in the above attachments please contact me.
I do not know when the port will be 100% complete. It would be nice if there was someone maintaining this module, I'd like to be able to put the new code on the 7.x stream for this module.
Comment #2
drewkeller commentedDo you have the latest code somewhere?
Comment #3
joseph.olstadHi Drew, I made a few enhancements to the drupal6 version, which in turn were partially upgraded to drupal 7.
The drupal 7 upgrade is not yet 100% complete. However, if you follow my instructions you will be able to run it in drupal 7 and you will be able to see what works and what doesn't
First you have to install the drupal 6 version that I have attached here in a drupal 6 installation of drupal
Then you should run the sample data from the examples folder (addressbook.csv) as an import to get test data in there (feel free to add your own test data, I had over 250 rows of data but I cannot send you my data because it's got real phone numbers from our organization) and it works.
The original addressbook module would not import people if they have the same address. I fixed that in this version.
Once you have it running in drupal 6, go ahead and install the drupal 7 version in drupal 7, you'll then have to export the tables that addressbook created in drupal 6 manually importing them to your drupal 7 db as the install in drupal 7 isn't ready yet, the module works if you have the tables in.
I used the "coder upgrade" module and "coder review" module to do most of the work converting to drupal 7, however there's a lot of work that has to be done manually that I have spent quite a bit of time on and that's the database api calls. Also, I drupal 7ized several other things that the coder review module warns about.
Keep in mind the forms calls that the original author are doing work but they are not using the forms API, that would take more work to do, but I focused on getting the basic functionality going before upgrading.
If you have a problem getting the attachment I'll put it on the drupal.org site again.
If you have questions, make them quick as I am changing contracts and will no longer be at this agency next week. I'll still check my stuff on drupal.org from time to time though. The original author is unresponsive and is not maintaining.
Thanks,
Joseph Olstad
>>> Drew 19/09/2011 2:06 pm >>>
Joseph
I posted a message under yours on drupal's website, but it looks like
you haven't been active there in several months. I was wondering if I
could download the updates you were making for the port to drupal 7
somewhere.
http://drupal.org/node/1205248
Thanks
-drew
>>>>Drew and others, please see attachment with files you are looking to download<<<<<<<<<
Comment #4
joseph.olstadDrew, I created an SVN account for you on my svn server.
If anyone else wants to join in on the fun, let me know , I'll give you access to the repository. As the maintainer of this module is unresponsive we are not able to take over this node until a drupal.org administrator decides to re-assign the maintainership to one of us.
For now, we're going rogue.
Comment #5
joseph.olstadMy contract ended and I went off to something else. Looks like no one else worked on this while I was gone.
Comment #5.0
joseph.olstadUpdated July 2012
Comment #6
joseph.olstadComment #7
joseph.olstadComment #7.0
joseph.olstadminor gramatical change