Skip to content

Instantly share code, notes, and snippets.

@Pum-purum
Created December 3, 2019 12:25
Show Gist options
  • Select an option

  • Save Pum-purum/92720e3dcec3a8956ae1d9d283991c5c to your computer and use it in GitHub Desktop.

Select an option

Save Pum-purum/92720e3dcec3a8956ae1d9d283991c5c to your computer and use it in GitHub Desktop.

Revisions

  1. Pum-purum created this gist Dec 3, 2019.
    17 changes: 17 additions & 0 deletions script.js
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,17 @@
    for (value of this.IDS) {
    $('#' + value).barrating({
    theme: 'fontawesome-stars',
    showSelectedRating: false,
    initialRating: this,
    onSelect: function (value, text, event){
    var obj = this.$elem[0];
    if (value == 5) {
    var companyID = $(obj).data('companyid');
    _this.allCorrect(value, companyID)
    } else {
    var companyName = $(obj).data('name');
    _this.notAllCorrect(value, companyName, event);
    }
    },
    });
    }