I was wondering if it's possbile to make a views integration. This would enlarge the possibilities of this module; for example, the user can see on a page/block which shifts are planned to come in the following days, changed shift messages, and so on..

Anyone else up for this integration request?

Comments

Hi

I contributed to this project adding a commit for special events which got rolled into Drupal 7.

I looked at Views Integration for this module and realised it needed a complete rewrite specifically the issues are:

Shift Scheduler does not create nodes or entitys thus Views Integration would be nigh on impossible.

I looked at a successor module (I ran out of time to do it or indeed the business imperative to do it either) but got some way to investigating the project scope.

Principally the project needs a number of things

1) Create a shift node entity content type with at least a date and an entity reference for either users or a content type to hold names of those taking shifts, a taxonomy vocabulary of roles, other fields as necessary so it is flexible enough to work for anyone.

2) Some way of recurring shifts. This involves a module like node date repeat or one of the four similar modules. Unfortunately none of them work as needed with all covering the same ground as each other and either being D6 specific or buggy. This would take a node with a date repeating field plus start and finish times and extract (explode if you like) these into seperate nodes for each day, each of which can then be edited and allocated to users/people as necessary.

3) Special Events would be best served by adding a shift content type node (or multiples shifts) for each event. Entity inline form would be a good starting point here but would need some extending to eliminate the need to duplicate dates and times.

4) Once you have all the fields field access of some form would handle permissioning (to control shift allocation)

5) Finally a calendar view with exposed form for shift allocation would replace the calendar in this module.

So there is as I see it the shopping list. I haven't been "shopping" to check the current status of some of the mentioned modules but if they have all been ported into D7 or are stable then all but 3) above could be achieved with practically no code to be written. This could also be a blueprint for an entity/node friendly and thus views friendly version of shift scheduler.

I hope this helps.

Tim

I understand, seems there's a lot of work that has to be done..

Hi

The major bulk of the work would be getting the nodes to recur from a repeating date, as soon as a solution with a good API is available this would be possible. I don't think the 'special events' bit is that much work to be honest and step 5 should be easy.

That node recurring bit is the annoyance see http://drupal.org/node/894680 for a discussion of the four (or is it 5) differing modules none of whom is working correctly for D7

An interesting project for someoned with good PHP who wants to learn the ins and outs of entitys and nodes in Drupal 7

By the way if anyone wants to use this methodology in d6 you should be good to go apart from special events as I recall most of it worked in D6.

Regards

Tim

with views integration this module would be killer!! i wish I was better with PHP... Subscribing :)

I have returned to this concept again and am considering the not inconsequential issue of how to break out repeated dates into nodes. This issue has been discussed again and again over for five years or so, there have been various attempts at a solution but only one in D7 so far, Quite rightly the debate is twofold, one how to ensure there is one good module rather than 5 part solutions and secondly how it should be done.

You can see the discussion here http://drupal.org/node/298334

If there is a solution that can quickly be brought together then we will have a workable solution for D7 and thus Views integration.