Using icons to represent data

Status
Not open for further replies.

belindab

New Member
Hi,
I'm creating a site for a eucalyptus grower to enter his date for clients to view. He knows nothing about html or databases, and I must say that he was very happy that with Joomla and Fabrik I have been able to create something that he can use quite easily.
Two questions for you.
1. One thing I want to do is to include images representing boolean values (e.g. leaf image if attractive foliage).
Rob suggested "This requires you to create a folder inside images/stories with png images which represent your tables data. So, if you were recording "1" for nice leaves and "0" for ugly leaves then you might want to create a folder images/stories/leaves with two images files inside it "1.png" and "0.png", representing the two icons.
Then you would edit the element that corresponds with this data and under the "table settings" tab select "/leaves/" for the "Icon folder" dropdown.
I have tried to do this, but am only getting 0 or 1 to display, not the icons. The element type is a radio button with two values, 1 (label:eek:rnamental) and 0 (label:eek:rdinary). I have also tried using a checkbox. In either case the table view shows the value of the field (0 or 1) and in the form view it shows the label.
Can you please advise what else I need to do to get the icons to show up?
2. Ordering of columns in table view - I've set this up in the elements and you can see that because they are red. However clicking on the column headers doesn't make any difference. Why not?
I'm using Joomla 1.5 with Fabrik 1.0.4 latest SVN

You can check out my results at
http://eucalyptus-passion.com/testcms/index.php look at the View Species menu item. (This is all still with default templates at present, please don't judge me on the look!).
Thanks for a very useful component and your help.
Regards,
Belinda
 
The foliage element type is a radio button with two values, 1 (label:eek:rnamental) and 0 (label:eek:rdinary). I have also tried using the same icons with the bark field which is a checkbox.
Thanks,
Belinda
 
OK, that's what I figured.

I think what Rob was suggesting is, instead of using radio buttons, use an image element, which points to a directory with just those two images in it. So instead of selecting a button, you'll directly choose which image you want.

-- hugh
 
Hi Hugh,
Thanks for the suggestion. I have tested this extensively with various options and cannot get the correct results.

I can only get the icon to show up in the detailed view by setting the image folder and filename - then the same icon always shows up, regardless of which one the user chose....

If I set the Image folder to "n/a" it always changes on SAVE or APPLY to "/" and then in the table view it shows the label "test" and in the detailed view it shows a square red bullet

If I set 'show the image in table view' it displays the label, in this case "test"
If I don't set 'show the image in table view' it displays "0.png,0.png" or "1.png,1.png"

Because Rob mentioned the Icon Folder drop down, I assumed that he was suggesting that somehow this would select the images based on the VALUE of the field, whether 0 or 1; which would be neat. But I can't get this to work with drop down, checkbox or radio button fields.

I have about 15 different features to display for each tree, so I need to get this working, somehow. I'd be most grateful for any other suggestions, or if it is a bug, a fix would be great!
Thanks for your help,
Belinda
 
OK, I think I've fixed the problem with the 'image icon folder' stuff. It was an issue in the Fabrik code, which was breaking the icon replacement code.

I now have it working as advertized, at least for tables. So, for instance, on a dropdown element, if you select an 'icon folder', any dropdown value that has a coresponding .png file in the icon folder will be replaced by that image. NOTE that the dd value should not include the .png extension. So if you want to display foo.png, give the dropdown item a value of 'foo'.

I'm about to work on the form display, so in View Only mode it will do the same thing.

Once I've tested here, I'll upload the changes to your site and test some more, before I commit the changes to SVN.

-- hugh
 
OK, I've uploaded the fixes to your site, and they seem to work OK. I had to make one small change (you had 'group repeat' set, which you don't really need, and tends to complicate things.

I also fixed your upload element. The problem there was twofold ... trailing slash on the dir name (yes, I know the tooltip is wrong, and we need to fix that so it doesn't care if there is one or not, but right now ... no trailing slashes on dir names). I also removed the _thumb prefix, which makes the lightbox stuff work a bit better. With the thumbs in their own subdir, you don't need the extension.

Obviously a lot of your test data is in the wrong format, but I created a working test entry and edited a few others so you should have enough working examples to go on.

Can you confirm that things are now working, and I'll commit the changes to SVN. Or not. :)

-- hugh
 
Thanks Hugh, it looks like its operating as I would expect now. I'm having some problems working today as our rural ADSL service is currently running at only 56kbs, so I'm going to do some gardening instead....I'll do some more testing on Monday morning (My time zone is GMT +1, where are you?).
Thanks again for sorting this out. Glad it wasn't me being an idiot though.
Belinda
 
Definitely not you being an idiot! You just ran across an area that very few people seem to use, so nobody has ever brought that bug to our attention.

It's not quite working perfectly yet (for instance, using repeating groups will break it right now), but it's working a heck of a lot better than it was (which was not at all!).

Have fun gardening!

-- hugh
 
Ok,
this is working for me now. I don't really need the repeating groups, but I thought it would make life easier for my client when they have a lot of data to enter.

I have noticed one thing on the back end which I hadn't tried before. In Tables, View Database if I click on View at the far right it always takes me back to login. Shouldn't I be able to see the Detailed view from the back end?

Belinda
 
Yeah, I noticed yesterday that some backend links were logging me out, I'll have to look in to that.

The repeating groups feature probably doesn't do what you think it might, so best leave it turned off. It doesn't create new rows, rather it inserts multiple, comma separated lists of data into the individual elements in that group, in the same table row.

-- hugh
 
Status
Not open for further replies.
We are in need of some funding.
More details.

Thank you.

Members online

Back
Top