By thefoolmartyr on
I will be creating a massive book list and want to organize the books by multiple catagories (department, ISBN, author, etc). I want the list to be searchable by all those different fields. Is this possible within a drupal module? I need drupal to allow for this resource to be accessed only for members. I know I can just create a mysql database and write up a simple script to search through the database, but can I just throw this onto a drupal page? Is there anyway to access this database from the drupal admin interface?
Thanks in advance
Comments
(no title)
You could create a "books" content type for book entries, and (with the help of the CCK module) arrange its layout and the fields it contains on a form. Those fields might be:
- Department: A category field, drawing values from a taxonomy, hierarchical or not (Taxonomy module -- in core, and cck_taxonomy module)
- ISBN: A simple text field
- Author(s): Either simple text field(s) or "node reference" field(s) drawing values from another linked content type which you have created in a similar way, let's call it "authors", with info about authors.
- Date fields, an image field, a text box for reviews... whatever. These can be arranged on the form with the help of the Content Template module or with theming.
All or part of these fields for a category of books or for an author can then presented arranged the way you want, for example in teaser lists or in tables, with the help of the Views module.
With the help of one of the available access control modules (depending on what you want to do), you can also set up access control to the nodes themselves and/or to their listings, either by content type, or by category, or manually for single nodes. So, you can define "user roles" which are allowed or not to view/review/edit something, and you can just assign these roles to certain users.
Connecting Drupal with an external database and running custom code is easy (see comments in settings.php and in the Handbook), but then most of Drupal's facilities that I tried to describe won't be available, so, for custom tasks, it would be better to familiarize with Drupal's concepts (node types and nodes, taxonomy, views etc) and with Drupal development:
http://drupal.org/node/508 -- Module developer's guide
http://api.drupal.org -- Drupal's API
http://groups.drupal.org/drupal-dojo -- Drupal Dojo group
http://www.apress.com/book/view/1590597559 -- Pro Drupal Development book
So, Drupal can do pretty much anything but takes work.