RatingStars component

Hi,
unfortunately my add-on really was never tested on mobile devices. I try to find some time to take a look at mobile support for the RatingStars add-on, but really cannot give you any promises of when I can fix the issue.

  • Teemu

Hi Ngan,

Thanks for great component.

I have however small problem with it - not looked at details in the code why yet but thought of asking first.
I am adding this component to table using custom extension of DefaultFieldFactory.
In that method I create this component as:

RatingStars ratingStars = new RatingStars();
ratingStars.setMaxValue(10);
ratingStars.setStyleName(“tiny”);
ratingStars.setImmediate(true);

The table itself is connected to SqlContainer.

  1. If I don’t put this code the data read from DB is not reflected in the component at all:

Item item = container.getItem(itemId);
Property property = item.getItemProperty(propertyId);
if (property != null && property.getValue() != null) {
ratingStars.setValue((Double) property.getValue());
}

  1. After doing that - the initial display of the component in the table basically doubles the
    original and correct value, so eg I have in DB value 3 - it displays 6 stars, for value 1 - displays 2 so fo so on …
    If I hover over the cell containing the rating star - it moves to the cursor and when navigating out of the
    cell / component - it suddenly displays correct value - not doubled.

Would you have any idea for the reason behind it ?

Many thanks,
Adrian

Hello! Thanks for your great component!
But why i can’t set value 0 after then i already set value 5, for example?

Can this be start information be stored in mysql so that everytime if someone clicks on star averaging of star values must be poped up?

Hi Teemu,
Our company is using your add on Rating Stars. Unfortunately a lot of customers are not able to add their feedback responses when using iPhone/iPad. I tried to debug the problem and what I found is that valueChangeListener is never called when using iPhone. Whereas when clicking on the stars from desktop or another mobile device does call the listener and so the value can be recorded. Can you please look into this?

Unfortunately I currently don’t have time to maintain this add-on. But if someone wants to work on this issue, I’m happy to review a pull request.

Hello, Teemu, I am Vagharshak from bonprix in Germany. We are using Your RatingStars addon and are very happy. Currently we have a new feature requirement, which is no supported by the addon currently: we want have the possibility to rate “back” to 0 stars, after rating is already done on the bar. We want to implement this following way: if, say, the bar currenty is set to 3 stars, clicking on the 3-rd star would set rating bar to zero (all start deactivated). And generally, each click on the current maximal star X would “reset” the rating bar. Would You like to have this feature in Your master branch? If yes, we would fork and implement the feature in the fork. Afterwards You could integrate the feature into the master. Thanks and best

Regars, VB