views:

14

answers:

1

I had built a website for my client with Drupal 6 . Now he wants to query cost of his service from one town to another town. I know basics of CCK and Views. I will need two select box for towns and show cost of between two towns and a way to let customer enter cost between towns. What is the easiest way of doing it in Drupal ? I am a java guy no PHP experience.

Edit:tablefield look promising. I need a way filter it view module. If I will succeed will write how to do it here.

+1  A: 

As a hack-type solution, you could do this:

  1. Create a new content (node) type, say, "Transport Routes".
  2. In it, define CCK fields From town, To town, Cost.
  3. Create a new View, which would display the Cost field.
  4. For the above view, enable two filters on the From and To fields, and make these filters accessible to the user.

It does sound very awkward, I know, and a better solution is probably to write a simple custom module, yet if you prefer to stay away from PHP - this is one way to do it.

NPC
is it possiblefill all the field in once? Client have to enter one from to and cost at each time with way.
Gok Demir
You can try some import solution for this - for example, Node Import (http://drupal.org/project/node_import), which allows you to import nodes from a CSV file, and it says that CCK support "almost works" - so you can try it and see if it works in your case. I think simple text fields should work without problems.
NPC