Rating Review - gobezu/k2fields GitHub Wiki
Currently jcomments is the supported comment system.
In order to use this feature:
- Install jcomments 2.3+ and corresponding K2 plugin and enable the jcomments plugin
- Enable the
rate
plugin in jcomments folder - Enable the
ratefix
plugin in system folder
Once these basics are in place you will need to define your rating criteria for each rating category. This is done in the setting of the rate
plugin in jcomments folder. We don't yet provide fancy interfaces for this purpose but the definition is straight forward and I will walk you through a sample definition available from here.
An excerpt of the file for one criteria group and to be added in the Rating criterias
field of the setting (please make sure to use the K2 rating criterias and groups
panel):
1%%Would you recommend this %cat% to others?%%20%%1=No,2=Maybe,3=Yes%%false%%stars
1%%Reception%%10%%1=Ignored,2=Welcomed,3=Felt very comfortable%%false%%stars
1%%Sanitation%%10%%1=Not acceptable,2=Clean,3=Immaculate%%false%%stars
1%%Money value%%20%%1=Too expensive,2=Reasonable,3=Worth every penny%%false%%stars
1%%Quality and freshness%%10%%1=Under expectation,2=Good,3=Excellent%%false%%stars
1%%Atmosphere%%10%%1=Unpleasant,2=Comfortable,3=Joyful%%false%%stars
1%%Timing of service%%10%%1=Was just about to leave,2=Acceptable,3=Timely%%false%%stars
%%
is the delimiter of the definitions- the first column ties the several criteria together to a criteria group, and in this case we have criteria group 1
- the second column is the criteria itself. As you notice we can use the placeholder
%cat%
which will be replaced by the name of the K2 category. - the third column is the weight given for the criteria and the sum of the weights of all criteria within a criteria group need to add up to 100
- the fourth column is the options available for the user to respond to for the criteria
- the fifth column which is assigned as false throughout indicates whether the criteria is a required one to be filled by user or not and is a feature yet to be supported and is best left as false for now
- the last column allows you to choose how the criteria should be presented with the options
- stars - a star starting from the left with the lowest option value and going in ascending order
- select - a drop down list with available options
Once you have defined the criteria group you then would need to tie it to the K2 category this should apply to. That is done in the Rating categories
field simply by providing the following:
12%%1%%
5%%2%%
- the first column provides the K2 category to tie to the criteria group. Alternatively here you can provide
all
to tie the criteria group 1 to all categories. - the second column provides the criteria group
- in the last column you can optionally provide comma separated K2 categories to be excluded from using this criteria group