Jump to content

Generating table output


Ronnie
 Share

Recommended Posts

Hi.

I need some brainstorming help, how to accomplish this task in the smartest way.

What I want to do i pretty simple/straight forward, a table with all my team members and ratings on how much knowledge they have in particular Products / Technologies.

I would like to have each teammember as a page and just add competence and rating together with competence area.

One approach would be to create unique fields for each Product / technology.

Ex

Field_Product_1

Field_Product_1_rating

Field_Product_1_competence_area

This will create a template that will be straightforward to work with, but as I have approx 60 products it will demand 180 fields, and that will take far to long to set up and be hard to administrate.

Another approatch would be to use one repeater for each competence area, with drop downs for the different products in each competence area and a dropdown for the rating.

But as repeaters is working in a way there you just can add hw many you want there is a great risk that the products will differ between different employees.

Here is a screenshot from excel with what i want to acheave,

post-1232-0-67280100-1410892386_thumb.jp
 
I hope that someone understand what I am searching for and have som valid input.
 
Thanks / Ronnie

post-1232-0-67280100-1410892386_thumb.jp

Link to comment
Share on other sites

  • team
    • joe
    • sally
    • lawrence
  • website data
    • food
      • fruits
        • apples
        • bananas
        • clementines
      • vegetables
        • asparagus
        • broccoli
        • cauliflower
      • meat
        • beef
        • chicken
        • pork

Lets say you set up your processwire website like this. Everything in italics is merely website data as pages. 

  • team = template "team", and actual viewable page with a template file
  • joe, sally, lawrence = template "employee"
  • the rest = template "generic-data"

On the employee template you could attach a repeater called "food_ratings". That repeater could have two fields, "food" and "rating". Field:rating would simply be numeric from 1-10, and field:food would be a "page reference" field.

Now when you create or edit a new employee page, you have a repeater where you can attach the data of an arbitrarily chosen new food and then give it a rating value for how much that person likes it, eg:

  • darren
    • food_ratings1 = apple, 10
    • food_ratings2 = broccoli, 5
    • food_ratings3 = chicken, 9

Could something like this be a solution for you?

Link to comment
Share on other sites

And actually you really could just drive it all out of page reference fields. For example you could make the field:rating a page reference and add it to your website data structure.

  • website data
    • ​food
      • ​[see above]
    • ratings
      • ​professional
      • expert
      • intermediate
      • novice
      • none

Simply drive the reference from /website-data/ratings/ and then youll have some flexibility if you ever want to change the ratings and turn them to "stars" or assign them numeric values.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...