Hi. I believe agreservations can be used for taxi/cab reservations e.g. on a specific date at a particular hour, and number of passengers.

I had a go at the setup but it is not very clear on how to do this by following the "README" file. I did not seem to be able to connect the ubercart product created with the timeframe, even though all the appropriate modules are installed.

Please could some post the steps for this kind of setup? Thanks

Comments

zeezhao’s picture

Ok. Kind of got it working, although a few bugs/errors which I will post separately.

Also will have to decide if can be used for base for this kind of reservation, as need to add joruneys and distance calculations etc using location/gmap & computed_field modules etc.

zeezhao’s picture

Trying to see if can be used, so added location & gmap modules etc. Added a "From" and "To" location fields on Reservation content type to indicate Journey From/To.

When trying to create Reservation, and press Save after filling fields, I get:

EntityMalformedException: Missing bundle property on entity of type node. in entity_extract_ids() (line 7633 of .....\includes\common.inc).

@agill - please does this mean that we can't add fields to Reservation?

I am using drupal 7.17 with latest devs agreservation (2012-10-10 -- 7.x-2.0-beta3+5-dev), ubercart ( 2012-11-21 - 7.x-3.2+53-dev) , entity (2012-10-24 -- 7.x-1.0-rc3+11-dev).

agill’s picture

i just did a quick test with a simple text field that i added to drupal 7.15 install with agreservations enabled.
I did not get the described error. Also the error does not really sound like it has to do with agreservations.
Are you using the locations module? and did you add the fields as entity reference fields?

For your use case i suggest using the following:
I suggest creating a separate contenttype as node-contenttype using the following modules:
Address Field, Geocoder, geoPHP, Geofield, Geofield Map
and maybe openlayers to have the points visible on a map.
And then adding an entity reference field to the reservations contenttype

Why do i suggest node-contenttype and not a separate entity? -because currently
openlayers proximity works best with node based geofields and not yet with geofields attached
to other entities which are not nodes (nodes are indeed entities, but lots of modules still have code that addresses node fields, the old way)

thats all that comes to my mind.
Taxi-reservation is an interesting use-case and i would like to see it in action ;-)

zeezhao’s picture

Thanks for your reply. I had got agreservations to work first without any changes. It was only after then that I added new fields to the Reservation content type via:
admin/structure/types/manage/agreservation/fields

Yes, I am using location module (2012-09-03 -- "7.x-3.0-alpha1+1-dev"), gmap (2012-11-04 -- "7.x-2.2")

I also use computed_field module to add a "Distance" field to the Reservation. It is calculated using longitude/latitude and location function earth_distance( )

edit:
Note that I was able to amend an old reservation created before adding From/To locations fields. That did save correctly - so location/gmap works. So issue is when a brand new reservation is created using:
node/add/agreservation

agill’s picture

adding the same fields you added to reservations contenttype to another
contenttype and then inserting a new node using node/add/anothertype
-have you tried that?

zeezhao’s picture

Yes, I did that too. Sorry - I have found out the issue - was due to a bug in the computed_field I am using, and only evident on brand new nodes.

Some immediate things to think about:
1. when I use node/add/agreservation it means user has to choose specific unit to reserve.
However, when done via your booking block, it picks a generic unit. But no way of telling how to allocate?

2. How to edit order/reservation when in cart?

3. Sometimes reservation created using node/add/agreservation can be disconnected from cart, especially if user has to edit reservation. [edit: i.e. "Create Order" link disappears and hence user can not add it to cart and hence pay, even though reservation exists admin can.]

zeezhao’s picture

@agill - please whenever you have a moment, let me know your thoughts on the issues in #6. Thanks

Yorgg’s picture

I also get this without location, gmap, agreservation or ubercart. I get 8 of those when running importing fields with nodes but the error is exactly the same.

zeezhao’s picture

In relation to #8, as mentioned above the error has nothing to do with agreservations. Its probably related to one of your newly created fields or a module associated with those fields.